Announcement

Collapse
No announcement yet.

Firefox cache moved outside subvolumes to avoid it's being snapshotted and backed up

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Firefox cache moved outside subvolumes to avoid it's being snapshotted and backed up

    Checking my home directory I saw that it was about 7 GB, but more than 1 GB was in the firefox cache. That 1 GB changes all the time, so is taking up lots of space in snapshots and backups, uselessly.

    So, I researched and set browser.cache.disk.parent_directory in about.config to a location in the same speedy btrfs but not in any subvolume, via the mount of the btrfs top level.

    Is this a good idea? What can go wrong?
    Regards, John Little

    #2
    When I log into root and mount the disk my @ and @home are on to /mnt, then "vdir /mnt" will show:
    /mnt
    @
    @home
    /snapshots

    I created snapshots using "mkdir /mnt/snapshots" after I first installed BTRFS. Snapshots is not in either @ or @home AND it is invisible to the system when you are running it. So, you can't direct files to it from within the running system.

    How to do it? You could create a subvolume /mnt/@ffcache and also create a mounting point in your home directory: "mkdir /home/youracct/ffcache" and then in /etc/fstab put a stanza that mounts @ffcache to /home/youracct/ffcache. Point your ffcache to it. I haven't tried creating a hidden directory and binding it to a subvolume.

    When you take a snapshot of @home it will NOT include @ffcache, just the same way a snapshot of @ shows that /home is empty. You always take a snapshot of @home separately from @.

    However, all that written, there may be an easier way in certain circumstances:
    https://support.mozilla.org/en-US/kb...-firefox-cache

    Click image for larger version

Name:	ff_cache_setting.jpg
Views:	1
Size:	49.6 KB
ID:	644657
    "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
    – John F. Kennedy, February 26, 1962.

    Comment


      #3
      Alternately, create a subvolume for the cache, mount it at the cache location, and don't back it up. Cleaner IMO

      EDIT: I guess that's exactly what Jerry proposed. He just used a lot more detail, LOL

      Please Read Me

      Comment

      Working...
      X