Can you setup btrfs on an existing installation?

Hey quick question here,

Looking into seting up my system with btrsf for backups. Assuming I have an existing installation, is there a way for me to set it up, fairly basic setup with just one volume (@) and one @home subvolume?

Or does it necessarily entails re-installation manjaro? Seems most of the guides I’m finding all work off a brand new install.

I’m currently following this guy.

I think btrfs is pretty interesting, I see the value, but it is not an obvious setup I’ll admit. I’d interested in making a writeup for dummies I can manage to make it work (as I am pretty much a dummy as a sysadmin).

Thanks!

In theory, it would be possible to convert an ext4 volume into btrfs, but it would have to be done while the volume is not in use — i.e. from a live USB/CD session — and it is very dangerous. That’s why it is recommended to rather reinstall and start with a clean slate.

Also note that btrfs snapshots are not backups. They are stored within the same btrfs volume, and they use copy-on-write. If you want to make backups — and you should! — then you need a second drive, formatted with a Linux-native filesystem, and then use timershift in rsync mode.

3 Likes

@Aragorn thanks for the reply.

Yes I understand that if I want backups I’ll have to do additional setups after. That’s fine.

But yes I see that changing the filesystem might be problematic. This does answer the question - I’m not sure I want to go down that rabbit hole, so might as well do this with a fresh install if I’m going to do it.

I might very well, and perhaps do a writeup on it after if I get around to make it work decently. Thanks!

2 Likes

This is true,

but i did this already 4 times :wink: and succeeded every time

It is possible to convert from ext4 and from reiserfs. And it is possible to get a clean state afterwards (This is described in detail in the btrfs-Wiki at kernel.org)

https://btrfs.readthedocs.io/en/latest/Convert.html

The disk should not be to full if you want to succeed, because btrfs needs some space to breath. Optimal is less than 50% full. Maximum may be 75%. In this process i would suggest to use a second drive(!), and switch to RAID1 with btrfs directly after converting.

You can reach a clean state after

  • deleting the ext4_saved snapshot and then
  • after a balance :smiling_face_with_three_hearts:

(search for RAID1)

But i would also suggest to have a backup from your valuable data beforehand :wink: (better safe than sorry)

This is written in german, but i may write the same in english soon

And later you can make good backups with btrfs send/receive
:footprints:

2 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.