DotResults - Quick Tech Answers

PuTTY for OS X? No thanks.

by Daniel on May 24, 2009

Wait! Before you read this post…
If you still need to use Putty, read our instructions to install Putty on OS X.
Let us know if you have any questions!
We’re here to help!

Many folks coming from the Windows world often ask where they can find the PuTTY client for OS X. While I do not wish to undermine the quality of the client (as it is, quite likely, the best for Windows), there is no such need for it on OS X. Why? This is simple – because all of the functionality that PuTTY offers, such as SSH, Telnet and Serial abilities come bundled with your OS X install. Since OS X is based on UNIX, it comes with a massive array of utilities that can be found across most different UNIX based OS’s and SSH and Telnet is no exception.


Although you won’t find a pretty interface for performing your SSH/Telnet needs, it is nevertheless very simple to do (and without having to be a UNIX enthusiast). So how do you do it? Via the ‘Terminal‘ App, of course!

So let us begin.

In most cases, there are only 3 options that most people require from SSH and they are:

  1. Be able to specify an IP/Hostname
  2. Be able to specify an SSH/Telnet port
  3. Be able to specify a private SSH key

All of the above can be achieved very easily and quickly. First, open the ‘Applications‘ folder (cmd-shift-a from Finder or go to your Disk->Applications). Locate the ‘Terminal’ application and drag it over to your Dock. Once there, click the ‘Terminal’ icon and a prompt will pop up. From here, you are just a few keyboard strikes away from SSH’ing and telnet’ing your way around the internets.

To ’ssh’ to a host, type ‘ssh username@hostname.com‘. This is rather self-explanatory – ‘ssh‘ is the command which invokes the ’ssh’ program, ‘username‘ is the user you wish to connect as, and ‘hostname.com‘ is the host you wish to connect to. While there are multiple different syntaxes for ’ssh’, this is likely the simplest one to remember.

Now that we’ve covered how to ‘ssh‘ to a host, lets specify a port. With no more than a couple of more keystrokes we can achieve just that. Same way as we specified the command before, this time around we just tack on a ‘-p 2222‘ to the end of the command. The ‘-p‘ is a command line option that takes an argument. So, the end result:

And finally, lets discuss how to use a private SSH key when connecting to a server via SSH. As you can probably already tell, this is achieved via a command line option as well. The option in question is ‘-i‘ and the argument that this option takes is the location of the private key. If you are unfamiliar with UNIX then locating the private key via the Terminal might be a bit confusing, but thankfully, the OS X terminal has a nice and simple solution to this.

Assuming your private key file is located on the Desktop, you can simply drag it over ‘on top’ of the Terminal window and the path to the key will be automatically added, saving you a whole lot of typing.

As you can see, you can specify multiple options in the same command!

There are many, many more other things you can accomplish with the ’ssh’ client, however these subjects are beyond the scope of this quick intro.

And as a final note – the default color scheme for Terminal is rather ugly and many do not know that the Terminal can, in fact, be just as pretty as any other OS X app. To do so – go to Terminal->Preferences->Settings, select the ‘Pro‘ color scheme/theme and press the ‘Default‘ button. Quit the Terminal application and relaunch. You should now see a Terminal just like in the screenshots above :)

Good luck!


  • Share/Bookmark

Tagged as: osx, putty, ssh, terminal, UNIX

{ 3 trackbacks }

[Tutorial] Install Putty On OS X Leopard - Page 2 - Surpass Web Hosting Forums
May 24, 2009 at 9:30 pm
How to Install Putty on OS X
October 28, 2009 at 7:02 pm
Basic Terminal Commands in OS X
November 3, 2009 at 3:09 pm

{ 6 comments… read them below or add one }

Odessa July 7, 2009 at 5:12 am

thanks!

Winfried Maus October 17, 2009 at 7:05 am

I don’t know – somebody even ported putty to Linux, so obviously there seems to be a demand for putty on Unixes or Unix-like platforms.

The thing is, once you got used to putty’s weird copy & paste behaviour (via marking and right-clicking), you simply expect this functionality in telnet and ssh sessions. It’s actually quite handy and easy to use when you work a lot with Cisco routers.

Furthermore, I can also relatively easy store session-specific profiles in putty.

Since putty (and WinSCP) are some of my mostly used tools at work – where I use a Windows notebook – why should I switch to using something else when I’m in Linux, FreeBSD or OS X? Isn’t this one of the blessings of Open Source and multi-platform applications that I more or less can use my favorite apps no matter what system I’m using?

So – yes, please, bring putty to OS X. :-)

Other than that, you wrote a very nice and helpful article. Thanks for that!

Ed December 16, 2009 at 11:26 am

I’d love to see an example of how to use the serial capabilities.

RE: “Furthermore, I can also relatively easy store session-specific profiles in putty.”

It is extremely easy to add configurations for ssh as well. Simply edit ~/.ssh/config and add entries with your favorite text editor like so:

Host myhost
Hostname myhost.somewhere.net
Port 2222 (optional)
User me (optional, if different from your local account)
Host myotherhost
Hostname myotherhost.elsewhere.net

Plus you can specify local / remote forwards, etc. Then you can simply do:

ssh myhost

And it’ll look it up in your config with whatever options you’ve specified. You can also have global options by using Host *

Beat February 27, 2010 at 4:02 am

Yes! I know JellyfiSSH iTerm and “builtin” ssh. I can work with screen or tmux too. But as System Engineer I have at work sometimes a bunch of open PuTTY sessions. What I miss most is the ability to reconnect or duplicate session with one mouse click. When you are troubleshooting a big network with tons of switches and routers, then You know the benefits of it. And if you have something on the serial console too, it has exact the same Interface. And ad Winfried says: The Cut and Paste behavior is strange. But extreme fast and easy.. PuTTY was for me the most valuable free (MIT Licence) Windows tool ever. It is a pity, that nothing similar is available for OSX

Eric April 14, 2010 at 3:22 pm

While the built-in terminal is good for 90% of people it’s emulation is lacking in several key areas. Putty bests terminal in completeness of it’s emulation, accuracy of emulation, and surprisingly UTF-8 accuracy. It would be great to see a cocoa native putty derivative some day.

CB June 18, 2010 at 9:49 am

One thing putty is nice about is allowing the use of a http proxy to tunnel my ssh connection through. My company forces all ssh traffic through ssh.mycompany.com and putty is the only client I’ve ever seen to allow the use of this. If you know of another, please let me know!

Leave a Comment

Previous post: Truffles and Trifles Orlando Cooking Class

Next post: Twitter’s Future, Glamorization Worries

  • Free UNIX Shell Account
  • Tags

    birdcage blog hosting services brand new cell phones chili cisco class computing cooking cryptographic software device facebook fonts gadget good idea googles handwriting handwriting font identify internet kindles mac macports online social networking openbsd orlando osx peek perl phone bill php programming language putty reason scanning scanning imaging social media spicy ssh system software terminal twitter UNIX web 2.0 wordpress world wide web

2010 DotResults. All rights reserved. Powered by Selans

Get smarter with the Thesis Theme for WordPress