What are the best practises for restarting mysql and rails servers on Cloud66, to minimise the possibilities of user's seeing errors?
Background Sometimes logging into a server via ssh, there is a message system restart required Sometimes there are security upgrades that require a restart.
Current Approach
My current approach for mysql is to:
- Put the app into maintenance mode
- use bluepill commands to stop the mysql
- restart server with "shutdown -r now" command
- After server has booted up, confirm that bluepill mysql service is running
- put the app back into non-maintenance mode
My current approach for rails servers is to:
- use bluepill commands to stop the web service (this is due to the fact that I have multiple web servers so the app can keep on running using alternative web servers)
- restart server with "shutdown -r now" command
- After server has booted up, confirm that bluepill web service is running
How do you do it?