Failed to run instance because thread creation failed.

Bug #733020 reported by guanxiaohua2k6
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Invalid
Undecided
Unassigned

Bug Description

I failed to run instance because the thread couldn't be created. The followings are related messages and version I used.

Messages from nova-network.log:

2011-03-11 10:28:48,404 DEBUG nova [-] network_topic : network from (pid=7830) serve /usr/lib/pymodules/python2.6/nova/service.py:278
2011-03-11 10:28:48,404 AUDIT nova [-] Starting network node (version 2011.2-workspace:tarmac-20110310204019-eamnui9ovgiu8dah)
2011-03-11 10:28:48,414 CRITICAL nova [-] failed to create /usr/lib/pymodules/python2.6/ubuntu7.MainThread-7830
(nova): TRACE: Traceback (most recent call last):
(nova): TRACE: File "/usr/bin/nova-network", line 48, in <module>
(nova): TRACE: service.serve()
(nova): TRACE: File "/usr/lib/pymodules/python2.6/nova/service.py", line 281, in serve
(nova): TRACE: x.start()
(nova): TRACE: File "/usr/lib/pymodules/python2.6/nova/service.py", line 84, in start
(nova): TRACE: self.manager.init_host()
(nova): TRACE: File "/usr/lib/pymodules/python2.6/nova/network/manager.py", line 489, in init_host
(nova): TRACE: super(VlanManager, self).init_host()
(nova): TRACE: File "/usr/lib/pymodules/python2.6/nova/network/manager.py", line 125, in init_host
(nova): TRACE: self.driver.init_host()
(nova): TRACE: File "/usr/lib/pymodules/python2.6/nova/network/linux_net.py", line 391, in init_host
(nova): TRACE: iptables_manager.apply()
(nova): TRACE: File "/usr/lib/pymodules/python2.6/nova/utils.py", line 523, in inner
(nova): TRACE: with lock:
(nova): TRACE: File "/usr/lib/pymodules/python2.6/lockfile.py", line 223, in __enter__
(nova): TRACE: self.acquire()
(nova): TRACE: File "/usr/lib/pymodules/python2.6/lockfile.py", line 239, in acquire
(nova): TRACE: raise LockFailed("failed to create %s" % self.unique_name)
(nova): TRACE: LockFailed: failed to create /usr/lib/pymodules/python2.6/ubuntu7.MainThread-7830

Version of nova-network: 2011.2~bzr786-0ubuntu0ppa1~maverick1

The contents of nova.conf:

--sql_connection=mysql://root:nova@ubuntu7/nova
--s3_host=ubuntu7
--rabbit_host=192.168.32.202
--cc_host=192.168.32.202
--ec2_url=http://192.168.32.202:8773/services/Cloud

--daemonize=1

--dhcpbridge_flagfile=/etc/nova/nova.conf
--dhcpbridge=/usr/bin/nova-dhcpbridge

--FAKE_subdomain=ec2

--ca_path=/var/lib/nova/CA
--keys_path=/var/lib/nova/keys
--networks_path=/var/lib/nova/networks
--instances_path=/var/lib/nova/instances
--images_path=/var/lib/nova/images
--buckets_path=/var/lib/nova/buckets

--libvirt_type=kvm

--network_manager=nova.network.manager.VlanManager

--vlan_interface=eth0

--logdir=/var/log/nova
--verbose
--volume_group=ubuntu7
--fixed_range=192.168.2.64/26
--network_size=64

Revision history for this message
Dan Prince (dan-prince) wrote :

Hi Guan. Can you try setting adding this to your nova.conf file:

--lock_path=/tmp

You can use any directory the nova user can write to.

The latest code requires a writable lock file directory.

Revision history for this message
Dan Prince (dan-prince) wrote :

I would also add that it would be nice to have lock_path default to something reasonable (writable) when using the nova packages.

Revision history for this message
guanxiaohua2k6 (guanxiaohua2k6) wrote :

Thank you, Dan Prince. I confirmed in my environment. It works. Thank you very much.

Revision history for this message
Thierry Carrez (ttx) wrote :

Closing as NOTABUG.
Note that Ubuntu packaging, as of bzr786, defines lock_path.

Changed in nova:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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