Renamed lib directory by mistake


 
Thread Tools Search this Thread
Operating Systems Solaris Renamed lib directory by mistake
# 1  
Old 10-15-2010
Error Renamed lib directory by mistake

Let's say someone accidentally renamed the lib directory in Solaris 8, and now they cannot get into the terminal or even rename the folder via file manager.What would one do?
# 2  
Old 10-15-2010
Running daemons supporting file activity like ftpd/sshd might be able to do something, but they are dead if they exec().

Maybe boot up from a cd on a ramdisk and mount the device and fix it? Can Solaris do that? Else, install a small system to another disk.
This User Gave Thanks to DGPickett For This Post:
# 3  
Old 10-15-2010
Notes:

I do have a copy of the lib directory on a windows machine.

My Sun Enterprise 250 server has a CD drive.

---------- Post updated at 12:37 PM ---------- Previous update was at 12:35 PM ----------

Quote:
Originally Posted by DGPickett
...Else, install a small system to another disk.
Could you please give me a hint on how to do that, or what I should google for to do that?
# 4  
Old 10-15-2010
If you can boot off a CDROM, then you can mount the filesystem where /lib is missing and then copy the /lib directory structure over from backup.

Remember, when you have physical access to a machine, you simply boot a working OS, mount the disk partitions with problems and go in an make the repairs.

For example, your friend "Joe" accidentally deleted the /lib directory running Solaris 8. You are running Solaris 8 as well. So you say, "Hey Joe, no worries at all". I can get you up and running in no time.

Then, you shutdown Joe's machine, remove his disk, shutdown your machine, install and mount the disk, copy over your /lib directory or copy from CDROM or even install from backup.... the choice is yours.

Joe has to buy you the beers after work.

As long as you have a bootable machine, you can fix it. Even if your machine is Linux. You can still mount the Solaris filesystem (what ever you are using), and repair the injury.
This User Gave Thanks to Neo For This Post:
# 5  
Old 10-15-2010
I was using WinSCP at the time, now I can no longer log into the server using or, or any other Putty-type program. I get an access denied message.
# 6  
Old 10-15-2010
OH, in your case, it is even easier...

You can simply mount the filesystem and move it over from whatever it was accidentally named, back to /lib.

You can be up and running in a few minutes.

---------- Post updated at 17:47 ---------- Previous update was at 17:45 ----------

Quote:
Originally Posted by DGPickett
Running daemons supporting file activity like ftpd/sshd might be able to do something, but they are dead if they exec().
Unlikely....

Without /lib very little works on most machines if they use shared libs, like most modern systems do.
# 7  
Old 10-15-2010
You've got my head spinning Neo, thank you so much.

What OS would you recomend I use to put on this disk for my ancient machine?

I have a Sun Enterprise 250 (1998 vintage).
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Ubuntu

Renamed Volume Group name on Webmin while running samba server (oops)

Hi...I'm new to Linux and was working on a home server. I have it operational with Samba Share as my NAS system. Unfortunately, while I was on Webmin I changed the Logical Volume Group Name and now I can't find the data I had saved on my Samba Server. Can anyone help me recover those files? ... (0 Replies)
Discussion started by: pangil
0 Replies

2. Shell Programming and Scripting

who renamed my executable

Hi All, I connected via rlogin in testing environment (ksh ) and placed an executable with -rwxr-xr-x permission. eg: from my own unix box used : rlogin host -l user But the exe was renamed by somebody. since it's only renaming none of the access time , modification time etc is altered.... (2 Replies)
Discussion started by: blackcat
2 Replies

3. UNIX for Dummies Questions & Answers

Can anyone help me to spot my mistake?

Hi there can anyone help me to spot my mistake and please explain why it appears My code : #!/usr/bin/gawk -f BEGIN { bytes =0} { temp=$(grep "datafeed\.php" | cut -d" " -f8) bytes += temp} END { printf "Number of bytes: %d\n", bytes } when I am running ./q411 an411 an411: ... (6 Replies)
Discussion started by: FUTURE_EINSTEIN
6 Replies

4. UNIX for Advanced & Expert Users

Solved: Missing whatis file from my /usr/shar/lib directory...

My whatis file is missing from my /usr/share/lib directory. I know I can recreate it by using catman -w command. My question is, why do all of my other servers have it and this one doesn't. Maybe due to a recent move of old to new servers and it just wasn't copied over. Unlikely, 'cause all... (0 Replies)
Discussion started by: zixzix01
0 Replies

5. UNIX for Dummies Questions & Answers

Probably some stupid mistake...

Hi everyone ! I have a file wich look like this : >Sis01 > Sis02 ... >Sis44 I want to separe each paragraphe in a different file, so I decide to use the "FOR" loop + sed. for f in {01..44} do (5 Replies)
Discussion started by: sluvah
5 Replies

6. UNIX for Advanced & Expert Users

Mistakenly renamed libdl.so: system got corrupted

Hi, I am using Ubuntu 8.04 64-bit (Hardy Heron LTS Desktop edition) OS on a 64-bit intel hardware (x86_64). I have wrongly renamed the /lib64/libdl-2.7.so shared library file and now hardly few commands are working. My Gnome UI display has gone and I could not establish any new connection via... (12 Replies)
Discussion started by: royalibrahim
12 Replies

7. UNIX for Advanced & Expert Users

Critical lib renamed

Hello I have moved a critical lib from its location, so all programms linked to libc dont work . I still have two shells on the machine, bash and ksh The only thing I see is copying back the lib, but of course : dd, cp , mv etc are dead . So i tryed a loop with read ... {^Jwhile read... (24 Replies)
Discussion started by: remi75
24 Replies

8. Red Hat

ls: /lib/libattr.so.1: no version information available (required by /lib/libacl.so.1)

Hello, I'm experimenting a problem on my rh server. Red Hat Enterprise Linux AS release 3 (Taroon Update 8) 2.4.21-47.ELsmp #1 SMP i686 i686 i386 GNU/Linux It started with a segmentation fault on #id root To resolve it, I've installed coreutils-4.5.3-28.4.i386.rpm But, I... (6 Replies)
Discussion started by: gogol_bordello
6 Replies

9. Shell Programming and Scripting

duplicate index names renamed

Hello everyone ! Please have a minute and see if you know how to script this I have a file like this: "create table .... ... create index n112 on ... ... create table ... .... create index n113 on... ... create table ... create index n112 on ...! duplicate ... (1 Reply)
Discussion started by: sotoc79
1 Replies

10. UNIX for Dummies Questions & Answers

Crontab Mistake!!!

Hi. I hope someone can help me with this problem. Being a novice to Unix, I editted my crontab directly by typing " crontab -e ". Well, I needed to make some changes so, I typed " crontab -r ". Now I have no crontab, and I can't seem to get crontab to write a new file. I' ve tried: vi... (4 Replies)
Discussion started by: cstovall
4 Replies
Login or Register to Ask a Question