From unknown Sun Jun 22 00:02:06 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#7483 <7483@debbugs.gnu.org> To: bug#7483 <7483@debbugs.gnu.org> Subject: Status: Tail claims bad file descriptor when following Reply-To: bug#7483 <7483@debbugs.gnu.org> Date: Sun, 22 Jun 2025 07:02:06 +0000 retitle 7483 Tail claims bad file descriptor when following reassign 7483 coreutils submitter 7483 Johan Pretorius severity 7483 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 26 03:44:18 2010 Received: (at submit) by debbugs.gnu.org; 26 Nov 2010 08:44:19 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PLtuj-0007XY-T5 for submit@debbugs.gnu.org; Fri, 26 Nov 2010 03:44:18 -0500 Received: from eggs.gnu.org ([140.186.70.92]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PLtrx-0007TJ-Na for submit@debbugs.gnu.org; Fri, 26 Nov 2010 03:41:26 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PLtwU-0004WA-2N for submit@debbugs.gnu.org; Fri, 26 Nov 2010 03:46:51 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, HTML_FONT_FACE_BAD,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,T_DKIM_INVALID, T_TO_NO_BRKTS_FREEMAIL autolearn=no version=3.3.1 Received: from lists.gnu.org ([199.232.76.165]:50662) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PLtwT-0004W3-Me for submit@debbugs.gnu.org; Fri, 26 Nov 2010 03:46:06 -0500 Received: from [140.186.70.92] (port=50448 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PLtvl-0003MR-VX for bug-coreutils@gnu.org; Fri, 26 Nov 2010 03:46:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PLtuv-0004Dp-Vq for bug-coreutils@gnu.org; Fri, 26 Nov 2010 03:45:11 -0500 Received: from mail-fx0-f41.google.com ([209.85.161.41]:52175) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PLtuv-0004DU-IJ for bug-coreutils@gnu.org; Fri, 26 Nov 2010 03:44:29 -0500 Received: by fxm13 with SMTP id 13so1101410fxm.0 for ; Fri, 26 Nov 2010 00:44:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=SGZKy7OkB5ySHUfe/QYjN1vOAk5VRNbmAP51WC9/Zio=; b=j95cPgyFWZzLdlfqYsL0nahd1cCyGYUkpwSiGQiwp6a3vxQj5mnsZlYddHACTxook9 4o/uioUvyMu+urQAmejJjYBW0RM3OabzPGgnvu5ezINIF7EVHj4JHuEP9XBKPW6JM9AB iYk3t3iN3HFOT9tCeJU6GNGcw6ptH4KuY5OKE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=X6V0YqhOPlbmmynbb+icX/4cZu6zmV3kAiNIZcTwA+Q94L6ukG9IAMamvvWjZeqZcy ldzGX2fWKBTACrp81wr53ja0kMhyh5s38Xnqe9UWHq189j2gkvFsbFwdsg9DDxjbD3Jp Pit4feNs5EtRKneS1YAOts0CvOKPh+vL/E+l4= MIME-Version: 1.0 Received: by 10.223.70.136 with SMTP id d8mr1790473faj.3.1290761068059; Fri, 26 Nov 2010 00:44:28 -0800 (PST) Received: by 10.223.107.212 with HTTP; Fri, 26 Nov 2010 00:44:28 -0800 (PST) Date: Fri, 26 Nov 2010 10:44:28 +0200 Message-ID: Subject: Tail claims bad file descriptor when following From: Johan Pretorius To: bug-coreutils@gnu.org Content-Type: multipart/alternative; boundary=00248c11da37f39e600495f0bae5 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Fri, 26 Nov 2010 03:44:16 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -5.0 (-----) --00248c11da37f39e600495f0bae5 Content-Type: text/plain; charset=ISO-8859-1 Hi there, I use tail 5.3.0 in Windows 7. It works fine unless I try to follow a file. Here is my --version output: C:\>tail --version tail (GNU coreutils) 5.3.0 Written by Paul Rubin, David MacKenzie, Ian Lance Taylor, and Jim Meyering. Copyright (C) 2005 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. The following works as expected with no error messages. tail \\ssb-batman\logs\batman\build.log However, if I try to follow, it gives output as follows. C:\>tail -f \\ssb-batman\logs\batman\build.log [INFO] Unpacking C:\p4ws\depot_cfg\ssb\trunk\postilion\ssb\postgen\target\postgen-izpack.zip to C:\p4ws\depot_cfg\ssb\trunk\postilion\ssb_installer\target\staging with includes null and excludes:null [INFO] Unpacking C:\p4ws\depot_cfg\ssb\trunk\postilion\ssb\scheduleinjector\target\scheduleinjector-izpack.zip to C:\p4ws\depot_cfg\ssb\trunk\postilion\ssb_installer\target\staging with includes null and excludes:null [INFO] Unpacking C:\p4ws\depot_cfg\ssb\trunk\postilion\ssb\services\target\services-izpack.zip to C:\p4ws\depot_cfg\ssb\trunk\postilion\ssb_installer\target\staging with includes null and excludes:null tail: \\ssb-batman\logs\batman\build.log: Bad file descriptor tail: no files remaining Why is tail suddenly claiming that the file descriptor is bad, when clearly it works just fine? So I tried some different things to see if I could get it to work. I tried tail --follow=\\ssb-batman\logs\batman\build.log but that just gives an even stranger error: tail: invalid argument `\\\\ssb-batman\\logs\\batman\\build.log' for `--follow' Valid arguments are: - `descriptor' - `name' Try `tail --help' for more information. I thought at first that maybe tail does not like the UNC path, but that is not the case - it does exactly the same when I use a local file. If I add --retry to the mix, I get the following very interesting reaction: It prints out the last few lines, throws out the same error as before, then prints out the entire file! This is what it looks like: C:\>tail -f "\\ssb-batman\logs\batman\build.log" --retry tail: warning: --retry is useful only when following by name [INFO] CfgSystemInfoExt ...................................... SUCCESS [4.328s] [INFO] SSB Installer ......................................... SUCCESS [1:28.422s] [INFO] ------------------------------------------------------------------------ [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESSFUL [INFO] ------------------------------------------------------------------------ [INFO] Total time: 22 minutes 54 seconds [INFO] Finished at: Fri Nov 26 10:11:17 GMT+02:00 2010 [INFO] Final Memory: 66M/1016M [INFO] ------------------------------------------------------------------------ tail: \\ssb-batman\logs\batman\build.log: Bad file descriptor tail: `\\ssb-batman\logs\batman\build.log' has become accessible [INFO] Scanning for projects... [INFO] Reactor build order: [INFO] Postilion Parent POM In the interests of brevity I cut out the rest of my 250KB log file :-) Regards, Johan -- Johan Pretorius Cell: 0829268327 pretoriusjf@gmail.com --00248c11da37f39e600495f0bae5 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi there,

I use tail 5.3.0 in Windows 7. =A0It works fin= e unless I try to follow a file.

Here is my --vers= ion output:
C:\>tail --version
tail (GNU coreutils) 5.3.0
Written by Paul Rubin, David MacKenzie, Ian Lanc= e Taylor, and Jim Meyering.

Copyright (C) 2005 Free Software Fo= undation, Inc.
This is free software= ; see the source for copying conditions. =A0There is NO
warranty; not even for MERCHANTABILITY or FITNES= S FOR A PARTICULAR PURPOSE.

<= /div>
The following works as expected with no error messages.
tail=A0\\ssb-batman\logs\b= atman\build.log

However, if I try to follow, it gives outp= ut as follows.
C:\>tail -f=A0\\ssb-batman\logs\batman\build= .log
[INFO] Unpacking C:\p4ws\depot_cfg\ssb\trunk\postilion= \ssb\postgen\target\postgen-izpack.zip to
=A0=A0C:\p4ws\depot_cfg\ssb\trunk\postilion\ssb_installer\target\= staging
=A0=A0 with includes null and exclude= s:null
[INFO] Unpacking C:\p4ws\depot_cfg\ssb\trunk\postilion\ssb\= scheduleinjector\target\scheduleinjector-izpack.zip to
=A0=A0C:\p4ws\depot_cfg\ssb\trunk\postilion\ssb_installer\target\stagi= ng
=A0=A0 with includes null and excludes:null<= /font>
[INFO] Unpacking C:\p4ws\depot_cfg\ssb\trunk\postilion\ssb\= services\target\services-izpack.zip to
=A0=A0C:= \p4ws\depot_cfg\ssb\trunk\postilion\ssb_installer\target\staging
=A0=A0 with includes null and excludes:null
tail: \\ssb-batman\logs\batman\build.log: Bad file descriptor<= /font>
tail: no files remaining

=
Why is tail suddenly claiming that the file descriptor is= bad, when clearly it works just fine?

So I tried = some different things to see if I could get it to work.

I tried=A0
tail --follow=3D<= /font>\\ssb-batman\logs\batman\build.log
but that just gives an even stranger error:
tail: invalid argument= `\\\\ssb-batman\\logs\\batman\\build.log' for `--follow'
Valid arguments are:
=A0=A0- `d= escriptor'
=A0=A0- `name'
Try `tail -= -help' for more information.

I thought at first that maybe tail d= oes not like the UNC path, but that is not the case - it does exactly the s= ame when I use a local file.

If I add --retry to t= he mix, I get the following very interesting reaction: =A0It prints out the= last few lines, throws out the same error as before, then prints out the e= ntire file! =A0This is what it looks like:
C:\>tail -f "\\ssb-batman\l= ogs\batman\build.log" --retry
tail: warning: --retry is useful only when following by nam= e
[INFO] CfgSystemInfoExt .....................= ................. SUCCESS [4.328s]
[INFO] SSB Installer ......................................= ... SUCCESS [1:28.422s]
[INFO] ----------------= --------------------------------------------------------
[INFO] ----------------------------------------------------= --------------------
[INFO] BUILD SUCCESSFUL
[INFO] ----------------------------------------------------= --------------------
[INFO] Total time: 22 minu= tes 54 seconds
[INFO] Finished at: Fri Nov 26 10:11:17 GMT+02:00 2010
[INFO] Final Memory: 66M/1016M
[INFO] ----------------------------------------------------= --------------------
tail: \\ssb-batman\logs\ba= tman\build.log: Bad file descriptor
tail: `\\ssb-batman\logs\batman\build.log' has become a= ccessible
[INFO] Scanning for projects...
[INFO] Reactor build order:
[IN= FO] =A0 Postilion Parent POM
<snip snip...>

In the intere= sts of brevity I cut out the rest of my 250KB log file :-)

Regards,
Johan

--
Johan Pretorius
Cell: 0829268327
--00248c11da37f39e600495f0bae5-- From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 26 13:43:31 2010 Received: (at 7483) by debbugs.gnu.org; 26 Nov 2010 18:43:31 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PM3Gd-0004Z5-44 for submit@debbugs.gnu.org; Fri, 26 Nov 2010 13:43:31 -0500 Received: from smtp.cs.ucla.edu ([131.179.128.62]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PM3GZ-0004Yt-Ss for 7483@debbugs.gnu.org; Fri, 26 Nov 2010 13:43:29 -0500 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp.cs.ucla.edu (Postfix) with ESMTP id AAE5F39E80FF; Fri, 26 Nov 2010 10:48:53 -0800 (PST) X-Virus-Scanned: amavisd-new at smtp.cs.ucla.edu Received: from smtp.cs.ucla.edu ([127.0.0.1]) by localhost (smtp.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Mtr+GdeM16bv; Fri, 26 Nov 2010 10:48:53 -0800 (PST) Received: from [192.168.1.10] (pool-71-189-109-235.lsanca.fios.verizon.net [71.189.109.235]) by smtp.cs.ucla.edu (Postfix) with ESMTPSA id 3E40939E80DC; Fri, 26 Nov 2010 10:48:53 -0800 (PST) Message-ID: <4CF00110.2070406@cs.ucla.edu> Date: Fri, 26 Nov 2010 10:48:48 -0800 From: Paul Eggert Organization: UCLA Computer Science Department User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.12) Gecko/20101027 Thunderbird/3.1.6 MIME-Version: 1.0 To: Johan Pretorius Subject: Re: bug#7483: Tail claims bad file descriptor when following References: In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Score: -2.9 (--) X-Debbugs-Envelope-To: 7483 Cc: 7483@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.9 (--) On 11/26/2010 12:44 AM, Johan Pretorius wrote: > I use tail 5.3.0 in Windows 7. Hmm, that's rather old. I suggest upgrading to a more-recent version before investigating further. The current version is 8.7. Also, you might try reporting the bug to whoever built it on Windows rather than to bug-coreutils, as it could well be a property of the Windows port rather than a bug in coreutils itself. From debbugs-submit-bounces@debbugs.gnu.org Fri Jul 22 18:21:43 2011 Received: (at 7483-done) by debbugs.gnu.org; 22 Jul 2011 22:21:44 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QkO6J-0007MH-33 for submit@debbugs.gnu.org; Fri, 22 Jul 2011 18:21:43 -0400 Received: from mx.meyering.net ([82.230.74.64]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QkO6H-0007M5-Ga for 7483-done@debbugs.gnu.org; Fri, 22 Jul 2011 18:21:41 -0400 Received: from rho.meyering.net (localhost.localdomain [127.0.0.1]) by rho.meyering.net (Acme Bit-Twister) with ESMTP id B26C36005B; Sat, 23 Jul 2011 00:21:35 +0200 (CEST) From: Jim Meyering To: Paul Eggert Subject: Re: bug#7483: Tail claims bad file descriptor when following In-Reply-To: <4CF00110.2070406@cs.ucla.edu> (Paul Eggert's message of "Fri, 26 Nov 2010 10:48:48 -0800") References: <4CF00110.2070406@cs.ucla.edu> Date: Sat, 23 Jul 2011 00:21:35 +0200 Message-ID: <87vcuu3qj4.fsf@rho.meyering.net> Lines: 20 MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -6.1 (------) X-Debbugs-Envelope-To: 7483-done Cc: 7483-done@debbugs.gnu.org, Johan Pretorius X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) tags 7483 + notabug close 7483 thanks Paul Eggert wrote: > On 11/26/2010 12:44 AM, Johan Pretorius wrote: >> I use tail 5.3.0 in Windows 7. > > Hmm, that's rather old. I suggest upgrading to a more-recent > version before investigating further. The current version is 8.7. > > Also, you might try reporting the bug to whoever built it on Windows > rather than to bug-coreutils, as it could well be a property > of the Windows port rather than a bug in coreutils itself. Thanks for the report. I'm closing this as "not a bug". If you find evidence of a bug using the latest, you might want to report it to whomever wrote packaged coreutils for windows 7. From unknown Sun Jun 22 00:02:06 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sat, 20 Aug 2011 11:24:05 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator