mysql server has gone away

mysql server has gone away

am 20.11.2003 19:18:52 von Mayuran

Hi,

We are considering upgrading our production servers from using MySQL
3.23 to
MySQL 4.0 so I was asked to see how our scripts work with v4. I
installed v4 on
one of our test environments and immediately saw this:

DBD::mysql::st execute failed: MySQL server has gone away.

I googled it and read the suggestions in the MySQL documentation and
increased
the allowed packet size to max_allowed_packet = 256. This did not fix
it. Also, I
know that the connection isnt timing out.

Can someone please offer some advice on the matter, I am stumped. I
noticed that
if I set : $dbh->{mysql_auto_reconnect} = 1 in my code that the problem
appears
to go away, but I still dont know what the real problem was, or if this
auto_reconnect
setting is causing any harm.

Any input is much appreciated,

Thank you

M. Yogarajah


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: mysql server has gone away

am 20.11.2003 19:25:10 von Rudy Lippan

On Thu, 20 Nov 2003, Mayuran wrote:

> Hi,
>
> We are considering upgrading our production servers from using MySQL
> 3.23 to
> MySQL 4.0 so I was asked to see how our scripts work with v4. I
> installed v4 on
> one of our test environments and immediately saw this:
>
> DBD::mysql::st execute failed: MySQL server has gone away.
>
> I googled it and read the suggestions in the MySQL documentation and
> increased
> the allowed packet size to max_allowed_packet = 256. This did not fix
> it. Also, I
> know that the connection isnt timing out.
>
> Can someone please offer some advice on the matter, I am stumped. I
> noticed that
> if I set : $dbh->{mysql_auto_reconnect} = 1 in my code that the problem
> appears
> to go away, but I still dont know what the real problem was, or if this
> auto_reconnect
> setting is causing any harm.

Do you have some sample code that causes the problem?


Rudy



--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: mysql server has gone away

am 20.11.2003 19:25:10 von Rudy Lippan

On Thu, 20 Nov 2003, Mayuran wrote:

> Hi,
>
> We are considering upgrading our production servers from using MySQL
> 3.23 to
> MySQL 4.0 so I was asked to see how our scripts work with v4. I
> installed v4 on
> one of our test environments and immediately saw this:
>
> DBD::mysql::st execute failed: MySQL server has gone away.
>
> I googled it and read the suggestions in the MySQL documentation and
> increased
> the allowed packet size to max_allowed_packet = 256. This did not fix
> it. Also, I
> know that the connection isnt timing out.
>
> Can someone please offer some advice on the matter, I am stumped. I
> noticed that
> if I set : $dbh->{mysql_auto_reconnect} = 1 in my code that the problem
> appears
> to go away, but I still dont know what the real problem was, or if this
> auto_reconnect
> setting is causing any harm.

Do you have some sample code that causes the problem?


Rudy



--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

import/export problem

am 10.12.2003 21:22:20 von lshen

Hi,
we are doing sybase migration to mysql, we have some problem for import
tables (data) into mysql database. Dose anyone have any idea in mysql import
comand?
thank you

Brian
----- Original Message -----
From: "Rudy Lippan"
To: "Mayuran"
Cc:
Sent: Thursday, November 20, 2003 1:25 PM
Subject: Re: mysql server has gone away


> On Thu, 20 Nov 2003, Mayuran wrote:
>
> > Hi,
> >
> > We are considering upgrading our production servers from using MySQL
> > 3.23 to
> > MySQL 4.0 so I was asked to see how our scripts work with v4. I
> > installed v4 on
> > one of our test environments and immediately saw this:
> >
> > DBD::mysql::st execute failed: MySQL server has gone away.
> >
> > I googled it and read the suggestions in the MySQL documentation and
> > increased
> > the allowed packet size to max_allowed_packet = 256. This did not fix
> > it. Also, I
> > know that the connection isnt timing out.
> >
> > Can someone please offer some advice on the matter, I am stumped. I
> > noticed that
> > if I set : $dbh->{mysql_auto_reconnect} = 1 in my code that the problem
> > appears
> > to go away, but I still dont know what the real problem was, or if this
> > auto_reconnect
> > setting is causing any harm.
>
> Do you have some sample code that causes the problem?
>
>
> Rudy
>
>
>
> --
> MySQL Perl Mailing List
> For list archives: http://lists.mysql.com/perl
> To unsubscribe:
http://lists.mysql.com/perl?unsub=lshen@pop900.gsfc.nasa.gov
>
>


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

import/export problem

am 10.12.2003 21:22:20 von lshen

Hi,
we are doing sybase migration to mysql, we have some problem for import
tables (data) into mysql database. Dose anyone have any idea in mysql import
comand?
thank you

Brian
----- Original Message -----
From: "Rudy Lippan"
To: "Mayuran"
Cc:
Sent: Thursday, November 20, 2003 1:25 PM
Subject: Re: mysql server has gone away


> On Thu, 20 Nov 2003, Mayuran wrote:
>
> > Hi,
> >
> > We are considering upgrading our production servers from using MySQL
> > 3.23 to
> > MySQL 4.0 so I was asked to see how our scripts work with v4. I
> > installed v4 on
> > one of our test environments and immediately saw this:
> >
> > DBD::mysql::st execute failed: MySQL server has gone away.
> >
> > I googled it and read the suggestions in the MySQL documentation and
> > increased
> > the allowed packet size to max_allowed_packet = 256. This did not fix
> > it. Also, I
> > know that the connection isnt timing out.
> >
> > Can someone please offer some advice on the matter, I am stumped. I
> > noticed that
> > if I set : $dbh->{mysql_auto_reconnect} = 1 in my code that the problem
> > appears
> > to go away, but I still dont know what the real problem was, or if this
> > auto_reconnect
> > setting is causing any harm.
>
> Do you have some sample code that causes the problem?
>
>
> Rudy
>
>
>
> --
> MySQL Perl Mailing List
> For list archives: http://lists.mysql.com/perl
> To unsubscribe:
http://lists.mysql.com/perl?unsub=lshen@pop900.gsfc.nasa.gov
>
>


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: import/export problem

am 11.12.2003 18:18:04 von Jerry Rocteur

Hi Brian,

I hope I've understood your question...

mysqlimport works as expected and is well documented but you'll need
version 3.22.15 or better. (this is when LOAD DATA LOCAL was added to
the client.

mysqlimport
mysqlimport Ver 3.4 Distrib 4.0.15, for apple-darwin6.4 (powerpc)
Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL license

Loads tables from text files in various formats. The base name of the
text file must be the name of the table that should be used.
If one uses sockets to connect to the MySQL server, the server will
open and
read the text file directly. In other cases the client will open the
text
file. The SQL command 'LOAD DATA INFILE' is used to import the rows.

Usage: mysqlimport [OPTIONS] database textfile...
Default options are read from the following files in the given order:
/etc/my.cnf /usr/local/mysql/data/my.cnf ~/.my.cnf
The following groups are read: mysqlimport client
The following options may be given as the first argument:
--print-defaults Print the program argument list and exit
--no-defaults Don't read default options from any options file
--defaults-file=# Only read default options from the given file #
--defaults-extra-file=# Read this file after the global files are read
--character-sets-dir=name
Directory where character sets are
--default-character-set=name
Set the default character set.
-c, --columns=name Use only these columns to import the data to.
Give the
column names in a comma separated list. This is
same as
giving columns to LOAD DATA INFILE.
-C, --compress Use compression in server/client protocol.
-#, --debug[=name] Output debug log. Often this is 'd:t:o,filename'
-d, --delete First delete all rows from table.
--fields-terminated-by=name
Fields in the textfile are terminated by ...
--fields-enclosed-by=name
Fields in the importfile are enclosed by ...
--fields-optionally-enclosed-by=name
Fields in the i.file are opt. enclosed by ...
--fields-escaped-by=name
Fields in the i.file are escaped by ...
-f, --force Continue even if we get an sql-error.
-?, --help Displays this help and exits.
-h, --host=name Connect to host.
-i, --ignore If duplicate unique key was found, keep old row.
--ignore-lines=name Ignore first n lines of data infile.
--lines-terminated-by=name
Lines in the i.file are terminated by ...
-L, --local Read all files through the client
-l, --lock-tables Lock all tables for write.
--low-priority Use LOW_PRIORITY when updating the table
-p, --password[=name]
Password to use when connecting to server. If
password is
not given it's asked from the tty.
-P, --port=# Port number to use for connection.
-r, --replace If duplicate unique key was found, replace old
row.
-s, --silent Be more silent.
-S, --socket=name Socket file to use for connection.
-u, --user=name User for login if not current user.
-v, --verbose Print info about the various stages.
-V, --version Output version information and exit.

Variables (--variable-name=value)
and boolean options {FALSE|TRUE} Value (after reading options)
--------------------------------- -----------------------------
character-sets-dir (No default value)
default-character-set (No default value)
columns (No default value)
compress FALSE
delete FALSE
fields-terminated-by (No default value)
fields-enclosed-by (No default value)
fields-optionally-enclosed-by (No default value)
fields-escaped-by (No default value)
force FALSE
host incc-test
ignore FALSE
ignore-lines (No default value)
lines-terminated-by (No default value)
local FALSE
lock-tables FALSE
low-priority FALSE
port 3306
replace FALSE
silent FALSE
socket (No default value)
user jerry
verbose FALSE
On Wednesday, Dec 10, 2003, at 21:22 Europe/Brussels, lshen wrote:

> Hi,
> we are doing sybase migration to mysql, we have some problem for import
> tables (data) into mysql database. Dose anyone have any idea in mysql
> import
> comand?
> thank you
>
> Brian
>
>


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: import/export problem

am 11.12.2003 18:18:04 von Jerry Rocteur

Hi Brian,

I hope I've understood your question...

mysqlimport works as expected and is well documented but you'll need
version 3.22.15 or better. (this is when LOAD DATA LOCAL was added to
the client.

mysqlimport
mysqlimport Ver 3.4 Distrib 4.0.15, for apple-darwin6.4 (powerpc)
Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL license

Loads tables from text files in various formats. The base name of the
text file must be the name of the table that should be used.
If one uses sockets to connect to the MySQL server, the server will
open and
read the text file directly. In other cases the client will open the
text
file. The SQL command 'LOAD DATA INFILE' is used to import the rows.

Usage: mysqlimport [OPTIONS] database textfile...
Default options are read from the following files in the given order:
/etc/my.cnf /usr/local/mysql/data/my.cnf ~/.my.cnf
The following groups are read: mysqlimport client
The following options may be given as the first argument:
--print-defaults Print the program argument list and exit
--no-defaults Don't read default options from any options file
--defaults-file=# Only read default options from the given file #
--defaults-extra-file=# Read this file after the global files are read
--character-sets-dir=name
Directory where character sets are
--default-character-set=name
Set the default character set.
-c, --columns=name Use only these columns to import the data to.
Give the
column names in a comma separated list. This is
same as
giving columns to LOAD DATA INFILE.
-C, --compress Use compression in server/client protocol.
-#, --debug[=name] Output debug log. Often this is 'd:t:o,filename'
-d, --delete First delete all rows from table.
--fields-terminated-by=name
Fields in the textfile are terminated by ...
--fields-enclosed-by=name
Fields in the importfile are enclosed by ...
--fields-optionally-enclosed-by=name
Fields in the i.file are opt. enclosed by ...
--fields-escaped-by=name
Fields in the i.file are escaped by ...
-f, --force Continue even if we get an sql-error.
-?, --help Displays this help and exits.
-h, --host=name Connect to host.
-i, --ignore If duplicate unique key was found, keep old row.
--ignore-lines=name Ignore first n lines of data infile.
--lines-terminated-by=name
Lines in the i.file are terminated by ...
-L, --local Read all files through the client
-l, --lock-tables Lock all tables for write.
--low-priority Use LOW_PRIORITY when updating the table
-p, --password[=name]
Password to use when connecting to server. If
password is
not given it's asked from the tty.
-P, --port=# Port number to use for connection.
-r, --replace If duplicate unique key was found, replace old
row.
-s, --silent Be more silent.
-S, --socket=name Socket file to use for connection.
-u, --user=name User for login if not current user.
-v, --verbose Print info about the various stages.
-V, --version Output version information and exit.

Variables (--variable-name=value)
and boolean options {FALSE|TRUE} Value (after reading options)
--------------------------------- -----------------------------
character-sets-dir (No default value)
default-character-set (No default value)
columns (No default value)
compress FALSE
delete FALSE
fields-terminated-by (No default value)
fields-enclosed-by (No default value)
fields-optionally-enclosed-by (No default value)
fields-escaped-by (No default value)
force FALSE
host incc-test
ignore FALSE
ignore-lines (No default value)
lines-terminated-by (No default value)
local FALSE
lock-tables FALSE
low-priority FALSE
port 3306
replace FALSE
silent FALSE
socket (No default value)
user jerry
verbose FALSE
On Wednesday, Dec 10, 2003, at 21:22 Europe/Brussels, lshen wrote:

> Hi,
> we are doing sybase migration to mysql, we have some problem for import
> tables (data) into mysql database. Dose anyone have any idea in mysql
> import
> comand?
> thank you
>
> Brian
>
>


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org