Possible to FTP to DietPi and get to /mnt?

sftp is a different story, for that there is indeed a separate openssh-sftp-server.
But scp works by default on the default dropbear for as long as I can remember from OpenWrt forum questions.

still, for me the OpenSSH client is needed as the SCP executable is required. And this is missing if I uninstall OpenSSH Client

this is the debug log from WinSCP

! 2021-03-18 17:08:34.265 -bash: line 37: /usr/bin/scp: No such file or directory
< 2021-03-18 17:08:34.265 WinSCP: this is end-of-file:127
* 2021-03-18 17:08:34.265 (ECommand) **Copying files from remote side failed.**
* 2021-03-18 17:08:34.265 Cannot execute SCP to start transfer. Please make sure that SCP is installed on the server and path to it is included in PATH. You may also try SFTP instead of SCP.
* 2021-03-18 17:08:34.265 Command failed with return code 127.

And /usr/bin/scp is part of OpenSSH client only

https://packages.debian.org/search?mode=path&suite=buster&section=all&arch=any&searchon=contents&keywords=%2Fusr%2Fbin%2Fscp

If that is the case, the openssh-client is installed by default. I do not have the openssh-client installed in dietpi software, SCP however works fine for me.

easy to check :wink:

dpkg -l openssh-client

But in general it is enough to have /usr/bin/scp available

Yes, there it is installed.

ii  openssh-client 1:7.9p1-10+deb10u2 armhf        secure shell (SSH) client, for secure access to remote machines

However I never installed the OpenSSH Client and the system runs with Pihole installed only.

So it most likely came preinstalled in the image and worked out of the box.

trendy can you check install state for OpenSSH client

cat /boot/dietpi/.installed | grep -F [0]

It’s definitely not pre-installed, but good to know that all is as expected. So for Dropbear SCP support there is still an scp executable required, while SFTP can be covered with the linked alternative one.

MichaIng
personally I have seen that a couple of times where OpenSSH client was installed during initial setup even if not selected. But I would need to run some test to find the pattern

That would be interesting indeed. On image updates I do at least one full first run setup as well and didn’t recognise this so far. I cannot imagine a kernel package or so pulling OpenSSH as dependency :thinking:.

nope it was on my list for a while to report to you, as it was installed by first run as pre-selected package. But give me some time to verify.

Yeah, sure it is not selected.

dietpi@kakadu:[~]$ cat /boot/dietpi/.installed | grep -F [0]
aSOFTWARE_INSTALL_STATE[0]=0

What device/image you are running

DietPi v7.0.2 (beta) : 13:26 - Παρ 19/03/2021
 ─────────────────────────────────────────────────────
 - Device model : RPi B (armv6l)

The beta must have been a leftover. I switched back to main after the testing period finished.

Maybe package got installed along with others? We never will find out probably. Running dietpi-update -1 should reinstall master branch

I do not have any system to test currently. If you, however, happen to do some testing for something else, please check if it is there on a freshly installed system. If it is not, try again installing pihole. I cannot think of anything else.

Pi-hole does not pull it as dependency. To check whether it’s a dependency of any other installed package, you could simply try to remove it. On confirmation prompt it would show you if/which dependants would be removed together with it: apt remove openssh-client

I did some testing and found out that on one system with dropbear as server, the openssh-client is pulled when sftp-server is installed, which most likely is what could have triggered the installation.
For the other system, in case you switch the ssh server from dropbear to openssh, both client and server are installed. Weirdly, removal of sftp-server asks to remove server too, and removal of client asks to remove both server and sftp as well.
Pretty strange and it doesn’t seem to work as I have expected.

Ah that makes all sense. These are the package dependencies:
openssh-server > openssh-sftp-server + openssh-client
openssh-sftp-server > openssh-client

Here an alternative SFTP server that does not pull the OpenSSH dependency: https://packages.debian.org/buster/gesftpserver
But it’s SFTP only, no SCP.