[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Is there a way to tell when a system was first booted?




On Aug 27, 2011 1:26 PM, "Ivan Shmakov" <ivan@gray.siamics.net> wrote:
>
> >>>>> shawn wilson <ag4ve.us@gmail.com> writes:
> >>>>> On Sat, Aug 27, 2011 at 11:43, John A. Sullivan III wrote:
> >>>>> On Sun, 2011-08-28 at 00:36 +1000, yudi v wrote:
>
>  >>> Is there a way to tell when a system was first booted?
>
>  >> Does "uptime" do what you want or do you mean booted for the truly
>  >> very first time (not counting reboots)?
>
>  > cat /proc/uptime
>
>        How's that more legible than the output of the uptime(1)
>        command?
>
> $ cat < /proc/uptime
> 44547837.32 177282465.98
> $ uptime
>  17:24:43 up 515 days, 14:24,  3 users,  load average: 0.00, 0.00, 0.00
> $

Nothing. Iirc uptime parses that file. For a history of boots, other than a BIOS log, you might look at the acct package, specifically what gets stored in wtmp. This would not give you anything prior to wtmp being created but might give you what you want.


Reply to: