Results 1 to 15 of 15
  1. #1
    Join Date
    Apr 2002
    Posts
    384

    MySQL runs as root, and doesn't start automatically

    I've just configured MySQL on my RaQ550.

    Added it in the php.ini file...
    ln -s /var/lib/mysql/mysql.sock /tmp/mysql.sock
    ...

    But now I installed phpMyAdmin.
    If I don't configure it,
    and place it in a directory of a virtual site
    I can create databases, see all databases,...
    So that's NOT safe for other customers' databases.

    It also tells me that mysql runs as [email protected]

    When I reboot my server, MySQL doesn't start so I have to start it manually each reboot.

    What did I do wrong?

  2. #2
    Join Date
    Oct 2001
    Posts
    1,315
    To start it automatically, you can add a line in /etc/rc.d/rc.local such as:
    /etc/rc.d/init.d/mysql(d) restart

    I also had some probs with PHPMYADMIN and it wanting to get the root pw... I found older versions were better
    Avi Brender
    Reliable Web Hosting by Elite Hosts, Inc
    CPANEL Reseller Hosting - Fantastico - Rvskins - ClientExec

  3. #3
    Join Date
    Apr 2002
    Posts
    384
    Thanks!

    But I don't understand that PHPMyAdmin has "root access" over the databases instead of needing a password for each database he wants to acces...
    Last edited by FiberOptic; 08-25-2002 at 01:48 PM.

  4. #4
    Join Date
    Oct 2001
    Posts
    1,315
    That is something i've had problems with in the past too, i use an older version on my servers to get around that

    in config.inc.php i set user to root, leave password field blank and then set auth_type to cookie - that asks them for the username/pw

    I use v 1.7 (around 2001/08/03)
    Avi Brender
    Reliable Web Hosting by Elite Hosts, Inc
    CPANEL Reseller Hosting - Fantastico - Rvskins - ClientExec

  5. #5
    Join Date
    Apr 2002
    Posts
    384
    Yes,

    but if a customer installs phpMyAdmin himself ...
    he'll be able to screw up all databases !

  6. #6
    Join Date
    Oct 2001
    Posts
    1,315
    no, if a customer installs it, he still needs the root pw to do anything with all the dbs.
    Avi Brender
    Reliable Web Hosting by Elite Hosts, Inc
    CPANEL Reseller Hosting - Fantastico - Rvskins - ClientExec

  7. #7
    Join Date
    Apr 2002
    Posts
    384
    No!
    That's the problem!

    Anyone can
    create databases
    create users
    change databases
    ...

    without having to give a password!

  8. #8
    Join Date
    Jul 2002
    Location
    Cleveland, Oh USA
    Posts
    41
    Then you don't have a root password set in your MySQL database. Set a password and that should solve that issue...

    SSH/telnet in and run this on the command line

    mysqladmin -u root password 'mynewpassword'

    You really should SSH by the way

  9. #9
    Join Date
    Aug 2002
    Location
    Denmark
    Posts
    1
    To make MySQL autostart on the 550 just type the following:

    mv /etc/rc.d/rc4.d/K90mysql /etc/rc.d/rc4.d/S90mysql
    mv /etc/rc.d/rc5.d/K90mysql /etc/rc.d/rc5.d/S90mysql
    mv /etc/rc.d/rc3.d/K90mysql /etc/rc.d/rc3.d/S90mysql

    That's all.

  10. #10
    Join Date
    Apr 2002
    Posts
    384
    Cool

    But can you explain how it works...
    I mean, I don't understand how that rename of one letter each file can make the raq load it each logon...

  11. #11
    Join Date
    Jul 2002
    Location
    Cleveland, Oh USA
    Posts
    41
    Easiest way to think of it... things with an S in their name in the /etc/rc.d/rc3.d folder get started on boot (at startup). So think S for start!

    Think K for... oh I don't know... I can't think of anything for K
    Last edited by blazeman; 08-25-2002 at 10:15 PM.

  12. #12
    Join Date
    Apr 2002
    Posts
    384
    Thanks!

  13. #13
    Join Date
    Jun 2002
    Location
    Silver Spring, Maryland
    Posts
    256
    K stands for kill

  14. #14
    Originally posted by blazeman
    Then you don't have a root password set in your MySQL database. Set a password and that should solve that issue...

    SSH/telnet in and run this on the command line

    mysqladmin -u root password 'mynewpassword'

    You really should SSH by the way
    ahh.. there you go optic
    Western Man

  15. #15
    Join Date
    Sep 2002
    Location
    Shreveport, LA
    Posts
    21
    Originally posted by arpetkii
    To make MySQL autostart on the 550 just type the following:

    mv /etc/rc.d/rc4.d/K90mysql /etc/rc.d/rc4.d/S90mysql
    mv /etc/rc.d/rc5.d/K90mysql /etc/rc.d/rc5.d/S90mysql
    mv /etc/rc.d/rc3.d/K90mysql /etc/rc.d/rc3.d/S90mysql

    That's all.
    ================================
    I prefer chkconfig mysql on
    --
    gerald

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •