IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  call shell script

    Posted Mon September 26, 2011 11:10 AM

    Hi,

    I am trying to call shell script located in tihe remote unix server. I am able to connect to the unix server through sftp connections. Now the challenge is top call shell script. Do we need to write one more java service for that or do we have any in built service for that.

    thanks in advance,
    shafi


    #Integration-Server-and-ESB
    #Flow-and-Java-services
    #webMethods


  • 2.  RE: call shell script

    Posted Mon September 26, 2011 11:14 AM

    SFTP is for file transfer, not for executing shell commands. Although beeing able to SFTP to a server may indicate you can do ssh as well.
    There is no build in service for calling shell commands. But there is an OpenSSH package available (has been on Advantage, honestly I do not know where to look on Empower, maybe somebody cann add the loation here when found). This package makes use of openssh and standard commands available on the IS host.


    #Integration-Server-and-ESB
    #Flow-and-Java-services
    #webMethods


  • 3.  RE: call shell script

    Posted Mon September 26, 2011 11:21 AM

    mwroblinski
    Senior Member
    mkroblinski,

    let me search on openSSH package. I may get those in the sshtools. Thanks for your suggestion.

    please help me if, you get the link for openSSH.

    shafi
    :slight_smile:


    #Integration-Server-and-ESB
    #webMethods
    #Flow-and-Java-services


  • 4.  RE: call shell script

    Posted Mon September 26, 2011 12:11 PM


  • 5.  RE: call shell script

    Posted Mon September 26, 2011 05:39 PM

    Hi,

    IMHO you don’t need any package unless you want to use purely java.
    You could simply call the ssh command with proper parameters to launch command remotely.

    There are also other tools (command line) available opensource to do this…

    But the easiest and faster way would be to do this ssh command. If you add the public key to the server you are connecting to (authorized_keys) then you don’t even need to put a password so it will be fully automatic.

    Jeremy


    #Flow-and-Java-services
    #Integration-Server-and-ESB
    #webMethods


  • 6.  RE: call shell script

    Posted Tue September 27, 2011 03:29 PM

    Hi Jeremy,

    are we talkingabout the same thing? I have the feeling you are talking about making a ssh call from a unix shell, but I’m talking about making the call from inside webMethods, as I assume his was the original question.
    How would you call an ssh command from within webMethods without using any package?


    #webMethods
    #Integration-Server-and-ESB
    #Flow-and-Java-services


  • 7.  RE: call shell script

    Posted Tue September 27, 2011 03:33 PM

    Hi,

    Well these are the 2 ways I just wanted to give the second one :slight_smile:

    The package would mean that you would do it using Java or C (ie: a package containing the openssh jars or c libraries with flow services calling those)

    At the end you are right he was mentioning packages so I guess the shell command is not an option for him …


    #webMethods
    #Flow-and-Java-services
    #Integration-Server-and-ESB


  • 8.  RE: call shell script

    Posted Wed September 28, 2011 04:11 AM

    Hi,

    I have got the ssh packages containing the some java services. So let me try to connect to unix server through those java services then let me write a new wM java to call the perticular shell script.

    :slight_smile:
    shafi


    #webMethods
    #Flow-and-Java-services
    #Integration-Server-and-ESB