Questions tagged [watch]
watch - execute a program periodically, showing output fullscreen
39
questions
0
votes
0
answers
179
views
Simplify NETSTAT monitoring output
I'm monitoring suspicious incoming connections using
sudo watch -n 30 "netstat -antp"
which provides more information than I need, so based on the answer I found here,
I've tried to ...
0
votes
1
answer
1k
views
How can I watch a folder on an sftp server for new files?
I log in to a sftp server, and to see the files I type ls. Is there any way to recursively watch a folder? For now I just keep typing ls -tlh. Is there a way for that to happen without me typing it? ...
1
vote
0
answers
199
views
Utilize `fswatch` to improve `rsync`'s speed?
I have some huge folders containing about 40000 files (and much, much more gitignored files like node_modules), and I want to rsync to a remote machine.
Currently, I use a simple script like run_rsync;...
1
vote
1
answer
1k
views
watch --color doesn't work when a pipe is involved?
The following demonstrates that watch works with color, but not when a pipe is involved.
$ touch test.txt
$ ls | grep --color test.txt
test.txt # This IS colored ...
-2
votes
2
answers
1k
views
BSOD Clock watchdog timeout Windows 10
ISSUE OS:
Windows 10 Enterprise.
HARDWARE:
MSI X370 SLI PLUS, Ryzen 1600, 32GB DDR4 2133, 250G SSD, 850W TT Gold PSU and Gigabyte RX580 8GB
ISSUE DESCRIPTION: Fresh install, OS works, installed ...
1
vote
1
answer
1k
views
Watch + pipe + multiple arguments
I have a command diff -y <(xxd FILE) <(xxd FILE_) | colordiff and i want to put it into watch routine. Something like that:
watch -n 0,1 'diff -y <(xxd FILE) <(xxd FILE_)'
But i have an ...
2
votes
1
answer
3k
views
Using watch command with "echo -e"
I want to monitor rows of a dynamic file and I use watch command for this. I have 2 files: test-status and iplist_test. I control something in iplist_test and I type this output to test-status. ...
2
votes
1
answer
65
views
Separating files in watch command
I have 3 files and I want watch the changes of these files with 'watch' command. But these 3 files have a lot of row and I just want see the last 3 rows with 'tail'. There is no problem at here. I can ...
0
votes
1
answer
496
views
Integrating "watch" with "top" logging until finished - HOW?
I stumbled across this link: "watch" the output of a command until a particular string is observed and then exit
I know the PID of the process. I want to log the process "resource-...
0
votes
0
answers
119
views
Watch folder and rename file extension
Good day, I'm trying to find a way to watch a folder, and as soon as it see's an xml file/s, it will change it's extension to .txt
I am trying to do this in powershell, hope this question find you ...
3
votes
1
answer
175
views
Is there a Unix command to record changes to output of another command?
I have a long running operation that affects some state.
That state is shown by running a certain command, say showst.
I want to see have a log of all the possible outputs showst will display during ...
4
votes
1
answer
5k
views
How do I live monitor on linux what files get accessed created modified and deleted?
How do I monitor from this moment on what files get accessed / modified / created / deleted. (in live mode), similar to fseventer / fslogger?
8
votes
2
answers
9k
views
Watch with awk command
How do you watch a command like?
awk 'NR%2==0 {printf "%s %8.0f", $1, $5}' filename.txt
Preceding this with "watch" gives this error:
awk: cmd. line:1: fatal: cannot open file `{printf' for reading ...
1
vote
1
answer
2k
views
Detecting new USB devices with bash?
I'm writing a bash script that needs to detect when a usb storage device is inserted and assign it to a variable that would otherwise, typically look something like: usb=/dev/sdb.
I have a few ...
31
votes
3
answers
14k
views
How do I get systemctl to print in color when being interacted with from a non-tty?
When I run a command like this:
# systemctl status plexmediaserver
I get nicely colored output. But when I run the following command:
# watch -n300 --color systemctl status plexmediaserver
Is ...