OpenVZ Forum


Home » General » Support » Trouble starting/accessing Gentoo VPS
Trouble starting/accessing Gentoo VPS [message #9797] Tue, 23 January 2007 07:20 Go to next message
davewi is currently offline  davewi
Messages: 6
Registered: January 2007
Junior Member
I followed instructions for setting up OpenVZ on Gentoo:
http://gentoo-wiki.com/HOWTO_OpenVZ
Whitch got me a long ways.
I eventually was able to create and start a VPS based on the
http://download.openvz.org/template/precreated/gentoo-200603 17-i686-stage3.tar.gz
However. Although I was able to run commands like:
vzctl set 101 --ipadd 192.168.0.5 --save
vzctl exec 101 /usr/bin/passwd root
vzctl exec 101 /usr/bin/ls

and
vzctl exec 101 /bin/ps ax
  PID TTY      STAT   TIME COMMAND
    1 ?        Ss     0:00 init
 9643 ?        Ss     0:00 /usr/sbin/sshd
 9646 ?        Rs     0:00 /bin/ps ax

getting interactive output to the screen (changing password etc), I couldn't get an interactive shell.
I tried ssh from host os and other computers
ssh root@192.168.0.5
vzctl enter 101
vzctl exec 101 /bin/bash
vzctl exec 101 /bin/sh

all with the same result of it just stopping at the point of initiating the terminal session. SSH made it through the whole authentication.
There are no messages about anything in the hosts /var/log/messages, /var/log/vzctl.log or the VPS client logs.
I was able to simply kill the process with a ctrl-c or kill pid.

Any thoughts? Guides to the right place?
Thanks for the help!!! Very Happy

Dave
Re: Trouble starting/accessing Gentoo VPS [message #9803 is a reply to message #9797] Tue, 23 January 2007 09:42 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

Am I got it right that vzctl enter NNN just hangs? If yes, please run strace -Ff on it and post the result here (as an attachment).

Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: Trouble starting/accessing Gentoo VPS [message #9811 is a reply to message #9803] Tue, 23 January 2007 17:36 Go to previous messageGo to next message
davewi is currently offline  davewi
Messages: 6
Registered: January 2007
Junior Member
Yes it hangs but hitting Ctrl-c still kills the process and not the VPS.
Atached are the logs from the following commands. (with addresses changed for security)
strace -Ff -ovzctlenter.log vzctl enter 101
strace -Ff -oovzssh.log ssh 192.168.0.17
strace -Ff -oovzbash.log vzctl exec 101 /bin/bash

ssh has to be kiled from a nother shell with kill -15 pid-for-ssh-process

Thanks again for looking at this! Very Happy

Dave
  • Attachment: vzctlenter.log
    (Size: 91.34KB, Downloaded 333 times)
  • Attachment: ovzssh.log
    (Size: 25.67KB, Downloaded 299 times)
  • Attachment: ovzbash.log
    (Size: 101.59KB, Downloaded 299 times)
Re: Trouble starting/accessing Gentoo VPS [message #9812 is a reply to message #9811] Tue, 23 January 2007 17:42 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

What kernel do you use?

Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: Trouble starting/accessing Gentoo VPS [message #9813 is a reply to message #9812] Tue, 23 January 2007 18:24 Go to previous messageGo to next message
davewi is currently offline  davewi
Messages: 6
Registered: January 2007
Junior Member
Linux onstar 2.6.9-023stab037openvz #8 Mon Jan 22 12:09:31 PST 2007 i686 Pentium III (Katmai) GNU/Linux
I've attached my make and .config files.

FYI I did :
 vzctl exec 101 /bin/mount    
none on /proc type proc (rw)
none on /proc type proc (rw)
none on /proc type proc (rw)
none on /proc type proc (rw)
none on /proc type proc (rw)


Thanks
  • Attachment: config
    (Size: 32.83KB, Downloaded 306 times)
  • Attachment: Makefile
    (Size: 41.23KB, Downloaded 299 times)
Re: Trouble starting/accessing Gentoo VPS [message #9814 is a reply to message #9813] Tue, 23 January 2007 18:59 Go to previous messageGo to next message
davewi is currently offline  davewi
Messages: 6
Registered: January 2007
Junior Member
I just downloaded a couple other os templates, created VPSs for them and was able to enter them.
Interesting. I did notice that all the other ones are for i386 while the gentoo is for i686. My kernel is compiled for a Pentium III so that shouldn't be a problem but???
Re: Trouble starting/accessing Gentoo VPS [message #9815 is a reply to message #9814] Tue, 23 January 2007 20:09 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

Looks like something is wrong with /dev and/or tty devices.

Oh, perhaps you do not enable CONFIG_LEGACY_PTYS when configuring your kernel? If that's the case, you shall mount /dev/pts in your VE. In Gentoo, this should happen in /sbin/rc script. You can check whether it is mounted or not by doing vzctl exec NNN cat /proc/mounts


Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: Trouble starting/accessing Gentoo VPS [message #9816 is a reply to message #9815] Tue, 23 January 2007 20:28 Go to previous messageGo to next message
davewi is currently offline  davewi
Messages: 6
Registered: January 2007
Junior Member
The kernel is compiled with
CONFIG_LEGACY_PTYS=y

the results of the gentoo based VPS are:
vzctl exec 101 cat /proc/mounts
simfs / simfs rw 0 0
proc /proc proc rw,nodiratime 0 0

and for the fedora core 5 minimal are:
vzctl exec 105 cat /proc/mounts
simfs / simfs rw 0 0
proc /proc proc rw,nodiratime 0 0
tmpfs /var/run tmpfs rw 0 0
tmpfs /var/lock tmpfs rw 0 0
devpts /dev/pts devpts rw 0 0
tmpfs /dev/shm tmpfs rw 0 0
tmpfs /var/run tmpfs rw 0 0
tmpfs /var/lock tmpfs rw 0 0


Thanks again! Very Happy
Dave
Re: Trouble starting/accessing Gentoo VPS [message #9820 is a reply to message #9816] Wed, 24 January 2007 00:41 Go to previous messageGo to next message
davewi is currently offline  davewi
Messages: 6
Registered: January 2007
Junior Member
The gentoo VPS /sbin/rc does not have stuff for creating devfs or pts.
I haven't found a way to get the /rc into the VPS file system.
Re: Trouble starting/accessing Gentoo VPS [message #9827 is a reply to message #9820] Wed, 24 January 2007 07:54 Go to previous message
Vasily Tarasov is currently offline  Vasily Tarasov
Messages: 1345
Registered: January 2006
Senior Member
Please, try to add to VE's /etc/fstab:
none    /dev/pts        devpts  rw      0 0

and restart this VE. Then try to enter it.

HTH,
Vasily.
Previous Topic: *SOLVED* problems creating veth device: "Bad parameter for --veth_add: ..."
Next Topic: *SOLVED* Network script like vps.mount
Goto Forum:
  


Current Time: Sat Oct 12 15:14:41 GMT 2024

Total time taken to generate the page: 0.06278 seconds