Koozali.org: home of the SME Server

how to add user to mysql and how to find sql passwd

Offline polarair

  • **
  • 32
  • +0/-0
    • http://www.cosoprinting.nl
how to add user to mysql and how to find sql passwd
« on: March 30, 2006, 10:19:41 PM »
Hi, Im new to sme but im a bit lost in finding the root passwprd or even adding a wheel user for mysql. I understand that sme7 is using a encripted password that is linked to root so the next best thing is to add a user with all the priv's Can any body help.
Also how do i get the php.ini to work or even where is it located.
Last but least how do i import a tablestructure into mysql.

So thats all from the newbie but im learing fast  ;-)

Mike
live is to short not to enjoy it :lol: ......

Offline Boris

  • *
  • 783
  • +0/-0
how to add user to mysql and how to find sql passwd
« Reply #1 on: March 30, 2006, 11:09:55 PM »
do not reset mysql root password.
Find on this site and install phpmyadmin contrib. It will help you to manage mysql users, databases etc...
...

Offline cactus

  • *
  • 4,880
  • +3/-0
    • http://www.snetram.nl
how to add user to mysql and how to find sql passwd
« Reply #2 on: March 31, 2006, 11:05:13 AM »
Quote from: "Boris"
do not reset mysql root password.
Find on this site and install phpmyadmin contrib. It will help you to manage mysql users, databases etc...


You can connect using the mysql commandline client that is installed as well as user root without a password, this user is only configured to have localaccess if I remember correclty.
Code: [Select]
mysql -u root
Now you can simply add user like you would normally do with SQL commands, e.g.
Code: [Select]
grant select on database.table(s) to 'user'@'domain' identified by 'password';
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Offline polarair

  • **
  • 32
  • +0/-0
    • http://www.cosoprinting.nl
how to add user to mysql and how to find sql passwd
« Reply #3 on: April 01, 2006, 11:10:52 PM »
great but i cant get in. I have added a user but i get access denied.

Tried webmin but no go..I'm desperate in getting a second admin account on the mysql server then i can do things. I understand that the root account has its own sme password but i cant find this either. I founf the .my.cng file with a password but where can i use this. Not in the madn software.

please help

PS the phpadmin contrib dows not work on my sme7rc1 i get all kind of errors
live is to short not to enjoy it :lol: ......

Offline pfloor

  • *****
  • 889
  • +1/-0
how to add user to mysql and how to find sql passwd
« Reply #4 on: April 01, 2006, 11:38:11 PM »
Quote
great but i cant get in. I have added a user but i get access denied.

At the command line simply enter:

mysql

If you can't access mysql from the command line then you have somehow broken mysql root access.

Quote
Tried webmin but no go..

Webmin will not work on SME.

Quote
I'm desperate in getting a second admin account on the mysql server then i can do things.

Why do you want a second admin account, why don't you just use the root account to mantain the database?  If you need to access mysql from an application or php website then create a new user with access to it's own database.  Don't use the root user for that.

Quote
I understand that the root account has its own sme password but i cant find this either.

You don't need to know the password.  just type "mysql" at the command line and it will let you in.

Quote
I founf the .my.cng file with a password but where can i use this. Not in the madn software.

I assume you are talking about phpmyadmin.  You don't need to know the password and the correct RPM installed will configure everything for you.

Quote
PS the phpadmin contrib dows not work on my sme7rc1 i get all kind of errors

What version did you try?  Here is the latest http://mirror.contribs.org/smeserver/contribs//dmay/smeserver/7.x/smeserver-phpmyadmin-2.6.4-pl4.dmay.noarch.rpm and should work.  If it does not, please report it to the bug tracker.

Paul
In life, you must either "Push, Pull or Get out of the way!"