From: Paul Cassella <pwc@speakeasy.net>
To: Andi Kleen <ak@suse.de>, davem@redhat.com
Cc: linux-kernel@vger.kernel.org, linux-net@vger.kernel.org
Subject: Re: 2.4.0-ac3 write() to tcp socket returning errno of -3 (ESRCH: "No such process")
Date: Mon, 8 Jan 2001 01:54:25 -0600 (CST) [thread overview]
Message-ID: <Pine.LNX.4.21.0101080116330.2261-100000@localhost> (raw)
In-Reply-To: <20010108073512.A29905@gruyere.muc.suse.de>
On Mon, 8 Jan 2001, Andi Kleen wrote:
> On Sun, Jan 07, 2001 at 11:55:28PM -0600, Paul Cassella wrote:
> > write() returns -1 and sets errno non-sensically. 2.4.0{,-ac[23]}
> Would it be possible to provide a compiling test case that shows these
> errors ?
The CVS version (perhaps even version 0.12) of gtk-gnutella should do it,
though it's not exactly what I'm running. After the crash I posted about,
I've been running it for another three and a half hours under similar
load, and it hasn't crashed again yet; nor have I seen any other
unexpected ret's (besides those noted below) get logged.
http://gtk-gnutella.sourceforge.net/cvs/
Though I don't think gtk-gnutella is special. It doesn't do anything
programmatically unusual with sockets, it just has a bunch of connections
to a bunch of different machines, which are probably running a bunch of
different os's, etc. And it aborts when write() returns unexpected
values.
I've appended the actual kernel diffs that I'm using; I'd just pasted them
from an xterm before. I probably should have added ECONNREFUSED and
ERESTARTSYS to the list.
> Also over what interface do you run it?
eth0 (tulip):
01:08.0 Ethernet controller: Lite-On Communications Inc LNE100TX (rev 21)
In answer to David's questions, I don't think I'm doing anything out of
the ordinary. I'm running over DSL with the above card on an external DSL
router. No netfilter, no tunneling, just IP.
CONFIG_PACKET=m
CONFIG_PACKET_MMAP=y
CONFIG_NETLINK=y
CONFIG_RTNETLINK=y
CONFIG_NETLINK_DEV=m
# CONFIG_NETFILTER is not set
# CONFIG_FILTER is not set
CONFIG_UNIX=y
CONFIG_INET=y
# CONFIG_IP_MULTICAST is not set
# CONFIG_IP_ADVANCED_ROUTER is not set
# CONFIG_IP_PNP is not set
# CONFIG_NET_IPIP is not set
# CONFIG_NET_IPGRE is not set
# CONFIG_ARPD is not set
CONFIG_INET_ECN=y
CONFIG_SYN_COOKIES=y
CONFIG_IPV6=m
# CONFIG_IPV6_EUI64 is not set
# CONFIG_KHTTPD is not set
# CONFIG_ATM is not set
# CONFIG_IPX is not set
# CONFIG_ATALK is not set
# CONFIG_DECNET is not set
# CONFIG_BRIDGE is not set
# CONFIG_X25 is not set
# CONFIG_LAPB is not set
# CONFIG_LLC is not set
# CONFIG_NET_DIVERT is not set
# CONFIG_ECONET is not set
# CONFIG_WAN_ROUTER is not set
# CONFIG_NET_FASTROUTE is not set
# CONFIG_NET_HW_FLOWCONTROL is not set
CONFIG_DUMMY=m
CONFIG_TULIP=y
I have these set, but I haven't used them:
CONFIG_PPP=m
# CONFIG_PPP_MULTILINK is not set
CONFIG_PPP_ASYNC=m
# CONFIG_PPP_SYNC_TTY is not set
CONFIG_PPP_DEFLATE=m
CONFIG_PPP_BSDCOMP=m
eth0 Link encap:Ethernet HWaddr 00:A0:CC:3E:E6:63
inet addr:64.81.146.215 Bcast:64.81.146.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:674842 errors:0 dropped:0 overruns:0 frame:0
TX packets:791977 errors:0 dropped:0 overruns:0 carrier:0
collisions:490 txqueuelen:100
Interrupt:11 Base address:0xd800
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:3856 Metric:1
RX packets:1138 errors:0 dropped:0 overruns:0 frame:0
TX packets:1138 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
Destination Gateway Genmask Flags Metric Ref Use Iface
64.81.146.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
0.0.0.0 64.81.146.1 0.0.0.0 UG 0 0 0 eth0
Is there a list somewhere of network options I should report (such as
filtering and tunneling)?
Should one of linux-kernel or linux-net be pruned from the Cc: list?
--
Paul Cassella
--- fs/read_write.c~ Sat Nov 11 18:07:38 2000
+++ fs/read_write.c Sun Jan 7 14:00:25 2001
@@ -146,6 +146,8 @@
ssize_t ret;
struct file * file;
+extern struct file_operations socket_file_ops;
+
ret = -EBADF;
file = fget(fd);
if (file) {
@@ -165,6 +167,18 @@
DN_MODIFY);
fput(file);
}
+ if(ret < 0 && file && file->f_op == &socket_file_ops ) {
+ switch(-ret) {
+ case EAGAIN: case EBADF: case EPIPE: case ENOSPC: case EIO: case ECONNRESET:
+ case EINTR: case ETIMEDOUT: case EFAULT: case EINVAL: case EMSGSIZE: case ENOMEM:
+ case ENOBUFS: case ENOTCONN:
+ break;
+
+ default:
+ printk(KERN_ERR "sys_write: ret is unexpectedly %d.\n", ret);
+ }
+ }
+
return ret;
}
--- net/socket.c~ Mon Jan 8 01:26:55 2001
+++ net/socket.c Sun Jan 7 13:58:55 2001
@@ -111,7 +111,7 @@
* in the operation structures but are done directly via the socketcall() multiplexor.
*/
-static struct file_operations socket_file_ops = {
+struct file_operations socket_file_ops = {
llseek: sock_lseek,
read: sock_read,
write: sock_write,
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
next prev parent reply other threads:[~2001-01-08 7:57 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-01-08 5:55 Paul Cassella
2001-01-08 5:58 ` David S. Miller
2001-01-08 7:16 ` Paul Cassella
2001-01-08 7:05 ` David S. Miller
2001-01-08 6:35 ` Andi Kleen
2001-01-08 7:54 ` Paul Cassella [this message]
[not found] <3A5B0A59.1EB60A88@uow.edu.au>
2001-01-09 14:03 ` Paul Cassella
2001-01-11 16:45 ` Paul Cassella
2001-01-11 17:18 ` David S. Miller
2001-01-12 10:52 ` 2.4.0-ac3 write() to tcp socket returning errno of -3 (ESRCH:"No " Andrew Morton
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.21.0101080116330.2261-100000@localhost \
--to=pwc@speakeasy.net \
--cc=ak@suse.de \
--cc=davem@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-net@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®