Welcome to the VanDyke Software Forums

Join the discussion today!

Go Back   VanDyke Software Forums > Scripting

Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
Old 12-03-2017, 07:42 PM
VanDyke82nev VanDyke82nev is offline
Registered User
Join Date: Jul 2017
Posts: 17
Jump Host to Remote Server -All-Script Challenge

Okay, I've searched all weekend and can't figure out how to solve this.


I have 600 servers distributed across 75 branch offices. Each branch office has their own jump server. The passwords are all different. I have to pull statuses (just run a couple commands) from all 600 servers.


Is it possible to use SecureCRT to log into these with a script?

I set up a saved SCRT session to one of the jump servers, then did dynamic port forwarding. Then I set up a session to one of the target servers, specifying the firewall from above. It worked.

But the problem is there is no way to import the 75 jump hosts or 600 servers with passwords into SCRT as saved sessions, and manually entering all 675 the passwords isn't a whole lot easier than just doing it all manually.


So I need to run it all from a script. I have it already in a spreadsheet. Like this (fake but similar data)

Jump_IP JH-user JH-pass Server IP srv-usr srv-pass freda oi43uomfw admin1 345d5 freda oi43uomfw roberta spdoowu598 freda oi43uomfw admin1 l6yhl8ik6 freda oi43uomfw admin3 wwfwcf5refg admin iuycowiuy webms4 4edyff5ys5y admin iuycowiuy adminxx r7h8htl8o admin iuycowiuy Adminul das4fasy646y admin iuycowiuy Bharlety df5u6gi7hhi admin iuycowiuy admintx ca4f4lkjl


Can I use the /firewall option?

I would have to guess I can set the port forwarding at the cmd line somehow, but can't find how.

connect ssh2 JumpHost Session username password etc. -port forwarding stuff
Wait for command prompt
connect ssh2 Server  session usnername password etc. -specify firewall above? or use port
wait for command prompt

run version command
wait for results

send exit (from Server)
send exit (from JumpHost)

Last edited by VanDyke82nev; 12-03-2017 at 07:49 PM.
Reply With Quote

firewall , jump host , port forwarding , ssh hop

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT -6. The time now is 12:18 PM.