Let's say I have a file with any number of lines, say 125. I want to get all lines except the first n, say 20. So I want lines 21-125.
Is there a way to do this with tail / head or another tool?
tail
head
Try
tail -n +21 myfile.txt
sed -i 1,20d filename
if you want to delete the first 20 lines!
Awk power can also be used:
awk -- 'NR > 20' /etc/passwd
I'm rusty with this, but something like: tail -n +20 filename