简体   繁体   中英

Restart of Nova services in Devstack

I have tried restarting the Nova services after some modifications in nova.conf file.

While trying to restart I am getting the error that unrecognized service.

I know that way to restart nova services in devstack was different.

Someone provide me the clear way for doing the same.

Another way: screen -x to list available screen sessions. ctrl+a , " to get list of available windows. Go to n-cpu and stop it with ctrl+c, than press arrow up to get last command in terminal and press enter to run it. Depends on you conf changes you will be need to restart other services (the start with 'n-', for example, n-api, n-cond and so one).

I'm not sure if it is ok to recommend URC channel on the StackOverflow, but also there is #openstack-nova channel in IRC (on freenode server). It could be useful (and faster way to get answer) to ask there, if you have problems with something nova-related.

I found the way for same:

   * First cd to folder devstack

   * You can find the file ./rejoin_stack.sh

   * Execute the same.

   * It will be executed and screen will be opened for access.

   * press ctrl + a + shift + '

   * Then it will be listing the running services

   * can move to service which needs to be stopped by scrolling towards it.

   * on the service which is needs to be stopped press enter

   * then press ctrl + c , it will stop the service

   * then press up arrow key to run the service again

   * service will be restarted successfully.

Not exactly a way of restarting Nova, but could help, too. It's a hack, though.

The ./rejoin_stack.sh has been removed from DevStack , and even screen does not seem to work for me; it does not show the menu and does not accept the CTRL sequences (I blame my running DevStack in Docker for it, but not important).

So this is where the hack comes handy. All DevStack services are restarted by running ./unstack.sh and ./stack.sh , but during that time, nova.conf modifications are dropped. The hack is to modify /devstack/lib/nova which works as a template for nova.conf , so that after rerunning ./stack.sh the nova.conf contains the intended values.

Newer versions of DevStack runs it's services as systemd unit files so, you can use systemctl to manage them.

List all services:

sudo systemctl list-units devstack@*

Restart any individual service (replace n-cpu.service with the service name):

sudo systemctl restart devstack@n-cpu.service

Restart all services.

sudo systemctl restart devstack@*

Refer OpenStack Documentation for more details.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM