ClearCase Folder Hard Links.

257 views
Skip to first unread message

Vijay

unread,
Aug 19, 2009, 8:03:24 AM8/19/09
to ClearCase
I have faced the following issue in my ClearCase practice.

Normally we cannot create hard link for the folders in the ClearCase.
But in my case the one of the folder with its sub directory is present
in two folders in the same VOB. If I checkout/add new element will be
reflected in other folder also.

For Further Details:
http://netbytez.blogspot.com/

Tamir Gefen

unread,
Aug 19, 2009, 8:16:13 AM8/19/09
to Vijay, ClearCase
Do you really need hard links? Sometimes it might be a pitfall... I think that soft links are much better in most cases.

Tamir
GoMidjets

VIJAY GANESH.M

unread,
Aug 19, 2009, 8:25:08 AM8/19/09
to Tamir Gefen, ClearCase
Here I have not created this hard links, But due to the bug explained has created the hard links
--
THANKS AND REGARDS

M.VIJAY GANESH
m.vija...@gmail.com
m_vija...@yahoo.co.in
http://netbytez.blogspot.com

Marc Girod

unread,
Aug 22, 2009, 5:20:24 AM8/22/09
to ClearCase
On Aug 19, 1:25 pm, "VIJAY GANESH.M" <m.vijaygan...@gmail.com> wrote:
> Here I have not created this hard links, But due to the bug explained has
> created the hard links

So, what is your question?

Hard links exist, and have their use.
Soft links are completely different and
most of the time, cannot serve the needs
for hard links.

If you want to remove the hard link,
checkout and rmname.
The other hardlink (entry in the directory)
will not disappear.

If you want to create hard links to directories
(and again, there are valid reasons for
wanting that), you cannot do it with the 'ln'
command (which explicitly disallows it,
following a unix tradition).
So, the way to do it, is to checkout, in
addition to your target directory, the source
directory, to use 'mv', and to uncheckout the
source (and checkin the target if you are
happy).

The reason for which unix disallows the
hardlinking of directories is the prevention
of cycles in file systems. They are known
as a way to achieve corruption.
One example of related problems can be
found by running 'find' from /view. Do not
make changes.

In ClearCase, hardlinks are a weapon to
deal with evil twins.
There can especially be used to maintain
third party distributions which hardcode
version information into names, in a
ClearCase friendly way.
They can also offer support for
(temporarily) accessing several versions
of some elements in the same view.

Marc
Reply all
Reply to author
Forward
0 new messages