ssh is terrifically easy

I mentioned a week or two ago that ssh was on my list of favorite utilities and tools, alongside things like nfs and the double-greater-than symbol. I didn’t say much about the experiences I’ve had with it though, and since that’s a slight oversight I thought I’d take the time to endorse it properly.

I most recently used ssh between the Sotec desktop machine running Arch Linux, and the two laptops I have both running Crux (at one point I had the Inspiron running Ubuntu, and I know I used it at one point on that machine, but it was brief and only for a minute or two). In this case I had set up the desktop to run “headless,” which I understand to mean “without an attached monitor.” (So can I call a machine without a keyboard “fingerless?”)

If you’re not familiar with ssh, it is, in a nutshell, exceptionally cool. That machine had no keyboard, mouse or monitor, so controlling it was done by logging in across the network. On one machine that was wired and on another it was wireless, but it doesn’t really matter since both machines suddenly “became” the host machine.

And I could rely on configurations and settings saved on the host machine to trigger when I logged in over the network. As an example, the .screenrc file on the host machine took effect when I started screen after signing in. That might sound unnecessarily oversimplified, but once you see where I’m going with this, it becomes so obvious as to be genius.

With screen started, I could detach and reattach between machines. You might already acknowledge screen (or similar programs, like tmux, et al.) as useful when working only on one machine. Now imagine signing in to a machine over your network, starting screen and, for example, rtorrent plus a couple other programs, detaching screen, signing off on that machine, then signing back on from a second machine, and reattaching the screen session that is still running.

Again, I apologize if that seems like a dreadful oversimplification of what ssh and some other programs can do under these circumstances. It sounds rather obvious to me too, but again, I began my computer adventures working on mainframes, and it would be more surprising to me not be able to do those things.

But an added benefit to a “home” user is that a machine can run by itself, in a corner, with no accessory devices (like monitor, mouse or keyboard). If it were light enough, and perhaps low-powered, it could conceivably use as little energy as a laptop, and if it was one of a rare breed of quiet desktops, you wouldn’t even know it was on. Once again I think of that strange 400Mhz Celeron desktop I once found, with no fans in it and only a strange fork-shaped heat sink; it would have been perfect.

It also means you can strip a machine to almost nothing and incur no necessities, like the monitor, etc. You could even rely on it to run in a memory-only machine, or something booted from a live CD and running without a safety net. Or perhaps a laptop with a shattered LCD. :mrgreen: In any case, once you see the value of being able to control a machine, interactively, over a distance, the possibilities multiply exponentially. ;)

And I know it’s probably not a wise idea, but I switched to the root account (with su, not logging in as root) more than once, and updated the system software, or performed a reboot. Once the machine had restarted, I signed on again and continued whatever mischief I had started.

Setting it up was a piece of cake, mostly because the Arch Wiki, of course, has a fantastic page set aside just for that purpose. (Is there anything the Arch Wiki doesn’t have excellent instructions for?) It literally took me only two edits of the configuration file, a quick addition of the ssh daemon to my /etc/rc.conf file, and I was in business. Usually I have to troubleshoot these things for a few minutes before getting them right, but ssh worked for me on the first try.

I suppose I can stop gloating over it now, since it’s only the most fundamental and commonplace of tools, and I’m behaving as if it were a cure for cancer. Still, for as many peculiar spots as you can find yourself in, or as many unusual and contorted systems as you can find in a garage sale, this works as a great solution. If nothing else, it can save you a minute or two getting up out of your chair to walk across the room and press a key or two. I’m always in favor of that. :D

About these ads

10 Responses to “ssh is terrifically easy”


  1. 1 mostlylinux 2009/07/21 at 11:43 PM

    To make it even more fun, you can edit /etc/motd on the headless machine and replace the contents with a nice ASCII art welcome (or anything else) for yourself when you log in with SSH. (:

  2. 2 Barrucadu 2009/07/22 at 12:52 AM

    I’m actually planning to build a little headless server tomorrow and control it via SSH :)
    I’m using a miniITX mobo with an Intel Atom 230 processor so the power usage should be low enough to be able to leave it on all the time.

  3. 3 BergAsche 2009/07/22 at 1:22 AM

    i LOVE it when i have to login to my little server over ssh. its an miniITX atom board machine for torrent, storage and other stuff.

    but its also very handy for remote troubleshooting, or for example when my father, a pc newbie, wants a new program installed.

    motd showoff!!!
    http://img3.imagebanana.com/img/j9a0qvyk/Screenshot.png
    :D

  4. 4 JakeT 2009/07/22 at 2:30 AM

    I use XP at work. I love being able to login (via ssh) to my home server when I need some UNIX-style networking tools, or when I want to check how something shows up outside our proxy server. Very handy.

  5. 5 road 2009/07/22 at 5:19 AM

    i only started using SSH heavily a few months ago but it has changed the way I “live”, computing wise. i communicate with a few linux boxes, but use XP at home and at work, and these both run openSSH/Cygwin, nearly seamlessly. ssh and scp has made it practically irrelevant which computer has what…

  6. 6 Nepherte 2009/07/24 at 4:02 AM

    You probably meant “exponentially” instead of “logarithmically”. The exponential function is the fastest growing function as oppossed to the logarithm, which is, I believe, the slowest ;)

  7. 8 Luca 2009/07/27 at 7:42 PM

    I picked up an old thin client off eBay a few years ago for about £50. It has a 700Mhz Crusoe processor, 512mb of (upgradable) RAM, and a 512mb (rather slow) SSD drive. I have Grub installed on the internal drive, along with a custom initramfs which boots the system off a USB drive (the BIOS doesn’t support booting from USB)! Best of all the machine uses about 10W and is silent!


  1. 1 Putting the Pentium back to work « Motho ke motho ka botho Trackback on 2009/08/03 at 9:37 AM
  2. 2 Things to do with an old computer « Motho ke motho ka botho Trackback on 2010/01/03 at 12:27 PM

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s




Welcome!



Visit the Wiki!

Some recent desktops


May 6, 2011
Musca 0.9.24 on Crux Linux
150Mhz Pentium 96Mb 8Gb CF
 


May 14, 2011
IceWM 1.2.37 and Arch Linux
L2300 core duo 3Gb 320Gb

Some recent games


Apr. 21, 2011
Oolite on Xubuntu 11.04
L2300 core duo 3Gb 320Gb

Enter your email address to subscribe to this blog and receive notifications of new posts.

Join 405 other followers

License

This work is licensed under the GNU Free Documentation License. Please see the About page for details.

Blog Stats

  • 3,960,821 hits

Archives


Follow

Get every new post delivered to your Inbox.

Join 405 other followers

%d bloggers like this: