diff --git a/doc/install-guide/ch_nova.xml b/doc/install-guide/ch_nova.xml index 3a5439903b..b0d9e829e2 100644 --- a/doc/install-guide/ch_nova.xml +++ b/doc/install-guide/ch_nova.xml @@ -4,8 +4,9 @@ xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0" xml:id="ch_nova"> - Add the Compute services + Add the Compute service - + + diff --git a/doc/install-guide/section_nova-controller-install.xml b/doc/install-guide/section_nova-controller-install.xml new file mode 100644 index 0000000000..58451ca450 --- /dev/null +++ b/doc/install-guide/section_nova-controller-install.xml @@ -0,0 +1,228 @@ +
+ Install and configure controller node + This section describes how to install and configure the Compute + service, code-named nova, on the controller node. + + To configure prerequisites + Before you install and configure Compute, you must create a database + and Identity service credentials including endpoints. + + To create the database, complete these steps: + + + Use the database access client to connect to the database + server as the root user: + $ mysql -u root -p + + + Create the nova database: + mysql> CREATE DATABASE nova; + + + Grant proper access to the nova + database: + mysql> GRANT ALL PRIVILEGES ON nova.* TO 'nova'@'localhost' IDENTIFIED BY 'NOVA_DBPASS'; +mysql> GRANT ALL PRIVILEGES ON nova.* TO 'nova'@'%' IDENTIFIED BY 'NOVA_DBPASS'; + Replace NOVA_DBPASS with a suitable + password. + + + Exit the database access client: + mysql> exit + + + + + Source the admin credentials to gain access to + admin-only CLI commands: + $ source admin-openrc.sh + + + To create the Identity service credentials, complete these + steps: + + + Create the nova user: + $ keystone user-create --name=nova --pass=NOVA_PASS --email=EMAIL_ADDRESS + Replace NOVA_PASS with a suitable + password and EMAIL_ADDRESS with + a suitable e-mail address. + + + Link the nova user to the + service tenant and admin + role: + $ keystone user-role-add --user=nova --tenant=service --role=admin + + + Create the nova service: + $ keystone service-create --name=nova --type=compute --description="OpenStack Compute" + + + + + Create the Compute service endpoints: + $ keystone endpoint-create \ + --service-id=$(keystone service-list | awk '/ compute / {print $2}') \ + --publicurl=http://controller:8774/v2/%\(tenant_id\)s \ + --internalurl=http://controller:8774/v2/%\(tenant_id\)s \ + --adminurl=http://controller:8774/v2/%\(tenant_id\)s + + + + To install and configure Compute controller components + + Install the packages: + # apt-get install nova-api nova-cert nova-conductor nova-consoleauth \ + nova-novncproxy nova-scheduler python-novaclient + # yum install openstack-nova-api openstack-nova-cert openstack-nova-conductor \ + openstack-nova-console openstack-nova-novncproxy openstack-nova-scheduler \ + python-novaclient + # zypper install openstack-nova-api openstack-nova-scheduler \ + openstack-nova-cert openstack-nova-conductor openstack-nova-console \ + openstack-nova-consoleauth openstack-nova-novncproxy python-novaclient + + + Edit the /etc/nova/nova.conf file and + complete the following actions: + + + In the [database] section, configure + database access: + [database] +... +connection = mysql://nova:NOVA_DBPASS@controller/nova + Replace NOVA_DBPASS with the + password you chose for the Compute database. + + + In the [DEFAULT] section, configure + RabbitMQ message broker access: + [DEFAULT] +... +rpc_backend = rabbit +rabbit_host = controller +rabbit_password = RABBIT_PASS + Replace RABBIT_PASS with the + password you chose for the guest account in + RabbitMQ. + + + In the [keystone_authtoken] section, + configure Identity service access: + +[keystone_authtoken] +... +auth_uri = http://controller:5000/v2.0 +auth_host = controller +auth_port = 35357 +auth_protocol = http +admin_tenant_name = service +admin_user = nova +admin_password = NOVA_PASS + Replace NOVA_PASS with the password + you chose for the nova user in the Identity + service. + + + In the [DEFAULT] section, configure the + my_ip key to use the management interface IP + address of the controller node: + [DEFAULT] +... +my_ip = 10.0.0.11 + + + In the [DEFAULT] section, configure the + VNC proxy to use the management interface IP address of the + controller node: + [DEFAULT] +... +vncserver_listen = 10.0.0.11 +vncserver_proxyclient_address = 10.0.0.11 + + + In the [DEFAULT] section, configure the + location of the Image Service: + [DEFAULT] +... +glance_host = controller + + + + + Populate the Compute database: + # su -s /bin/sh -c "nova-manage db sync" nova + + + + To install and configure the Compute controller components + + Install the packages: + # apt-get install nova-api nova-cert nova-conductor nova-consoleauth \ + nova-novncproxy nova-scheduler python-novaclient + + + Respond to prompts for + database management, + Identity service + credentials, + service endpoint + registration, and + message broker + credentials. + + + Edit the /etc/nova/nova.conf file and + complete the following actions: + + + In the [DEFAULT] section, configure the VNC + proxy to use the management interface IP address of the controller + node: + [DEFAULT] +... +vncserver_listen = 10.0.0.11 +vncserver_proxyclient_address = 10.0.0.11 + + + + + + To finalize installation + + Restart the Compute services: + # service nova-api restart +# service nova-cert restart +# service nova-consoleauth restart +# service nova-scheduler restart +# service nova-conductor restart +# service nova-novncproxy restart + + + Start the Compute services and configure them to start when the + system boots: + # service openstack-nova-api start +# service openstack-nova-cert start +# service openstack-nova-consoleauth start +# service openstack-nova-scheduler start +# service openstack-nova-conductor start +# service openstack-nova-novncproxy start +# chkconfig openstack-nova-api on +# chkconfig openstack-nova-cert on +# chkconfig openstack-nova-consoleauth on +# chkconfig openstack-nova-scheduler on +# chkconfig openstack-nova-conductor on +# chkconfig openstack-nova-novncproxy on + + + By default, the Ubuntu packages create an SQLite database. + Because this configuration uses a SQL database server, you can + remove the SQLite database file: + # rm /var/lib/nova/nova.sqlite + + +
diff --git a/doc/install-guide/section_nova-controller.xml b/doc/install-guide/section_nova-controller.xml deleted file mode 100644 index b0049844de..0000000000 --- a/doc/install-guide/section_nova-controller.xml +++ /dev/null @@ -1,200 +0,0 @@ -
- Install Compute controller services - Compute is a collection of services that enable you to launch - virtual machine instances. You can configure these services to run - on separate nodes or the same node. In this guide, most services - run on the controller node and the service that launches virtual - machines runs on a dedicated compute node. This section shows you - how to install and configure these services on the controller - node. - - - Install the Compute packages necessary for the controller - node. - # yum install openstack-nova-api openstack-nova-cert openstack-nova-conductor \ - openstack-nova-console openstack-nova-novncproxy openstack-nova-scheduler \ - python-novaclient - # apt-get install nova-api nova-cert nova-conductor nova-consoleauth \ - nova-novncproxy nova-scheduler python-novaclient - # zypper install openstack-nova-api openstack-nova-scheduler \ - openstack-nova-cert openstack-nova-conductor openstack-nova-console \ - openstack-nova-consoleauth openstack-nova-novncproxy python-novaclient - - - Respond to the prompts for database - management, [keystone_authtoken] settings, - RabbitMQ - credentials, and API endpoint registration. The nova-manage - db sync command runs automatically. - - - - Compute stores information in a database. In this guide, we - use a MySQL database on the controller node. Configure Compute - with the database location and credentials. Replace - NOVA_DBPASS with the password for the - database that you will create in a later step. - # openstack-config --set /etc/nova/nova.conf \ - database connection mysql://nova:NOVA_DBPASS@controller/nova - Edit the [database] section - in the /etc/nova/nova.conf file, adding it if - necessary, to modify this - key: - -[database] -connection = mysql://nova:NOVA_DBPASS@controller/nova - - - - Configure the Compute service to use the RabbitMQ message broker by - setting these configuration keys in the [DEFAULT] - configuration group of the /etc/nova/nova.conf - file: - [DEFAULT] -... -rpc_backend = rabbit -rabbit_host = controller -rabbit_password = RABBIT_PASS - - - Set these configuration keys to configure Compute to use - the RabbitMQ message broker: - # openstack-config --set /etc/nova/nova.conf \ - DEFAULT rpc_backend nova.rpc.impl_kombu -# openstack-config --set /etc/nova/nova.conf DEFAULT rabbit_host controller -# openstack-config --set /etc/nova/nova.conf DEFAULT rabbit_password RABBIT_PASS - - - Set the , - , and - - configuration options to the management interface IP address of the - controller node: - # openstack-config --set /etc/nova/nova.conf DEFAULT my_ip 10.0.0.11 -# openstack-config --set /etc/nova/nova.conf DEFAULT vncserver_listen 10.0.0.11 -# openstack-config --set /etc/nova/nova.conf DEFAULT vncserver_proxyclient_address 10.0.0.11 - Edit the - /etc/nova/nova.conf file and add these - lines to the [DEFAULT] section: - In Debian, the debconf - package automatically sets up my_ip - parameter but you must edit the - /etc/nova/nova.conf file to configure - the and - options, - which appear at the end of the file: - [DEFAULT] -... -my_ip = 10.0.0.11 -vncserver_listen = 10.0.0.11 -vncserver_proxyclient_address = 10.0.0.11 - - - - By default, the Ubuntu packages create an SQLite database. - Delete the nova.sqlite file created in - the /var/lib/nova/ directory so that it - does not get used by mistake: - # rm /var/lib/nova/nova.sqlite - - - Use the password you created previously to log in as root. - Create a nova database user: - $ mysql -u root -p -mysql> CREATE DATABASE nova; -mysql> GRANT ALL PRIVILEGES ON nova.* TO 'nova'@'localhost' \ -IDENTIFIED BY 'NOVA_DBPASS'; -mysql> GRANT ALL PRIVILEGES ON nova.* TO 'nova'@'%' \ -IDENTIFIED BY 'NOVA_DBPASS'; - - - Create the Compute service tables: - # su -s /bin/sh -c "nova-manage db sync" nova - - - Create a nova user that Compute uses to - authenticate with the Identity Service. Use the - service tenant and give the user the - admin role: - $ keystone user-create --name=nova --pass=NOVA_PASS --email=nova@example.com -$ keystone user-role-add --user=nova --tenant=service --role=admin - - - Configure Compute to use these credentials with the Identity - Service running on the controller. Replace - NOVA_PASS with your Compute password. - # openstack-config --set /etc/nova/nova.conf keystone_authtoken auth_uri http://controller:5000 -# openstack-config --set /etc/nova/nova.conf keystone_authtoken auth_host controller -# openstack-config --set /etc/nova/nova.conf keystone_authtoken auth_protocol http -# openstack-config --set /etc/nova/nova.conf keystone_authtoken auth_port 35357 -# openstack-config --set /etc/nova/nova.conf keystone_authtoken admin_user nova -# openstack-config --set /etc/nova/nova.conf keystone_authtoken admin_tenant_name service -# openstack-config --set /etc/nova/nova.conf keystone_authtoken admin_password NOVA_PASS - Add these keys to the - [keystone_authtoken] section: - -[keystone_authtoken] -... -auth_uri = http://controller:5000 -auth_host = controller -auth_port = 35357 -auth_protocol = http -admin_tenant_name = service -admin_user = nova -admin_password = NOVA_PASS - - - You must register Compute with the Identity Service so - that other OpenStack services can locate it. Register the - service and specify the endpoint: - - $ keystone service-create --name=nova --type=compute \ - --description="OpenStack Compute" -$ keystone endpoint-create \ - --service-id=$(keystone service-list | awk '/ compute / {print $2}') \ - --publicurl=http://controller:8774/v2/%\(tenant_id\)s \ - --internalurl=http://controller:8774/v2/%\(tenant_id\)s \ - --adminurl=http://controller:8774/v2/%\(tenant_id\)s - - - Start Compute - services and configure them to start when the system - boots: - Restart Compute services: - # service nova-api restart -# service nova-cert restart -# service nova-consoleauth restart -# service nova-scheduler restart -# service nova-conductor restart -# service nova-novncproxy restart - # service openstack-nova-api start -# service openstack-nova-cert start -# service openstack-nova-consoleauth start -# service openstack-nova-scheduler start -# service openstack-nova-conductor start -# service openstack-nova-novncproxy start -# chkconfig openstack-nova-api on -# chkconfig openstack-nova-cert on -# chkconfig openstack-nova-consoleauth on -# chkconfig openstack-nova-scheduler on -# chkconfig openstack-nova-conductor on -# chkconfig openstack-nova-novncproxy on - - - To verify your configuration, list available - images: - $ nova image-list -+--------------------------------------+---------------------+--------+--------+ -| ID | Name | Status | Server | -+--------------------------------------+---------------------+--------+--------+ -| acafc7c0-40aa-4026-9673-b879898e1fc2 | cirros-0.3.2-x86_64 | ACTIVE | | -+--------------------------------------+---------------------+--------+--------+ - - -
diff --git a/doc/install-guide/section_nova-verify.xml b/doc/install-guide/section_nova-verify.xml new file mode 100644 index 0000000000..59542a6b74 --- /dev/null +++ b/doc/install-guide/section_nova-verify.xml @@ -0,0 +1,46 @@ +
+ Verify operation + This section describes how to verify operation of the Compute + service. + + + Perform these commands on the controller node. + + + Source the admin credentials to gain access to + admin-only CLI commands: + $ source admin-openrc.sh + + + List service components to verify successful launch of each + process: + $ nova service-list ++------------------+-------------+----------+---------+-------+----------------------------+-----------------+ +| Binary | Host | Zone | Status | State | Updated_at | Disabled Reason | ++------------------+-------------+----------+---------+-------+----------------------------+-----------------+ +| nova-cert | controller | internal | enabled | up | 2014-06-29T22:23:16.000000 | - | +| nova-consoleauth | controller | internal | enabled | up | 2014-06-29T22:23:10.000000 | - | +| nova-scheduler | controller | internal | enabled | up | 2014-06-29T22:23:14.000000 | - | +| nova-conductor | controller | internal | enabled | up | 2014-06-29T22:23:11.000000 | - | +| nova-compute | compute1 | nova | enabled | up | 2014-06-29T22:23:11.000000 | - | ++------------------+-------------+----------+---------+-------+----------------------------+-----------------+ + + This output should indicate four components enabled on the + controller node one component enabled on the compute node. + + + + List images in the Image Service catalog to verify connectivity + with the Identity service and Image Service: + $ nova image-list ++--------------------------------------+---------------------+--------+--------+ +| ID | Name | Status | Server | ++--------------------------------------+---------------------+--------+--------+ +| acafc7c0-40aa-4026-9673-b879898e1fc2 | cirros-0.3.2-x86_64 | ACTIVE | | ++--------------------------------------+---------------------+--------+--------+ + + +