Results 1 to 10 of 12

Thread: fstab irrelevant?

Hybrid View

  1. #1
    Join Date
    Dec 2009
    Beans
    74

    fstab irrelevant?

    I just bought a new disk and installed it (internally) in my desktop computer, presently running ubuntu 10.04. I partitioned it, made a filesystem, and mounted it on a temporary mount point (/media/newdrive). Then did an df to double check, everything looked good. Next step was to edit fstab.

    The new disk is /dev/sda1. The root partition is presently on /dev/sdb1 - based on the output of df. But in fstab, which hasn't been modified for over a year, the root filesystem is on /dev/sda1. I rebooted, and nothing changed. So is fstab irrelevant?

    The plan is to install the latest ubuntu on the new disk, and then copy over personal stuff from the old disk. I could probably go ahead and just do this, but I'm wondering about fstab. I know I should be using UUIDs, if I do that and throw out the old fstab, will everything magically work?

    Thanks for any insight.

    Alex

  2. #2
    Join Date
    Oct 2011
    Location
    ZZ9 Plural Z Alpha
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: fstab irrelevant?

    Quote Originally Posted by grizdog View Post

    The new disk is /dev/sda1. The root partition is presently on /dev/sdb1 - based on the output of df. But in fstab, which hasn't been modified for over a year, the root filesystem is on /dev/sda1.
    This makes no sense to me at all. Check the device labels with fdisk-

    Code:
    sudo fdisk -l
    AFAIK the alphabetical order of devices (sda,sdb,sdc) never gets reversed like that.
    And as far as your intentions, why bother running both drives at the same time anyway? Remove the old drive, put the new one in, install Ubuntu, then transfer your stuff.

  3. #3
    Join Date
    Jul 2005
    Location
    England
    Beans
    Hidden!

    Re: fstab irrelevant?

    Quote Originally Posted by cortman View Post
    This makes no sense to me at all. Check the device labels with fdisk-

    Code:
    sudo fdisk -l
    AFAIK the alphabetical order of devices (sda,sdb,sdc) never gets reversed like that.
    And as far as your intentions, why bother running both drives at the same time anyway? Remove the old drive, put the new one in, install Ubuntu, then transfer your stuff.
    No, fstab is certainly not irrelevant; just try booting without one and you'll see why.

    I think you'll find that the sda, sdb etc, nomenclature can change in certain circumstances and that is one reason why fstab now uses UUIDs by default instead of the /dev/sda1 etc etc.

    I also have no doubt that the fstab file that the OP refers to uses UUID, but mentions /dev/sdx in a commented out line above, as is the current way of doing things in Ubuntu.

    If the old disk is an IDE and the new one is sata, I think that can account for the apparent reversal of priority, or the order they are attached to the cable in the machine or jumper settings of IDE disks may also be the reason.
    Last edited by ajgreeny; September 6th, 2012 at 03:43 PM.
    DISTRO: Xubuntu 14.04-64bit --- Code-tags --- Boot-Repair --- Grub2 wiki & Grub2 Basics --- RootSudo

  4. #4
    Join Date
    Apr 2008
    Location
    LOCATION=/dev/random
    Beans
    5,767
    Distro
    Ubuntu Development Release

    Re: fstab irrelevant?

    Can you post your fstab file please.
    Code:
    cat /etc/fstab
    Cheesemill

  5. #5
    Join Date
    Dec 2009
    Beans
    74

    Re: fstab irrelevant?

    Here is the output from fdisk -l:
    Code:
    sudo fdisk -l
    
    Disk /dev/sda: 1000.2 GB, 1000204886016 bytes
    255 heads, 63 sectors/track, 121601 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk identifier: 0x00002b1e
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sda1               1      121601   976760001   83  Linux
    
    Disk /dev/sdb: 250.1 GB, 250059350016 bytes
    255 heads, 63 sectors/track, 30401 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk identifier: 0x000bfb54
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sdb1   *           1       29656   238209024   83  Linux
    /dev/sdb2           29656       30402     5987329    5  Extended
    /dev/sdb5           29656       30402     5987328   82  Linux swap / Solaris
    
    Disk /dev/sdc: 500.1 GB, 500107862016 bytes
    255 heads, 63 sectors/track, 60801 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk identifier: 0x61ce8b27
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sdc1               1       60801   488384001   83  Linux
    And here is the content of fstab:
    Code:
    cat /etc/fstab
    # /etc/fstab: static file system information.
    #
    # Use 'blkid -o value -s UUID' to print the universally unique identifier
    # for a device; this may be used with UUID= as a more robust way to name
    # devices that works even if disks are added and removed. See fstab(5).
    #
    # <file system> <mount point>   <type>  <options>       <dump>  <pass>
    proc            /proc           proc    nodev,noexec,nosuid 0       0
    /dev/sda1       /               ext4    errors=remount-ro 0       1
    /dev/sda5       none            swap    sw              0       0
    /dev/fd0        /media/floppy0  auto    rw,user,noauto,exec,utf8 0       0
    /dev/sdb1       /media/disk     ext3    rw,nosuid,nodev,uhelper=udisks   0      2
    The drive that is mounted at /media/disk is an external drive I use for backups.

  6. #6
    Join Date
    Dec 2009
    Beans
    74

    Re: fstab irrelevant?

    Update: When I put in an Ubuntu install disk, the only drive it finds is the old one, the one with the old Ubuntu already installed. It does not find the new internal disk, or the external USB disk.

    Thanks for any help. THis looks very strange to me.

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
  •