运行一个可用的nfs服务:
[[email protected] ~]# showmount -e 192.168.100.10
Export list for controller:
/nfs *
查看openstack当前nova的后端存储位置:
我修改了默认云主机存储路径
[[email protected] ~]# cat /etc/nova/nova.conf | grep instances_path | grep -v "#"
instances_path=/data/nova/instances
如果是下面这样:
[[email protected] ~]# cat /etc/nova/nova.conf | grep "instances_path"
#instances_path=$state_path/instances
那么就是默认路径:/var/lib/nova/instances
找到了路径就简单了,挂载nfs到后端路径:
[[email protected] ~]# mount -t nfs 192.168.100.10:/nfs /data/nova/instances/
设置目录属性:
[[email protected] ~]# chown -R nova:nova /data/nova/instances/
验证:
重启openstack-nova-compute服务
原文地址:https://www.cnblogs.com/ztxd/p/12241159.html
时间: 2024-10-08 21:17:06