I'm lazy, so in this case - RedHat 5 - I just used rc.local:

# cat /etc/rc.d/rc.local
#!/bin/sh
#!
# This script will be executed *after* all the other init scripts.
# You can put your own initialization stuff in here if you don't
# want to do the full Sys V style init stuff.

touch /var/lock/subsys/local
/usr/local/staf/startSTAFProc.sh

A lot of my tests involve reboots or (clean and unclean/power-cycles).  I
am not sure if this error occurs soon after a reboot, but I believe it
actually does.

Thanks,
Paul


                                                                       
  From:       David Bender/Austin/IBM                                  
                                                                       
  To:         Paul Ellsworth/San Jose/i...@ibmus                        
                                                                       
  Cc:         Sharon Lucas/Austin/i...@ibmus, staf-users@lists.sourceforge.net
                                                                       
  Date:       01/29/2010 06:50 AM                                      
                                                                       
  Subject:    Re: [staf-users] STAF running but does not return command output
                                                                       




Paul,

On this system, are you starting STAFProc during reboot?  That error
message can occur when STAFProc is started during reboot, and the message
doesn't really indicate that there is a problem with STAF.  We have
sometimes found that the method used to start STAFProc during reboot can
have some side effects when running processes via STAF.  Can you show us
the exact system file updates you have made to start STAFProc during
reboot?  Can you retry your tests when you start STAFProc manually after
the reboot, and assuming they work correctly, try rebooting the system so
that STAFProc starts automatically, and then run the tests again to see if
the problem occurs?  This would help us narrow down the problem.

Thanks,
David


                                                                       
 David Bender          11501 Burnet Rd.   Phone (T/L): 1-512-286-5315  
 STAF/STAX Development Bldg. 903-5B002    (363-5315)                   
                       Austin, TX         ITN: 23635315                
 IBM Software Group,   78758-3400         Email: bda...@us.ibm.com     
 WPLC                                                                  
                                                                       
                                                                       







                                                                       
  From:       Paul Ellsworth/San Jose/i...@ibmus                        
                                                                       
  To:         Paul Ellsworth/San Jose/i...@ibmus                        
                                                                       
  Cc:         Sharon Lucas/Austin/i...@ibmus, staf-users@lists.sourceforge.net
                                                                       
  Date:       01/28/2010 08:25 PM                                      
                                                                       
  Subject:    Re: [staf-users] STAF running but does not return command output
                                                                       





It has shown up again. This is a Linux box. STAF was working fine and a
STAX job was running (STAX machine is separate) and interacting with two
Linux machines. One of them began having this error randomly, as far as I
can tell; it successfully was running processes 14 seconds earlier.

It looks like, from the nohup.out file, this is the "cause" of the failure,
especially since it appears to only effect the process service:

-- snip --
Startup time : 20100128-17:49:35

STAFProc version 3.3.5 initialized
20100128-17:49:44;1143372096;00000100;STAFProcess::processMonitorThread:
Error opening /dev/tty, errno: 6

Thanks,
Paul E.

Inactive hide details for Paul Ellsworth---01/28/2010 10:58:17 AM---It
looks like the AIX box had some funny things going on.  Paul
Ellsworth---01/28/2010 10:58:17 AM---It looks like the AIX box had some
funny things going on. I restarted STAF on it and now it's worki
                                                                       
                                                                       
 From:           Paul Ellsworth/San Jose/i...@ibmus                     
                                                                       
                                                                       
 To:             Sharon Lucas/Austin/i...@ibmus                         
                                                                       
                                                                       
 Cc:             staf-users@lists.sourceforge.net                      
                                                                       
                                                                       
 Date:           01/28/2010 10:58 AM                                   
                                                                       
                                                                       
 Subject:        Re: [staf-users] STAF running but does not return command
                 output                                                
                                                                       





It looks like the AIX box had some funny things going on. I restarted STAF
on it and now it's working ok.

20100122-15:27:31;4370;00000100;Caught STAFException: REGISTER Service
Request (6) - To: local, from Handle: 3, Handle Name:
STAFRegistrationProgram, Request: REGISTER TYPE STAF DATA :90:version:
3.3.5;osname: AIX;osmajor: 3;osminor: 5;osrev:
00CBD5C24C00;name: ;email: ;org: ;
20100122-15:27:31;4370;00000100;Caught STAFException in submitRemoteRequest
(), Exception: STAFInvalidParmException, Text: STA, Error code: 42
20100122-15:27:32;4113;00000100;Caught STAFException in
STAFProcess::ProcessMonitorThread(), Exception: STAFBaseOSErrorException,
Text: STAFEventSemReset: 22, Error code: 10

After restarting STAF, I'm not sure I have any more servers in the strange
state. I'll e-mail again if it happens to a server that is already working
ok. :)

Thanks,
Paul

Inactive hide details for Sharon Lucas---01/28/2010 10:42:04 AM---Try
adding the STDIN option specifying an empty file, e.g. /tSharon
Lucas---01/28/2010 10:42:04 AM---Try adding the STDIN option specifying an
empty file, e.g. /tmp/empty.txt, you created on the machin
                                                                       
                                                                       
 From:         Sharon Lucas/Austin/IBM                                 
                                                                       
                                                                       
 To:           Paul Ellsworth/San Jose/i...@ibmus                       
                                                                       
                                                                       
 Cc:           staf-users@lists.sourceforge.net                        
                                                                       
                                                                       
 Date:         01/28/2010 10:42 AM                                     
                                                                       
                                                                       
 Subject:      Re: [staf-users] STAF running but does not return command
               output                                                  
                                                                       



Try adding the STDIN option specifying an empty file, e.g. /tmp/empty.txt,
you created on the machine where the process is running, e.g. on sjpwr5c2c.
Does that make a difference?

STAF sjpwr5c2c PROCESS START SHELL COMMAND "date" RETURNSTDOUT
STDERRTOSTDOUT STDIN /tmp/empty.txt WAIT

--------------------------------------------------------------
Sharon Lucas
IBM Austin, luc...@us.ibm.com
(512) 286-7313 or Tieline 363-7313


Inactive hide details for Paul Ellsworth/San Jose/IBMPaul Ellsworth/San
Jose/IBM
                                                                       
         Paul Ellsworth/San Jose/IBM                                   
                                                                       
                                                                       
         01/28/2010 12:37 PM                                           
                                                                        To
                                                                       
                                                  Sharon               
                                                  Lucas/Austin/i...@ibmus
                                                                       
                                                                        cc
                                                                       
                                                  staf-us...@lists.sourcef
                                                  orge.net             
                                                                       
                                                                   Subject
                                                                       
                                                  Re: [staf-users] STAF
                                                  running but does not 
                                                  return command output
                                                  Sharon Lucas         
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       


The first return code of 1 doesn't always show up. Here's another machine
that it's happening, this time STAF is running on AIX.

[r...@sjx86098 ~]# staf sjpwr5c2c process start shell stderrtostdout
command "date" returnstdout wait
Response
--------
{
Return Code: 0
Key : <None>
Files : [
{
Return Code: 0
Data :
}
]
}

[r...@sjx86098 ~]# staf sjpwr5c2c ping ping
Response
--------
PONG

Thanks,
Paul
Inactive hide details for Sharon Lucas---01/28/2010 10:31:08 AM---First,
add option STDERRTOSTDOUT so that you can see if thereSharon
Lucas---01/28/2010 10:31:08 AM---First, add option STDERRTOSTDOUT so that
you can see if there's any additional error information whe
                                                                       
                                                                       
 From:         Sharon Lucas/Austin/IBM                                 
                                                                       
                                                                       
 To:           Paul Ellsworth/San Jose/i...@ibmus                       
                                                                       
                                                                       
 Cc:           staf-users@lists.sourceforge.net                        
                                                                       
                                                                       
 Date:         01/28/2010 10:31 AM                                     
                                                                       
                                                                       
 Subject:      Re: [staf-users] STAF running but does not return command
               output                                                  
                                                                       



First, add option STDERRTOSTDOUT so that you can see if there's any
additional error information when it fails.

Also, try adding option SHELL. For example: STAF local PROCESS START SHELL
COMMAND "date" RETURNSTDOUT STDERRTOSTDOUT WAIT

--------------------------------------------------------------
Sharon Lucas
IBM Austin, luc...@us.ibm.com
(512) 286-7313 or Tieline 363-7313


Inactive hide details for Paul Ellsworth/San Jose/i...@ibmuspaul
Ellsworth/San Jose/i...@ibmus
                                                                       
      Paul Ellsworth/San Jose/i...@ibmus                                
                                                                       
                                                                       
      01/28/2010 12:21 PM                                              
                                                                        To
                                                                       
                                                     staf-us...@lists.sour
                                                     ceforge.net       
                                                                       
                                                                        cc
                                                                       
                                                                       
                                                                   Subject
                                                                       
                                                     [staf-users] STAF 
                                                     running but does not
                                                     return command output
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       



This has happened both right after starting STAF as well as after it
already has been working.

It appears to mainly affect starting processes. STAF pinging it works.
Here's an example of the failure:

sjx64ycle:~ # staf local process start command "date" returnstdout wait
Response
--------
{
Return Code: 1
Key : <None>
Files : [
{
Return Code: 0
Data :
}
]
}

It should be:
[r...@sjx86098 ~]# staf local process start command "date" returnstdout
wait
Response
--------
{
Return Code: 0
Key : <None>
Files : [
{
Return Code: 0
Data : Thu Jan 28 10:19:12 PST 2010

}
]
}

Any ideas?

Thanks,
Paul E.
------------------------------------------------------------------------------

The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the
business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users



[attachment "pic09430.gif" deleted by Paul Ellsworth/San Jose/IBM]
[attachment "pic30164.gif" deleted by Paul Ellsworth/San Jose/IBM]
------------------------------------------------------------------------------

The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the
business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users

------------------------------------------------------------------------------

The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the
business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users


<<inline: graycol.gif>>

<<inline: ecblank.gif>>

<<inline: 2D439684.gif>>

------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users

Reply via email to