Bring Process to foreground of another terminal

Hi,

I am currently in the middle of running portupgrade... I came back to my laptop, opened up the lid and it looked like the GUI had restarted (saw nvidia splash, no more terminal with my portupgrade).

I did a pu and i believe that it's still running (weired, because i thought all child processes would be killed if the GUI crashed):


Code:
# ps
  PID  TT  STAT      TIME COMMAND
 1468  v0- I      0:00.04 /usr/local/sbin/gdm-binary
 1658  v0  Is+    0:00.00 /usr/libexec/getty Pc ttyv0
 1659  v1  Is+    0:00.00 /usr/libexec/getty Pc ttyv1
 1660  v2  Is+    0:00.00 /usr/libexec/getty Pc ttyv2
 1661  v3  Is+    0:00.00 /usr/libexec/getty Pc ttyv3
 1662  v4  Is+    0:00.00 /usr/libexec/getty Pc ttyv4
 1663  v5  Is+    0:00.00 /usr/libexec/getty Pc ttyv5
 1664  v6  Is+    0:00.00 /usr/libexec/getty Pc ttyv6
 1665  v7  Is+    0:00.00 /usr/libexec/getty Pc ttyv7
73367   2  Is+    0:00.03 make
73375   2  I+     0:00.03 make config
73379   2  I+     0:00.00 [sh]
73391   2  R+    90:21.39 /usr/bin/dialog --checklist Options for en-freebsd-do
73901   1  I      0:00.00 su
73902   1  S      0:00.01 _su (csh)
74465   1  R+     0:00.00 ps

The portupgrade command isn't there but I'm sure that the make and make config is a prompt.. so the terminal that was originally displayed this is now gone, how do I bring this one to a new terminal so I can carry on?
 
killasmurf86 said:
Use sysutils/tmux or sysutils/screen
With them you will be able to close GUI terminal, disconnect from net or whatever and later continue, without loosing progress

it sounds like i have to actually start the session up with these before being able to do that?


pelmen said:
You can snoop control via

watch -W /dev/pts/<NUM>

thanks, this sounds like what I'm after, but i get this:
Code:
# watch -W /dev/pts/2
watch: fatal: can't open device

thanks for the replys
 
killasmurf86 said:
Yes. You can consider them as Window Managers for CLI apps :D

Here's info about screen (I prefer tmux)
http://forums.freebsd.org/showthread.php?t=3599

yeah, i found that but i can't use screen because i didn't launch the update with it, and watch is giving me that error i have there so there is nothing to do but sack it off and reboot/stop the process and start the update again? if that's the only way to do it will it affect/break anything?
 
Back
Top