Re: secure automated access (was "Re: Backing up all databases")

2003-11-17 Thread Ed Leafe
On Monday, November 17, 2003, at 11:51 AM, Michael Stassen wrote: I'm glad this worked for you, but now I'm confused. The manual clearly indicates the use of quotes around the password. See . The "typical user option file" starts with [clien

Re: secure automated access (was "Re: Backing up all databases")

2003-11-17 Thread Michael Stassen
Ed Leafe wrote: On Monday, November 17, 2003, at 02:58 AM, Michael Stassen wrote: cat $HOME/.my.cnf [client] password="rootpassword" /usr/local/mysql/bin/mysql --defaults-file=$HOME/.my.cnf ERROR 1045: Access denied for user: '[EMAIL PROTECTED]' (Using password: YES) Oh. That changes things.

Re: secure automated access (was "Re: Backing up all databases")

2003-11-17 Thread Randall Perry
> >> In the case of root cron jobs then, you need a .my.cnf readable only by >> root in root's home. It should include >> >> [client] >> password="mysql_root_password" > > This is incorrect, unless the double quotes are part of the password. > Removing them so that the entry reads: > > [clien

Re: secure automated access (was "Re: Backing up all databases")

2003-11-17 Thread Randall Perry
>> >> Mac OS 10.2.3. Maybe Panther has an issue with the build? > > 10.2.3 is Jaguar, not Panther. Did you mean 10.3.x? As I said, I'm > running mysql 4.0.16 on Mac OS 10.2.8, and this works for me. I suppose > an issue with Panther is possible, though I'd be surprised if something > simple l

Re: secure automated access (was "Re: Backing up all databases")

2003-11-17 Thread Ed Leafe
On Monday, November 17, 2003, at 02:58 AM, Michael Stassen wrote: cat $HOME/.my.cnf [client] password="rootpassword" /usr/local/mysql/bin/mysql --defaults-file=$HOME/.my.cnf ERROR 1045: Access denied for user: '[EMAIL PROTECTED]' (Using password: YES) Oh. That changes things. The error says "U

Re: secure automated access (was "Re: Backing up all databases")

2003-11-17 Thread Michael Stassen
Randall Perry wrote: Mysterious. I assume `mysql -p` prompts you for root's password and works as expected, since without -p it says you're not using a password, rather than saying there's something wrong with the password. Yes, that works. When you tried the defaults-file option, did you use t

Re: secure automated access (was "Re: Backing up all databases")

2003-11-16 Thread Randall Perry
> Mysterious. I assume `mysql -p` prompts you for root's password and > works as expected, since without -p it says you're not using a password, > rather than saying there's something wrong with the password. > Yes, that works. > When you tried the defaults-file option, did you use the full pa

Re: secure automated access (was "Re: Backing up all databases")

2003-11-13 Thread Michael Stassen
Mysterious. I assume `mysql -p` prompts you for root's password and works as expected, since without -p it says you're not using a password, rather than saying there's something wrong with the password. When you tried the defaults-file option, did you use the full path? That is, mysql --def

Re: secure automated access (was "Re: Backing up all databases")

2003-11-13 Thread Randall Perry
on 11/13/03 3:57 PM, Michael Stassen at [EMAIL PROTECTED] wrote: > The client (mysql) reads the .my.cnf file when you start it, so > restarting mysqld and relogging in as root are not necessary. > > Let's see if I have this straight: While logged in as root, you created > .my.cnf in root's home d

Re: secure automated access (was "Re: Backing up all databases")

2003-11-13 Thread Michael Stassen
The client (mysql) reads the .my.cnf file when you start it, so restarting mysqld and relogging in as root are not necessary. Let's see if I have this straight: While logged in as root, you created .my.cnf in root's home directory. This file contains the password for the mysql user "root". Ye

Re: secure automated access (was "Re: Backing up all databases")

2003-11-13 Thread Randall Perry
I created the .my.cnf file in root's home dir, added the directives below setting the correct password. Restarted mysqld, re-logged in as root, but nothing works. It's not getting the password. > The simplest solution is to keep the password in the .my.cnf file in > your home directory. See http

Re: secure automated access (was "Re: Backing up all databases")

2003-11-12 Thread Randall Perry
That sounds like the solution. Thanks for your help, everyone. > The simplest solution is to keep the password in the .my.cnf file in > your home directory. See http://www.mysql.com/doc/en/Option_files.html > in the manual. > > In the case of root cron jobs then, you need a .my.cnf readable on

Re: secure automated access

2003-11-12 Thread David T-G
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Mike -- ...and then Michael Stassen said... % % Mikael Fridh wrote: [And thank you to Mikael, too.] % % >On Wednesday 12 November 2003 17.15, David T-G wrote: % > % >>What if one user connects to the database as different users (as I do, in ... %

Re: secure automated access

2003-11-12 Thread Michael Stassen
Mikael Fridh wrote: On Wednesday 12 November 2003 17.15, David T-G wrote: % [client] % password="mysql_root_password" What if one user connects to the database as different users (as I do, in fact; sometimes all-db-root, sometimes one-db-root, sometimes read-only user)? Let's back this out

Re: secure automated access

2003-11-12 Thread Mikael Fridh
On Wednesday 12 November 2003 17.15, David T-G wrote: > % [client] > % password="mysql_root_password" > What if one user connects to the database as different users (as I do, in > fact; sometimes all-db-root, sometimes one-db-root, sometimes read-only > user)? Let's back this out of "root" and g

Re: secure automated access

2003-11-12 Thread David T-G
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Michael, et al -- ...and then Michael Stassen said... % % The simplest solution is to keep the password in the .my.cnf file in % your home directory. See http://www.mysql.com/doc/en/Option_files.html % in the manual. OK. % % In the case of root

Re: secure automated access (was "Re: Backing up all databases")

2003-11-12 Thread Michael Stassen
The simplest solution is to keep the password in the .my.cnf file in your home directory. See http://www.mysql.com/doc/en/Option_files.html in the manual. In the case of root cron jobs then, you need a .my.cnf readable only by root in root's home. It should include [client] password="mysql_root_p

Re: secure automated access (was "Re: Backing up all databases")

2003-11-12 Thread David T-G
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Dan, et al -- ...and then Dan Greene said... % % you could put a shell script as the actual cron job, and make the file only read-able by root, using an environment variable as the password passed (defined in shell script file), so that way even if