You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are a number of ways that a Stratis filesystem UUID could be changed, erased, or corrupted outside of Stratis’ control. Should Stratis be aware of this kind of change and if so, what should be done about it?
In this example the a filesystem is created and then wiped, however from Stratis’ point of view the filesystem still exists and displays the UUID. The UUID is stored in the MDV and could be used for verification.
stratis pool create p1 /dev/loop0
stratis fs create p1 fs1
mkdir /fs1
mount /dev/stratis/p1/fs1 /fs1
[root@ci~]# df -lh
Filesystem Size Used Avail Use% Mounted on
devtmpfs 869M 0 869M 0% /dev
tmpfs 888M 0 888M 0% /dev/shm
tmpfs 356M 9.5M 346M 3% /run
/dev/vda1 20G 2.0G 19G 10% /
tmpfs 178M 0 178M 0% /run/user/0
tmpfs 1.0M 0 1.0M 0% /run/stratisd/keyfiles
/dev/mapper/stratis-1-377c6813ac5947c0b2d0d91e65e5642b-thin-fs-232c3a2f36da45a89532592570838ece 1.0T 7.2G 1017G 1% /fs1
[root@ci~]# stratis pool
Name Total Physical Properties UUID
p1 10 GiB / 583.65 MiB / 9.43 GiB ~Ca,~Cr 377c6813-ac59-47c0-b2d0-d91e65e5642b
[root@ci~]# stratis fs
Pool Name Name Used Created Device UUID
p1 fs1 546 MiB Jan 17 2022 16:49 /dev/stratis/p1/fs1 232c3a2f-36da-45a8-9532-592570838ece
[root@ci~]# blkid
/dev/vda1: UUID="b7392ae2-037b-442a-b489-5b1f6ed9cb7c" BLOCK_SIZE="512" TYPE="xfs" PARTUUID="460985b7-01"
/dev/loop1: UUID="9550b846-ccc0-4276-b123-c46046a05a95" POOL_UUID="377c6813-ac59-47c0-b2d0-d91e65e5642b" BLOCKDEV_SECTORS="20971520" BLOCKDEV_INITTIME="1642456188" TYPE="stratis"
/dev/mapper/stratis-1-377c6813ac5947c0b2d0d91e65e5642b-thin-fs-232c3a2f36da45a89532592570838ece: UUID="232c3a2f-36da-45a8-9532-592570838ece" BLOCK_SIZE="512" TYPE="xfs"
[root@ci~# umount /fs1
[root@ci~]# wipefs -a /dev/stratis/p1/fs1
/dev/stratis/p1/fs1: 4 bytes were erased at offset 0x00000000 (xfs): 58 46 53 42
[root@ci~]# blkid
/dev/vda1: UUID="b7392ae2-037b-442a-b489-5b1f6ed9cb7c" BLOCK_SIZE="512" TYPE="xfs" PARTUUID="460985b7-01"
/dev/loop1: UUID="9550b846-ccc0-4276-b123-c46046a05a95" POOL_UUID="377c6813-ac59-47c0-b2d0-d91e65e5642b" BLOCKDEV_SECTORS="20971520" BLOCKDEV_INITTIME="1642456188" TYPE="stratis"
[root@ci~]# stratis pool
Name Total Physical Properties UUID
p1 10 GiB / 583.65 MiB / 9.43 GiB ~Ca,~Cr 377c6813-ac59-47c0-b2d0-d91e65e5642b
[root@ci~]# stratis fs
Pool Name Name Used Created Device UUID
p1 fs1 546 MiB Jan 17 2022 16:49 /dev/stratis/p1/fs1 232c3a2f-36da-45a8-9532-592570838ece
[root@localhost scripts]# reboot
--- vm started ---
(manually start loop0 again)
[root@ci~]# stratis pool
Name Total Physical Properties UUID
p1 10 GiB / 583.65 MiB / 9.43 GiB ~Ca,~Cr 377c6813-ac59-47c0-b2d0-d91e65e5642b
[root@ci~]# stratis fs
Pool Name Name Used Created Device UUID
p1 fs1 546 MiB Jan 17 2022 16:49 /dev/stratis/p1/fs1 232c3a2f-36da-45a8-9532-592570838ece
[root@ci~]# blkid
/dev/loop0: UUID="9550b846-ccc0-4276-b123-c46046a05a95" POOL_UUID="377c6813-ac59-47c0-b2d0-d91e65e5642b" BLOCKDEV_SECTORS="20971520" BLOCKDEV_INITTIME="1642456188" TYPE="stratis"
/dev/vda1: UUID="b7392ae2-037b-442a-b489-5b1f6ed9cb7c" BLOCK_SIZE="512" TYPE="xfs" PARTUUID="460985b7-01"
[root@ci~]# ls -trlh /dev/mapper
total 0
crw-------. 1 root root 10, 236 Jan 17 16:54 control
lrwxrwxrwx. 1 root root 7 Jan 17 17:04 stratis-1-private-377c6813ac5947c0b2d0d91e65e5642b-physical-originsub -> ../dm-0
lrwxrwxrwx. 1 root root 7 Jan 17 17:04 stratis-1-private-377c6813ac5947c0b2d0d91e65e5642b-flex-thinmeta -> ../dm-1
lrwxrwxrwx. 1 root root 7 Jan 17 17:04 stratis-1-private-377c6813ac5947c0b2d0d91e65e5642b-flex-thindata -> ../dm-2
lrwxrwxrwx. 1 root root 7 Jan 17 17:04 stratis-1-private-377c6813ac5947c0b2d0d91e65e5642b-flex-mdv -> ../dm-4
lrwxrwxrwx. 1 root root 7 Jan 17 17:04 stratis-1-private-377c6813ac5947c0b2d0d91e65e5642b-thinpool-pool -> ../dm-3
lrwxrwxrwx. 1 root root 7 Jan 17 17:04 stratis-1-377c6813ac5947c0b2d0d91e65e5642b-thin-fs-232c3a2f36da45a89532592570838ece -> ../dm-5
[root@ci~]# mount /dev/mapper/stratis-1-private-377c6813ac5947c0b2d0d91e65e5642b-flex-mdv /mnt
[root@ci~]# cat /mnt/filesystems/232c3a2f36da45a89532592570838ece.json
{"name":"fs1","uuid":"232c3a2f-36da-45a8-9532-592570838ece","thin_id":0,"size":2147483648,"created":1642456189}[root@ci~]#
[root@ci~]# stratis report engine_state_report
{
"errored_pools": [],
"hopeless_devices": [],
"pools": [
{
"blockdevs": {
"cachedevs": [],
"datadevs": [
{
"path": "/dev/loop0",
"uuid": "9550b846-ccc0-4276-b123-c46046a05a95"
}
]
},
"filesystems": [
{
"name": "fs1",
"uuid": "232c3a2f-36da-45a8-9532-592570838ece"
}
],
"name": "p1",
"uuid": "377c6813-ac59-47c0-b2d0-d91e65e5642b"
}
]
}
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
There are a number of ways that a Stratis filesystem UUID could be changed, erased, or corrupted outside of Stratis’ control. Should Stratis be aware of this kind of change and if so, what should be done about it?
In this example the a filesystem is created and then wiped, however from Stratis’ point of view the filesystem still exists and displays the UUID. The UUID is stored in the MDV and could be used for verification.
Beta Was this translation helpful? Give feedback.
All reactions