2

I have an Asus DSL-AC68U router. I can easily ssh to it:

ssh router

After having configured the proper options in .ssh/config:

Host router
Hostname ddnshostname
User myuser
KexAlgorithms +diffie-hellman-group1-sha1

In short, I already can access the router via SSH and FTP but I'd like the security and ease of use of SSHFS (or similar!). However, I seem not to be able to mount stuff with SSHFS:

$ sshfs -o sshfs_debug router:/tmp/home/root/ testmount/ -d         [1]
SSHFS version 2.6
FUSE library version: 2.9.5
nullpath_ok: 0
nopath: 0
utime_omit_ok: 0
executing <ssh> <-x> <-a> <-oClearAllForwardings=yes> <-2> <casatrieste> <-s> <sftp>
sh: /opt/libexec/sftp-server: not found
remote host has disconnected

I found out this is because sftp-server in my router seems to be displaced or missing. However, I cannot find neither sftp_server nor ssh_config anywhere in the router using find / | grep ssh_config. It seems like I'm missing the sftp-server package completely. Is there any other way to allow me to use SSHFS? I can already access the router via ftp, but I'd like to mount the file system remotely.

I should probably install openssh-sftp-server. However this means I should install optware and I'd prefer to avoid that.

How can I mount SSHFS folders from this router remotely?

1
  • alternatives to consider: use rsync to fetch a copy of the remote, edit it locally, then rsync it back. Or use an editor like emacs which has a tramp mode which lets you edit/browse files remotely pretty transparently. Commented Mar 18, 2016 at 17:10

3 Answers 3

2

I had a similar question and solved it by installing Entware:

To install Optware on your RT-AC68U in three simple steps:

  • Mount the ext4 formatted disk;
  • Go to router’s web interface (router.asus.com) -> USB Application and install Download Master;
  • Once successfully installed, uninstall it (not disable). The Optware package will remain installed, but just the Download Master will be removed.

Uninstall the Download Master because it is incompatible with transmission for Optware, a better alternative for the torrent client.

OPTWARE install per http://dsl-n55u.wikidot.com/optware

  1. Wipe the USB stick & format it with a fresh Ext2 partition
  2. Visit the web management pages (http://router.asus.com/APP_Installation.asp), choose an application like "Media Server" and press the "Install" link
  3. Choose the USB disc to install on (likely "sda", or the label if you added one when formatting) and the ASUS code whirls for a few minutes downloading stuff - let it.
  4. Once finished, if you don't actually want to use the ASUS application "Uninstall" or "Disable" it - this will leave Optware initialised on the USB stick anyway.

After installing Optware, install SSH server:

ipkg install openssh-sftp-server

sshfs is now possible

3
  • Unfortunately I'm not aware of any third party firmware which supports the DSL-AC68U. Commented Feb 15, 2019 at 11:46
  • Avoid installing 3rd party firmware: can you install Optware as described in the link in your original post? If yes then install the openssh-sftp-server package as demonstrated above. I tested the server with sshfs from Ubuntu and the results were excellent. Please post when you are successful too :) Commented Feb 15, 2019 at 12:58
  • Of course you are entirely correct, sorry for dismissing your answer that fast in my previous comment. I can do what you said and it kinda works. I say kinda because on my router the usb3 shielding is not excellent, so there is some interference with 5GHz wifi that make this setup less than ideal (basically, speeds are more or less those of USB2). Nevertheless, this is by far the best answer, thanks. Commented Feb 18, 2019 at 12:10
1

SSHFS is using SFTP. If the server does not support SFTP, it won't work.

You need to install the sftp-server on router and configure it if you want to use it SFTP/SSHFS. Period. What is the question?

3
  • That's what I gathered. The question is if what I understood is correct (it seems so) and if there is any way around the issue other than installing optware which I fear may void my warranty. Or, alternatively, if there is any other equivalent solution other than SSHFS. Commented Mar 18, 2016 at 10:06
  • You might be able to make NFS working, if it is supported by the router.. Commented Mar 18, 2016 at 10:42
  • I don't think it is unfortunately, or I'd be very happy indeed, I love NFS. It is supported by the Merlin firmware which however does not seem to support my router. Commented Mar 18, 2016 at 11:02
1

You can use scp directly anywhere there is ssh:

https://en.wikipedia.org/wiki/Secure_copy

There is nothing to mount. There are also tools that use scp to provide a directory-oriented view. I use WinSCP off Windows, because it understands PuTTy credentials.

1
  • Yes, I can do that (I use the standard KDE file manager, Dolphin, which can browse remotely with SSH using the fish:// KIO slave), but that's not what I wanted to do... which I now believe is impossible on my router anyway. Commented Feb 22, 2018 at 14:18

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.