On Thu, 21 Oct 1999, Lars Lindley wrote:
> Hi everyone.
> I have request for help.
> I run mprime on Linux.
> What I want to do is to have mprime automatically start when I boot
> and send the -m output to a tty or something like that. Perhaps tty8?
> Is this possible??
I created an account called "gimps" and installed mprime in it's home
directory. In my startup scripts I have:
/bin/su - gimps -c "/home/gimps/mprime -d -w/mnt/c/gimps" > /dev/tty11 2>&1 &
I actually cheated with my init scripts. I created a file
/etc/init.d/local - and put this line in it, and then ln -s'ed it to
/etc/rc2.d/S20local through /etc/rc5.d/S20local.
On Sun, 24 Oct 1999, poke wrote:
> Sorry, -d, not -m. I'm not that familiar with the command line arguments
> of mprime. My expertise lies in the symantics of Linux.
>
> One way to pipe to a virtual terminal AND to a file is by using a
> combination of a tee and a redirect. Something like:
>
> /usr/src/mprime -d | tee -a /home/GIMPS/tracking.txt > /dev/tty6
There is no reason that starting mprime from /etc/inittab should be any
slower. It's still the same program, being run on the same machine, just
executed by a different program.
I might switch to the inittab method, but the only good reason to do so
would be to handle the gimps client crashing, which I've never seen it do.
And the only reason not to would be the rare occasions when I want to stop
it -- I'd have to remark out the line in /etc/inittab & do "telnit q"
instead of just "killall mprime".
I also do my mail & system log similarly.
I have a line in my /etc/syslog.conf
*.* /dev/tty12
This sends everything that goes through the system log daemon to the 12th
virtual terminal, which I find very convienient. Do a "killall -HUP
syslogd" to get it to reread the config file.
I have a ppp connection. In my /etc/ppp/ip-up script (which is executed
whenever ppp connects), I have the following:
/bin/su - darxus -c /home/darxus/.ip-up &
Which executes the script /home/darxus/.ip-up & as user "darxus" -- this
script contains:
#!/bin/bash
open -v -c 10 ~/pine.open
~/pine.open contains:
#!/bin/bash
export TERM=vt100
exec ssh -t monet 'pine -i'
I'd forgotten this was so complicated... there were reasons for the way I
did it, but I've long forgotten them :)
Anyway, the end result is, whenever I bring up my ppp connection, I
automatically get pine (the mailreader I use) in my 10th virtual terminal,
over a ssh connection.
I've also tried this with BitchX (IRC client), but it think's it's not
attached to a real terminal and runs in dumb terminal mode.
BTW, I've done
chown darxus.darxus /dev/tty10
chown gimps.gims /dev/tty11
I also have 20 virtual terminals (plus the 3 things above + X) & my
console's text resolution set at 132x60 using lilo. I don't use X much.
__________________________________________________________________
PGP fingerprint = 03 5B 9B A0 16 33 91 2F A5 77 BC EE 43 71 98 D4
[EMAIL PROTECTED] / http://www.op.net/~darxus
Find the next largest prime, be famous:
http://www.mersenne.org/prime.htm
_________________________________________________________________
Unsubscribe & list info -- http://www.scruz.net/~luke/signup.htm
Mersenne Prime FAQ -- http://www.tasam.com/~lrwiman/FAQ-mers