[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re-starting GEM



OK, someone asked how to start/stop GEM without losing memory and such.
Here is a method that works. 

I'm sure that everyone knows you can use CNTRL-ALT-C to kill GEM.  If you
started GEM from a SHELL, you get your shell back.  You can sometimes run
a GEM application from the shell after you've killed the GEM desktop.
Since GEM has already initialized the program can still call GEM, however,
sometimes tyhe screen manager or something gets left in a weird state.

SO!   Try the following.  Boot into a shell that supports good job control.
I found that sh03 whatever binary was not adequate (I think this is ash).
Bash has funky problems on my console when I run NVDI, so I used TCSH.
You run GEM in the background!!   If TCSH doesn't suspend GEM for TTY input
when you start pressing keys, then simply press CNTRL-ALT-Z to stop GEM.
You will get the standard message about a stopped job.   Type JOBS to get
the job list.  You can use your shell as long as you like now.  To
return to GEM, simply type FG 1 (or whatever job GEM is).  To get back to
the shell, SIGSTOP GEM again.   This doesn't free the memory that GEM
uses, but it's about as close as its gonna get without some really nasty hacks
I think.

Like I said, killing GEM and then running a GEM program later sometimes works,
but you gotta be careful (perhaps doing a wind_update(BEG_MCNTL) or something
before the new GEM program would help) as it sometimes fails to work 
properly.  The sigstop method works just as well, although you need to redraw
the screen with something (maybe you can write a GEM desk ACC that saves
the screen and then SIGSTOPs GEM, when it wakes up it could restore the
screen .. maybe?)

CYA