Are there any better solution to this?
tail -200 /var/log/messages | head -100
Are there other methods to achieve this output? (not more complex, I'm looking for simpler solutions!)
|
Are there any better solution to this?
Are there other methods to achieve this output? (not more complex, I'm looking for simpler solutions!) |
|||||||||
|
|
If you want to browse through a file interactively, just use
(which means: jump to the end, move 1000 lines up, 100 lines down, one screen forward and one screen backward) |
|||
|
|
|
If you know the starting line number (counted from the beginning of the file), you can use
(which prints the lines 300 until 400) If you don't know the start line (address in sed lingo), you can reverse the input, use sed and reverese again:
You can also use sed with a start address and specify how many following lines should be printed:
|
||||
|
|