On Tue, Sep 26, 2017 at 02:20:18PM -0400, Brian Evans wrote: > On 9/26/2017 2:03 PM, Ruben Safir wrote: > > hello monty et al > > > > i'm trying to write an init script for maria and artix, which is using > > openrc > > > > I got it to start up but the pid-file is a problem and I think that the > > command line options for mysqld_safe is not working. it doesnt > > create the specified pid file > > Gentoo's OpenRC startup script does not use mysqld_safe because of such > limitations. > We have start-stop-daemon create the pidfile and call mysqld directly > instead. >
I was considering doing it like that but I realized that would mean rewritting a significant part of my.conf and combing through mysqld_safe and try to lock it down as much as monty already has... I trust monty :) If I do this, I will make it all complaint to the current architecture and build a package. I finally got it to work by making a /run/mariadb directory, chowon to maria.mariadb, and changing the pid file in my.conf and /etc/init.d/mariadb (using the start-stop-daemon) to /run/mariadb/mariadb.pid Seems to work for the time being. > Alternatively, OpenRC's supervise-daemon could be used if one wanted to > have the server "always available", but I believe that a database crash > should be investigated by an admin. 100% I'm on board with that. > > > [www3 ~]# tail -f /usr/local/var/www3.err > > 2017-09-26 10:41:53 139828287336192 [Note] InnoDB: 128 rollback segment(s) > > are active. > > 2017-09-26 10:41:53 139828287336192 [Note] InnoDB: Waiting for purge to > > start > > 2017-09-26 10:41:53 139828287336192 [Note] InnoDB: Percona XtraDB > > (http://www.percona.com) 5.6.36-82.0 started; log sequence number 1601111 > > 2017-09-26 10:41:53 139828287336192 [Note] Plugin 'FEEDBACK' is disabled. > > 2017-09-26 10:41:53 139827658368768 [Note] InnoDB: Dumping buffer pool(s) > > not yet started > > 2017-09-26 10:41:53 139828287171328 [Warning] Failed to load slave > > replication state from table mysql.gtid_slave_pos: 1146: Table > > 'mysql.gtid_slave_pos' doesn't exist > > 2017-09-26 10:41:53 139828287336192 [Note] Server socket created on IP: > > '::'. > > 2017-09-26 10:41:53 139828286868224 [ERROR] mysqld: Can't create/write to > > file '/run/mariadb.pid' (Errcode: 13 "Permission denied") > > 2017-09-26 10:41:53 139828286868224 [ERROR] Can't start server: can't > > create PID file: Permission denied > > 170926 10:41:53 mysqld_safe mysqld from pid file /run/mariadb.pid ended > > MySQL and MariaDB attempt to create the pidfile as the user that mysqld > is running as.. which may be a potential security issue if that user is > compromised. > > Brian > > _______________________________________________ > Mailing list: https://launchpad.net/~maria-discuss > Post to : maria-discuss@lists.launchpad.net > Unsubscribe : https://launchpad.net/~maria-discuss > More help : https://help.launchpad.net/ListHelp -- So many immigrant groups have swept through our town that Brooklyn, like Atlantis, reaches mythological proportions in the mind of the world - RI Safir 1998 http://www.mrbrklyn.com DRM is THEFT - We are the STAKEHOLDERS - RI Safir 2002 http://www.nylxs.com - Leadership Development in Free Software http://www2.mrbrklyn.com/resources - Unpublished Archive http://www.coinhangout.com - coins! http://www.brooklyn-living.com Being so tracked is for FARM ANIMALS and and extermination camps, but incompatible with living as a free human being. -RI Safir 2013 _______________________________________________ Mailing list: https://launchpad.net/~maria-discuss Post to : maria-discuss@lists.launchpad.net Unsubscribe : https://launchpad.net/~maria-discuss More help : https://help.launchpad.net/ListHelp