*This message was transferred with a trial version of CommuniGate(tm) Pro* Hi, I'm a total Linux newbie, just purchased 8.1 to run as an email and proxy server (having got very tired of Uncle Bill's antics). Running headless with SSH from a terminal session on my Mac (and no monitor available - I had to borrow one for the install). One small problem I'm hoping someone can help me with: Seems when I restart the system (i.e. power cut, etc), my server applications don't appear to automatically start - I have to go into the directory structure, find the following files and ./xxx start: /etc/init.d/init.d/CommuniGate /etc/software/init.d/webwasher I gather that "init.d" is the "startup" directory, and SuSE runs everything in that directory during boot? Is this just a simple case that the install scripts for these two applications should have put the files mentioned into /etc/init.d instead of the place where they've been put? Is this correct? Anything else I need to be looking at (like any files which control the order of application startup?)? There's the files "S80CommuniGate" and "S99webwasher" in the /etc/init.d/rc3.d/ directory which I gather is something to do with the runlevel? (I'm running in level 3). Looking at them in Pico, they appear to be startup scripts (which makes me confused as to why they don't actually start the apps). What's the number in front of them? Is it some kind of starting timer and my problem is just that I don't wait long enough for the apps to start? (questions, questions, questions!) ;-) Please be specific as I'm a total newbie. Thanks!
Russ wrote:
/etc/init.d/init.d/CommuniGate
/etc/software/init.d/webwasher
It's true that these were better to stay in /etc/init.d, but it's not mandatory. If you have symbolic links to them (S99whatever) in /etc/init.d/rc3.d, they should start in run level 3 (text, no graphics). If you normally start up the computer in run level 5 (graphics), then you need to have those symlinks in /etc/init.d/rc5.d. But if the computer is a server, you don't need the graphics anyway. To start in text mode: Yast, Graphics Card and Monitor. Anyway, it's better to follow the SuSE rules for init scripts. They are: init scripts in /etc/init.d Enable a service to start at reboot: chkconfig --add service where service is the name of the script in init.d. What chkconfig actually does is create the right symlinks in /etc/init.d/rcX.d for you. Disable a service: chkconfig --del service /etc/software/init.d/webwasher ^^^^^^^^ This part is not really standard. Is there a particular reason why you use Communigate? -- Silviu Marin-Caea Systems Engineer Linux/Unix http://www.genesys.ro Phone +40723-267961
*This message was transferred with a trial version of CommuniGate(tm) Pro* On Monday, November 4, 2002, at 09:02 am, Silviu Marin-Caea wrote:
/etc/init.d/init.d/CommuniGate /etc/software/init.d/webwasher
It's true that these were better to stay in /etc/init.d, but it's not mandatory.
No problems with my moving them with a simple "mv"?
Anyway, it's better to follow the SuSE rules for init scripts.
They are: init scripts in /etc/init.d
Enable a service to start at reboot: chkconfig --add service where service is the name of the script in init.d. What chkconfig actually does is create the right symlinks in /etc/init.d/rcX.d for you.
Disable a service: chkconfig --del service
Great! Just the info I needed.
Is there a particular reason why you use Communigate?
I need the server to do standard email, a few announcement lists and be pretty hard on spam with RBLs and honey pots (and as a newbie I need something pretty easy to configure - i.e. integrated - I've heard Sendmail is approaching a black art). Also in the near future I'm going to need site-to-site encryption and the CommuniGate server-to-server encrypt seems just the job (to save messing around with PGP at the client end) - I figure I may as well start as I mean to go on. If there's any better (i.e. cheaper but just as easy) I'd be pleased to know! :-)
Silviu Marin-Caea
Enable a service to start at reboot: chkconfig --add service
The tools to use are either the runlevel editor in YaST or insserv (or if you want to be LSB conforming /usr/lib/lsb/install_initd and /usr/lib/lsb/remove_initd). Philipp -- Philipp Thomas work: pthomas@suse.de Development SuSE Linux AG private: pth@t-link.de
On Monday 04 November 2002 00:43, Russ wrote:
Seems when I restart the system (i.e. power cut, etc), my server applications don't appear to automatically start - I have to go into the directory structure, find the following files and ./xxx start:
/etc/init.d/init.d/CommuniGate /etc/software/init.d/webwasher
I gather that "init.d" is the "startup" directory, and SuSE runs everything in that directory during boot?
You're on the right track. /etc/init.d contains the startup/shuitdown scripts for various applications. you should also see various "rc<number>.d" directories, and as you surmised, rc3.d contains the startup scripts for runlevel 3. The confusing part about all of this (is/was) that some distributions placed the "rc#.d" directories "below" init.d, and others "beside" [at the same level as] init.d. Functionally it shouldn't matter, but it can confuse some installation scripts. That's what appears to have happened for "communigate" since I see you have init.d as a subdirectory of init.d!
Is this just a simple case that the install scripts for these two applications should have put the files mentioned into
/etc/init.d
instead of the place where they've been put?
I would think so.
Is this correct? Anything else I need to be looking at (like any files which control the order of application startup?)?
You almost answered yourself in asking your next question(s) -- within the rc.d directories you should see several files of the form Snn<name> and Knn<name> where "nn" is a two digit number. "by convention", the Snn's are start scripts, and Knn's are stop (kill) scripts. In actuallity, these are "symlinks" BACK to the corresponding file in init.d
There's the files "S80CommuniGate" and "S99webwasher" [...]
The two-digit number DOES have a purpose: it controls the order in which scripts are started. There is a master "startup" script that is given the runlevel you want to change to. This script reads the corresponding "rc#.d" directory and simply executes (in sorted filename order) everything beginning with an upper-case S When you boot your system (with a monitor attached) you should see some "chatter" as things are started up. Eventually you'll see a message like "switching to runlevel 3" followed by several lines of the form starting xyz [OK] starting pdq [OK] starting network services starting eth0 [OK] starting eth-pcmcia-0 [delayed] starting communigate [OK] starting webwasher [FAILED] login: (the above is simply an example -- I'm fairly sure you don't have pcmcia services or network adapters, but this is about the only one that comes up with something other than "OK" or "FAILED" -- just trying to be complete here :) ) Note in particular the last two I've listed here: communigate and webwasher -- because communigate has a startup-number of 80 and webwasher has 99, you'll likely see them JUST before the "login" prompt as I've shown here. If you DON'T see them,. it could mean a few things: 1) the startup user doesn't have the "permission" to run (execute) the startup scripts [difficult to do since the startup user is usually root...] 2) the "symlinks" don't point to the right places [noting you have init.d/init.d and etc/software/init.d, this is more likely...] 3) there is some sort of error in the scripts themselves (not likely since you say you CAN run these manually and they work) I suspect you will see them, but you will also see "[FAILED]" off to the right for these -- that is when you'll have to start digging into the startup process in depth to find out why they are failing to start (could be that these rely on other processes that are not being started) For further info, type the command man init.d at a shell prompt -- this should bring up the online help that explains what I just said in greater detail :)
Russ
/etc/init.d/init.d/CommuniGate
This location is a violation of standards.
/etc/software/init.d/webwasher
This as well.
I gather that "init.d" is the "startup" directory, and SuSE runs everything in that directory during boot?
Nope :) /etc/init.d contains scripts to start various services. If and when they are run is determined by the symbolic links in /etc/init.d/rc[0-6].d. Links starting with S are for starting, those beginning with K for killing services. The numbers after S/K determine the order in which services are started/stopped.
Is this just a simple case that the install scripts for these two applications should have put the files mentioned into
/etc/init.d
instead of the place where they've been put?
The real scripts should be in /etc/init.d, *BUT* they need LSB compliant headers in order to work correctly. Have a loot at /etc/init.d/skeleton for how a LSB compliant init script should look like. Last I checked, WebWasher definitely did things an RPM for SuSE Linux (or rather a LSB compliant Distribution) should *not* do and I just guess that Communigate's RPM was also created for RedHat and will need modifications in order to run correctly on a LSB compliant system. Do you have an URL for Communigate? I might find time to have a look at, if only to have another specimen for my 'how not to do it' collection. Philipp -- Philipp Thomas work: pthomas@suse.de Development SuSE Linux AG private: pth@t-link.de
*This message was transferred with a trial version of CommuniGate(tm) Pro* On Tuesday, November 5, 2002, at 01:41 am, Philipp Thomas wrote:
Is this just a simple case that the install scripts for these two applications should have put the files mentioned into
/etc/init.d
instead of the place where they've been put?
The real scripts should be in /etc/init.d, *BUT* they need LSB compliant headers in order to work correctly. Have a loot at /etc/init.d/skeleton for how a LSB compliant init script should look like.
Philipp, I appreciate the assistance but you're talking to someone with a total exposure to Linux of 5 days - previous to that we're talking "right click, create shortcut, move to Windows/Start Menu". I have absolutely no idea about the internal structure of scripts and the extent of my experience is somewhat limited - I can move files around but scripting is currently completely beyond me. I'd ask what LSB was but even if you told me I'd still have no clue as to what to do with it.
Last I checked, WebWasher definitely did things an RPM for SuSE Linux (or rather a LSB compliant Distribution) should *not* do and I just guess that Communigate's RPM was also created for RedHat and will need modifications in order to run correctly on a LSB compliant system.
Do you have an URL for Communigate? I might find time to have a look at, if only to have another specimen for my 'how not to do it' collection.
Yep... It's http://www.stalker.com/cpro/default.html And as you assume, the RPM download for SuSE is a RedHat RPM. -- Russ
participants (4)
-
Philipp Thomas
-
Russ
-
Silviu Marin-Caea
-
Tom Emerson