1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to? Use Take Command for SSH?

Discussion in 'Support' started by aliteralmind, Aug 5, 2014.

  1. aliteralmind

    Joined:
    Jul 23, 2014
    Messages:
    37
    Likes Received:
    0
  2. thorsten

    Joined:
    Aug 16, 2008
    Messages:
    124
    Likes Received:
    0
    PuTTY is a terminal emulator and SSH client but not a shell. That means PuTTY's shell features are not "rudimentary" but simply non-existing. Even if Take Command had SSH built-in, that wouldn't make any difference in regard to the shell on the remote host you are connecting to.
     
  3. Charles G

    Joined:
    Apr 2, 2011
    Messages:
    1,016
    Likes Received:
    0
    SSH.JPG SSH is in the Option dialog - as shown in the attached SSH.JPG
     
  4. Charles Dye

    Charles Dye Super Moderator
    Staff Member

    Joined:
    May 20, 2008
    Messages:
    3,288
    Likes Received:
    39
    Not certain, but I think that's used for SFTP connections.
     
  5. Charles G

    Joined:
    Apr 2, 2011
    Messages:
    1,016
    Likes Received:
    0
    Well - they are marked as SSH - not SFTP so I wasn't sure.....
     
  6. rconn

    rconn Administrator
    Staff Member

    Joined:
    May 14, 2008
    Messages:
    9,809
    Likes Received:
    82
  7. rconn

    rconn Administrator
    Staff Member

    Joined:
    May 14, 2008
    Messages:
    9,809
    Likes Received:
    82
    You can use the SFTP syntax in TCC to connect to an FTP server via SSH.
     
  8. Charles Dye

    Charles Dye Super Moderator
    Staff Member

    Joined:
    May 20, 2008
    Messages:
    3,288
    Likes Received:
    39
    Or maybe the question was about how to run TCC over SSH? You would have to install TCC on the server, of course. The details of how to configure the SSH software to run TCC rather than CMD.EXE will be software-specific.

    If you do manage to get this going, you'll probably want to add ConsolePopupWindows=Yes to your .INI file, since the GUI popups will be invisible through your telnet connection.
     
  9. Charles Dye

    Charles Dye Super Moderator
    Staff Member

    Joined:
    May 20, 2008
    Messages:
    3,288
    Likes Received:
    39
    Wandering off topic: Does telnet pick up on direct console writes such as the console popups and SCRPUT, DRAWBOX, etcetera? Or does it only catch writes to streams like stdout and stderr?
     
  10. Stefano Piccardi

    Joined:
    May 31, 2008
    Messages:
    376
    Likes Received:
    2
    Telnet alone I don't think so. Telnet is a purely text protocol, just like email. You'd need some sort of terminal emulator, possibly over telnet, to write directly to an emulated console. But then I don't know that SCRPUT, DRAWBOX etc. write control sequences, do they?
     
  11. mwb1100

    Joined:
    Nov 6, 2014
    Messages:
    2
    Likes Received:
    0
    I hope I'm not too late for the OP - I'm trying to use Putty in a TC tab and have gotten part of the way there using some techniques that other people have used with the Console2 program. Following the suggestions here:

    http://blog.jimueller.com/post/29709142253/use-putty-with-console2

    I can get a Putty session to run in a cmd.exe window (and therefore a TC tab) with half decent results. Basically, you launch the putty session using the plink.exe command and the session remains in the original console window instead of the console that the GUI putty.exe program would create. For example:

    c:\util\ansicon "C:\util\plink.exe" -load "6467 - HW 1.5 - COM9"

    where "6467 - HW 1.5 - COM9" is the name of the putty configuration I want to connect using. ansicon is a helper program that converts ANSI terminal control sequences (such as for text color or to move the cursor) into appropriate Win32 console window API calls.

    The one problem I have is that arrow keys are not usable in the terminal session. I'm not sure if this is a limitation of Putty, plink or ansicon. It's not a TC limitation because the behavior is exactly the same when running in a standalone cmd.exe console window.

    However, if someone at JPSoft or in the forum can suggest how TC could attach to the console window that putty.exe creates, I'd appreciate it (because I think that will fix the arrow key problem). Putty.exe starts with a simple GUI dialog box to get configuration information, then you you make a connection it creates something that looks like a console window (I'm not sure if it technically is though). I was expecting that TC's "Tabs/Attach..." would list it as something that TC could present in a tab, but no such luck. If someone can explain how I can convince TC to do that (or if JPSoft can take this as a feature request), that would be awesome.
     
  12. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,888
    Likes Received:
    30
    The putty window is not a console; it's a GUI terminal emulator. TCMD won't be able to attach to it.by
     
  13. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,888
    Likes Received:
    30
    But PLINK.EXE is a real console. The command below gives me a nicely colored interactive ssh session (on the remote host "by"). If I execute the command from a TCC running in a TCMD tab, then I return to TCC when I exit the remote session. If I put that command on a TCMD toolbar button (open a new window) that TCMD opens a tab for it and closes the tab when I'm done.
    Code:
    P:\ansi166\x86\ANSICON.EXE g:\putty\plink.exe -ssh by
    The plink session doesn't seem as robust as a real putty session. For example, I ran "vi .cshrc" and couldn't do anything, including exit vi.
     
  14. mwb1100

    Joined:
    Nov 6, 2014
    Messages:
    2
    Likes Received:
    0
    Thanks for the info. I seem to have a little better luck than you: vi works for me in a plink session (at least when using it to connect to the embedded system I'm working on), but arrow keys don't. Given that both ansicon and putty/plink are open source there's some hope I could get this to work better, but I suspect I'll never put in the effort and will just live with putty outside of the TC tabs.
     

Share This Page