Skip to main content

Questions tagged [tail]

Unix command to view the end of a file

2 votes
1 answer
137 views

Execute self-extracting bash script (with binary data appended) w/o saving it first

I have a self-extracting bash script (binary data appended to the end) like this: #!/bin/bash export TMPDIR=$(mktemp -d) ARCHIVE_START_LINE=$(...) # <omitted> # extracting data archive into a ...
Edward Ruchevits's user avatar
2 votes
1 answer
155 views

tail -f does not follow files on WSL

I have : F:\xampp-htdocs>wsl --list Windows Subsystem für Linux-Distributionen: Ubuntu-22.04 (Standard) I cd into my logfiles on Window 11: /mnt/d/xampp-2024-15-01/apache/logs$ there i do tail -f ...
Heinz's user avatar
  • 121
12 votes
3 answers
2k views

Stop scrolling to the bottom automatically in PuTTY

I am using tail -f to monitor a file via PuTTY. But each time new content arrives then it automatically scrolls to the bottom and so I can't read the text. Is there a way to make it stop that ...
Black's user avatar
  • 8,131
0 votes
1 answer
229 views

How to output contents of rotating log files dynamically to stdout?

I want to output the contents of a number of rotating log files, let's say file.log.1 and file.log to stdout for continued processing. For a single log file I could have used tail -F file.log, but ...
bohrax's user avatar
  • 111
1 vote
1 answer
138 views

stopping ssh process that is sent to background without corrupting stdout

My script aims to extract a text log file using tail -f and a wireshark trace using tshark. But I don't know if these are the best options for my goal. My script has to ssh into a machine (which I ...
Fixenet's user avatar
  • 13
2 votes
1 answer
6k views

Modify 2>&1 so that output goes to a specific file and any errors or other output goes to a log file I can monitor?

I'm reading this post and I don't fully follow the answer. I wondered if I could modify this, what's it called, command redirect? What I would like: Don't hang, use ampersand & to move on to the ...
Doug Fir's user avatar
  • 155
0 votes
1 answer
820 views

What are the command line parameters (options) for Microsoft's CMTRACE tool?

The CMTRACE tool is included in Microsoft's System Center 2012 R2 Configuration Manager Toolkit. It's a reasonably good tail tool. One of its downsides, however, is that it can take a very long time ...
End Antisemitic Hate's user avatar
1 vote
2 answers
807 views

Tail -f is not showing the update of the file when edited form editor

I have opened a file using tail -f <filename, and tried to append some texts in the same file from another tab using vim, the updated content is not showing. But if I append some texts using echo ...
shiponcs's user avatar
  • 113
0 votes
1 answer
223 views

Find files from different directories with inclusion and exclusion of some

I want to find files from three different folders with certain files included & excluded. Folder 1: Path: /var/www/app/var/log/ Exclude only: file1.log & file2.log Folder 2: Path: /var/log/...
MagePsycho's user avatar
0 votes
0 answers
757 views

Mac terminal : terminate tail output

How can I terminate the tail log output on the mac terminal and come back to the prompt? I have tried using command+z|x|c|q and control+z|x|c|q but it doesn't work. With control, I get the below ...
Nancy's user avatar
  • 1
0 votes
1 answer
103 views

Tail log and output top processes upon encountering string fails

I am running the following command to tail a log file and output top processes to a file upon encountering a given string: tail -f mylogfile.log | awk ' /server on fire/ { system("...
Branka's user avatar
  • 101
1 vote
1 answer
650 views

Unblock "less" after follow mode / scrolling past end of buffer

I'm using less to capture the output of a live program. Using F activates follow mode, showing me real-time output. However, after entering follow mode (or, more generally, scrolling past the buffered ...
loopbackbee's user avatar
  • 1,441
2 votes
0 answers
59 views

Realtime filtering of a capture in a different process

Posted this on network engineering earlier: https://networkengineering.stackexchange.com/questions/67433/realtime-filtering-of-a-recording-in-a-different-process I have a network recording setup ...
flyingcheetah's user avatar
0 votes
1 answer
3k views

tail -n1 on latest non-empty line

I wanted to achieve something similar to this grep -v '^$' <myfile-with-blank-lines-at-the-end> | tail -n 1 Basically, I have a file with a unique number, followed by a comma and I want to ...
oneindelijk's user avatar
4 votes
1 answer
24k views

Combining find grep and tail

I am trying to find all files that start with a certain name, then go through each file to find lines that contains a string, then only print out the last line of each file that contain the string. ...
Shep Bryan's user avatar

15 30 50 per page
1
2 3 4 5
10