Operating System - HP-UX
1832531 Members
8464 Online
110043 Solutions
New Discussion

best way to start mysql in hp-ux 11

 
David_337
Occasional Contributor

best way to start mysql in hp-ux 11

Hi,
I'm running mysql under 11.0. I can start the mysql daemon from the command line ok. I tried to get it to start on bootup but I'm doing something wrong. Before I re-invent the wheel is there a standard way to do this?
Thanks,
Dave Driscoll scripts and error messages attached.
3 REPLIES 3
Rodney Hills
Honored Contributor

Re: best way to start mysql in hp-ux 11

Attached is mysqld which you should copy into /sbin/init.d

HTH

-- Rod Hills
There be dragons...
Steven E. Protter
Exalted Contributor

Re: best way to start mysql in hp-ux 11

mysql needs to be started by the user that owns the binaries, not root.

The best way to do this is in the startup script at /sbin/init.d/mysql (choose your own name, i generally clone a file called template)

In the start section you need to have this:

/usr/bin/su - mysql -c "command line of mysql start script"

That line points to a startup script that you should have tested and working for the mysql user.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
David_337
Occasional Contributor

Re: best way to start mysql in hp-ux 11

I tried Rodney's script first since I was looking for a standard solution but it failed so I tried Steven's suggestion since I already had a command line script that worked but it failed too. Then I edited Rodney's script: in my install mysql is in /usr/local/mysql, the init scripts are in /sbin and rc0.d links use K instead of S & now everything seems to be working.
Thanks guys
Dave