底层共享存储在迁移配置:
每台compute 节点都需要配置一下
让nova用户可以登陆
usermod -s /bin/bash nova
设置nova 用户密码
echo "nova"|passwd --stdin nova
切换nova并生成key同步其它节点上
su - nova
ssh-keygen -t rsa -N '' -f ~/.ssh/id_rsa
ssh-copy-id nova@x.x.x.x```
没有做上面的处理在更改配置或者热迁移将会报如下错误:
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server six.reraise(self.type_, self.value, self.tb)
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 122, in decorated_function
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server return function(self, context, *args, **kwargs)
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 216, in decorated_function
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server kwargs['instance'], e, sys.exc_info())
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server self.force_reraise()
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server six.reraise(self.type_, self.value, self.tb)
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 204, in decorated_function
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server return function(self, context, *args, **kwargs)
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 3856, in resize_instance
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server self.instance_events.clear_events_for_instance(instance)
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server File "/usr/lib64/python2.7/contextlib.py", line 35, in __exit__
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server self.gen.throw(type, value, traceback)
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 6632, in _error_out_instance_on_exception
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server raise error.inner_exception
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server ResizeError: Resize error: not able to execute ssh command: Unexpected error while running command.
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server Command: ssh -o BatchMode=yes 172.16.20.1 mkdir -p /gpfs/nova//instances/e946ffb3-c797-42c5-b7ab-16aa8ceab84d
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server Exit code: 255
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server Stdout: u''
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server Stderr: u'Host key verification failed.\r\n'
2018-04-11 14:19:34.574 10770 ERROR oslo_messaging.rpc.server