OpenStack:Nova
lastmod 2018-08-17created 2016-06-0815 edits
Command
-
nova list - Prints the list of active services (instances).
-
nova service-list - Prints the list of services.
File
-
/etc/nova/nova.conf - NOVA configuration file.
-
/var/log/nova/nova-compute.log - NOVA log file.
Configuration
Can be configured through the /etc/nova/nova.conf file.
Nova API Metadata Service
- [Recommended] Play with OpenStack instance metadata
- Introduction of Metadata service in Openstack
- Instance can not access Openstack metadata service
- What is this IP address: 169.254.169.254?
- OpenStack: Things to check in quantum when a virtual machine's network doesn't work (includes metadata-related content)
- Amazon EC2, private, public ip, hostname, or etc
- metadata provided admin_pass not working with cloudbase provided ws2012 image #11
- unable to ping metadata server 169.254.169.254
- metadata service not reachable from instance in neutron single flat provider network
- How to use meta-data service for VM with provider network
- [Recommended] OpenStack cloud-init cannot contact or ping 169.254.169.254 to establish meta-data connection – fix
Allows metadata requests from instances. The nova-api-metadata service is generally used when installing nova-network and when running in multi-host mode. For more details, see Metadata service in the OpenStack Cloud Administrator Guide.
First check the OpenStack official documentation about the metadata service. Metadata Ideally if you run an OpenStack production environment you will opt for a multi compute node solution which requires nova metadata service on each nova-compute node (for performance purpose). You can assign the metadata server like so:
- Use the
metadata_hostoption in nova.conf, specify the IP address of the node running nova-api - Run the nova-api service on each nova-compute node and specify the
enabled_apis = metadataflag in nova.conf - Or the last option (my favorite), simply run the
nova-api-metadata(with the same name package) service on each nova-compute node. It doesn’t require any modification in nova.conf (default options are enough)
Flags related to metadata in nova.conf:
metadata_listen_port = 8775
metadata_host = 172.17.1.3
metadata_manager = nova.api.manager.MetadataManager
quota_metadata_items = 128
metadata_listen = 0.0.0.0
enabled_apis = [‘ec2’, ‘osapi_compute’, ‘osapi_volume’, ‘metadata’]
metadata_port = 8775
Restart
In the RDO Project, use the following.
$ sudo systemctl | grep nova
$ sudo systemctl restart openstack-nova-api.service
$ sudo systemctl restart openstack-nova-cert.service
$ sudo systemctl restart openstack-nova-compute.service
$ sudo systemctl restart openstack-nova-conductor.service
$ sudo systemctl restart openstack-nova-consoleauth.service
$ sudo systemctl restart openstack-nova-novncproxy.service
$ sudo systemctl restart openstack-nova-scheduler.service
VGA PCI passthrough
Troubleshooting
KVM: Permission denied
- Bug 950436 - Could not access KVM kernel module: Permission denied
- Re: libvirt-users - virt-install: failed to initialize KVM: Permission denied
- Error: No valid host was found. There are not enough hosts available - closed
When creating an instance from Horizon, the following error may occur.
Checking the log file may show an error like the following.
Traceback (most recent call last):
File "/usr/share/virt-manager/virtManager/asyncjob.py", line 96, in cb_wrapper
callback(asyncjob, *args, **kwargs)
File "/usr/share/virt-manager/virtManager/asyncjob.py", line 117, in tmpcb
callback(*args, **kwargs)
File "/usr/share/virt-manager/virtManager/domain.py", line 1160, in startup
self._backend.create()
File "/usr/lib64/python2.7/site-packages/libvirt.py", line 692, in create
if ret == -1: raise libvirtError ('virDomainCreate() failed', dom=self)
libvirtError: internal error Process exited while reading console log output: char device redirected to /dev/pts/1 (label charserial0)
Could not access KVM kernel module: Permission denied
failed to initialize KVM: Permission denied
In this case, the SELinux context for libvirt may be blocked. Check the settings here.
If that's a hassle, just disable it!
List of OpenStack Service
| Main | |
| Storage | |
| Shared services | |
| Higher-level services | |
| ETC | |