From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: Implementing guix system rollback / switch-generation Date: Sun, 12 Jun 2016 18:46:55 +0200 Message-ID: <87k2hul5hc.fsf@gnu.org> References: <87wpm3qngd.fsf@gmail.com> <87a8iy68lm.fsf@gnu.org> <877fdyesni.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:59469) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bC8XO-00005X-PX for guix-devel@gnu.org; Sun, 12 Jun 2016 12:47:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bC8XL-0001GJ-Fc for guix-devel@gnu.org; Sun, 12 Jun 2016 12:47:02 -0400 In-Reply-To: <877fdyesni.fsf@gmail.com> (Chris Marusich's message of "Thu, 09 Jun 2016 00:19:13 -0700") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Chris Marusich Cc: guix-devel@gnu.org Hello, Chris Marusich skribis: > ludo@gnu.org (Ludovic Court=C3=A8s) writes: [...] >> It=E2=80=99s not possible to obtain past grub.cfg files, but that=E2=80= =99s not a >> problem: we can always regenerate a new grub.cfg. > > I'm curious: is there a reason why /boot is not itself just another > symlink? It might be nice if instead of overwriting the grub.cfg file, > we could just flip a symlink when rolling back. /boot contains GRUB, and there=E2=80=99s nothing that runs before GRUB that would allow us to choose among several GRUBs. So we assume the latest GRUB always =E2=80=9Cworks=E2=80=9D, and we generat= e a grub.cfg with a menu list all the older generations, which is rather convenient from the UI viewpoint, I think. >> I think having basic delete-generations, switch-generations, and >> roll-back sub-commands would be definitely welcome. >> >> As a first step, switch-generations/roll-back commands could simply >> update the symlinks and regenerate grub.cfg. >> >> Milestone #2 would be running the previous system=E2=80=99s activation s= cript, >> which installs /run/current-system and adjust the set of users and >> groups. >> >> Milestone #3 would be live service downgrade, as you describe. >> >> Thoughts? > > I think breaking it down like that makes a lot of sense. I'll give > milestone #1 a shot: make switch-generations/roll-back commands that > just update the symlinks and regenerate grub.cfg. Awesome. Thanks for starting this discussion! Ludo=E2=80=99.