Solved

Copy a file from laptop to UNIX using putty?

Posted on 2013-05-24
8
759 Views
Last Modified: 2013-05-31
I would like a copy a file from my local windows machine to a remote unix server using putty.

How can I do this?
0
Comment
Question by:sventhan
8 Comments
 
LVL 68

Accepted Solution

by:
woolmilkporc earned 250 total points
ID: 39195305
There is a utility "pscp" (= an SCP client for PuTTY).

It is part of the PuTTY suite and can use PuTTY's stored session profiles for connecting.

Get it from here:

http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html

Here are the docs:

http://the.earth.li/~sgtatham/putty/0.62/htmldoc/Chapter5.html#pscp
0
 
LVL 18

Author Comment

by:sventhan
ID: 39195336
I tried and I've got the following Error.
Fatal: Network error: Connection refused



I can only connect to this server using putty on telnet, port 23.  I could not able to get this done using WinScp or FileZilla.

thanks,
Sve
0
 
LVL 68

Assisted Solution

by:woolmilkporc
woolmilkporc earned 250 total points
ID: 39195385
So you're using PuTTY as a telnet client instead of as an ssh client.

If port 23 is indeed the only port which is available to you then you're basically lost - the telnet server listening to that port is not meant for providing file transfer capabilities.

Aren't there indeed any other ports available? FTP? RCP? I must say I didn't see many servers holding the insecure telnet port open while leaving the secure ssh in the cold.

It might be that some legacy terminal software like xmodem or zmodem can do the trick - need to find a Windows version though.

curl can use telnet - but I never installed it on Windows, yet there are binaries for that platform.
Try it if you like:

http://curl.haxx.se/download.html
0
 
LVL 4

Expert Comment

by:EddyvanOpdorp
ID: 39195557
If you can use ssh (and you can because you use putt) then is the easiest way to use winscp.
You can download this tool here:
http://winscp.net/eng/download.php
0
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 
LVL 27

Expert Comment

by:serialband
ID: 39195771
Are you sure that you are using the ssh protocol and not just using telnet?  Did you change the sshd port to 23 on the server.  That's actually not recommended.  You should use a port above 1024 if you're going to change the default port.
0
 
LVL 40

Assisted Solution

by:omarfarid
omarfarid earned 125 total points
ID: 39195962
The connection refused you go is either because sshd is not running on the remote system, or there is a firewall terminating / denying your connection, or miss translating (IP NATing) of remote system IP.

you can try to see if sshd is running or not by logging to the remote system (with telnet, for example) and then run below command

ssh 0

if you get the same message then sshd is not running and you need to run it as user root.

if you are getting login prompt then it could be of firewall blocking your ip address, or a mistranslation of IP address. The later can be checked by trying to ssh from a local system on the same network of the remote system.
0
 
LVL 19

Assisted Solution

by:simon3270
simon3270 earned 125 total points
ID: 39198066
If it is a text file, one option would be to log in to the remote machine, enter the command
   cat > required_file
Then open the local file in, for example, wordpad, select all text (Ctrl-A) and and "copy" the text to tthe clipboard (Ctrl-C).  Then paste the text into the Putty window (try right-clicking the mouse) and press Ctrl-D in the putty session to stop writing to the output file..  This will work for text files of a few tens of lines at least - you may be lucky and get it to work for longer files.

If the file is a binary one, use uuencode on the Windows machine to convert it to a text repersentation, copy that text to the unix machine as above, then uudecode on the UNIX machine to convert it back to binary.
0
 

Expert Comment

by:dougone
ID: 39209183
i would install filezilla server on the laptop..and ftp to the laptop from unix.. from command ftp x.x.x.x user password that you set up on the filezilla server and that should work
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Using 'screen' for session sharing, The Simple Edition Step 1: user starts session with command: screen Step 2: other user (logged in with same user account) connects with command: screen -x Done. Both users are connected to the same CLI sessio…
FreeBSD on EC2 FreeBSD (https://www.freebsd.org) is a robust Unix-like operating system that has been around for many years. FreeBSD is available on Amazon EC2 through Amazon Machine Images (AMIs) provided by FreeBSD developer and security office…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now