You are not logged in.

#1 2015-09-18 09:00:53

ederc
Member
Registered: 2015-05-07
Posts: 5

[SOLVED] ncurses and bash updated, ncurses downgraded => system broken

Dear all,

today I updated my system via pacman. Afterwards mutt was no longer working due to the update of ncurses to version 6.0.3. Afterwards I downgraded ncurses to 5.9.4 via pacman using the cached old package. BUT I forgot to downgrade bash, too. Now I am no longer able to login to my system, I cannot get any terminal or bash since /bin/sh gives an error not finding libncursesw.so.6.
I also booted my machines with an Arch Linux USB stick and tried to mount the system, but also this is not working due to the same /bin/sh error
.
When trying to get a terminal during boot I get the following messages:

Stopped Getty on tty1
Started Getty on tty1
Stopping User Manager for UID 1000
Stopped User Manager for UID 1000
Removed slice user-1000.slice

I would appreciate any idea or helpful hint.

Last edited by ederc (2015-09-18 10:05:00)

Offline

#2 2015-09-18 09:15:47

headkase
Member
Registered: 2011-12-06
Posts: 1,976

Re: [SOLVED] ncurses and bash updated, ncurses downgraded => system broken

This post has a potential solution in it:

https://www.reddit.com/r/archlinux/comm … em_update/

Foutrelis wrote:

Downgrading ncurses renders bash unusable (along with everything else that links to libncursesw.so.6). Packages in the repos were rebuilt to use the new ncurses ABI, so any errors you get regarding libncursesw.so.5 originate from AUR packages (or other third-party repos) that you need to rebuild yourself.

At this point you must boot using the installation media, mount your partitions under e.g. /mnt and then use the live environment's pacman (without chroot'ing) to upgrade ncurses.

Probably something like the following (untested):

pacman -r /mnt -Su

Offline

#3 2015-09-18 09:17:23

foutrelis
Developer
From: Athens, Greece
Registered: 2008-07-28
Posts: 705
Website

Re: [SOLVED] ncurses and bash updated, ncurses downgraded => system broken

See my reply here.

We also just pushed bash 4.3.042-3 and readline 6.3.008-3 which specifically require libncursesw.so.6 in order to prevent this from happening to other users

Offline

#4 2015-09-18 09:17:45

ayekat
Member
Registered: 2011-01-17
Posts: 1,589

Re: [SOLVED] ncurses and bash updated, ncurses downgraded => system broken

ederc wrote:

I also booted my machines with an Arch Linux USB stick and tried to mount the system, but also this is not working due to the same /bin/sh error

What command did you type to get the error upon mounting?

Have you got another shell installed on your system? If so, you could try to change the /bin/sh symlink to /bin/dash or /usr/bin/zsh or something, then change user's default shell in /etc/passwd. But that's quite a hack.

From the live system, assuming you've mounted the "broken" system at /mnt, I would probably go for something like

pacman --root /mnt --cachedir /mnt/var/cache/pacman/pkg --config /mnt/etc/pacman.conf -Syu

But I'd need a moderator confirming this is a good idea. EDIT There it is.

Last edited by ayekat (2015-09-18 09:18:26)


pkgshackscfgblag

Offline

#5 2015-09-18 10:04:21

ederc
Member
Registered: 2015-05-07
Posts: 5

Re: [SOLVED] ncurses and bash updated, ncurses downgraded => system broken

headkase wrote:

This post has a potential solution in it:

https://www.reddit.com/r/archlinux/comm … em_update/

Foutrelis wrote:

Downgrading ncurses renders bash unusable (along with everything else that links to libncursesw.so.6). Packages in the repos were rebuilt to use the new ncurses ABI, so any errors you get regarding libncursesw.so.5 originate from AUR packages (or other third-party repos) that you need to rebuild yourself.

At this point you must boot using the installation media, mount your partitions under e.g. /mnt and then use the live environment's pacman (without chroot'ing) to upgrade ncurses.

Probably something like the following (untested):

pacman -r /mnt -Su

Thank you very much! The answer given in the link solved my problem:

1. I booted via an Arch Linux USB stick.
2. I mounted my partitions.
3. I used the command

pacman -r /mnt -Su

4. I unmounted the partitions and rebooted.

Now I can access my system again.

Offline

#6 2015-09-18 15:02:19

Deuchnord
Member
Registered: 2015-04-04
Posts: 11

Re: [SOLVED] ncurses and bash updated, ncurses downgraded => system broken

Hi,

I had the same problem and this solution worked like a charm here too, thanks smile

Offline

#7 2015-09-21 16:04:12

koshak
Member
Registered: 2013-03-13
Posts: 35

Re: [SOLVED] ncurses and bash updated, ncurses downgraded => system broken

sudo ln -s /usr/lib/libncursesw.so{,.5}

worked for me.

Offline

#8 2015-09-21 16:52:57

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: [SOLVED] ncurses and bash updated, ncurses downgraded => system broken

koshak wrote:
sudo ln -s /usr/lib/libncursesw.so{,.5}

worked for me.

This is only something you would do if you really want to screw your install...


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#9 2015-11-08 14:27:41

br_84
Member
Registered: 2015-11-08
Posts: 1

Re: [SOLVED] ncurses and bash updated, ncurses downgraded => system broken

jasonwryan wrote:
koshak wrote:
sudo ln -s /usr/lib/libncursesw.so{,.5}

worked for me.

This is only something you would do if you really want to screw your install...

I used koshak's snippet just to get pacman going and updated bash and readline. Then i removed /usr/lib/libncursesw.so.5 and updated the system. Works perfectly, no permanent screw-up smile

Offline

Board footer

Powered by FluxBB