Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to use Centos7 to quickly install and use openstack in Vmware

2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/02 Report--

This article mainly explains "how to use Centos7 to quickly install and use openstack in VMware". The explanation in this article is simple and clear, easy to learn and understand. Please follow the ideas of Xiaobian slowly to study and learn "how to use Centos7 to quickly install and use openstack in VMware"!

System environment:

Centos7.4, Alibaba Cloud download dvd version, Install the basic settings server version, It is relatively clean, Can find some pits.

Turn on virtual machine virtualization

Check that the virtual machine supports CPU VT function, and the return value is not 0 to indicate support. egrep --color 'vmx|svm' /proc/cpuinfo | wc -l

To facilitate testing, turn off the firewall

systemctl stop NetworkManager systemctl disable NetworkManager systemctl stop firewalldsystemctl disable firewalld/usr/sbin/setenforce 0 //SELINUX must be turned off (optional)

Software environment:

yum install epel-releaseyum install -y python-pipyum install -y git

Officially started:

1. Download devstack

git clone https://git.openstack.org/openstack-dev/devstack cd devstack#If the download is too slow, you can change it to git clone http://git.trystack.cn/openstack-dev/devstack #############

2. Create a stack user

Method 1: Create using scripts provided by devstack

./ tools/create-stack-user.shcd .. mv devstack /opt/stackchown -R stack:stack /opt/stack/devstack

Method 2: Create your own.

sudo useradd -s /bin/bash -d /opt/stack -m stackecho "stack ALL=(ALL) NOPASSWD: ALL" | sudo tee /etc/sudoers.d/stack

Create a local.conf

su stackcd /opt/stack/devstackcp samples/local.conf ./ vim local.conf[[local| localrc]]#ADMIN_PASSWORD=passwordSERVICE_TOKEN=$ADMIN_PASSWORDDATABASE_PASSWORD=$ADMIN_PASSWORDRABBIT_PASSWORD =$ADMIN_PASSWORDSERVICE_PASSWORD =$ADMIN_PASSWORD

4. Solve the problem of slow domestic network (optional operation, can skip)

Mirror source modification: my.oschina.net/haitaohu/blog/3084004, I use Ali's

pip source modification: my.oschina.net/haitaohu/blog/3084043, Ali used, Zhongke.. Sometimes errors are caused by the lack of a source, pay attention to your own verification

DevStack and OpenStack source code can be replaced with TryStack images, added to the local.conf configuration file in step 3

# use TryStack git mirrorGIT_BASE=http://git.trystack.cnNOVNC_REPO=http://git.trystack.cn/kanaka/noVNC.gitSPICE_REPO=http://git.trystack.cn/git/spice/spice-html5.git

DNS added

/etc/resolv.conf#Add 8.8.8#Restart service network restart

5. Installation and deployment

./ stack.sh

The execution time here is relatively long, wait patiently...

6. Test after installation

$ source devstack/openrc admin admin

$ keystone endpoint-list

$ nova service-list

$ neutron agent-list

$ senlin cluster-list

7. Access using a browser

http://** /dashboard

The username is admin and the password is set in the local.conf file.

Openstack installed successfully.

Possible problems encountered:

1.Unable to datermine DISTRO, can not continue.

Solution:

yum install redhat-lsb-core -y

2. Invalid path permissions, check whether to grant stack user sudo permission, if yes, check whether to operate in step 2, if not, grant/opt directory permission

chmod -R 777 /opt#because by default it is installed under the/opt directory

3. pip version problem

Solution: pip install --upgrade pip, remember pip -V to confirm after success

If you encounter a problem where the pip version is lower than version 9.0, but after upgrading pip19, you will go back as soon as you execute stack.sh

The reason is that the version will be checked during installation. If it is not within the specified range, it will be reinstalled. Later, the latest version will be required, resulting in an infinite loop.

vi /opt/stack/devstack/tools/cap-pip.txt

Show pip!= 8,

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report