<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    I am trying to record all ACL related updates to a particular inode
    on an ext3 file system. <br>
    <br>
    <b>Question:</b><br>
    <ul>
      <li>Is ext3_set_acl() the best entry point to trace from? </li>
    </ul>
    <br>
    I wrote the following trivial system tap script, in an attempt to
    capture this information:<br>
    <br>
    #!/usr/bin/stap<br>
    /*<br>
    * Aggregate calls to ext3_set_acl() for a particular inode number<br>
    * Purpose:<br>
    *  - Track ACL modifications to an ext3 inode<br>
    */<br>
    global check_count;<br>
    global inode_num = 0;<br>
    <br>
    probe module("ext3").function("ext3_set_acl") {<br>
            inode_num = $1;<br>
            if ($inode->i_ino == $1) {<br>
                    printf ("execname: %s, pid: %d, inode num: %d\n",
    execname(), pid(), $inode->i_ino);<br>
                    /*check_count++; */<br>
                    check_count[execname()] <<< 1;<br>
            }<br>
    }<br>
    <br>
    probe end {<br>
                    printf ("Calls to ext3_set_acl():\n");<br>
            foreach ([exec] in check_count-) {<br>
                    printf ("%s operated %d times on inode %d\n", exec,
    @count(check_count[exec]), inode_num);<br>
            }<br>
            delete check_count;<br>
            delete inode_num;<br>
    }<br>
    <br>
    Thanks in advance,<br>
    <pre class="moz-signature" cols="72">-- 
Aaron Tomlin</pre>
  </body>
</html>