I created 2 monitors to test our sftp(k) environment. The 1st monitor tests
sftpk (cert based authentication) and the 2nd tests sftp (userid/pass
authentication). Both monitors connect to our sftp server, upload a file, then
delete the file from the sftp server. If I have the configured credential
domain account actively logged onto the IPMon Windows server both monitors
work. However, if the account is not logged into an RDP session, only the
certificate based monitor works (sftpk).
Here's the setup:
2003 server.
Saved profiles in Putty for both.
Tried entering all on command line and just referencing psftp.exe in the
external process job.
Tried adding all environment variables to the job for domain user acct in
question. This domain user account runs over 100 other monitors successfully.
===================================
If I configure the sftp monitor job (credential based) to load a saved putty session, the monitor remains
green. However, the sftp server shows no record of a connection attempt for
this job and ipmon logs show the following:
2012-05-17 12:10:09 monitor state change | from(disabled) to(uninitialized)
name(SendFile SFTP.somehostname.COM [sftpserver01] ) type(external process)
id(1371424934976)
Next entry after setting monitor to "Disable"
2012-05-17 12:15:24 monitor state change | from(up) to(disabled)
name(SendFile SFTP.somehostname.COM [sftpserver01] ) type(external process)
id(1371424934976)
SFTP Server has no record of a connection attempt.
===================================
If I use the external process and call psftp.exe while specifying all
options on command line (not using a stored putty
profile), the monitor works ONLY when the configured credential is logged
on to the server desktop.
2012-05-17 12:22:18 monitor state change | from(disabled) to(uninitialized)
name(SendFile SFTP.somehostname.COM [sftpserver01] ) type(external process)
id(1242575916096)
2012-05-17 12:22:32 monitor state change | from(up) to(disabled)
name(SendFile SFTP.somehostname.COM [sftpserver01] ) type(external process)
id(1242575916096)
ipaddr - domain\testacct [17/May/2012:12:22:18 -0500] "user
domain\testacct" 331 0,
ipaddr - domain\testacct [17/May/2012:12:22:18 -0500] "pass
*******" 230 0,
ipaddr - domain\testacct [17/May/2012:12:22:20 -0500] "created
/Usr/IPmon/spool/test/IPMONsftp_testsftp.txt" 226 13006,
ipaddr - domain\testacct [17/May/2012:12:22:21 -0500] "dele
/Usr/IPmon/spool/test/IPMONsftp_testsftp.txt" 250 0,
ipaddr - domain\testacct [17/May/2012:12:22:22 -0500] "quit -, 221 0,
===================================
Again, regardless of how I setup the monitors, if the account
"domain\testacct" is actively logged onto Windows on IPMon Server,
the monitors work.
If the account is not logged onto the Windows Server, only the sftpK monitor
(certificate based) works.
What am I missing and how can I make this work?
Thanks
External Monitor Config:
Executable Name: psftp.exe
Directory: C:\Program Files\PuTTY
Cmmd Line Params: -l testacct -pw somepasswd -batch -bc -be -b "D:\ JobScripts\SFTPScripts\ipmonTosftp.sh"
SFTP.somehostname.COM
Startup Dir: D:\JobScripts\SFTPScripts
Credential: domain_testacct
After failures, added environ variables
ALLUSERSPROFILE
APPDATA
CommonProgramFiles
ComSpec
HOMEDRIVE
HOMEPATH
Path
USERNAME
USERPROFILE