- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- ftp removes trailing white space
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
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
тАО07-02-2003 12:04 PM
тАО07-02-2003 12:04 PM
ftp removes trailing white space
Thanks,
Jim Krol
james.krol@boeing.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-02-2003 12:09 PM
тАО07-02-2003 12:09 PM
Re: ftp removes trailing white space
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-02-2003 12:10 PM
тАО07-02-2003 12:10 PM
Re: ftp removes trailing white space
And uncompress in hp-ux?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-02-2003 12:14 PM
тАО07-02-2003 12:14 PM
Re: ftp removes trailing white space
If you need this record to match, you have 2 choices.
1. rename the files via script, batch, interactive.
2. change the whitespace to underscores or hyphens.
Sincerely,
Shannon
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-02-2003 12:17 PM
тАО07-02-2003 12:17 PM
Re: ftp removes trailing white space
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-02-2003 12:55 PM
тАО07-02-2003 12:55 PM
Re: ftp removes trailing white space
In ASCII, the mainframe reads the record, then sends that record to the client (HP-UX) and ftpd then adds the EOL character at the end of the mainframe's definition of the record. And therein lies the problem. ftp doesn't know anything about trailing spaces so the file was probably 'adjusted' at the mainframe.
If BINARY does not produce the right file image in ftp then transfer the file in ASCII and convert the file to fixed record length using dd and cbs=80 conv=block,sync options. Or you can use sed to extend the record length. Unix does not make file conversion very easy.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-02-2003 12:59 PM
тАО07-02-2003 12:59 PM
Re: ftp removes trailing white space
ftp hpserver.com
username
password
bin
quote type e
put mainframe.dataset hp.dataset
quit
Here's a REXX macro you can use to convert EBCDIC to ASCII on the mainframe and then you
can send the file:
EDIT MACRO TO CONVERT TO ASCII
/* REXX */
/* */
/* This edit macro is designed to convert EBCDIC data to ASCII */
/* */
ADDRESS ISREDIT
'MACRO'
'(start) = LINENUM .ZF'
'(endit) = LINENUM .ZL'
DO point=start UNTIL point>=endit
'(line) = LINE' point
address linkmvs "C2ASCII line"
'LINE' point '= (line)'
END
"LOCATE 1"
EXIT 1
And the supporting assembler routine C2ASCII
The following routine requires no special linkage but it will need to be available in the TSO STEPLIB concatenation.
******************************************************************
* C2ASCII: CONVERT DATA TO ASCII
******************************************************************
C2ASCII AMODE 31
C2ASCII RMODE ANY
C2ASCII CSECT
BAKR 14,??
LR 12,15
USING C2ASCII,12
L 1,??(1)
LH 5,??(1) * GET THE LENGTH OF THE PARAMETER
LA 4,2(1)
XLATE (4),(5),TO=A
PR
END
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-02-2003 03:53 PM
тАО07-02-2003 03:53 PM
Re: ftp removes trailing white space
Interesting that this came up today. I just encountered a problem on our latest version of TCPIP for VSE similar to what you describe.
For your instance, our shop routinely pads records with spaces (40) and we got away from the problem you state.
Best regards,
DL
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-03-2003 07:13 AM
тАО07-03-2003 07:13 AM
Re: ftp removes trailing white space
Thanks to all,
Jim Krol
james.krol@boeing.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-03-2003 07:37 AM
тАО07-03-2003 07:37 AM
Re: ftp removes trailing white space
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-03-2003 10:34 AM
тАО07-03-2003 10:34 AM
Re: ftp removes trailing white space
I've encountered this problem any number of times when transferring files between heterogenous systems. The solution that has always worked infallibly is to append a character to the end of the record at the sending end and strip it off on the receiving end. Piece of cake to add it and strip it off with utilities on most systems.