Skip to main content

Thread: Lost /etc/fstab - Need to Rebuild


hey all,

long story short, haste, not enough speed, tab completion , typo means i'm without fstab. machine has affected rather new , using software raid, i'd appreciate few pointers on getting fixed up. i've made start, i'd rather not blindly test attempt , leave myself non-booting os.

fstab rebuild attempt:
code:
proc        /proc            proc    defaults                        0    0 none        /dev/pts        devpts    gid=5,mode=620                        0    0 /dev/md1    /            ext4    rw,relatime,errors=remount-ro,barrier=1,data=ordered    0    0 /dev/md2    /home            ext4    rw,relatime,barrier=1,data=ordered            0    0
/etc/mtab:
code:
$ cat /etc/mtab  rootfs / rootfs rw 0 0 /dev/root / ext4 rw,relatime,errors=remount-ro,barrier=1,data=ordered 0 0 none /proc proc rw,nosuid,nodev,noexec,relatime 0 0 none /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0 none /proc/sys/fs/binfmt_misc binfmt_misc rw,nosuid,nodev,noexec,relatime 0 0 none /sys/fs/fuse/connections fusectl rw,relatime 0 0 /dev /dev devtmpfs rw,relatime,size=8183468k,nr_inodes=2045867,mode=755 0 0 none /dev/pts devpts rw,nosuid,noexec,relatime,gid=5,mode=620 0 0 none /dev/shm tmpfs rw,nosuid,nodev,relatime 0 0 none /var/run tmpfs rw,nosuid,relatime,mode=755 0 0 none /var/lock tmpfs rw,nosuid,nodev,noexec,relatime 0 0 /dev/md2 /home ext4 rw,relatime,barrier=1,data=ordered 0 0
fdisk:
code:
$ sudo fdisk -l  disk /dev/sda: 2000.4 gb, 2000398934016 bytes 255 heads, 63 sectors/track, 243201 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: 0x000b5ce3     device boot      start         end      blocks   id  system /dev/sda1   *           1        1306    10485760+  fd  linux raid autodetect /dev/sda2            1306      243136  1942498304   fd  linux raid autodetect /dev/sda3          243136      243201      525920   82  linux swap / solaris  disk /dev/sdb: 2000.4 gb, 2000398934016 bytes 255 heads, 63 sectors/track, 243201 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: 0x00095fa9     device boot      start         end      blocks   id  system /dev/sdb1   *           1        1306    10485760+  fd  linux raid autodetect /dev/sdb2            1306      243136  1942498304   fd  linux raid autodetect /dev/sdb3          243136      243201      525920   82  linux swap / solaris  disk /dev/md2: 1989.1 gb, 1989118197760 bytes 2 heads, 4 sectors/track, 485624560 cylinders units = cylinders of 8 * 512 = 4096 bytes sector size (logical/physical): 512 bytes / 512 bytes i/o size (minimum/optimal): 512 bytes / 512 bytes disk identifier: 0x00000000  disk /dev/md2 doesn't contain valid partition table  disk /dev/md1: 10.7 gb, 10737352704 bytes 2 heads, 4 sectors/track, 2621424 cylinders units = cylinders of 8 * 512 = 4096 bytes sector size (logical/physical): 512 bytes / 512 bytes i/o size (minimum/optimal): 512 bytes / 512 bytes disk identifier: 0x00000000  disk /dev/md1 doesn't contain valid partition table
df:
code:
$ df -h filesystem            size  used avail use% mounted on rootfs                 10g  6.5g  3.0g  69% / /dev/root              10g  6.5g  3.0g  69% / /dev                  7.9g  176k  7.9g   1% /dev none                  7.9g     0  7.9g   0% /dev/shm none                  7.9g   76k  7.9g   1% /var/run none                  7.9g     0  7.9g   0% /var/lock /dev/md2              1.8t  271g  1.5t  16% /home
thanks in advance, i'll try more careful next time

normally backup file created. check folder /etc/ file called fstab.bak. backup file. see if can replace existing 1 one , hope .bak file nof damaged. compare 2 files , check if .bak file correct. swap files:

- open terminal
- type: sudo rm /etc/fstab
- type sudo rename /etc/fstab.bak /etc/fstab

happens when reboot?


Forum The Ubuntu Forum Community Ubuntu Official Flavours Support General Help [SOLVED] Lost /etc/fstab - Need to Rebuild


Ubuntu

Comments

Popular posts from this blog

Falang and too many redirects - Joomla! Forum - community, help and support

Infinite loop detected in JErrorInfinite loop detected in JError - Joomla! Forum - community, help and support

logged out from joomla! - Joomla! Forum - community, help and support