When I install a rpm package on RHEL using rpm, I got a error message just like "Failed dependencies: /bin/sh is needed by xxx".
I checked that /bin/sh is there and it links to /bin/bash and bash works well.
I found a solution that to add --nodeps
to the rpm command to solve this problem. But I really want to know what is the root cause?
How to reproduce this error on a fresh install of Ubuntu 14.04.
sudo apt-get install rpm
chmod +x nomachine_4.2.25_1_x86_64.rpm
on itextract it like this:
el@apollo:~Desktop$ sudo rpm -i nomachine_4.2.25_1_x86_64.rpm
rpm: RPM should not be used directly install RPM packages, use Alien instead!
rpm: However assuming you know what you are doing...
error: Failed dependencies:
/bin/sh is needed by nomachine-4.2.25-1.x86_64
So that is the error. To fix it I followed its advice to use alien.
sudo alien -i nomachine_4.2.25_1_x86_64.rpm --scripts
And no machine installed correctly.
I have find root cause for this problem. The rpm-libs is missing on my machine. I reinstall rpm-libs then everything is ok. Note: After installing rpm-libs, if the problem still exists, please try "rpm -v --rebuilddb --define="_rpmlock_path /var/lock/rpm"".
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With