LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 03-31-2011, 06:59 AM   #1
STDOUBT
Member
 
Registered: May 2010
Location: Stumptown
Distribution: Slackware64
Posts: 583

Rep: Reputation: 242Reputation: 242Reputation: 242
fsck is confused / lying


I have Lenny still running on a laptop (for various silly reasons I don't want to upgrade yet).
I boot this machine maybe 10 times per week. Last week fsck forced a check while I was on AC power. Everything went fine. Now, just a week or so later (after maybe 10 bootups), fsck forces another check stating the filesystem has been mounted 47 times... This is simply NOT true.
Does anyone have an idea of what might be going on here?
Many Thanks for clues!

EDIT:
Quote:
Originally Posted by widget View Post
It is not that you have booted that many times. It is that the file system has been mounted x number of times.
I tested this with some kludgey bashrc commands. Thank you for the enlightenment, sir!

Last edited by STDOUBT; 04-27-2011 at 09:57 PM.
 
Old 03-31-2011, 08:26 AM   #2
demosthenese
LQ Newbie
 
Registered: Sep 2010
Distribution: debian sid/xfce
Posts: 24

Rep: Reputation: 4
Do you have separate root and home partitions? Separate counts are kept for each if you do.
 
Old 03-31-2011, 09:02 AM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,126

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
User says "fsck is confused / lying"
Me says user versus Ted (presuming ext?) ....

Guess who I'm backing.
 
Old 03-31-2011, 10:13 AM   #4
tommylovell
Member
 
Registered: Nov 2005
Distribution: Raspbian, Debian, Ubuntu
Posts: 380

Rep: Reputation: 103Reputation: 103
Presuming ext2/3.

You can always do a 'dumpe2fs -h /dev/<devicename>' after each reboot and check the "Mount count:".

Code:
[root@example ~]# dumpe2fs -h /dev/mapper/athlon-root 
dumpe2fs 1.41.12 (17-May-2010)
.
.
.
Mount count:              11
Maximum mount count:      -1
Last checked:             Mon Mar 14 22:35:17 2011
Check interval:           0 (<none>)
.
.
.
And if "Maximum mount count: -1" and "Check interval: 0 (<none>)" (oops), you should change one or the other to occasionally force a 'fsck'.

Code:
[root@example ~]# tune2fs -i2w /dev/mapper/athlon-root 
tune2fs 1.41.12 (17-May-2010)
Setting interval between checks to 1209600 seconds

[root@example ~]# dumpe2fs -h /dev/mapper/athlon-root 
dumpe2fs 1.41.12 (17-May-2010)
.
.
.
Mount count:              11
Maximum mount count:      -1
Last checked:             Mon Mar 14 22:35:17 2011
Check interval:           1209600 (2 weeks)
Next check after:         Mon Mar 28 22:35:17 2011
.
.
.
I'm with syg00 on this one. Why would Lenny lie?

Last edited by tommylovell; 03-31-2011 at 10:15 AM.
 
Old 03-31-2011, 10:37 PM   #5
STDOUBT
Member
 
Registered: May 2010
Location: Stumptown
Distribution: Slackware64
Posts: 583

Original Poster
Rep: Reputation: 242Reputation: 242Reputation: 242
Quote:
Originally Posted by demosthenese View Post
Do you have separate root and home partitions? Separate counts are kept for each if you do.
Yes, separate / and /home partitions, both ext3.

Quote:
user versus Ted
I don't get this reference, but I think I understand your position.
Code:
example:/home/user# dumpe2fs -h /dev/mapper/sample-root 
.
.
Mount count:              4
Maximum mount count:      39
Last checked:             Thu Mar 31 04:46:13 2011
Check interval:           15552000 (6 months)
.
.
I understand why my "mounted 47 times" would happen visa vis my "Maximum mount count": on battery power, forced checks are skipped.

Code:
example:/home/user# dumpe2fs -h /dev/mapper/sample-home
.
.
Mount count:              15
Maximum mount count:      23
Last checked:             Thu Mar 24 03:46:15 2011
Check interval:           15552000 (6 months)
.
.
I'm guessing the difference in the "Maximum mount count" would be due to the idea that a root partition would need less frequent checking vs. a /home partition.

Anyway, if anyone has ideas for an explanation as to why fsck claims that I have booted 47 times when I know it was far less than that, I'd really appreciate it!
 
Old 03-31-2011, 11:21 PM   #6
widget
Senior Member
 
Registered: Oct 2008
Location: S.E. Montana
Distribution: Debian Testing, Stable, Sid and Manjaro, Mageia 3, LMDE
Posts: 2,628

Rep: Reputation: 497Reputation: 497Reputation: 497Reputation: 497Reputation: 497
I have no idea what you do on your box, like what else is installed or if you share files with another OS or computer.

That said, I get my / root partitions checked all the time with a similar message on this multi boot box that is used for testing (mainly Ubuntu pre-release versions).

You are somewhat incorrect as to the message. It is not that you have booted that many times. It is that the file system has been mounted x number of times.

If you are sharing files your /home file system is being mounted every time. I chroot into the test installs / partition to update/upgrade so the root partitions get mounted for that.

If I want to check files or maybe do some copy/paste of files or directories some installs file system is bing mounted to do those things.

This could be the case with you.
 
Old 04-01-2011, 09:13 AM   #7
demosthenese
LQ Newbie
 
Registered: Sep 2010
Distribution: debian sid/xfce
Posts: 24

Rep: Reputation: 4
Could it be the first fsck was on your root partition, and several battery boots later, the second fsck was on your home partition?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
President Bush just can't stop lying Envision5000 General 31 03-26-2006 02:52 PM
lying to programs DanTaylor Programming 11 02-28-2006 08:25 PM
URGENT- cfdisk or df are lying to me! TGWDNGHN Linux From Scratch 3 10-14-2005 08:53 AM
who is lying??? yenonn General 30 01-02-2004 02:35 AM
df -h .. Lying? mikeshn Linux - General 2 07-08-2002 08:52 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 11:35 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration