You are not logged in.
A few days ago I ran into a problem after running pacman -Syu that ended up with an unbootable system. I found this topic that ultimately solved the kernel panic-
https://bbs.archlinux.org/viewtopic.php … 1#p1127251
All that was needed was a symlink "/lib" to point to "/usr/lib"
My system now almost boots but luckily I can now get a to a shell (zsh). The problem is that I can not run bash, and various other tools- including my desktop environment and pacman.
I have checked my $path, and have verified that I have the binary file "/usr/bin/bash" and a symlink in /bin/bash to point to that binary file, which does exist...
% ls -l /bin/bash
lrwxrwxrwx 1 root root 13 May 24 23:43 /bin/bash -> /usr/bin/bash
% ls -l /usr/bin/bash
-rwxr-xr-x 1 root root 738008 Mar 13 00:47 /usr/bin/bashBut when I try to start a bash shell or run a script
% bash
zsh: command not found: bash
% pacman
zsh: command not found: pacman
% /usr/bin/bash
zsh: no such file or directory /usr/bin/bash
% cat test.sh
#!/bin/bash
echo "Hello World"
% ./test.sh
zsh: ./test.sh: bad interpreter: /bin/bash: no such file or directoryI hope i was thorough enough in providing information about my system, but please let me know if there's anything else I left out that may be able to help.
Thanks so much!
[SOLVED]- Ended up mounting my system from a live install cd, and copying over each bash binary in my system with the live media's binary.
Last edited by OrangeCrush (2013-05-25 06:38:43)
Offline
After glib update?! /lib -> /usr/lib!? How long has it been since you have updated?
Offline
A few months?
I was just trying to install a package, and after getting 404's on the repository URL's, I just tryed to synchronize the repository databases with pacman -Syu, as this worked in the past. The problem, and eventually solution, that I had was exactly laid out in https://bbs.archlinux.org/viewtopic.php … 1#p1127251 so i assumed that glibc was the issue. Perhaps this was not the case- I only assumed that it was. Nevertheless I can not find any information about a problem running /bin/bash that says the file does not exist when it does.
Offline
If it has only been a few months, that thread should have nothing to do with what you are experiencing. That problem stemmed from when the filesystem was actually changed from having /lib as an actual directory to /lib as a symlink to /usr/lib. Oh the problems that caused. For me it went perfectly smooth... well I did have to search for and rid /lib of extraneous unowned files, but it was smooth after that.
You say though that you did not have a /lib symlink when you checked, and then you created it? This is odd, as that is part of the filesystem package and therefore a tracked file. Maybe you should start by reinstalling the filesystem package just to make sure that the necessary components of the filesystem are all in order before proceeeding.
BTW, you should really update more often than every "few months" as that is what using a rolling release is all about. Also if you don't update very often still, never update the database (-Sy) without also updating the system (-Syu) as this will lead to partial upgrades, which can severly break your system. So never do "pacman -Sy <package>" as that is the equivalent of doing just a "pacman -Sy" and then continuing on your merry way. Big changes are in the air right now around these parts, so keeping your system up to date is probably going to be crucial in making subsequent updates as pain free as possible (we are heading towards the final /bin -> /usr/bin move!).
Offline
Ok. Thanks for the advice. The problem about installing packages is that pacman is broken as well..perhaps I wasn't clear enough above, sorry. I will investigate installing packages without pacman?
Offline
Yes, so you need to use a live media to install pacman with... pacman. Actually in this case, pacstrap will probably do, as it is simply a wrapper around pacman. If you want to use pacman proper, it has options to point it to an alternate root as well as an alternate package cache and db. Pacstrap is just a wrapper around pacman that does these things automagically for you. It is fully written in bash, so it is also easily changed.
Offline
SOLVED. Thank you for your help. I messed around with pacman --root ... but what ended up doing the trick was just taking the bash binary file from the live media and copying over the one in my system. Thanks again!
Offline