LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Yum erase glibc (https://www.linuxquestions.org/questions/linux-newbie-8/yum-erase-glibc-927397/)

Divya Sankaran 02-03-2012 07:44 AM

Yum erase glibc
 
I did a yum erase glibc on my linux redhat machine and it deleted a lot of files including some importatnt files! Now I am unable to even enter the machine because it says the root password is wrong. Now what to do to enter the machine first and then reinstall all the packages!!!! Please help me.

unSpawn 02-03-2012 10:57 AM

Quote:

Originally Posted by Divya Sankaran (Post 4592839)
I did a yum erase glibc on my linux redhat machine and it deleted a lot of files including some importatnt files! Now I am unable to even enter the machine because it says the root password is wrong. Now what to do to enter the machine first and then reinstall all the packages!!!! Please help me.

Boot the installer or a Live CD, configure network, download glibc .rpm package, cd / and then 'rpm2cpio|cpio -idv' unpack it. After (and if) the machine boots use You to down load and --force install the package again.

knudfl 02-03-2012 11:15 AM

Two packages are required for "glibc", I think :
glibc and glibc-common .


You may be out of luck, if you didn't stop 'yum erase glibc'
immediately : 98 % of all packages depend on glibc,
and were removed too by that command.
! Glibc is your OS (Together with the kernel)
and should never be touched !

.

John VV 02-03-2012 02:20 PM

you will not do that again
reinstall the operating system

unSpawn 02-04-2012 03:04 AM

Quote:

Originally Posted by John VV (Post 4593106)
reinstall the operating system

If the OP can access the system using a Live CD that's rather disporportionate.

chrism01 02-05-2012 06:13 PM

On a RH system, you should be able to boot from the install media and type
Code:

linux rescue

# then after its done, use this example ;
# amend rpm names as needed

chroot /mnt/sysimage

rpm -ivh --replacepkgs --root /mnt/sysimage /mnt/source/Server/bash-3*.rpm



All times are GMT -5. The time now is 10:27 PM.