All of lore.kernel.org
 help / color / mirror / Atom feed
* Suggestion for sticky-compression mount setting (default mount options)
@ 2011-02-05  2:44 Kirk Wolff
  2011-02-05 12:18 ` Felix Blanke
  2011-02-05 13:19 ` Olaf van der Spek
  0 siblings, 2 replies; 4+ messages in thread
From: Kirk Wolff @ 2011-02-05  2:44 UTC (permalink / raw)
  To: linux-btrfs

[-- Attachment #1: Type: text/plain, Size: 1756 bytes --]

As I've been using btrfs with an external USB drive, I wonder how to
handle efficiently the compression setting.  When I plug a drive in to
ubuntu, it is automatically mounted.  Its mounted without the
compression option as its not in fstab.  I don't see it as desirable to
install each usb drive in fstab on each computer that it may be used
just so that compression is automatically enabled.  In discussion with
cjb on irc, I came to realize that the compression setting shouldn't be
filesystem-wide therefore it doesn't make sense to have default mount
options for an entire btrfs filesystem as you may want compression on
one subvolume and not on another.  Therefore, it seems to me that
default mount options should be able to be configured for each
subvolume.  If you follow this idea through, this means that you would
need to be able to both override each of the default mount options from
the mount command (or fstab).  For example, if a subvolume has its
default mount option set to compress, you should be able to disable
compression if you manually mount it with "-o nocompress".  If mount
default mount options were able to be configured through btrfs for each
subvolume, then for the case when you have a simple USB drive that
you're using for backups, the default subvolume could have compress
automatically set when its plugged into a PC.  Then you can use
snapshots alongside the default subvolume to perform a type of
differential backups (similar to rsnapshot, but using COW instead of
hard links).  I can guess there are people out there that may want other
mount options to be carried around with the subvolume such as disabling
COW or whatever.  What are your thoughts on the above?  Please advise.

- Kirk

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Suggestion for sticky-compression mount setting (default mount options)
  2011-02-05  2:44 Suggestion for sticky-compression mount setting (default mount options) Kirk Wolff
@ 2011-02-05 12:18 ` Felix Blanke
  2011-02-05 15:31   ` cwillu
  2011-02-05 13:19 ` Olaf van der Spek
  1 sibling, 1 reply; 4+ messages in thread
From: Felix Blanke @ 2011-02-05 12:18 UTC (permalink / raw)
  To: Kirk Wolff; +Cc: linux-btrfs

Hi,

I don't think that the fs is a good place to store default mountoptions.

If you want to auto mount usb devices with compression, just write a
udev rule or whatever ubuntu uses to mount usb devices.


Regards,
Felix

Am Fri, 04 Feb 2011 20:44:03 -0600
schrieb Kirk Wolff <kirk@wolffelectronicdesign.com>:

> As I've been using btrfs with an external USB drive, I wonder how to
> handle efficiently the compression setting.  When I plug a drive in to
> ubuntu, it is automatically mounted.  Its mounted without the
> compression option as its not in fstab.  I don't see it as desirable
> to install each usb drive in fstab on each computer that it may be
> used just so that compression is automatically enabled.  In
> discussion with cjb on irc, I came to realize that the compression
> setting shouldn't be filesystem-wide therefore it doesn't make sense
> to have default mount options for an entire btrfs filesystem as you
> may want compression on one subvolume and not on another.  Therefore,
> it seems to me that default mount options should be able to be
> configured for each subvolume.  If you follow this idea through, this
> means that you would need to be able to both override each of the
> default mount options from the mount command (or fstab).  For
> example, if a subvolume has its default mount option set to compress,
> you should be able to disable compression if you manually mount it
> with "-o nocompress".  If mount default mount options were able to be
> configured through btrfs for each subvolume, then for the case when
> you have a simple USB drive that you're using for backups, the
> default subvolume could have compress automatically set when its
> plugged into a PC.  Then you can use snapshots alongside the default
> subvolume to perform a type of differential backups (similar to
> rsnapshot, but using COW instead of hard links).  I can guess there
> are people out there that may want other mount options to be carried
> around with the subvolume such as disabling COW or whatever.  What
> are your thoughts on the above?  Please advise.
> 
> - Kirk
> 


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Suggestion for sticky-compression mount setting (default mount options)
  2011-02-05  2:44 Suggestion for sticky-compression mount setting (default mount options) Kirk Wolff
  2011-02-05 12:18 ` Felix Blanke
@ 2011-02-05 13:19 ` Olaf van der Spek
  1 sibling, 0 replies; 4+ messages in thread
From: Olaf van der Spek @ 2011-02-05 13:19 UTC (permalink / raw)
  To: Kirk Wolff; +Cc: linux-btrfs

On Sat, Feb 5, 2011 at 3:44 AM, Kirk Wolff
<kirk@wolffelectronicdesign.com> wrote:
> one subvolume and not on another. =C2=A0Therefore, it seems to me tha=
t
> default mount options should be able to be configured for each
> subvolume. =C2=A0If you follow this idea through, this means that you=
 would

Is compression a per-file option or a per-subvolume option? Seems a
bit inflexible if it's per-subvolume.


--=20
Olaf
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" =
in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Suggestion for sticky-compression mount setting (default mount options)
  2011-02-05 12:18 ` Felix Blanke
@ 2011-02-05 15:31   ` cwillu
  0 siblings, 0 replies; 4+ messages in thread
From: cwillu @ 2011-02-05 15:31 UTC (permalink / raw)
  To: Felix Blanke; +Cc: Kirk Wolff, linux-btrfs

On Sat, Feb 5, 2011 at 6:18 AM, Felix Blanke <felixblanke@gmail.com> wrote:
> Hi,
>
> I don't think that the fs is a good place to store default mountoptions.
>
> If you want to auto mount usb devices with compression, just write a
> udev rule or whatever ubuntu uses to mount usb devices.

I believe the point was to avoid configuring each system he might use
it with; otherwise a simple fstab entry would have sufficed.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-02-05 15:31 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-05  2:44 Suggestion for sticky-compression mount setting (default mount options) Kirk Wolff
2011-02-05 12:18 ` Felix Blanke
2011-02-05 15:31   ` cwillu
2011-02-05 13:19 ` Olaf van der Spek

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.