LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-31-2016, 03:07 AM   #1
sumeet inani
Member
 
Registered: Oct 2008
Posts: 905
Blog Entries: 26

Rep: Reputation: 49
scp using vsftpd


hi ,
i am using 64bit "Ubuntu 16.04.1 LTS"
Installed vsftpd
Actually , i have to transfer file from an embedded device (192.168.1.10) to my PC.
but first , i am trying locally .
Even that didn't work .

/etc/vsftpd.conf
is
Code:
#i want standalone vsftpd
listen=NO
listen_ipv6=YES
anonymous_enable=YES
local_enable=YES
write_enable=YES
local_umask=022
anon_upload_enable=YES
anon_mkdir_write_enable=YES
dirmessage_enable=YES
use_localtime=YES
xferlog_enable=YES
secure_chroot_dir=/var/run/vsftpd/empty
pam_service_name=vsftpd

ssl_enable=YES
allow_anon_ssl=YES
force_local_data_ssl=NO
force_local_logins_ssl=NO
ssl_tlsv1=YES
ssl_sslv2=YES
ssl_sslv3=YES
rsa_cert_file=/etc/vsftpd/vsftpd.pem
anon_umask=022
My computer ip is 192.168.1.4
$ whoami
lxuser
$ cd anotherfolder
$cat filetosend
sumeet
$ scp filetosend lxuser@192.168.1.4:/home/lxuser
ssh: connect to host 192.168.1.4 port 22: Connection refused
lost connection

By the way
Normal ftp works
prateek is filename
Quote:
$ ftp 192.168.1.4
Connected to 192.168.1.4.
220 (vsFTPd 3.0.3)
Name (192.168.1.4:lxuser): lxuser
331 Please specify the password.
Password:
230 Login successful.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> put prateek
local: prateek remote: prateek
200 PORT command successful. Consider using PASV.
150 Ok to send data.
226 Transfer complete.
7 bytes sent in 0.00 secs (162.7604 kB/s)

Last edited by sumeet inani; 12-31-2016 at 03:10 AM.
 
Old 12-31-2016, 05:50 AM   #2
Turbocapitalist
Senior Member
 
Registered: Apr 2005
Distribution: Linux Mint, Devuan, OpenBSD
Posts: 4,454
Blog Entries: 3

Rep: Reputation: 2229Reputation: 2229Reputation: 2229Reputation: 2229Reputation: 2229Reputation: 2229Reputation: 2229Reputation: 2229Reputation: 2229Reputation: 2229Reputation: 2229
scp works over the SSH protocol but it is not using the SFTP protocol. None of the three have anything to do with FTP, the legacy protocol. Specifically, SFTP is a different protocol than FTPS and it looks like you have set up the latter. If you are trying to set up a simple and secure transfer, then I'd recommend removing any trace of vsftp and installing OpenSSH server instead. That will give you SFTP automatically.

If you are really pressed for computing resources on your embedded system then parts of Dropbear, an OpenSSH derivative, can be used instead. Even with Dropbear you'll have SFTP and can avoid the pain and expense of configuring FTPS.
 
Old 01-02-2017, 01:59 AM   #3
sumeet inani
Member
 
Registered: Oct 2008
Posts: 905

Original Poster
Blog Entries: 26

Rep: Reputation: 49
done

installed openssh server & removed vsftpd.
scp simply works .
Looks like scp is not related to ftp in any way .
FTP basic is port 20 for data and 21 for control.
scp uses ssh which runs on port 22.
Thanks.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Shell scp works perfectly, Net::SCP::Expect calls timing out - reasons? EnderX Programming 1 04-27-2013 02:35 AM
Centos 6.3 host+guest: try scp to guest: scp cmd not found. ssh ok chrism01 Linux - Virtualization and Cloud 3 08-24-2012 02:52 AM
Which is safer? Only ssh +scp for 2 users? Or ssh (1 user) + vsftpd (1 virtual user) bvz Linux - Security 2 09-18-2011 09:55 PM
[SOLVED] ssh scp key not working to ssh/scp without password rjo98 Linux - Newbie 9 08-22-2011 05:28 PM
scp does not work and gives the following error message: scp: FATAL: Executing ssh1 i akay Linux - Networking 16 09-29-2008 12:41 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:07 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration