Find the answer to your Linux question:
Results 1 to 3 of 3
Hi All, Iam new to LINUX, i want to change the date in my server. Code: developer@server:~> date Mon Apr 7 18:35:33 IST 2008 developer@server:~> date -s="4/8/2008 11:38:00" date: invalid ...
  1. #1
    Just Joined!
    Join Date
    Dec 2007
    Location
    chennai-TN,India
    Posts
    42

    [SOLVED] Error in Changing Date

    Hi All,

    Iam new to LINUX, i want to change the date in my server.

    Code:
    developer@server:~> date
    Mon Apr  7 18:35:33 IST 2008
    developer@server:~> date -s="4/8/2008 11:38:00"
    date: invalid date `=4/8/2008 11:38:00'
    developer@server:~>
    Can some one clarify me how can i change the date in LINUX and why it is throwing error as Invalid Date?

  2. #2
    Linux Newbie raghaven.kumar's Avatar
    Join Date
    Mar 2008
    Location
    Bangalore, India
    Posts
    209
    you can use the most simple format

    'date MMddhhmmyy.ss'
    M-month
    d-date
    h-hour
    m-minute
    y-year
    s-seconds

    eg. date 0408114808.22
    for Apr,8,2008 11:48:22

  3. #3
    Just Joined!
    Join Date
    Dec 2007
    Location
    chennai-TN,India
    Posts
    42
    Okay thanks for the reply, i dont have permission to set the date.

    Code:
    developer@server:~> date -s '040812102008'
    date: cannot set date: Operation not permitted
    Thu Jan  8 00:00:00 IST 213756
    Anyway thanks for your reply.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...