macfusion-ng / macfusion2

Macfusion2
225 stars 28 forks source link

10.8 #4

Closed bruman closed 11 years ago

bruman commented 11 years ago

I just upgraded 10 10.8.2 from 10.6 and I am having issues getting mac macfusion to work

I have tried a bunch of stuff, installed osxfuse, install sshfs from osxfuse, and upgrading to your version of macfusion (Version 2.0.5-dev (7e9052e)

I am getting

(SSHServerFS, tmp, 12/30/12 10:29 PM) Mounting
(MFClient, tmp, 12/30/12 10:29 PM) Note status changed for fs <MFClientFS: 0x40079a4c0> (tmp) to Waiting to Mount
(SSHServerFS, tmp, 12/30/12 10:29 PM) Task launched OK
(SSHServerFS, tmp, 12/30/12 10:29 PM) debug1: Reading configuration data /etc/ssh_config
(SSHServerFS, tmp, 12/30/12 10:29 PM) debug1: /etc/ssh_config line 20: Applying options for *
debug1: Connecting to 10.X.X.X [10.X.X.X] port 22.
debug1: Connection established.
debug1: identity file /Users/xxx/.ssh/id_rsa type -1
debug1: identity file /Users/xxx/.ssh/id_rsa-cert type -1
debug1: identity file /Users/xxx/.ssh/id_dsa type -1
debug1: identity file /Users/xxx/.ssh/id_dsa-cert type -1
debug1: Remote protocol version 2.0, remote software version OpenSSH_5.3p1 Debian-3ubuntu7
debug1: match: OpenSSH_5.3p1 Debian-3ubuntu7 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_5.9
(SSHServerFS, tmp, 12/30/12 10:29 PM) debug1: SSH2_MSG_KEXINIT sent
(SSHServerFS, tmp, 12/30/12 10:29 PM) debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-ctr hmac-md5 none
debug1: kex: client->server aes128-ctr hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
(SSHServerFS, tmp, 12/30/12 10:29 PM) debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
(SSHServerFS, tmp, 12/30/12 10:29 PM) debug1: Server host key: RSA 58:95:c0:1e:5a:ac:94:a9:90:1b:b3:d3:6d:83:ab:c9
debug1: Host '10.X.X.X' is known and matches the RSA host key.
debug1: Found key in /Users/xxx/.ssh/known_hosts:5
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: Roaming not allowed by server
debug1: SSH2_MSG_SERVICE_REQUEST sent
(SSHServerFS, tmp, 12/30/12 10:29 PM) debug1: SSH2_MSG_SERVICE_ACCEPT received
(SSHServerFS, tmp, 12/30/12 10:29 PM) debug1: Authentications that can continue: publickey,password
debug1: Next authentication method: publickey
debug1: Trying private key: /Users/xxx/.ssh/id_rsa
debug1: Trying private key: /Users/xxx/.ssh/id_dsa
debug1: Next authentication method: password
debug1: read_passphrase: can't open /dev/tty: Device not configured
debug1: Authentications that can continue: publickey,password
debug1: No more authentication methods to try.
Permission denied (publickey,password).
remote host has disconnected
(MFClient, tmp, 12/30/12 10:29 PM) Note status changed for fs <MFClientFS: 0x40079a4c0> (tmp) to Failed to Mount

From the command line

wibble:Resources xxx$ /usr/local/bin/sshfs xxx@10.X.X.X:/mnt /tmp/ssh/ -ocache=no -onolocalcaches -ovolname=ssh
xxx@10.X.X.X's password: 

Works

wibble:Resources xxx$ ./sshfs-static  xxx@10.X.X.X:/mnt /tmp/ssh/ -ocache=no -onolocalcaches -ovolname=ssh
sshfs: cannot find sshnodelay.so
warning: ssh nodelay workaround disabled
xxx@10.X.X.X's password: 

Also works, but with the error.

I have seen a bunch of posts about issues with 10.8.2. So my first question is, Does it work on 10.8.2

My second is any suggestions?

ElDeveloper commented 11 years ago

To answer your question: I have not been able to personally test it in OS X 10.8 though I know other users have reported it works just fine.

I'm not sure about this bug, the only times I see something similar to this is when a connection cannot be completed within the given window of time (by default is now 15 s). A suggestion might be increasing the timeout to something like 50 s. Doing this has done the trick for me in the past. I've been trying to catch this bug for quite a while now but haven't been successful.

The general solution that I've seen for this is to use public keys (of course if you have the option to do so), this tutorial seems to be very direct, though if you search in google you might find a better/simpler tutorial.


A side-note on this is that you should only require OSX FUSE with the FUSE compatibility layer to have a functional version of the software. I don't really think this might be the root of the problem but nonetheless it is worth mentioning it.

ElDeveloper commented 11 years ago

I recently updated my machine to 10.8 and found this exact same problem. After some usage of the OS, some other programs were also malfunctioning so I realized this had to be 10.8 and a big change that Apple made to the OS that removed a dependency etc. While working on other things and still having this problem in mind, it was brought to my attention that Apple removed X11 from the OS installation. Some of the functionality for the underlying infrastructure that's built around OpenSSH has dependencies in X11.

The specific details are that the mechanism that Macfusion uses to open a connection is making a system call to sshfs which in turns makes usage of OpenSSH to create the connection and find an authentication method. The first thing it tries to do is to read a publickey, if there is not a public key it then tries to read a password. The trick here is that if there is an environment variable SSH_ASKPASS, this variable should point to a program that will print the password to standard output, then OpenSSH will read this password and if authorized the connection will begin all this happens in a non-interactive session and in the background.

The solution is to install XQuartz. Note that you will need admin privileges so either ask your admin to install this system wide or do it yourself. Cool thing about this is that Apple supports the development of this project, so it does not seem like the type of project that is going to die for lack of development.

I've updated the README.md file to reflect that this is now a dependency, see 7b587d9.

For more information about the SSH authentication methods etc, please see this link.


tl;dr

X11 is too mainstream so Apple removed it from the OS installation; you have to manually install XQuartz to fix this problem.