Welcome to the new Parasoft forums! We hope you will enjoy the site and try out some of the new features, like sharing an idea you may have for one of our products or following a category.

Executing Autosys through Putty

I have a scenario where i need to execute Autosys through putty.
I need to enter connection string, Username, and Password in the putty and after that i need to give certain commands.

Is the above scenario is possible via Parasoft SOA test?
If Possible please let me know how to do it.

Tagged:

Comments

  • jakubiak
    jakubiak Posts: 813 admin

    Can you perform the execution via command line by passing arguments to specify connection string, username, and password? If so, I would recommend doing that using the External Tool which allows you to call any executable from within SOAtest, passing any necessary arguments to it.

  • benken_parasoft
    benken_parasoft Posts: 1,306 ✭✭✭

    In case this helps, the SFTP Client marketplace extension can also execute commands on a remote host.

  • Hi Benken,

    Can you please explain more about SFTP tool.
    it Consists of below details.
    Host:(It's Connection String Right?)
    Port:
    UserName:
    Password:
    Local Folder: Path of the putty.exe right?

    and can you please explain what to give in command and Argument.

    My scenarios is to enter two commands(one after other)

  • Actually there is no SFTP client.
    I have selected FTP client and SFTP as protocol and i can see the above options.

    Am i doing RIght?

  • benken_parasoft
    benken_parasoft Posts: 1,306 ✭✭✭

    Can you please explain more about SFTP tool.

    It is part of the "Parasoft Functional Essentials Pack" from https://marketplace.parasoft.com
    I linked to the documentation which has details.
    I believe the "FTP client" tool is more restricted in terms of what commands can be executed.

    and can you please explain what to give in command and Argument

    This is for you to decide. :) I am just explaining how you might go about executing a remote command using something other than putty. If you prefer to do this through putty instead then you can use the External Tool as what was also suggested.

  • malavijay
    malavijay Posts: 1

    I need to execute Autorep -j this command through putty. Could you please explain the Autosys-Putty connectivity details?

  • Saran20
    Saran20 Posts: 9

    Have you figured out a solution to run the autosys command through putty

  • Ireneusz Szmigiel
    Ireneusz Szmigiel Posts: 228 ✭✭✭

    @Saran20
    as I understand you want to execute commands on remote *nix server from AutoSys "framework" installed there (I mean on remote *nix server)?
    Am I right?
    If yes, then you should first look at the Putty "-m" option or try to use plink (part of putty package), as it might fit better into your requirements as is mostly used for automated operations.

    Then, when you putty/plink command file prepared, then use in SOAtest with External Tool:

    --
    Ireneusz Szmigiel
    http://www.catb.org/esr/faqs/smart-questions.html

  • benken_parasoft
    benken_parasoft Posts: 1,306 ✭✭✭
    edited May 22

    Instead of PuTTY, you should also just consider using "ssh" (OpenSSH client). It is also included as part of Windows (C:\Windows\System32\OpenSSH\ssh.exe).

  • Saran20
    Saran20 Posts: 9
    edited May 22

    @Ireneusz Szmigiel I tried the below, the test case was successful. Am able to see the test opened putty and login was successful. but I don't think -m option worked. It didn't ran the command in file

    Below is the command in my file

  • Saran20
    Saran20 Posts: 9

    @benken_parasoft i don't find openssh under my C:\Windows\System32 in windows 10

  • benken_parasoft
    benken_parasoft Posts: 1,306 ✭✭✭

    i don't find openssh under my C:\Windows\System32 in windows 10

    In Windows, you install "OpenSSH Client" from "Settings > System > Optional Features".

  • benken_parasoft
    benken_parasoft Posts: 1,306 ✭✭✭
    edited May 22

    It didn't ran the command in file

    I can't comment on PuTTY or why it does or doesn't do something. SOAtest is just calling the executable with the exact arguments you define, similar to invoking it from a Command Prompt.

    However, the bash "history" command generally does not work through ssh sessions by default. I found a solution on stackoverflow:
    History command is not working in a non-interactive SSH command

    From SOAtest I can invoke ssh like this to execute "history":

    Since history prints directly to stdout, you can capture the output using the External Tool's "Console (stdout/stderr)" output. You could chain a Write File tool or Diff tool or Edit tool or Text Data Bank or whatever you desire.

    Using "ssh" is convenient in that it is ubiquitous, generally available across operating systems including Windows. The External Tool in my screenshot executed correctly on both Windows and Linux because in both cases "ssh" is already on the PATH.

Tagged