como fazer o / etc / fstab original?

1

como fazer original / etc / fstab? obrigado

root@Gateway:~# fdisk -l

Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders, total 156301488 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00033c3d

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048    70311935    35154944   83  Linux
/dev/sda2        70311936   148436991    39062528   83  Linux
/dev/sda3       148439038   156301311     3931137    5  Extended
/dev/sda5       148439040   156301311     3931136   82  Linux swap / Solaris

Disk /dev/mapper/cryptswap1: 4025 MB, 4025483264 bytes
255 heads, 63 sectors/track, 489 cylinders, total 7862272 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x27dc0ef5

Disk /dev/mapper/cryptswap1 doesn't contain a valid partition table
root@Gateway:~#
    
por zerolah 04.04.2014 / 12:44

1 resposta

1

Um exemplo de como recriar o fstab pode ser encontrado em ubuntuforums.org

Você precisa do resultado de:

$ sudo blkid
/dev/sda1: LABEL="EFI" UUID="3F3C-1AF6" TYPE="vfat"
/dev/sda2: UUID="83062D46C78FDD33" LABEL="Macintosh HD" TYPE="hfsplus"
/dev/sda3: UUID="9A1C07811C075821" TYPE="ntfs"
/dev/sda4: UUID="58e05acc-a255-48c7-ac8a-acbf5a7764c9" TYPE="ext3"
/dev/sda5: TYPE="swap" UUID="dc91869f-897e-47d1-a472-98551ae03fa5"

e de:

$ cat /etc/mtab
/dev/sda4 / ext3 rw,relatime,errors=remount-ro 0 0
tmpfs /lib/init/rw tmpfs rw,nosuid,mode=0755 0 0
proc /proc proc rw,noexec,nosuid,nodev 0 0
sysfs /sys sysfs rw,noexec,nosuid,nodev 0 0
varrun /var/run tmpfs rw,nosuid,mode=0755 0 0
varlock /var/lock tmpfs rw,noexec,nosuid,nodev,mode=1777 0 0
udev /dev tmpfs rw,mode=0755 0 0
tmpfs /dev/shm tmpfs rw,nosuid,nodev 0 0
devpts /dev/pts devpts rw,noexec,nosuid,gid=5,mode=620 0 0
fusectl /sys/fs/fuse/connections fusectl rw 0 0
lrm /lib/modules/2.6.28-17-generic/volatile tmpfs rw,mode=755 0 0
securityfs /sys/kernel/security securityfs rw 0 0
binfmt_misc /proc/sys/fs/binfmt_misc binfmt_misc rw,noexec,nosuid,nodev 0 0
gvfs-fuse-daemon /home/dan/.gvfs fuse.gvfs-fuse-daemon rw,nosuid,nodev,user=dan 0 0

Com esses resultados, você pode recriar um arquivo fstab. Com base no exemplo, seria:

# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
# /dev/sda4
UUID=58e05acc-a255-48c7-ac8a-acbf5a7764c9 / ext3 relatime,errors=remount-ro 0 1
# /dev/sda5
UUID=dc91869f-897e-47d1-a472-98551ae03fa5 none swap defaults 0 0

Mas o seu / etc / fstab será diferente. Você terá diferentes UUIDs, discos diferentes e pode ter diferentes opções de montagem.

    
por Rinzwind 04.04.2014 / 12:55