- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- << UNMATCHED error with << FTPEOF VERY URGENT!!
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-27-2002 03:31 AM
тАО09-27-2002 03:31 AM
I keep getting this error:
2) Check connection FTP server
xx.xxx.xx.xx is alive
./ftp.sh[51]: syntax error at line 55 : `<<' unmatched
What the f#ck is wrong with this?
I copied this from another script wich runs every night, so this should work fine. Why do I get the error?!?!!?!?!? Is it because of the gremlins in my computer?
ftp -nv $2 << FTPEOF # > /tmp/temp_log.$$
user $3 $4
cd $5 #Switch to directory
get $1 #Get file
Sander
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-27-2002 03:42 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-27-2002 03:44 AM
тАО09-27-2002 03:44 AM
Re: << UNMATCHED error with << FTPEOF VERY URGENT!!
You need to at the end
bye
EOF
No need for the language mate
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-27-2002 03:46 AM
тАО09-27-2002 03:46 AM
Re: << UNMATCHED error with << FTPEOF VERY URGENT!!
ftp -inv << EOF
open
user
binary
cd /home/
get .profile
bye
EOF
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-27-2002 03:48 AM
тАО09-27-2002 03:48 AM
Re: << UNMATCHED error with << FTPEOF VERY URGENT!!
Rgds, Robin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-27-2002 03:49 AM
тАО09-27-2002 03:49 AM
Re: << UNMATCHED error with << FTPEOF VERY URGENT!!
thnx for the reply.
Sorry to say but i've got an EOF!
ftp -nv $2 << FTPEOF # > /tmp/temp_log.$$
user $3 $4
cd $5 #Switch to directory
get $1 #Get file
FTPEOF #End spool
So what else can be the problem?
Sander
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-27-2002 04:00 AM
тАО09-27-2002 04:00 AM
Re: << UNMATCHED error with << FTPEOF VERY URGENT!!
bye
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-27-2002 04:01 AM
тАО09-27-2002 04:01 AM
Re: << UNMATCHED error with << FTPEOF VERY URGENT!!
I've taken out 1 < before FTPEOF (line no 50 approx.)
In the result you see a line
3) Conection succesfull
I didn't get that when I had <
Here's the entire script:
#-------------
# CONSTANTS
#------------
FILE=$1
SERVER=$2
USERNAME=$3
PASSWORD=$4
FTP_DIR=$5
EMAILADRES=$6 #"sander.derix@office.xerox.com"
#-------------
# LOG
#-------------
LOG=/tmp/$1.log
MSG=/tmp/$1.msg
echo "File transfer $1 to QAD failed" > $MSG
#----------------------------------------------------
echo "1) Checking for an Existing Input File"
cd /tmp
echo "1) Checking for an Existing Input File"
cd /tmp
cp $FILE $FILE-01
echo "2) Check connection FTP server"
#----------------------------------------------------
/usr/sbin/ping ${SERVER} >$LOG
grep -i "alive" $LOG
i=$?
if [ "$i" = "0" ] ; then
echo "3) Conection succesfull"
ftp -inv $SERVER < FTPEOF
user $3 $4
cd $5 #Switch to directory
get $1 #Get file
>> FTPEOF #End spool
if test $? = 0 ; then
cat /tmp/temp_log.$$ >>$MSG
echo ====
echo "FTP of $1 completed successfully."
echo ====
"ftp.sh" 85 lines, 3254 characters
(opbdev1:cpiddvl) /u/appl/sderix/test-> ./ftp.sh
./ftp.sh: !/bin/ksh: not found
1) Checking for an Existing Input File
2) Check connection FTP server
xx.xxx.xx.xx is alive
3) Conection succesfull
./ftp.sh[54]: FTPEOF: cannot open
./ftp.sh[55]: user: cannot execute
./ftp.sh[56]: /dg03/ftp_get: not found
ERROR [
cat: cannot open /tmp/temp_log.5928
====
FTP of mf680sfr.dat completed successfully.
====
./ftp.sh[65]: /tmp/mf680sfr.dat.msg: cannot execute
mailnote sent to
The flags you gave are used only when sending mail.
Usage: mailx -eiIUdFntBNHvV~ -T FILE -u USER -h hops -r address
-s SUBJECT -f FILE users
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-27-2002 04:02 AM
тАО09-27-2002 04:02 AM
Re: << UNMATCHED error with << FTPEOF VERY URGENT!!
I do not think that it is allowed to have anything but that EOF string on the line - not even a comment.
regards,
John K.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-27-2002 04:08 AM
тАО09-27-2002 04:08 AM
Re: << UNMATCHED error with << FTPEOF VERY URGENT!!
You shouldn't have taken out the "<", that's why you're getting the new errors.
Take out the ">> " before the FTPEOF, and make sure the FTPEOF line is on it's own, starting at column 1.
Rgds, Robin.