• Home
  • About Us
  • Contact
  • Privacy Policy

LinuxAdmin.io

  • Home
  • Tutorials
    • System Administration
    • Linux Tutorials
    • Web Hosting
    • WordPress
    • Virtualization
    • Troubleshooting
    • OpenStack

How To Upgrade Supervisord In CentOS 6

supervisord installation

Supervisord is a simple system for process management and monitoring.  It can start processes or restart them when they crash. The repositories for CentOS 6 for supervisor are quite old (version 2.x) which do not contain the latest features.  You can read more on the project’s website.  If you already have an existing installation installed through yum this guide provides the steps to update it to a more recent version.  We are going to remove the old package and install a new one through python’s pip.

Remove the Old Files

Stop the currently running version

/etc/init.d/supervisord stop

Make a backup directory to hold the temporary files

mkdir ~/supervisord-backup

Copy the configuration file

cp /etc/supervisord.conf supervisvor-backup/

Copy the init script

cp /etc/init.d/supervisord supervisvor-backup/

Remove the yum package

yum -y remove supervisor

Install The New Supervisord

Install pip (if you do not already have it)

yum -y install python-pip

Install the updated version through pip

pip install supervisor

Put the configuration file back into place

cp supervisvor-backup/supervisord.conf /etc/supervisord.conf

Put the init script back into place

cp  supervisvor-backup/supervisord /etc/init.d/supervisord

Go ahead and restart the script

/etc/init.d/supervisord restart

Configuration Changes after upgrade

I ran into a couple errors when updating the package. After doing above the first error I got was:

# supervisorctl
unix:///var/tmp/supervisor.sock refused connection

This was resolved by adding the following to /etc/supervisor.conf:

[unix_http_server]
file=/var/tmp/supervisor.sock

I also received this error:

# supervisorctl
Sorry, supervisord responded but did not recognize the supervisor namespace commands that supervisorctl uses to control it. Please check that the [rpcinterface:supervisor] section is enabled in the configuration file (see sample.conf).

This was resolved by adding the following to /etc/supervisor.conf:

[rpcinterface:supervisor]
supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface

You should now have completed the upgrade now have the most recent version running on your server.

 

Jul 11, 2017LinuxAdmin.io
0 0 vote
Article Rating
How To Configure A Default Gateway on CentOSBash Scripting Introduction
You Might Also Like
 
Virsh KVM Commands For Management
 
SELinux Introduction In CentOS 7
Subscribe
Notify of
guest
guest
3 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
imr
imr
5 years ago

super thank you !!!
finally nailed that stupid sorry error

-1
Reply
LinuxAdmin.io
Author
LinuxAdmin.io
5 years ago
Reply to  imr

Glad to help!!

1
Reply
fyrye
fyrye
4 years ago

For those installing supervisord 3.x on CentOS 6. Instead of copying /etc/supervisord.conf for the default configuration settings, make a separate backup of your custom configuration settings. Then after running pip install supervisor, you can run sudo echo_supervisord_conf > /etc/supervisord.conf This will fix the issues mentioned in the “Changes After Upgrade” section, as well as remove the invalid configuration settings from the CentOS 6 supervisord 2.x configuration.

0
Reply
5 years ago 3 Comments Linux System Administration, Linux Tutorials, PHP, Web Hosting centos, linux5,019
Recent Posts
  • Laravel Installation Guide For CentOS
  • Openstack Services Explanation And Overview
  • OSSEC Intrusion Detection Installation On Centos 7
  • Configure ProFTPd for SFTP on CentOS
  • How To Check And Repair MyISAM Tables In MySQL
Most Commented
Hot Clone Linux Server with Rsync
Hot Clone A CentOS Server With Rsync
14 Comments
ngx_cache_purge module
Install The ngx_cache_purge Module In Nginx
8 Comments
piwik-nginx
Piwik Analytics on Nginx
8 Comments
Tags
linuxcentosLinux Performance Tuningsysadminkvmnetworkingmemcachedanalyticssystemd
About

We love Linux and are dedicated to creating Linux administration tutorials for System Administrators since 2016.

Most Viewed
Default Gateway
How To Configure A Default Gateway on CentOS
62,983 views
Zend Opcache
Setup and Optimize Zend OpCache
46,714 views
Install ffmpeg
FFMpeg Install On CentOS 7
20,909 views
Archives
Email subscription

Sign up for our newsletter to receive the latest news and event postings.

2018 © LinuxAdmin.io
wpDiscuz