内容简介:因为kolla比DevStack等方式要新一些,故最终选用kolla来安装。而kolla又分下面两种只是入门,就选择使用单点部署ubuntu 14.04 安装测试
因为kolla比DevStack等方式要新一些,故最终选用kolla来安装。而kolla又分下面两种
- kolla-kubernetes (不如ansible成熟)
- kolla-ansible
只是入门,就选择使用单点部署
系统环境
ubuntu 14.04 安装测试
步骤
主要根据参考中的 官方文档
来搭的环境,需要注意的是,
kolla-ansible和kolla两个项目切到origin/stable/queens等稳定版本
根据文档安装完成后,可以登陆 Horizon dashboard
、访问nova等api接口,但是创建虚机还是会报错,留作后面再排错。
遇到的问题
-
build image卡住没有进度
解决方法:添加 docker 源 /etc/docker/daemon.json {"registry-mirrors": ["https://a5aghnme.mirror.aliyuncs.com"]}
-
报错
ERROR:kolla.common.utils.base:The command '/bin/sh -c yum -y install centos-release-ceph-luminous centos-release-opstools centos-release-qemu-ev epel-release yum-plugin-priorities && yum clean all && rm -rf /var/cache/yum' returned a non-zero code: 1
-
docker-engine和docker.io冲突
解决方法:卸载docker.io yum remove docker.io docker-common
-
找不到镜像
Tag 7.0.0 not found in repository docker.io/kolla/centos-binary-cron 解决方法:修改globals.yml中的配置指定tag Dockerhub images are tagged as pike, master, etc. Please set: openstack_release: "pike" in your globals.yml
-
报错
Error starting daemon: error initializing graphdriver: \"/var/lib/docker\" contains several valid graphdrivers: devicemapper, overlay; Please cleanup or explicitly choose storage driver (-s <DRIVER>) 到/var/lib/docker根据情况,将下面的overlay或者devicemapper文件夹删掉即可。这种情况发生在使用采用dc/os安装后,原有的devicemapper模式修改成了overlay,但是docker同时只能支持一种存储模式。 不能删除/var/lib/docker/devicemapper 提示device busy时,可以umount /var/lib/docker/devicemapper后再删除
-
Kolla-build: command not found
pip install ./kolla
-
报错
https://packagecloud.io/grafana/stable/el/7/x86_64/repodata/repomd.xml: [Errno 14] HTTPS Error 302 - Found
-
docker python库报错
load_config() got an unexpected keyword argument 解决方法:不要按照官方文档安装python-docker-py pip install 'docker>=2.6,<3.0.0'
-
报错
pip install ./kolla时报错 Failed to fetch https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu/dists/xenial/InRelease Unable to connect to packagecloud-repositories.s3.dualstack.us-west-1.amazonaws.com:https: INFO:kolla.common.utils.zookeeper:W: Some index files failed to download. They have been ignored, or old ones used instead. 解决办法: pip install ./kolla --ignore-installed PyYAML
-
pip依赖不能重装
Cannot uninstall 'PyYAML'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.
-
部署中报错
问题: The conditional check 'config_json.changed | bool or rabbitmq_confs.changed 解决办法:kolla和kolla-ansible 都切到stable版本 问题: fatal: [localhost]: FAILED! => {"msg": "Unable to look up a name or access an attribute in template string ({{ inventory_hostname in groups['neutron-metering-agent'] }}).\nMake sure your variable name does not contain invalid characters like '-': argument of type 'StrictUndefined' is not iterable"} 解决办法: 直接禁用haproxy 问题: failed: [localhost] (item=/usr/share/kolla-ansible/ansible/roles/haproxy/templates/haproxy.cfg.j2) => {"changed": false, "item": "/usr/share/kolla-ansible/ansible/roles/haproxy/templates/haproxy.cfg.j2", "msg": "AnsibleUndefinedVariable: 'dict object' has no attribute 'glance-registry'"} 解决办法:直接禁用haproxy enable_haproxy: "no" 问题: rabbitmq_monitoring_password' is undefined" 问题: .docker.io/v2/: dial tcp: lookup registry-1.docker.io on 192.168.0.2:53: read udp 192.168.0.10:48758->192.168.0.2:53: i/o timeout\")\\n'"} 解决办法: 修改/etc/hosts添加dns服务器:nameserver 8.8.8.8 问题: 只有一张物理网卡 解决办法: ifconfig创建一个虚拟网卡 ifconfig eth0:0 192.168.10.10 up 问题: docker需要认证 解决办法: docker login命令先登陆 问题: TASK [neutron : Running Neutron bootstrap container] *************************** 卡住了
-
部署前检查报错
fatal: [localhost]: FAILED! => {"changed": false, "cmd": ["ip", "-4", "-o", "addr", "show", "dev", "eth0"], "delta": "0:00:00.043125", "end": "2019-01-10 13:48:41.975511", "failed_when_result": true, "rc": 0, "start": "2019-01-10 13:48:41.932386", "stderr": "", "stderr_lines": [], "stdout": "2: eth0 inet 192.168.16.88/20 brd 192.168.31.255 scope global noprefixroute eth0\\ valid_lft forever preferred_lft forever", "stdout_lines": ["2: eth0 inet 192.168.16.88/20 brd 192.168.31.255 scope global noprefixroute eth0\\ valid_lft forever preferred_lft forever"]}
-
登陆dabashboard提示证书不可用
原因:账号密码不正确 账号默认是admin,密码在cat /etc/kolla/passwords.yml|grep -i keystone_admin
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网
猜你喜欢:- BTC 主网节点搭建
- 4.2 集群节点初步搭建
- 本机搭建三节点k8s集群
- 基于Docker快速搭建多节点Hadoop集群
- 五分钟学会搭建自己的比特币全节点
- CentOS7 上搭建多节点 Elasticsearch集群
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。