Using Return Codes (PuTTY and AIX) - SSH

This is a discussion on Using Return Codes (PuTTY and AIX) - SSH ; We need to call an AIX script (scriptA calls programB) from a Windows machine (batch job) using PuTTY (PLINK). ScriptA is a generic wrapper script that passes some parameters to programB. We cannot run programB directly (policy). We've gotten a ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: Using Return Codes (PuTTY and AIX)

  1. Using Return Codes (PuTTY and AIX)

    We need to call an AIX script (scriptA calls programB) from a Windows
    machine (batch job) using PuTTY (PLINK). ScriptA is a generic
    wrapper
    script that passes some parameters to programB. We cannot run
    programB directly (policy).

    We've gotten a Windows batch job to log in with PLINK and start
    scriptA, which runs programB. This works OK, but if there is a
    problem we don't have any visibility into it. The most we have been
    able to do is get a return of 0 that means scriptA was run.

    We really need to know on the Windows machine if either scriptA or
    programB on the AIX machine fails, so we can send an alert (custom
    pop-
    up window) to the Windows server support staff.

    Does anyone here have experience in passing return codes from
    programB
    back to calling scriptA in AIX?

    Does anyone here have experience in passing the AIX scriptA/programB
    return code(s) back to the original Windows batch job?

    Thanks,
    Rand
    REMOVE_rand.r...@bmwnaext.com


  2. Re: Using Return Codes (PuTTY and AIX)

    "Rand Reed" writes:

    > We've gotten a Windows batch job to log in with PLINK and start
    > scriptA, which runs programB. This works OK, but if there is a
    > problem we don't have any visibility into it. The most we have been
    > able to do is get a return of 0 that means scriptA was run.


    I'd do something like:

    Get scriptA to check programB for errors and then print out anything
    bad that happened. Then have the Windows batch job just send that
    output to a log file somewhere,

    (S)

+ Reply to Thread