5 ms·
Slightly related: what many people don't know is that on OS X and BSDs, commands often react to SIGINFO (Ctrl-t), giving progress information. E.g. from the cp
by danieldk 12y ago
Slightly related: what many people don't know is that on OS X and BSDs, commands often react to SIGINFO (Ctrl-t), giving progress information. E.g. from the cp man page:
If cp receives a SIGINFO (see the status argument for stty(1)) signal,
the current input and output file and the percentage complete will be
written to the standard output.
- ramidarigaz 12y agodd has a similar feature, but with SIGUSR (kill -USR1), and it works on Linux too.
- ysangkok 12y agoHow do you fire that signal from the console ?
- spoiler 12y agoBy using kill -s <Signal> <Process ID>
- koenigdavidmj 12y agopkill -USR1 dd You'll need to use ps to get the pid if you've got multiple dd instances running, and you'll of course need to run that as root if your dd instance is running as root.
- akshatpradhan 12y agoPersonally, I think the experience of typing ctrl+t is better than using pkill. Just 2 keyboard taps and you're done.
- ak217 12y agoVery cool. Is there a reason why Linux tools don't react to SIGINFO, other than just "not implemented"?
- deleted 12y ago[deleted]
- na85 12y agoAs far as I'm aware, Linux tools do react to various signals, just not SIGINFO because it comes from BSD and Linux just doesn't use that particular signal. You can check dd progress by sending USR1, for example.
- ak217 12y agoI just wish there was a control sequence keystroke like Ctrl+I to get programs to do that.