public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrei Borzenkov <arvidjaar@gmail.com>
To: linux-btrfs@vger.kernel.org
Subject: Re: find snapshot parent?
Date: Mon, 8 Jul 2019 07:05:01 +0300	[thread overview]
Message-ID: <243cd969-9ee1-e031-894c-f99b63c630bb@gmail.com> (raw)
In-Reply-To: <20190707221837.GA15143@tik.uni-stuttgart.de>

08.07.2019 1:18, Ulli Horlacher пишет:
> On Sun 2019-07-07 (12:12), Nikolay Borisov wrote:
> 
> 
>> root@ubuntu-virtual:~# mount /dev/vdc /media/scratch/
>>
>> root@ubuntu-virtual:~# btrfs subvol show /media/scratch/      
>> /
>> 	Name: 			<FS_TREE>
>> 	UUID: 			80633e8d-fa8a-4922-ac0c-b46d7b2e2d81
>> 	Parent UUID: 		-
>> 	Received UUID: 		-
>> 	Creation time: 		2019-07-07 09:09:15 +0000
>> 	Subvolume ID: 		5
>> 	Generation: 		8
>> 	Gen at creation: 	0
>> 	Parent ID: 		0
>> 	Top level ID: 		0
>> 	Flags: 			-
>> 	Snapshot(s):
>> 				snap1
>> 				snap-ro
> 
> 
> root@fex:~# lsb_release -d
> Description:    Ubuntu 18.04.2 LTS
> 
> root@fex:~# btrfs version
> btrfs-progs v4.15.1
> 
> root@fex:~# mount|grep /local
> /dev/sdd1 on /local type btrfs (rw,relatime,space_cache,user_subvol_rm_allowed,subvolid=5,subvol=/)
> 
> root@fex:~# btrfs subvolume show /local
> /
>         Name:                   <FS_TREE>
>         UUID:                   -
>         Parent UUID:            -
>         Received UUID:          -
>         Creation time:          -
>         Subvolume ID:           5
>         Generation:             1633457
>         Gen at creation:        0
>         Parent ID:              0
>         Top level ID:           0
>         Flags:                  -
> 
> No UUID!
> 

Neither here on different versions of openSUSE. Note that it also
mistakenly displays subvolumes as snapshots (I assume, it simply
compares NULL subvolume UUID with NULL parent UUID in this case).

bor@leap423:~> sudo btrfs version
btrfs-progs v4.5.3+20160729
bor@leap423:~> uname -a
Linux leap423 4.4.180-102-default #1 SMP Mon Jun 17 13:11:23 UTC 2019
(7cfa20a) x86_64 x86_64 x86_64 GNU/Linux
bor@leap423:~> sudo btrfs su sh /mnt
/mnt is toplevel subvolume
bor@leap423:~>

bor@localhost:~> sudo btrfs version
btrfs-progs v4.19.1
bor@localhost:~> uname -a
Linux localhost 4.12.14-lp151.28.7-default #1 SMP Mon Jun 17 16:36:38
UTC 2019 (f8a1872) x86_64 x86_64 x86_64 GNU/Linux
bor@localhost:~> sudo btrfs su sh /mnt
/
	Name: 			<FS_TREE>
	UUID: 			-
	Parent UUID: 		-
	Received UUID: 		-
	Creation time: 		-
	Subvolume ID: 		5
	Generation: 		338
	Gen at creation: 	0
	Parent ID: 		0
	Top level ID: 		0
	Flags: 			-
	Snapshot(s):
				@
				@/var
				@/usr/local
				@/tmp
				@/srv
				@/root
				@/opt
				@/home
				@/boot/grub2/x86_64-efi
				@/boot/grub2/i386-pc
				@/.snapshots
				@/.snapshots/1/snapshot
bor@localhost:~>

bor@10:~> sudo btrfs version
btrfs-progs v5.1
bor@10:~> uname -a
Linux 10.0.2.15 5.1.7-1-default #1 SMP Tue Jun 4 07:56:54 UTC 2019
(55f2451) x86_64 x86_64 x86_64 GNU/Linux
bor@10:~> sudo btrfs su sh /mnt
/
	Name: 			<FS_TREE>
	UUID: 			-
	Parent UUID: 		-
	Received UUID: 		-
	Creation time: 		-
	Subvolume ID: 		5
	Generation: 		26638
	Gen at creation: 	0
	Parent ID: 		0
	Top level ID: 		0
	Flags: 			-
	Snapshot(s):
				@
				@/.snapshots
				@/boot/grub2/i386-pc
				@/boot/grub2/x86_64-efi
				@/home
				@/opt
				@/srv
				@/tmp
				@/usr/local
				@/var/cache
				@/var/crash
				@/var/lib/libvirt/images
				@/var/lib/machines
				@/var/lib/mailman
				@/var/lib/mariadb
				@/var/lib/mysql
				@/var/lib/named
				@/var/lib/pgsql
				@/var/log
				@/var/opt
				@/var/spool
				@/var/tmp
bor@10:~>



  reply	other threads:[~2019-07-08  4:11 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-06 15:53 find snapshot parent? Ulli Horlacher
2019-07-06 16:57 ` Nikolay Borisov
2019-07-06 20:43   ` Ulli Horlacher
2019-07-07  5:27     ` Andrei Borzenkov
2019-07-07  6:43     ` Nikolay Borisov
2019-07-07  7:37       ` Andrei Borzenkov
2019-07-07  9:12         ` Nikolay Borisov
2019-07-07 22:18           ` Ulli Horlacher
2019-07-08  4:05             ` Andrei Borzenkov [this message]
2019-07-06 23:24 ` Ulli Horlacher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=243cd969-9ee1-e031-894c-f99b63c630bb@gmail.com \
    --to=arvidjaar@gmail.com \
    --cc=linux-btrfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox