ssh to terminal server


 
Thread Tools Search this Thread
Special Forums Cybersecurity ssh to terminal server
# 1  
Old 03-22-2011
ssh to terminal server

Hi. We are currently upgrading the terminal server in our system (Solaris 8). Previously, we used telnet to reach the terminal server from our maintenance workstation. Now, the new one supports SSH, so we're finally moving off telnet. When logging into the terminal server via telnet, a user was prompted for both a username and password. However with SSH, it seems the user has to specify the username up front (ssh joeshmoe@remoteserver) or the user is prompted for the password of the username for the local workstation. I guess ssh assumes you want to login as the same username on the remote server.

Opening the terminal server session is done by a script that can be used by multiple users. I've figured out how to log into the terminal server via ssh, and specify the terminal server port that I want to use, but I cannot figure out how to leave the username out of the ssh command. Smilie

i.e.,
Code:
ssh joeshmoe:port02@terminalServer

I'd like to leave the username out of the script if possible and have the user be prompted for it.

Thanks in advance for any suggestions!

Last edited by pludi; 03-22-2011 at 04:53 PM..
# 2  
Old 03-22-2011
Just prompt the user for a user name in your script. Then pass the entered user name to the ssh command.
# 3  
Old 03-23-2011
Or use $LOGNAME

Code:
 ssh $LOGNAME:port02@terminalserver

# 4  
Old 03-25-2011
Thanks, Pederabo. I guess I overlooked the obvious solution!
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. AIX

Unable to login in ssh terminal

Hi guys when ever i tried to connect aix server in my institute through ssh terminal the pop is coming like network is unreachable .Am using MacBook air the other guys who are using putty software in windows they can easily login in tho the server through remotely . Is there any one can... (3 Replies)
Discussion started by: aashishb007
3 Replies

2. IP Networking

Ssh port forwarding through a pseudo terminal

Here's a situation: I do all my work on a Mac. I have mysql installed on my mac. 1. There's a certain linux server 'server01' that provides access to another linux server 'server02' via a pseudo terminal So, to ssh into 'server02', I do this from my mac: ssh -t server01... (1 Reply)
Discussion started by: imperialguy
1 Replies

3. OS X (Apple)

Using a private key with SSH in terminal

Before you get the wrong idea, I am not looking for how to generate one. I have a key from a server admin but I can't figure out how to use it in OS X. I have the key, the address and everything I should need but there doesn't seem to be a step by step on how to install the key and use it in... (4 Replies)
Discussion started by: kylebellamy
4 Replies

4. Shell Programming and Scripting

Strange terminal behaviour after killing ssh

Hi, We have a problem where occasionally an ssh will hang for no apparent reason preventing the rest of the script continuing. To deal with this I am trying to write a wrapper script to kill a hung ssh command after a specified period. The scripts use a sleep command running in the... (2 Replies)
Discussion started by: RECrerar
2 Replies

5. Cybersecurity

ssh to terminal server

Hi. We are currently upgrading the terminal server in our system (Solaris 8). Previously, we used telnet to reach the terminal server from our maintenance workstation. Now, the new one supports SSH, so we're finally moving off telnet. When logging into the terminal server via telnet, a user was... (0 Replies)
Discussion started by: jalburger
0 Replies

6. Shell Programming and Scripting

Using ssh to add register key on ssh server

Hi, I want to use ssh to add a register key on remote ssh server. Since there are space characters in my register key string, it always failed. If there is no space characters in the string, it worked fine. The following is what I have tried. It seems that "ssh" command doesn't care about double... (9 Replies)
Discussion started by: leaftree
9 Replies

7. OS X (Apple)

No terminal (tty) after ssh and telnet also

Hi all, we are just confused about a strange problem on one server in production (XServer, running OSXS 10.5.6). It works normal for month. Since two day everthing seems to be fine also with one exception. When we connect trough ssh we won't get a tty session. For testing purposes, we enabled... (2 Replies)
Discussion started by: Frank.Knobloch
2 Replies

8. UNIX for Dummies Questions & Answers

Disable SSH w/ OS X Terminal

I want to shut down SSH, yet I'm unable to. Last login: Sun Dec 14 17:59:36 on console ryans-imac-2:~ Ryan$ service ssh stop service: failed to stop the 'ssh' service ryans-imac-2:~ Ryan$ Please advise. Thanks. (2 Replies)
Discussion started by: pianoman1976
2 Replies

9. UNIX for Advanced & Expert Users

Control process from different terminal (over SSH)

I pressed CTRL Z and suspended the job. then I pressed bg, The process re-started to throw output on the terminal and its not allowing me to access the prompt. its not even accepting CTRL Z. The process has been running for about 2 hours now and I want to suspend it by opening another terminal.... (3 Replies)
Discussion started by: rakeshou
3 Replies

10. UNIX for Dummies Questions & Answers

mac 10.4>terminal>linux remote server>ssh login accepted>session closed-why?

mac 10.4>terminal>linux remote server>ssh login accepted>session closed-why? AHHHH!! I have been connecting to the server with the line: ssh userid@website.com The remote server accepts my password; logs me in with ssh; posts a lovely welcome message AND closes the session. Is this a "term... (0 Replies)
Discussion started by: xprankard
0 Replies
Login or Register to Ask a Question