putty.exe -ssh user@systemhost -pw password1 -m c:\putty\sshcommand1.txt -sessionlog c:\temp\puttylog.txt
In sshcommand1.txt put something like to dump data:
cat /dirname/errlog.txt
Regards,
Richard Schoen
Web:
http://www.richardschoen.net
Email: richard@xxxxxxxxxxxxxxxxx
----------------------------------------------------------------------
message: 1
date: Tue, 12 Mar 2024 01:06:22 -0400
from: Dan <dan27649@xxxxxxxxx>
subject: [PCTECH] Automate PuTTY via batch and execute the ERRLOG
command
I am brand new to PuTTY. I am trying to automate retrieving ERRLOG data via batch. FWIW, I installed ?Simon Tatham Putty .76? on Windows 10 and am
using the Windows command line. Here?s where I?m at so far:
putty.exe -ssh user@SERVER -pw TheActualPassword
^ This brings up the terminal with the user successfully logged in:
Using username "user".
Last unsuccessful login: Tue Dec 26 11:26:13 EST 2023 on ssh from
111.15.171.117
Last login: Mon Mar 11 23:23:59 EDT 2024 on ssh from 111.15.171.117
$
As an Amazon Associate we earn from qualifying purchases.