Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision Next revisionBoth sides next revision | ||
| docs:guide-user:services:nas:sftp.server [2023/01/16 12:35] – [SFTP server] update infobox vgaetera | docs:guide-user:services:nas:sftp.server [2023/03/04 11:21] – [Popular clients] stokito | ||
|---|---|---|---|
| Line 3: | Line 3: | ||
| ===== Introduction ===== | ===== Introduction ===== | ||
| - | * This how-to describes the method for setting up SFTP server on OpenWrt. | + | * This how-to describes the method for setting up [[wp> |
| - | * It relies on [[docs: | + | * It relies on [[docs: |
| - | * You can use multiple native SFTP clients such as: | + | * You can use any suitable |
| - | * [[https:// | + | |
| - | * [[https:// | + | |
| - | * [[docs: | + | |
| ===== Goals ===== | ===== Goals ===== | ||
| * Transfer files to/from the router. | * Transfer files to/from the router. | ||
| - | * Follow Dropbear authentication settings. | + | * Secure file transfer operations. |
| - | * Support | + | * Support |
| ===== Instructions ===== | ===== Instructions ===== | ||
| - | Install | + | The SSH File Transfer (SFTP) is a file transfer protocol that works over SSH. It's like SCP but has more features. |
| + | For a basic usage the low level SCP may be enough but if you need, for example, to mount drive then use the SFTP. | ||
| + | |||
| + | The vanilla OpenWrt out of the box has a small [[docs: | ||
| + | But it doesn' | ||
| + | The package comes from another OpenSSH server which is bigger but has more features and default on desktop systems like Ubuntu. | ||
| + | Many [[docs: | ||
| + | So for this routers you really don't need anything to do and just start using it. | ||
| + | |||
| + | But if not then install the required package: | ||
| <code bash> | <code bash> | ||
| - | # Install packages | ||
| opkg update | opkg update | ||
| opkg install openssh-sftp-server | opkg install openssh-sftp-server | ||
| Line 25: | Line 30: | ||
| ===== Testing ===== | ===== Testing ===== | ||
| - | Enter the following | + | Enter the following |
| <code bash> | <code bash> | ||
| - | sftp://192.168.1.1/ | + | sftp://root@openwrt.lan/ |
| + | </ | ||
| + | |||
| + | ===== Troubleshooting ===== | ||
| + | Collect and analyze the following information. | ||
| + | |||
| + | <code bash> | ||
| + | # Restart services | ||
| + | /etc/init.d/log restart; / | ||
| + | |||
| + | # Log and status | ||
| + | logread -e dropbear; netstat -l -n -p | grep -e dropbear | ||
| + | |||
| + | # Runtime configuration | ||
| + | pgrep -f -a dropbear | ||
| + | |||
| + | # Persistent configuration | ||
| + | uci show dropbear | ||
| + | ls -l / | ||
| + | ls -l $(opkg files openssh-sftp-server | grep -e ^/) | ||
| </ | </ | ||
| ===== Extras ===== | ===== Extras ===== | ||
| - | ==== Announce on the network | + | ==== Popular clients ==== |
| - | You may want to announce the service | + | * Windows: [[docs: |
| + | * Windows: [[https:// | ||
| + | * Linux, macOS, FreeBSD: [[https:// | ||
| + | * Linux, macOS, FreeBSD: [[https:// | ||
| + | * Linux: [[wp> | ||
| + | * Linux: [[https:// | ||
| + | * Windows, macOS, Linux, FreeBSD: [[https:// | ||
| + | * macOS: [[https:// | ||
| + | * Android: [[https:// | ||
| + | * Android TV, RapberryPI: [[https:// | ||
| + | * [[https:// | ||
| + | |||
| + | ==== Service discovery | ||
| + | You may want to provide | ||
| <code bash> | <code bash> | ||
| - | # Install packages | ||
| opkg update | opkg update | ||
| opkg install announce | opkg install announce | ||
| </ | </ | ||
| - | ==== OpenSSH compatibility ==== | + | See also [[docs:guide-developer:mdns|umdns Multicast DNS Daemon]] |
| - | Dropbear does not support SFTP by itself. | + | |
| - | Meanwhile OpenSSH client uses SFTP [[https:// | + | |
| - | Use '' | + | |