openstack单节点离线安装_第1页
openstack单节点离线安装_第2页
openstack单节点离线安装_第3页
openstack单节点离线安装_第4页
openstack单节点离线安装_第5页
已阅读5页,还剩6页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

openstack单节点离线安装.配置虚拟机网络vi/etc/sysconfig/network-scripts/ifcfg-网卡名TYPE=Ethernet#BOOTPROTO=dhcpBOOTPROTO=staticDEFROUTE=yesPEERDNS=yesPEERROUTES=yesNAME=eno16777736DEVICE=eno16777736ONBOOT=yesIPADDR=00NETMASK=GATEWAY=DNS1=9DNS2=14重启网络服务/etc/init.d/networkrestart.配置离线软件仓库vi/etc/yum.repos.d/openstack-j.repo[openstack-j]name=openstack-jbaseurl=HYPERLINKfile:///opt/openstack/gpgcheck=0enabled=1yumcleanallyummakecache.配置hosts文件vi/etc/hosts51controller.安装openstack安装脚本:安装脚本:selinuxyuminstallopenstack-selinuxNTP安装命令:yuminstallntp添加开机启动并重启服务:systemctlenablentpd.servicesystemctlrestartntpd.service数据库:yuminstallmariadbmariadb-serverMySQL-pythonyuminstallmariadbmariadb-serverMySQL-python修改配置文件:vi/etc/f[mysqld]jnd-addres,开机-启动并重启噩务n:nodbsyntedb_file_pele_marjsdb.servicecystemxrt-sseavtrmuitfa_beneiviceci设置轴库密幽NAMESutf8'character-set-server=utf8mysql_secure_installation消息队列:yuminstallrabbitmq-server添加开机启动并重启服务:systemctlenablerabbitmq-server.servicesystemctlstartrabbitmq-server.service设置密码:rabbitmqctlchange_passwordguestRABBIT_PASSKeystone:数据库中添加keystone:mysql-uroot-pCREATEDATABASEkeystone;生成A随机秘钥IVILEGESONkeystone.*TO'keystone'@'localhost'IDENTIFIEDBYGRAt机秘^PRIVILEGESONkeystone.*TO'keystone'@'%'IDENTIFIEDBYopYSTONS_DBPASSn14a3a84da9cb2808853安装命令:yuminstallopenstack-keystonepython-keystoneclient修改配置文件:vi/etc/keystone/keystone.conf[DEFAULT]admin_token=xxxxxxxxxxxxxxxxxxxxxxxkeystone-managepki_setup--keystone-userkeystone--keystone-groupkeystonecdiOWba-sekeystone:keystone/var/log/keystone同步步步数据库iemy3qe//keytonneetcYSTysNEne/BPASS@controller/keystonechmod-R6-rwx/etc/keystone/sslsrevo/fei]n/sh-c"keystone-managedb_sync"keystone启(动服务:eystone.contrib.revoke.backends.sql.Revoke[token]provider=viders.uuid.Providerdriver=keystone.token.persistence.backends.sql.Token

systemctlenableopenstack-keystone.servicesystemctlrestartopenstack-keystone.service(crontab-l_-ukeystone2>&1|grep-qtoken_flush)||echo'@hourly/usr/bin/keystone-managetoken_flush>/var/log/keystone/keystone-tokenflush.log2>&1t>>S_SERspICE_c6onElk=ystonexxxxxxxxxxxxxxxxxexportOS_SERVICE_ENDPOINT=http:〃controller:35357/v2.0创建用户:keystonetenant-create--nameadmin--description"AdminTenant"keystoneuser-create--nameadmin--passADMIN_PASS--emailEMAIL_ADDRESS创建岫文件尸6ate--nameadmin湎O黑ndpSW湎O黑ndpSW制RO=eDKteD--SS_SPAVSC$_SyStOOeNslervice-list|awk'/identity/{print62po-tpU_A:UlH_UtR/Ahitnt)r:O/le0r:5tr0O/v:35357/v2'naiurlhttp://controller:5000/v2.0--adminurlhttp://controller:35357/v2.0--regionregionOneGlance:添加镜像数据库:mysql-uroot-pCREATEDATABASEglance;GRANTALLPRIVILEGESONglance.*TO'glance'@'localhost'IDENTIFIEDBY'GLANCE_DBPASS';GRANTALLPRIVILEGESONglance.*TO'glance'@'%'IDENTIFIEDBY'GLANCE_DBPASS';添加用户:sourceadmin-openrc.shkeystoneuser-create--nameglance--passGLANCE_PASSkeystoneuser-role-add--userglance--tenantservice--roleadminkeystoneservice-create--nameglance--typeimage--description"OpenStackImageService"keystoneendpoint-create--service-id$(keystoneservice-list|awk'/image/{print$2}')--publicurlhttp://controller:9292--internalurlhttp://controller:9292--adminurlhttp://controller:9292--regionregionOne安装镜像服务:yuminstallopenstack-glancepython-glanceclient修改配置文件:vi/etc/glance/glance-api.conf[DEFAULT]...notification_driver=noop[database]connection=mysql://glance:GLANCEDBPASS@controller/glancekeystonetenant-create--nameadmin--description"AdminTenant"keystoneuser-create--nameadmin--passADMIN_PASS--emailEMAIL_ADDRESSkeystonerole-create--nameadminkeystoneuser-role-add--useradmin--tenantadmin--roleadminkeystonetenant-create--nameservice--description"ServiceTenant"keystoneservice-create--namekeystone--typeidentity--description"OpenStackIdentity"keystoneendpoint-create--service-id$(keystoneservice-list|awk'/identity/{print$2}')--publicurlhttp://controller:5000/v2.0--internalurlhttp://controller:5000/v2.0--adminurlhttp://controller:35357/v2.0--regionregionOne创建秘钥文件:viadmin-openrc.shexportOS_TENANT_NAME=adminexportOS_USERNAME=adminexportOS_PASSWORD=ADMIN_PASSexportOS_AUTH_URL=http://controller:35357/v2.0unsetOS_SERVICE_TOKENOS_SERVICE_ENDPOINTGlance:添加镜像数据库:mysql-uroot-pCREATEDATABASEglance;GRANTALLPRIVILEGESONglance.*TO'glance'@'localhost'IDENTIFIEDBY'GLANCE_DBPASS';GRANTALLPRIVILEGESONglance.*TO'glance'@'%'IDENTIFIEDBY'GLANCE_DBPASS';添加用户:sourceadmin-openrc.shkeystoneuser-create--nameglance--passGLANCE_PASSkeystoneuser-role-add--userglance--tenantservice--roleadminkeystoneservice-create--nameglance--typeimage--description"OpenStackImageService"keystoneendpoint-create--service-id$(keystoneservice-list|awk'/image/{print$2}')--publicurlhttp://controller:9292--internalurlhttp://controller:9292--adminurlhttp://controller:9292--regionregionOne安装镜像服务:yuminstallopenstack-glancepython-glanceclient修改配置文件:vi/etc/glance/glance-api.conf[DEFAULT]...notificationdriver=noop[database]connection=mysql://glance:GLANCE_DBPASS@controller/glance[keystone_authtoken]...auth_uri=http://controller:5000/v2.0identity_uri=http://controller:35357admin_tenant_name=serviceadmin_user=glanceadmin_password=GLANCE_PASS[paste_deploy]...flavor=keystone[glance_store]...default_store=filefilesystem_store_datadir=/var/lib/glance/images/vi/etc/glance/glance-registry.conf[DEFAULT]...notification_driver=noop[database]connection=mysql://glance:GLANCE_DBPASS@controller/glance[keystone_authtoken]...auth_uri=http://controller:5000/v2.0identity_uri=http://controller:35357admin_tenant_name=serviceadmin_user=glanceadmin_password=GLANCE_PASS[paste_deploy]...flavor=keystone同步数据库:su-s/bin/sh-c"glance-managedb_sync"glance启动服务:systemctlenableopenstack-glance-api.serviceopenstack-glance-registry.servicesystemctlrestartopenstack-glance-api.serviceopenstack-glance-registry.service验证操作:mkdir/tmp/imageswget-P/tmp/images1/other/cirros/cirros-0.3.4-x86_64-disk.imgsourceadmin-openrc.shglanceimage-create--name"cirros-0.3.3-x86_64"--file/tmp/images/cirros-0.3.4-x86_64-disk.img--disk-formatqcow2--container-formatbare--is-publicTrue--progressglanceimage-listrm-rf/tmp/imagesNOVA控制服务添加nova数据库:mysql-uroot-pCREATEDATABASEnova;GRANTALLPRIVILEGESONnova.*TO'nova'@'localhost'IDENTIFIEDBY'NOVA_DBPASS';GRANTALLPRIVILEGESONnova.*TO'nova'@'%'IDENTIFIEDBY'NOVA_DBPASS';添加nova用户:sourceadmin-openrc.shkeystoneuser-create--namenova--passNOVA_PASSkeystoneuser-role-add--usernova--tenantservice--roleadminkeystoneservice-create--namenova--typecompute--description"OpenStackComputekeystoneendpoint-create\--service-id$(keystoneservice-list|awk'/compute/{print$2}')\--publicurlhttp://controller:8774/v2/%\(tenant_id\)s\--internalurlhttp://controller:8774/v2/%\(tenant_id\)s\--adminurlhttp://controller:8774/v2/%\(tenant_id\)s\--regionregionOne安装novayuminstallopenstack-nova-apiopenstack-nova-certopenstack-nova-conductoropenstack-nova-consoleopenstack-nova-novncproxyopenstack-nova-schedulerpython-novaclient修改配置文件vi/etc/nova/nova.conf[DEFAULT]rpc_backend=rabbitrabbit_host=controllerrabbit_password=RABBIT_PASSmy_ip=YOUIPauth_strategy=keystonevncserver_listen=YOUIPvncserver_proxyclient_address=YOUIP[database]connection=mysql://nova:NOVA_DBPASS@controller/nova[keystone_authtoken]auth_uri=http://controller:5000/v2.0identity_uri=http://controller:35357admin_tenant_name=serviceadmin_user=novaadmin_password=NOVA_PASS[glance]host=controller同步数据库:su-s/bin/sh-c"nova-managedbsync"nova启动服务:systemctlenableopenstack-nova-api.servicesystemctlstartopenstack-nova-api.servicesystemctlenableopenstack-nova-cert.servicesystemctlstartopenstack-nova-cert.servicesystemctlenableopenstack-nova-consoleauth.servicesystemctlstartopenstack-nova-consoleauth.servicesystemctlenableopenstack-nova-scheduler.servicesystemctlstartopenstack-nova-scheduler.servicesystemctlenableopenstack-nova-conductor.servicesystemctlstartopenstack-nova-conductor.servicesystemctlenableopenstack-nova-novncproxy.servicesystemctlstartopenstack-nova-novncproxy.serviceNOVA计算服务安装软件包yuminstallopenstack-nova-computesysfsutilslibvirt-daemon-config-nwfilter.x86_64yuminstallopenstack-nova-computesysfsutilslibvirt-daemon-config-nwfilter.x86_64vi/etc/nova/nova.conf[DEFAULT]rpc_backend=rabbitrabbit_host=controllerrabbit_password=RABBIT_PASSauth_strategy=keystonemy_ip=MANAGEMENT_INTERFACE_IP_ADDRESSvnc_enabled=Truevncserver_listen=vncserver_proxyclient_address=MANAGEMENT_INTERFACE_IP_ADDRESSnovncproxy_base_url=http://controller:6080/vnc_auto.html[keystone_authtoken]auth_uri=http://controller:5000/v2.0identity_uri=http://controller:35357admin_tenant_name=serviceadmin_user=novaadmin_password=NOVA_PASS[glance]host=controller[libvirt]virt_type=qemu重启服务systemctlenablelibvirtd.serviceopenstack-nova-compute.servicesystemctlstartlibvirtd.serviceopenstack-nova-compute.serviceNOVA-NETWORK网络节点:vi/etc/nova/nova.conf[DEFAULT]network_api_class=work.api.APIsecuritygroupapi=novasystemctlrestartopenstack-nova-api.servicesystemctlrestartopenstack-nova-scheduler.servicesystemctlrestartopenstack-nova-conductor.service计算

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论