安装winscp软件,地址:https://winscp.net//.exe新建连接,输入linux服务器的IP地址、端口号、用户名和密码,点击登录
1、安装winscp软件,地址:https://winscp.net/download/winscp575.exe
2、新建连接,输入linux服务器的IP地址、端口号、用户名和密码,点击登录
3、在登录界面选择SFTP协议,点击登录
4、登录成功后,可以在左侧的文件列表中查看服务器上的文件,右侧的文件列表中查看本地电脑上的文件
代码如下:
#!/usr/bin/env bash
# Connect to a Linux server using WinSCP
# Set the hostname
HOST="example.com"
# Set the username
USER="username"
# Set the password
PASS="password"
# Set the port
PORT="22"
# Connect to the server
winscp.exe -hostkey="ssh-rsa 2048 xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx" -hostname=$HOST -username=$USER -password=$PASS -port=$PORT
本站系公益性非盈利分享网址,本文来自用户投稿,不代表码文网立场,如若转载,请注明出处
评论列表(72条)