Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

remote login issue

 
Mohtashim Shaikh
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
We have a setup whereby we cannot login to ServerB directly by using putty.

We have to first login to ServerA by providing username and password and it somehow takes us to serverB and prompts for the password for my login id for ServerB. Providing the password again logs me onto ServerB where I have a script test.sh which I need to execute.

I wanted to automate the execution of script test.sh on ServerB from my local windows machine hence I wrote the below command.



This command logs me onto ServerA but does not take me to ServerB hence test.sh script is not found.

I cannot logon to serverB due to this hopping concept in place.

Kindly help me with some work around.

Note: ServerA and ServerB both are unix servers.
 
Pat Farrell
Rancher
Posts: 4678
7
Linux Mac OS X VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try connecting from a non-windows box. OS-X or another Linux or even Unix.
They all have ssh clients you can use.

Try using something besides putty to see if it is a putty-specific problem.
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Perhaps shh access has been restricted to specific hosts. Look at the /etc/hosts.allow and /etc/hosts.deny files on ServerB.
 
Pradeep Kumar
Ranch Hand
Posts: 108
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My two cents on this. How is that you can login to ServerB from ServerA and not from your local windows machine.

To verify if the ServerB is accessible from your local windows machine try pinging the serverB from the cmd window. If you cannot ping then the serverB is not in the same network or domain.
To verify that the ports are open form your local windows machine try doing telnet to serverB from putty to port 22 which is the default port for ssh login. If you are not able to telnet to ServerB you cannot login to the remote machine.

Also are ServerA and your machine on the same domain? In case they are not in same domain, you need to use SSL VPN to connect to the ServerB from your local machine.

In case they are in the same domain, you need to see if there is any proxy required to login to ServerB from your local machine. Check with your system administrator for more details.

Hope this helps.

Http://www.unixonthego.com
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic