hrolsons
asked on
"Bad File Descriptor" in FreeBSD
I was having trouble writing to a directory so I got on the server and for that directory it said "Bad File Descriptor".
Does anyone know how to fix this?
Does anyone know how to fix this?
File corruption, have you run an fsck yet?
ASKER
I have not, I'll look up how to do that.
ASKER
My hosting company ran the fsck and I'm still getting the error.
How do you upload the file? Where do you get the error?
"Bad file descriptor" is a probable sign of software bug - closing file and then writing to descriptor. or writing to TCP connection when it was not open etc etc.
"Bad file descriptor" is a probable sign of software bug - closing file and then writing to descriptor. or writing to TCP connection when it was not open etc etc.
ASKER
I'm uploading the file via a Visual Basic program I wrote.
Is it a windows error or a error text in (FTP) protocol or a error logged somewhere on UNIX side?
ASKER
I get "Path Not Found" on the FTP side, but when I look up the file in unix doing a "ls -li" is where I see the "Bad File Descriptor".
i would tend to think that there is a problem with your FTP server software. namely it loses file descriptor on otherwise "good" error.
try another FTP server?
try another FTP server?
ASKER
Yes, but taking FTP out of the equation all together I still see the error when I'm in an SSH session and issue "ls -li".
On particular freebsd system - are userland and kernel versions matching? (you cannot check userland, but if uname -a says either -p[0-9]* or -current somewhere it is a clear sign that patched kernel was installed likely without updating userland (by means of make world)
ASKER
When I run uname -a I get:
FreeBSD xxx-xx-xxx-xxx.dedicated.a bac.net 7.1-RELEASE-p11 FreeBSD 7.1-RELEASE-p11 #0: Fri Feb 26 18:34:31 UTC 2010 root@i386-builder.daemonol ogy.net:/u sr/obj/usr /src/sys/G ENERIC i386
I'm not sure what userland is and will search Google and learn more about it.
FreeBSD xxx-xx-xxx-xxx.dedicated.a
I'm not sure what userland is and will search Google and learn more about it.
You have patched kernel.
It might happen that respective userland aka all programs included in system, was not installed. Sadly they are not well versioned.
You can try recompiling "ls" command alone (in usr.bin)
It might happen that respective userland aka all programs included in system, was not installed. Sadly they are not well versioned.
You can try recompiling "ls" command alone (in usr.bin)
ASKER
I ended up sending all files to a new directory and deleting the old and it seems to be working fine. Not sure what the speedbump was but it seems to be in the past.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.