Stack Overflow for Teams — Collaborate and share knowledge with a private group. Create a free Team What is Teams? Collectives on Stack Overflow. Learn more. Asked 6 years, 1 month ago. Active 4 years, 5 months ago. Viewed 16k times. Kakenx Kakenx 1, 2 2 gold badges 16 16 silver badges 32 32 bronze badges. This rather belongs to Super User. That said, winscp. Add a comment.
Active Oldest Votes. NaN NaN 5, 4 4 gold badges 28 28 silver badges 48 48 bronze badges. The two environments are too far apart. First, we have a file on the remote server called filetodownload. This will give you the folder name, like this:.
Replace the sections in bold with the information you gathered in step 1. For example, the command used for this example is:. Open up a command line in Windows.
Windows 10 already has SCP installed by default. The color contrasts with the yellow, and syntax highlighting is a nice change from the drab command line. As you can see, you first need to confirm the connection using the RSA fingerprint of the remote server.
Replace [UserName] with your own Windows username. The user your specify under scp can reach everything as if you were logged in. If you are needing to sudo or su to get to this file on the remote system, the proper thing to do is copy it to your normal user's home directory, chmod so your normal user owns and can read it, then get it with scp , etc. If the file is very large, chmod the file directly temporarily without making a copy.
Another thing you can try - If you are running your own SSH server at home or wherever, and it's reachable from the remote SSH server you're logged into, you can use scp to send it from your remote session to your local system. The way I would do what you're asking for would be to turn on session logging on your ssh client Ways to do this vary. Depending on the file you might get away with just setting a big scrollback buffer. You can then trim the extraneous bits off of either end of the log and base64 decode it back into your original file.
Some client programs have methods built in for doing pretty much the same thing with, say, the XMODEM protocol or similar, but availability of the transmission software on the server side is probably going to be a lot less than for base64, which is included in most of the Linux distros I've used recently.
If you have a client that supports it though, it takes care of the chopping and decoding phase automatically, which can be convenient for large files. I don't know that anybody's really used it since the days of telnet BBSs though, so good luck. The basic format of the command is as follows:. The biggest kicker is how to format the remote part. When you address a remote file, you need to do it in the following manner:.
This is followed by a colon, then the path to the file or folder in question. This allows me to specify a port number instead of the default Secure copy is great. You can put it in scripts and have it do backups to remote computers.
The problem is that you may not always be around to enter the password.
0コメント