centos7安装KVM管理工具WebVirtMgr
【摘要】 测试WebVirtMgr
安装WebVirtMgr,为后续其他测试做准备
#centos7安装
yum -y install net-tools
rpm -Uvh http://nginx.org/packages/centos/7/noarch/RPMS/nginx-release-centos-7-0.el7.ngx.noarch.rpm
yum install -y nginx
#启动,重启,开机自启nginx,运行状态
systemctl start nginx
systemctl restart nginx
systemctl enable nginx
systemctl status nginx
#查看当前所有tcp端口
netstat -ntlp
#浏览器访问ip
#安装相关依赖
yum install -y qemu-kvm libvirt libvirt-python libguestfs-tools virt-install virt-manager python-virtinst libvirt-client virt-viewer qemu-kvm-tool
yum -y install git python-pip libvirt-python libxml2-python python-websockify supervisor gcc python-devel
systemctl start libvirtd.service
systemctl enable libvirtd.service
#安装python扩展
pip install numpy -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
#若报错bash: pip: 未找到命令...则:(
wget https://bootstrap.pypa.io/pip/2.7/get-pip.py
python get-pip.py
)
mkdir -p /data/kvm
git clone git://github.com/retspen/webvirtmgr.git 或 git clone https://github.com/retspen/webvirtmgr.git
#安装django环境
cd webvirtmgr
pip install -r requirements.txt -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
# 初始化环境
./manage.py syncdb
#Yes,配置管理员用户
Would you like to create one now? (yes/no): yes
Username (leave blank to use 'root'): root
Email address:
Password:
Password (again):
Superuser created successfully.
# 配置Django 静态页面
./manage.py collectstatic
输入Yes即可
#继续添加管理员
./manage.py createsuperuser
#启动WebVirMgr:浏览器IP:8000
./manage.py runserver 0.0.0.0:8000
#后续更新
【版权声明】本文为华为云社区用户原创内容,转载时必须标注文章的来源(华为云社区)、文章链接、文章作者等基本信息, 否则作者和本社区有权追究责任。如果您发现本社区中有涉嫌抄袭的内容,欢迎发送邮件进行举报,并提供相关证据,一经查实,本社区将立刻删除涉嫌侵权内容,举报邮箱:
cloudbbs@huaweicloud.com
- 点赞
- 收藏
- 关注作者
评论(0)