• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 546
  • Last Modified:

wanted ZIP tool for OS/400 PF (not IFS)

Looking for a ZIP tool (low cost) to compress large phyisical files.
0
asdf13
Asked:
asdf13
  • 6
  • 5
  • 2
  • +1
3 Solutions
 
Gary PattersonVP Technology / Senior Consultant Commented:
Can you explain your need in a little more detail?  For example, the as400 os has built in support for a compresses archive called a save file.

You use the Crtsavf command to create a save file, and then use normal SAV* commands, specifying a target device of *SAVF, and specifying the Dtacpr(*high) option.

There are zip-compatible tools for the as400, but they produce ifs files as output, because the zip protocol is a stream file protocol, and is not aware of the structure of as400 database files.
- Gary Patterson.
0
 
asdf13Author Commented:
Hello Gary,
thanks for your explanations so far.
My intention is,  to zip pf-files in a library, for sending out via SFTP
to VMS operting system. (about 30 files size uncompressed, in total  about 180 GB )

Because of time limits, it is not possible to convert in IFS files, zip and send out.
PF-files have fixed length, contain alpha, numeric, packed fields.  
I assume, compression result must be tested.




   
0
 
tliottaCommented:
My intention is,  to zip pf-files in a library...

Since .ZIP files can't really exist in libraries, it doesn't seem that that's likely to happen.

Also, if the files are intended for use under VMS, I wouldn't expect savefiles to be much good either, especially compressed. I'm not aware of facilities on other platforms for reading savefiles (not to mention compressed). I wouldn't be surprised if they exist; I just haven't heard of any, well, except for one basic PC utility which wouldn't be appropriate for this. I'm not too sure that it's a good idea even to send direct record of images of database files, though they should be easy enough to read even with various utilities.

I'd expect the fastest method would be to save one file into a savefile, .ZIP the savefile in the IFS, FTP that .ZIP file, then move to file #2. The steps for each file could be run in parallel, so that file #2 was being saved while #1 was being FTPed.

Tom
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 
tliottaCommented:
...FTP that .ZIP file...

Correction --- "SFTP" or whatever transfer method you'll use.

Tom
0
 
Gary PattersonVP Technology / Senior Consultant Commented:
Are you aware that AS/400 DB2 tables are stored in a proprietary format that is probably not going to be very useful on your VMS system?  Also, as Tom pointed out, AS/400 Save Files are a non-standard format that won't lively be of much use on another platform.

Most people that want to port database files to another (different) system follow a process like this:

1) Export data from AS/400 DB2 tables to a common format, such as as CSV files.  As a bonus, properly exporting the data will convert all of your numeric fiends into easy-to use and import formats.

2) Zip and transmit

3) Unzip and process CSV files or import CSVs to the remote database.

You can use the CPYTOIMPF command to export AS/400 DB2 tables to various delimited and non-delimited stream file (IFS) formats.

Once you have the files in stream files, you can either download to a PC and use your favorite Windows ZIP tool to zip.  You can also use the AS/400 QSH environment's jar (Java Archive) command to zip the files (jar can produce zip-formatted files).  There are also a variety of zip tools that you can obtain and install:

http://forums.systeminetwork.com/isnetforums/showthread.php?t=44602

- Gary Patterson
0
 
tliottaCommented:
A VMS system might allow for DDM/DRDA data transfers. The two databases might be able to remove intermediate programmed conversion steps.

But the time element --

Because of time limits...

It's not clear what the restriction is. Is it a hard deadline? Is it a painfully slow connection between the systems? Is it necessary to get everything off of the AS/400 immediately while there will be time on the VMS side for a slower conversion?

Tom
0
 
tliottaCommented:
...you can either download to a PC and use your favorite Windows ZIP tool to zip.

With /QNTC (or maybe even NFS), it wouldn't necessarily be a "download". A .CSV could be created directly on a shared network drive if necessary.

Tom
0
 
tliottaCommented:
Sheesh ... VMS... sorry, was thinking VM. Probably should ignore "DDM" comment.

Tom
0
 
Gary PattersonVP Technology / Senior Consultant Commented:
Tom,

Probably just quibbling over semantics, but m-w.com defines the verb "download" as:

"To transfer (as data or files) from a usually large computer to the memory of another device (as a smaller computer)".

I didn't mention a specific mechanism, but QNTC or NFS are certainly easy ways to accomplish such transfers, though in my experience FTP is usually faster.

- Gary Patterson
0
 
stevebowdoinCommented:
I like to answer the question that was asked.  Try this: http://systeminetwork.com/article/make-zip-files-iseries

I use Scott’s method in production with no troubles.  When you get to that part where you specify the file to be zipped it will look something like this: /QSYS.LIB/MYLIB.LIB/MYFILE.FILE/MYFILE.MBR
That will zip your PF.  I would be shocked it the result was useful on VMS.  Where is the EBCDIC to ASCII conversation going to happen?

I recommend this: 1.install Scott’s method.  2. CPYTOIMPF your PF to an IFS file 3.zip your new file.  4. Transmit the ZIP.

The CPYTOIMPF will do the EBCDIC/ASCII job.  It will also fix any packed or binary data problems.

Steve
0
 
Gary PattersonVP Technology / Senior Consultant Commented:
@Steve,

I like to answer the question that was asked.

I do too.  (And did, yesterday.)  :-)

Just follow the link in my second post above, it leads right to another Scott K. post referencing the same article that you linked to (and several others that directly answer the "zip tool for AS/400" question).

Sometimes, however, when a question doesn't make a lot of sense, or when I get the sense that the person asking the question might not know how to best frame their question due to a lack of knowledge of the subject matter, or when I suspect that a language barrier that may limit the questioner's ability to pose the question, or when my experience tells me that the questioner may not be aware of the limitations or alternatives to a particular technique, I try add value to my response by attempting to discover and/or anticipate their actual functional needs in addition to directly answering the question.

In this case, I answered the question by providing a link to a relevant thread that discusses AS/400 zip tools.  

I also posed questions and offered information relevant to most cross-system data transfer tasks in and attempt to discover the actual functional requirements.  Since then, we've learned that this was for a cross-system data migration to VMS (an ASCII-based platform), that the files contain mixed alpha and numeric data, including packed fields.  

As a result, I proposed an  mechanism for exporting and compressing data from an AS/400 to a heterogeneous OS, such as VMS, that will present the data to the remote system in a format that is more likely to be easily usable.

- Gary Patterson

0
 
stevebowdoinCommented:
Gary

Looks like you and I have two ways of stating the same answer.

Steve
0
 
asdf13Author Commented:
well done discussion of the request .
thanks !
0
 
tliottaCommented:
I didn't mention a specific mechanism, but QNTC or NFS are certainly easy ways to accomplish such transfers, though in my experience FTP is usually faster.

I agree with all of that -- I was wanting to be more certain it was clear to the asker.

As for the element of FTP, though...

Due to the difficulty in transferring database formats to other platforms (packed and also negative zoned-decimal, not to mention possible integer values or others), I've sometimes created VIEWs that present all data as pure CHARACTER columns. Then I've FTPed the VIEW rather than the underlying TABLE.

I haven't needed to do it through sftp nor anything other than FTP, but with FTP the data has always been cleanly transferable. Nor have I tried anything like feeding such a VIEW into any variety of .ZIP function.

But it seems plausible. It ought to be worth a try.

Tom
0
 
Gary PattersonVP Technology / Senior Consultant Commented:
@Steve,

Great minds think alike!

@Tom,

The view/ftp technique is nice.  I think that is a "keeper".

- Gary
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

  • 6
  • 5
  • 2
  • +1
Tackle projects and never again get stuck behind a technical roadblock.
Join Now