Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Snapper support #28

Closed
wants to merge 3 commits into from
Closed

Snapper support #28

wants to merge 3 commits into from

Conversation

daftaupe
Copy link
Contributor

Hello, I did a little hack in order to make grub-btrfs not reference the Snapper pre/post snapshots (as asked in issue #23) with the addition of 2 variables that one can use in /etc/default/grub.

I don't have the time to, so I didn't do any extensive testing though.

@Antynea
Copy link
Owner

Antynea commented Nov 24, 2016

Hello,

Great job,
I do not use snapper
If someone can confirm that it works

@daftaupe
Copy link
Contributor Author

Let's wait for comments, but actually I don't think it's so important, pre/post snapshot could be included in the grub menu.
If I follow what's written in #2, I notice that you're making rw snapshots manually (or not explicitly saying that you set them in ro mode), the thing is, if you boot on them you're actually modifying them isn't it ?

@Antynea
Copy link
Owner

Antynea commented Nov 25, 2016

If I follow what's written in #2, I notice that you're making rw snapshots manually (or not explicitly saying that you set them in ro mode), the thing is, if you boot on them you're actually modifying them isn't it ?

exactly,
I create rw snapshot before an update.
If the update breaks the system, I go back on the previously created snapshot, set it by default, and finally delete the old one.
If the / boot isn't separated, don't forget to reinstall grub in the snapshot, otherwise a small suprise will be present at the next reboot :)

@daftaupe
Copy link
Contributor Author

You should close this PR. It's not a good feature after all.
What do you mean with grub ? I have a non-separated /boot but I didn't notice anything. Are you talking about a UEFI system ?

@Antynea
Copy link
Owner

Antynea commented Nov 26, 2016

During my tests, 3 years ago,
with a non-separated /boot, Grub didn't find his cubs.
I was forced to relaunch grub-install

Not having had the opportunity to reiterate the thing at the moment (arch never broke),
It may just be my tests that went wrong.

I tested with this Btrfstree:

@root
@snaps

Where @root contains the entire system as well as /boot
Where @snaps contains snapshots rw and mounted in /snaps

If I started in /snaps/test1, then set as default and delete @root
Generates grub.cfg
To the next reboot /snaps/test1 was started by default, but grub could not find these own files.

This is certainly no longer true, today.

@daftaupe
Copy link
Contributor Author

Thanks for the info, yes it works now (at least in my case). But 3 years is a lot compared to btrfs lifespan, you should rerun some tests in a vm maybe :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants