Can you help me find UUID of my SSD which is partitioned already? The goal is I want to mount this SSD under my home dir. To do so, I need to add a line to my /etc/fstab file. To do so, I need to put its UUID in the line. To do so, I need to determine its UUID. Nothing is output by command blkid, which baffles me. The advice in the fstab file says:
" Use 'blkid' to print the universally unique identifier for a device"
and I certainly have this device, and this device is certainly working, and certainly partitioned, and I used sudo, but blkid steadfastly won't print anything about this device's UUID for some reason. But maybe the UUID is already being shown in the file /etc/fstab as
UUID=69A1-BD52 so I don't really need blkid to work, and I can skip that nonsense. Not sure. OS is Ubuntu 14.04LTS.
Here is my current fstab:
# /etc/fstab: static file system information. # # Use 'blkid' 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> /dev/mapper/ubuntu--vg-root / ext4 errors=remount-ro 0 1 # /boot was on /dev/sda2 during installation UUID=9b4fb887-5dd8-413c-b0b0-dd3c803cf4ab /boot ext2 defaults 0 2 # /boot/efi was on /dev/sda1 during installation UUID=69A1-BD52 /boot/efi vfat umask=0077 0 1 /dev/mapper/ubuntu--vg-swap_1 none swap sw 0 0 /dev/nvme0n1 /mnt/fastssd auto nosuid,nodev,nofail,x-gvfs-show 0 0 # Following was added by ga for permanent fast swap file on ssd with high priority as created at cmd line earlier /mnt/fastssd/100GiB.swap none swap sw 0 0
Here is output of df command:
$ df Filesystem 1K-blocks Used Available Use% Mounted on udev 65956452 0 65956452 0% /dev tmpfs 13196096 9816 13186280 1% /run /dev/mapper/ubuntu--vg-root 1789679056 27183296 1671562308 2% / tmpfs 65980460 0 65980460 0% /dev/shm tmpfs 5120 4 5116 1% /run/lock tmpfs 65980460 0 65980460 0% /sys/fs/cgroup /dev/nvme0n1 492128608 104929192 362177652 23% /mnt/fastssd /dev/sda2 483946 250653 208308 55% /boot /dev/sda1 523248 3668 519580 1% /boot/efi tmpfs 13196096 0 13196096 0% /run/user/1000
Here is me running blkid to try to see the UUID:
$ blkid /dev/nvme0n1 $ blkid /mnt/fastssd $ sudo blkid /mnt/fastssd $ blkid /dev/sda1
Nothing outputted. I did not omit any output. My sudo login was successful.
This device is already partitioned and formatted and working nicely. Shouldn't every partitioned device already have a UUID?
UUID=69A1-BD52 its UUID? Can I confirm this?
Most important question: Can I safely repeat the
UUID=69A1-BD52 in the new line I wish to add to my fstab file, so it will mount this SSD under my home directory?
Example of line I would add to my fstab if it's safe and correct to do so:
UUID=69A1-BD52 /home/user/fastssd auto rw,noauto,user,sync 0 2
The above line is just a big guesstimate, and I don't know if 2 belongs there etc.
This device would be mounted twice. Is it safe or do I need to remove a line? I don't have a reason to keep the old mount location if the new mount location is OK. Would I need to change my SSD swap file entry if I move it to being under my home directory? It's OK by me for this device to be inaccessible to other users, as its my computer.