TCLUG Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [TCLUG:16689] LInux system files



Some of the configuration files have man pages for them, so try those
out:

	man profile
	man bashrc
	man rc.modules
	man login

Those might tell you what you need to know or at least point you to
another man page or source that can.

Look at some of the files in /etc/init.d/ and see how they handle
"start", "stop", and other arguments. Make a shell script (maybe start
with a copy from some other service/daemon) that does this for your
netware client and put it in /etc/init.d/ (call it nwclient for
instance). Then make symbolic links to this script from
/etc/rc3.d/S95nwclient and other locations:

	ln -s /etc/init.d/nwclient /etc/rc1.d/K10nwclient
	ln -s /etc/init.d/nwclient /etc/rc2.d/K10nwclient
	ln -s /etc/init.d/nwclient /etc/rc3.d/S90nwclient
	ln -s /etc/init.d/nwclient /etc/rc5.d/S90nwclient
	ln -s /etc/init.d/nwclient /etc/rc6.d/K10nwclient

In this setup, nwclient will start when switching to runlevels 3 or 5,
but stop when switching to runlevels 1, 2, or 6. The numbers
(S##nwclient or K##nwclient) indicate the order in which things will
happen. If I remember correctly, when going to runlevel 3, the OS will
kill things (01-99) and then start things (01-99) in order for things
located in /etc/rc3.d/ that fit the pattern (S##* or K##*).

For the nwlogin thing you might have to have a shell script that checks
if a person is attached to a netware server (or if this is the first
shell they've opened on this machine) and runs nwlogin if they are not
and call it from "~/.login". For nwlogout you could do something
similar.

HTH,

Troy

Bill Layer wrote:
> 
> Hi,
> 
> One of the biggest sources of confusion in Linux (at least for me) are the
> locations and purposes of the myriad system files and scripts. Files like:
> 
> ~/.bash_profile
> /etc/rc.d/rc.modules
> /etc/profile
> /etc/rc.d/rc6.d
> 
> And on and on, not to mention all of the networking configuration files.
> Is there a tutorial that descibes all of the common system
> configuration files and scripts, with info on why, when and by what they
> are called, and the type of content that should be found in them?
> 
> For example, I am trying to confgure my sysetm, so that at boottime, when
> the system goes to runlevel 3, it automagically starts my Novell Netware
> client. Then, at each user login, I want the nwlogin command run, and at
> each user logout, I want the nwlogout -a command run.
> 
> However, I do NOT want the nwlogin / nwlogout commands to run when simply
> starting / terminating a new shell (or a console from X) Only on account
> login / out.
> 
> Some advice anyone?
> 
> Bill Layer
> b.layer@vikingelectronics.com
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tclug-list-unsubscribe@mn-linux.org
> For additional commands, e-mail: tclug-list-help@mn-linux.org

-- 
	<a href="http://umn.edu/~john1536">Troy Johnson</a>

Check out Perl!
	http://www.perl.com/