rich@oxtrap.UUCP (K. Richard Magill) (10/17/87)
Can anyone tell me how to run a getty under X? I have a bunch of sun 3/50's doing basically nothing but functioning as X servers and I want the X screen saver when noone is logged in. Actually, there are a number of other reasons for wanting the X to live above the getty/login. Short of hacking init source, (We're binary only), can anyone suggest a solution short of an infinite shell loop spawned into the background from rc? xoxorich. ---------- Windows and Icons and Mice! Oh my!
jg@jumbo.dec.com (Jim Gettys) (10/18/87)
4.3 BSD and Ultrix both have support for running window systems from init; under Ultrix, for example, one just logs into a window; the server and an initial process are maintained by init. You might pester Sun to adopt the 4.3 changes to init, getty and login which support window systems; there is nothing X specific to the support; it should be equally useable for NeWS. - Jim
rwhite@nusdhub.UUCP (Robert C. White Jr.) (10/18/87)
In article <1724@oxtrap.UUCP>, rich@oxtrap.UUCP (K. Richard Magill) writes: > Can anyone tell me how to run a getty under X? I don't know enough to comment about "X" but this is how I made a program that logs people out if they leave their systems idle to long: init runs "my program" "my program" forks itself. the "parent" version of "my program" exec(s) getty getty continues normally.... The child version of "my program" uses kill w/sig 0 to make shure getty or login or whatever [that had the parent process number] is still running. If not, it suicides. If so, it stat(s) the tty line. If now - stat is greater than x, it kill(app signal)(s) the parent process id, and suicides after the "parent" process dies. otherwise it sleeps, and then loops. You might try a variant of this with whatever "X" does, possibly allowing a "backside" rondivous between the "spy" and the main invocation of "x" Disclaimer: it's just a thought... Robert
rwhite@nusdhub.UUCP (Robert C. White Jr.) (10/18/87)
In article <1724@oxtrap.UUCP>, rich@oxtrap.UUCP (K. Richard Magill) writes: > Can anyone tell me how to run a getty under X? On the [very high] chance that my other opsting was not quite what you were asking.... as in you don't have something like inittab to change the "program to respawn" definition use this hack: mv /bin/getty /bin/gettyreal ln "my program" /bin/getty "my prog" execs getty <see previous posting> As a very basic warning!!!!!!!!!! Do be shure you have at least one terminal logged in as root continuously durring the instalation and testing [do test it!] of this hack. I have known people who tried this, had it not work when they logged out, and then couldn't log back in without a system restore done from firmware. Potentally VERY!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! NASTY. rob.
rich@oxtrap.UUCP (K. Richard Magill) (10/22/87)
In article <141@nusdhub.UUCP> rwhite@nusdhub.UUCP (Robert C. White Jr.) writes: >In article <1724@oxtrap.UUCP>, rich@oxtrap.UUCP *I* write: >> Can anyone tell me how to run a getty under X? Well I had hoped to avoid "replacing" getty... So what I did was kick off an infinite (shudder) shell loop from rc. After playing with the screen timeout options (sun, DON'T DO ANYTHING BUT THE DEFAULT!!! DON'T EVEN CONFIRM THE DEFAULT WITH A SWITCH!!!) it seems to be running ok. ie, while true; do xinit getty ... -- X ... ; done (xterms sometimes "miss" uwm and end up in the process table forever, but...) This is X12. Hah! Had you going there for a second! X11.1. rich. Disclaimer: This is not a disclaimer.