Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!xlned.com!feeder7.xlned.com!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.023 X-Spam-Evidence: '*H*': 0.95; '*S*': 0.00; 'causing': 0.04; 'subject:reset': 0.07; '22,': 0.09; 'indicates': 0.09; 'received:209.85.219': 0.09; 'subject:peer': 0.09; 'python': 0.11; 'sockets': 0.16; 'tcp': 0.16; 'exception': 0.16; 'wrote:': 0.18; 'wed,': 0.18; 'cc:addr:gmail.com': 0.22; 'email addr:gmail.com>': 0.22; 'reset': 0.22; 'to:name:python- list@python.org': 0.22; 'error': 0.23; 'typical': 0.24; '\xa0if': 0.24; 'cc:2**0': 0.24; 'header:In-Reply-To:1': 0.27; 'am,': 0.29; 'message-id:@mail.gmail.com': 0.30; 'url:mailman': 0.30; 'code': 0.31; 'getting': 0.31; 'this.': 0.32; 'url:python': 0.33; 'received:209.85': 0.35; 'connection': 0.35; 'except': 0.35; 'received:google.com': 0.35; 'there': 0.35; 'version': 0.36; 'really': 0.36; '2.6': 0.36; 'url:listinfo': 0.36; 'url:org': 0.36; 'received:209': 0.37; 'skip:& 10': 0.38; 'to:addr:python- list': 0.38; 'anything': 0.39; 'skip:& 20': 0.39; 'to:addr:python.org': 0.39; 'url:mail': 0.40; 'catch': 0.60; 'subject:"': 0.60; 'establish': 0.61; 'simply': 0.61; "you're": 0.61; 'connecting': 0.64; 'within': 0.65; 'here': 0.66; 'fin': 0.84; 'treating': 0.84; '2013': 0.98 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=ptgAXa5ymhmeGrQDN+OoAUpmRWe3ykeI8ONxpG4avcE=; b=NOAq3M5/06H1vYndPHlYWHrUXxSsVON0hw7crB9hsDM3wj4a49ZR6StqMuRJKix1zZ 0gl9X0qN/J7rxJBONGxej0oJMUR5CikSR5K4sdkfzTgy9NmLM8g1T6kmkEtMvYASWLan UA4JPlZFRNImCEO1lTN4piXs7Tb5sqMP4ikLnjsEMQ/CUpTAv/50diJdR7vpWA5EHx3H gMj5N+LuikSMnqyO6gRnSTctyUqCzrL84df93t58FLcdDeHlzbYYCLCk6DWIwpZKekbJ NAOo4x0g6n5vEBcY/k2aZdfXqThE+zDNHpDyfrbFGH0HJEtIkwY6Ln6w04jyMa4zwMsA aBCw== X-Received: by 10.182.80.5 with SMTP id n5mr4299608obx.88.1369223202304; Wed, 22 May 2013 04:46:42 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <038ecc3e-1272-46c0-84d5-556daeffbde0@googlegroups.com> References: <038ecc3e-1272-46c0-84d5-556daeffbde0@googlegroups.com> From: Matt Jones Date: Wed, 22 May 2013 06:46:22 -0500 Subject: Re: Diagnosing socket "Connection reset by peer" To: "python-list@python.org" Content-Type: multipart/alternative; boundary=047d7b2e4146977a0c04dd4d1e15 Cc: loial X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 74 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1369223210 news.xs4all.nl 15990 [2001:888:2000:d::a6]:49115 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:45724 --047d7b2e4146977a0c04dd4d1e15 Content-Type: text/plain; charset=ISO-8859-1 This typically indicates that the "peer" at the other end of the tcp connection severed the session without the typical FIN packet. If you're treating the printer as a "blackbox" then there really isn't anything you can do here except catch the exception and attempt to reconnect. *Matt Jones* On Wed, May 22, 2013 at 3:46 AM, loial wrote: > I have a sockets client that is connecting to a printer and occassionally > getting the error "104 Connection reset by peer" > > I have not been able to diagnose what is causing this. Is there any > additional traceing I can do(either within my python code or on the > network) to establish what is causing this error? > > Currently I am simply trapping socket.erruor > > Python version is 2.6 > > > > > > > -- > http://mail.python.org/mailman/listinfo/python-list > --047d7b2e4146977a0c04dd4d1e15 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
This typically indicates that the= "peer" at the other end of the tcp connection severed the sessio= n without the typical FIN packet. =A0If you're treating the printer as = a "blackbox" then there really isn't anything you can do here= except catch the exception and attempt to reconnect.

Matt Jones

On Wed, May 22, 2013 at 3:46 AM, loial <= span dir=3D"ltr"><jldunn2000@gmail.com> wrote:
I have a sockets client that is connecting to a printer and occassionally g= etting the error "104 Connection reset by peer"

I have not been able to diagnose what is causing this. Is there any additio= nal traceing I can do(either within my python code or on the network) to es= tablish what is causing this error?

Currently I am simply trapping socket.erruor

Python version is 2.6






--
http://mail.python.org/mailman/listinfo/python-list

--047d7b2e4146977a0c04dd4d1e15--