[prev in list] [next in list] [prev in thread] [next in thread] 

List:       lxc-users
Subject:    Re: [lxc-users] Questions on how to "lxd init" again, reinstall, upgrade and downgrade
From:       Simos Xenitellis <simos.lists () googlemail ! com>
Date:       2017-03-15 23:38:47
Message-ID: CAPtVWc5AzobWyd1YXdTJzDKFwZMtO07wUFYjYy_k1G3M+-36+w () mail ! gmail ! com
[Download RAW message or body]

On Tue, Mar 14, 2017 at 2:11 AM, Simos Xenitellis
<simos.lists@googlemail.com> wrote:
> Hi All,
>
> I am writing a post on LXD and
> 1. how to run "lxd init" again (keeping the ZFS allocated space)
> 2. how to run "lxd init" again (clearing up the ZFS allocated space,
> allocate fresh space)
> 3. how to upgrade to the latest (currently 2.11) version
> 4. how to downgrade
>
> Here is how I plan to tackle these issues:
> 1. how to run "lxd init" again (keeping the ZFS allocated space)
>>> requires to "sudo systemctl stop lxd.service"
>>> requires to "sudo zpool destroy mylxdpool"
>>> then "nmcli connection delete lxdbr0" (to delete the bridge)
> |--> now "lxd init" and select to reuse the ZFS device
>
> 2. how to run "lxd init" again (clearing up the ZFS allocated space,
> allocate fresh space)
>>> requires to "sudo systemctl stop lxd.service"
>>> requires to "sudo zpool destroy mylxdpool"
>>> then "nmcli connection delete lxdbr0"
>>> remove everything in /var/lib/lxd/
>>> remove everything in /var/log/lxd/
> |--> now "lxd init" and select to reuse the ZFS device
>
> 3. how to upgrade to the latest (currently 2.11) version
>>> Enable the lxd-stable PPA (has 2.11)
> |--> then "sudo apt install lxd", which will bring in "lxd-client".
>
> 4. how to downgrade
> (AFAIK, downgrading is not expected to be tested, so it requires to
> remove everything (case [2]),
> downgrade "lxd" and "lxd-client", then "lxd init".
>
>
> If there is any big no-no in the above, I would love to hear about it!
>

I completed the first installment,
https://blog.simos.info/how-to-initialize-lxd-again/

It talks about what to look for when you need to run "lxd init" again.
I strategically added other interesting info so it should be
educational in general.

I do not talk about removing the lxdbr0 bridge as it still works fine
even if it exists.
The upside is that there are no extra "dnsmasq" processes lying
around, which would have to be taken care of.

I am now again "rm -fr /var/log/lxd/" unless there is a good reason
(currently: only when downgrading LXD).

My next endevour is how to upgrade (to lxd-stable: 2.11) or downgrade
(back to 2.0.9 in 16.04).
As far as I understand, upgrading is being tested, so it just works.
For downgrading, it needs to "rm -fr /var/lib/lxd/".

Simos
_______________________________________________
lxc-users mailing list
lxc-users@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-users
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic