Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

From reading the Perforce docs it sounds like only changelists and version history can be backed up. Is it possible to get Perforce to create a backup of files too, so that in the event of loss, through hardware failure for example, a complete set of files could be recovered?

share|improve this question

migrated from stackoverflow.com Oct 19 '09 at 11:30

This question came from our site for professional and enthusiast programmers.

4 Answers 4

As far as I understand, no, perforce is not doing that.

The perforce back-up process is two-fold: 1 - You need to back-up the files in the depot, using standard files back-up procedures. The files in the depot are in RCS format, and are called yourfiles.ext,v Those are the "sources" data. AFAIK, something as simple as getting a tar/zip copy of the depot in a safe place regularly is enough (USB key, etc... if you are worry of a server hardware failure). 2 - You need to use the perforce admin checkpoint command to back-up the content of the db files in the perforce depot. This is for all the perforce metadata.

One without the other is useless. So both should be synchronised.

Two things I have learned is that: A - You cannot open the archive files easily without restoring the metadata. I.e. I have not found a "RCS archives reader" tool that can open the perforce files from the backup without perforce itself. I.e. to get the content of one single files of the archive you need to restore the depot, including the metadata. B - the db.* metadata perforce files are using a proprietary DB system and cannot be open with standard db tools (like a SQL client or something)

Best regards,

Thomas

share|improve this answer
    
Thank you for that info, I'll give it a go later on and see if I can restore a backup onto another computer using this method. –  Macca Oct 19 '09 at 11:07

I'm not sure which docs you've been reading, but there's a fairly comprehensive guide in the Admin manual here.

If you are after something fairly simply - i.e. yours is not an industrial strength installation, then there's a few notes here that describes a way to get you backups going quickly and easily in just a few minutes.

share|improve this answer

The Perforce checkpoint is only a backup in so far as you can restore from it. You still need to backup the checkpoint file, and all subfolders of you perforce directory (by default where all depots are stored) where the files actually are to tape, remote storage etc as you would normally do with any backup.

What we have done elsewhere is run the checkpoint script and then add that file and the subfolder to our standard backup script.

share|improve this answer

The manual for the 2009.2 version of perforce server p4d has pretty clear documentation on this topic, see Greg Whitfield's answer above. I'd hyperlink to the last manual, but I don't have enough reputation.

The system administrator's guide pages on replication have more industrial solutions; making hot spares of metadata for no-downtime metadata backups, for example. The replicate command reference clearly explains you want to use 3rd party tools to backup the file data.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.