Questions tagged [date]
154 questions
4
votes
3 answers
Convert SELinux log date format from Epoch to Normal
When SELinux logs an event to the audit log on my CentOS 6 system, it's logging it in epoch time which makes for a real hassle when trying to troubleshoot. Is there any way to make it log these events using human readable date formats? I've looked…

Safado
- 4,786
- 7
- 37
- 54
4
votes
2 answers
Date and time zone on Linux
I ran the date command and it gave the following output:
root@localhost:~$ date
Thu Dec 30 14:19:47 UTC 2010
Then, I modified the date using date -s which gave the following output:
root@localhost:~$ date -s "12/30/2010 JST 14:19:47"
Thu Dec 30…

LinuxPenseur
- 443
- 1
- 6
- 16
4
votes
2 answers
date keeps resetting
I have a virtual machine(VirtualBox) running Ubuntu server. When i issue date -s 2011-01-01 it changes the date, but after a few seconds, the date resets itself to the real time.
I do not have any ntp service running (althrough i'm not sure how to…

quamis
- 362
- 7
- 18
4
votes
4 answers
Why is my "Last log on" date wrong?
I'm sitting here across the office from Bob, who is logged into the domain right now, working away. I pull up AD Admin Center and take a look at Bob's account and it tells me his last log on date is 10/25/2010 at noon. It's currently 11/2/2010 at…

blsub6
- 1,131
- 6
- 25
- 45
3
votes
1 answer
jq sort by date (iso 8601)
I try to sort json by date (field CreationTimeUTC) in iso 8601 format with jq 1.5.
I found this post, but that return : 'Cannot index boolean with string "CreationTimeUTC"'
jq '.Entities.BackupJobSessions.BackupJobSessions[] |…

user5525652
- 157
- 1
- 4
- 14
3
votes
1 answer
Set date format in nginx autoindex HTML listing
The default date format in nginx autoindex HTML directory listings is 19-Jun-2019. Can I change it to ISO YYYY-MM-DD format instead?

Lassi
- 495
- 1
- 5
- 10
3
votes
1 answer
Linux date translation to different time zone
The Linux server is hosted in EST timezone. But I want to translate the output of date command to IST(Indian Standard time +5:30 hrs) format and use it in a shell script. Is there any option available for date command to do this or have manually…

nitins
- 2,579
- 15
- 44
- 68
3
votes
2 answers
Why is $ date still displaying EST when /etc/localtime is symlinked to /usr/share/zoneinfo/GMT?
I'm having a problem setting the date on my server...
$ ls -la /etc | grep localtime
lrwxrwxrwx 1 root root 23 Mar 6 12:07 /etc/localtime -> /usr/share/zoneinfo/GMT
For some reason, although the time 17:31:06 is GMT, the timezone suffix is…

Tom
- 731
- 3
- 11
- 24
2
votes
1 answer
filtering event logs with specific TIME range of ANY day
How can I query windows server events between two times of any day?
I have tried with PowerShell...
Get-EventLog -Logname xxxx -After 04:00:00 -Before 04:00:30
...but just returns today's events

jreinap
- 23
- 1
- 4
2
votes
0 answers
Journalctl seems to be ignoring since and until
I'm trying to get the logs of a problem that's been happening for over a week by this point. I'm trying to use journalctl to print the logs but it doesn't seem to give me anything more or less than the past 5 days. I've tried using since/until but…

Thomas
- 225
- 2
- 9
2
votes
1 answer
Centos 6 Timezone Wrong
I am trying to set my Centos 6 VPS to GMT timezone.
I tried a sudo ln -s /usr/share/zoneinfo/GMT /etc/localtime
Which works fine.
However when I run date it returns:
Tue Oct 4 05:09:32 GMT 2016
Which indicates there is something that is much more…

Shiv
- 199
- 1
- 6
2
votes
1 answer
Set up a permanent system date
I need to set up a permanent system date in a Linux test server for time-sensitive software which needs this time loop (Groundhog day's style) or bending time (Hiro's ones), you name it.
I tried it with a cron at 00:00 every day that invokes date to…

Dario Castañé
- 155
- 1
- 2
- 7
2
votes
0 answers
How to configure hwclock to UTC on Redhat Linux?
I have linux redhat machine
# more /etc/redhat-release
Red Hat Enterprise Linux Server release 5.11 (Tikanga)
I want to change the hwclock to UTC time
So I perform little test as
# date -u
Tue Jul 26 10:01:53 UTC 2016
more…

dandan
- 1,081
- 4
- 13
- 21
2
votes
2 answers
Creating a RFC 1123 compliant date for HTTP header creation on the CLI
I'm trying to create a HTTP 1/1 compliant date header using standard unix date(1) in order to post this to a RESTful server using curl or similar.
Any ideas what format to pass to date(1) to get this to be RFC 1123 compliant?
Many thanks

Brad
- 289
- 4
- 10
2
votes
1 answer
How to start tomcat with faketime within a docker container?
I use docker to deploy a Java web application in tomcat. For testing purposes, I want to force the system date to a specific value.
With Docker it is not possible to change the container date without affecting the host date. So I would like to use…

jsebfranck
- 213
- 1
- 2
- 7