You are not logged in.

#1 2019-02-18 22:45:36

mig4ng
Member
Registered: 2017-01-04
Posts: 10

[SOLVED] Pacman not working after force updating libidn2

Hello,

I updated libidn2 because a package I was using was not being able to load it.
I was in slow internet connection so I did not want to upgrade the whole system and brainlessly forced update of just libidn2 and it broke a lot of packages in my system, including pacman.

I still did not reboot the machine and it is working but I am certain that if I reboot it there is a 99% chance it will not load without a live usb flash drive.

Any ideas on how to fix this without the live usb? All ideas are highly appreciated! :-)

Last edited by mig4ng (2019-02-21 00:49:07)

Offline

#2 2019-02-19 06:33:11

eschwartz
Fellow
Registered: 2014-08-08
Posts: 4,097

Re: [SOLVED] Pacman not working after force updating libidn2

mig4ng wrote:

Hello,

I updated libidn2 because a package I was using was not being able to load it.
I was in slow internet connection so I did not want to upgrade the whole system and brainlessly forced update of just libidn2 and it broke a lot of packages in my system, including pacman.

I still did not reboot the machine and it is working but I am certain that if I reboot it there is a 99% chance it will not load without a live usb flash drive.

Any ideas on how to fix this without the live usb? All ideas are highly appreciated! :-)

DO NOT REBOOT. One of the things which depends on libidn2 is systemd, so you're entirely correct to be cautious about that.

The easiest way to fix the problem is to use my statically linked pacman binary in order to reinstall the old version of libidn2 -- or to update your entire system. https://aur.archlinux.org/packages/pacman-static

As per the pinned message there, you can download either the pacman-static *package* from my custom repo (or not, because pacman is already broken) or you can download the executable itself -- both are signed by my Trusted User signing key, so you can verify they are trustworthy.


Managing AUR repos The Right Way -- aurpublish (now a standalone tool)

Offline

#3 2019-02-19 10:33:26

mig4ng
Member
Registered: 2017-01-04
Posts: 10

Re: [SOLVED] Pacman not working after force updating libidn2

Unfortunately as I went to sleep I forgot to power the laptop and it turn off and now it does not turn on.
Thank you @eschwartz your suggestion was indeed a good idea to try when I had the computer on but now it is impossible I think.

I tried to boot from the live usb, mount the correct /dev/nvme0n1p1 to /mnt and then tried to

pacstrap /mnt base

in hopes I'd fix pacman and then update the whole system but it did not work.
Any other ideas on how to fix this issue? Highly appreciated!

Offline

#4 2019-02-19 12:26:44

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,523
Website

Re: [SOLVED] Pacman not working after force updating libidn2

mig4ng wrote:

but it did not work.

https://bbs.archlinux.org/viewtopic.php?id=57855

Of course, pacstrap is the wrong tool as it is meant only to be used on new systems.  However, it still should have succeeded in solving the present problem.  In any case, the correct solution would be to use pacman with the -r flag pointing to your mounted system, and either A) downgrade to the libidn2 package that matches the rest of your system (probably in your package cache) or B) do a full system upgrade, not just the "base" group.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#5 2019-02-19 13:09:56

mig4ng
Member
Registered: 2017-01-04
Posts: 10

Re: [SOLVED] Pacman not working after force updating libidn2

Trilby wrote:
mig4ng wrote:

but it did not work.

https://bbs.archlinux.org/viewtopic.php?id=57855

Of course, pacstrap is the wrong tool as it is meant only to be used on new systems.  However, it still should have succeeded in solving the present problem.  In any case, the correct solution would be to use pacman with the -r flag pointing to your mounted system, and either A) downgrade to the libidn2 package that matches the rest of your system (probably in your package cache) or B) do a full system upgrade, not just the "base" group.

Yeah I think I completely rewrite my system using pacstrap, luckily I have backup of everything important I had so I will reinstall Arch since this installation was done in 2017 and I didn't understand a lot of linux back then, I still don't but I feel more comfortable with it now.
For anyone with the same problem as the one I described:
- Revert immediately the libidn2 or other package causing this error, and then upgrade the whole system.
- If you shutdown the system use a usb thumb drive and start arch live to fix pacman.
- Always follow the documentation available on the wiki, I tried to quick fix my system by myself and I dug myself into a bigger hole lol

Offline

#6 2019-02-19 13:35:36

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,523
Website

Re: [SOLVED] Pacman not working after force updating libidn2

*headdesk*

mig4ng wrote:

Yeah I think I completely rewrite my system using pacstrap

No.  No you didn't.  That's not possible.  If the pacstrap command ran to completion, you overwrote all the files in the base group ... with themselves.  So that is completely harmless and would actually *solve* your original problem.  It would also reset your pacman keyring, I suspect, and may do some other initialization which is pointless, but in the grand scheme of things mostly harmless.  It would most definitely not "rewrite your system".

mig4ng wrote:

luckily I have backup of everything important I had so I will reinstall Arch...

You don't need a backup - all your data is untouched on the same drive it has been.  And there is absolutely no need to reinstall - and even if you do reinstall, you can preseve all your data simply by leaving your home partition alone.  But still, don't reinstall.

Just fix the problem.  We can help with that if you stop doing more and more crazy things in an attempts at nuclear solutions - and more importantly, if you actually provide information on what you have done and how pacstrap "didn't work".  If you can't help but spiral a very minor problem like what triggered this thread into such a state that you need to reinstall the OS, then don't reinstall arch, it will not end well.  If you want to use arch, stop, think, and learn.

Last edited by Trilby (2019-02-19 13:37:10)


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#7 2019-02-21 00:47:50

mig4ng
Member
Registered: 2017-01-04
Posts: 10

Re: [SOLVED] Pacman not working after force updating libidn2

Trilby wrote:

*headdesk*

mig4ng wrote:

Yeah I think I completely rewrite my system using pacstrap

No.  No you didn't.  That's not possible.  If the pacstrap command ran to completion, you overwrote all the files in the base group ... with themselves.  So that is completely harmless and would actually *solve* your original problem.  It would also reset your pacman keyring, I suspect, and may do some other initialization which is pointless, but in the grand scheme of things mostly harmless.  It would most definitely not "rewrite your system".

mig4ng wrote:

luckily I have backup of everything important I had so I will reinstall Arch...

You don't need a backup - all your data is untouched on the same drive it has been.  And there is absolutely no need to reinstall - and even if you do reinstall, you can preseve all your data simply by leaving your home partition alone.  But still, don't reinstall.

Just fix the problem.  We can help with that if you stop doing more and more crazy things in an attempts at nuclear solutions - and more importantly, if you actually provide information on what you have done and how pacstrap "didn't work".  If you can't help but spiral a very minor problem like what triggered this thread into such a state that you need to reinstall the OS, then don't reinstall arch, it will not end well.  If you want to use arch, stop, think, and learn.

You are absolutely right, and I did not rewrite my system, I was mounting the wrong partition therefore I was unable to see my files.
I managed to fix my system, and I recommend everyone to install pacman-static as a backup or have the live usb available with you when you decide to make dumb moves like me tongue

Thank you all for all the help smile

Offline

#8 2019-02-21 00:49:44

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,523
Website

Re: [SOLVED] Pacman not working after force updating libidn2

I'm glad that worked out.  Sorry if I sounded harsh - it just frustrates me when someone looks like they're going to throw their hands up and start over rather than take advantage of a good chance to learn a bit more about their system.  I'm glad you opted for the latter in the end.

So is this all sorted then?  If so, please edit your first post to mark the thread as SOLVED.

Last edited by Trilby (2019-02-21 00:50:00)


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#9 2019-02-21 00:56:59

mig4ng
Member
Registered: 2017-01-04
Posts: 10

Re: [SOLVED] Pacman not working after force updating libidn2

Trilby wrote:

I'm glad that worked out.  Sorry if I sounded harsh - it just frustrates me when someone looks like they're going to throw their hands up and start over rather than take advantage of a good chance to learn a bit more about their system.  I'm glad you opted for the latter in the end.

So is this all sorted then?  If so, please edit your first post to mark the thread as SOLVED.

Yeah, basically I updated everything with the -r flag of pacman, it took a long time to update because it was capped at 70kbps +-, I still haven't figured out this slow connection problem, tried on multiple networks, tried to follow the wiki solution for related problems and nothing solved it.
I managed to find a usb-c to RJ45 (ethernet) adapter and updated this way instead, but now I want to understand why the connection was slow and learn how to fix it lol

Offline

#10 2019-02-21 02:50:18

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,523
Website

Re: [SOLVED] Pacman not working after force updating libidn2

Feel free to collect some information about that issue and start a new thread and we may be able to help out.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

Board footer

Powered by FluxBB