Re: MySQL 4.x questions...

2004-01-30 Thread Peter Risdon
Eric F Crist wrote:

Thanks for all your help with this problem.  Both apps seemed to have 
successfully installed now, but they both have errors.  PostNuke keeps 
telling me it's 'Failed to Initialize' and I can't get away from the phpBB 
install script, no matter where I go.  I can try to trouble shoot these on my 
own, though.

Have a good day!

 

I'd have thought both these errors might stem from a problem writing (as 
opposed to connecting) to the relevant databases. Are the schema 
installed? It's helpful to check what is actually happening to the 
tables if there are any, and there should be.

#mysqlshow -u username -p databasename

will show the tables, if there are any...

#mysql -u username -p databasename
mysql> select * from tablename\G
will show what is in the tables. If this isn't changing during 
initialisation/install then there's probably a permissions prob. You can 
check permissions as follows (assuming there is a root password):

mysql -u root -p mysql
mysql> select * from db\G
Your output should include a block like this:

*** 1. row ***
Host: localhost
  Db: databasename
User: username
 Select_priv: Y
 Insert_priv: Y
 Update_priv: Y
 Delete_priv: Y
 Create_priv: Y
   Drop_priv: Y
  Grant_priv: N
 References_priv: Y
  Index_priv: Y
  Alter_priv: Y
Create_tmp_table_priv: Y
Lock_tables_priv: Y


PWR.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: MySQL 4.x questions...

2004-01-30 Thread Eric F Crist
Thanks for all your help with this problem.  Both apps seemed to have 
successfully installed now, but they both have errors.  PostNuke keeps 
telling me it's 'Failed to Initialize' and I can't get away from the phpBB 
install script, no matter where I go.  I can try to trouble shoot these on my 
own, though.

Have a good day!

-- 
Eric F Crist
AdTech Integrated Systems, Inc
(612) 998-3588

pgp0.pgp
Description: signature


Re: MySQL 4.x questions...

2004-01-30 Thread Peter Risdon
Eric F Crist wrote:

Hey all,

I installed MySQL server 4.1.0_1 to support the PostNuke CMS and the phpBB 
bulletin board system.  For the life of me, I can't get a database setup for 
either of them to use.  Both users groups tell me that there's a mysql 
problem with configuration.  Here are the errors:

phpBB:

Warning: mysql_error(): supplied argument is not a valid MySQL-Link resource 
in /www/seccomp/htdocs/phpBB2/db/mysql4.php on line 330

Warning: mysql_errno(): supplied argument is not a valid MySQL-Link resource 
in /www/seccomp/htdocs/phpBB2/db/mysql4.php on line 331
phpBB : Critical Error 

Could not connect to the database 

PostNuke:

No database made.Error connecting to db
Program: /www/seccomp/htdocs/pn/install/db.php - Line N.: 45
Database: seccomp-nuke
Error (1044) : Access denied for user: '@localhost' to database 
'seccomp-nuke'

Can someone tell me what I need to setup to get this working right?  I've been 
feeling pretty worthless with this stuff lately.  I've never needed this much 
help.  Maybe I'm just trying to do too much at once?

TIA
 

This is a general answer, not specific to phpnuke or phpBB, neither of 
which I am famil.iar with.

Applications that use a mysql backend generally come with database 
schema (often a file called something.sql) and need to be configured 
with a valid user name and password. The process for setting these apps 
up is as follows:

1. install the port.

2. setup the database for the app with:

#mysqladmin create databasename

(see the app documentation for the correct database name to use)

3. Then grant the relevant permissions top the username the app is going 
to want to use (again see docs). It's generally safe to log into mysql 
as root and grant all. Mysql installs with a blank root password so if 
you haven't changed this (and you should!), you can login as follows:

#mysql -u root databasename

Then use the following statement to grant all:

mysql> grant all on databasename.* to [EMAIL PROTECTED] identified by 
"password";

4. Set up the schema as follows:

#mysql -u username -p databasename < schemafile.sql

5. You then need to make sure the correct user name and password are in 
the app's config scripts. This usually an include file with php apps.

HTH.

PWR.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: MySQL 4.x questions...

2004-01-29 Thread Andrew Boothman
Eric F Crist wrote:

Hey all,

I installed MySQL server 4.1.0_1 to support the PostNuke CMS and the phpBB 
bulletin board system.  For the life of me, I can't get a database setup for 
either of them to use.  Both users groups tell me that there's a mysql 
problem with configuration.  Here are the errors:

phpBB:

Warning: mysql_error(): supplied argument is not a valid MySQL-Link resource 
in /www/seccomp/htdocs/phpBB2/db/mysql4.php on line 330
 
 Warning: mysql_errno(): supplied argument is not a valid MySQL-Link resource 
in /www/seccomp/htdocs/phpBB2/db/mysql4.php on line 331
 phpBB : Critical Error 

 Could not connect to the database 

PostNuke:

No database made.Error connecting to db
Program: /www/seccomp/htdocs/pn/install/db.php - Line N.: 45
Database: seccomp-nuke
 Error (1044) : Access denied for user: '@localhost' to database 
'seccomp-nuke'

Can someone tell me what I need to setup to get this working right?  I've been 
feeling pretty worthless with this stuff lately.  I've never needed this much 
help.  Maybe I'm just trying to do too much at once?
It's some kind of permissions problem. For some reason user accounts and 
permissions are surprisingly difficult to get right in MySQL.

The fact that you get "Access denied for user" means that a connection 
is being opened, but that it couldn't be authenticated.

You need to check the DB-related settings in your applications. Check 
you have supplied the correct usernames and passwords.

Really - there's no substitute for seriously reading and digesting 
. 
There's a lot of information on there but it's really quite a 
complicated issue.

The thing to look for is whether you've granted the correct rights to 
the correct [EMAIL PROTECTED] Note that MySQL defines [EMAIL PROTECTED] and 
[EMAIL PROTECTED] to be different things. If I remember correctly, 
connecting using the unix socket (not the networking TCP socket) will 
show as @my.hostname while connecting to the TCP socket on 127.0.0.1 
will show as @localhost.

I find it difficult everytime I set up a new application using MySQL 
myself. But it is possible to get your head around it!

Best of luck.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: MySQL 4.x questions...

2004-01-29 Thread Saint Aardvark the Carpeted
Eric F Crist disturbed my sleep to write:
Content-Description: signed data
> I installed MySQL server 4.1.0_1 to support the PostNuke CMS and the phpBB 
> bulletin board system.  For the life of me, I can't get a database setup for 
> either of them to use.  Both users groups tell me that there's a mysql 
> problem with configuration.  Here are the errors:

Hm...if I had to guess, I'd say that either MySQL isn't running, or
phpBB/PostNuke haven't been configured correctly.

Try "ps auxw | grep mysql" and make sure it's running.  If not, the
start script should be /usr/local/etc/rc.d/mysql.sh (I think).

Try connecting to it using the mysql client and the MySQL user name and
password you've set up for your programs:

$ mysql -u [MySQL user name] -p [database name]
Password: *

Finally, check the configuration for your programs and MySQL.  Is phpBB
trying to connect via TCP/IP?  If so, is MySQL set up to listen via
TCP/IP, or is it only on a file socket?  What about basics like the user
name and password?

Hope that helps...let me know how it turns out.

Hugh
-- 
Saint Aardvark the Carpeted
[EMAIL PROTECTED]
Because the plural of Anecdote is Myth.
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


MySQL 4.x questions...

2004-01-29 Thread Eric F Crist
Hey all,

I installed MySQL server 4.1.0_1 to support the PostNuke CMS and the phpBB 
bulletin board system.  For the life of me, I can't get a database setup for 
either of them to use.  Both users groups tell me that there's a mysql 
problem with configuration.  Here are the errors:

phpBB:

Warning: mysql_error(): supplied argument is not a valid MySQL-Link resource 
in /www/seccomp/htdocs/phpBB2/db/mysql4.php on line 330
 
 Warning: mysql_errno(): supplied argument is not a valid MySQL-Link resource 
in /www/seccomp/htdocs/phpBB2/db/mysql4.php on line 331
 phpBB : Critical Error 

 Could not connect to the database 

PostNuke:

No database made.Error connecting to db
Program: /www/seccomp/htdocs/pn/install/db.php - Line N.: 45
Database: seccomp-nuke
 Error (1044) : Access denied for user: '@localhost' to database 
'seccomp-nuke'

Can someone tell me what I need to setup to get this working right?  I've been 
feeling pretty worthless with this stuff lately.  I've never needed this much 
help.  Maybe I'm just trying to do too much at once?

TIA
-- 
Eric F Crist
AdTech Integrated Systems, Inc
(612) 998-3588

pgp0.pgp
Description: signature