Perforce Public Knowledge Base - Uncompress a checkpoint in Windows
Reset Search
 

 

Article

Uncompress a checkpoint in Windows

« Go Back

Information

 
Problem
When saving a compressed journal or checkpoint, Perforce uses the GZIP file format (which uses the .gz suffix). An MD5 checksum file is also saved alongside the GZIP file.
 
This article explains how to properly uncompress a compressed journal or checkpoint file on Windows.
Solution

To uncompress the .gz file, use the following steps:

1. Download gzip, a compression utility that is part of the GNU project. We suggest downloading the complete package from Sourceforge.net here:
http://gnuwin32.sourceforge.net/packages/gzip.htm

2. Install the utility

3. Run the following command:

gzip -d -a checkpoint.N.gz

The above command deletes the .gz file after a successful decompression. To uncompress and not delete the file, use a command like this:

gzip -c -d -a checkpoint.N.gz > output-file-name.N

Troubleshooting

  • After extracting Perforce checkpoint or journal files using a different utility, the MD5 sum differs
This checksum mismatch is expected.  For historical reasons, Perforce Server uses UNIX line endings in compressed files.  Journals and checkpoints on Windows are expected to have Windows line endings, however most compression utilities do not convert line endings when extracting .gz files. In such cases, there will be a checksum mismatch.
 
To correct the issue, use the gzip command listed above to extract the files. If needed you can re-compress the file to GZIP format before running the command.  Regardless of the line-ending style used by the checkpoint or journal files, they will be read correctly by Perforce Server regardless of whether the MD5 checksum value matches or not.
Related Links

Feedback

 

Was this article helpful?


   

Feedback

Please tell us how we can make this article more useful.

Characters Remaining: 255