:: Re: [DNG] another upgrade ascii to …
Kezdőlap
Delete this message
Reply to this message
Szerző: Florian Zieboll
Dátum:  
Címzett: dng
Tárgy: Re: [DNG] another upgrade ascii to beowulf borked
On Tue, 3 Aug 2021 06:44:56 -0400
Hendrik Boom <hendrik@???> wrote:

> I was following the instructions on
> https://www.devuan.org/os/documentation/dev1fanboy/en/upgrade-to-beowulf
> and got to the point of doing apt-get dist-upgrade.
>
> Partway through, it decided, a usual, that it had to stop and restart 
> several services:
>     postgresql lprng exim4 cron atd_______________________________
> (the entry box had a lot of underscores in it; I suspect just filler?)

>
> I OK'd it.
>
> Next thing on the screen was:
>
> Restarting services possibly affected by the upgrade"
> postgresql: restarting...FAILED! (1)
> lprng: restarting...done.
> exim: restarting...done.
> cron: restarting...done.
> atd...done.
>
> and then it froze for five hours.
>
> After waiting five hours, I tried aborting the upgrade (it had
> evidently failed by this point), first with control-C which did not
> work, then with killall apt-get from a separate xterm.
> Yes, this killed the upgrade.
>
> I tried again with apt-get dist-upgrade
> This time it just told me
>     E: Could not get lock /var/lib/dpkg/lock - (11: resource
> temporarily unavailable) E: Unable to lock the administration
> directory (/var/lib/dpkg), os another process using it?

>
> I'm not sure how to proceed from here.
> Is it safe to somehow break the lock? If so, how?
> Does something have to be done to restore the adnimistration
> directory to a safe state?
> Is it OK to reboot (this would be in the middle of an upgrade, and
> the system might not be consistent enough to run successfully)
>
> In case all else fails and I have to reinstall from scratch, I'd
> prefer to install chimaera directly instead of going the ascii ->
> beowulf -> chimaera route. Are there (draft) intructions for that?



As the lock is there to prevent other processes to interact with the
package database during the running update (which you have already
killed!), I see no reason to not just 'rm /var/lib/dpkg/lock' and then
try to fix the failed installation with the appropriate command ('dpkg
--configure -a' or 'dpkg --configure --pending') and then repeat the
upgrade procedure. At least this is what I used to do in such a case,
and I can't remember to have ever messed up anything this way.

Disclaimer: It's a while ago that I had been in this situation but IIRC,
this is how I solved such issues.

libre Grüße,
Florian