Mounting remote directories over SSH from Windows, Linux and the mac.

I have a Linux server that I like very much. It’s at the hart of my home network and it houses all the data and projects I’m working on. My music collection, the podcasts I’ve downloaded, textfiles and scripts I’m working on and so forth.

The downside is that I don’t always have access to these files. I work on a variety of operating systems (A Windows laptop for work, A Mac for my creative splurges and a Linux workstation to fool around with). There are several solutions to “dail in” to your home network of course but somewhere I’ve found SSH to be one of the simplest ways to access remote machines, tunnel traffic and … access files.

Sometimes you want remote files to behave like local ones.

The problem is that sometimes you want to have your remote files and folders behave just like your local files and folders, without having to worry about vpn’s, netbios or FQDN names of certain files. You just want the data on your remote machine to act like data on your local one. Enter SSHFS.

SSHFS is based on SSH, a simple elegant and secure protocol that not only lets you connect to a remote server to run commands in a terminal environment, it’s also a pretty good poor-mans VPN you can tunnel all your tcraffic through (via SSHuttle). It’s also good to copy over files via secure ftp (with Filezilla for example). But copying files back and forth isn’t handy. You want real-time access to the juice man. Let’s get you fixed up and mount your remote linux folders, natively into your filesystem on Windows, Mac and Linux.

SSHFS on a Linux client.

SSHFS on Linux
On your Linux client you need to install sshfs
sudo apt instal sshfs

sudo apt instal sshfs

Then you create a directory on your local machine where you want to mound the files
Once installed you connect to your remote machine with the command

sshfs username@remotemachine:/directoryonremotemachine /directoryonlocalmachine

SSHFS from a MacOs client.

SSHFS on Mac
MacOs does not have sshfs capabilities by default but these can easily be installed via Brew
When brew is installed you can install sshfs with the brew command.
To mount your remote directory just use the same command as on Linux/

 brew install sshfs 
sshfs username@remotemachine:/directoryonremotemachine /directoryonlocalmachine

SSHFS from a Windows Machine

That also works but it does require a little more work to get it done AND Windows won’t let you mount to a folder nativey but points you to a driveletter instead.

First off install the following two applications:
sshfs-win
WinFsp

Next all you need to do is open a command line window and enter the following command.
net use .<yourdrive>: \sshfs\yourusename@remotehost….\directorystartingfromroot

 net use x: \sshfs\me@thedeathstar.empire....\deathstarplans R3belsRscumm 

In the end.

At the end of the day using SSHFS is a great way to quickly access files on a remote Linux system while having the files and folders integrated into the filestructure of whatever operating system you use. The additional encryption provided by SSH gives you good security. Both on Linux and on the mac you will be asked to authenticate with your password. If you don’t want to do that you setup ssh key exchange (see here) on how that is done. You can enter the commands in a script that you can just run (like a logon script).


Beware then when you are doing this on Windows your logon script might contain your login and your password for the remote system in clear text. So keep that somewhere safe.

Related Posts

KW1203 – Stick It

This week Knightwise dives back into a topic to help you make better use of hostile foreign computers. With the proliferation of high-speed high-capacity USB thumb drives it’s easier than ever before to carry your computing workload with you and run your life from a stick.

Links

Credits

Episode produced by Keith Murray
Home screen picture courtesy of MaxPixel

Related Posts

KW1107 Let the Technology Work for You

Toolbox

We’re back! It’s the first episode of 2017. Knightwise reinforces the sliders ethos by kicking Linux to the curb — well sorta.

Links

Music

  • Lightning Traveler – Summer [Jamendo]

Credits

Related Posts

The Many Faces of Reddit

On the Internet, we all have our “time sinks”; those big bad dark rabbit holes that suck up our attention for hours on end while real life (and productivity) passes us by.

For some of you that might be Facebook, Google+, Pinterest or even Wikipedia (in which case, bravo!). For me my time sink is Reddit. Yes that strange forum-place that has a “sub” for just about anything and is packed with comments, snarky remarks and all out flame wars. In short: the best and the worst the Internet has to offer.

I have personally selected a set of sub-reddits that interest me, from /r/chernobyl to /r/homeservers and from the intriguing /r/documentaries to the embarrassing /r/tifu. Reddit continues to be a source of entertainment and information for me that can keep me away from the mediocre rivers of sludge that we call Facebook or the “mainstream” media.

I interact with Reddit on a variety of platforms and locations. In short: If it has an Internet connection, I want to be able to check Reddit on it. I seldom stoop so low as to access Reddit via a regular browser (only if I have to) and prefer to use the following clients instead.

iOS: The ‘Official’ Reddit client
On my iPhone (and iPad) I have tried out several apps that let me have digital intercourse with the little alien guy (The Reddit icon) but I have settled on the standard Reddit client. Its not as highly configurable al some of the alternatives but its simplicity has its advantages when you are on the road. Commenting, browsing and searching through subreddits is easy and the apps is pretty fast. 4/5 stars!
Reddit for iOS (App Store)

Windows: Redditting
There are not a lot of cool apps in the Windows store, but Redditing is surely one of them. This great Windows clients lets you browse Reddit easily both on a “standard” desktop interface or on your Surface pro 4 using your stubby cheeto-covered fingers. I love using Redditting to browse through the wallpaper section of Reddit (/r/wallpapers or /r/starshipporn) and downloading all the cool wallpapers using the cool “download” button.
Redditting for Windows (Microsoft Store)

Linux: Rtv
On Linux (On my Raspberry Pi that is) the command line is your friend and RTV is probably one of the coolest and nerdiest applications out there. RTV gives you a nice color coded CLI interface to browse your favorite subs, do posts and make comments. Clicking a link opens a command line browser which makes /r/wallpapers a Sub that is a little … empty.
Rtv for Linux (Github)

MacOS: Reditr
Finally when I cuddle up behind my massive 15″ Macbook Pro I use Reditr to browse through Reddit. When it comes to look and feel its a lot like Redditting, minus the touch-friendly design. The great thing with Reditr is that it is fast and simple to work with, giving you a learning curve that a brain dead hamster could master in under 30 seconds.
RedditR (Mac App Store)

Android: Reddit is Fun
Reddit is Fun ‘makes’ reddit fun on Android tablets and smartphones. A true and capable competitor to the “official” Reddit app with the standard abilities to post, comment and up-vote but which also sports an easy to learn interface that lets you discover NEW reddit subs just by punching in the right search term. Now you can say you stumbled across your favorit /r/bronies completely BY ACCIDENT.
Reddit is Fun (Google Play Store)

Reddit is great and has a lot to offer. Thanks to these cool clients I’m able to get the most out of my time spent on the site. Up-votes, down-votes, comments, replies, fresh posts. I start them on one device and pick up where I left off on another… “Slider Style!”

Related Posts

Windows on the Dell

A little more then a year ago I bought my very first laptop that came pre-packaged with Linux. My slick, cool, small and light Dell XPS 13 was probably the first laptop I bought that did not have the OEM stickers stuck to the palm rest, removed. Usually I peel off these lame “Windows” or “Intel” stickers, but in this case the shiny orange UBUNTU sticker stayed on as a badge of honor.

I have been using the machine quite frequently over the last year, mostly tinkering with it to get the “pre-installed” version of Ubuntu “just right”. Because quite frankly, as “compatible” as this machine ought to be with Linux, it wasn’t. After several hours spent scrolling through forums, chatting on IRC and posting on Reddit I had rolled back the bios version and edited a bunch of config files just to stop the keyboard from jumping to “aaaaaaaaaaatttttorrrrrrrrrepeat” (very annoying). But like the owner of an Alfa Romeo I enjoyed the process because I love to tinker.

Fast forward about a year and my life is a little bit different. With a full time consultancy gig at one of my clients and quite a few business projects on the side, I don’t have as much free time as I used to have. As a result, the little Dell got started to get left out. Since I needed some business applications like Office, Visio and Outlook (for the gig at the client) I did not get a chance to play around with the Ubuntu sporting Dell as often as I wanted to.

Several times I’ve tried to switch over my workflow to be as “cross platform compatible” as I could, but when you need to send Visio or Word files back and forth, Open Office might be found lacking at times. The other point of sheer frustration was that I could not (neither with my own skills or those of the bluetooth stack developer) get a bluetooth mouse to work under linux. Result ? The XPS started collecting dust in favor of my Surface Pro 4 that went to work with me every day.

So this week I said “no more”. I was fed up with having an expensive laptop just sitting there because it’s OS doesn’t fit into my workflow and I don’t have the time to adjust my workflow. So I wiped it and installed Windows 10 on it gasp!

Have I betrayed my Linux roots? Have I forsaken my sliders promise? No. I have not.

I am still running Linux on it! 🙂 A fast, snappy and dark-themed version of Linux Mint is what i’m using right now, in a VM! Thats right I’ve decided to stop letting hardware issues and workflow incompatibly interfere with my chance to run Linux. Now I just run Linux on all my machines… in Virtual Machines! Along with whatever core OS (Windows, MacOS) sits on top of the hardware.

I’ll write about my experiences more later this week (don’t want to bore you with a mega long post) but suffice to say that thanks to modern day processors and snappy VM apps like VirtualBox, there is no noticeable difference between running Linux in a VM and running Linux natively on the hardware. Aside from the fact that everything just works! And I can just “slide” my mouse across to my second screen and finish up that Visio drawing, using my bluetooth mouse!

In the end everyone wins. I get to have Linux at my fingertips, I still have the power to use “work” related apps whenever I need to and my little Dell XPS 13 is living up to be a good investment because now I finally use it some more. I ended up dual-booting Linux years ago to go native. I’ve not given up running Linux natively; I just want to “slide” from OS to OS and with these VM’s that works just fine.

Image Credit: Pierre Lecourt on Flickr

Related Posts

Fight Your Digital Redundancy

Device Overload

How About “Just” the iPad?

Whenever I have been pack my bag for my morning commute I get annoyed with the sheer redundancy of the stuff I take with me. Here I am packing not one, but three or four “computer capable” devices into a bag to haul off to some office somewhere.

Not only am I carrying around more devices then I could possibly operate at one time, the software on these devices is redundant as well. For some reason I cannot fathom I have 3 different versions of Microsoft Word on my person. One on my PC, One on my smartphone and one on my tablet. It is possible to dream up a situation in which I might be required to use said trifecta of Microsoft’s favorite text-blender simultaneously… but that would involve an alien invasion and myself in the unlikely role of the geek that saves the world with a bulleted list.

Blame the Lizard Brain

So why do we (still) cling to this redundancy? The answer is simple: because it feels safe. After 7 years in the tablet era we still have not come to “trust” these devices in a way we trust our beloved PC’s (which by now are seriously starting to mimmic our tablets in both appearance and behavior). God knows its not because the tablet apps are by some means sub-standard or don’t offer what we need. The one major hurdle the tablet haters could never get over was the lack of an ‘actual’ filesystem on iOS or Android. Sandboxed applications drove them insane. Yet what do we see today? PC based operating systems are – out of sheer self-preservation – starting to move in a very similar direction. Windows 10 supports installation of unified apps from its app store (in essence a sandbox) and Linux is embracing a more contained approach to applications with their container-oriented Snap packages. With the average smartphone having enough RAM and CPU power to put a PC from 2013 to shame and even the most low-end tablet having a screen resolution that matches the TV in the living room, technical shortcomings are no excuse either. Then what is it that turns us into digital packrats?

The real answer is in the fact that we only think we are carrying around redundant devices because we make them redundant.

We install Word on our phone, our tablet and our laptop because we can. We try to read a spreadsheet on our phone because we can. We even try to edit family photos on a 7 inch laptop using nothing but our stubby fingers. All because we can. Certainly not because we have to.

Somehow with the overabundant availability of identical software on different devices we have started to think that we have to click on “install” everywhere. No wonder it feels redundant.

Specialization is the Key

If we truly where to look at the real strength of each device, we would figure out what do do where pretty quickly. Short messages and communication? Phone. Watching video’s on the go or browsing through news articles while sitting on the train? Tablet. Full blown posture friendly photo editing? PC/Laptop.

You see? No more redundancy. Instead you have a sense that your devices are complementary, depending on the task you do and the situation you are in.

Don’t do a 3000 piece jigsaw puzzle with chopsticks. Don’t use a lawnmower to trim your nails. Stay away from the firehose when you want to water that delicate orchid in the living room. Each device has its use, its purpose and its strength (just like you btw). So remember that next time you feel tempted to install Powerpoint on your smartphone: (to quote commander Scott in Star Trek V) “Use the right tool for the right job!” So ask yourself: “is this really the right device for the job? And if it’s not, do it somewhere else.

Related Posts

KW1105 60 Minutes of Common Sense

The knightwise.com podcast is back this week with a splash of cold water and a dose of plain old common sense. This week we talk about some strategies to keep you, your devices and your data out of nefarious hands. Vigilance, my friends.

Links

Music

Credits

Related Posts

KW1103 The World of Words

This week Knightwise delves into the world of words and how he gets the words out of his head and down onto the virtual page across the myriad platforms that he finds himself.

There are lots of different editors for different kinds of jobs. Check out a whole bunch of them on this week’s episode of the knightwise.com podcast.

Links

Music

Credits

Related Posts

KW1102 Thinking Inside the Box

It’s time to get virtual.

On this installment of the podcast Knightwise delves into the topic of virtualization and talks about how to make the most of a single piece of hardware by letting it do the job of multiple different machines.

We are also joined by special guest Matthew Williams of Open FOSS Training who tells us about his new video tutorial and provides some tips for working with VirtualBox on Windows 10.

Links

Music

Credits

Related Posts

KW1101 The Knightwise Identities

We’re Back!

After a long winter’s nap the Knightwise.com podcast is back for another season of cross-platform goodness. Season 11 kicks off this week with Knightwise doing something he hasn’t done in a few years. Come along for the ride as our intrepid host talks about managing work, life and your multiple selves in the digital age.

Links

Music

Credits

Related Posts