You are not logged in.

#1 2008-02-12 23:22:53

senjin
Member
Registered: 2006-09-15
Posts: 181
Website

pacman -Syu can break the system (solved, just warning)

I think it's a bug in pacman, but it broke my system, so this is a warning for you:

1. I typed pacman -Syu.
2. It asked me if I want to replace mktemp with coreutils - I answered yes.
3. Then I got nvidia bug (file conflict). I have read on the forum that it's not a serious problem and I should do pacman -Sf nvidia.
4. I did pacman -Sf nvidia, but pacman wanted to update kernel also.
5. Kernel update failed. I got ton of "mktemp - command not found" messages. The system (kernel) was broken, when I tried to reboot, I got only "ramfs" prompt...
6. I booted from arch cd, installed back mktemp, installed kernel (the new one, 2.6.24) successfully, rebooted, did pacman -Sfu - now everything works fine.

I think the problem is that pacman removed mktemp too early, and didn't install coreutils to replace it after finding nvidia file conflict. The other problem is that if kernel installation fails, it shouldn't replace the existing, working kernel. I managed to solve the problem, but for a newbie it could be disaster... and it can cause similar situations in the future.

Offline

#2 2008-02-12 23:34:46

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,365
Website

Re: pacman -Syu can break the system (solved, just warning)

This is indeed an interesting bug... and one that wouldn't been seen very often.

You should file a bug report with the details.

Offline

#3 2008-02-13 00:21:18

senjin
Member
Registered: 2006-09-15
Posts: 181
Website

Re: pacman -Syu can break the system (solved, just warning)

Offline

#4 2008-02-13 01:24:30

Cerebral
Forum Fellow
From: Waterloo, ON, CA
Registered: 2005-04-08
Posts: 3,108
Website

Re: pacman -Syu can break the system (solved, just warning)

I already know the order of events that caused this to happen - this is due to the fact that pacman treats a 'replace' operation like a remove, followed by an upgrade.  I'll cross-post it to the FS report.

1) You answered yes to remove mktemp, and replace with coreutils.
2) All packages downloaded from the repos.
3) Pacman removed mktemp ('cause you told it you could)
4) Pacman then attempts to upgrade all the packages you downloaded.
5) Pacman fails, because of filesystem conflicts with nvidia.
6) Pacman quits, leaving mktemp removed from your filesystem, but the new coreutils isn't installed.

The solution in your case would have been to simply pacman -S coreutils before rebooting. 

In anycase, this behaviour should probably be looked at in pacman.  I'm not sure how complicated it'd be to do all the filesystem checks before removing mktemp instead of after.

Offline

#5 2008-02-13 05:04:09

stonecrest
Member
From: Boulder
Registered: 2005-01-22
Posts: 1,190

Re: pacman -Syu can break the system (solved, just warning)

In my opinion, this is the same issue as: http://bugs.archlinux.org/task/9088


I am a gated community.

Offline

#6 2008-02-13 06:09:45

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,365
Website

Re: pacman -Syu can break the system (solved, just warning)

Very similar...  only difference is that it was not the replacing package that caused the conflict.  I should check if that is covered by the pactest mentioned in your bug report.  Edit: not quite, but the fix for that should cover both...

Last edited by Allan (2008-02-13 06:14:10)

Offline

#7 2008-02-13 14:18:52

mrunion
Member
From: Jonesborough, TN
Registered: 2007-01-26
Posts: 1,938
Website

Re: pacman -Syu can break the system (solved, just warning)

This happened to me as well.  I had to boot from a live CD, chroot into my "old" system, upgrade the kernel again from the pacman cache and all was well.


Matt

"It is very difficult to educate the educated."

Offline

#8 2008-02-14 21:48:12

krusty
Member
Registered: 2008-02-14
Posts: 3

Re: pacman -Syu can break the system (solved, just warning)

Actually I upgraded my system just now, but i got the same ramfs-output on booting...

So i chroot'ed into the system with the arch live cd; mktemp can't be installed cause it conflicts with coreutils, so should i remove coreutils and install back mktemp?

The other thing is: I've never used chroot before...so is it normal that i don't have a connection to the internet in it? Cause for an update i need the connection, do i?

Thx for now, Krusty wink

Offline

#9 2008-02-15 00:27:45

senjin
Member
Registered: 2006-09-15
Posts: 181
Website

Re: pacman -Syu can break the system (solved, just warning)

The kernel should build properly with coreutils, I think you don't have to go back to mktemp...

You can find downloaded packages in /var/cache/pacman/pkg, you don't have to download them each time. Anyway -  just re-install kernel and you can try to reboot normally.

Offline

#10 2008-02-15 12:35:28

krusty
Member
Registered: 2008-02-14
Posts: 3

Re: pacman -Syu can break the system (solved, just warning)

hmm...thanks for the answer, senjin smile

I reinstalled the kernel just with "pacman -S kernel26" but I remember some error message about mktemp hmm
Thus rebooting still brings up the recovery prompt...

So: how do I get connection to the internet in chroot? I think I need the connection to download the last packages, innit?

*edit* I just chrooted into the system again and i think the problem is, that two packages (mkinitcpio and nvidia (?!)) still do need the mktemp package...
the question is: how can i solve this conflict?

Last edited by krusty (2008-02-15 13:20:18)

Offline

#11 2008-02-15 14:12:55

mrunion
Member
From: Jonesborough, TN
Registered: 2007-01-26
Posts: 1,938
Website

Re: pacman -Syu can break the system (solved, just warning)

I had the same issue Krusty.  What I did was boot from a live CD and chroot into the "existing (broken)" system.  I then installed the latest kernel from the cache (pacman -U /var/cache/plg/kernel26....24-xx.....) and after the installation finished I rebooted and all was well.


Matt

"It is very difficult to educate the educated."

Offline

#12 2008-02-15 16:41:45

senjin
Member
Registered: 2006-09-15
Posts: 181
Website

Re: pacman -Syu can break the system (solved, just warning)

Krusty, can't you then uninstall coreutils and install back mktemp - and install kernel then? It worked for me.

Anyway it should work with coreutils, but... I don't know, I'm linux newbie wink

Offline

#13 2008-02-15 17:46:25

krusty
Member
Registered: 2008-02-14
Posts: 3

Re: pacman -Syu can break the system (solved, just warning)

mrunion wrote:

I then installed the latest kernel from the cache (pacman -U /var/cache/plg/kernel26....24-xx.....) and after the installation finished I rebooted and all was well.

Yes, this is exactely what I did as well, but it still won't work hmm

senjin wrote:

Krusty, can't you then uninstall coreutils and install back mktemp - and install kernel then?

Yeah, but that's the point: mktemp and coreutils got dependencies...it would be a lot of work to remove all of these -infact very important- packages. I'm afraid of breaking my system by deleting stuff like kernel26, mkinitcpio, etc...


Conclusion:
The simple trick to install the kernel again from cache didn't work; older kernels won't install because of dependencies, older coreutils won't install because of dependencies and mktemp won't install because of coreutils.
And best of all: Removing any of these packages brings up even more dependencies sad

*edit Ok, first of all: I got my linux back smile

I had to downgrade kernel26 as well as coreutils and remove nvidia and lirc. Then i could install mktemp and reboot. Then i just had to do a pacman -Syu without nvidia and then install nvidia seperately...this was the deal.

Last edited by krusty (2008-02-15 21:25:17)

Offline

Board footer

Powered by FluxBB