title: openstack: Failed to launch instance from the glance
body: <p>We have setup OpenStack using conjure-up on a (Ubuntu LTS server 16.04.3) single machine. All are services are up and running, and successfully I am able to upload images to the glance.</p>
  
  <p>We wanted to save these glance images created by "glance image-create" in remote machine which have nfs server. So we have configured glance-api.conf file as below.</p>
  
  <p>My glance-api.conf looks like this:</p>
  
  <pre><code>[glance_store]
  filesystem_store_datadir = /var/lib/glance/images
  default_store = file
  </code></pre>
  
  <p>And in glance controller node, I have mounted </p>
  
  <p><code>remote machine Ip/home/glance/images/</code> in this directory path 
  <code>/var/lib/glance/images</code></p>
  
  <p>and have mentioned the same mounted directory path inside the glance-api.conf file.</p>
  
  <p>I have created the two sample private network with some ip (192.168.1.0 and 10.221.50.0) but have not created a public network as at this moment I don't want to access this VM instance from outside.</p>
  
  <p>When I am trying to launch the instance from dashboard UI as well as through CLI, I am getting below error.</p>
  
  <pre>Error: Failed to perform requested operation on instance "Ubuntu_Hawkbit", the instance has an error status: Please try again later [Error: No valid host was found. There are not enough hosts available.].</pre>
  
  <p>Note: I have tried by associating Instance with different private network ,thinking that it may be network IP address issue but facing the same error.</p>
  
  <p>When I check /var/log/nova/nova-compute.log logs, I see below error.</p>
  
  <pre>ERROR nova.image.glance [req-1459f1b2-491c-46a2-b803-6ff621a79d30 6ebc7996240c4ce688234f544c9d0116 07427c9d49704357a049b24193ee0a28 - -
     -] Error contacting glance server 'http://10.206.193.159:9292' for 'data', done trying.  
  ERROR nova.image.glance CommunicationError:
     Error finding address for
     http://10.206.193.159:9292/v1/images/6c30e2ab-1078-45ad-bed2-3e3a75f6af8c:
     ('Connection aborted.', BadStatusLine("''",))   
  ERROR
     nova_lxd.nova.virt.lxd.image
     [req-1459f1b2-491c-46a2-b803-6ff621a79d30
     6ebc7996240c4ce688234f544c9d0116 07427c9d49704357a049b24193ee0a28 - -
     -] [instance: eedc008d-ef34-498d-8774-b3813ce032f4] Failed to upload 6c30e2ab-1078-45ad-bed2-3e3a75f6af8c to LXD: Connection to glance 
  ERROR nova_lxd.nova.virt.lxd.operations
     [req-1459f1b2-491c-46a2-b803-6ff621a79d30
     6ebc7996240c4ce688234f544c9d0116 07427c9d49704357a049b24193ee0a28 - -
     -] [instance: eedc008d-ef34-498d-8774-b3813ce032f4] Faild to start container instance-00000020: Connection to glance host
     http://10.206.193.159:9292 failed: Error finding address for
     http://10.206.193.159:9292/v1/images/6c30e2ab-1078-45ad-bed2-3e3a75f6af8c:
     ('Connection aborted.', BadStatusLine("''",))  
  ERROR nova.compute.manager [req-1459f1b2-491c-46a2-b803-6ff621a79d30
     6ebc7996240c4ce688234f544c9d0116 07427c9d49704357a049b24193ee0a28 - -
     -] [instance: eedc008d-ef34-498d-8774-b3813ce032f4] Instance failed to spawn</pre>