Operating System - HP-UX
1832885 Members
2508 Online
110048 Solutions
New Discussion

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

 
GPissutto
Frequent Advisor

MCServiceGuard 11.20 for EXT SAP 5.1 sap.functions

 

Hi folks,

Please, Does anybody know if there is any issue with file sap.functions in MCSG SAP EXT 5.1?, because I'm getting this error when I start the package:

 

Oct 21 11:57:46 AM - Node "svr1": (get_source): Found /etc/cmcluster.conf
Oct 21 11:57:46 AM - Node "svr1": (get_source): Found /etc/cmcluster/PRD/sap.config
Oct 21 11:57:46 AM - Node "svr1": (get_source): Found /opt/cmcluster/sap/sap.functions
/etc/cmcluster/PRD/sapwas.cntl[6]: syntax error at line 572 : `(' unexpected
Oct 21 11:57:46 AM - Node "svr1": (get_source): Found /etc/cmcluster/sap.functions
/etc/cmcluster/PRD/sapwas.cntl[6]: syntax error at line 572 : `(' unexpected
Oct 21 11:57:46 AM - Node "svr1": (get_source): Found /opt/cmcluster/sap/SID/customer.functions
Oct 21 11:57:46 AM - Node "svr1": (get_source): Found /etc/cmcluster/PRD/customer.functions
/etc/cmcluster/PRD/sapwas.cntl[269]: initialize:  not found
/etc/cmcluster/PRD/sapwas.cntl[270]: app_handler:  not found
/etc/cmcluster/PRD/sapwas.cntl[2]: start_saposcol:  not found
/etc/cmcluster/PRD/sapwas.cntl[3]: start_own_app:  not found
/etc/cmcluster/PRD/sapwas.cntl[310]: LogMsg:  not found
        ERROR:  Function customer_defined_run_cmds
        ERROR:  Failed to RUN customer commands

 

I did some tests modifying sap.functions and there is something happening with  `( , I erased some of them and it passed, but that's not the idea I neither need nor have to modify it. There is something regarding the shell execution, but I am not able to see it.

 

I appreciate any help you can provide.

 

Thanks in advance.

 

13 REPLIES 13
Dennis Handly
Acclaimed Contributor

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

>/etc/cmcluster/PRD/sapwas.cntl[6]: syntax error at line 572 : `(' unexpected

 

What's on line 6 and line 572?

GPissutto
Frequent Advisor

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

 

Line 572 is this line in sap.functions:

 

if [ `(su - ${3} -c "${location:-cleanipc} ${2}") 2>&1|grep "Shared Memory Key"|grep "Att"|wc -l` -ne 0 ]; then

 

I modified to:

 

if [ `su - ${3} -c "${location:-cleanipc} ${2}" 2>&1|grep "Shared Memory Key"|grep "Att"|wc -l` -ne 0 ]; then

 

And it passed, but then another line of the same characteristics was marked with the same syntax error (in sap.functions)

 

This happens after the function get_source in sapwas.cntl is called and the error happens only for sap.functions files (both /opt/cmcluster/sap/sap.functions and /etc/cmcluster/sap.functions)

 

 

 

Line 6 is in sapwas.cntl, and after function get_source (the sixth line in the function) where all the files called by get_source are executed with "dot space":

   . $1    # display any errors

 

Thanks.

 

 

 

 

Dennis Handly
Acclaimed Contributor

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

>if [ `(su - ${3} -c "${location:-cleanipc} ${2}") 2>&1| grep "Shared Memory Key" | grep "Att" | wc -l` -ne 0 ]; then

 

Hmm, I'm not sure why they would have an extra set of () there?  What shell is on the first line of the script?

I would also split it into two lines:

su - ${3} -c "${location:-cleanipc} ${2}" 2>&1 | grep "Shared Memory Key" | grep -q "Att"

if [ $? -eq 0 ]; then

GPissutto
Frequent Advisor

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

 

That's exactly the problem, we are not supposed to modify sap.functions, is part of the Sap Extension Toolkit, and it is a robust script written by HP, and there is no shebang at the begining of the script, cause it is called with "dot script" in the sapwas.cntl and sapwas.cntl is called with "dot script" as well in the dbciPRD.cntl script, and this is called by the cluster, which works with posix or sh (here I'm not sure), so the thing is that it is and standard procedure.

GPissutto
Frequent Advisor

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

There is something wrong with sap.functions that comes with Sap Extension 5.1, I used an older version (B.04.51.00), and it worked fine, everything is now working properly. So, I don't know what is the problem here, may be the installer made a mistake in both nodes when I installed the software or there is a bug...I don't know.

Dennis Handly
Acclaimed Contributor

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

>That's exactly the problem, we are not supposed to modify sap.functions

 

Have you reported the problem to HP?

 

>is part of the SAP Extension Toolkit, and it is a robust script written by HP, and there is no shebang at the beginning of the script, cause it is called with "dot script" ..., and this is called by the cluster, which works with POSIX or sh (here I'm not sure)

 

You might try using that fragment in sh and ksh to see if one accepts it.

GPissutto
Frequent Advisor

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

Not yet, but I'm going to ... thanks anyway.

 

Cheers

 

Dennis Handly
Acclaimed Contributor

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

>You might try using that fragment in sh and ksh to see if one accepts it.

 

I have no problems with that extra () in that if.  But I don't know what $3, $2 or $location are.

JeanMesquida
Senior Member

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

Hi GPissutto,

 

The same behaviour occurs on one upgraded SGeSAP : did you find a solution to your problem ?

 

Thanks and best regards

Jean

Cortes Albertino
Trusted Contributor

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

Hello,

 

Check if PHSS_42151 is currently installed on these impacted systems.

This problem has already been reported to HP.
A patch is planned to become available by March 2012 to correct this.
This issue is addressed in a change request QXCR1001166323.

You can contact HP support for extra details if needed.

 

Hope it helps,

Albertino

JeanMesquida
Senior Member

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

Merci/Thanks Albertino

 

A bientôt

Jean

Cortes Albertino
Trusted Contributor

Re: ServiceGuard 11.20 for EXT SAP 5.1 sap.functions

Hello,

 

The fix is now available PHSS_42569 ( contains also QXCR1001162701 fix ).

 

Hope it helps,

 

Albertino

Stephen Doud
Honored Contributor

Re: MCServiceGuard 11.20 for EXT SAP 5.1 sap.functions

See

PHSS_42569    11.31 SGeSAP B.05.10 cumulative patch