LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   ahhh!! I cant login as root or any user at all nor install anything (https://www.linuxquestions.org/questions/linux-newbie-8/ahhh-i-cant-login-as-root-or-any-user-at-all-nor-install-anything-4175528956/)

asilentmurmur 12-21-2014 05:36 PM

ahhh!! I cant login as root or any user at all nor install anything
 
Hello all

I am running into some trouble when trying to install packages on my RHEL 6.6 distro which is running off of a USB flash drive. Let me give you a bit of a backstory on this whole ordeal:

I attended a Red Hat workshop a few days ago and they provided us all with USB flash drives containing RHEL 6.6 which can be booted from the USB. Well after the work shop they told us that we cannot use their RHN account with the flash drive that they gave us so we had to unsubscribe from RHN. When I got home I added the CentOS 6.6 repo to /etc/yum.repos.d/ and I was able to download packages using yum and the CentOS 6.6 repo. Well today I was trying to install the Virtualization Client group using :

yum groupinstall "Virtualization Client"
and I received an error message saying that there is a multilib discrepancy between cyrus-sasl-lib-2.1.23-15.el6_6.1.x86_64 and the i686 version. So naturally I thought to myself "why not remove the cyrus-sasl-lib version that is currently installed and them do a yum install cyrus-sasl-lib to install the correct version?" well thats where I made my big mistake. I ran

rpm -e --nodeps cyrus-sasl-lib

which did remove the package but now whenever I try to do a yum install or a yum update or a yum anything it tells me:

Code:

There was a problem importing one of the Python modules required to run yum. The error leading to this problem was:
    libsasl2.so.2: cannot open shared object file: no such file or directory

I then figured I should just download the rpm for cyrus-sasl-lib and install it using rpm -Uvh --replacepkgs cyrus-sasl-lib etc etc.rpm (i found these instructions on a website)
but whenever I attempt to run the command I receive:

Code:

error: cyrus-sasl-lib-2.1.23-15.el6_6.1.x86_64.rpm: Header V3 RSA/SHA1 Signature, key ID c105b9de: BAD
error: cyrus-sasl-lib-2.1.23-15.el6_6.1.x86_64.rpm cannot be installed.

A bit of research on the internet informed me that the rpm db might be corrupted so I ran

rpm -vv --rebuilddb
which ran successfully (I think)

but still whenever I try to run the rpm -Uvh or rpm -ivh or RPM anything command to install the cyrus-sasl-lib rpm I still get teh same error messages as above.

I have no idea what to do. I had to boot into single user mode just to be able to run any commands because 1) The system will not allow me to su into root nor login as ANY user whatsover (this is in init 3) and also the system will not boot into the GUI at all, it just hangs there with the "RHEL 6" banner on the screen.

I am totally lost as to what I should do to fix this problem. PLEASE help! All help is greatly appreciated..

I do not want to have to reinstall because I have no idea how the Red Hat team was able to install the distro to the USB and be able to boot from the USB ! Also I am able to write files to the USB booted distro in a persistent manner, i.e. the files do not disappear after I reboot.

Thanks everyone!

Ser Olmy 12-21-2014 05:56 PM

Quote:

Originally Posted by asilentmurmur (Post 5288728)
I then figured I should just download the rpm for cyrus-sasl-lib and install it using rpm -Uvh --replacepkgs cyrus-sasl-lib etc etc.rpm (i found these instructions on a website)
but whenever I attempt to run the command I receive:

Code:

error: cyrus-sasl-lib-2.1.23-15.el6_6.1.x86_64.rpm: Header V3 RSA/SHA1 Signature, key ID c105b9de: BAD
error: cyrus-sasl-lib-2.1.23-15.el6_6.1.x86_64.rpm cannot be installed.


So it chokes on the signature. I guess you could try the --nosignature and --nodigest options, if you're certain the package is in fact good.

unSpawn 12-21-2014 07:07 PM

Nooowwwww! 0xC105B9DE is the official signing key for CentOS 6. It should reside in /etc/pki/rpm-gpg/ when the EPEL release RPM is installed. If it isn't then please install the EPEL release RPM properly. Then fix it instead of subverting one of RPM's vital features:
Code:

rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6

Ser Olmy 12-21-2014 07:20 PM

Quote:

Originally Posted by unSpawn (Post 5288747)
Nooowwwww! 0xC105B9DE is the official signing key for CentOS 6. It should reside in /etc/pki/rpm-gpg/ when the EPEL release RPM is installed. If it isn't then please install the EPEL release RPM properly. Then fix it instead of subverting one of RPM's vital features:
Code:

rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6

Well, there's a chance the OP won't find the CentOS signing key in /etc/pki/rpm-gpg, since he isn't actually running CentOS at all, but rather RHEL 6.6, which he's trying to update/repair using packages from a CentOS repository.

unSpawn 12-21-2014 07:35 PM

He said
Quote:

When I got home I added the CentOS 6.6 repo
so if he didn't do that "the right way", then yeah, so much for safety belts...

asilentmurmur 12-22-2014 05:26 AM

Quote:

Originally Posted by Ser Olmy (Post 5288730)
So it chokes on the signature. I guess you could try the --nosignature and --nodigest options, if you're certain the package is in fact good.

Hello all thank you for responding I really appreciate it

I tried to install the rpm using --nosignature and --nodigest and I did not receive the error message any more. The only problem is that it is asking for various dependencies to be installed. So i downloaded the dependencies, glibc and db4-4.7.25-18 and when I tried to install them using --nosignature and --nodigest, it asked for more dependencies to be resolved. So I downloaded those dependencies for glibc, which are libgcc, nss-softokn-freebl, basesystem, and glibc-common and then attempted to install them using rpm -ivh --nodigest --nosignature and in turn I get asked for more dependencies.


Any idea how I should resolve this? Also regarding the GPG for CentOS.. I dont have it in my /etc/pki/rpm-gpg/ directory. I did download it to an external drive and transferred it to the broken installation, and using rpm --import I installed it but I still do not see it in my rpm-gpg directory nor did I resolve any issues.

---------- Post added 12-22-14 at 06:27 AM ----------

Quote:

Originally Posted by unSpawn (Post 5288757)
He said so if he didn't do that "the right way", then yeah, so much for safety belts...

So what would be the right way to set up the repo ?

suicidaleggroll 12-22-2014 08:26 AM

You DO NOT just add the CentOS repo to an RHEL OS and call it good! You must actually CHANGE your OS from RHEL to CentOS, which is much more involved than just added a repo. If you didn't do that properly, then you've probably screwed up the system pretty bad. There are hundreds of guides online that walk you though changing an RHEL installation to CentOS. Not a single one of which tells you to simply add the CentOS repo and start installing packages.

Any chance you can get a replacement USB drive, or a replacement image for it? Was there anything on there except a vanilla installation? If not, then you'd be best off just downloading a CentOS ISO and installing it from scratch.

asilentmurmur 12-22-2014 09:18 AM

Quote:

Originally Posted by suicidaleggroll (Post 5288967)
You DO NOT just add the CentOS repo to an RHEL OS and call it good! You must actually CHANGE your OS from RHEL to CentOS, which is much more involved than just added a repo. If you didn't do that properly, then you've probably screwed up the system pretty bad. There are hundreds of guides online that walk you though changing an RHEL installation to CentOS. Not a single one of which tells you to simply add the CentOS repo and start installing packages.

Any chance you can get a replacement USB drive, or a replacement image for it? Was there anything on there except a vanilla installation? If not, then you'd be best off just downloading a CentOS ISO and installing it from scratch.

Hello

thank you for your response. I would like to install CentOS on the USB instead of RHEL so I dont have to go through all of the crazy trouble again. I searched online for decent tutorials which explain how to install CentOS on a bootable USB and to successfully boot from it. But I have not been able to find any thing that works. My laptop is a Macbook Air and I want to be able to use the Macbook Air to boot into the USB and run CentOS smoothly from the USB. Anyone have any ideas if this will work?

lsalab 12-23-2014 03:55 PM

If what you want is to have a CentOS test machine, why not just run it on a virtual machine (VirtualBox, VMware, etc.) ?

You could just create a small VM to run the CentOS.

John VV 12-23-2014 08:38 PM

asilentmurmur

as above you can not just add the cent repos to RHEL6

-- That will NOT work

if you are not going to buy the required support contract
then MIGRATE to cent 6.6

http://wiki.centos.org/HowTos/Migrat...=%28migrate%29

cent uses version numbers DIFFERENT THAN redhat uses ( but just a bit higher )

that way migration is easy



As to a bootable thumb drive

HOW did you make it ????
that is VERY important !!!

cent6 dose not have a live cd
7.0 dose
http://mirror.rackspace.com/CentOS/7/isos/x86_64
"CentOS-7.0-1406-x86_64-livecd.iso"

for a LIVE image you can just use "dd" to put the image on the drive

for a NON live image you NEED to do a normal INSTALL to it

burn the dvd "CentOS-7.0-1406-x86_64-DVD.iso" to a dvd
put the thumb drive AND the dvd in the computer
then reboot

then INSTALL to the thumb drive

7 "should" auto install grub to the thumb
BUT IT MIGHT NOT!!!!! so pay attention and make sure it DOSE


All times are GMT -5. The time now is 03:04 AM.