Error when trying to setup ssh synchronizer with setup wizard

421 views
Skip to first unread message

Markus

unread,
Jan 19, 2014, 10:52:49 AM1/19/14
to mobileor...@googlegroups.com
Hi,

I can't get a connection with the ssh synchronizer. I get an error message when I run the setup wizard:
'Login failed: Failed to find index file with error: java.io.IOException: 2: No such file'

All necessary org files have been created by emacs (index.org, agendas.org, checksums.org, mobileorg.org, and my notes.org).
Emacs and the MobileOrg files are on the same Debian Linux machine.
I have played with the location of the files and file permissions without success.
Basically, ssh connection from mobile phone to the Linux machine is working with a ssh client (so, no problem with credentials or port).
Both devices are on the same LAN.
Tested with Android 2.3.4 on a Motorola Atrix and Android 4.3 on a Samsung Galaxy S3, both with MobileOrg version 0.9.13. I always get this error message.
Don't know what to do anymore.
Any suggestions?

Matthew Jones

unread,
Jan 19, 2014, 1:27:55 PM1/19/14
to mobileorg-android on behalf of Markus
how are you entering the path into the program?  Are you giving it the path to the index file or the path to the directory containing the index file?


--
You received this message because you are subscribed to the Google Groups "mobileorg-android" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mobileorg-andr...@googlegroups.com.
To post to this group, send email to mobileor...@googlegroups.com.
Visit this group at http://groups.google.com/group/mobileorg-android.
For more options, visit https://groups.google.com/groups/opt_out.

Markus

unread,
Jan 19, 2014, 2:46:28 PM1/19/14
to mobileor...@googlegroups.com
I'm entering the entire path to the index file (including index.org at the end).

Matthew Jones

unread,
Jan 19, 2014, 2:53:17 PM1/19/14
to mobileorg-android on behalf of Markus
have you tried just giving it the path to the directory containing the index file?  It's been a while since I've looked at this.


On Sun, Jan 19, 2014 at 2:46 PM, Markus via mobileorg-android <mobileorg-android+noreply-APn2wQ...@googlegroups.com> wrote:
I'm entering the entire path to the index file (including index.org at the end).

--

Markus

unread,
Jan 19, 2014, 3:42:27 PM1/19/14
to mobileor...@googlegroups.com
Yes, I've tried all this. With and without the file name as well as with and without leading slash.
When I try it without the file name, it gives an error message that the entry must point to index.org.
I even have changed the location of the files, e.g. into the ssh root directory.

Matthew Jones

unread,
Jan 19, 2014, 4:09:23 PM1/19/14
to mobileorg-android on behalf of Henning Weiss

This is pretty strange as this works well for me and a lot of others are you go of the full path to the file?

--

Markus

unread,
Jan 20, 2014, 7:30:33 AM1/20/14
to mobileor...@googlegroups.com
Yes, I enter the full path to the file. This is:

/org/MobileOrg/index.org

Markus

unread,
Jan 26, 2014, 7:50:36 AM1/26/14
to mobileor...@googlegroups.com
Hi,

I've solved the problem.
It's all about ssh configuration. MobileOrg ssh synchronizer will not work with the Debian default ssh configuration.


The subsystem for sftp must be changed in /etc/ssh/sshd_config from '/usr/lib/openssh/sftp-server' to 'internal-sftp'.
The following section at the bottom of sshd_config must be entered in case the MobileOrg files are located in the home directory tree of a user:

Match Group users
      ChrootDirectory /home/%u
      ForceCommand internal-sftp


Besides, the file system persmissions must be changed. From ssh root directory (depending on ssh config), all the way up
in the directory structure to the file systems root ('/') must be owned by user root.



Markus

npatr...@gmail.com

unread,
Feb 5, 2014, 11:54:27 PM2/5/14
to mobileor...@googlegroups.com
I'm having similar issues. I have been using ssh successfully for months and it just stopped working. I've tried making the internal-sftp change, moving it from a home directory to a root owned /org/mobile directory. Either way, it comes back with auth failed.

Do you have any other suggestions?

Markus

unread,
Feb 7, 2014, 1:26:32 PM2/7/14
to mobileor...@googlegroups.com
This ssh stuff is very strict on directory/file permissions.
Finally I have made a step-by-step approach. Independent of org/MobileOrg, I first tried to establish a connnection with a ssh client
on the Android device, where the ssh root directory points to the MobileOrg directory (configured in /etc/ssh/sshd_config).
I always had a tail on /var/log/auth.log.
Now, I have chown'ed all the files in MobileOrg directory to root and group to users. The group must have r/w permission.
The directories all the way up to file system root needs to be owned by root.
The rest is configuration of org and MobileOrg.

Did you changed any files or permissions? Did you make an OS update? Maybe sshd_config has been overwritten during update!
Check sshd_config for duplicate sftp subsystem entries. Only the first one is valid.

Markus
Reply all
Reply to author
Forward
0 new messages