1826073 Members
3410 Online
109690 Solutions
New Discussion

Re: missing some scripts

 
SOLVED
Go to solution
simon_164
Super Advisor

missing some scripts

I have the error on shutdown:

/sbin/rc2.d/K177hpws_apache[46]: 1: not found.
/sbin/rc2.d/K177hpws_tomcat[46]: 1: not found.
/sbin/rc2.d/K177hpws_webmin[45]: 1: not found.
/sbin/rc2.d/K177hpws_webproxy[44]: 1: not found.
/sbin/rc2.d/K177hpws_xmltools[42]: 1: not found.
/sbin/rc1.d/K300acct [39]: 1: not found.
/sbin/rc1.d/K410Rpcd[30]: 1: not found.
/sbin/rc1.d/K604runner[21]: 1: not found.


and the error on startup:

/sbin/rc2.d/S130pfilboot[5]: 1: not found.
/sbin/rc2.d/S131ipfboot[6]: 1: not found.
/sbin/rc2.d/S590Rpcd[30]: 1: not found.
/sbin/rc2.d/S606runner[21]: 1: not found.
/sbin/rc2.d/S700acct[39]: 1: not found.
/sbin/rc3.d/S823hpws_apache[46]: 1: not found.
/sbin/rc3.d/S823hpws_tomcat[46]: 1: not found.
/sbin/rc3.d/S823hpws_webmin[45]: 1: not found.
/sbin/rc3.d/S823hpws_webproxy[44]: 1: not found.
/sbin/rc3.d/S823hpws_xmltools[42]: 1: not found.


Any one have an idea? why i am missing these files?
13 REPLIES 13
Victor Fridyev
Honored Contributor
Solution

Re: missing some scripts

Hi,

It looks that APACHE has been uninstalled wrongly.
Install it and the messages will disappear.

HTH
Entities are not to be multiplied beyond necessity - RTFM
OldSchool
Honored Contributor

Re: missing some scripts

have any of the following occurred recently:

swinstall (possibly one that failed)
swremove
recent patching?

it looks like either some web services were removed, or that they didn't get all the way installed

Peter Nikitka
Honored Contributor

Re: missing some scripts

Hi,

I don't think, a file or command '1' is missing. I think, there is an invalid assignment to variables.
Look at this:

a= 1 # blank seperated
will result in
ksh: 1: not found

Check for such changes in
/etc/rc.config.d/*

mfG Peter
The Universe is a pretty big place, it's bigger than anything anyone has ever dreamed of before. So if it's just us, seems like an awful waste of space, right? Jodie Foster in "Contact"
simon_164
Super Advisor

Re: missing some scripts

I have a typical another server, do you think copying the scripts will be a good idea?

I checked Apache it seems ok, no unusual swremove has been done different than the other server. maybe some changes in /etc/rc.config.d/nfsconf but nothing more.
Jonathan Fife
Honored Contributor

Re: missing some scripts

I would bet that you have a file somewhere in /etc/rc.config.d that has some bad syntax.

Try the following (as just a normal user, not root):

set -x
. /etc/rc.config

See if the error pops up, and then see what fname= was immediately above it. The fname is a file, so look in /etc/rc.config.d at that file and see if there is a syntax issue somewhere.
Decay is inherent in all compounded things. Strive on with diligence
James R. Ferguson
Acclaimed Contributor

Re: missing some scripts

Hi Simon:

You don't have missing scripts but rather a corrupted file(s) in '/etc/rc.config.d/'.

If you look at the comments in '/etc/rc.config' you will see that files in this directory are expected to follow a strict naming convention if they are not to be processed during startup and shutdown.

When '/sbin/rc' runs, the '/etc/rc.config.d' directory is examined by the script '/etc/rc.config'. This script skips any file whose basename contains an "extension" that begins with the characters [.,~#].

Thus, it is permissible to have 'netconf' and 'netconf.old'. The '.old' backup will *not* be processed.

If, however, you had kept an old version of your 'netconf' file named as, 'oldnetconf', then *both* 'netconf' and 'oldnetconf' would be sourced. Since the letter "o" follows "n", the result would be undesirable insofar as the last variable declarations seen would be from the wrong file.

One way to find bogus files that cause prolems is to do:

# sh -vx /etc/rc.config 2>&1|more

Regards!

...JRF...
OldSchool
Honored Contributor

Re: missing some scripts

Check the directory contents in:
/etc/rc.config.d

If you do an ls -l, I'd almost bet you will find it comes up with trash, like a filename w/ control characters or something along those lines, maybe a 1.

this is related to your other post as well

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=1050553

as the rpc daemons aren't coming up

the file listed are complaining about a file "1" not being found. The scripts referred to are running /etc/rc.config
which in turn tries to "source" files in /etc/rc.config.d.
simon_164
Super Advisor

Re: missing some scripts

sh -vx --- did not show anything i can understand as errors.
ls -l also did not show any particular error.
I am comparing with a different system, I am having the same scripts and file on both systems in the same location. Any other idea?
Patrick Wallek
Honored Contributor

Re: missing some scripts

Try this:

# cd /etc/rc.config.d
# grep "= 1" *

And see what comes back. If anything is returned, the edit the script and remove the space between the = and the 1. There should never be and spaces between the variable names, the = signs and the values in any files. Everything should look like:

VAR=0
VAR=1
Matti_Kurkela
Honored Contributor

Re: missing some scripts

Ah, a classic HP-UX startup/shutdown puzzle.

The numbers in square brackets are line numbers in each script. For example,

/sbin/rc2.d/S590Rpcd[30]: ...

means that an error has occurred on the 30th line of the script /sbin/rc2.d/S590Rpcd.

The rest of the message is a description of the error: "1: not found." It turns out that HP-UX is trying to find a command that would be named simply as "1". Unix is terse, but not quite *that* terse.

At this point, you could figure this one out by sitting down and working your way through the totality of the HP-UX startup/shutdown sequences. While that might be enlightening, it would require quite a lot of time that might be better spent more constructively.

It turns out that most scripts called from /sbin/rc?.d directories have something in common. A snippet like this:

if [ -f /etc/rc.config ] ; then
. /etc/rc.config
else
echo "ERROR: /etc/rc.config defaults file MISSING"
fi

Each script that has this snippet in it will read /etc/rc.config and execute it as a part of itself. You might note that all the line numbers in your error messages, in each script that produces the error message, will refer to a line that says:

. /etc/rc.config

So the actual problem might be with /etc/rc.config. But no HP-UX administrator has any reason to modify that script, and any typos in that would be noticed, reported as a bug and patched long ago.

Actually, /etc/rc.config loops through each file in /etc/rc.config.d and... executes each of them in the same way as /etc/rc.config was executed in the original script. So if several startup/shutdown scripts give similar error messages, the problem is somewhere in /etc/rc.config.d.

Let me emphasize: the problem is *not* with the scripts in /sbin/rc?.d directories. The problem is in one of the files in /etc/rc.config.d/ directory.
MK
simon_164
Super Advisor

Re: missing some scripts

no significant output.
someone mentioned my other thread about showmount not working, I have another system similar to this one, absolutely the same, other than IP and ..
now Showmount on the other system does not work although no error at startup or shutdown.

I have to /usr/sbin/rpc.mountd to be able to make showmount and not get the error RPC: program not registered
James R. Ferguson
Acclaimed Contributor

Re: missing some scripts

Hi (again) Simon:

Thy this:

# sh -vx /etc/rc.config > /tmp/myrcerrs 2>&1

...Now 'vi' the file and find the string 'found'. When you do, look for the script that was sourced when the error occured. You should see a line above the "not found" (for example) like:

+ . /etc/rc.config.d/netconf

Regards!

...JRF...
simon_164
Super Advisor

Re: missing some scripts

I found the solution , Yuppeeee !!
I am not gonna tell you what :d.
No really there was an extra file over there, I removed it and Voila !.