OpenVZ Forum


Home » General » Support » rpm in a container question? (rpm within a container does not work)
rpm in a container question? [message #38204] Fri, 27 November 2009 20:29 Go to next message
michaelk is currently offline  michaelk
Messages: 8
Registered: November 2009
Junior Member
Hi Everyone!

I have a small but a very annoying problem... I can't do "rpm" within a container.

Example:

# cat /etc/redhat-release
CentOS release 5.4 (Final)

# uname -r
2.6.18-164.2.1.el5.028stab066.7

This command works fine:
# rpm --dbpath /vz/root/101/var/lib/rpm -qa

While this command shows nothing: Confused

# vzctl enter 101
entered into CT 101
# rpm -qa

Any hints why?

Thanks in advance,

Michael
Re: rpm in a container question? [message #38205 is a reply to message #38204] Fri, 27 November 2009 20:45 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

What are RPM software versions on the host system and inside the CT? I.e. the output of the below executed on the host system:

rpm --version
vzctl exec 101 rpm --version


Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: rpm in a container question? [message #38206 is a reply to message #38204] Fri, 27 November 2009 21:27 Go to previous messageGo to next message
Paparaciz
Messages: 302
Registered: August 2009
Senior Member
what if you try yum? does it make any errors?
with some containers which i had migrated from xen based virtualization (xen guests) i had problems also with yum, and also rpm makes no output
you can try some suggestions provided by me in:
https://www.centos.org/modules/newbb/viewtopic.php?topic_id= 20237&forum=37&post_id=76684#forumpost76684

[Updated on: Fri, 27 November 2009 21:28]

Report message to a moderator

Re: rpm in a container question? [message #38212 is a reply to message #38206] Sat, 28 November 2009 10:19 Go to previous message
michaelk is currently offline  michaelk
Messages: 8
Registered: November 2009
Junior Member
Hi!

creating a new /dev/urandom

i.e:

# vzctl stop 101
# mknod --mode 644 /vz/private/101/dev/urandom c 1 9
# vzctl start 101

solved the problem Razz

I guess something got messed up when I upgraded from 5.3 to 5.4...

Thanks for all help!

Michael
Previous Topic: Problems getting openvz kernel to recognize elrepo driver
Next Topic: Transparent HA on two node active/passive cluster
Goto Forum:
  


Current Time: Tue Aug 27 21:20:25 GMT 2024

Total time taken to generate the page: 0.03682 seconds