4 ms·
Couldn't you just send a SIGUSR1 signal to see the progress?
by mahouse 11y ago
Couldn't you just send a SIGUSR1 signal to see the progress?
- mshook 11y agoYou could but letting dd take care of it instead of doing it yourself is much better IMHO.
- zimbatm 11y agoWhat if you started dd without status=progress ?
- neikos 11y agoThen that's your own fault?
- zimbatm 11y agoBut surely if you could send a SIGUSR1 and get the progress it would be useful. I won't always have the foresight to put the progress argument. Maybe I expected the task to be quick but it's not.
- Gracana 11y agoUpdating dd to continuously dump text to the screen by default would probably break a lot of existing scripts.
- zimbatm 11y agoJust on SIGUSR1 would be good enough to get an idea where dd is at. And it would be on stderr, not stdout.
- Gracana 11y ago> it would be on stderr, not stdout Oh, that's true. Anyway, what behavior do you want to see exactly? You can still send the USR1 signal and get the update behavior just like before. Were you just pointing out that there are cases where you still need to use that feature, or something else?
- pixelbeat 11y agoThat's more awkward and outputs a separate line per interrupt. Also to do that programmatically (to provide progress to a program using dd underneath) is tricky to do robustly due to the default disposition of SIGUSR1. SIGUSR1 is really only a hack provided on systems that don't support SIGINFO (which is easier to generate and whose default disposition is easier to handle robustly)
- unluckier 11y agoIf you're on BSD, that'll kill dd.