uvt-kvm ssh fails with No such file or directory: u'/var/lib/libvirt/dnsmasq/default.leases'

Bug #1420142 reported by Nobuto Murata
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
uvtool (Ubuntu)
In Progress
High
Jorge Niedbalski

Bug Description

`uvt-kvm ssh --insecure <VM>` fails, but I can ssh to the VM using IP address instead.

$ uvt-kvm create ssh-test release=trusty

$ uvt-kvm ssh --insecure ssh-test
Traceback (most recent call last):
  File "/usr/bin/uvt-kvm", line 35, in <module>
    uvtool.libvirt.kvm.main_cli_wrapper(sys.argv[1:])
  File "/usr/lib/python2.7/dist-packages/uvtool/libvirt/kvm.py", line 711, in main_cli_wrapper
    main(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/uvtool/libvirt/kvm.py", line 706, in main
    args.func(parser, args)
  File "/usr/lib/python2.7/dist-packages/uvtool/libvirt/kvm.py", line 582, in main_ssh
    return ssh(name, login_name, args.ssh_arguments)
  File "/usr/lib/python2.7/dist-packages/uvtool/libvirt/kvm.py", line 467, in ssh
    ips = name_to_ips(name)
  File "/usr/lib/python2.7/dist-packages/uvtool/libvirt/kvm.py", line 460, in name_to_ips
    in (uvtool.libvirt.mac_to_ip(mac) for mac in macs)
  File "/usr/lib/python2.7/dist-packages/uvtool/libvirt/kvm.py", line 460, in <genexpr>
    in (uvtool.libvirt.mac_to_ip(mac) for mac in macs)
  File "/usr/lib/python2.7/dist-packages/uvtool/libvirt/__init__.py", line 241, in mac_to_ip
    with codecs.open(LIBVIRT_DNSMASQ_LEASE_FILE, 'r') as f:
  File "/usr/lib/python2.7/codecs.py", line 878, in open
    file = __builtin__.open(filename, mode, buffering)
IOError: [Errno 2] No such file or directory: u'/var/lib/libvirt/dnsmasq/default.leases'

ProblemType: Bug
DistroRelease: Ubuntu 15.04
Package: uvtool-libvirt 0~bzr92-0ubuntu2
ProcVersionSignature: Ubuntu 3.18.0-13.14-generic 3.18.5
Uname: Linux 3.18.0-13-generic x86_64
ApportVersion: 2.16-0ubuntu1
Architecture: amd64
CurrentDesktop: Unity
Date: Tue Feb 10 16:45:32 2015
EcryptfsInUse: Yes
InstallationDate: Installed on 2015-02-09 (0 days ago)
InstallationMedia: Ubuntu 15.04 "Vivid Vervet" - Alpha amd64 (20150207)
PackageArchitecture: all
SourcePackage: uvtool
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Nobuto Murata (nobuto) wrote :
Revision history for this message
Robie Basak (racb) wrote :

Hi,

How did you obtain the VM's IP address, please? Did "uvt-kvm ip <VM>" work at the time the ssh subcommand failed?

Revision history for this message
Nobuto Murata (nobuto) wrote :

I just got it from my ARP table. "uvt-kvm ip" does not work either.

Robie Basak (racb)
Changed in uvtool (Ubuntu):
importance: Undecided → High
Changed in uvtool (Ubuntu):
status: New → In Progress
assignee: nobody → Jorge Niedbalski (niedbalski)
Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

This is fixed in "uvtool (0~bzr99-0ubuntu1) vivid"
Now you might run into this still if you run Trusty (not having this fix as it doesn't need it for its version of libvirt) but then pull in Ubuntnu Cloud Archive Mitaka (or other newer libvirts.

In that case you will get this issue again.
Since UCA is to support an Openstack setup and not for general use the updated uvtool (universe) is not in there.

Workaround: you can easily get the latest from https://launchpad.net/~uvtool-dev/+archive/ubuntu/master and things work again.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related blueprints

Remote bug watches

Bug watches keep track of this bug in other bug trackers.