Linux process management
Solution 1:
Redirecting all outputs (stdout, stdin, stderr) can disassociate a child process with the parent.
You can try attaching to the process with gdb, type 'c' for continue, and watch that console while you hup it from another.
gdb /bin/dd pid
Solution 2:
Thanks to kmarsh's answer and this threads I was able to redirect my lost output (stderr) to a file:
gdb /bin/dd 2616
(gdb) p creat("/root/dd.stderr",0600)
[Switching to Thread 0x7f651ece56e0 (LWP 2616)]
$1 = 3
(gdb) p dup2(3,2)
$2 = 2
(gdb) p close(3)
$3 = 0
(gdb) q
After running kill -USR1 2616
I can cat my new file:
631820341060 bytes (632 GB) copied, 81603.1 s, 7.7 MB/s
Solution 3:
i'm afraid not. but next time - use screen. google for tutorials or start here.
Solution 4:
You might be able to see the output by looking in /proc/(pid of your dd/fd/1
or /proc/(pid)/fd/2
. Cat that, then hit it with a USR1 and see if you get anything.