[MXS-49] init script missing from MaxScale 1.0.5 RPM after upgrade Created: 2015-03-18  Updated: 2015-05-06  Resolved: 2015-03-19

Status: Closed
Project: MariaDB MaxScale
Component/s: None
Affects Version/s: 1.0.5
Fix Version/s: 1.1.0

Type: Bug Priority: Minor
Reporter: Kolbe Kegel (Inactive) Assignee: markus makela
Resolution: Won't Fix Votes: 0
Labels: None
Environment:

CentOS 6



 Description   

Apparently the 1.0.5 RPM for CentOS 6 doesn't include an init script?

[root@max1 ~]# service maxscale status
maxscale: unrecognized service
[root@max1 ~]# ls /etc/init.d/maxscale*
/etc/init.d/maxscale.rpmorig

[root@max1 ~]# rpm -ql maxscale
/usr/local/skysql/maxscale
/usr/local/skysql/maxscale/COPYRIGHT
/usr/local/skysql/maxscale/LICENSE
/usr/local/skysql/maxscale/README
/usr/local/skysql/maxscale/SETUP
/usr/local/skysql/maxscale/bin
/usr/local/skysql/maxscale/bin/maxadmin
/usr/local/skysql/maxscale/bin/maxkeys
/usr/local/skysql/maxscale/bin/maxpasswd
/usr/local/skysql/maxscale/bin/maxscale
/usr/local/skysql/maxscale/etc
/usr/local/skysql/maxscale/etc/MaxScale_template.cnf
/usr/local/skysql/maxscale/lib
/usr/local/skysql/maxscale/lib/liblog_manager.so
/usr/local/skysql/maxscale/lib/libquery_classifier.so
/usr/local/skysql/maxscale/log
/usr/local/skysql/maxscale/maxscale
/usr/local/skysql/maxscale/maxscale.conf
/usr/local/skysql/maxscale/modules
/usr/local/skysql/maxscale/modules/libHTTPD.so
/usr/local/skysql/maxscale/modules/libMySQLBackend.so
/usr/local/skysql/maxscale/modules/libMySQLClient.so
/usr/local/skysql/maxscale/modules/libcli.so
/usr/local/skysql/maxscale/modules/libdebugcli.so
/usr/local/skysql/maxscale/modules/libfwfilter.so
/usr/local/skysql/maxscale/modules/libgaleramon.so
/usr/local/skysql/maxscale/modules/libhintfilter.so
/usr/local/skysql/maxscale/modules/libmaxscaled.so
/usr/local/skysql/maxscale/modules/libmysqlmon.so
/usr/local/skysql/maxscale/modules/libnamedserverfilter.so
/usr/local/skysql/maxscale/modules/libndbclustermon.so
/usr/local/skysql/maxscale/modules/libqlafilter.so
/usr/local/skysql/maxscale/modules/libreadconnroute.so
/usr/local/skysql/maxscale/modules/libreadwritesplit.so
/usr/local/skysql/maxscale/modules/libregexfilter.so
/usr/local/skysql/maxscale/modules/libtee.so
/usr/local/skysql/maxscale/modules/libtelnetd.so
/usr/local/skysql/maxscale/modules/libtestfilter.so
/usr/local/skysql/maxscale/modules/libtestroute.so
/usr/local/skysql/maxscale/modules/libtopfilter.so
/usr/local/skysql/maxscale/mysql
/usr/local/skysql/maxscale/mysql/errmsg.sys



 Comments   
Comment by Timofey Turenko [ 2015-03-19 ]

init script is created by postinst script:

[root@node1 ~]# rpm -qp --scripts maxscale-1.0.5-unstable.rpm
preinstall program: /bin/sh
postinstall scriptlet (using /bin/sh):
#!/bin/sh

install /usr/local/skysql/maxscale/maxscale /etc/init.d/
install /usr/local/skysql/maxscale/maxscale.conf /etc/ld.so.conf.d/
/sbin/ldconfig
preuninstall program: /bin/sh
postuninstall scriptlet (using /bin/sh):
#!/bin/sh
rm /etc/init.d/maxscale
rm /etc/ld.so.conf.d/maxscale.conf

Comment by Timofey Turenko [ 2015-03-19 ]

works for me.

Was the package installed properly?

Comment by Kolbe Kegel (Inactive) [ 2015-03-19 ]

Apparently it's only an issue for an upgrade.

[root@max1 ~]# rpm -i http://downloads.mariadb.com/software/MaxScale/maxscale/RPM/rhel6/maxscale-1.0.4-stable.rpm
[root@max1 ~]# ls /etc/init.d/maxscale*
/etc/init.d/maxscale
/etc/init.d/maxscale.bak
[root@max1 ~]# rpm -Uvh http://downloads.mariadb.com/software/MaxScale/maxscale/RPM/rhel6/maxscale-1.0.5-stable.rpm
Retrieving http://downloads.mariadb.com/software/MaxScale/maxscale/RPM/rhel6/maxscale-1.0.5-stable.rpm
Preparing...                ########################################### [100%]
   1:maxscale               ########################################### [100%]
[root@max1 ~]# ls /etc/init.d/maxscale*
/etc/init.d/maxscale.bak

Comment by Timofey Turenko [ 2015-03-19 ]

The reason is:

  • /etc/init.d/maxscale was a part of the package before 1.0.6
  • in 1.0.6 this file is created by %post script
  • when RPM tool performs package upgrade it install a new package, run %post and then remove files that belong to previous version but do not belong to the new one - as a result /etc/init.d is deleted.

Yes, it is a bug, but it is not a blocker ('yum reinstall maxscale' and 'rpm -i --force ...' fixes problem).

Comment by Kolbe Kegel (Inactive) [ 2015-03-19 ]

I find it troubling that you re-classify these kinds of bugs as "minor". This bug should be a blocker. We should block new releases until this bug is fixed. If it is already fixed, that's great! If it's not, we must not issue new releases of the product until the issue is resolved. Forcing an atypical upgrade path for the software is not an acceptable long-term workaround.

I'm not using 1.0.6 here at all, so I am not sure how it fits into the picture.

Comment by Kolbe Kegel (Inactive) [ 2015-03-19 ]

Also, please correct the "Resolution" so that this bug is not labeled "Not a Bug". Thanks.

Comment by Timofey Turenko [ 2015-03-19 ]

simple workaround:
'yum reinstall maxscale' and 'rpm -i --force maxscale-1.0.6.rpm'

Comment to the Release notes is added ("know issues")

Generated at Thu Feb 08 03:56:24 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.