Results 1 to 6 of 6
Hi,
Is there any way, to find out how many time my system has been rebooted till now....
- 05-30-2009 #1Just Joined!
- Join Date
- Mar 2007
- Posts
- 32
to find how many times my pc has been rebooted
Hi,
Is there any way, to find out how many time my system has been rebooted till now.
- 05-30-2009 #2
I'm not sure about any specific commands.
Hint: check your /var/log/messages . (and also any archived messages file) using grep to extract info. "Freeing initrd memory" or some other unique booting message and count it.
Mostly likely that will give you the answer.
HTH- Lakshmipathi.G
-------------------
FOSS India Award winning ext3fs Undelete tool and tutorials www.giis.co.in
First they criticize you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
-------------------
- 05-30-2009 #3Just Joined!
- Join Date
- Mar 2007
- Posts
- 32
Hi,
During the mean time, I did a search and find out with the command tune2fs, with the option as -l
#tune2fs -l /dev/hda4
Note: /dev/hda4 may be any partition, but / partition is fine to go with .
Result:
Mount count: 4
I am not sure, whether is could be the exact one, but this is also one way to find out.
- 05-30-2009 #4
Solution from ext3-user mail list;
mount count value will reset back to 0 when it reaches maximum mount count,set for automatic
execution of e2fsck .
so use the last command,
HTHlast reboot- Lakshmipathi.G
-------------------
FOSS India Award winning ext3fs Undelete tool and tutorials www.giis.co.in
First they criticize you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
-------------------
- 05-30-2009 #5Linux Newbie
- Join Date
- Sep 2004
- Location
- UK
- Posts
- 160
This might help, probably won't:
smartctl --all /dev/sda
It gives Power_Cycle_Count and Start_Stop_Count for the harddisk, which IF the system only runs Linux and the disk was installed when you installed linux should give a reasonaly accurate idea on number of soft-reboots and hard (power cycle reboots)
on mine I get (the systems only ever run linux and was a new build):
4 Start_Stop_Count 0x0032 100 100 020 Old_age Always - 354
12 Power_Cycle_Count 0x0032 100 100 020 Old_age Always - 356
Other than that can't think of anything else.In a world without walls and fences, who needs Windows and Gates?
- 05-31-2009 #6Just Joined!
- Join Date
- Nov 2008
- Location
- Virginia, USA
- Posts
- 18


Reply With Quote
