Question & Answer
Question
What is the required procedure for removing change set versions of an IBM Rational ClearCase UCM activity in the command line interface? This technote steps through the required cleartool sub-commands for removing change set versions from a ClearCase UCM activity.
Answer
Important Considerations
] The following procedure is used to remove checked in versions from the change set of a UCM activity using command line syntax. Note: For any checked out version listed in the change set, cancel the checkout and the version will no longer appear in the change set list. Removing checked in versions should be done with discretion and under conditions that warrant such action. For example, instances where a deliver or rebase fails leaving checked in versions which are preventing the operation from being canceled as detailed in technote 1125189 and technote 1179696. When removing versions as a result of a failed rebase, then the checked in versions will be listed on the development stream, and vice-versa when removing versions as the result of a failed deliver operation (the checked in versions will be listed on the target stream). This is important because this procedure requires that the checked in versions be removed from a UCM stream. You need to know specifically what stream the change set versions are on to be sure and remove the correct ones. Note: Merge hyperlinks are removed from the source to the target version that was created as a result of a deliver or rebase operation; hence, there are no dangling hyperlinks left to cleanup, such as detailed in technote 1117462. File versions should be removed before removing the versions of directory elements. This will help avoid stranding any elements and causing them to get put into the lost+found; refer to technote 1120317 for more details. The following command is used to remove change set information: cleartool rmver -xbranch -xlabel -xattr -xhlinkRemoving Checked In Versions
- Set into a UCM view attached to the stream that the activity is associated with and list of the available activities:
M:\prj1_dev_vu2>cleartool lsact
02-Jun-06.14:59:50 rebase.prj1_dev.20060602.145948 administrator "rebase prj1_dev on 6/2/2006 2:59:48 PM."
08-Jun-06.08:58:29 test_activity administrator "test_activity"
08-Jun-06.09:24:53 rebase.prj1_dev.20060608.092451 administrator "rebase prj1_dev on 6/8/2006 9:24:51 AM."
08-Jun-06.12:03:38 rebase.prj1_dev.20060608.120336 administrator "rebase prj1_dev on 6/8/2006 12:03:36 PM."
- List out the properties of the activity to display the change set versions:
M:\prj1_dev_vu2>cleartool lsact -l test_activity
activity "test_activity"
08-Jun-06.08:58:29 by administrator.None@IBM-8D5F4F33A08
master replica: original@\PVOB1
owner: IBM-8D5F4F33A08\administrator
group: IBM-8D5F4F33A08\None
stream: prj1_dev@\PVOB1
title: test_activity
change set versions:
M:\prj1_dev_vu2\multivob\comp1\test1.txt@@\main\prj1_dev\4
M:\prj1_dev_vu2\multivob\comp1\test1.txt@@\main\prj1_dev\3
M:\prj1_dev_vu2\multivob\comp1\test1.txt@@\main\prj1_dev\2
M:\prj1_dev_vu2\multivob\comp1@@\main\prj1_dev\4
M:\prj1_dev_vu2\multivob\comp1\test1.txt@@\main\prj1_dev\1
- Remove the first file element version in the change set:
M:\prj1_dev_vu2>cleartool rmver -xbranch -xlabel -xattr -xhlink M:\prj1_dev_vu2\multivob\comp1\test1.txt@@\main\prj1_dev\4
- You will be prompted with the following message > review the message > then type or click Yes to proceed:
- On UNIX and Linux:
Removing these versions of "M:\prj1_dev_vu2\multivob\comp1\test.txt":
\main\prj1_dev\4 [has: hyperlinks]
Remove versions? [no]
- On Windows:
- A message will be returned to indicate that the version was removed:
Removed versions of "M:\prj1_dev_vu2\multivob\comp1\test1.txt".
Note: If there are multiple versions listed for a file element, as seen in the above cleartool lsact -l output, then you will need to remove each of them. The order in which they are removed is insignificant, you can remove version 1 first or last. Then proceed with removing the directory element versions.
- After removing all versions from the change set of the activity, it can be removed:
M:\prj1_dev_vu2>cleartool rmact -force test_activity
Removed activity "test_activity".
Note: An error will occur if either of the following are true: - The activity change set is not empty:
M:\prj1_dev_vu2>cleartool rmact -force test_activity
cleartool: Error: Cannot remove an activity with versions in its change set.
cleartool: Error: Unable to remove activity "test_activity".
- The activity is still set in a UCM view:
M:\prj1_dev_vu2>cleartool rmact -force test_activity
cleartool: Error: Activity "activity:test_activity@\PVOB1" is set in view "prj1_dev_vu2".
cleartool: Error: Unable to remove activity "test_activity".
[{"Product":{"code":"SSSH27","label":"Rational ClearCase"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"UCM: Activity","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF015","label":"IRIX"},{"code":"PF016","label":"Linux"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"2002.05.00;2003.06.00;7.0","Edition":"","Line of Business":{"code":"LOB45","label":"Automation"}},{"Product":{"code":"SSSH27","label":"Rational ClearCase"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"UCM: Activity","Platform":[{"code":"","label":""}],"Version":"","Edition":"","Line of Business":{"code":"LOB45","label":"Automation"}}]
Was this topic helpful?
Document Information
Modified date:
16 June 2018
UID
swg21134544