Problem with init scripts and multiple instances

Bug #1156996 reported by Alexey Kopytov
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona Server moved to https://jira.percona.com/projects/PS
Status tracked in 5.7
5.1
Won't Fix
High
Unassigned
5.5
Triaged
High
Unassigned
5.6
Triaged
High
Unassigned
5.7
Triaged
High
Unassigned

Bug Description

Converting https://answers.launchpad.net/percona-server/+question/224544 to a bug report:

"
Hi,

I have a question about Percona server (5.5). When upgrading the Percona debs via Percona repository I see that the package adds back /etc/rc*.d links, and starts mysql. This is probably nice in most situations but in a cluster environment it's not very good to have either of these things. MySQL is started by the cluster. And since startup links are created MySQL will try to start on secondary node also and so on.

So is there a preferred way of handling a situation like mine?
"

Tags: pkg
Revision history for this message
Muhammad Irfan (muhammad-irfan) wrote :

I am able to reproduce the issue on debian 7 with Percona Server 5.1/5.5/5.6. Installed PS packages from percona repo and during upgrade i found links are re-created.

# apt-get install percona-server-server-5.5 percona-server-client-5.5 percona-server-common-5.5

* Verified from rc.d scripts and found mysql is added once i installed PS 5.5 from Percona repository.
# ls -la /etc/rc* | grep mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:18 K02mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:18 K02mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:18 S17mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:18 S17mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:18 S17mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:18 S17mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:18 K02mysql -> ../init.d/mysql

* Removed mysql service from rc.d directory to prevent auto-start of mysql service on OS reboot.
# update-rc.d -f mysql remove
update-rc.d: using dependency based boot sequencing

# ls -la /etc/rc* | grep mysql

Upgraded to Percona Server 5.6 and found links are re-created.

* Removed PS 5.5 packages.
# apt-get --purge remove percona-server-server-5.5 percona-server-client-5.5 percona-server-common-5.5

* Started upgrade to PS 5.6
# apt-get install percona-server-server-5.6 percona-server-common-5.6 percona-server-client-5.6

# ls -la /etc/rc* | grep mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:35 K02mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:35 K02mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:35 S17mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:35 S17mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:35 S17mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:35 S17mysql -> ../init.d/mysql
lrwxrwxrwx 1 root root 15 Dec 24 06:35 K02mysql -> ../init.d/mysql

So, mysql daemon script added after upgrade implicitly to rc.d directory.

tags: added: pkg
Revision history for this message
Muhammad Irfan (muhammad-irfan) wrote :

I verified that links are created for Percona Server 5.7 too for auto start of MySQL service on Debian 7.

Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PS-643

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

Bug watches keep track of this bug in other bug trackers.