Error in accept: Bad file descriptor

Error in accept: Bad file descriptor

Post by Todd Ratso » Thu, 24 Jan 2002 03:25:39



Hi All,

I have an OpenBSD box running mysql-3.23.47, php4.1.1 & Apache 1.3.22.
I have been using php-nuke on it for some time now without incident
until today...

I have tried to create a new database in order to add another nuke based
site to this server and I can't seem to import the sql file.  This file
is the same one I used to create the original (nuke 5.3.1) database.  I
have tried importing it in the shell and through phpMyAdmin-2.2.3

I always get an error stating that mysql cannot modify a .frm file.  I
downloaded a new copy of the sql file in case it was corrupt but I get
the same error in a different .frm file.  I then dumped a backup of the
functioning db through phpMyAdmin and tried to import this sql file into
a new db with the same results.

An example of a table create that frequently fails and the error message
is as follows:

CREATE TABLE nuke_authors (
  aid varchar(30) NOT NULL default '',
  name varchar(50) default NULL,
  url varchar(60) default NULL,
  email varchar(60) default NULL,
  pwd varchar(13) default NULL,
  counter int(11) NOT NULL default '0',
  radminarticle tinyint(2) NOT NULL default '0',
  radmintopic tinyint(2) NOT NULL default '0',
  radminuser tinyint(2) NOT NULL default '0',
  radminsurvey tinyint(2) NOT NULL default '0',
  radminsection tinyint(2) NOT NULL default '0',
  radminlink tinyint(2) NOT NULL default '0',
  radminephem tinyint(2) NOT NULL default '0',
  radminfilem tinyint(2) NOT NULL default '0',
  radminfaq tinyint(2) NOT NULL default '0',
  radmindownload tinyint(2) NOT NULL default '0',
  radminreviews tinyint(2) NOT NULL default '0',
  radminnewsletter tinyint(2) NOT NULL default '0',
  radminsuper tinyint(2) NOT NULL default '1',
  admlanguage varchar(30) NOT NULL default '',
  PRIMARY KEY  (aid)
) TYPE=MyISAM;

INSERT INTO nuke_authors VALUES
('God','God','http://phpnuke.org','http://phpnuke.org','Password',0,0,0,
0,0,0,0,0,0,0,0,0,0,1,'');

MySQL said:
Can't create/write to file './test/nuke_authors.frm'

I have even tried to manually copy the files in the db
ie: cp -R /usr/local/mysql/var/db1/ /usr/local/var/db2/

When done this way, mysql crashes when I query the db:

SQL-query :  
SHOW TABLE STATUS FROM `sample`
MySQL said:
Can't read dir of './sample/' (Errcode: 9)

The console is reporting the following error:

020122 10:50:35  Error in accept: Bad file descriptor

mysql then crashes and I need to restart it.

I am running mysql with the following command:

/usr/local/mysql/libexec/mysqld --no-defaults --user=mysqld &

the mysqld user owns all the files including the var dir.

Anyone experience this type of malfunction before?

Todd Ratson
System Administrator
Canadian Mental Health Association for the East Kootenay

icq# 132791172
(250) 426-5222

Give a person a fish and it will feed them for a day. Teach a person to
fish and it will feed them for a lifetime.

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)



Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

 
 
 

Error in accept: Bad file descriptor

Post by Michael Wideni » Fri, 25 Jan 2002 18:41:08


Hi!

Todd> Hi All,

Todd> I have an OpenBSD box running mysql-3.23.47, php4.1.1 & Apache 1.3.22.
Todd> I have been using php-nuke on it for some time now without incident
Todd> until today...

Todd> I have tried to create a new database in order to add another nuke based
Todd> site to this server and I can't seem to import the sql file.  This file
Todd> is the same one I used to create the original (nuke 5.3.1) database.  I
Todd> have tried importing it in the shell and through phpMyAdmin-2.2.3

Todd> I always get an error stating that mysql cannot modify a .frm file.  I
Todd> downloaded a new copy of the sql file in case it was corrupt but I get
Todd> the same error in a different .frm file.  I then dumped a backup of the
Todd> functioning db through phpMyAdmin and tried to import this sql file into
Todd> a new db with the same results.

Todd> An example of a table create that frequently fails and the error message
Todd> is as follows:

<cut>

Todd> MySQL said:
Todd> Can't create/write to file './test/nuke_authors.frm'

Todd> I have even tried to manually copy the files in the db
Todd> ie: cp -R /usr/local/mysql/var/db1/ /usr/local/var/db2/

Todd> When done this way, mysql crashes when I query the db:

Todd> SQL-query :  
Todd> SHOW TABLE STATUS FROM `sample`
Todd> MySQL said:
Todd> Can't read dir of './sample/' (Errcode: 9)

The above is very strange error:

-------
(~) perror 9
Error code   9:  Bad file descriptor
-------

This is something that should never happen.
Normally the problem in cases like this are that the mysqld process
doesn't have the right to read/write to the database files, but it
doesn't appear to be that in this case.

Todd> The console is reporting the following error:

Todd> 020122 10:50:35  Error in accept: Bad file descriptor

I wonder if the error from accept could somehow influence
the error from show table status or vice versa.

<cut>

If you could generate a trace file when this happens and send it to
ftp://support.mysql.com/pub/mysql/secret
we would try to solve this for you.

The manual section at:

http://www.mysql.com/doc/M/a/Making_trace_files.html

tells you everything you need to know about how to make a MySQL trace
file.

Regards,
Monty

--
For technical support contracts, goto https://order.mysql.com/
   __  ___     ___ ____  __

 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, CTO
/_/  /_/\_, /___/\___\_\___/   Helsinki, Finland
       <___/   www.mysql.com

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)



Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php