Page 2 of 2 FirstFirst 12
Results 11 to 16 of 16

Thread: Check disk on EVERY boot

  1. #11
    Join Date
    Mar 2007
    Location
    S.West Greater London, UK
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Check disk on EVERY boot

    mount
    -----
    PHP Code:
    /dev/sda5 on type ext2 (rw,errors=remount-ro,user_xattr)
    proc on /proc type proc (rw,noexec,nosuid,nodev)
    sysfs on /sys type sysfs (rw,noexec,nosuid,nodev)
    none on /sys/fs/fuse/connections type fusectl (rw)
    none on /sys/kernel/debug type debugfs (rw)
    none on /sys/kernel/security type securityfs (rw)
    udev on /dev type devtmpfs (rw,mode=0755)
    devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
    tmpfs on /run type tmpfs (rw,noexec,nosuid,size=10%,mode=0755)
    none on /run/lock type tmpfs (rw,noexec,nosuid,nodev,size=5242880)
    none on /run/shm type tmpfs (rw,nosuid,nodev)
    /
    dev/sda1 on /media/sda1 type fuseblk (rw,noexec,nosuid,nodev,allow_other,blksize=4096)
    /
    dev/sda2 on /media/sda2 type fuseblk (rw,noexec,nosuid,nodev,allow_other,blksize=4096)
    binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
    gvfs-fuse-daemon on /home/retrobadger/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=retrobadger


    So from that I believe it is sda5, which returns:

    PHP Code:
    tune2fs 1.42 (29-Nov-2011)
    Filesystem volume name:   <none>
    Last mounted on:          <not available>
    Filesystem UUID:          d4632dd4-13ce-4b61-85ad-80f1250740c8
    Filesystem magic number
    :  0xEF53
    Filesystem revision 
    #:    1 (dynamic)
    Filesystem features:      ext_attr filetype sparse_super large_file
    Default mount options:    (none)
    Filesystem state:         not clean
    Errors behavior
    :          Continue
    Filesystem OS type:       Linux
    Inode count
    :              18497536
    Block count
    :              36971581
    Reserved block count
    :     1848579
    Free blocks
    :              11219686
    Free inodes
    :              17189358
    First block
    :              0
    Block size
    :               4096
    Fragment size
    :            4096
    Blocks per group
    :         32768
    Fragments per group
    :      32768
    Inodes per group
    :         16384
    Inode blocks per group
    :   512
    Last mount time
    :          Fri Jun 15 18:30:59 2012
    Last write time
    :          Wed Dec 12 13:02:52 2012
    Mount count
    :              1
    Maximum mount count
    :      30
    Last checked
    :             Wed Dec 12 11:49:06 2012
    Check interval
    :           (<none>)
    Reserved blocks uid:      (user root)
    Reserved blocks gid:      (group root)
    First inode:              11
    Inode size
    :              128 

    I'm not quite sure what I am reading, but notice the line:
    PHP Code:
    Filesystem state:         not clean 

    boot.log
    --------
    PHP Code:
    tail -n20 /var/log/boot.log
     
    Setting sensors limits                                                                                                                                OK ]
     * 
    Starting the Firestarter firewall...                                                                                                                  [fail]
     * 
    Stopping System V initialisation compatibility                                                                                                        OK ]
     * 
    Starting System V runlevel compatibility                                                                                                              OK ]
     * 
    Starting eCryptfs                                                                                                                                     OK ]
     * 
    Starting restore sound card(s') mixer state(s)                                                                                                        [ OK ]
     * Starting GNOME Display Manager                                                                                                                        [ OK ]
     * Starting ACPI daemon                                                                                                                                  [ OK ]
     * Starting anac(h)ronistic cron                                                                                                                         [ OK ]
     * Starting save kernel messages                                                                                                                         [ OK ]
     * Starting LightDM Display Manager                                                                                                                      [ OK ]
     * Starting regular background program processing daemon                                                                                                 [ OK ]
     * Starting deferred execution scheduler                                                                                                                 [ OK ]
     * Stopping anac(h)ronistic cron                                                                                                                         [ OK ]
     * Stopping CPU interrupts balancing daemon                                                                                                              [ OK ]
     * Stopping GNOME Display Manager                                                                                                                        [ OK ]
     * Starting automatic crash report generation                                                                                                            [ OK ]
     * Stopping eCryptfs                                                                                                                                     [ OK ]
     * Stopping save kernel messages                                                                                                                         [ OK ]
     * Starting crash report submission daemon                                                                                                               [ OK ] 


    And no, I cannot see a forcefsck file in the root.


    Dan
    Dan Duke
    www.retrobadger.net
    Freelance Web/Drupal Designer & Developer.

  2. #12
    Join Date
    Mar 2010
    Location
    Metro-ATL; PM free zone.
    Beans
    9,335
    Distro
    Lubuntu 14.04 Trusty Tahr

    Re: Check disk on EVERY boot

    ext2 is part of the problem. It isn't a journaled file system. You need to be using ext3 or later.

    I'd remove all the NTFS crap from the fstab for now. It isn't helping.

    Also, it seems that your file system has some corruption. The running of fsck during reboot is trying to correct it. I guess it is failing, hence the reason it tries again at the next reboot.

    I'd get a good backup ASAP, then I'd
    * boot from a tools liveCD and run fsck against the ext2 partition manually so I could see what the problems are.
    * migrate to ext3, which is a journal layer over ext2.

    Simplify the problem until you can determine WHAT the problem is and solve it.

  3. #13
    Join Date
    Mar 2007
    Location
    S.West Greater London, UK
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Check disk on EVERY boot

    Ok, I will try and dedicate some time to that over the weekend to do the backup, fsck, and change filesystem. Would you recommend going to ext3 or skipping that entirely and going to ext4 through this method?

    Also, what are the commands to switch the filesystem? I can find lots of exmaples online, but wonder which is right.

    ext2 > ext3
    tune2fs -j /dev/sda5
    e2fsck -pf /dev/sda5


    ext2 > ext4
    tune2fs -O extents,uninit_bg,dir_index /dev/sda5
    e2fsck -pf /dev/sda5


    Dan
    Dan Duke
    www.retrobadger.net
    Freelance Web/Drupal Designer & Developer.

  4. #14
    Join Date
    Mar 2010
    Location
    Metro-ATL; PM free zone.
    Beans
    9,335
    Distro
    Lubuntu 14.04 Trusty Tahr

    Re: Check disk on EVERY boot

    Quote Originally Posted by retrodans View Post
    Also, what are the commands to switch the filesystem? I can find lots of exmaples online, but wonder which is right.
    I don't know. I've never migrated file systems myself. The man page for each command is enlightening. I would start by reading the man page on newfs, mkfs and tune2fs. Of course, you can always perform a backup, use a LiveCD to create a new file system with ext3 or ext4, then restore from the backup to the new file system. Be very careful about restoring the /etc/fstab - this file specified the file system, so if you've changed it, but it still says ext2, bad things will happen. All this work is best performed from a liveCD ... unless you want to risk corrupted data later.

    I would try a little research, read up on any command that a website says will migrate - the EXT2 to EXT3 migration really should be easy, fairly quick and risk free, assuming the issues with your EXT2 fsck are corrected. If you don't get those corrected, I'd build a new file system from scratch and restore the backup.

    Which file system? That is a tough question. The default for Ubuntu is ext4, so many people are using it happily. I've started using it on new, non-production systems. I still use JFS for my critical data and ext3 for all production stuff. JFS was easier than other options when I started on Linux - long before EXT3 existed. File systems are the base for data available on any OS and shouldn't be selected without knowledge of the risks and rewards. Ext4 might be fine for most people's data, but from time to time, there are still edge cases that lose data. I saw one report earlier this year. My data is too important to risk loss, even with fantastic backups and RAID for the primary storage. Others will have a different opinion and will say that I'm too risk adverse.

    Most of the people that I know running large scale Linux systems use XFS for everything except the boot partition. XFS has a long history of great performance and stability, but it cannot be booted under Linux. It is a peer file system from the time of JFS, but XFS has better performance. http://www.phoronix.com/scan.php?pag...item&px=Nzg4MA explains a little why Google chose EXT4 over XFS or JFS.

    Choices, choices.

    The quick answer is "use ext4." You will probably be just fine and the performance of ext4 is extremely good. I do not know anyone that has lost data under EXT4 due to file system issues. Still, nothing replaces having good, automatic, backups.

    If I have some time later, I'll look up how to migrate ext2 to other file EXT[34] systems - more for my curiosity than anything else. http://www.ghacks.net/2010/08/11/convert-ext23-to-ext4/ seems to have reasonable steps outlined, but just be certain you do a backup before starting. Screwing around with file systems is dangerous and total loss of data can happen. I found a few other articles, but those were older and expected that we'd pull ext4 code from a source repository and compile the drivers. That is not needed anymore and will lead to a long term maintenance issue if you do it. Best to stay with tools from the package manager system to avoid that.
    Last edited by TheFu; December 14th, 2012 at 04:14 PM. Reason: bold for caution about fixing current issue.

  5. #15
    Join Date
    Jan 2010
    Location
    Auckland, New Zealand
    Beans
    87
    Distro
    Ubuntu 12.10 Quantal Quetzal

    Re: Check disk on EVERY boot

    Before migrating the file system, I'd recommend sorting out the problems with the existing ext2 filesystem.

    If you have a live CD, I'd boot from that and run e2fsck on the problem filesystem. That will let you see what errors are reported and, if it is successful, it should mark the filesystem as clean.

  6. #16
    Join Date
    Mar 2007
    Location
    S.West Greater London, UK
    Beans
    Hidden!
    Distro
    Ubuntu

    Talking Re: Check disk on EVERY boot

    Brilliant, that seems to have solved my issue perfectly. Thanks for that.
    Dan Duke
    www.retrobadger.net
    Freelance Web/Drupal Designer & Developer.

Page 2 of 2 FirstFirst 12

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •