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

Re: [Sheflug] running top on its console?



> 
> To put it on the 6th console, for example replace this line in your
> inittab (this is gentoo specific, other inittabs will differ slightly):
> 
> c6:12345:respawn:/sbin/agetty 38400 tty6 linux
> 
> with:
> 
> c6:12345:respawn:/usr/local/sbin/autologin
> 

Or simply...

	c6:345:respawn:/usr/bin/top -s > /dev/tty6 < /dev/tty6

No need for a seperate program to spawn it. Seen this working for years
on a Slack box. The '-s' option to top runs top in 'secure' mode, disabling
potentially bad commands (like 'k' for kill)... useful if people you don't
trust have access to the console (see man page for which commands are
disabled).

If you want it to run as a user other than top, you should be able to spawn
it via 'su'.

Chris...

-- 
\ Chris Johnson           \
 \ cej [at] nightwolf.org.uk    ~-----,   
  \ http://cej.nightwolf.org.uk/  ~-----------------------------------, 
   \ Redclaw chat - http://redclaw.org.uk - telnet redclaw.org.uk 2000 \____
___________________________________________________________________

Sheffield Linux User's Group -
http://www.sheflug.co.uk/mailfaq.html

  GNU the choice of a complete generation.