Jody Gugelhupf
2007-Sep-22 15:51 UTC
[asterisk-users] error messages related to mysql in asterisk CLI
hi there :) i get this error in the asterisk CLI: Sep 21 20:31:49 ERROR[3774]: cdr_addon_mysql.c:159 mysql_log: cdr_mysql: Unknown connection error: (2006) MySQL server has gone away when I run 'cdr mysql status' i get: Connected to voiceone at localhost, port 3306 using table cdr for 18 minutes, 24 seconds. Wrote 8 records since last restart and 1 records since last reconnect. I checked my /etc/asterisk/cdr_mysql.conf but don't know what is wrong, here is my /etc/asterisk/cdr_mysql.conf: [global] hostname=localhost dbname=voiceone table=cdr user=username password=XXXXX port=3306 sock=/var/run/mysqld/mysqld.sock userfield=1 any ideas what i'm doing wrong? thx jody :)>Sep 21 20:31:49 ERROR[3774]: cdr_addon_mysql.c:159 mysql_log: cdr_mysql: >Unknown connection error: >(2006) MySQL server has gone away > >This part is more like mistake in /etc/asterisk/cdr_mysql.conf . Check it >once and relaod asterisk , then you can type "cdr mysql status" in cli to >check if it connects to mysql properly . > > > > >Sep 21 20:31:49 ERROR[3774]: cdr_csv.c:237 csv_log: Unable to re-open master >file >/var/log/asterisk//cdr-csv//Master.csv : Permission denied > >Permission error try chowning the directory to user which asterisk runs on >OR chmod 777 /var/log/asterisk/* -R > >Sep 21 20:31:49 ERROR[3774]: cdr_custom.c:127 custom_log: Unable to re-open >master file >/var/log/asterisk/cdr-custom/Master.csv : Permission denied > >Same permission error . >On 22/09/2007, Jody Gugelhupf <knueffle at yahoo.com> wrote:> > hi ppl, i have a problem, i get these messages in the asterisk CLI: > > Sep 21 20:31:49 ERROR[3774]: cdr_addon_mysql.c:159 mysql_log: cdr_mysql: > Unknown connection error: > (2006) MySQL server has gone away > > Sep 21 20:31:49 ERROR[3774]: cdr_csv.c:237 csv_log: Unable to re-open > master file > /var/log/asterisk//cdr-csv//Master.csv : Permission denied > > Sep 21 20:31:49 ERROR[3774]: cdr_custom.c:127 custom_log: Unable to > re-open master file > /var/log/asterisk/cdr-custom/Master.csv : Permission denied > > how can i fix these errors? > here some info about my system: > > debian etch 4.0 > kernel: > 2.6.18-4-686 > Asterisk 1.2.13 > VoiceOne version is v. 0.5.0 using plugin subsystem v. 0.4pre3 > mysql Ver 14.12 Distrib 5.0.32, for pc-linux-gnu (i486) using readline 5.2 > PHP 4.4.4-8+etch4 (cli) (built: Jun 30 2007 21:02:54) > using grandstream(handytone) 486 as sip device, no other devices or PSTN > connected, only using > sip/voip providers > behind router/NAT > > thx in advance :) > jody :)Ask a question on any topic and get answers from real people. Go to Yahoo! Answers and share what you know at http://ca.answers.yahoo.com
Nicholas Blasgen
2007-Sep-22 20:33 UTC
[asterisk-users] error messages related to mysql in asterisk CLI
It would surprise me to see mySQL configured incorrectly, but it's always a possibility. Look at the mysql server var called 'wait_timeout'. phpMyAdmin shows it under "system vars". http://blog.taragana.com/index.php/archive/mysql-tip-mysql-server-has-gone-away-or-lost-connection-to-server-during-query-fix/ On 9/22/07, Jody Gugelhupf <knueffle at yahoo.com> wrote:> > hi there :) > i get this error in the asterisk CLI: > > Sep 21 20:31:49 ERROR[3774]: cdr_addon_mysql.c:159 mysql_log: cdr_mysql: > Unknown connection error: > (2006) MySQL server has gone away-------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20070922/283842c4/attachment.htm
Andrea Spadaccini
2007-Sep-23 17:46 UTC
[asterisk-users] error messages related to mysql in asterisk CLI
Ciao Jody,> hi there :) > i get this error in the asterisk CLI: > > Sep 21 20:31:49 ERROR[3774]: cdr_addon_mysql.c:159 mysql_log: cdr_mysql: > Unknown connection error: > (2006) MySQL server has gone away > > when I run 'cdr mysql status' i get: > Connected to voiceone at localhost, port 3306 using table cdr for 18 minutes, 24 > seconds. Wrote 8 records since last restart and 1 records since last > reconnect.This is not an error, and in fact should be printed as a WARNING instead of being printed as an ERROR. IIRC I even submitted a small patch to change this behaviour.. Should check its status. Don't worry, it's a normal message. :) It's only annoying. Bye, -- Dott. Andrea Spadaccini Multimedia Technologies Institute s.r.l.