<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Joel Becker wrote:
<blockquote cite="mid20060720210028.GM23246@ca-server1.us.oracle.com"
 type="cite">
  <pre wrap="">On Thu, Jul 20, 2006 at 07:54:57PM +0200, Andre Brinkmann wrote:
  </pre>
  <blockquote type="cite">
    <pre wrap="">Similar to OCFS2, XFS relies on the uniqueness of a serial number. But 
with XFS, I am able to change this uid with a user space admin tool. I 
hope to find (or implement) similar features in OCFS2 to be able to 
support snapshots. I think the possibility to change the uuid is import 
for most storage system. Even hardware RAIDs with integrated snapshots 
will have similar problems.
    </pre>
  </blockquote>
  <pre wrap=""><!---->
        I find it interesting that you use a modification of the uuid to
handle snapshotting.  Certainly would work for a snapshot of
OCFS2...however, it's also dangerous.  Two OCFS2 nodes absolutely rely
on the uuid to ensure they are heartbeating for the same thing.  So we
cannot safely change the uuid if there is any chance another node is
running on the filesystem (let alone our own node :-).
        Now, your snapshot won't be mounted anywhere, sure, but our
tools won't know a snapshot vs a live filesystem, and will need to make
sure.  That just requires some locking.
        So, I think it is something we can look into as a feature for
tunefs.ocfs2, but it isn't a one-liner and requires some correctness.
        Would you prefer to _set_ the uuid, or just generate a new one?
I'd personally go with the latter (all it needs to do is differ from the
non-snapshot volume), but I wanted to ask your opinion.

Joel

  </pre>
</blockquote>
Hello Joel,<br>
<br>
in my opinion, it is ok to let tunefs change the uuid of a volume.
Normally this is done inside a script-chain and <br>
the scripts should know what they are doing. Furthermore, it seems that
the security mechanisms inside <br>
tunefs ensure that changes to mounted devices are not possible, if the
cluster is online. <br>
<br>
I agree with you that it makes no sense to let the user guess a uuid
and that tunefs should just generate a new<br>
one. I have played around with your tools to get a better understanding
of your tools and ocfs2 and I have created<br>
a patch for the uuid. I have tried to program according to your coding
style.<br>
<br>
After applying the patches for the Makefile in tunefs.ocfs and for
tunefs.c itself, you can generate a new uuid <br>
by setting the -u or the --uuid-reset flag. The uuid is generated
according to the method in mkfs.c . <br>
<br>
After applying the patch, it has been possible to generate snapshots of
ocfs2-volumes in a two node cluster<br>
without any difficulties.<br>
<br>
Best Regards<br>
<br>
Andre<br>
<br>
<br>
</body>
</html>