Please note that the use of -C1 is documented, however the use of other -Cn options are still undocumented, and are subject to change or removal without prior notice. Consider using the p4migrate utility instead to translate case. If you choose to use the -Cn flag, you must ALWAYS use this flag. This is necessary both when starting your Perforce Server and when running checkpointing or upgrade operations. If you do not do so, you risk corrupting your Perforce database and/or your checkpoint and journal.
What does the -Cn flag do?
When do I use it?
The -Cn flag instructs the Perforce Server to override the operating system's case handling behavior for the Perforce database. The flag was introduced in release 2004.2, and is a server side flag. From the release notes:
You use the -Cn flag when:
You want to change the way the Perforce Server handles the case, overriding the operating system's default case-handling.You are migrating your Perforce Server to an operating system with a different case-handling method, but you wish to retain the existing method for case-handling.
You do NOT use the -Cn flag when:
You are not intending to override the operating system case-handling.If you do not intend to override case-handling, you checkpoint the database, resolve any case conflicts and inconsistencies, then restore from this case-consistent checkpoint. This process is explained in more detail in Article #75: Cross-Platform Server Migration.
You MUST NOT use -C0 or -C2 when:
running your Perforce Server on a Windows platform, and one file name or path differs from another only in case. This will corrupt the corresponding archive files.When using either -C0 or -C2, the Perforce Server makes a distinction between "//depot/file.txt" and "//depot/FILE.TXT", and tells the operating system to write "file.txt,v" or "FILE.TXT,v" accordingly. Although Windows is capable of preserving the case used, it is unaware of the difference between these two names. Therefore, "file.txt,v" overwrites or is appended to "FILE.TXT,v", and so too for the reverse, causing loss or corruption of revision content.
If you have not created a database, you can simply start the Perforce Server using the appropriate -Cn flag.
For an existing database, call or email Perforce Technical Support at support@perforce.com because this is not a trivial task. You will need to take a checkpoint of the database, then restore it including the appropriate -Cn flag in the "restore" command. This restore ensures that the order of the keys is appropriate for the case-handling. In addition, you will need to correct case differences using the p4migrate script, and change versioned file line endings.
Important: The -Cn flag can only be used against new Perforce databases. Using the -Cn flag against a Perforce Server that is already in use instantly renders the keys out of order. Not only does it make the data largely inaccessible, it could easily cause the btree code enough confusion to corrupt the tree.
Notes:
The 2007.2 release of the Perforce Server checks the case order of the database on startup. If there is a mismatch, an error is reported in the log:
As of 2010.1 -C1 is now documented in p4d -h $p4d -h$ -C1 Force server to be case insensitive
For a working example of using the -Cn flag see Article 516: Moving from Windows to Linux, Retaining Case-handling.
Chapters: Bitkeeper, Ibm Rational Clearcase, Perforce, Team Foundation Server, Microsoft Visual Sourcesafe, Visual Studio Team System, Accurev, Code Co-Op, Starteam, Ibm Rational Clearcase Ucm, Sun Workshop Teamware, Ic Manage, Allfusion Harvest Change Manager, Ftpvc, Mks Source, Ibm Configuration Management Version Control, Qvcs, Vault, Ibm Rational Multiversion File System. Source: Wikipedia. Pages: 78. Not illustrated. Free updates online. Purchase includes a free trial membership in the publisher's book club where you can select from more than a million books without charge. Excerpt: Rational ClearCase is a software tool for revision control (e.g. configuration management, SCM) of source code and other software development assets. It is developed by the Rational Software division of IBM. ClearCase forms the base of version control for many large and medium sized businesses and can handle projects with hundreds or thousands of developers. ClearCase supports two kinds of use models, UCM, and base ClearCase. UCM provides an out-of-the-box model while base ClearCase provides a basic infrastructure (upon which UCM is built) which allows for more flexibility. Both can be configured to support a wide variety of needs. ClearCase can run on a number of platforms including AIX, z/OS, Linux, HP-UX, Solaris and Windows. It can handle large binary files, large numbers of files, and large repository sizes. It handles branching, labeling, and versioning of directories. ClearCase was developed by Atria Software and first released in 1992 on Unix and later on Windows. Some of the Atria developers had worked on an earlier system: DSEE (Domain Software Engineering Environment) from Apollo Computer. After Hewlett-Packard bought Apollo Computer in 1989, they left to form Atria. Atria later merged with Pure Software to form PureAtria. That firm merged with Rational Software, which was purchased by IBM in 2003 . IBM continues to develop and ma...More: http://booksllc.net/?id=343023