Page 1 of 1

Assistance with FTP from centos to W2K3 machine

Posted: 2012/02/21 00:49:38
by RodPerez_GTA
Hello all,
I am new to this forum and this is my first post. I need some assistance on uploading a *.gz file via ftp to a W2K3 machine. Here are the info:

-Currently using CentOS 5.5 Final
-W2K3 machine set to allow anonymous log on via FTP

Here is the script

#!/bin/sh
#MySQL Backup Script
#Full Backup

### FTP server Setup ###
FTPD="some_directory"
FTPU="anonymous"
FTPP="some_email"
FTPS="some_IP"

# delete any existing backups
rm -f /some_location/db*.gz

#make a new backup file
mysqldump --user=some_username--password=some_password --all-databases | gzip > /some_location/db-`date +%Y-%m-%d`.gz

# local directory to pickup *.gz file
FILE="/some_location/"

# login to remote server
cd $FILE
ftp -n -i $FTPS <<EOF
user $FTPU $FTPP
cd $FTPD
mput *.gz
quit

EOF
######

I would get the following error:
'AUTH GSSAPI': command not understood
'AUTH KERBEROS_V4': command not understood
KERBEROS_V4 rejected as an authentication type

Here is the log from the W2K3 box:
USER anonymous 331 0
PASS some_email 230 0
CWD /some_location 250 0
created /some_location/db-2012-02-21.gz 226 0
QUIT - 226 0

Assistance with this issue would be greatly appreciated.

Thanks,
Rod P.

Assistance with FTP from centos to W2K3 machine

Posted: 2012/02/21 15:34:37
by pschaff
Welcome to the CentOS fora. Please see the recommended reading for new users linked in my signature.

[quote]
RodPerez_GTA wrote:
...
CWD /some_location 250 0
created /some_location/db-2012-02-21.gz 226 0
[/quote]
Looks like it worked. What's the problem? The messages can be safely ignored as long as the login ultimately succeeded.

Re: Assistance with FTP from centos to W2K3 machine

Posted: 2012/02/21 23:25:48
by RodPerez_GTA
Forgot to mention that the *.gz file is corrupt when i open it from the file server. The data is incomplete. I checked the original *.gz on the centos box and there is more data than what is in the w2k3 box.

I found a workaround to it and just installed winSCP in the w2k3 box and automated the process. But if anyone has ever had this issue and resolved it, can you post your resolution.

Thanks

Re: Assistance with FTP from centos to W2K3 machine

Posted: 2012/02/22 01:34:55
by TrevorH
Try a different ftp client? lftp might work. Or use smbclient

[code]
/usr/bin/smbclient -U username //ip.add.re.ss/Directory password -c "put $NOW.csv.gz"
[/code]

Re: Assistance with FTP from centos to W2K3 machine

Posted: 2012/02/22 02:34:29
by RodPerez_GTA
thanks i will give it a try.