Wirelessly Mount an iPhone to Your Desktop

This tip is only intended for those who jailbroke their iPhone. This does not apply to unhacked iPhones. Wouldn't it be convenient if your iPhone's filesystem could be mounted directly to your desktop? SSHFS, a MacFUSE extension, uses SSH to mount your iPhone wirelessly to your Mac. Once mounted, the iPhone's entire filesystem is available just like any other drive on your Mac. Here's how to do it (Mac only).

To perform this little trick, you need to have SSH installed on your iPhone. You can grab OpenSSH from AppTapp (aka Installer.app) on your iPhone. You will need to make sure that logging in via the Terminal actually works before using MacFUSE. The most common problem may be that your key has changed. Terminal will warn you of this when you attempt to log in. If that seems to be your problem, remove the "known_hosts" file from your /username/.ssh directory.

How to:

  • Grab the latest version of MacFUSE from Google Code.

  • Get the SSHFS filesystem extension from Google Code as well.
  • Install MacFUSE and reboot your Mac
  • Move sshfs.app to a good spot, perhaps the Applications folder. It doesn't matter.
  • Launch sshfs.app and give it your iPhone's IP address and log in using root. You will need to specify that the remote directory is / . If you don't, things won't work out.
  • Enter the iPhone's password. The default for versions 1.0.2 and earlier is dottie. Default for version 1.1.1 is alpine

That's it, you're done! The same task can be accomplished using SFTP, but it feels more convenient to have it mounted to the desktop, wouldn't you say?


Help

I have followed all the instructions, here but I must be doing something wrong. I find my iPhone's IP address by going to Settings > WiFi on my iPhone. I plug in the IP address, type in "root" and "/", and then connect. When it asks for authentication, I type in "dottie" (I'm using 1.0.2), and it doesn't work. I tried changing the root password using MobileTerminal, then tried putting in that password, but it still didn't work. What am I doing wrong?

Quote:
Originally Posted by *Josh View Post
I have followed all the instructions, here but I must be doing something wrong. I find my iPhone's IP address by going to Settings > WiFi on my iPhone. I plug in the IP address, type in "root" and "/", and then connect. When it asks for authentication, I type in "dottie" (I'm using 1.0.2), and it doesn't work. I tried changing the root password using MobileTerminal, then tried putting in that password, but it still didn't work. What am I doing wrong?
The instructions state that you need to make sure you can log in via the Terminal first. If you've nevever SSH'd into your iPhone, you need to do that first.

just wondering .. since it's able to be viewed as any other drive .. does that mean that any data recovery software that read hfs+ drives would be able to perform data recovery on the iphone volume??

dunno if this has been tried or not but i don't see why this wouldn't be possible .. tons of my lost pictures and notes would be very thankful

Thanks

Thanks for pointing that out. My iPhone has now been successfully mounted on my desktop. Somebody might want to post a step-by-step guide of how to do this with more detail...

Works on Touch as well

Just for anybody's information, this works great on the iPod Touch as well.

I did have one problem that might crop up for others. After installing, I ran sshfs through the regular prompts (including password), but then had nothing happen. It turned out that although I had already been sshing from my Macbook to the Touch, I hadn't actually installed OpenSSH via the installer. (Rather, I was running whatever SSH implementation was installed by iJailbreak.)

After installing OpenSSH, there was another wrinkle -- the previous SSH authentication didn't want to play with the new OpenSSH setup (I can't remember the error message I finally got when sshing through Terminal, but the gist of it was that the SSH client had changed). That required trashing the 'known_hosts' file in Users/[yourname]/.ssh. After that, everything's working great.

Quote:
Originally Posted by *dan View Post
just wondering .. since it's able to be viewed as any other drive .. does that mean that any data recovery software that read hfs+ drives would be able to perform data recovery on the iphone volume??

dunno if this has been tried or not but i don't see why this wouldn't be possible .. tons of my lost pictures and notes would be very thankful
Well, I think you could back up but recovery would be another thing entirely, as in I don't believe that would work

I don't get how to login in to terminal?

You SSH in using the terminal by issuing the command:

ssh -l root the.iphone.ip.address

Exploring

how do you explore in without mounting the iphone as a drive? (I've already SSHed in)

Quote:
Originally Posted by TEBS View Post
how do you explore in without mounting the iphone as a drive? (I've already SSHed in)
It's sort of difficult, that's why this method is good. You could also try SFTP with an FTP application.

hey,

I dont get/ understan the sshing the terminal process this is all foreign lnguage 2 me... is the terminal the sshs login connection? or is it supposed 2 be in my iphone some where? P88j4yls. help the rest i can figure out thank you.

Quote:
Originally Posted by *kid View Post
hey,

I dont get/ understan the sshing the terminal process this is all foreign lnguage 2 me... is the terminal the sshs login connection? or is it supposed 2 be in my iphone some where? P88j4yls. help the rest i can figure out thank you.
To log in using ssh you need the bsd subsystem and OpenSSH installed on your iPhone. Those can be found in installer.app. Once you have that, use terminal to log in.

Log in by issuing the command ssh -l root your.iphones.ip.address and hit return. It might take a while the first time. For the password, enter dottie for everything earlier than 1.1.1 and alpine for 1.1.1

After you've done that you can ssh in.

Hey man,

thanks alot I know you didnt have 2 do that and I realy appreciate it!
Have a great day.

Quote:
Originally Posted by Mubs View Post
You SSH in using the terminal by issuing the command:

ssh -l root the.iphone.ip.address
mubs i'm having trouble sshing in as well. at what stage in the process do i attempt to ssh in using the terminal?
i've jailbreaked, and apparently installed ssh using iNdependence. my understanding is that i can ssh in with the terminal now, but it is not working for me. any ideas?
thanks
-h

Quote:
Originally Posted by ardonut View Post
mubs i'm having trouble sshing in as well. at what stage in the process do i attempt to ssh in using the terminal?
i've jailbreaked, and apparently installed ssh using iNdependence. my understanding is that i can ssh in with the terminal now, but it is not working for me. any ideas?
thanks
-h
You need to have BSD subsystem and OpenSSH installed first. You can get both from Installer.app

ni wi-fi and no ip address

i dont have wi-fi connection and my IP address is lost during reset (Erase all content and setting); then i suppose I cant use this method?

Works on Tiger but not anymore in Leopard.

More information pls

Quote:
Originally Posted by Spoon View Post
The instructions state that you need to make sure you can log in via the Terminal first. If you've nevever SSH'd into your iPhone, you need to do that first.
I installed SSH followed the directions.. Terminal seems to try to log in but hangs... waiting for a response asking for the password.. SSHFS does EXACTLY the same thing.

In term (on the iPhone) I CAN log into the phone using the root/alpine (for 1.1.1) and it DOES get me there.

Tried removing the 'known_hosts" file but man.. I cant find it... a n y w h e r e.. cant even find /username/.ssh directory just exactly where is that located...?

log in as root, unbelievable!

Why can't I ssh

I have been trying to ssh my phone but when it comes down to the password part i can never get in. It just keeps repeating password: like 3 times then it reads root@'s password:. I have 1.1.1 and i type in alpine, but nothin. Please help

This is the latest version of the extension:

http://macfuse.googlecode.com/files/sshfs-1.0.0.dmg

Great Tool

This seems to be working great. I have been looking for an easy way to copy over files where I want them and manipulate things. The only mistake I made was that I just got a new iMac and forgot I needed to check "Connected Servers" in the Finder prefs before I would see my iPhone. Thanks yet again everyone at TUAW.

Quote:
Originally Posted by TEBS View Post
how do you explore in without mounting the iphone as a drive? (I've already SSHed in)
you'll have to install fugu

Please help.. I installed te BSD app and OpenSSH on my Iphone. Then I installed MacFUSE and ssh. I rebooted and then opened the Terminal app on my laptop and typed in...

ssh -l root your.iphones.ip.address
and hited return...
It gave me the following message.
No address associated with nodename

Any thoughts...?

Has anyone tested the latest version on OS X Leopard?

What is the user name to be used?

logged through the terminal but failed the ssh not sure why no message appears.

Steps on how to change icon of your Safari bookmarked in your homescreen. (1.1.3 )

Using SSH, navigate to private/var/root/library/webclips you'll see a different folders w/ long file name (ex.F18042EF-0F23-5433-ADA4-A5528B4F7G32.webclip). Open every folder to locate icon.png. Temporary copy it to your document folder so you know which bookmarked page you're looking at. As you identify the file you can now replace it with your own customise icon (png format).

Leopard???

so i have followed the instructions but for some reason the "SSHFS" app seems to hang, and never prompts me for the PW... is this due to me running 10.5? i have installed the 10.5 macfuse software and the latest build of the sshfs app... thoughts?

ps i can ssh in just fine i use fugu with no problems, but it just wont seem to mount : (

SSH password for 1.1.4

Does this method work for 1.1.4?

Is there a different password for 1.1.4?

I had my iPhone Jailbroken at 1.1.1, but I then ran into "issues", I restore and just decided to wait for the coders to work out the kinks. So, yeah, I'm up to 1.1.4, and I'd rather not downgrade...

Anyhow, any advice would be great. Thank you.

hey

my iphone in terminal says:

-sh: ssh-: command not found

Iphone 3G SSH Problems

tried alsorts guys got the BSD subsystem on iphone got SSH stuff used the OSX sshfs to no avail cyberduck no avail all passwords correct....dunno what else to do,

im on Leopard so I guess Im not gonna get this goin?

All I want to do is get the movies I shot with Cycorder off.