← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1588041] Re: [2.0 rc1] juju can't access vSphere VM deployed with Xenial, cloud-init fails to set SSH keys

 

I have downloaded a drive image of a xenial VM that Juju attempted to
boot and found that cloud-init could not parse the user-data attached to
the instance.  Here is the relevant error from /var/log/cloud-init.log.
Attaching /var/lib/cloud, /var/log, and /etc/cloud to this bug for
further research.

Sep 22 18:47:54 ubuntu [CLOUDINIT] __init__.py[DEBUG]: {'Content-Type': 'text/x-not-multipart', 'Content-Disposition': 'attachment; filename="part-001"', 'MIME-Version': '1.0'}
Sep 22 18:47:54 ubuntu [CLOUDINIT] __init__.py[WARNING]: Unhandled non-multipart (text/x-not-multipart) userdata: 'b'I2Nsb3VkLWNvbmZpZwphcHRf'...'


** Attachment added: "xenial-juju-vsphere-userdata-20160921.tar.gz"
   https://bugs.launchpad.net/juju/+bug/1588041/+attachment/4746458/+files/xenial-juju-vsphere-userdata-20160921.tar.gz

** Project changed: cloud-images => cloud-init

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to cloud-init.
https://bugs.launchpad.net/bugs/1588041

Title:
  [2.0 rc1] juju can't access vSphere VM deployed with Xenial,  cloud-
  init fails to set SSH keys

Status in cloud-init:
  New
Status in juju:
  Triaged

Bug description:
  I tried to do a bootstrap with vsphere as a provider using vsphere 6.0 and juju 1.25.5.
  -----------------------------------------------------------------
    vsphere:
      type: vsphere
      host: '**.***.*.***'
      user: 'administrator@xxxxxxxxxxx'
      password: '**********'
      datacenter: 'dc0'
      bootstrap-timeout: 1800
      logging-config: "<root>=DEBUG;juju=DEBUG;golxc=TRACE;juju.container.lxc=TRACE"
      agent-stream: released
  -----------------------------------------------------------------

  Initially, I did not specify the default series and bootstrap VM
  deployed with Xenial, however, juju  could not connect to it after
  getting the address and seems stuck trying to connect and I had to
  CTRL-C:

  -----------------------------------------------------------------
  $ juju bootstrap -e vsphere
  ERROR the "vsphere" provider is provisional in this version of Juju. To use it anyway, set JUJU_DEV_FEATURE_FLAGS="vsphere-provider" in your shell environment
  $ export JUJU_DEV_FEATURE_FLAGS="vsphere-provider"
  $ juju bootstrap -e vsphere
  Bootstrapping environment "vsphere"
  Starting new instance for initial state server
  Launching instance
   - juju-e33e5800-edd9-4af7-8654-6d59b1e98eb9-machine-0
  Installing Juju agent on bootstrap instance
  Waiting for address
  Attempting to connect to 10.245.39.94:22
  Attempting to connect to fe80::250:56ff:fead:1b03:22
  ^CInterrupt signalled: waiting for bootstrap to exit
  ERROR failed to bootstrap environment: interrupted
  -----------------------------------------------------------------

  When I specified the default series to be trusty, it worked:
  -----------------------------------------------------------------
    vsphere:
      type: vsphere
      host: '**.***.*.***'
      user: 'administrator@xxxxxxxxxxx'
      password: '**********'
      datacenter: 'dc0'
      default-series: trusty
      bootstrap-timeout: 1800
      logging-config: "<root>=DEBUG;juju=DEBUG;golxc=TRACE;juju.container.lxc=TRACE"
      agent-stream: released
  -----------------------------------------------------------------

  This was the output:

  -----------------------------------------------------------------
  $ juju bootstrap -e vsphere
  Bootstrapping environment "vsphere"
  Starting new instance for initial state server
  Launching instance
   - juju-b157863b-3ed4-4ae5-8c3c-82ae7629bff7-machine-0
  Installing Juju agent on bootstrap instance
  Waiting for address
  Attempting to connect to 10.245.45.153:22
  Attempting to connect to fe80::250:56ff:fead:3fa2:22
  Warning: Permanently added '10.245.45.153' (ECDSA) to the list of known hosts.
  sudo: unable to resolve host ubuntuguest
  Logging to /var/log/cloud-init-output.log on remote host
  Running apt-get update
  Running apt-get upgrade
  Installing package: curl
  Installing package: cpu-checker
  Installing package: bridge-utils
  Installing package: rsyslog-gnutls
  Installing package: cloud-utils
  Installing package: cloud-image-utils
  Installing package: tmux
  Fetching tools: curl -sSfw 'tools from %{url_effective} downloaded: HTTP %{http_code}; time %{time_total}s; size %{size_download} bytes; speed %{speed_download} bytes/s ' --retry 10 -o $bin/tools.tar.gz <[https://streams.canonical.com/juju/tools/agent/1.25.5/juju-1.25.5-trusty-amd64.tgz]>
  Bootstrapping Juju machine agent
  Starting Juju machine agent (jujud-machine-0)
  Bootstrap agent installed
  vsphere -> vsphere
  Waiting for API to become available
  Waiting for API to become available
  Waiting for API to become available
  Waiting for API to become available
  Bootstrap complete
  -----------------------------------------------------------------

To manage notifications about this bug go to:
https://bugs.launchpad.net/cloud-init/+bug/1588041/+subscriptions