User's Manual for the ARJ archiver program, October 1997 ARJ software and manual copyright (c) 1990-97 by ARJ Software, Inc. All rights reserved. ARJ version 2.60 release ** IMPORTANT NEWS **************************************************** Users of ARJ should read the WHATSNEW.DOC and UPDATE.DOC files that contain information about the latest improvements to ARJ. A MAJOR change has been made to the ARJ BACKUP feature. ********************************************************************** TOPICS COVERED IN THIS DOCUMENT ------------------------------- DEDICATION INTRODUCTION NEW USERS TERMINOLOGY MAJOR FEATURES OF ARJ ARCHIVER BENCHMARKS RELEASE NOTES YEAR 2000 COMPLIANCE STATEMENT TECHNICAL NOTES ARJR AND DEARJ PROGRAMS SYSTEM REQUIREMENTS INSTALLATION QUICK START TO USING ARJ HOW TO CREATE AN EXECUTABLE SELF-EXTRACTING ARJ ARCHIVE CONVERTING OTHER ARCHIVE FILES TO ARJ FORMAT HOW TO USE ARJ ARJ LIMITATIONS IMPORTANT NOTES TIPS TO USING ARJ EFFICIENTLY USING ARJ WITHIN OTHER PROGRAMS ARJMENU PROGRAM USING ARJ AS A BACKUP PROGRAM BACKUP TYPE ARCHIVES AND BACKUP FILES CHAPTER ARCHIVES WINDOWS 95 LONG FILENAME SUPPORT ARJ-PROTECT DATA PROTECTION FEATURE ARJ ANSI COMMENT HANDLING THE FILESPEC "..." ARJ ERROR SITUATIONS ARJ DOS ERRORLEVELS ARJ USER ACTION PROMPTS ARJ ENVIRONMENT VARIABLE ARJ COMMAND LINE SYNTAX ARJ RESPONSE FILE SYNTAX ARCHIVE NAME WILDCARDING ARJ COMMANDS ARJ SWITCH OPTIONS ARJ COMMAND OPTIONS SAMPLE ARJ COMMANDS ARJ_SECURITY ENVELOPE KNOWN ARJ ISSUES/PROBLEMS ARJ ERROR MESSAGES COMMONLY ASKED QUESTIONS ARJ TECHNICAL SUPPORT ARJ AVAILABILITY ARJ INTERNET MAILING LIST ARJ WEB SUPPORT SDN EXTENSION FILES DISTRIBUTORS ACKNOWLEDGEMENTS USAGE AND DISTRIBUTION POLICY BRIEF BIOGRAPHY OF ARJ AUTHOR FINAL COMMENTS DEDICATION: The ARJ program is dedicated to God and to my family. From the beginning, our family decided that God would be the senior partner in our company and that our business practices would strive to reflect the principles that He has so graciously provided to the world in His Word. INTRODUCTION: ARJ is the result of a desire to use my interest in compression technology to produce an archiver for personal use on PCs and on minicomputers that provides power and excellent flexibility. This document is designed as an ARJ program reference manual and is not appropriate for novices to ARJ. The file named INTRO.DOC is intended for novices. Please note that the shareware versions of the ARJ programs may be slightly limited in functionality. See the UPDATE.DOC for more information. NEW USERS: Users new to the ARJ archiver should start reading the INTRO.DOC file instead of this document file. TERMINOLOGY: The following terms are used through this manual. ARCHIVE - This is a file containing one or more files in a compressed or non-compressed state and containing file related information such as filename and date-time last modified, etc. ARJ FILE - This is an archive created by ARJ. BACKUP TYPE ARCHIVE - This is an ARJ archive that has the internal backup flag turned on. This feature is obsolete after ARJ version 2.50a. Current and future versions of ARJ will ignore the special flag set on file backups. Replacing this backup archive scheme is the chapter archive scheme. CHAPTER ARCHIVE - This is an ARJ archive that contains one or more backup chapters. A chapter archive stores a full backup and a series of incremental backups in a manner that saves disk space by not storing duplicate files. A chapter archive allows the user to recover a directory of files as they were when the backup chapter was made. In other words, if daily backup chapters of a source directory were made from Monday to Friday, one could recover the source directory as it was on Wednesday. COMPRESSION - The process of encoding redundant information into data requiring less storage space. COMPRESSION PERCENTAGE/RATIO - The percentage compression reported by ARJ is a variation of one of the TWO standard methods of expressing compression ratio in the technical literature. ARJ uses the compressed size / original size ratio. The other method is the inverse ratio. When ARJ reports 96% as the compression ratio, which means that the compressed file is 96 percent of the original size (very little compression). Other archivers use their own methods. LHARC uses the same ratio as ARJ. EXTRACTION or UNCOMPRESSION - The processing of recreating the exact information that was previously compressed. SELF-EXTRACTION MODULE (SFX) - This is an archive that is an executable file that is capable of extracting self-contained files. TEXT MODE - In text mode, ARJ inputs the file using the C library text mode which translates the carriage return, linefeed control characters of MS-DOS to a single linefeed character. This saves space and provides the option for cross platform file extraction. On another platform, the host C library would change the single linefeed to the host text newline separator sequence. In addition, for platforms such as PRIMOS which set bit 8 in ASCII text characters, ARJ sets/resets bit 8 according to the platform extracted to. When extracting a text mode file to the same type of platform archived from, ARJ will NOT strip the 8-bit text to 7-bit text. VOLUMES - These are ARJ archives that are in sequence and have been created by a single ARJ command. Files in the volumes may span volumes in a split format. These volumes are usable archives. MAJOR FEATURES OF ARJ: Currently provides excellent compression in terms of size reduction compared to the leading archivers including PKZIP 1.10, PKZIP 2.04, PAK 2.51, ARC 7.0 (ARC PLUS), LHARC 1.13c, LHA 2.13, and ZOO 2.10. ARJ is particularly effective with database files and documents. The ability to process and archive up to 65,000 files at one time. The ability to select files for archival by type and/or attribute. Support for Windows 95 long filenames in the Windows 95 GUI DOS environment. Archive and individual file comments with the option of inputting comments from a file. ARJ has MS-DOS 3.x international language support for the proper casing of filenames and text. The ability to put the entire ARJ command line in a response type file as in "ARJ @command.rsp". 32 bit CRC file integrity check. DOS volume label support. Default storing of specified pathnames to allow recovery of a directory structure. Empty directory support. Backup support in the chapter archive scheme which allows a series of backups to be included in a single archive so that one can recover any one of the backups. The advantage of chapters is that files that have not changed are saved only once in the archive. Test new archive before overwriting the original archive option. Archives that can span diskettes. This allows the user to backup a full hard disk drive to multiple floppies. Recovery of individual files is convenient because each diskette archive is an individual archive except for the split file portion. No need to use SLICE with ARJ. In addition, ARJ in disk spanning mode can support the use of 3.5 HD diskettes formatted at higher capacities than 1.44 MBytes. Moreover, ARJ can build these disk spanning archives on the hard disk drive for later transfer to diskettes. Archive file re-ordering facility with the option of sorting by file size, file extension, CRC value, date-time modified, filename, pathname, compression ratio, file attribute and more. String searching with context display within archive files. Built-in facility to recover files from broken archives. Self-extraction feature that is internal to the ARJ runfile. The SFX module is full-featured with a built-in help screen. ARJ also includes a smaller SFXJR module with fewer features. Multiple volume self-extracting archives. The ability to embed command line type options inside self-extracting archives. Internal string data integrity check in ARJ to resist hacking a la LHARC to ICE. Archive security envelope "seal" feature to resist tampering with secured archives. This feature disallows ANY changes to a secured archive. Even the archive comments can NOT be changed without removing the "seal". Password option to encrypt archived files. Text mode data compression option to enable movement of text files from one host machine to another. Text mode also results in slightly greater file size reduction on MS-DOS machines. File extraction to screen in a paged mode to permit browsing through an archive. Specification of the files to be added to or exclude from an archive via one or more list files. In addition, ARJ can generate a list file. Specification of files to be excluded from processing by ARJ. Sub-directory recursion during compression and extraction. ARCHIVER BENCHMARKING: This is information for those who plan to publish benchmark test results comparing ARJ with other file archivers. The ARJ -jm compression is intended to demonstrate the best that ARJ can do in terms of size reduction. However, the ARJ -jm1 compression is almost as good in terms of size reduction. The ARJ -m2 compression is intended to compete with LHA 2.12. The ARJ -m3 compression is intended to compete with PKZIP 1.10. The ARJ -e option is necessary during size benchmarks because ARJ by default stores the entire specified pathname in the archive as opposed to other archivers which strip path specs. Example command: ARJ a benchmrk -e -jm1 files\*.* The very size of the ARJ runfile adds significantly to the compression and extraction times when testing smaller archives. RELEASE NOTES: The use of ARJ in a business, commercial, institutional, or government environment requires a license. However, business, commercial, institutional and government users may use ARJ for evaluation purposes for a period of 30 days. See the LICENSE.DOC for full details. The inclusion of any of the ARJ software (ARJ, ARJR, DEARJ, ARJSFX, ARJSFXV, ARJSFXJR, REARJ) with software and/or hardware for distribution requires a license. While evaluating ARJ, you should use the "-jt" (test archive) option to verify new ARJ archives of your data. This version has been tested under DOS 2.11, 3.3, 4.01, 5.0, 6.0, and 6.2x. It also runs under the DOS windows of Windows 3.x, Windows 95, OS/2 2.0, Warp 3, and Warp 4. Here is a suggested command that will test ARJ on all of your files: ARJ a testvol c:\ "-v360sdel testvol.*" -xtestvol.* -y -jf -jt1 -r YEAR 2000 COMPLIANCE STATEMENT: This version of ARJ as well as all previous versions are YEAR 2000 compliant and will operate properly with full functionality up to the year 2079. No special user changes or activities are required for this compliance. No programming or configuration changes are required either. The limitation beyond 2079 concerns the syntax of the "-o" and "-ob" date selection options. The date specification is YYMMDD. The selectable years range from 1980 to 2079. The date specifications "800101", "990101", "000101", "790101" stand for January 1 of the years 1980, 1999, 2000, 2079 respectively. TECHNICAL NOTES: A detailed technical description of the ARJ archive format is available in the UNARJ distribution archive. This archive contains a description of the archive header formats as well as C source code for an ARJ archive extractor and lister program. This source code has been made portable to several platforms including UNIX, NEXT, DOS, and AMIGA. ARJR, DEARJ, and REARJ PROGRAMS: The new programs ARJR and DEARJ are available to registered and licensed users of ARJ. ARJR is the ARJ program without the help screen and SFX modules. DEARJ is the ARJR program without the archive creation/modification functions, the "w" command, and the "-jt1" and "-jt2" switches. There are two versions of REARJ, the shareware version and the registered version. The registered version contains a number of additional enhancements including environment variable usage, !listfile capability and selection by file date-time. See the LICENSE.DOC and ORDERFRM.DOC for more information. UNARJ and DEARJ are NOT the same program. SYSTEM REQUIREMENTS: The ARJ software package is designed to work under DOS versions and DOS boxes from 2.11 and above. However, certain features have an OS limitation under DOS versions prior to DOS 3.0: access to the self-extractors and to the built-in help information. To get the ARJ help screens and the ARJ self-extraction creation to work, ARJ.EXE MUST be located in the CURRENT directory. This limitation exist only in newer versions of ARJ to save on memory usage. Within the Windows 95 DOS box environment, ARJ supports the use of Windows 95 long filenames. This feature ONLY works in the Windows 95 DOS box. It does not work under DOS 6.x nor does it work under Windows NT. INSTALLATION: We assume that you have a copy of the self-extracting ARJ module named ARJ###.EXE where "###" represents the ARJ version number. Typing ARJ### [RETURN] at the DOS command prompt will initiate the self-extraction feature. ARJ### will by default extract its files to the current directory. When ARJ### starts, you will see several lines of text describing ARJ and then a line asking if you wish to continue extraction. Entering "yes" or "y" will continue the extraction. If there are any duplicate filenames in the current directory, the program will prompt you for overwriting. You can enter "yes", "no", or "quit". To install the ARJ software, simply copy ARJ.EXE, REARJ.EXE, REARJ.CFG, ARJSORT.COM and optionally ARJCRYPT.COM to one of the directories named in the DOS PATH statement found in your AUTOEXEC.BAT. On many PCs, this directory may be C:\DOS or C:\BIN. With MS-DOS 3.0 and above, you can use path notation "\BIN\ARJ e archive" to use ARJ. ARJCRYPT.COM is ONLY found in versions of ARJ for USA use. You may, of course, prefer to use ARJ 1.00 or higher to extract the contents of ARJ###.EXE file manually. Example: ARJ e ARJ###.EXE \temp\ QUICK START TO USING ARJ: See the document INTRO.DOC. HOW TO CREATE AN EXECUTABLE SELF-EXTRACTING ARJ ARCHIVE: The command "ARJ y -je archive" will create a full featured self-extracting archive from an already built archive. The command "ARJ y -je1 archive" will create a smaller self-extracting archive. Syntax: ARJ y -je archive produces archive.exe The registered version of ARJ lets users create multiple volume self-extracting archives, Syntax: ARJ y -je archive -v360K produces archive.exe, archive.e01, archive.e02 .... Under DOS systems other than 2.11, 3.2, 3.3, 4.0, 5.0, 6.x, and 7.0, you may have to rename the self-extract module to ARJSFX.EXE to do the extraction. See the "-je" option for more information. CONVERTING OTHER ARCHIVE FILES TO ARJ FORMAT: Included with this software is the program REARJ. This program can be used to individually or collectively convert archive files from other formats to the ARJ format. The command "REARJ *.ZIP *.ARC *.LZH" will convert all ZIP, ARC, and LZH archives in the current directory to the ARJ format. See the REARJ.DOC for more information about REARJ. HOW TO USE ARJ: If you type ARJ [return], you will see a simple help screen. If you type ARJ -? [return], you will see more detailed help information. ARJ LIMITATIONS: ARJ will accept up to: 64 filenames/wildnames on command line 65000 filenames resulting from wildnames 16000 filenames/wildnames to exclude 16000 ARJ filenames resulting from wildnames 2048 character comments (up to 25 lines or 1 file) For compressing, ARJ requires approximately 300,000 bytes plus the memory necessary to store all of the pathnames to be archived when using the default compression method (-m1). For extracting, ARJ requires approximately 175,000 bytes plus. The program DEARJ (available to registered users) requires approximately 125,000 bytes plus. There is no limitation on the number of files that can be stored in one archive. However, under default use, each add command can only add a maximum of 16,000 files at a time depending upon memory availability. We expect that a normal maximum of 5,000 to 10,000 filenames can be handled without running out of memory during the compress phase. The new option "-hm" allows ARJ to archive up to 65,000 files at one time by using disk space or XMS memory instead of conventional memory. Example: ARJ a -r archive \*.* -hm ARJ currently does not see that wildnames like "C:*.*" and "C:\*.*" can actually represent the same thing. ARJ would expand each of those two wildnames into a list that could be up to twice as long as necessary. When updating an archive, ARJ creates a temporary file named ARJTEMP.$nn in the current directory or special work directory if specified (-hm!F:\). While ARJ is scanning a wildcard filespec, ARJ will change the name of the target archive to ARJTEMP.$nn while the scan is proceeding to avoid including the archive itself in an add or move command. Also, as a result, you cannot add a file named ARJTEMP.$nn to an ARJ archive. Please note that the name of this temporary file may change at a future revision of ARJ. In this release, ARJ will not use memory for filenames that it does not select by name or by file attribute (archive bit, file type). IMPORTANT NOTES: When using the "-w" working directory switch, ARJ does not check on space availability before overwriting the original archive if it exists. Be sure that you have enough disk space for the new archive before using the "-w" switch. If ARJ aborts in this situation because of disk space, ARJ will keep the temporary archive. By default, ARJ does not see hidden or system files. ARJ will process system and hidden files when you either specify the "-a" switch or use the new "-hb" switch. Like LHARC and PKZIP, ARJ requires extra disk space to UPDATE an archive file. ARJ will backup the original archive while it creates the new archive, so enough room must be available for both archives at the same time. Unlike PKZIP, ARJ does not require additional work space when CREATING a new archive. Currently, ARJ will not extract overwriting a readonly file unless the "-ha" option is specified. TIPS TO USING ARJ EFFICIENTLY: You should use a software or hardware disk cache to speed up ARJ access. Diskette drives should NOT be write-delay enabled. Write-delay would prevent ARJ from truly verifying diskette writes. When archiving to diskettes, you should use the "-w" option to set a working directory on your RAMDRIVE or hard disk drive to speed up building the archive. You should use the "-jt" or "-jt1" option when archiving to diskettes or when you really want to be sure that ARJ will be able to extract what you have archived. There are cases where your hardware or memory resident software will corrupt your work, so the "-jt" options are excellent insurance. If you have bad sectors on your diskettes and verify is turned off, DOS will not tell you about diskette errors until it is too late. These errors are NOT RECOVERABLE. Using the "-js" option saves time by not compressing archives of PKZIP, LHA, ARC, ZOO, ARJ, etc. You should use the "-e" option whenever you do not need to store pathnames in an archive that you are creating. This will save space. Convert an ARJ archive into a self-extracting archive with a command like the following: ARJ y archive -je To capture a comment from an ARJ archive, use the following command: ARJ e archive ... -zcomment.txt (the "..." is significant). ARJ has several compression methods that provide size/time tradeoffs. Method 4 "-m4" is about twice as fast as method 1. The "-jm1" and "-jm" options modify the "-m1" option to provide even greater compression at a cost in time. USING ARJ WITHIN OTHER PROGRAMS: Since ARJ uses over 300,000 bytes of memory during compression, it is difficult to use ARJ in a large application program unless that program swaps itself out of memory when it executes DOS commands like ARJ. However, there is at least one shareware program available that will automatically swap your large application program out of memory whenever it shells out to DOS to execute a command. The program SHROOM by Davis Augustine should be able to solve this memory problem for you. The latest version as of 03/11/92 is named SHROM19C.ZIP on Channel One BBS. According to the SHROOM documentation, you can reach the author at: CompuServe id 72230,3053 Davis Augustine P.O. Box 610 Sausalito, CA 94966-0610 This is not an endorsement of the product SHROOM. The easiest way we have found to use this product is to type: SHROOM COMMAND.COM SHROOM -v COMMAND.COM will let you see SHROOM in action when you shell out to execute a DOS command. ARJMENU PROGRAM: A program called ARJMENU by Michael McCombs is available. As far as we know, it is the only menu-driven interface program that supports ALL of the features of ARJ. This program is aimed at users who hate command line interfaces. ARJMENU allows the user to pick and choose ARJ options. The user does not have to remember the ARJ switch syntax. The current version of the program supports ARJ version 2.30. The author is no longer supporting this program. ARJ HELP HYPERTEXT PROGRAM: ARJ-Help is an electronic book (brand named Window Book (TM)) that allows the user to discover easily how to use ARJ. It runs under DOS. It is very fast and has a rich set of features which include full-text search, hypertext links, a table of contents that can be reorganized to your needs, a complete index, and much more. The current version can be found on some BBSes as ARJHLP24.EXE. Window Book, Inc. P.O. Box 390697 Cambridge MA 02139 USA TEL: 617-661-9515 or 800-524-0380. FAX: 617-354-3961 ARCHIVER UTILITIES THAT SUPPORT THE ARJ FORMAT: The following are some other utilities that facilitate the use of ARJ. This list is not all inclusive or is it meant as a personal recommendation. ARCHIVE MANAGER PRO - Archiver shell ARJMENU 1.x - ARJ shell SHEZ 8.x - Archiver shell ARCMASTER 6.x - Archiver shell ZGEN 1.x - Archiver shell ACZAR 1.x - Archiver shell ARJVIEW - ARJ shell AVIEW - BBS archive viewer WINZIP - Windows archiver shell WINDOWS COMMANDER - WIndows archiver shell A particularly useful ARJ support utility is SARJ (latest version is 1.12) by Frederic Taes. It improves upon ARJ compression by using ARJ to build "solid" archives. USING ARJ AS A BACKUP PROGRAM: ARJ can be used as a substitute for a backup program. Now ARJ includes an error recovery option (-hk) to help protect against many kinds of data errors. The most common cause of failure is bad diskettes. You should let ARJ test the archives ON the diskettes. Testing the archives before copying them to diskettes is not enough. Critical data should always be backed up two or more times. Please keep in mind that damage to compressed data is many times more serious than damage to uncompressed data. WARNING: It is our recommendation that you should NOT update multiple volume ARJ archives of critical data especially backup archives. A system error could cause the current set of volumes being updated to be damaged. Use a separate set of diskettes to do an incremental backup. The following partial command lines illustrate a full backup command, an incremental backup command, and a restore command. The only parts missing are the names of the files to backup/restore. ARJ a A:backup -r -vvas -a1 -b2 -hk -js -jt -jiC:\backup.inx -wC:\ -m3 ARJ a A:backup -r -vvas -a1 -b1 -hk -js -jt -jiC:\backup.inx -wC:\ -m3 ARJ x A:backup -vv -y You should familiarize yourself with the above switches so that you can modify the above command lines as needed. If you have a RAMDRIVE large enough, you should change the "-w" option to point to the RAMDRIVE. If you have enough free hard disk space, you can build all of the diskette volumes on the hard disk for future transfer to diskette. In this case, you will need to change the name of the archive to "C:backup" or similar. The "-vvas" option should be changed to "-v360", "-v720" or whatever is appropriate for your diskette size. Please note that 360, 720, 1200, and 1440 are abbreviations for the standard diskette sizes. Other sizes will require your entering the entire number. Another change is to add the option "-y" which will turn off the "Ok to proceed ...." prompt. Lastly, if the "-w" option is pointing to the hard disk, you should remove the "-w" option entirely. ARJ a C:backup -r -v360 -m3 -y ***IMPORTANT*** Only a maximum of 100 volumes can be built on disk at one time because of the volume suffix rolling over at *.A99 to *.A00 when using default archive naming. However, if you specify the starting archive name with a suffix of ".000" or ".001", ARJ will create up to 1000 or 999 uniquely named volumes. ARJ a C:backup.000 -r ........... Both backup commands will pause for a "system command". You can execute DOS commands at this point. This is a suitable place to do a "dir a:" to make sure that your disk is formatted and has enough free space on it. You may need to execute "format a:" or "del a:\". A very useful command might be "QDR A:". QDR is a utility from Vernon Buerg. You will need to type "exit" to allow ARJ to continue. If the backup fails after completing one or more diskettes, you can restart at the next archive after the last successful volume. There are two methods to do this restart. If you have specified an index file with the "-ji" option during the failed backup, you can restart by retyping the EXACT SAME command line as before and adding the "-jn" option. This will cause ARJ to scan the previously written index file for the proper restart information. ARJ will automatically set the correct volume name. Example: ARJ a a:backup c:\ -r -vvas -jiINDEX.FIL ARJ a a:backup c:\ -r -vvas -jiINDEX.FIL -jn The second method is more complicated. Refer to the "-jn" and "-jx" descriptions for more details. For example, if the above full backup command failed during diskette two, on filename "DOS\MODE.COM" which was started at byte 125. This would be the correct command: ARJ a A:backup.A01 -r -vvas -a1 -m4 -jx125 -jnDOS\MODE.COM The most error prone step is determining the correct "-jn" option. A common error concerns the use of the root directory symbol "\" with the "-jn" option. Verify the presence or absence of the root symbol "\" in the backup index file. If the restore fails after one or more diskettes, simply retype the same command as before but add the right ".Ann" suffix to the archive name. If ARJ has aborted because of a disk full on a file split between volumes, you will have to restart at the first volume that contains that file. BACKUP TYPE ARCHIVES AND BACKUP FILES: This type of archive is obsolete after ARJ version 2.50a. It is replaced by the chapter archive. CHAPTER ARCHIVES: This feature is useful when backing up frequently modified files. This new feature is designed to make the backup management of a directory or application easier. It allows the taking of a sequence of backup "snapshots" of a changing application or directory. A chapter archive can provide major space savings over using many separate archives for backup. For example, a chapter archive could be used to keep track of the state of a Windows 3.1 directory. An initial chapter backup could be made of the original Windows 3.1 installation. Then, whenever a new software package is installed, a new chapter snapshot could be taken. ARJ ac winback c:\windows\*.* -r -a1 -jt1 If a Windows problem develops, one can restore Windows back to any particular chapter for testing. ARJ x winback c:\ -y -jb5 restore chapter 5 This chapter feature is especially useful for software developers. Since a chapter archive can contain up to 250 chapters, the change history of a software source directory for a period of weeks can be maintained in a single archive. You could take four chapter snapshots per day for over two months to a single archive. This would allow you to restore your source directory to one or more points in time to help you track the appearance of software problems. See the "-jb" option for more details. The limitation on the maximum number of chapters is an internal resource issue as well as a "recommendation" to build a new archive. Making thousands of modifications to important backup data is a somewhat risky activity. WINDOWS 95 LONG FILENAME SUPPORT: This version of ARJ supports the use of long filenames under the Windows 95 GUI in the MS-DOS Prompt environment. It does not support long filenames under MS-DOS 6.22 and below. It supports long filenames ONLY when the Windows 95 GUI (graphical user interface) is running. In other words, there is no long filename support in Windows 95 MS-DOS mode (accessed from the Win95 shutdown menu). Moreover, there is NO long filename support in ARJ for Windows NT. Windows 95 DOS support (and therefore ARJ) do not support access to long filenames containing certain characters. For example, a filename containing the copyright symbol or the trademark symbol cannot be accessed in a Win95 DOS window with the COPY command or with ARJ. These type of filenames can only be accessed via their short names. The Win95 system normally stores filename characters as two bytes per symbol allowing an alphabet of 65536 possible symbols. Because Win95 DOS only uses one byte per character position allowing only a 256 symbol alphabet, many characters are displayed by Win95 DOS as "_". The small ARJ self-extractor (-je1) does NOT support the handling of long filenames. The ARJSFX and ARJSFXV modules (-je) support long filename handling. However, they will only extract archived Win95 long filename files under Win95. If long filename files are being extracted to plain DOS, an error message will be displayed. They can be forced to extract the Win95 archived files with the "-j" option. For compatibility with MS-DOS and older versions of ARJ, ARJ can create a dual-name compatibility ARJ archive. This is an archive with both shortnames and longnames stored in it. The longnames are stored in the file comment field. New versions of ARJ will treat the dual-name archive according to the operating system environment. In other words, under MS-DOS, a dual-name archive will look like a shortname archive. Under Win95, a dual-name archive will look like a longname archive. This is also true of the ARJSFX and ARJSFXV modules (-je). For efficiency reasons ARJ does not repeatedly check for file system support of long filenames. ARJ only tests the "C:" file system. An error may occur if ARJ under Win95 tries to access a disk drive that does not support long filename handling. The "-hf" option can be used to force ARJ to use the standard 8.3 filename APIs instead of the longname APIs. There are four new options "-hf", "-hf1", "-hf2", and "-hf3" that provide choices in the handling of long filenames. See the discussion of those options below for more information. ARJ will save Win95 long filenames in the letter case they are stored on disk; however, all filename matching is done without regard to case. In other words, "ThisName.Ext" matches "thisNAME.ext". When archiving files under Windows 95, be sure to EXCLUDE files from processing that are OPEN such as WIN386.SWP. REMINDER: When specifying filenames with embedded blanks or symbols like ">", "<", or "|" on the command line, you MUST quote the filenames. Examples: ARJ a archive "C:\Program Files\*.*" -r ARJ c archive "<<<*" -jz -jb However, please note that ending a quoted filename with a "\" will not work as expected. The "\" before a special character will quote it literally. The string \" will result in a literal double quote mark. This is not a feature of ARJ. Example: "C:\Program Files\" will be translated to C:\Program Files" You will need to use two backslash marks as in "\\". Example: "C:\Program Files\\" For Windows 95 disaster recovery, we make use of the program DOSLFNBK.EXE 1.5 by D. J. Murdoch. With this program while in plain DOS, you can save all of the long filenames to BACKUP.LFN. Then you can use ARJ or any other DOS backup scheme to backup your system including the BACKUP.LFN. CAUTION: DOSLFNBK 1.5 may not work on all Windows 95 versions. It apparently does NOT WORK on VFAT32 Windows 95. Here is a brief list of steps to backup and restore: 1) Make a Win95 startup diskette. 2) Shutdown to MS DOS mode. 3) While you are on the C: drive, execute "DOSLFNBK C:\". Change to the D: drive (if any) and execute "DOSLFNBK D:\". Execute DOSLFNBK for each drive on each drive. 4) Use ARJ or other DOS backup program to backup ALL of the files. Example: ARJ a A:backup C:\*.* D:\*.* -r -a1 -jt1 -va -jf CAUTION: For important backups, we always make TWO BACKUPS of our system. All too often, one or more files will not restore correctly because of some data error (MURPHY'S LAW in action). 5) Save ARJ.EXE or your backup program to diskettes in a restorable form. 6) Backup finished. 1) Boot from your Win95 startup diskette. 2) Execute "SYS C:" from the A: drive to re-install the boot. 3) Install ARJ.EXE or your backup program on the hard drive. 4) Restore all of the files. Example: ARJ x A:backup -v -jf -y -ha 5) On each drive, execute "DOSLFNBK /r" to restore the long filenames. 6) Restore finished. ARJ-PROTECT DATA PROTECTION FEATURE: With this version, ARJ can repair "protected" archives that suffer from slight amounts of data damage (CRC error, bad header, etc). An ARJ archive is "protected" with the "-hk" option. With the "-hk" option, ARJ will generate a separate ARJ data protection file. This protection file is REQUIRED in order to repair damaged ARJ archives. The size of this file ranges from a minimum of 4096 bytes and upwards. For larger archives, the protection file size is typically less than one percent of the archive file size. For this release, the protection file is a separate file. This avoids the problem of uploading unnecessary data to BBSes and ftp sites. The name of the protection file is based upon the archive name plus the extension ".XRJ". Volume protection filenames end in ".X01", etc. This protection feature is sector based and allows repair due to typical types of disk corruption (bad sector, virus damage, cross links, etc). This type of sector protection is NOT effective for most data transmission problems where data is missing from the middle of a transmission. Technically, this protection feature uses a series of XOR sums and checksums in order to allow repairs. Larger archives are logically treated as several streams of data. ARJ can protect each "stream" from one or two damaged sections 1024 bytes in size. However, for large archives (1 MB or larger) ARJ can sometimes repair up to four damaged sections per MByte. The "-hk1, "-hk2" ... "-hk9" options can offer more data protection at the cost of a proportionately larger protection file. The "-hk" option sets ARJ to build a protection file. The "q" command is used to repair a damaged archive. The repaired archive is named ARJFIXED.ARJ. Example: ARJ a archive -hk generates archive.xrj ARJ q archive repairs archive.arj ARJ ANSI COMMENT HANDLING: As of version 2.55, ARJ will use its own ANSI sequence display handler to display ARJ comments. In previous versions, ARJ depended upon the "-ja" option and an installed ANSI.SYS driver to handle the ANSI escape sequences. The "-ja" option has a new function now. The "-ja" option will set the "P" command to display files using the new ANSI sequence display handler. The ARJSFXV module (-je -v) also will display ANSI comments now. Please note that the ARJ comment field size is limited to about 2K bytes. THE FILESPEC "...": Several times in this document and the UPDATE.DOC file, there is mention of the filespec "..." (not to be confused with my use of "...." in this document to mean "and so on"). This filespec is chosen so as not to match any existing filename. ARJ will NOT generate an error or warning for not matching "..." specifically. This is a problem when using ARJ on a NOVELL network as the filespec "..." is a valid directory name. A partial workaround is to specify a non-existent filespec such as "@@@" in place of "...". Or you may use the "-hn" option to specify a name that is not to match any filename. ARJ ERROR SITUATIONS: ADD: If a user specified file is not found during an add, ARJ will continue processing, and will keep the archive and terminate with an error condition. Note that files specified within an ARJ listfile that are not found during an add will NOT trigger an error unless the "-hl" option is also specified. In a disk full condition or any other file i/o error, ARJ will promptly terminate with an error condition and delete the temporary archive file unless the user has specified the "-jk" switch. MOVE: ARJ will only delete files that have been successfully added to the archive. If you have specified the "-jt" (test) switch, ARJ will abort on any error. If you specify the "-jk" switch, ARJ will keep the temporary archive upon an abort. EXTRACT: In a disk full condition or any other file i/o error, ARJ will promptly terminate with an error condition and delete the current output file. CRC ERRORS OR BAD FILE DATA: In the case where an ARJ archive has been corrupted, ARJ will report a CRC error or a Bad file data error. These corruptions can be the result of an unreliable diskette, a computer memory problem, a file transfer glitch, or incompatible CACHING software. Most of these errors are the result of file transfer glitches and bad diskettes. A few are the result of an incompatible interaction with SUPER PCKWIK 3.3 advanced diskette support or Windows 3.x. Individual files in an archive that are affected by the CRC or Bad file data errors CANNOT be recovered. Other files in a damaged archive can be recovered by extracting them using the "-jr" option. However, with some preventative action as in the use of the -hk option to generate a data damage protection file, slightly corrupted ARJ archives can be fully repaired and all damaged files recovered. CRITICAL ERROR HANDLER: ARJ sets up an interactive critical error handler to handle DOS critical errors like "sector not found" and "drive not ready". When a critical error occurs, ARJ will prompt the user with the message "Retry Y/N?". The user may retry the failed operation by pressing "Y". Pressing "N" will fail the operation or abort to DOS depending upon the version of DOS. The user can press Control BREAK to abort to DOS. ARJ DOS ERRORLEVELS: ARJ returns a number of DOS errorlevels for different situations. 0 -> success 1 -> warning (specified file to add to archive not found, specified file to list, extract, etc., not found, or answering negatively to "OK to proceed to next volume...." prompt) 2 -> fatal error 3 -> CRC error (header or file CRC error) 4 -> ARJ-SECURITY error or attempt to update an ARJ-SECURED archive 5 -> disk full or write error 6 -> cannot open archive or file 7 -> simple user error (bad parameters) 8 -> not enough memory 9 -> not an ARJ archive 10 -> XMS memory error (read or write) 11 -> user control break Please note that DOS batchfiles have a unique method of testing for a DOS errorlevel. The batch statement IF ERRORLEVEL 0 .... means if the errorlevel is EQUAL TO or GREATER THAN 0. Generally, one should test for the highest possible errorlevels first and proceed lower as in: ARJ a archive *.* if errorlevel 9 goto not_arj if errorlevel 8 goto no_memory . . . if errorlevel 1 goto minor_error type ARJ command successful ARJ USER ACTION PROMPTS: ARJ prompts the user for action at certain times. There are several types of prompts. One is for yes/no permission, another is for a new filename, another is for archive comments, and one other is for search strings. The ARJ yes/no user prompts provide a lot of flexibility. In addition to the normal yes and no responses, ARJ also accepts the following responses: quit, always, skip, global, and command. "Global" sets ARJ to inhibit all subsequent user prompts by assuming YES for all queries as if "-y" were specified. "Always" sets ARJ to assume YES for subsequent queries of the same class. For example, answering ALWAYS to the overwrite query will assume YES for ALL subsequent overwrite queries. "Skip" sets ARJ to assume NO for ALL subsequent queries of the same class. After "always" or "skip" responses, subsequent user prompt messages will still be output to the screen but no user response will be accepted. "Command" prompts for one DOS command and then executes it. ARJ then returns to expect an answer to the current yes/no query. You should keep the query in mind as ARJ does NOT always redisplay the full query message. Since ARJ uses STDIN for user input, be careful about typing ahead anticipating prompts. ARJ may prompt you for an unexpected action and use your earlier input. The "-jyy" option lets you change the prompting modes to single character query mode. See the section on "-jy" for more information. ARJ ENVIRONMENT VARIABLE: ARJ will first look for an environment variable named ARJ_SW and use its value as switch options for ARJ. If ARJ finds such an environment variable, it will display a message to that effect. You can inhibit ARJ from using this environment variable by using the "-+" option. You can also set the name of the environment variable with the "-+" option as in ARJ a -+ARJ_SW2 archive. SET ARJ_SW= Example: SET ARJ_SW=-w\temp -k -e Do NOT add any blanks after the variable name ARJ_SW. As in LHARC, command line switches can be selected to override ARJ_SW settings. ARJ will allow you to use a different switch character "-" or "/" in ARJ_SW and in the command line except when using the "-ju" (unix) option. If the ARJ_SW environment variable specifies a filename (text not beginning with a switch character), ARJ will open that filename and scan it looking for a line of text that begins in column 1 with the same letter as the ARJ command being executed. The following text is processed as the ARJ_SW switches. This allows each ARJ command to have its own switch settings. In addition, ARJ will also look for the "+" (plus) symbol in column 1 to use as a miscellaneous switch string. This string will be added to any command switch string found if any. If no command switch string is found, ARJ will use the miscellaneous switch string as the ARJ_SW switch settings. NOTE that the "+" switch settings will NOT be used if the "+" string occurs below the command switch string. SET ARJ_SW=C:\ARJ\ARJ.CFG C:\ARJ\ARJ.CFG contains: a -jm1 -jt -i1 c -zcomment.txt + -jv l -jp e -i1 AND is equivalent to: a -jm1 -jt -i1 c -zcomment.txt l -jp -jv e -i1 -jv f -jv v -jv all other commands . . . In the above example, any ARJ "a" commands will use "-jm1 -jt -i1" as the ARJ_SW switch options. The ARJ_SW variable or the ARJ_SW configuration file switch settings may NOT have quoted switches such as "-vasformat a:". ARJ COMMAND LINE SYNTAX: ARJ [-[-|+|