Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Plink ssh script with multiple usernames

Posted on 2012-03-14
5
Medium Priority
?
1,152 Views
Last Modified: 2012-04-08
Hi

I am trying to SSH to a sonicwall to do backups of the device.

I can manually ssh and then run the command no problem but the issue is I cannot use plink to automate it.

When you ssh to the Sonicwall the first prompt is Login as: - here you can pretty much type anything you want and then press enter you get User: - here you enter the admin username and then you enter the password and your in.

if i do plink -ssh 1.2.3.4 -l admin -pw xyz  it uses admin for the first login but just sits then at the second login.

if I do admin@1.2.3.4 -l admin -pw xyz it does the same thing.

Is there any way to get around this issue.

thanks
0
Comment
Question by:mickinoz2005
  • 3
  • 2
5 Comments
 
LVL 51

Expert Comment

by:ahoffmann
ID: 37723709
if you mean that you have a nested login, then Tcl's expect could help to write a login script
  http://expect.nist.gov/
0
 
LVL 5

Author Comment

by:mickinoz2005
ID: 37726859
Thanks for that will have a look.

Any thoughts on the plink front though?

Think its possible with just plink on its own?
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 37728342
sorry, I don't know plink
0
 
LVL 5

Accepted Solution

by:
mickinoz2005 earned 0 total points
ID: 37800160
I got no solution to this so I want to close it and refund points.
0
 
LVL 5

Author Closing Comment

by:mickinoz2005
ID: 37820800
no solution
0

Featured Post

New Tabletop Appliances Blow Competitors Away!

WatchGuard’s new T15, T35 and T55 tabletop UTMs provide the highest-performing security inspection in their class, allowing users at small offices, home offices and distributed enterprises to experience blazing-fast Internet speeds without sacrificing enterprise-grade security.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Optimal Xbox 360 connectivity requires "OPEN NAT". If you use Juniper Netscreen or SSG firewall products in a home setting, the following steps will allow you get rid of the dreaded warning screen below and achieve the best online gaming environment…
In this article, WatchGuard's Director of Security Strategy and Research Teri Radichel, takes a look at insider threats, the risk they can pose to your organization, and the best ways to defend against them.
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…
Suggested Courses
Course of the Month9 days, 19 hours left to enroll

927 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question