btrfs: Option to create read-only snapshot does not exist

Bug #924621 reported by Stefan Lasiewski
30
This bug affects 6 people
Affects Status Importance Assigned to Milestone
btrfs-tools (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

According to the Btrfs wiki [1], Btrfs supports read-only snapshots.

    NEWS
    Linux 2.6.38 released (March 2011) LZO compression. Forced read-only mode for handling filesystem errors. Read-only snapshots.

Read-only snapshots should be created with the command `btrfs subvolume snapshot -r volume nameofsnapshot [2] [3].

However, the option to support this does not exist on Ubuntu 11.10:

    $ btrfs subvolume snapshot -r /u1 /u1/.snapshot/test
    ERROR: 'subvolume snapshot' requires 2 arg(s)

[1] https://btrfs.wiki.kernel.org/#News
[2] http://article.gmane.org/gmane.comp.file-systems.btrfs/14173/match=read+only+snapshot
[3] http://blog.dailystuff.nl/2012/01/btrfs-and-readonly-snapshots/

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in btrfs (Ubuntu):
status: New → Confirmed
Revision history for this message
Jeff Strunk (jstrunk-math) wrote :

I think this bug was reported on the wrong package.

affects: btrfs (Ubuntu) → btrfs-tools (Ubuntu)
Revision history for this message
Jeff Strunk (jstrunk-math) wrote :

https://launchpad.net/~yofel/+archive/btrfs has an up to date package for btrfs-tools with this functionality. The package in Precise appears to be a snapshot from June 2010.

# dpkg -i btrfs-tools_0.19+20120421-0daily6~bzr457~precise1_amd64.deb
(Reading database ... 108869 files and directories currently installed.)
Preparing to replace btrfs-tools 0.19+20100601-3ubuntu3 (using btrfs-tools_0.19+20120421-0daily6~bzr457~precise1_amd64.deb) ...
Unpacking replacement btrfs-tools ...
Setting up btrfs-tools (0.19+20120421-0daily6~bzr457~precise1) ...
Processing triggers for man-db ...
# btrfs subvolume snapshot -r /export/ftp /export/ftp/.snapshot/hardy
Create a readonly snapshot of '/export/ftp' in '/export/ftp/.snapshot/hardy'

Revision history for this message
Stefan Lasiewski (stefanlasiewski) wrote :

Just confirming that this also happens in Precise. I recently upgraded to Precise, and I get this same error.

$ cat /etc/issue
Ubuntu 12.04 LTS \n \l

$ btrfs subvolume snapshot -r /u1 /u1/.snapshot/test
ERROR: 'subvolume snapshot' requires 2 arg(s)

Gary M (garym)
tags: added: oneiric precise
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.