*BSDThis forum is for the discussion of all BSD variants.
FreeBSD, OpenBSD, NetBSD, etc.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hello
I was trying to get gmake to run and it kept saying that libc.so.6 or something was missing. So, I tried to change the search path for the /libexec and so I moved /libexec to /libexec_old and tried to see if gmake works. It didnt. Then I issued the command "mv /libexec_old /libexec" after that, I cannot run any commands. The ssh terminal is frozen, there is no prompt and all I get is "ELF interpreter /libexec/ld-elf.so.1 not found". I guess I have messed up big time. What do I do now? To make matters worse, its a virtual machine and not a physical machine. The virtual machine refuses to shut down for a reboot.
I don't think rebooting is going to help, considering that the kernel's not going to run afterwards. Is it possible to do a rescue CD boot on a virtual machine? If not, I dare say you're probably hosed. (Although I would think that any process in memory would still work fine.)
Were you able to run the mv command? If not, use /rescue/mv
The /rescue directory is populated with statically linked commands for just this situation. They will be able to help you fix the problem. To see what you have to work with, do:
"cd rescue; ./ls"
Do Not Reboot! If you do, you won't actually solve the problem and will be at the same point you're at now (having to use /rescue) but without everything mounted or clean. It's best to just fix it from the running system so you don't screw more things up. You don't want this problem combined with dirty filesystems.
Were you able to run the mv command? If not, use /rescue/mv
The /rescue directory is populated with statically linked commands for just this situation. They will be able to help you fix the problem. To see what you have to work with, do:
"cd rescue; ./ls"
Do Not Reboot! If you do, you won't actually solve the problem and will be at the same point you're at now (having to use /rescue) but without everything mounted or clean. It's best to just fix it from the running system so you don't screw more things up. You don't want this problem combined with dirty filesystems.
Hmm.. too bad. I already rebooted and yes, I am hosed. Luckily, we had a back up of the virtual machine and we have used it to load it up again. but some of my customizations in this vm are gone. Thanks for all your help. I will keep that in mind the next time i encounter this type of situation.
That happens sometimes. Next time something like this happens, try and remember that you're probably not the first person to do it. I've done it myself (actually) in my earlier days. All the BSDs come with a directory of statically linked tools which exist for situations like that. And almost every other big "Oops" you're likely to make has been done and might have a solution waiting for just that problem.
If you didn't waste the "hosed" copy (like if you just moved it aside) you can try and bring it back up. You're going to need to boot (it will go single-user automatically) and then fsck the drives before fixing things. It can be done. Or you could even boot from the image you're currently using, with the old image as a second disk, and clean and repair it from the backup system.
I hope you didn't waste the broken copy... because it could have been saved.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.