Bug 174624 - "tail +5 file" no longer works
"tail +5 file" no longer works
Product: Fedora
Classification: Fedora
Component: coreutils (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Tim Waugh
: 174785 (view as bug list)
Depends On:
  Show dependency treegraph
Reported: 2005-11-30 14:52 EST by Ville Herva
Modified: 2007-11-30 17:11 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-11-30 14:58:30 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Ville Herva 2005-11-30 14:52:12 EST
Description of problem:
tail +<number> file no longer works

Version-Release number of selected component (if applicable):
tail (GNU coreutils) 5.93

How reproducible:

Steps to Reproduce:
1. tail +5 /etc/protocols
Actual results:
tail: cannot open `+5' for reading: No such file or directory
==> /etc/protocols <==
crdup   127     CRUDP           # Combat Radio User Datagram
sscopmce        128     SSCOPMCE

Expected results:
lines beginning from line 5

Additional info:
One can use 

  tail -n +5 /file

as a workaround.

However, this ("tail +5" not working) breaks many existing scripts, such as the 
Sun j2re-1.4.2 installer. "tail +2" appears to work on other platforms as well 
(like Irix). 

At least coreutils-5.93-2 broken as well,
but tail from coreutils-5.2.1-56 works.
Comment 1 Tim Waugh 2005-11-30 14:58:30 EST
This is intentional.  See this info page:

info coreutils "Standards Conformance"

for rationale and a work-around that will work in the case you mention.
Comment 2 Ville Herva 2005-11-30 15:05:28 EST

seems to clarify this issue.

I'm not sure if people _really_ need to be able to tail files with a name like "
+72" easier than to view the lines starting from 72 of any file.

But I guess POSIX is the word of God. And the scripts will be fixed in twenty 
years anyway...

Comment 3 Ville Herva 2005-11-30 15:14:05 EST
Thanks for the quick reply.

(As an afterthought I realize my tone was not perhaps as calm as it should've 
been. In any case I didn't mean to blame _you_.)
Comment 4 Tim Waugh 2005-12-02 04:26:07 EST
*** Bug 174785 has been marked as a duplicate of this bug. ***
Comment 5 Tim Waugh 2005-12-16 04:50:17 EST
*** Bug 175907 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.