Re: Log Warnings Level
Kristen G. Thorson wrote: But all I really get from this reading is 0 turns it off, 1 prints some warnings, and 2 prints level 1 warnings plus aborted connections warnings. I have not been able to find any additional information in my search. Am I missing something, or is this all the documentation there is on this? What kind of additional information are you looking about the --W (or --log-warnings=N) option? Thank you for the response. I was looking for information on how high the level can go - 2? 5? 200? - and what types of warnings are logged for a given level? AFAIK, 2 is the highest. Anything beyond that, is equivalent to it I'd pay attention to aborted connections, as MySQL Network's monitoring service actually does do so I'm not sure what you mean by this. Could you clarify? With a log level of 2 here, you actually get to see aborted connections -- Colin Charles, Community Engineer MySQL AB, Melbourne, Australia, www.mysql.com Mobile: +614 12 593 292 / Skype: colincharles Web: http://www.bytebot.net/blog/ MySQL Forge: http://forge.mysql.com/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Log Warnings Level
> -Original Message- > From: Colin Charles [mailto:[EMAIL PROTECTED] > Sent: Wednesday, January 17, 2007 9:08 PM > To: Kristen G. Thorson > Cc: mysql@lists.mysql.com > Subject: Re: Log Warnings Level > > Kristen G. Thorson wrote: > > Hi! > > > But all I really get from this reading is 0 turns it off, 1 prints some > > warnings, and 2 prints level 1 warnings plus aborted connections > > warnings. I have not been able to find any additional information in my > > search. Am I missing something, or is this all the documentation there > > is on this? > > What kind of additional information are you looking about the --W (or > --log-warnings=N) option? Thank you for the response. I was looking for information on how high the level can go - 2? 5? 200? - and what types of warnings are logged for a given level? > I'd pay attention to aborted connections, as MySQL Network's monitoring > service actually does do so I'm not sure what you mean by this. Could you clarify? Thanks! -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Log Warnings Level
Kristen G. Thorson wrote: Hi! But all I really get from this reading is 0 turns it off, 1 prints some warnings, and 2 prints level 1 warnings plus aborted connections warnings. I have not been able to find any additional information in my search. Am I missing something, or is this all the documentation there is on this? What kind of additional information are you looking about the --W (or --log-warnings=N) option? I'd pay attention to aborted connections, as MySQL Network's monitoring service actually does do so kind regards -- Colin Charles, Community Engineer MySQL AB, Melbourne, Australia, www.mysql.com Mobile: +614 12 593 292 / Skype: colincharles Web: http://www.bytebot.net/blog/ MySQL Forge: http://forge.mysql.com/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Log Warnings Level
The manual indicates that you can specify a specific level to control what types of warnings are logged: http://dev.mysql.com/doc/refman/5.0/en/server-options.html (See section on log-warnings.) But all I really get from this reading is 0 turns it off, 1 prints some warnings, and 2 prints level 1 warnings plus aborted connections warnings. I have not been able to find any additional information in my search. Am I missing something, or is this all the documentation there is on this? Thanks, Kristen G. Thorson Programmer (804) 553-1130, Ext. 204 www.AllegroConsultants.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: How to Log Warnings and Errors from queries
Hi Rithish, Thank you all for your suggestion, I would definitely give it a shot. Regards, Ryan. On 3/13/06, Rithish Saralaya <[EMAIL PROTECTED]> wrote: > > Hello Ryan. I am more of a developer than a MySQL administrator. Hence, I > would always favour applications logging query errors rather than being > dependent on MySQL to generate a log for me. Of course, I may be wrong. > > You could write a query execution function, say exec_mysql_query(...) in > one > of you files, say 'Db.inc' and have it included in all your files. > > exec_mysql_query(...) will log all mysql errors into a file. and you may > provide an web-interface (assuming this is a web application) to > view/download the log files. > > Regards, > Rithish. > > > > -Original Message- > From: ryan lwf [mailto:[EMAIL PROTECTED] > Sent: Friday, March 10, 2006 8:14 PM > To: Dan Nelson > Cc: mysql@lists.mysql.com > Subject: Re: How to Log Warnings and Errors from queries > > > Hi Dan, > > Noted with thanks. > > As such, is there a workaround to log problematic sql queries ran against > the mysqld server ? Do I need to write separate script to do this ? > > Regards, > Ryan. > > On 3/10/06, Dan Nelson <[EMAIL PROTECTED]> wrote: > > > > In the last episode (Mar 08), ryan lwf said: > > > I understand that the option log-errors and log-warnings only logs > > > server related internal errors. How do I enable logging errors from > > > queries executed, so that I can fix the problematic query statement > > > accordingly? > > > > > > The statement "SHOW WARNINGS" and "SHOW ERRORS" does not work on my > > > server with mysqld-4.0.25 binary version. > > > > Those commands appeared in MySQL 4.1. Before then, warnings were > > simply counted. > > > > -- > >Dan Nelson > >[EMAIL PROTECTED] > > > >
RE: How to Log Warnings and Errors from queries
Hello Ryan. I am more of a developer than a MySQL administrator. Hence, I would always favour applications logging query errors rather than being dependent on MySQL to generate a log for me. Of course, I may be wrong. You could write a query execution function, say exec_mysql_query(...) in one of you files, say 'Db.inc' and have it included in all your files. exec_mysql_query(...) will log all mysql errors into a file. and you may provide an web-interface (assuming this is a web application) to view/download the log files. Regards, Rithish. -Original Message- From: ryan lwf [mailto:[EMAIL PROTECTED] Sent: Friday, March 10, 2006 8:14 PM To: Dan Nelson Cc: mysql@lists.mysql.com Subject: Re: How to Log Warnings and Errors from queries Hi Dan, Noted with thanks. As such, is there a workaround to log problematic sql queries ran against the mysqld server ? Do I need to write separate script to do this ? Regards, Ryan. On 3/10/06, Dan Nelson <[EMAIL PROTECTED]> wrote: > > In the last episode (Mar 08), ryan lwf said: > > I understand that the option log-errors and log-warnings only logs > > server related internal errors. How do I enable logging errors from > > queries executed, so that I can fix the problematic query statement > > accordingly? > > > > The statement "SHOW WARNINGS" and "SHOW ERRORS" does not work on my > > server with mysqld-4.0.25 binary version. > > Those commands appeared in MySQL 4.1. Before then, warnings were > simply counted. > > -- >Dan Nelson >[EMAIL PROTECTED] > -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: How to Log Warnings and Errors from queries
There are some scripts that help us to save logs, For example: log4php You write your app and when you're testing it you define a level to save the errors into a file and display them in your app but in production the client doesn't have to see the errors, only the developers, so, in your log4php define that only write the errors into a log file. This is a easy way to control the errors logs, without re-write your scripts, for example: Testing: Mysql_query($sql) or die(mysql_error()." $sql"); Production: Mysql_query($sql) or die(saveLog(mysql_error()." $sql")); Regards! Edwin. -Mensaje original- De: Subscriptions [mailto:[EMAIL PROTECTED] Enviado el: Viernes, 10 de Marzo de 2006 10:27 a.m. Para: mysql@lists.mysql.com Asunto: Re: How to Log Warnings and Errors from queries In PHP, you can see the error message as follows: $result = mysql_query($sSQL) or die ("".mysql_error() ."".$sSQL); Just change it to write that mysql_error() to a file instead and that'll do it. So, something like: $result = mysql_query($sSQL) or die ( log_error(mysql_error()) ); where you create that function log_error to write to a file. Jenifer - Original Message - From: "Kishore Jalleda" <[EMAIL PROTECTED]> To: "ryan lwf" <[EMAIL PROTECTED]> Cc: "Dan Nelson" <[EMAIL PROTECTED]>; Sent: Friday, March 10, 2006 10:03 AM Subject: Re: How to Log Warnings and Errors from queries as you know mysql gives you an error to check your sql syntax when it doesn't understand a query but does not log it , but you can have your application (php, perl, etc ) accessing mysql to log any bad/malformed queries... Kishore Jalleda On 3/10/06, ryan lwf <[EMAIL PROTECTED]> wrote: > Hi Dan, > > Noted with thanks. > > As such, is there a workaround to log problematic sql queries ran > against the mysqld server ? Do I need to write separate script to do > this ? > > Regards, > Ryan. > > On 3/10/06, Dan Nelson <[EMAIL PROTECTED]> wrote: > > > > In the last episode (Mar 08), ryan lwf said: > > > I understand that the option log-errors and log-warnings only logs > > > server related internal errors. How do I enable logging errors > > > from queries executed, so that I can fix the problematic query > > > statement accordingly? > > > > > > The statement "SHOW WARNINGS" and "SHOW ERRORS" does not work on > > > my server with mysqld-4.0.25 binary version. > > > > Those commands appeared in MySQL 4.1. Before then, warnings were > > simply counted. > > > > -- > >Dan Nelson > >[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: How to Log Warnings and Errors from queries
In PHP, you can see the error message as follows: $result = mysql_query($sSQL) or die ("".mysql_error() ."".$sSQL); Just change it to write that mysql_error() to a file instead and that'll do it. So, something like: $result = mysql_query($sSQL) or die ( log_error(mysql_error()) ); where you create that function log_error to write to a file. Jenifer - Original Message - From: "Kishore Jalleda" <[EMAIL PROTECTED]> To: "ryan lwf" <[EMAIL PROTECTED]> Cc: "Dan Nelson" <[EMAIL PROTECTED]>; Sent: Friday, March 10, 2006 10:03 AM Subject: Re: How to Log Warnings and Errors from queries as you know mysql gives you an error to check your sql syntax when it doesn't understand a query but does not log it , but you can have your application (php, perl, etc ) accessing mysql to log any bad/malformed queries... Kishore Jalleda On 3/10/06, ryan lwf <[EMAIL PROTECTED]> wrote: Hi Dan, Noted with thanks. As such, is there a workaround to log problematic sql queries ran against the mysqld server ? Do I need to write separate script to do this ? Regards, Ryan. On 3/10/06, Dan Nelson <[EMAIL PROTECTED]> wrote: > > In the last episode (Mar 08), ryan lwf said: > > I understand that the option log-errors and log-warnings only logs > > server related internal errors. How do I enable logging errors from > > queries executed, so that I can fix the problematic query statement > > accordingly? > > > > The statement "SHOW WARNINGS" and "SHOW ERRORS" does not work on my > > server with mysqld-4.0.25 binary version. > > Those commands appeared in MySQL 4.1. Before then, warnings were > simply counted. > > -- >Dan Nelson >[EMAIL PROTECTED] > -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: How to Log Warnings and Errors from queries
as you know mysql gives you an error to check your sql syntax when it doesn't understand a query but does not log it , but you can have your application (php, perl, etc ) accessing mysql to log any bad/malformed queries... Kishore Jalleda On 3/10/06, ryan lwf <[EMAIL PROTECTED]> wrote: > Hi Dan, > > Noted with thanks. > > As such, is there a workaround to log problematic sql queries ran against > the mysqld server ? Do I need to write separate script to do this ? > > Regards, > Ryan. > > On 3/10/06, Dan Nelson <[EMAIL PROTECTED]> wrote: > > > > In the last episode (Mar 08), ryan lwf said: > > > I understand that the option log-errors and log-warnings only logs > > > server related internal errors. How do I enable logging errors from > > > queries executed, so that I can fix the problematic query statement > > > accordingly? > > > > > > The statement "SHOW WARNINGS" and "SHOW ERRORS" does not work on my > > > server with mysqld-4.0.25 binary version. > > > > Those commands appeared in MySQL 4.1. Before then, warnings were > > simply counted. > > > > -- > >Dan Nelson > >[EMAIL PROTECTED] > > > >
Re: How to Log Warnings and Errors from queries
Hi Dan, Noted with thanks. As such, is there a workaround to log problematic sql queries ran against the mysqld server ? Do I need to write separate script to do this ? Regards, Ryan. On 3/10/06, Dan Nelson <[EMAIL PROTECTED]> wrote: > > In the last episode (Mar 08), ryan lwf said: > > I understand that the option log-errors and log-warnings only logs > > server related internal errors. How do I enable logging errors from > > queries executed, so that I can fix the problematic query statement > > accordingly? > > > > The statement "SHOW WARNINGS" and "SHOW ERRORS" does not work on my > > server with mysqld-4.0.25 binary version. > > Those commands appeared in MySQL 4.1. Before then, warnings were > simply counted. > > -- >Dan Nelson >[EMAIL PROTECTED] >
Re: How to Log Warnings and Errors from queries
In the last episode (Mar 08), ryan lwf said: > I understand that the option log-errors and log-warnings only logs > server related internal errors. How do I enable logging errors from > queries executed, so that I can fix the problematic query statement > accordingly? > > The statement "SHOW WARNINGS" and "SHOW ERRORS" does not work on my > server with mysqld-4.0.25 binary version. Those commands appeared in MySQL 4.1. Before then, warnings were simply counted. -- Dan Nelson [EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
How to Log Warnings and Errors from queries
Hi all, I understand that the option log-errors and log-warnings only logs server related internal errors. How do I enable logging errors from queries executed, so that I can fix the problematic query statement accordingly? The statement "SHOW WARNINGS" and "SHOW ERRORS" does not work on my server with mysqld-4.0.25 binary version. Any inputs are appreciated. Thanks, Ryan.
Re: log-warnings
On 12 Nov 2005, at 04:26, Harrison Fisk wrote: The log-warnings option doesn't do what you want. It will cause the mysqld server log more internal errors. Non-critical errors such as network disconnects will be logged into the error log with that setting. The option you want it is the --show-warnings option for the mysql client itself. Ah, I see. That explains a lot - so there is still no way of seeing these warnings at the server? I can now see the warnings on the client side, though I note it doesn't log the query that caused the error, but it still reduces my work to a bit of simple detective work rather than having to trawl through endless log files. Thanks for the explanation, Marcus -- Marcus Bointon Synchromedia Limited: Putting you in the picture [EMAIL PROTECTED] | http://www.synchromedia.co.uk -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: log-warnings
Hi, On Nov 11, 2005, at 10:01 PM, Marcus Bointon wrote: At the time I reported this bug back in February: http:// bugs.mysql.com/bug.php?id=8684 I was pleased to see it apparently fixed so fast. I wasn't yet using MySQL 5, so I couldn't get the fix. I am now upgrading to 5 using mysql 5.0.15, and I find I still face much the same problem. Despite much rummaging in the docs, the log-warnings options still seem completely undocumented (it gets a few mentions as a startup option, but nowhere does it say where the messages disappear to), and despite having it 'enabled' (it's difficult to know what to set it to as it has no documentation) in my.cnf, I'm not seeing warnings logged anywhere. I had assumed they'd go in the error log, but that seems to be mostly empty. Putting it in the regular or binary logs seems hopeless - I'm trying to pick out numerous (> 2) warnings that happen during a 1.2 million record mysqldump import. Anything that I've tried for processing text log files (grep/sed/awk/vi etc) takes several hours at a time and usually finds nothing of use. If I could see the warnings then I could probably fix the problem that's causing them at source. Help! If there was at least a user note on warnings I could be saved - can anyone tell me where I might find the warning messages, along with the query that caused them? The log-warnings option doesn't do what you want. It will cause the mysqld server log more internal errors. Non-critical errors such as network disconnects will be logged into the error log with that setting. The option you want it is the --show-warnings option for the mysql client itself. mysql --show-warnings db < file.sql Should output the errors to screen afaik. You can redirect it to a file or similar if you want. Regards, Harrison -- Harrison C. Fisk, Trainer and Consultant MySQL AB, www.mysql.com Get a jumpstart on MySQL Cluster -- http://www.mysql.com/consulting/ packaged/cluster.html -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
log-warnings
At the time I reported this bug back in February: http:// bugs.mysql.com/bug.php?id=8684 I was pleased to see it apparently fixed so fast. I wasn't yet using MySQL 5, so I couldn't get the fix. I am now upgrading to 5 using mysql 5.0.15, and I find I still face much the same problem. Despite much rummaging in the docs, the log- warnings options still seem completely undocumented (it gets a few mentions as a startup option, but nowhere does it say where the messages disappear to), and despite having it 'enabled' (it's difficult to know what to set it to as it has no documentation) in my.cnf, I'm not seeing warnings logged anywhere. I had assumed they'd go in the error log, but that seems to be mostly empty. Putting it in the regular or binary logs seems hopeless - I'm trying to pick out numerous (> 2) warnings that happen during a 1.2 million record mysqldump import. Anything that I've tried for processing text log files (grep/sed/awk/vi etc) takes several hours at a time and usually finds nothing of use. If I could see the warnings then I could probably fix the problem that's causing them at source. Help! If there was at least a user note on warnings I could be saved - can anyone tell me where I might find the warning messages, along with the query that caused them? Thanks, Marcus -- Marcus Bointon Synchromedia Limited: Putting you in the picture [EMAIL PROTECTED] | http://www.synchromedia.co.uk -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: log-warnings
On 18 Feb 2005, at 16:05, Gleb Paharenko wrote: There is no direct way to load warnings into log files. Just for the archives, I reported this as a bug and it's in the MySQL bug db as having been verified, so I guess now we just hope/wait for a fix in a later version: http://bugs.mysql.com/bug.php?id=8684 Marcus -- Marcus Bointon Synchromedia Limited: Putting you in the picture [EMAIL PROTECTED] | http://www.synchromedia.co.uk -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: log-warnings
Hello. There is no direct way to load warnings into log files. But you may use a small value for max_error_count and launch mysql in a batch mode saving results in the file. Marcus Bointon <[EMAIL PROTECTED]> wrote: > I'm migrating a MySQL 3.23 db to 4.1.10 (on Linux x86) and I'm getting > some infrequent warnings when importing data dumps created with > mysqldump, but I can't seem to find out what the warnings are. > > I'm typically importing around 100,000 records at a time, so using > 'SHOW WARNINGS' manually is no use - and I can't yet nail down a query > that actually generates a warning anyway. > > I can start the mysql client using -v, but as even at the lowest level > or verbosity it always displays the query, and since my inserts are > often 30k per record, it's just not practical to scan the output, plus > it makes it go very slowly. > > I've got log-warnings in my my.cnf file, and mysqld is definitely > picking it up (adding it made log-warnings appear as set to 2, though I > can't find any reference in the docs for what the values mean), but > mysql is not logging any warnings at all. > > I have log-error=/var/lib/mysql/mysql.err set in my.cnf, and again it's > definitely being picked up by the server. > > If it makes a difference, I'm using all InnoDB tables. > > All I need is for warnings to be logged along with the query that > caused it without having to log everything and trawl through it - what > have I missed?! > > Marcus -- For technical support contracts, goto https://order.mysql.com/?ref=ensita This email is sponsored by Ensita.NET http://www.ensita.net/ __ ___ ___ __ / |/ /_ __/ __/ __ \/ /Gleb Paharenko / /|_/ / // /\ \/ /_/ / /__ [EMAIL PROTECTED] /_/ /_/\_, /___/\___\_\___/ MySQL AB / Ensita.NET <___/ www.mysql.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: log-warnings
On 18 Feb 2005, at 14:24, Thomas Sundberg wrote: I would approach this problem by isolating the where the problem occurs. I.e. Remove, comment out, half of you insert queries and see if the problem still exists. If it does, then remove yet another half of the remaining part leaving only 1/4 of the original problem to solve. This would give the solution in approximately log(n) times where n is number of parts you can remove. I.e. If you have 100 different inserts, you would find the correct one in about 5 tries. This is of course the brute method you always fall back to when you don't even know where the problem exists. Having 100 000 different inserts would increase the number of tries to 11 or 12. Well, that's exactly the kind of thing I'm trying to avoid. The hassle is that I have 1.7 million records spread over 26 tables, with hundreds of warnings generated when I import. I can't believe that there's no way of having these reported - does no-one value their data? Why doesn't log-warnings do anything? Should I report it as a bug? I really don't want to spend days trawling through/slicing up 3Gb of dump files when a trivial settings change might just show me them all in one go. As part of the effort to get more detail, I've switched to using single instead of extended inserts (also because many of my records hit 30k each). Could you imagine working with a compiler that only ever told you 'there was an error'? Ultimately I want to tune the output of the dumps and fix any data problems at source so I can do transfers smoothly - my 4.1 DB is my dev version, and I'm wanting to transfer regular dumps to make sure I'm working with up-to-date stuff. That should be a matter of not much more than file transfer and import time, not several days to manually track down errors every time. Marcus -- Marcus Bointon Synchromedia Limited: Putting you in the picture [EMAIL PROTECTED] | http://www.synchromedia.co.uk -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: log-warnings
> -Original Message- > From: Marcus Bointon [mailto:[EMAIL PROTECTED] > Sent: den 18 februari 2005 14:47 > To: mysql@lists.mysql.com > Subject: log-warnings > > I'm migrating a MySQL 3.23 db to 4.1.10 (on Linux x86) and > I'm getting some infrequent warnings when importing data > dumps created with mysqldump, but I can't seem to find out > what the warnings are. > > I'm typically importing around 100,000 records at a time, so > using 'SHOW WARNINGS' manually is no use - and I can't yet > nail down a query that actually generates a warning anyway. > > I can start the mysql client using -v, but as even at the > lowest level or verbosity it always displays the query, and > since my inserts are often 30k per record, it's just not > practical to scan the output, plus it makes it go very slowly. > > I've got log-warnings in my my.cnf file, and mysqld is > definitely picking it up (adding it made log-warnings appear > as set to 2, though I can't find any reference in the docs > for what the values mean), but mysql is not logging any > warnings at all. > > I have log-error=/var/lib/mysql/mysql.err set in my.cnf, and > again it's definitely being picked up by the server. > > If it makes a difference, I'm using all InnoDB tables. > > All I need is for warnings to be logged along with the query > that caused it without having to log everything and trawl > through it - what have I missed?! I would approach this problem by isolating the where the problem occurs. I.e. Remove, comment out, half of you insert queries and see if the problem still exists. If it does, then remove yet another half of the remaining part leaving only 1/4 of the original problem to solve. This would give the solution in approximately log(n) times where n is number of parts you can remove. I.e. If you have 100 different inserts, you would find the correct one in about 5 tries. This is of course the brute method you always fall back to when you don't even know where the problem exists. Having 100 000 different inserts would increase the number of tries to 11 or 12. /Thomas -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
log-warnings
I'm migrating a MySQL 3.23 db to 4.1.10 (on Linux x86) and I'm getting some infrequent warnings when importing data dumps created with mysqldump, but I can't seem to find out what the warnings are. I'm typically importing around 100,000 records at a time, so using 'SHOW WARNINGS' manually is no use - and I can't yet nail down a query that actually generates a warning anyway. I can start the mysql client using -v, but as even at the lowest level or verbosity it always displays the query, and since my inserts are often 30k per record, it's just not practical to scan the output, plus it makes it go very slowly. I've got log-warnings in my my.cnf file, and mysqld is definitely picking it up (adding it made log-warnings appear as set to 2, though I can't find any reference in the docs for what the values mean), but mysql is not logging any warnings at all. I have log-error=/var/lib/mysql/mysql.err set in my.cnf, and again it's definitely being picked up by the server. If it makes a difference, I'm using all InnoDB tables. All I need is for warnings to be logged along with the query that caused it without having to log everything and trawl through it - what have I missed?! Marcus -- Marcus Bointon Synchromedia Limited: Putting you in the picture [EMAIL PROTECTED] | http://www.synchromedia.co.uk -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: How can we use --log-warnings
Hello. I didn't find any bug related to this behaviour. What operation system do you use? Connect to the server with mysql command line client program and kill it with the SIGKILL signal. Check the error file to find messages about aborted connections. Can you reproduce a problem on the latest release (4.1.9 now)? Try only --log-warnings, without specifying the exact value. [snip] We are with mysql 4.0.17-log and we want to use --log-warnings to see aborted connections in our errorlog. We put log_warnings = 2 in our my.cnf and restarted mysql but we did not see aborted connections in our errorlog. We tried --log-warnings = 2 on the command line when we started mysql and again, we did not see aborted connections in our errorlog. We tried --log-warnings on the command line when we started mysql and again, we did not see aborted connections in our errorlog. When I do a mysqladmin variables, I saw log_warnings = ON. So, how can we set this parameter to be able to see something in our errorlog ?"Marois, David" <[EMAIL PROTECTED]> wrote: [snip] -- For technical support contracts, goto https://order.mysql.com/?ref=ensita This email is sponsored by Ensita.NET http://www.ensita.net/ __ ___ ___ __ / |/ /_ __/ __/ __ \/ /Gleb Paharenko / /|_/ / // /\ \/ /_/ / /__ [EMAIL PROTECTED] /_/ /_/\_, /___/\___\_\___/ MySQL AB / Ensita.NET <___/ www.mysql.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
How can we use --log-warnings
We are with mysql 4.0.17-log and we want to use --log-warnings to see aborted connections in our errorlog. We put log_warnings = 2 in our my.cnf and restarted mysql but we did not see aborted connections in our errorlog. We tried --log-warnings = 2 on the command line when we started mysql and again, we did not see aborted connections in our errorlog. We tried --log-warnings on the command line when we started mysql and again, we did not see aborted connections in our errorlog. When I do a mysqladmin variables, I saw log_warnings = ON. So, how can we set this parameter to be able to see something in our errorlog ? David Marois <mailto:[EMAIL PROTECTED]> [EMAIL PROTECTED]