You are not logged in.

#1 2017-04-24 01:04:15

halgi
Member
Registered: 2016-05-19
Posts: 27

[SOLVED] Fstab and partition name changes

My fstab is :

# 
# /etc/fstab: static file system information
#
# UUID=678f7528-285a-4494-aee3-86ecb9c57cc6 LABEL=Arch\134x20fs
/dev/sdc5           	/         	ext4      	rw,relatime,data=ordered	0 1

# UUID=b8c4bd1d-3729-42d0-b0fa-03a45b39c916
/dev/sda1           	/home/gi/multimedia	ext4      	rw,relatime,data=ordered	0 2

# UUID=6478-AF4E
/dev/sdc1           	/boot/efi 	vfat      	rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro	0 2

# UUID=382a107d-b545-4d2f-bbc5-2c114c438b44 LABEL=Linux\134x20Swap
/dev/sdc4           	none      	swap      	defaults  	0 0

For some reason my ssd was found to be /dev/sdc, and the arch install usb was /dev/sdb. When i bootup without the usb a startup job hangs.

Here is the output of lsblk

NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0 931.5G  0 disk 
└─sda1   8:1    0 931.5G  0 part /home/gi/multimedia
sdb      8:16   1  14.4G  0 disk 
├─sdb1   8:17   1   867M  0 part 
└─sdb2   8:18   1    64M  0 part 
sdc      8:32   0 232.9G  0 disk 
├─sdc1   8:33   0   100M  0 part /boot/efi
├─sdc2   8:34   0   128M  0 part 
├─sdc3   8:35   0 122.4G  0 part 
├─sdc4   8:36   0     8G  0 part [SWAP]
└─sdc5   8:37   0    60G  0 part /

Any ideas on how to fix this?

Last edited by halgi (2017-04-24 01:44:51)

Offline

#2 2017-04-24 01:07:39

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: [SOLVED] Fstab and partition name changes

You already have UUIDs listed as comments in fstab. Just use them instead of paths. Verify them with

lsblk -f

and then use the format

UUID=<uuid>

.

I wrote a script not too long ago to partially automate the update: fstab-uuid.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#3 2017-04-24 01:37:26

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,523
Website

Re: [SOLVED] Fstab and partition name changes

How is that script different from just using `genfstab -pU /`?


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Online

#4 2017-04-24 01:47:58

halgi
Member
Registered: 2016-05-19
Posts: 27

Re: [SOLVED] Fstab and partition name changes

Xyne's solution worked thanks!

Trilby wrote:

How is that script different from just using `genfstab -pU /`?

I used 'genfstab -p' i think the -U option will use uuid=<uuid> instead of /dev/sda etc. . .

Edit: Trilby sorry i misread your post ignore this reply

Last edited by halgi (2017-04-24 01:54:24)

Offline

#5 2017-04-24 02:13:11

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: [SOLVED] Fstab and partition name changes

Trilby wrote:

How is that script different from just using `genfstab -pU /`?

I was aware of my own script. I was not aware of "genfstab -pU /". tongue

I wrote it to scratch a quick itch when I needed to update fstab, crypttab and the bootloader config file. It can "parse" any file consisting of delimited fields (fstab, crypttab) and it can also scan other formats for candidate paths that have UUIDs.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

Board footer

Powered by FluxBB