立即注册 登录
About云-梭伦科技 返回首页

zhangli0912的个人空间 https://aboutyun.com/?20459 [收藏] [复制] [分享] [RSS]

日志

DevStack在ubuntu14.04上安装

热度 1已有 1115 次阅读2016-4-21 11:19 |个人分类:Devstack| devstack, openstack

网络环境如下

etho         Link encap: Ethernet HWaddr 00:0c:29:ca:01:c4

                inet addr: 192.168.202.132  Bcast: 192.168.202.255  Mask: 255.255.255.0

                inet6 addr:fe80::20c::29ff:feca:1e4/64 Scope:Link

                UP BROADCAST RUNNING MULTICAST   MTU:1500   Metric:1

                RX packets:28 errors:0 dropped:0  overruns:0  frame:0

                TX packets:33 errors:0 dropped:0  overruns:0 carrier:0

                collisions:0 txqueue len:1000

                RX bytes:3504 (3.5 KB)  TX  bytes:3250  (3.2  KB)

lo              Link encap:Local Loopback

                 inet addr:127.0.0.1   Mask:255.0.0.0

                 inet5 addr:  : :1/128  Scope:Host

                 UP LOOPBACK  RUNNING  MTU:65536   Metric:1

                RX packets:0 errors:0 dropped:0  overruns:0  frame:0

                TX packets:0 errors:0 dropped:0  overruns:0 carrier:0

                collisions:0 txqueue len:1000

                RX bytes:0 (0.0 KB)  TX  bytes:0  (0.0  KB)

浮动IP范围(虚拟网络编辑器→DHCP设置)

起始IP地址(S):192.168.202.128

结束IP地址(E):192.168.202.254

网关是(虚拟网络编辑器→NAT设置)

网关IP(G):192.168.202.2

1.设置ubuntu

配置前,先做个配置文件的备份:

cp /etc/apt/sources.list /etc/apt/sources.list_bak

配置新的源:

nano /etc/apt/sources.list

sources.list文件中将之前的源都注释掉,添加如下五行源:

deb http://cn.archive.ubuntu.com/ubuntu/ trusty main restricted universe multiverse

deb http://cn.archive.ubuntu.com/ubuntu/ trusty-security main restricted universe multiverse

deb http://cn.archive.ubuntu.com/ubuntu/ trusty-updates main restricted universe multiverse

deb http://cn.archive.ubuntu.com/ubuntu/ trusty-proposed main restricted universe multiverse

deb http://cn.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse

2.更新unpdate

apt-get update

3.同步一下时间

ntpdate ntp.sjtu.edu.cn

4.安装git

apt-get install git

5.下载devstack

cd /homegit clone http://git.trystack.cn/openstack-dev/devstack.git

6.目前Devstack脚本已经不支持直接使用root身份运行,需要创建stack用户运行

cd /home/devstack/tools/./create-stack-user.sh

7.修改Devstack目标权限,让stack用户可以运行

chown -R stack:stack /home/devstackchmod 777 /dev/pts/0

8.切换到stack用户下

su stackcd /home/devstack

9.进入devstack目录下,创建local.conf文件

nano local.conf

添加如下内容

[[local|localrc]]# Define images to be automatically downloaded during the DevStack built process.DOWNLOAD_DEFAULT_IMAGES=FalseIMAGE_URLS="http://download.cirros-cloud.net/0.3.4/cirros-0.3.4-x86_64-disk.img" #change github to trystackGIT_BASE=${GIT_BASE:-http://git.trystack.cn}NOVNC_REPO=${NOVNC_REPO:-http://git.trystack.cn/kanaka/noVNC.git} # CredentialsDATABASE_PASSWORD=passADMIN_PASSWORD=passSERVICE_PASSWORD=passSERVICE_TOKEN=passRABBIT_PASSWORD=pass#FLAT_INTERFACE=eth0 HOST_IP=192.168.202.132  # Enabling Neutron (network) Servicedisable_service n-netenable_service q-svcenable_service q-agtenable_service q-dhcpenable_service q-l3enable_service q-metaenable_service q-meteringenable_service neutron ## Neutron optionsQ_USE_SECGROUP=TrueFLOATING_RANGE="192.168.202.0/24"FIXED_RANGE="10.0.0.0/24"Q_FLOATING_ALLOCATION_POOL=start=192.168.202.133,end=192.168.202.143PUBLIC_NETWORK_GATEWAY="192.168.202.2"Q_L3_ENABLED=TruePUBLIC_INTERFACE=eth0Q_USE_PROVIDERNET_FOR_PUBLIC=TrueOVS_PHYSICAL_BRIDGE=br-exPUBLIC_BRIDGE=br-exOVS_BRIDGE_MAPPINGS=public:br-ex # VLAN configuration.Q_PLUGIN=ml2ENABLE_TENANT_VLANS=True # Work offline#OFFLINE=True# Reclone each timeRECLONE=yes # Logging# -------# By default ``stack.sh`` output only goes to the terminal where it runs. It can# be configured to additionally log to a file by setting ``LOGFILE`` to the full# path of the destination log file. A timestamp will be appended to the given name.LOGFILE=/opt/stack/logs/stack.sh.logVERBOSE=TrueLOG_COLOR=TrueSCREEN_LOGDIR=/opt/stack/logs

10.运行

./stack.sh

 11.出现

登陆网址,用户名和密码表明安装成功

12.验证

参考陈沙克日志http://www.chenshake.com/install-ubuntu-14-04-devstack/


路过

雷人

握手
1

鲜花

鸡蛋

刚表态过的朋友 (1 人)

评论 (0 个评论)

facelist doodle 涂鸦板

您需要登录后才可以评论 登录 | 立即注册

关闭

推荐上一条 /2 下一条