<?xml version="1.0" encoding="windows-1252"?>
<node id="996395" title="Re^5: Unix 2 Perl Module FTP" created="2012-09-29 11:21:14" updated="2012-09-29 11:21:14">
<type id="11">
note</type>
<author id="155876">
Mr. Muskrat</author>
<data>
<field name="doctext">
&lt;p&gt;You said that user1@FQDN worked from the FTP client but you didn't say that you've tried it from your Net::FTP script. Also, double check that you have the right password in your script.&lt;/p&gt;
&lt;code&gt;#!/usr/bin/perl
use strict;
use warnings;
use Net::FTP;

my $ftp_site     = '9.9.9.9 5000';
my $ftp_dir      = '/Directory2';
my $ftp_get_file = 'that.file';
my $ftp_user     = 'user1@FQDN'; # if 'DOMAIN/user1' and 'DOMAIN\\user1' don't work, perhaps this will
my $ftp_password = 'password321'; # double check your password, maybe it's the problem!

my $ftp = Net::FTP-&gt;new($ftp_site)
   or die "Could not connect to $ftp_site: $@";

$ftp-&gt;login($ftp_user, $ftp_password)
   or die "Could not login to $ftp_site with user $ftp_user: ", $ftp-&gt;message;

$ftp-&gt;cwd($ftp_dir)
   or die "Could not change remote working directory to $ftp_dir on $ftp_site: ", $ftp-&gt;message;

$ftp-&gt;get($ftp_get_file)
   or die "Could not get $ftp_get_file the file is not present in $ftp_dir: ", $ftp-&gt;message;

$ftp-&gt;quit();
&lt;/code&gt;</field>
<field name="root_node">
996264</field>
<field name="parent_node">
996296</field>
</data>
</node>
