openstack学习笔记十一 Nova
计算节点 跑虚拟机 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 [root@hequan~] #yuminstallopenstack-nova.noarchopenstack-nova-api.noarchopenstack-nova-conductor.noarch openstack-nova-novncproxy.noarchopenstack-nova-scheduler.noarchopenstack-nova-console.noarch ##控制节点 [root@hequan~] #yuminstallopenstack-nova-compute.noarch##计算节点 keystoneuser-create--namenova--passhequan keystoneuser-role-add--usernova--roleadmin--tenantservices keystoneservice-create--namenova-- type compute--descriptionnova |7708b5c40aec4cf3b59d6d84596a5f6b|nova|compute|OpenstackComputeService| |017bdbf9f335436cbd7f65fe74089b28|nova_ec2|ec2|EC2Service| |4f7b60427d304fd89658f4f8c23dd708|novav3|computev3|OpenstackComputeServicev3| +----------------------------------+-----------+-------------------------------------------------+-------------------------------------------------+--------------------------------------------+----------------------------------+ | id |region|publicurl|internalurl|adminurl|service_id| +----------------------------------+-----------+-------------------------------------------------+-------------------------------------------------+--------------------------------------------+----------------------------------+ |0bda7145ebc944a99112c53e97362fa1|RegionOne|http: //115 .29.107.17:8774 /v2/ %(tenant_id)s|http: //115 .29.107.17:8774 /v2/ %(tenant_id)s|http: //115 .29.107.17:8774 /v2/ %(tenant_id)s|7708b5c40aec4cf3b59d6d84596a5f6b| |731be711c3be4497b57c8751ce111986|RegionOne|http: //115 .29.107.17:8773 /services/Cloud |http: //115 .29.107.17:8773 /services/Cloud |http: //115 .29.107.17:8773 /services/Admin |017bdbf9f335436cbd7f65fe74089b28| |7ec9cb12959f4bedb7e0757c79b636fd|RegionOne|http: //127 .0.0.1:8774 /v3 |http: //127 .0.0.1:8774 /v3 |http: //127 .0.0.1:8774 /v3 |4f7b60427d304fd89658f4f8c23dd708| keystoneendpoint-create--service- id --publicul '' --internalurl '' --adminurl '' openstack-db--init--servicenova--passwordhequan--root123456 [root@hequan~] #ls-ld/var/log/nova/ drwxr-x---2novaroot40967月2300:08 /var/log/nova/ [root@hequan~] #chownnova.nova/var/log/nova/-R [root@hequannova(keystone_admin)] #mvnova.confnova.conf.bak [root@hequannova(keystone_admin)] #systemctllist-unit-files|grepnova openstack-nova-api.serviceenabled openstack-nova-cert.serviceenabled openstack-nova-compute.serviceenabled openstack-nova-conductor.serviceenabled openstack-nova-console.servicedisabled openstack-nova-consoleauth.serviceenabled openstack-nova-metadata-api.servicedisabled openstack-nova-novncproxy.serviceenabled openstack-nova-scheduler.serviceenabled openstack-nova-xvpvncproxy.servicedisabled vncserver_proxyclient_address=115.29.107.17 ##改成本机的IP vim nova.conf 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 [DEFAULT] internal_service_availability_zone=internal default_availability_zone=nova novncproxy_host=0.0.0.0 novncproxy_port=6080 notify_api_faults=False state_path= /var/lib/nova report_interval=10 enabled_apis=ec2,osapi_compute,metadata ec2_listen=0.0.0.0 ec2_listen_port=8773 ec2_workers=1 osapi_compute_listen=0.0.0.0 osapi_compute_listen_port=8774 osapi_compute_workers=1 metadata_listen=0.0.0.0 metadata_listen_port=8775 metadata_workers=1 compute_manager=nova.compute.manager.ComputeManager service_down_time=60 rootwrap_config= /etc/nova/rootwrap .conf volume_api_class=nova.volume.cinder.API auth_strategy=keystone use_forwarded_for=False heal_instance_info_cache_interval=60 reserved_host_memory_mb=512 cpu_allocation_ratio=16.0 ram_allocation_ratio=1.5 network_api_class=nova.network.neutronv2.api.API default_floating_pool=public force_snat_range=0.0.0.0 /0 metadata_host=115.29.107.17 dhcp_domain=novalocal security_group_api=neutron scheduler_default_filters=RetryFilter,AvailabilityZoneFilter,RamFilter,ComputeFilter,ComputeCapabilitiesFilter,ImagePropertiesFilter,CoreFilter scheduler_driver=nova.scheduler.filter_scheduler.FilterScheduler compute_driver=libvirt.LibvirtDriver vif_plugging_is_fatal=True ##修改False如果有报错实例执行请求失败 vif_plugging_timeout=300 ##修改为0 firewall_driver=nova.virt.firewall.NoopFirewallDriver force_raw_images=True debug=False verbose=True log_dir= /var/log/nova use_syslog=False syslog_log_facility=LOG_USER use_stderr=True notification_topics=notifications rpc_backend=rabbit amqp_durable_queues=False sql_connection=mysql: //nova :hequan@115.29.107.17 /nova image_service=nova.image.glance.GlanceImageService lock_path= /var/lib/nova/tmp osapi_volume_listen=0.0.0.0 vncserver_proxyclient_address=115.29.107.17 ##修改本机地址 vnc_keymap=en-us vnc_enabled=True vncserver_listen=0.0.0.0 novncproxy_base_url=http: //115 .29.107.17:6080 /vnc_auto .html [api_database] [barbican] [cells] [cinder] catalog_info=volumev2:cinderv2:publicURL [conductor] [cors] [cors.subdomain] [database] [ephemeral_storage_encryption] [glance] api_servers=115.29.107.17:9292 [guestfs] [hyperv] [image_file_url] [ironic] [keymgr] [keystone_authtoken] auth_uri=http: //115 .29.107.17:5000 /v2 .0 identity_uri=http: //115 .29.107.17:35357 admin_user=nova admin_password=hequan admin_tenant_name=services [libvirt] virt_type=qemu inject_password=False inject_key=False inject_partition=-1 live_migration_uri=qemu+tcp: //nova @%s /system cpu_mode=none vif_driver=nova.virt.libvirt.vif.LibvirtGenericVIFDriver [matchmaker_redis] [matchmaker_ring] [metrics] [neutron] service_metadata_proxy=True metadata_proxy_shared_secret=hequan url=http: //115 .29.107.17:9696 admin_username=neutron admin_password=hequan admin_tenant_name=services region_name=RegionOne admin_auth_url=http: //115 .29.107.17:5000 /v2 .0 auth_strategy=keystone ovs_bridge=br-int extension_sync_interval=600 timeout=30 default_tenant_id=default [osapi_v21] [oslo_concurrency] [oslo_messaging_amqp] [oslo_messaging_qpid] [oslo_messaging_rabbit] kombu_reconnect_delay=1.0 rabbit_host=115.29.107.17 rabbit_port=5672 rabbit_hosts=115.29.107.17:5672 rabbit_use_ssl=False rabbit_userid=guest rabbit_password=guest rabbit_virtual_host=/ rabbit_ha_queues=False heartbeat_timeout_threshold=0 heartbeat_rate=2 [oslo_middleware] [rdp] [serial_console] [spice] [ssl] [trusted_computing] [upgrade_levels] [vmware] [vnc] [workarounds] [xenserver] [zookeeper] [osapi_v3] enabled=False 1 2 3 4 5 6 7 8 9 10 11 12 [root@hequan~] #nova-manageservicelist [root@hequan~(keystone_admin)] #novahost-list +---------------+-------------+----------+ |host_name|service|zone| +---------------+-------------+----------+ |hequan.lol|consoleauth|internal| |hequan.lol|scheduler|internal| |hequan.lol|conductor|internal| |hequan.lol|compute|nova| |hequan.lol|cert|internal| [root@hequan~] #systemctlis-activelibvirtd.service active 本文转自 295631788 51CTO博客,原文链接:http://blog.51cto.com/hequan/1832697,如需转载请自行联系原作者