Problem with init scripts and multiple instances

Bug #1156996 reported by Alexey Kopytov on 2013-03-19
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona Server
Status tracked in 5.7
5.1
High
Unassigned
5.5
High
Unassigned
5.6
High
Unassigned
5.7
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 Edit Tag help
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
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Related questions