Linux-BTRFS Archive on lore.kernel.org
 help / color / Atom feed
From: Andrei Borzenkov <arvidjaar@gmail.com>
To: linux-btrfs@vger.kernel.org
Subject: Re: find subvolume directories
Date: Sat, 13 Jul 2019 14:10:50 +0300
Message-ID: <62366a29-a8ea-a889-f857-0305eba99051@gmail.com> (raw)
In-Reply-To: <20190713082759.GB16856@tik.uni-stuttgart.de>

13.07.2019 11:27, Ulli Horlacher пишет:
> On Sat 2019-07-13 (06:59), Andrei Borzenkov wrote:
>> 13.07.2019 2:17, Ulli Horlacher ?8H5B:
>>
>>> I need to find (all) subvolume directories.
> 
>> That is just coincidence because @/.snapshot subvolume is mounted on
>> /.snapshot. It could also be mounted under /var/lib/snapper (insert your
>> path here).
> 
> Yes, this is the problem for me!
> 
> 
>>> But what if a btrfs filesystem does not have a toplevel /@/ directory, but
>>> anything else, like /this/is/my/top/directory ?
>>>
>>
>> btrfs does not have "top level directory" beyond single /.
> 
> I used the wrong naming.
> I have meant "top level directory beyond /"
> 
> 
>> It is entirely up to the user who creates it how subvolumes are named and
>> structured. You can well have /foo, /bar, /baz mounted as /, /var and
>> /home.
> 
> And how can I find them in my mounted filesystem?
> THIS is my problem.

I am not sure what problem you are trying to solve, but you can use list
of current mounts to build path to each subvolume (as long as it is
either below one of mounted subvolumes or explicitly mounted).

> As I wrote: "find / -inum 256" is too slow.
> 
> 


  reply index

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-12 23:17 Ulli Horlacher
2019-07-13  3:59 ` Andrei Borzenkov
2019-07-13  8:27   ` Ulli Horlacher
2019-07-13 11:10     ` Andrei Borzenkov [this message]
2019-07-13 11:28       ` Ulli Horlacher
2019-07-13 15:08         ` Andrei Borzenkov
2019-07-15 13:22         ` Piotr Szymaniak
2019-07-15 22:40           ` Ulli Horlacher
2019-07-15 23:58             ` [RFC] a standard user-friendly way to find a snapshot in nested subvolumes [was: find subvolume directories] Nicholas D Steeves
2019-07-16  0:41               ` Ulli Horlacher
2019-07-15 11:39       ` find subvolume directories Ulli Horlacher
2019-07-15 11:33 ` Ulli Horlacher
2019-07-16 11:04 ` Ulli Horlacher

Reply instructions:

You may reply publically 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=62366a29-a8ea-a889-f857-0305eba99051@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

Linux-BTRFS Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-btrfs/0 linux-btrfs/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-btrfs linux-btrfs/ https://lore.kernel.org/linux-btrfs \
		linux-btrfs@vger.kernel.org linux-btrfs@archiver.kernel.org
	public-inbox-index linux-btrfs


Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-btrfs


AGPL code for this site: git clone https://public-inbox.org/ public-inbox