Mysql

Discuss Networking
Post Reply
Master of Reality
guru
guru
Posts: 562
Joined: Thu Jan 09, 2003 8:25 pm

Mysql

Post by Master of Reality »

i'm setting up phpbb on slackware... and i am pretty sure the problem is with mysql. I have safe_mysqld running and i have a user named mor and a database named phpbb that has all permissions (and hosts) for user mor.

I try to install phpbb... it cant connect to database. So i opened mysql (mysql -u mor -p) and typed "use phpbb" and it says ERROR 1044: Access denied for user: 'mor@localhost' to database 'phpbb'.

I am using command line and to a lesser extent webmin to try and configure this.
Any ideas how to fix this? IT just doesnt seem right. Webmin still says mor has all permsions from any host to connect to phpbb.

Master of Reality
guru
guru
Posts: 562
Joined: Thu Jan 09, 2003 8:25 pm

Post by Master of Reality »

ok ok... that wasnt the problem. It cant connect to db after i fixed the permissions to allow mor to connect to phpbb. It was set to not be able to connect from any host. But i fixed that and it still says it cant connect to the database

User avatar
Void Main
Site Admin
Site Admin
Posts: 5716
Joined: Wed Jan 08, 2003 5:24 am
Location: Tuxville, USA
Contact:

Post by Void Main »

I usually do this in webmin. First I set up a user under the "User Permissions" link, in your case you would set up a user "mor" with host set to "localhost", might want to also set a password, "permissions" can stay set to "none". Then under the "Database Permissions" link you would add a permissions for the "phpBB" database for user "mor" from host "localhost", you can set the permissions to "All" (the user doesn't need really need "All" but it'll work). Then from a command line you should be able to:

Code: Select all

$ mysql phpBB --user=mor -p
This should prompt you for a password to which you would enter the password you used in the first step above. If this connects you to the phpBB database without error then your phpBB setup script should work using "mor", "yourpassword", "localhost" for the setup information...

Master of Reality
guru
guru
Posts: 562
Joined: Thu Jan 09, 2003 8:25 pm

Post by Master of Reality »

those are my settings and i can connect that way.
I thought it might have had something to do with my hostname because my computer was chatroom.fsckmicro$oft.com and i didnt change it to mor.servebeer.com which i just did. And it still says :
phpBB : Critical Error

Could not connect to the database


.....is there any logs for mysql that i could check, i could not find any


(mysql hates me :( )

User avatar
Void Main
Site Admin
Site Admin
Posts: 5716
Joined: Wed Jan 08, 2003 5:24 am
Location: Tuxville, USA
Contact:

Post by Void Main »

It should have nothing to do with the hostname of your ethernet adapter because you aren't using that for MySQL. You are using "localhost" on your loopback adapter (127.0.0.1). The only other thing I can think of are incorrect /etc/php.ini settings, or not having the proper libraries installed. Might also want to look in your error_log to see if there is a more detailed error message in there.

Master of Reality
guru
guru
Posts: 562
Joined: Thu Jan 09, 2003 8:25 pm

Post by Master of Reality »

my apache error_log doesnt say anything about it. How would i check about the proper libraries?

Master of Reality
guru
guru
Posts: 562
Joined: Thu Jan 09, 2003 8:25 pm

Post by Master of Reality »

do you need to put an initial table or anything in the database when making it... or do you just create a db and leave it completely empty for phpBB??

Master of Reality
guru
guru
Posts: 562
Joined: Thu Jan 09, 2003 8:25 pm

Post by Master of Reality »

ahhhhhhhh!!!!.... ok... i changed the host from localhost to mor.servebeer.com... and poof! it magically works... i have no idea why or how its possible that the computer didnt dissappear in a puff of logic... but it works.

User avatar
Void Main
Site Admin
Site Admin
Posts: 5716
Joined: Wed Jan 08, 2003 5:24 am
Location: Tuxville, USA
Contact:

Post by Void Main »

Then sumpin must not be cornfiggered right.

Post Reply