Tiny Core Linux

Tiny Core Base => Raspberry Pi => Topic started by: althalus on March 27, 2013, 01:02:42 PM

Title: Problems with SCP and dropbear
Post by: althalus on March 27, 2013, 01:02:42 PM
So I got my Pi yesterday, got Core installed, dropbear set up and running, and starting to play with it. I'm not a fan of the debian import script, it seems to be pulling in all sorts of dependencies that I wouldn't need in TC on my laptop (eg, selinux). So I'm trying to set up my build tools (the tc-ext-tools shell scripts) - but I can't seem to use scp to get anything on or off the pi.

From my laptop:
Code: [Select]
tc@box:~/PROJECTS$ scp tc-ext-tools/ tc@10.1.1.6:

Secure login powered by Dropbear SSH server on piCore.
Enter passphrase for key '/home/tc/.ssh/jls.identity':
sh: scp: not found
lost connection

From the pi:
Code: [Select]
tc@box:~$ scp -r tc@10.1.1.2:PROJECTS/tc-ext-tools ./PROJECTS/
/usr/bin/dbclient: No such file or directory
Title: Re: Problems with SCP and dropbear
Post by: curaga on March 27, 2013, 01:48:22 PM
Just to make sure, it's dropbear.tcz not an imported dropbear?

(I don't have a pi, just clarifying)
Title: Re: Problems with SCP and dropbear
Post by: althalus on March 27, 2013, 04:46:44 PM
Yep, dropbear.tcz.
Title: Re: Problems with SCP and dropbear
Post by: althalus on March 27, 2013, 07:58:10 PM
Actually, if I'd looked closer at the error messages that posted, I could have solved this quicker. Putting symlinks to dropbearmulti in /usr/bin successfuly worked around the problem. Note that I ALSO needed the extra scp symlink in /usr/bin for scp TO the pi to work.

 I think this should qualify as a bug in the dropbear.tcz package?
Title: Re: Problems with SCP and dropbear
Post by: tinypoodle on March 27, 2013, 11:36:47 PM
Note that I ALSO needed the extra scp symlink in /usr/bin for scp TO the pi to work.

 I think this should qualify as a bug in the dropbear.tcz package?
Do you mean on the pi or on the box connected to it?
In latter case, which arch is that?
Title: Re: Problems with SCP and dropbear
Post by: bmarkus on March 28, 2013, 12:18:55 AM

 I think this should qualify as a bug in the dropbear.tcz package?

Thanks for reporting. There is a new version available, will update package.
Title: Re: Problems with SCP and dropbear
Post by: althalus on March 28, 2013, 08:28:45 AM
Note that I ALSO needed the extra scp symlink in /usr/bin for scp TO the pi to work.

 I think this should qualify as a bug in the dropbear.tcz package?
Do you mean on the pi or on the box connected to it?
In latter case, which arch is that?
On the Pi, apologies if that wasn't clear.
Title: Re: Problems with SCP and dropbear
Post by: tinypoodle on March 28, 2013, 09:26:47 AM
The "ALSO" in caps was what confused me...   ::)
An instance of scp is required to run concurrently on both sides (auto invoked on remote machine).
Title: Re: Problems with SCP and dropbear
Post by: althalus on March 28, 2013, 03:13:53 PM
The "ALSO" in caps was what confused me...   ::)
An instance of scp is required to run concurrently on both sides (auto invoked on remote machine).
Yeah, but having scp in /usr/local/bin isn't good enough. What it seems like to me, is that the problem when using scp from the pi has something to do with dropbear itself being hardcoded to expect dbclient in /usr/bin, and the problem of using scp to the pi seems like a path issue, like /usr/local/bin isn't listed in where ever the $PATH variable is set when using scp.

At any rate, I have a workaround, and I've shared my experience so smarter people can fix it :)
Title: Re: Problems with SCP and dropbear
Post by: sbp on March 30, 2013, 02:54:09 AM

 I think this should qualify as a bug in the dropbear.tcz package?

Thanks for reporting. There is a new version available, will update package.

Hi bmarcus

I didn't know that scp was possible using dropbear. When you find the time please update the package.

Steen
Title: Re: Problems with SCP and dropbear
Post by: tinypoodle on March 30, 2013, 03:50:12 AM
I didn't know that scp was possible using dropbear.

Code: [Select]
dropbearmulti
;)
Title: Re: Problems with SCP and dropbear
Post by: paco on April 26, 2013, 12:36:02 AM
Hello all,

after reading this post, I found some websites indicating, that dropbear runs with "sftp-server". There is a "sftp-server.tcz" for x86. Would it be possible to add sftp-server to the RaspPi port?

Thanks,
Patrick

EDIT: I just found that openssh.tcz exists and sftp-server is inside this packet. To use sftp, I just use openssh instead of dropbear.