IBM Support

Troubleshooting "failed 'create_version' operation" messages checking in text files



When using IBM Rational ClearCase, the following error occurs when attempting to check in files or add them to source control: cleartool: Error: Type manager "text_file_delta" failed create_version operation. cleartool: Error: Unable to check in "file.txt".


Possible causes include:

  • Limitations of the ClearCase text file type manager:
    • 8000 character per line limitation when performing comparison or merges.
    • Is not able to process lines that contain unprintable characters (most notably NULL characters.)
  • Text file source container corruption. While this would generally manifest itself as an error on the "construct_version" operation in the view server logs, it can occur while checking in files.

Diagnosing The Problem

Detecting files that the text_file_delta type manager cannot process

The following Perl script is an example to help detect lines with embedded binary data or long lines. To use this Perl script:
  1. Copy the code below into a text file (for example
  2. Open a command prompt.
  3. Start a view.
  4. Mount the VOB containing the files you need to examine.
  5. cd, through the above view, into the directory containing the file you need to examine.
  6. Use ccperl, or the Perl interpreter of your choice, to run the script (example ccperl



All source code and/or binaries attached to this document are referred to here as "the Program". IBM is not providing program services of any kind for the Program. IBM is providing the Program on an "AS IS" basis without warranty of any kind. IBM WILL NOT BE LIABLE FOR ANY ACTUAL, DIRECT, SPECIAL, INCIDENTAL, OR INDIRECT DAMAGES OR FOR ANY ECONOMIC CONSEQUENTIAL DAMAGES (INCLUDING LOST PROFITS OR SAVINGS), EVEN IF IBM, OR ITS RESELLER, HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

# Usage: ccperl [directory name]
# Run this script in a View/VOB context.

# Obtain a directory name from argument
if( $#ARGV < 0 ) {
    $dirname = ".";
}else {
    $dirname = shift( @ARGV );

opendir DIR, $dirname or die "Error: Cannot open dir[$dirname]\n";

print "--------- Files with hidden issues --------\n";

# Check all files on the directory
while( $fname = readdir DIR ) {

    $fname = $dirname . "\\" . $fname;

    #Skip if the file is a binary file or another directory
    if( -B $fname || -d $fname ) {

    #Check the file if it is not binary.
    open FD, $fname or next;
    $lineno = 0;
    while( <FD> ) {
        $len = (length $_) - 1;
        if( $len >= 8000 ) {
            #Report the detecte line info
            print "$fname\t: Line# $lineno\tLine Length $len characters\n";
        $nullofs = index($_,"\0");
        if ($nullofs != -1) {
            print "$fname\t: Line# $lineno\tNull at offset $nullofs\n";

When run in a directory, it will list files with issues with output similar to the following:
------------ Files with hidden issues -----------
.\foo.txt       : Line# 12      Line Length 8172 characters
.\nullme.txt    : Line# 80      Null at offset 119

Detecting corrupt text_file source containers

The most common corruption in source containers is NULL characters embedded in the container due to failed write operations. In many cases, operating system caching will hide this issue from the application until it is too late to recover from the situation.

One example of this is the "Delayed Write Failed" messages that Microsoft Windows provides when the system fails to write to storage after the application has closed the file.

ClearCase ships with a perl script -- -- that checks for null characters embedded in text_file_delta containers. The script is located in one of these locations by default:

  • Windows:
    • C:\Program Files\Rational\ClearCase\etc\utils
    • C:\Program Files[ (x86)]\IBM\RationalSDLC\ClearCase\etc\utils
  • Unix or Linux:
    • /opt/rational/clearcase/etc/utils
    • /opt/ibm/RationalSDLC/clearcase/etc/utils
    • /usr/atria/etc/utils

To use the script, run it as follows:

    {path to ccperl}\ccperl {VOB Storage Path}

Output for a clean VOB will resemble the following:

C:\Users\user1>ccperl "\Program Files (x86)\IBM\RationalSDLC\ClearCase\etc\utils\" c:\ccstg\vobs\mkvobtest.vbs
Processing tfd containers under VOB storage dir c:\ccstg\vobs\mkvobtest.vbs/s
Started at:   20 12:41:26 2013

Completed at:   20 12:41:29 2013
======= tfd container summary:
71 OK
0 with ERRORS

Any other output would indicate possible source container corruption.

Resolving The Problem

  1. File being checked in has embedded binary data or over-long lines:
    • If practical or possible, edit the file to remove the data that the ClearCase type manager will not accept.
    • If the file contents are generated from another source, or otherwise cannot be edited or modified, use a different element type.

      To change the type of an existing element, run:

      cleartool chtype {new element type} {name of file to change}.

      To force the element type for a given file when adding it to source control, the command-line "mkelem" command must be used. The command to run is:

      cleartool mkelem -eltype {type name} ... {File to add to source control}

      The most common types to use instead are:
      • xml
      • html
      • file
      • compressed_file

  2. Source container is damaged.
    To resolve issues with corrupt source containers or other corrupt data inside a ClearCase Versioned Object Base, contact IBM Rational Support and open a Problem Management Record (PMR).

[{"Product":{"code":"SSSH27","label":"Rational ClearCase"},"Business Unit":{"code":"BU004","label":"Hybrid Cloud"},"Component":"Utilities and Tools","Platform":[{"code":"PF033","label":"Windows"}],"Version":"7.0;7.0.1;7.1;7.1.1;7.1.2","Edition":""},{"Product":{"code":"SSSH27","label":"Rational ClearCase"},"Business Unit":{"code":"BU004","label":"Hybrid Cloud"},"Component":"Utilities and Tools","Platform":[{"code":"","label":""}],"Version":"","Edition":""}]

Document Information

Modified date:
29 September 2018