Mailinglist Archive: opensuse-factory (437 mails)

< Previous Next >
[opensuse-factory] Re: fstab, systemd and UUID
On Tue, 7 Apr 2015 20:31, Cristian Rodríguez wrote:
On Tue, Apr 7, 2015 at 2:26 PM, ellanios82 wrote:

/dev/sdb3 swap swap defaults 0 0

No! device names are not persistent , that's why we are discussing this at all.

Ok, back to the planning board. Points made (and proven):

* "/dev/sd??" names are not persistent, not the solution we seek.

* "UUID" as it is, nice for filesystems, not so nice for swap.

* "/dev/disk/by-id/(ata|scsi-SATA)_{Dev_Model}_{Dev_Serial}-part?"
That is a valid (uniq, save to move port/order) solution, but
it is a really LONG string. (Some dislike this approach)

How about this mix:
We take the "UUID" approach, but change it some.
ACSII "SWAP" translates to "53 57 41 50 0a", let
this be the first part of any swap Partition UUID.
even better if in the next part is the {Dev_Serial}

For the full mounty:
"SWAP{Dev_Model}{Dev_Serial}{Part.no}{Fillup,random}"
convert this -> toHex, use as UUID

That way "swapon" can identify a valid swap partition,
even if the UUID changes.

All it would take is a change in mkswap and swapon code,
no other stuff has to be touched.


Please discuss.

- Yamaban.

< Previous Next >