Red Hat Bugzilla – Bug 174624
"tail +5 file" no longer works
Last modified: 2007-11-30 17:11:18 EST
Description of problem:
tail +<number> file no longer works
Version-Release number of selected component (if applicable):
tail (GNU coreutils) 5.93
Steps to Reproduce:
1. tail +5 /etc/protocols
tail: cannot open `+5' for reading: No such file or directory
==> /etc/protocols <==
crdup 127 CRUDP # Combat Radio User Datagram
sscopmce 128 SSCOPMCE
lines beginning from line 5
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
At least coreutils-5.93-2 broken as well,
but tail from coreutils-5.2.1-56 works.
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.
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
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_.)
*** Bug 174785 has been marked as a duplicate of this bug. ***
*** Bug 175907 has been marked as a duplicate of this bug. ***