Skip to content

Instantly share code, notes, and snippets.

@panperla
Last active November 14, 2016 14:44
Show Gist options
  • Save panperla/4a85cd4774474a9ce27a98ea2aef9dbe to your computer and use it in GitHub Desktop.
Save panperla/4a85cd4774474a9ce27a98ea2aef9dbe to your computer and use it in GitHub Desktop.
Supervisor installation and setup for galera node - ubuntu 16.04

Supervisor installation for galera node

  1. We need to install supervisor daemon
  2. Create /etc/supervisor/conf.d/mysql.conf config file
  3. Restart supervisor
apt-get install supervisor -y
echo "[program:mysqld]
command=/usr/bin/pidproxy /var/run/mysqld/mysqld.pid /usr/sbin/mysqld --pid-file=/var/run/mysqld/mysqld.pid
stdout_logfile=/var/log/supervisor/%(program_name)s.log
stderr_logfile=/var/log/supervisor/%(program_name)s.log
autorestart=true
autostart=true
">/etc/supervisor/conf.d/mysql.conf
/etc/init.d/mysql stop
/etc/init.d/supervisor restart

NOTE - please make sure mysql is not being in the constant loop of restarting it might happend when we launch supervisor while mysqld is up and running

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment