RE: Grant permissions problems - help - WORKS!
Thanks for the help to ALL I got it to work. I do not know how but I think that they might have been hidden characters in the program doing insert in the actuall insert statements. I retyped the insert code in the program and things started to work. Probably when I ftp the code somethin gelse got added. Thanks again, Nestor :-) Nestor A. Florez -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Grant permissions problems - help
Nestor Florez wrote: I actually took a look at the mysql.user table and user nestor has a password in both entries to the table. One entry is for localhost and the other is for '%'; I try inserting from the command line and I get: mysql> insert into School (school_desc) values ('Nestor'); Query OK, 1 row affected (0.00 sec) OK, mysql says it inserted this row with no errors. Even when I do it as the main root for mysql the record is not inserted. Why do you think the row is not inserted? Do you know how to reset the auto_increment Depends on what you mean. What exactly do you want to happen to the auto_increment column? Nestor :-) Nestor A. Florez Victor Pendleton <[EMAIL PROTECTED]> 11/13/2003 11:49:51 AM Their are two nestor users. One with a password and one without a password. The one with connect from anywhere is only allowed to modify the test database. Fix your privileges and you should be okay. -Original Message- From: Nestor Florez [mailto:[EMAIL PROTECTED] Sent: Thursday, November 13, 2003 1:04 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: Grant permissions problems - help +--- --+ | Grants for [EMAIL PROTECTED] | +--- --+ | GRANT USAGE ON *.* TO 'nestor'@'%' IDENTIFIED BY PASSWORD '93c8c803300d29b9' | | GRANT ALL PRIVILEGES ON `test`.* TO 'nestor'@'%' | +--- --+ IS the same on both my W2K and my Mac OS X Nestor :-) Nestor A. Florez Victor Pendleton <[EMAIL PROTECTED]> 11/13/2003 11:01:37 AM execute show grants for nestor@'%' and see what that user has. -Original Message- I forgot to mentioned that this same code works on the same database on my W2K but I am having problems on my Mac OS X (Darwin). I sqldump the database from my W2K to my Mac Os X. Nestor :-) Nestor A. Florez Nestor Florez 11/13/2003 10:17:37 AM >>> I have a mysql db where via a web page I access a database I have set the permissions to grant select, insert, update, delete on test.* to [EMAIL PROTECTED] identified by 'nestor'; flush privileges; The database has 3 tables. I can select via PHP code all the tables, but when I try to insert or update 2 of the tables allow me but there is one table that does not. My schools table refuses to insert or update, but my courses_eng and course_esp allows me to select, insert, update, delete I them gave the following command: grant all privileges on test.* to [EMAIL PROTECTED] identified by 'nestor'; grant all privileges on test.* to nestor@'%' identified by 'nestor'; flush privileges; I am still not able to insert and update to the school table, but I can do this on the course_eng and course_esp tables. Any ideas. Thanks, Nestor :-) Nestor A. Florez -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Grant permissions problems - help
I actually took a look at the mysql.user table and user nestor has a password in both entries to the table. One entry is for localhost and the other is for '%'; I try inserting from the command line and I get: mysql> insert into School (school_desc) values ('Nestor'); Query OK, 1 row affected (0.00 sec) Even when I do it as the main root for mysql the record is not inserted. Do you know how to reset the auto_increment Nestor :-) Nestor A. Florez >>> Victor Pendleton <[EMAIL PROTECTED]> 11/13/2003 11:49:51 AM >>> Their are two nestor users. One with a password and one without a password. The one with connect from anywhere is only allowed to modify the test database. Fix your privileges and you should be okay. -Original Message- From: Nestor Florez [mailto:[EMAIL PROTECTED] Sent: Thursday, November 13, 2003 1:04 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: Grant permissions problems - help +--- --+ | Grants for [EMAIL PROTECTED] | +--- --+ | GRANT USAGE ON *.* TO 'nestor'@'%' IDENTIFIED BY PASSWORD '93c8c803300d29b9' | | GRANT ALL PRIVILEGES ON `test`.* TO 'nestor'@'%' | +--- --+ IS the same on both my W2K and my Mac OS X Nestor :-) Nestor A. Florez >>> Victor Pendleton <[EMAIL PROTECTED]> 11/13/2003 11:01:37 AM >>> execute show grants for nestor@'%' and see what that user has. -Original Message- I forgot to mentioned that this same code works on the same database on my W2K but I am having problems on my Mac OS X (Darwin). I sqldump the database from my W2K to my Mac Os X. Nestor :-) Nestor A. Florez >>> Nestor Florez 11/13/2003 10:17:37 AM >>> I have a mysql db where via a web page I access a database I have set the permissions to grant select, insert, update, delete on test.* to [EMAIL PROTECTED] identified by 'nestor'; flush privileges; The database has 3 tables. I can select via PHP code all the tables, but when I try to insert or update 2 of the tables allow me but there is one table that does not. My schools table refuses to insert or update, but my courses_eng and course_esp allows me to select, insert, update, delete I them gave the following command: grant all privileges on test.* to [EMAIL PROTECTED] identified by 'nestor'; grant all privileges on test.* to nestor@'%' identified by 'nestor'; flush privileges; I am still not able to insert and update to the school table, but I can do this on the course_eng and course_esp tables. Any ideas. Thanks, Nestor :-) Nestor A. Florez -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Grant permissions problems - help
Victor, I will fixed this, but I do not think this is th eproblem. I have the same settings on both W2K and Mac OS X and it only fails on the Mac Also When I log in as nestor with a password on the Mac I can not insert a record from the ocmmand line. I can do this on my W2K database. Thanks I will try it, Nestor :-) Nestor A. Florez >>> Victor Pendleton <[EMAIL PROTECTED]> 11/13/2003 11:49:51 AM >>> Their are two nestor users. One with a password and one without a password. The one with connect from anywhere is only allowed to modify the test database. Fix your privileges and you should be okay. -Original Message- From: Nestor Florez [mailto:[EMAIL PROTECTED] Sent: Thursday, November 13, 2003 1:04 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: Grant permissions problems - help +--- --+ | Grants for [EMAIL PROTECTED] | +--- --+ | GRANT USAGE ON *.* TO 'nestor'@'%' IDENTIFIED BY PASSWORD '93c8c803300d29b9' | | GRANT ALL PRIVILEGES ON `test`.* TO 'nestor'@'%' | +--- --+ IS the same on both my W2K and my Mac OS X Nestor :-) Nestor A. Florez >>> Victor Pendleton <[EMAIL PROTECTED]> 11/13/2003 11:01:37 AM >>> execute show grants for nestor@'%' and see what that user has. -Original Message- I forgot to mentioned that this same code works on the same database on my W2K but I am having problems on my Mac OS X (Darwin). I sqldump the database from my W2K to my Mac Os X. Nestor :-) Nestor A. Florez >>> Nestor Florez 11/13/2003 10:17:37 AM >>> I have a mysql db where via a web page I access a database I have set the permissions to grant select, insert, update, delete on test.* to [EMAIL PROTECTED] identified by 'nestor'; flush privileges; The database has 3 tables. I can select via PHP code all the tables, but when I try to insert or update 2 of the tables allow me but there is one table that does not. My schools table refuses to insert or update, but my courses_eng and course_esp allows me to select, insert, update, delete I them gave the following command: grant all privileges on test.* to [EMAIL PROTECTED] identified by 'nestor'; grant all privileges on test.* to nestor@'%' identified by 'nestor'; flush privileges; I am still not able to insert and update to the school table, but I can do this on the course_eng and course_esp tables. Any ideas. Thanks, Nestor :-) Nestor A. Florez -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Grant permissions problems - help
Their are two nestor users. One with a password and one without a password. The one with connect from anywhere is only allowed to modify the test database. Fix your privileges and you should be okay. -Original Message- From: Nestor Florez [mailto:[EMAIL PROTECTED] Sent: Thursday, November 13, 2003 1:04 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: Grant permissions problems - help +--- --+ | Grants for [EMAIL PROTECTED] | +--- --+ | GRANT USAGE ON *.* TO 'nestor'@'%' IDENTIFIED BY PASSWORD '93c8c803300d29b9' | | GRANT ALL PRIVILEGES ON `test`.* TO 'nestor'@'%' | +--- --+ IS the same on both my W2K and my Mac OS X Nestor :-) Nestor A. Florez >>> Victor Pendleton <[EMAIL PROTECTED]> 11/13/2003 11:01:37 AM >>> execute show grants for nestor@'%' and see what that user has. -Original Message- I forgot to mentioned that this same code works on the same database on my W2K but I am having problems on my Mac OS X (Darwin). I sqldump the database from my W2K to my Mac Os X. Nestor :-) Nestor A. Florez >>> Nestor Florez 11/13/2003 10:17:37 AM >>> I have a mysql db where via a web page I access a database I have set the permissions to grant select, insert, update, delete on test.* to [EMAIL PROTECTED] identified by 'nestor'; flush privileges; The database has 3 tables. I can select via PHP code all the tables, but when I try to insert or update 2 of the tables allow me but there is one table that does not. My schools table refuses to insert or update, but my courses_eng and course_esp allows me to select, insert, update, delete I them gave the following command: grant all privileges on test.* to [EMAIL PROTECTED] identified by 'nestor'; grant all privileges on test.* to nestor@'%' identified by 'nestor'; flush privileges; I am still not able to insert and update to the school table, but I can do this on the course_eng and course_esp tables. Any ideas. Thanks, Nestor :-) Nestor A. Florez -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Grant permissions problems - help
OK guys this is beyond me. I just found out that I can NOT insert into my SCHOOL table when I login into mysql as user nestor on my Mac OS X. The table is autoincremented. how do I find out what is the next number to be incremented? Nestor :-) Nestor A. Florez >>> "Nestor Florez" <[EMAIL PROTECTED]> 11/13/2003 11:08:58 AM >>> I just realized that if I login to mysql as the user I can insert records. It must be somehting with my code I will try the trace_on It is just amazing that the same code works in my W2K machine and when I ftp it to the Mac OS X only adding to th eschools fails. Thanks, Nestor :-) Nestor A. Florez >>> George Webb <[EMAIL PROTECTED]> 11/13/2003 11:06:29 AM >>> Hi Nestor. What does the mysql_error() report as the exact error message? This could help you identify what kind of access control issue it is. Alternatively, you could try running the same query from the command line (using the mysql client) and see if you get the same error. Also, I'm not really sure about this feature, but it has helped me once or twice: "trace mode". In PHP, you can do ini_set('mysql.trace_mode','on'); and there might be a way to do this also with the mysql client Best, George. George Webb [EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Grant permissions problems - help
I just realized that if I login to mysql as the user I can insert records. It must be somehting with my code I will try the trace_on It is just amazing that the same code works in my W2K machine and when I ftp it to the Mac OS X only adding to th eschools fails. Thanks, Nestor :-) Nestor A. Florez >>> George Webb <[EMAIL PROTECTED]> 11/13/2003 11:06:29 AM >>> Hi Nestor. What does the mysql_error() report as the exact error message? This could help you identify what kind of access control issue it is. Alternatively, you could try running the same query from the command line (using the mysql client) and see if you get the same error. Also, I'm not really sure about this feature, but it has helped me once or twice: "trace mode". In PHP, you can do ini_set('mysql.trace_mode','on'); and there might be a way to do this also with the mysql client Best, George. George Webb [EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Grant permissions problems - help
+-+ | Grants for [EMAIL PROTECTED] | +-+ | GRANT USAGE ON *.* TO 'nestor'@'%' IDENTIFIED BY PASSWORD '93c8c803300d29b9' | | GRANT ALL PRIVILEGES ON `test`.* TO 'nestor'@'%' | +-+ IS the same on both my W2K and my Mac OS X Nestor :-) Nestor A. Florez >>> Victor Pendleton <[EMAIL PROTECTED]> 11/13/2003 11:01:37 AM >>> execute show grants for nestor@'%' and see what that user has. -Original Message- I forgot to mentioned that this same code works on the same database on my W2K but I am having problems on my Mac OS X (Darwin). I sqldump the database from my W2K to my Mac Os X. Nestor :-) Nestor A. Florez >>> Nestor Florez 11/13/2003 10:17:37 AM >>> I have a mysql db where via a web page I access a database I have set the permissions to grant select, insert, update, delete on test.* to [EMAIL PROTECTED] identified by 'nestor'; flush privileges; The database has 3 tables. I can select via PHP code all the tables, but when I try to insert or update 2 of the tables allow me but there is one table that does not. My schools table refuses to insert or update, but my courses_eng and course_esp allows me to select, insert, update, delete I them gave the following command: grant all privileges on test.* to [EMAIL PROTECTED] identified by 'nestor'; grant all privileges on test.* to nestor@'%' identified by 'nestor'; flush privileges; I am still not able to insert and update to the school table, but I can do this on the course_eng and course_esp tables. Any ideas. Thanks, Nestor :-) Nestor A. Florez -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Grant permissions problems - help
Hi Nestor. What does the mysql_error() report as the exact error message? This could help you identify what kind of access control issue it is. Alternatively, you could try running the same query from the command line (using the mysql client) and see if you get the same error. Also, I'm not really sure about this feature, but it has helped me once or twice: "trace mode". In PHP, you can do ini_set('mysql.trace_mode','on'); and there might be a way to do this also with the mysql client Best, George. George Webb [EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Grant permissions problems - help
execute show grants for nestor@'%' and see what that user has. -Original Message- From: Nestor Florez [mailto:[EMAIL PROTECTED] Sent: Thursday, November 13, 2003 12:21 PM To: Nestor Florez; [EMAIL PROTECTED] Subject: Re: Grant permissions problems - help I forgot to mentioned that this same code works on the same database on my W2K but I am having problems on my Mac OS X (Darwin). I sqldump the database from my W2K to my Mac Os X. Nestor :-) Nestor A. Florez >>> Nestor Florez 11/13/2003 10:17:37 AM >>> I have a mysql db where via a web page I access a database I have set the permissions to grant select, insert, update, delete on test.* to [EMAIL PROTECTED] identified by 'nestor'; flush privileges; The database has 3 tables. I can select via PHP code all the tables, but when I try to insert or update 2 of the tables allow me but there is one table that does not. My schools table refuses to insert or update, but my courses_eng and course_esp allows me to select, insert, update, delete I them gave the following command: grant all privileges on test.* to [EMAIL PROTECTED] identified by 'nestor'; grant all privileges on test.* to nestor@'%' identified by 'nestor'; flush privileges; I am still not able to insert and update to the school table, but I can do this on the course_eng and course_esp tables. Any ideas. Thanks, Nestor :-) Nestor A. Florez -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Grant permissions problems - help
I forgot to mentioned that this same code works on the same database on my W2K but I am having problems on my Mac OS X (Darwin). I sqldump the database from my W2K to my Mac Os X. Nestor :-) Nestor A. Florez >>> Nestor Florez 11/13/2003 10:17:37 AM >>> I have a mysql db where via a web page I access a database I have set the permissions to grant select, insert, update, delete on test.* to [EMAIL PROTECTED] identified by 'nestor'; flush privileges; The database has 3 tables. I can select via PHP code all the tables, but when I try to insert or update 2 of the tables allow me but there is one table that does not. My schools table refuses to insert or update, but my courses_eng and course_esp allows me to select, insert, update, delete I them gave the following command: grant all privileges on test.* to [EMAIL PROTECTED] identified by 'nestor'; grant all privileges on test.* to nestor@'%' identified by 'nestor'; flush privileges; I am still not able to insert and update to the school table, but I can do this on the course_eng and course_esp tables. Any ideas. Thanks, Nestor :-) Nestor A. Florez -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Grant permissions problems - help
I have a mysql db where via a web page I access a database I have set the permissions to grant select, insert, update, delete on test.* to [EMAIL PROTECTED] identified by 'nestor'; flush privileges; The database has 3 tables. I can select via PHP code all the tables, but when I try to insert or update 2 of the tables allow me but there is one table that does not. My schools table refuses to insert or update, but my courses_eng and course_esp allows me to select, insert, update, delete I them gave the following command: grant all privileges on test.* to [EMAIL PROTECTED] identified by 'nestor'; grant all privileges on test.* to nestor@'%' identified by 'nestor'; flush privileges; I am still not able to insert and update to the school table, but I can do this on the course_eng and course_esp tables. Any ideas. Thanks, Nestor :-) Nestor A. Florez -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Problems with grant/permissions
Check the file ownership, and make sure that its the same as the mysql user. Barry Gold wrote: > I duplicated the mysql database from another machine by copying over the > table files. But now I find myself unable to access the tables. > > I restarted the mysql server using the --skip-grant-tables option. Then > I could access the tables, but the grant command wasn't recognized so I > couldn't just add my root id to the permissions. > > I tried adding myself by inserting rows into the user and host tables, > but it still didn't work. > > Anybody got any ideas? I want to get this cleaned up so I can slave the > new copy to the old one, to act as a backup server. > > - > Before posting, please check: >http://www.mysql.com/manual.php (the manual) >http://lists.mysql.com/ (the list archive) > > To request this thread, e-mail <[EMAIL PROTECTED]> > To unsubscribe, e-mail <[EMAIL PROTECTED]> > Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Problems with grant/permissions
I duplicated the mysql database from another machine by copying over the table files. But now I find myself unable to access the tables. I restarted the mysql server using the --skip-grant-tables option. Then I could access the tables, but the grant command wasn't recognized so I couldn't just add my root id to the permissions. I tried adding myself by inserting rows into the user and host tables, but it still didn't work. Anybody got any ideas? I want to get this cleaned up so I can slave the new copy to the old one, to act as a backup server. - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
grant permissions
Hello. I want to create a user in mysql that can create and "grant" other users with permissions to a specific table. I created user with permitions of "grants", and permissions of "insert" and "grant" to "mysql" database, and I cant add users with that user. I want that this user could add users, but not remove them. another question - can I create such user, but without permissions to change properties of user root, or to create user with root permition. and one more question: Can I make additional users-permitions table or data-base in MySql in order to use it for specific database? Thank you, Tamar Klein - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
GRANT permissions
I'm confused, and wondering if anyone can help me. I'm running 2 virtual servers, let's say server1.domain.com and server2.domain.com. These virtual servers sit on servers named host1.isp.com and host2.isp.com respectively (I hope I haven't lost anyone yet). I have a perl script, that lists the contents of a table in a database stored on [EMAIL PROTECTED], and when I point the DSN to host=localhost, all works fine. Now I want the app to run on both virtual servers, so I modify the script on server2.domain.com to have DSN=server1.domain.com. I have granted all permissions required to: [EMAIL PROTECTED] [EMAIL PROTECTED] user@"%.domain.com" /and/ user@"%.isp.com" Yet the script doesn't run. It doesn't say cannot connect (I do get that error if I revoke all privs), but I get: DBI->connect(database=DBNAME;host=HOSTNAME;port=143) failed: Lost connection to MySQL server during query at /script/name line 26 Can't call method "prepare" on an undefined value at /script/name line 29. I can connect to the database from server2 using: mysql DBNAME -u USERNAME -h HOSTNAME -p without problems. I guess what I'm asking, to cut a long question short, is if anyone has any idea what this error message means. Lost connection make me think it authenticates, but then disconnects, however if I connect to localhost from server1, it works fine. One last thing, even if I "grant all to user@%" it won't run properly. Hoping someone can help, and thanks in advance... Ben - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php