#!/bin/bash FILENAME=$1 DSTDIR=$2 FTPSRV=ip FTPUSER="user" FTPPWD="password" SRCDIR=‘/path/‘ FILE1=$1 /usr/bin/ftp -in $FTPSRV <<! user $FTPUSER $FTPPWD cd $SRCDIR lcd $DSTDIR bin mput ${FILE1} quit ! exit 0
时间: 2024-12-21 16:34:15
#!/bin/bash FILENAME=$1 DSTDIR=$2 FTPSRV=ip FTPUSER="user" FTPPWD="password" SRCDIR=‘/path/‘ FILE1=$1 /usr/bin/ftp -in $FTPSRV <<! user $FTPUSER $FTPPWD cd $SRCDIR lcd $DSTDIR bin mput ${FILE1} quit ! exit 0