From Fedora Project Wiki

(fusecompress on-disk change.)
(Update with fusecompress1 review and updated migration instructions)
Line 2: Line 2:


=== fusecompress ===
=== fusecompress ===
Fusecompress is a compressing filesystem accessible from userspace and
Fusecompress is a compressing filesystem mountable by unprivileged users.  (Note: this may mean we don't want this note
mountable by unprivileged users.  (Note: this may mean we don't want this note
in the system admin section).  Fedora-11 had fusecompress-1.99.19.  Fedora-12
in the system admin section).  Fedora-11 had fusecompress-1.99.19.  Fedora-12
updates to fusecompress-2.6.  This fixes many very nasty bugs but changes
updates to fusecompress-2.6.  This fixes many very nasty bugs but changes
the on-disk format. '''There is no way to upgrade the on-disk format within
the on-disk format.  Users with fusecompress filesystems will need to migrate
F-12 at this time.''' Users with fusecompress filesystems will need to move
their data to the new format. I have a package under review to make this possible:
their data out of the fusecompress filesystem prior to updating, update to F-12,
create a new fusecompress filesystem, and then move their data into the new
filesystem.


I am working on a fusecompress1 package which will only have the
  https://bugzilla.redhat.com/show_bug.cgi?id=525814
fusecompress_offline tool.  This will allow migration of data but not allow
 
mounting the old filesystems in F12.  Migration will look like this:
If a user doesn't read these release notes and realize they need to upgrade the format, the first indication they'll have that something is wrong will probably be when they try to read a text file and it is binary:


<pre>
<pre>
$ # Old fusecompress filesystem had data in ~/.storage and was mounted on
$ less test.txt
$ # ~/storage
"test.dump" may be a binary file. See it anyway?
$ # New fusecompress filesystem will have data in ~/.fusecompressstorage and
$ # still mount on ~/storage
$ cd ~/
$ mkdir ~/.fusecompressstorage
$ fusecompress ~/.fusecompressstorage ~/storage
$ find ~/.storage -type f -exec fusecompress_offline1 \{\} \;
$ mv ~/.storage/* ~/storage
</pre>
</pre>


I will update this note with the review ticket and status so we know if we can publish this migration strategy or not.
I don't know how we can work around that though.
 
The basic method of updating their system is documented in a /usr/share/doc/fusecompress1-%{version}/README.fedora file in the fusecompress1 package.  The fusecompress package has a README.fedora that tells the user to install fusecompress1 and read that file.  I'm copying the
upgrade instructions below.  I don't know if you'll want it in the release notes or just a pointer to the in-package document.
 
<pre>
Let's say that in Fedora 11 your old fusecompress rootDir (where the files are
actually stored) is in ~/.fusestorage and you mount it on ~/storage. Now you've
updated to Fedora 12 and need to get your fusecompress filesystems updated to
the new on-disk format.  Here's the basic steps::
 
    # Make sure the old fusecompress filesystem is unmounted
    fusermount -u ~/storage
    # Move it to a new location
    mv ~/.fusestorage ~/.fusestorage.old
    # Create a new directory for our new format data
    mkdir ~/.fusestorage
    # Mount the new directory.  It's now a new format fusecompress filesystem
    fusecompress ~/.fusestorage ~/storage
    # Decompress all the files in the old fusecompress data directory
    fusecompress_offline1 ~/.fusestorage.old
    # Move the files into the new format storage
    mv .fusestorage.old/* ~/storage
    # If you have any hidden files, remember to move them too
    mv .fusestorage.old/.?* ~/storage
 
Note that to use this exact procedure you need to have enough disk space to
uncompress all of the files stored in ~/.fusestorage.old.  If you don't have
that much space, you'll have to run fusecompress_offline1 on portions of
~/.fusestorage.old and move them to ~/storage where they'll be recompressed,
freeing up the space for you to run fusecompress_offline1 on more files.
</pre>

Revision as of 21:07, 25 September 2009

File Systems

fusecompress

Fusecompress is a compressing filesystem mountable by unprivileged users. (Note: this may mean we don't want this note in the system admin section). Fedora-11 had fusecompress-1.99.19. Fedora-12 updates to fusecompress-2.6. This fixes many very nasty bugs but changes the on-disk format. Users with fusecompress filesystems will need to migrate their data to the new format. I have a package under review to make this possible:

 https://bugzilla.redhat.com/show_bug.cgi?id=525814

If a user doesn't read these release notes and realize they need to upgrade the format, the first indication they'll have that something is wrong will probably be when they try to read a text file and it is binary:

$ less test.txt
 "test.dump" may be a binary file.  See it anyway?

I don't know how we can work around that though.

The basic method of updating their system is documented in a /usr/share/doc/fusecompress1-%{version}/README.fedora file in the fusecompress1 package. The fusecompress package has a README.fedora that tells the user to install fusecompress1 and read that file. I'm copying the upgrade instructions below. I don't know if you'll want it in the release notes or just a pointer to the in-package document.

Let's say that in Fedora 11 your old fusecompress rootDir (where the files are
actually stored) is in ~/.fusestorage and you mount it on ~/storage. Now you've
updated to Fedora 12 and need to get your fusecompress filesystems updated to
the new on-disk format.  Here's the basic steps::

    # Make sure the old fusecompress filesystem is unmounted
    fusermount -u ~/storage
    # Move it to a new location
    mv ~/.fusestorage ~/.fusestorage.old
    # Create a new directory for our new format data
    mkdir ~/.fusestorage
    # Mount the new directory.  It's now a new format fusecompress filesystem
    fusecompress ~/.fusestorage ~/storage
    # Decompress all the files in the old fusecompress data directory
    fusecompress_offline1 ~/.fusestorage.old
    # Move the files into the new format storage
    mv .fusestorage.old/* ~/storage
    # If you have any hidden files, remember to move them too
    mv .fusestorage.old/.?* ~/storage

Note that to use this exact procedure you need to have enough disk space to
uncompress all of the files stored in ~/.fusestorage.old.  If you don't have
that much space, you'll have to run fusecompress_offline1 on portions of
~/.fusestorage.old and move them to ~/storage where they'll be recompressed,
freeing up the space for you to run fusecompress_offline1 on more files.