[CALUG] Strange behaviour

John Szakmeister john at szakmeister.net
Mon Jun 24 20:49:49 EDT 2013


On Mon, Jun 24, 2013 at 3:27 PM, Rajiv Gunja <opn.src.rocks at gmail.com> wrote:
> Yup! it was exactly due to the switch at the end of 23 hours 59 minutes.
> I had to change my code to :
>
> uptime | awk '{print $(NF-2)" " $(NF-1)" " $NF }'
>
> that way I always have the last 3 columns, irrespective of the day.
>
> After I saw that hour switch every 24 hours, I felt so ashamed of missing
> that.
>
> Thanks once again for the help.

You're welcome!  Glad it's all working for you now.

-John



More information about the CALUG mailing list