google / novm

Experimental KVM-based VMM for containers, written in Go.
Apache License 2.0
1.68k stars 123 forks source link

novm command error #28

Open foxwang opened 9 years ago

foxwang commented 9 years ago

root@ubuntu:/home/fox/novm# novm kernels

| id | url | timestamp | release | name |

| e4a4937c6cf0c769af670ebf6df1a2eb2a001995 | file:///tmp/tmpoFu5Jj | Mon Jan 12 00:51:20 2015 | 3.13.0-32-generic | |

root@ubuntu:/home/fox/novm# novm --debug create --kernel e4a4937c6cf0c769af670ebf6df1a2eb2a001995 --name test 20182 root@ubuntu:/home/fox/novm# novm list root@ubuntu:/home/fox/novm# novm run 20144 error: "{'name': None}" root@ubuntu:/home/fox/novm#

root@ubuntu:/home/fox/novm# uname -an Linux ubuntu 3.13.0-32-generic #57-Ubuntu SMP Tue Jul 15 03:51:08 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux root@ubuntu:/home/fox/novm# go version go version go1.2.1 linux/amd64

hamo commented 9 years ago

If you want to run something in one instance, you should do like:

novm run --id 20144 WhatYouWantToRun

foxwang commented 9 years ago

like this?: root@ubuntu:/home/fox/novm# novm --debug create --kernel e4a4937c6cf0c769af670ebf6df1a2eb2a001995 --name test 20351 root@ubuntu:/home/fox/novm# novm list //nothing。。。。。。。。 root@ubuntu:/home/fox/novm# novm --debug run --id 20351 /bin/ls Traceback (most recent call last): File "./novm/cli.py", line 203, in main result = fn(_built_args) File "./novm/shell.py", line 182, in run command=command) File "./novm/manager.py", line 397, in run_noguest ctrl = control.Control(ctrl_path, bind=False) File "./novm/control.py", line 56, in init self._sock.connect(path) File "/usr/lib/python2.7/socket.py", line 224, in meth return getattr(self._sock,name)(_args) error: [Errno 2] No such file or directory root@ubuntu:/home/fox/novm#

hamo commented 9 years ago

@foxwang if novm list outputs nothing, that means the kvm instance is not started. Here is the output on my machine: hamo@TRINITY ~ $ python2 /usr/bin/novm create 28448 hamo@TRINITY ~ $ ps aux | grep 28448 hamo 28448 64.5 1.9 1668548 116728 pts/5 Sl 17:54 0:02 novmm -statefd=5 -vmlinux /home/hamo/.novm/kernels/6177e7ae242914ff8750c05ff850a901fd935dd3/vmlinux -sysmap /home/hamo/.novm/kernels/6177e7ae242914ff8750c05ff850a901fd935dd3/sysmap -initrd /home/hamo/.novm/kernels/6177e7ae242914ff8750c05ff850a901fd935dd3/initrd -setup /home/hamo/.novm/kernels/6177e7ae242914ff8750c05ff850a901fd935dd3/setup -cmdline=intel_pstate=disable pci=conf1 -controlfd=3 root 28456 0.0 0.0 0 0 ? S 17:54 0:00 [kvm-pit/28448] hamo 28468 0.0 0.0 12604 1136 pts/5 S+ 17:54 0:00 grep --colour=auto 28448 hamo@TRINITY ~ $ python2 /usr/bin/novm run --id 28448 /bin/ls bin boot dev etc home lib lib64 lost+found mnt opt proc root run sbin srv sys tmp usr var

foxwang commented 9 years ago

tks can you tell me,What’s your OS ?and the kernel version?

amscanne commented 9 years ago

Are you sure you have /dev/kvm and a new enough kernel?

The best way to debug is run the following command:

novm --debug create --nofork --com1

cholcombe973 commented 9 years ago

I think I'm having the same issue on ubuntu 14.04: ~/repos/novm$ ./scripts/novm --debug create --nofork --com1 2015/04/22 16:32:39 Missing capability: XCRS

influx6 commented 7 years ago

Am having errors as well on creating containers and executing commands:

 python2 scripts/novm --debug run --id 11469 /usr/bin/ls
Traceback (most recent call last):
  File "./novm/cli.py", line 203, in main
    result = fn(*built_args)
  File "./novm/shell.py", line 186, in run
    command=command)
  File "./novm/manager.py", line 404, in run_noguest
    ctrl = control.Control(ctrl_path, bind=False)
  File "./novm/control.py", line 57, in __init__
    self._sock.connect(path)
  File "/usr/lib/python2.7/socket.py", line 228, in meth
    return getattr(self._sock,name)(*args)
error: [Errno 2] No such file or directory