Re: mysql connect problems
On Sat, 11 Dec 2004 09:23:52 +, Peter Risdon [EMAIL PROTECTED] wrote: When I specify a value for MySQL server and for DB root password on the MediaWiki 1.3.8 installation page, I get Couldn't connect to database with a script note MySQL error 1250: Client does not support authentication protocol requested by server; consider upgrading MySQL client. When I omit the root password value, so it can connect with the user wikiuser, it says Check name/pass or enter root password below, with notes # MySQL error 1045: Access denied for user: 'root'@'localhost' (Using password: NO) and Trying regular user... need password. OK, but is this a mysql problem? It's certainly beginning to seem _not_ to be, isn't it. Can you connect as the relevant users from the command line? Yes. Which would seem to affirm your suspicion above. And I've tried every possible combination of information on the MediaWiki install page, but nothing works. If there are no more suggestions on how to fix this, how about recommendations for a different wiki package? Preferably, one that won't be quite as much of a bear to set up Thanks. ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: mysql connect problems
John DeStefano wrote: [...] When I specify a value for MySQL server and for DB root password on the MediaWiki 1.3.8 installation page, I get Couldn't connect to database with a script note MySQL error 1250: Client does not support authentication protocol requested by server; consider upgrading MySQL client. When I omit the root password value, so it can connect with the user wikiuser, it says Check name/pass or enter root password below, with notes # MySQL error 1045: Access denied for user: 'root'@'localhost' (Using password: NO) and Trying regular user... need password. OK, but is this a mysql problem? Can you connect as the relevant users from the command line? Peter. -- the circle squared network systems and software http://www.circlesquared.com ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: mysql connect problems
On Fri, 10 Dec 2004 18:08:48 +0100, Jorn Argelo [EMAIL PROTECTED] wrote: select user, password, host from user; on 'mysql' returned 3 'root' entries using 2 different passwords (localhost, %, and the actual host name), 2 anon entries (localhost and host name), 2 'mtuser' entries (one on localhost w/o pw, one on '%'), and one 'wikiuser' entry (localhost w/o pw). I changed the root passwords so they all use the same one, and changed the 'mtuser' entry that didn't have a password so its password matches that of the other entry. Have you issued the command similair like GRANT ALL PRIVILEGES ON *.* TO '[EMAIL PROTECTED]'; Yes: I ran both of these commands as root: GRANT ALL ON wikidb.* TO wikiuser; GRANT ALL ON mtdb.* TO mtuser; FLUSH PRIVILEGES; It still didn't work in either case. However, I logged off as I had to leave for a bit, later opened a new SSH session, and now can log in to mysql as both users, AND Mobile Type is now working! I have no idea what changed. And MediaWiki is still saying Couldn't connect to database. Running show databases; as 'wikiuser' shows the proper database (plus the 'test' database). I'm stuck. ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: mysql connect problems
On Fri, 10 Dec 2004 14:13:40 -0500, John DeStefano wrote On Fri, 10 Dec 2004 18:08:48 +0100, Jorn Argelo [EMAIL PROTECTED] wrote: select user, password, host from user; on 'mysql' returned 3 'root' entries using 2 different passwords (localhost, %, and the actual host name), 2 anon entries (localhost and host name), 2 'mtuser' entries (one on localhost w/o pw, one on '%'), and one 'wikiuser' entry (localhost w/o pw). I changed the root passwords so they all use the same one, and changed the 'mtuser' entry that didn't have a password so its password matches that of the other entry. Have you issued the command similair like GRANT ALL PRIVILEGES ON *.* TO '[EMAIL PROTECTED]'; Yes: I ran both of these commands as root: GRANT ALL ON wikidb.* TO wikiuser; GRANT ALL ON mtdb.* TO mtuser; FLUSH PRIVILEGES; AFAIK you must type '[EMAIL PROTECTED]' (including the quotes). If that doesn't work, then I don't know it either. Perhaps somebody else on the list has an idea? Jorn. ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: mysql connect problems
Jorn Argelo wrote: On Fri, 10 Dec 2004 14:13:40 -0500, John DeStefano wrote On Fri, 10 Dec 2004 18:08:48 +0100, Jorn Argelo [EMAIL PROTECTED] wrote: select user, password, host from user; on 'mysql' returned 3 'root' entries using 2 different passwords (localhost, %, and the actual host name), 2 anon entries (localhost and host name), 2 'mtuser' entries (one on localhost w/o pw, one on '%'), and one 'wikiuser' entry (localhost w/o pw). I changed the root passwords so they all use the same one, and changed the 'mtuser' entry that didn't have a password so its password matches that of the other entry. Have you issued the command similair like GRANT ALL PRIVILEGES ON *.* TO '[EMAIL PROTECTED]'; Yes: I ran both of these commands as root: GRANT ALL ON wikidb.* TO wikiuser; GRANT ALL ON mtdb.* TO mtuser; FLUSH PRIVILEGES; AFAIK you must type '[EMAIL PROTECTED]' (including the quotes). If that doesn't work, then I don't know it either. Perhaps somebody else on the list has an idea? I have found it's best to connect to the database you want to grant the privileges on before issuing the GRANT command. This doesn't seem to be the way it's documented, but it works for me. You might also consider using passwords... mysql\u wikidb mysqlGRANT ALL on wikidb.* to [EMAIL PROTECTED] IDENTIFIED BY 'password'; mysql\u mtdb mysqlGRANT ALL on mtdb.* to [EMAIL PROTECTED] IDENTIFIED BY 'password'; Peter. -- the circle squared network systems and software http://www.circlesquared.com ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: mysql connect problems
On Fri, 10 Dec 2004 00:15:10 +0100, Jorn Argelo [EMAIL PROTECTED] wrote: On Thu, 9 Dec 2004 17:18:38 -0500, John DeStefano wrote [snip] At a prompt, if I try to connect to mysql using the '-p' option like this: # mysql -u root -p ... I can connect. Which makes sense. Because the -p option is for entering a password. And I don't think you'll have an empty root password ;) I assumed p meant password in some respect, but didn't realize until you pointed it out that it actually meant _prompt_ for password, and that no password must inherently be assumed (which doesn't sound very secure). But if I try to connect without '-p' like this: # mysql -u root ... I get an error: mysqladmin: connect to server at 'localhost' failed error: 'Access denied for user: 'root'@'localhost' (Using password: NO)' What you're trying to do now is connecting with an empty password, and thus it refuses to connect. You always have to imply the -p option unless the password of your user is empty, but you DON'T want that. But this seems to work only for root: when I try the same command specifying one of the users I created: # mysql -u wikiuser -p Enter password: ...it doesn't work: ERROR 1045 (28000): Access denied for user: 'mtuser'@'localhost' (Using password: YES) From what I can gather, this has to do with setting passwords for different aliases or incarnations of the host for a single user (root). I've tried every solution I've found for adding additional connection settings for root (including more than one method for changing the root password). When I log into mysql as root, use the mysql database, and run 'select user, password, host from user;' I see multiple entries for root for different 'host' values ('localhost', the actual host name, and '%'). Well, I have checked it as well, and I have just the root user on localhost (with a different password then the one on the system though) and two anonymous users (so no username and no password) for localhost and the FQDM without any permissions. So I'm not really sure if the % is good or not. Perhaps you're running a different version then I am (I use 4.1.7). Yes: I'm running 5.0.0-alpha (at least that's what I get back from mysqladmin -u root -p version). So, do you recommend I try to remove those extra root entries? Also, how do I get these Web-based clients to connect to the accounts and databases they require? I have created a database for each application, and a user and password for each, and tried to grant permissions for each to connect to the respective database. But it's not working: both Web clients return can't connect errors. ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: mysql connect problems
On Fri, 10 Dec 2004 09:54:56 -0500, John DeStefano wrote On Fri, 10 Dec 2004 00:15:10 +0100, Jorn Argelo [EMAIL PROTECTED] wrote: On Thu, 9 Dec 2004 17:18:38 -0500, John DeStefano wrote [snip] At a prompt, if I try to connect to mysql using the '-p' option like this: # mysql -u root -p ... I can connect. Which makes sense. Because the -p option is for entering a password. And I don't think you'll have an empty root password ;) I assumed p meant password in some respect, but didn't realize until you pointed it out that it actually meant _prompt_ for password, and that no password must inherently be assumed (which doesn't sound very secure). A little side note, you can always type mysql -u root -pyourpassword (note that there is no space between the two) as well. But if I try to connect without '-p' like this: # mysql -u root ... I get an error: mysqladmin: connect to server at 'localhost' failed error: 'Access denied for user: 'root'@'localhost' (Using password: NO)' What you're trying to do now is connecting with an empty password, and thus it refuses to connect. You always have to imply the -p option unless the password of your user is empty, but you DON'T want that. But this seems to work only for root: when I try the same command specifying one of the users I created: # mysql -u wikiuser -p Enter password: ...it doesn't work: ERROR 1045 (28000): Access denied for user: 'mtuser'@'localhost' (Using password: YES) You have to make sure that the user has access to login. Unless you are using this database on an important machine, you can always change the root password like this: set password = password(yournewpassword); Like that, you won't have problems with permissions and such, but people who put security at a top priority will not like this method. From what I can gather, this has to do with setting passwords for different aliases or incarnations of the host for a single user (root). I've tried every solution I've found for adding additional connection settings for root (including more than one method for changing the root password). When I log into mysql as root, use the mysql database, and run 'select user, password, host from user;' I see multiple entries for root for different 'host' values ('localhost', the actual host name, and '%'). Well, I have checked it as well, and I have just the root user on localhost (with a different password then the one on the system though) and two anonymous users (so no username and no password) for localhost and the FQDM without any permissions. So I'm not really sure if the % is good or not. Perhaps you're running a different version then I am (I use 4.1.7). Yes: I'm running 5.0.0-alpha (at least that's what I get back from mysqladmin -u root -p version). So, do you recommend I try to remove those extra root entries? It's probably the best thing not to touch anything regarding the MySQL configuration unless you're sure what you're doing. Also, how do I get these Web-based clients to connect to the accounts and databases they require? I have created a database for each application, and a user and password for each, and tried to grant permissions for each to connect to the respective database. But it's not working: both Web clients return can't connect errors. Probably the same problem as stated before. If you are going to use one global root user, do make sure that you only use the web-based interface in a LAN enviroment, or add mod_ssl to your apache configuration. You don't want to send such sensible passwords over the net in plain text. If you want more information regarding the MySQL console, I would suggest you try the MySQL documentation located on their website. It's just as great as the FreeBSD handbook is ;) Cheers, Jorn ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: mysql connect problems
On Fri, 10 Dec 2004 16:09:20 +0100, Jorn Argelo [EMAIL PROTECTED] wrote: You have to make sure that the user has access to login. Unless you are using this database on an important machine, you can always change the root password like this: set password = password(yournewpassword); Like that, you won't have problems with permissions and such, but people who put security at a top priority will not like this method. I logged into mysql as root over a PuTTy/SSH connection and performed this command, specifying a new password. But the result was Query OK, 0 rows affected (0.01 sec). I believe this is because there are multiple 'root' entries in the user table with different 'host' values. I was able to change these values when I specified which entry I wanted to change: mysql UPDATE user SET password=PASSWORD(''new_password') - WHERE user='root' and host='host_entry'; Yes: I'm running 5.0.0-alpha (at least that's what I get back from mysqladmin -u root -p version). So, do you recommend I try to remove those extra root entries? It's probably the best thing not to touch anything regarding the MySQL configuration unless you're sure what you're doing. Are these extra root user entries in the mysql database, which I believe I've entered myself while trying different solutions, considered part of the MySQL configuration? select user, password, host from user; on 'mysql' returned 3 'root' entries using 2 different passwords (localhost, %, and the actual host name), 2 anon entries (localhost and host name), 2 'mtuser' entries (one on localhost w/o pw, one on '%'), and one 'wikiuser' entry (localhost w/o pw). I changed the root passwords so they all use the same one, and changed the 'mtuser' entry that didn't have a password so its password matches that of the other entry. 'mtuser' can not log in to mysql locally: # mysql -u mtuser -p Enter password: ERROR 1045 (28000): Access denied for user: 'mtuser'@'localhost' (Using password: YES) A similar error is returned by the Movable Type System Loader page (which is to be expected, since he/she can't log in locally): Access denied for user: 'mtuser'@'%' to database 'mtdb' at /usr/www/mt-static/mt-load.cgi line 195. 'wikiuser' can log in to mysql locally, but the MediaWiki 1.3.8 installation page reports it Couldn't connect to database, no mater whether I specify localhost, the actual host name, or leave the 'MySQL server' field blank. If you want more information regarding the MySQL console, I would suggest you try the MySQL documentation located on their website. It's just as great as the FreeBSD handbook is ;) I agree: the MySQL docs are comprehensive, extensive, and very well-organized. But for an inexperienced user like me, browsing through the troubleshooting sections to find an answer is like... well, trying to install Mobile Type. ;) ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: mysql connect problems
On Fri, 10 Dec 2004 11:07:17 -0500, John DeStefano wrote On Fri, 10 Dec 2004 16:09:20 +0100, Jorn Argelo [EMAIL PROTECTED] wrote: You have to make sure that the user has access to login. Unless you are using this database on an important machine, you can always change the root password like this: set password = password(yournewpassword); Like that, you won't have problems with permissions and such, but people who put security at a top priority will not like this method. I logged into mysql as root over a PuTTy/SSH connection and performed this command, specifying a new password. But the result was Query OK, 0 rows affected (0.01 sec). That is good, because you changed your password now :) I believe this is because there are multiple 'root' entries in the user table with different 'host' values. I was able to change these values when I specified which entry I wanted to change: mysql UPDATE user SET password=PASSWORD(''new_password') - WHERE user='root' and host='host_entry'; Yes: I'm running 5.0.0-alpha (at least that's what I get back from mysqladmin -u root -p version). So, do you recommend I try to remove those extra root entries? It's probably the best thing not to touch anything regarding the MySQL configuration unless you're sure what you're doing. Are these extra root user entries in the mysql database, which I believe I've entered myself while trying different solutions, considered part of the MySQL configuration? Ah. I was not aware that you entered users yourself. Then you should delete the amends you made yourself. select user, password, host from user; on 'mysql' returned 3 'root' entries using 2 different passwords (localhost, %, and the actual host name), 2 anon entries (localhost and host name), 2 'mtuser' entries (one on localhost w/o pw, one on '%'), and one 'wikiuser' entry (localhost w/o pw). I changed the root passwords so they all use the same one, and changed the 'mtuser' entry that didn't have a password so its password matches that of the other entry. Have you issued the command similair like GRANT ALL PRIVILEGES ON *.* TO '[EMAIL PROTECTED]'; See http://dev.mysql.com/doc/mysql/en/GRANT.html for more info. 'mtuser' can not log in to mysql locally: # mysql -u mtuser -p Enter password: ERROR 1045 (28000): Access denied for user: 'mtuser'@'localhost' (Using password: YES) A similar error is returned by the Movable Type System Loader page (which is to be expected, since he/she can't log in locally): Access denied for user: 'mtuser'@'%' to database 'mtdb' at /usr/www/mt-static/mt-load.cgi line 195. 'wikiuser' can log in to mysql locally, but the MediaWiki 1.3.8 installation page reports it Couldn't connect to database, no mater whether I specify localhost, the actual host name, or leave the 'MySQL server' field blank. ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: mysql connect problems
On Fri, 10 Dec 2004 21:43:19 +, Peter Risdon [EMAIL PROTECTED] wrote: AFAIK you must type '[EMAIL PROTECTED]' (including the quotes). If that doesn't work, then I don't know it either. Perhaps somebody else on the list has an idea? I have found it's best to connect to the database you want to grant the privileges on before issuing the GRANT command. This doesn't seem to be the way it's documented, but it works for me. You might also consider using passwords... mysql\u wikidb mysqlGRANT ALL on wikidb.* to [EMAIL PROTECTED] IDENTIFIED BY 'password'; mysql\u mtdb mysqlGRANT ALL on mtdb.* to [EMAIL PROTECTED] IDENTIFIED BY 'password'; Thank you both. Certainly makes sense, but it didn't work (If it _had_ worked, I'd be suspicious as to why I needed to do this for MediaWiki, and not for Mobile Type (which works now).). When I specify a value for MySQL server and for DB root password on the MediaWiki 1.3.8 installation page, I get Couldn't connect to database with a script note MySQL error 1250: Client does not support authentication protocol requested by server; consider upgrading MySQL client. When I omit the root password value, so it can connect with the user wikiuser, it says Check name/pass or enter root password below, with notes # MySQL error 1045: Access denied for user: 'root'@'localhost' (Using password: NO) and Trying regular user... need password. ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: mysql connect problems
On Thu, 9 Dec 2004 17:18:38 -0500, John DeStefano wrote [snip] At a prompt, if I try to connect to mysql using the '-p' option like this: # mysql -u root -p ... I can connect. Which makes sense. Because the -p option is for entering a password. And I don't think you'll have an empty root password ;) But if I try to connect without '-p' like this: # mysql -u root ... I get an error: mysqladmin: connect to server at 'localhost' failed error: 'Access denied for user: 'root'@'localhost' (Using password: NO)' What you're trying to do now is connecting with an empty password, and thus it refuses to connect. You always have to imply the -p option unless the password of your user is empty, but you DON'T want that. From what I can gather, this has to do with setting passwords for different aliases or incarnations of the host for a single user (root). I've tried every solution I've found for adding additional connection settings for root (including more than one method for changing the root password). When I log into mysql as root, use the mysql database, and run 'select user, password, host from user;' I see multiple entries for root for different 'host' values ('localhost', the actual host name, and '%'). Well, I have checked it as well, and I have just the root user on localhost (with a different password then the one on the system though) and two anonymous users (so no username and no password) for localhost and the FQDM without any permissions. So I'm not really sure if the % is good or not. Perhaps you're running a different version then I am (I use 4.1.7). I'd appreciate any help at all with this. Thanks very much. ~John ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED] ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]