You are not logged in.

#1 2020-02-21 23:36:44

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

[Solved] Chroot fail during system recovery or pacstrap error?

I am trying to recover my system after a disastrous uninstall from AdaCore. It scrubbed my /usr tree.

I am going by the web Installation Guide, and booting from the 2020-0201 Live Cd. Since the system was working, I have a usb stick to help me. I am skipping some steps.
1) skip loadkeys
2) mount usbstick as /mnt/sdb1; network out and timedate just fine
3) skip fdisk , format, and swap
4) mount the problem disk as /mnt/sda1
5) try to pacstrap /mnt/sda1 with about 44 argument packages; 10 terminate with “call to execv / command failed to execute correctly” errors but base & Linux & Linux firmware are installed without error.
6) try to “sh -x arch-chroot /mnt/sda1” to trace execution, but unshare line fails with “chroot: failed to run command +/bin/bash+: no such file” yet target /mnt/sda1/bin/bash is found by ls.

I do not know if step 5 error is a preview of 6 malfunction. In any case, please help?

Last edited by OrigBitmancer (2020-03-03 08:26:13)

Offline

#2 2020-02-21 23:46:21

loqs
Member
Registered: 2014-03-06
Posts: 18,691

Re: [Solved] Chroot fail during system recovery or pacstrap error?

Pacman#Pacman_crashes_during_an_upgrade
At step 6 from the link try:

pacman --sysroot /mnt -S `pacman --sysroot /mnt -Qoq /usr`

Last edited by loqs (2020-02-21 23:46:51)

Offline

#3 2020-02-22 00:21:16

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

loqs wrote:

Pacman#Pacman_crashes_during_an_upgrade
At step 6 from the link try:

pacman --sysroot /mnt -S `pacman --sysroot /mnt -Qoq /usr`

Thank you again!
I presume to substitute mount point /mnt/sda1 for /mnt .... but I will try each.

Offline

#4 2020-02-22 00:29:49

loqs
Member
Registered: 2014-03-06
Posts: 18,691

Re: [Solved] Chroot fail during system recovery or pacstrap error?

If the root filesysystem of the installation is /dev/sda1 then in step 2 of the link you would use

mount /dev/sda1 /mnt 

Offline

#5 2020-02-22 00:31:41

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

Despite the usbstick?

Offline

#6 2020-02-22 00:37:58

loqs
Member
Registered: 2014-03-06
Posts: 18,691

Re: [Solved] Chroot fail during system recovery or pacstrap error?

Booting from the live media why would you need to mount anything else before mounting the system to /mnt?

Offline

#7 2020-02-22 01:43:20

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

Live media does not have a short cut to networking, and I have to use wpa.... I got tired of typing.

I forgot to mention above: I have been trying this for two days. I have been following the Wiki guides. “Fixing a broken system” in General Troubleshooting was a first stop, and pacman’s “How do I reinstall ...” was the second.

Last edited by OrigBitmancer (2020-02-22 01:48:22)

Offline

#8 2020-02-22 01:50:23

loqs
Member
Registered: 2014-03-06
Posts: 18,691

Re: [Solved] Chroot fail during system recovery or pacstrap error?

archlinux-2020.02.01-x86_64.iso was built with wpa_supplicant 2:2.9-5

Offline

#9 2020-02-22 02:06:14

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

Ok. Now how do I get it to do something like :
pacman --sysroot /mnt -Qoq /usr > /mnt/temp/Qoq
And then
pacman --sysroot /mnt —ignore yay -S `cat  /mnt/temp/Qoq`

I.e. ignore errors?

Offline

#10 2020-02-22 02:10:09

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

What is the language for a subtractive diff?
File1:
A
B
C

File2:
B

Output:
A
C

I have 83 B entries to remove from the 3500-line Qoq list ....

(additional research and help....)
Aha!

comm -23 <(sort Qoq)  <(sort errors) > Qminuserrors

I will clean up this post.

Last edited by OrigBitmancer (2020-02-22 22:52:56)

Offline

#11 2020-02-22 03:45:31

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

Sorry. Now I used your hint and am trying Crash During Upgrade.

pacman —sysroot /mnt -Syu 

gives

Error: failed retrieving file ... :could not resolve host

With ... being core.db, extra.db, ....
fails in step 4.

ping archlinux.org

shows that I am still online.

Could it be using temp space on the optical disc?

I have a good mirrorlist. What argument would point to /sdb1/mirrorlist ?

Last edited by OrigBitmancer (2020-02-23 06:54:30)

Offline

#12 2020-02-23 23:19:27

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

Now from

pacman —sysroot /mnt -S bash

I get
error:could not open file: /etc/mtab: no such file
bBecause there is no creating process?
Can I use fstab?

Offline

#13 2020-02-23 23:44:42

loqs
Member
Registered: 2014-03-06
Posts: 18,691

Re: [Solved] Chroot fail during system recovery or pacstrap error?

stat /mnt/etc/mtab

Edit:
The error occurred after you have done 1, 2 and 3 from the link at step 4?

Last edited by loqs (2020-02-23 23:46:45)

Offline

#14 2020-02-24 23:43:46

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

That sequence has no internet access step.

I have to substitute my own. I use

wpa_supplicant -B -I wlan0 -c /mnt/tmp/wpa_supplicant.conf && dhcpcd wlan0

I put this in a text file so that typos are kept away, and sh <text file>

Am I getting shell environment issues?

Then after pacman...Syu I get
... a lot of “Could not resolve host” messages
...
Error: failed to synchronize all databases

And the job ends.

Last edited by OrigBitmancer (2020-02-24 23:48:34)

Offline

#15 2020-02-24 23:54:04

loqs
Member
Registered: 2014-03-06
Posts: 18,691

Re: [Solved] Chroot fail during system recovery or pacstrap error?

Can you ping the first mirror in the system's mirrorlist from the live media after you run wpa_supplicant and dhcpcd?

Offline

#16 2020-02-25 00:24:13

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

Yes, any mirror pings. I know it is the system’s not mine because it has offshore urls.

Debug output helps.

It keeps looking for sync databases in /var/lib/pacman/sync/ but that has no sysroot prefix?

Offline

#17 2020-02-25 00:48:00

loqs
Member
Registered: 2014-03-06
Posts: 18,691

Re: [Solved] Chroot fail during system recovery or pacstrap error?

Please post the output from the failing command. See tip box from pastebin.

Offline

#18 2020-02-25 02:42:33

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

It sent back
http://ix.io/2cC9
And I remembered there was a code for that....

Last edited by OrigBitmancer (2020-02-25 15:46:18)

Offline

#19 2020-02-25 22:38:36

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

/var is intact. Can the install sequence be constructed?

Offline

#20 2020-02-25 22:50:22

loqs
Member
Registered: 2014-03-06
Posts: 18,691

Re: [Solved] Chroot fail during system recovery or pacstrap error?

The log ends with

:: thunderbird and thunderbird-60-bin are in conflict. Remove thunderbird-60-bin? [y/N] 

As standard error and standard out were redirected to the pastebin so there was no on screen output.
I am guessing the log ends there because you terminated the command when you could not see any output?  So the error is not in the provided log.

Off topic but did you enable every entry in the mirrorlist?

Offline

#21 2020-02-25 23:23:53

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

No, I tried to use only the mirrors near me.

I have to edit the master mirror list and replace it every time. I will replace it on the host. Does it honor —ignore arguments?

Offline

#22 2020-02-25 23:33:10

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

loqs wrote:

The log ends with

:: thunderbird and thunderbird-60-bin are in conflict. Remove thunderbird-60-bin? [y/N] 

As standard error and standard out were redirected to the pastebin so there was no on screen output.
I am guessing the log ends there because you terminated the command when you could not see any output?  So the error is not in the provided log.

Off topic but did you enable every entry in the mirrorlist?

The error is not in the provided log, but the first hint is that the databases are not being found. Can you see that near the top?

Offline

#23 2020-02-25 23:41:13

loqs
Member
Registered: 2014-03-06
Posts: 18,691

Re: [Solved] Chroot fail during system recovery or pacstrap error?

No the databases are found and parsed.

debug: "/var/lib/pacman/sync/core.db.sig" is not readable: No such file or directory

Databases are not signed so the signature file should not be present.

Offline

#24 2020-02-26 04:07:00

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

The /var is intact. Can the /usr be reconstructed from it?

Offline

#25 2020-02-26 07:13:25

OrigBitmancer
Member
Registered: 2019-01-22
Posts: 144

Re: [Solved] Chroot fail during system recovery or pacstrap error?

There also is /var/log/pacman.log which has 11196 lines.

I saw there was Pacman:Restore_local_database https://wiki.archlinux.org/index.php/Pa … l_database

but I cannot install pacutils from local repo:

 pacman —sysroot /mnt —confirm -U /var/cache/pacman/pkg/pacutils.... .xz

Gives the log in http://ix.io/2cHx

Offline

Board footer

Powered by FluxBB