Hello,
Is it possible to change the way log files, NagiosXI backup file names, etc... anything that uses the Epoch time to use YYYYMMDDHHMMSS format instead?
Thanks,
JLu
Change system date/time stamps from epoch to YYYYMMDDHHMMSS
Re: Change system date/time stamps from epoch to YYYYMMDDHHM
Hi JLu,
How are you doing?
I'm very sorry but there is not a way to change Epoch time to a "human readable" format in Nagios XI.
However, you can try using perl -pe 's/(\d+)/localtime($1)/e' to convert the time to a "human readable" format.
Example:
Here's another similar ticket:
https://support.nagios.com/forum/viewto ... 16&t=44154
Best Regards,
Vinh
How are you doing?
I'm very sorry but there is not a way to change Epoch time to a "human readable" format in Nagios XI.
However, you can try using perl -pe 's/(\d+)/localtime($1)/e' to convert the time to a "human readable" format.
Example:
Code: Select all
tail -50 /usr/local/nagios/var/nagios.log | perl -pe 's/(\d+)/localtime($1)/e'
or
perl -pe 's/(\d+)/localtime($1)/e' < /usr/local/nagios/var/nagios.log | less
https://support.nagios.com/forum/viewto ... 16&t=44154
Best Regards,
Vinh
Re: Change system date/time stamps from epoch to YYYYMMDDHHM
Thank you for that.
Are there enough users who would qualify this for a new feature/option?
You can close the case.
Thanks again.
JLu
Are there enough users who would qualify this for a new feature/option?
You can close the case.
Thanks again.
JLu
Re: Change system date/time stamps from epoch to YYYYMMDDHHM
Hi JLu,
Please feel free to open a "feature request" at the below URL ...
https://github.com/NagiosEnterprises/nagioscore/issues
Closing ticket!! ...
Regards,
Vinh
Please feel free to open a "feature request" at the below URL ...
https://github.com/NagiosEnterprises/nagioscore/issues
Closing ticket!! ...
Regards,
Vinh