<div dir="ltr"><div class="gmail_extra"><div><div>On Sat, Mar 23, 2013 at 9:08 AM, Brian Foster <span dir="ltr">&lt;<a href="mailto:bfoster@redhat.com" target="_blank">bfoster@redhat.com</a>&gt;</span> wrote:<br></div></div>

<div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div class="im">On 03/22/2013 05:11 PM, Patrick Regan wrote:<br>


&gt; I have a 8-node 2 replica Gluster volume mounted with the fuse client.<br>
&gt; We also have an in-house Perl script we use for doing block string<br>
&gt; substitutions. If we run this script on directories on the volume, I<br>
&gt; get the following error on almost every file:<br>
&gt;<br>
&gt; cp: skipping file $FILEPATH as it was replaced while being copied<br>
&gt;<br>
<br>
</div>That error is preceded with the following comment in coreutils:<br>
<br>
  /* Compare the source dev/ino from the open file to the incoming,<br>
     saved ones obtained via a previous call to stat.  */<br>
<br>
... which basically means the source inode has changed between the time<br>
this particular function runs a stat on the source path and some<br>
previous call had run the same thing. Had you confirmed which cp command<br>
in your script results in this error (e.g., it looks like you have a cp<br>
to temp and a cp to orig)?<br></blockquote><div><br></div><div style>Actually both cp&#39;s cause the error to occur. Both the copy to the temp, and the copy from the temp to the original.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">


<br>
I know nothing about perl (and the lack of indentation in the script<br>
post is making my eyes cross :P), but have you thought about the level<br>
of serialization you&#39;re getting in the perl script between the cp<br>
commands and programmatic file access? In other words, is it possible<br>
the work your script invokes via print and `` operators is racing with<br>
the script itself?<br></blockquote><div><br></div><div style>My apologies for the lack of indentation. I should have known whitespace would have gotten stripped. Here are links to both the perl and the shell scripts:</div>

<div style><br></div><div style><a href="http://pastebin.com/Q9mxSjS0">http://pastebin.com/Q9mxSjS0</a>  - Perl<br></div><div style><a href="http://pastebin.com/RaS3cxQa">http://pastebin.com/RaS3cxQa</a>  - Bash</div><div style>

<br></div><div style>I too am not that much of a Perl expert, so I&#39;ll ask a few of my developers here. I&#39;ll report back with anything else I can find.</div><div style><br></div><div style>Even if it was a race condition, why does it happen with the FUSE client, but not NFS?</div>

<div style><br></div><div style>Thanks,</div><div style>Pat</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">


<br>
Brian<br>
<div><div class="h5"><br>
&gt; If I mount the volume with NFS, this issue does not arise.<br>
&gt;<br>
&gt; I have also tried to replicate the issue using a roughly equivalent<br>
&gt; shell script, but the shell script does not produce the same result on<br>
&gt; either the fuse or the nfs client.<br>
&gt;<br>
&gt; I&#39;ll paste my volume log followed by the perl script, followed by my<br>
&gt; rough shell script.<br>
&gt;<br>
&gt; I would appreciate any feedback.<br>
&gt;<br>
&gt; Thanks!<br>
&gt;<br>
&gt; -------------<br>
&gt;<br>
&gt; [2013-03-22 16:32:52.893362] I [glusterfsd.c:1666:main]<br>
&gt; 0-/usr/sbin/glusterfs: Started running /usr/sbin/glusterfs version<br>
&gt; 3.3.1<br>
&gt; [2013-03-22 16:32:52.932157] I [io-cache.c:1549:check_cache_size_ok]<br>
&gt; 0-usrweb-quick-read: Max cache size is 2124763136<br>
&gt; [2013-03-22 16:32:52.932634] I [io-cache.c:1549:check_cache_size_ok]<br>
&gt; 0-usrweb-io-cache: Max cache size is 2124763136<br>
&gt; [2013-03-22 16:32:53.035759] I [client.c:2142:notify]<br>
&gt; 0-usrweb-client-0: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; [2013-03-22 16:32:53.041228] I [client.c:2142:notify]<br>
&gt; 0-usrweb-client-1: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; [2013-03-22 16:32:53.046270] I [client.c:2142:notify]<br>
&gt; 0-usrweb-client-2: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; [2013-03-22 16:32:53.050863] I [client.c:2142:notify]<br>
&gt; 0-usrweb-client-3: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; Given volfile:<br>
&gt; +------------------------------------------------------------------------------+<br>
&gt;   1: volume usrweb-client-0<br>
&gt;   2:     type protocol/client<br>
&gt;   3:     option remote-host ak001<br>
&gt;   4:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;   5:     option transport-type tcp<br>
&gt;   6: end-volume<br>
&gt;   7:<br>
&gt;   8: volume usrweb-client-1<br>
&gt;   9:     type protocol/client<br>
&gt;  10:     option remote-host ak002<br>
&gt;  11:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;  12:     option transport-type tcp<br>
&gt;  13: end-volume<br>
&gt;  14:<br>
&gt;  15: volume usrweb-client-2<br>
&gt;  16:     type protocol/client<br>
&gt;  17:     option remote-host ak003<br>
&gt;  18:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;  19:     option transport-type tcp<br>
&gt;  20: end-volume<br>
&gt;  21:<br>
&gt;  22: volume usrweb-client-3<br>
&gt;  23:     type protocol/client<br>
&gt;  24:     option remote-host ak004<br>
&gt;  25:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;  26:     option transport-type tcp<br>
&gt;  27: end-volume<br>
&gt;  28:<br>
&gt;  29: volume usrweb-replicate-0<br>
&gt;  30:     type cluster/replicate<br>
&gt;  31:     subvolumes usrweb-client-0 usrweb-client-1<br>
&gt;  32: end-volume<br>
&gt;  33:<br>
&gt;  34: volume usrweb-replicate-1<br>
&gt;  35:     type cluster/replicate<br>
&gt;  36:     subvolumes usrweb-client-2 usrweb-client-3<br>
&gt;  37: end-volume<br>
&gt;  38:<br>
&gt;  39: volume usrweb-dht<br>
&gt;  40:     type cluster/distribute<br>
&gt;  41:     subvolumes usrweb-replicate-0 usrweb-replicate-1<br>
&gt;  42: end-volume<br>
&gt;  43:<br>
&gt;  44: volume usrweb-write-behind<br>
&gt;  45:     type performance/write-behind<br>
&gt;  46:     subvolumes usrweb-dht<br>
&gt;  47: end-volume<br>
&gt;  48:<br>
&gt;  49: volume usrweb-read-ahead<br>
&gt;  50:     type performance/read-ahead<br>
&gt;  51:     subvolumes usrweb-write-behind<br>
&gt;  52: end-volume<br>
&gt;  53:<br>
&gt;  54: volume usrweb-io-cache<br>
&gt;  55:     type performance/io-cache<br>
&gt;  56:     subvolumes usrweb-read-ahead<br>
&gt;  57: end-volume<br>
&gt;  58:<br>
&gt;  59: volume usrweb-quick-read<br>
&gt;  60:     type performance/quick-read<br>
&gt;  61:     subvolumes usrweb-io-cache<br>
&gt;  62: end-volume<br>
&gt;  63:<br>
&gt;  64: volume usrweb-md-cache<br>
&gt;  65:     type performance/md-cache<br>
&gt;  66:     subvolumes usrweb-quick-read<br>
&gt;  67: end-volume<br>
&gt;  68:<br>
&gt;  69: volume usrweb<br>
&gt;  70:     type debug/io-stats<br>
&gt;  71:     option latency-measurement off<br>
&gt;  72:     option count-fop-hits off<br>
&gt;  73:     subvolumes usrweb-md-cache<br>
&gt;  74: end-volume<br>
&gt;<br>
&gt; +------------------------------------------------------------------------------+<br>
&gt; [2013-03-22 16:32:53.057710] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 0-usrweb-client-2: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:32:53.057895] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 0-usrweb-client-1: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:32:53.058025] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 0-usrweb-client-0: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:32:53.059259] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 0-usrweb-client-3: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:32:56.933277] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 0-usrweb-client-2: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:32:56.933966] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 0-usrweb-client-2:<br>
&gt; Connected to <a href="http://10.0.8.242:24010" target="_blank">10.0.8.242:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:32:56.934012] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 0-usrweb-client-2:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:32:56.934161] I [afr-common.c:3628:afr_notify]<br>
&gt; 0-usrweb-replicate-1: Subvolume &#39;usrweb-client-2&#39; came back up; going<br>
&gt; online.<br>
&gt; [2013-03-22 16:32:56.934400] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 0-usrweb-client-2:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:32:56.938890] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 0-usrweb-client-1: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:32:56.939504] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 0-usrweb-client-1:<br>
&gt; Connected to <a href="http://10.0.8.241:24010" target="_blank">10.0.8.241:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:32:56.939553] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 0-usrweb-client-1:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:32:56.939685] I [afr-common.c:3628:afr_notify]<br>
&gt; 0-usrweb-replicate-0: Subvolume &#39;usrweb-client-1&#39; came back up; going<br>
&gt; online.<br>
&gt; [2013-03-22 16:32:56.939940] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 0-usrweb-client-1:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:32:56.944004] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 0-usrweb-client-0: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:32:56.944408] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 0-usrweb-client-0:<br>
&gt; Connected to <a href="http://10.0.8.240:24010" target="_blank">10.0.8.240:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:32:56.944502] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 0-usrweb-client-0:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:32:56.945219] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 0-usrweb-client-0:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:32:56.949911] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 0-usrweb-client-3: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:32:56.950480] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 0-usrweb-client-3:<br>
&gt; Connected to <a href="http://10.0.8.243:24010" target="_blank">10.0.8.243:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:32:56.950524] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 0-usrweb-client-3:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:32:56.998230] I [fuse-bridge.c:4191:fuse_graph_setup]<br>
&gt; 0-fuse: switched to graph 0<br>
&gt; [2013-03-22 16:32:56.998706] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 0-usrweb-client-3:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:32:56.999145] I [fuse-bridge.c:3376:fuse_init]<br>
&gt; 0-glusterfs-fuse: FUSE inited with protocol versions: glusterfs 7.13<br>
&gt; kernel 7.10<br>
&gt; [2013-03-22 16:32:57.000718] I<br>
&gt; [afr-common.c:1965:afr_set_root_inode_on_first_lookup]<br>
&gt; 0-usrweb-replicate-0: added root inode<br>
&gt; [2013-03-22 16:32:57.001914] I<br>
&gt; [afr-common.c:1965:afr_set_root_inode_on_first_lookup]<br>
&gt; 0-usrweb-replicate-1: added root inode<br>
&gt; [2013-03-22 16:42:00.074968] I [glusterfsd-mgmt.c:65:mgmt_cbk_spec]<br>
&gt; 0-mgmt: Volume file changed<br>
&gt; [2013-03-22 16:42:02.114686] I [io-cache.c:1549:check_cache_size_ok]<br>
&gt; 1-usrweb-quick-read: Max cache size is 2124763136<br>
&gt; [2013-03-22 16:42:02.114945] I [io-cache.c:1549:check_cache_size_ok]<br>
&gt; 1-usrweb-io-cache: Max cache size is 2124763136<br>
&gt; [2013-03-22 16:42:02.265593] I [client.c:2142:notify]<br>
&gt; 1-usrweb-client-0: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; [2013-03-22 16:42:02.270654] I [client.c:2142:notify]<br>
&gt; 1-usrweb-client-1: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; [2013-03-22 16:42:02.275012] I [client.c:2142:notify]<br>
&gt; 1-usrweb-client-2: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; [2013-03-22 16:42:02.279133] I [client.c:2142:notify]<br>
&gt; 1-usrweb-client-3: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; [2013-03-22 16:42:02.283267] I [client.c:2142:notify]<br>
&gt; 1-usrweb-client-4: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; [2013-03-22 16:42:02.287310] I [client.c:2142:notify]<br>
&gt; 1-usrweb-client-5: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; [2013-03-22 16:42:02.291472] I [client.c:2142:notify]<br>
&gt; 1-usrweb-client-6: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; [2013-03-22 16:42:02.295771] I [client.c:2142:notify]<br>
&gt; 1-usrweb-client-7: parent translators are ready, attempting connect on<br>
&gt; transport<br>
&gt; Given volfile:<br>
&gt; +------------------------------------------------------------------------------+<br>
&gt;   1: volume usrweb-client-0<br>
&gt;   2:     type protocol/client<br>
&gt;   3:     option remote-host ak001<br>
&gt;   4:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;   5:     option transport-type tcp<br>
&gt;   6: end-volume<br>
&gt;   7:<br>
&gt;   8: volume usrweb-client-1<br>
&gt;   9:     type protocol/client<br>
&gt;  10:     option remote-host ak002<br>
&gt;  11:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;  12:     option transport-type tcp<br>
&gt;  13: end-volume<br>
&gt;  14:<br>
&gt;  15: volume usrweb-client-2<br>
&gt;  16:     type protocol/client<br>
&gt;  17:     option remote-host ak003<br>
&gt;  18:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;  19:     option transport-type tcp<br>
&gt;  20: end-volume<br>
&gt;  21:<br>
&gt;  22: volume usrweb-client-3<br>
&gt;  23:     type protocol/client<br>
&gt;  24:     option remote-host ak004<br>
&gt;  25:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;  26:     option transport-type tcp<br>
&gt;  27: end-volume<br>
&gt;  28:<br>
&gt;  29: volume usrweb-client-4<br>
&gt;  30:     type protocol/client<br>
&gt;  31:     option remote-host ak005<br>
&gt;  32:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;  33:     option transport-type tcp<br>
&gt;  34: end-volume<br>
&gt;  35:<br>
&gt;  36: volume usrweb-client-5<br>
&gt;  37:     type protocol/client<br>
&gt;  38:     option remote-host ak006<br>
&gt;  39:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;  40:     option transport-type tcp<br>
&gt;  41: end-volume<br>
&gt;  42:<br>
&gt;  43: volume usrweb-client-6<br>
&gt;  44:     type protocol/client<br>
&gt;  45:     option remote-host ak007<br>
&gt;  46:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;  47:     option transport-type tcp<br>
&gt;  48: end-volume<br>
&gt;  49:<br>
&gt;  50: volume usrweb-client-7<br>
&gt;  51:     type protocol/client<br>
&gt;  52:     option remote-host ak008<br>
&gt;  53:     option remote-subvolume /srv/gluster/volusrweb<br>
&gt;  54:     option transport-type tcp<br>
&gt;  55: end-volume<br>
&gt;  56:<br>
&gt;  57: volume usrweb-replicate-0<br>
&gt;  58:     type cluster/replicate<br>
&gt;  59:     subvolumes usrweb-client-0 usrweb-client-1<br>
&gt;  60: end-volume<br>
&gt;  61:<br>
&gt;  62: volume usrweb-replicate-1<br>
&gt;  63:     type cluster/replicate<br>
&gt;  64:     subvolumes usrweb-client-2 usrweb-client-3<br>
&gt;  65: end-volume<br>
&gt;  66:<br>
&gt;  67: volume usrweb-replicate-2<br>
&gt;  68:     type cluster/replicate<br>
&gt;  69:     subvolumes usrweb-client-4 usrweb-client-5<br>
&gt;  70: end-volume<br>
&gt;  71:<br>
&gt;  72: volume usrweb-replicate-3<br>
&gt;  73:     type cluster/replicate<br>
&gt;  74:     subvolumes usrweb-client-6 usrweb-client-7<br>
&gt;  75: end-volume<br>
&gt;  76:<br>
&gt;  77: volume usrweb-dht<br>
&gt;  78:     type cluster/distribute<br>
&gt;  79:     subvolumes usrweb-replicate-0 usrweb-replicate-1<br>
&gt; usrweb-replicate-2 usrweb-replicate-3<br>
&gt;  80: end-volume<br>
&gt;  81:<br>
&gt;  82: volume usrweb-write-behind<br>
&gt;  83:     type performance/write-behind<br>
&gt;  84:     subvolumes usrweb-dht<br>
&gt;  85: end-volume<br>
&gt;  86:<br>
&gt;  87: volume usrweb-read-ahead<br>
&gt;  88:     type performance/read-ahead<br>
&gt;  89:     subvolumes usrweb-write-behind<br>
&gt;  90: end-volume<br>
&gt;  91:<br>
&gt;  92: volume usrweb-io-cache<br>
&gt;  93:     type performance/io-cache<br>
&gt;  94:     subvolumes usrweb-read-ahead<br>
&gt;  95: end-volume<br>
&gt;  96:<br>
&gt;  97: volume usrweb-quick-read<br>
&gt;  98:     type performance/quick-read<br>
&gt;  99:     subvolumes usrweb-io-cache<br>
&gt; 100: end-volume<br>
&gt; 101:<br>
&gt; 102: volume usrweb-md-cache<br>
&gt; 103:     type performance/md-cache<br>
&gt; 104:     subvolumes usrweb-quick-read<br>
&gt; 105: end-volume<br>
&gt; 106:<br>
&gt; 107: volume usrweb<br>
&gt; 108:     type debug/io-stats<br>
&gt; 109:     option latency-measurement off<br>
&gt; 110:     option count-fop-hits off<br>
&gt; 111:     subvolumes usrweb-md-cache<br>
&gt; 112: end-volume<br>
&gt;<br>
&gt; +------------------------------------------------------------------------------+<br>
&gt; [2013-03-22 16:42:02.301090] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 1-usrweb-client-0: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:42:04.158794] E<br>
&gt; [client-handshake.c:1717:client_query_portmap_cbk] 1-usrweb-client-5:<br>
&gt; failed to get the port number for remote subvolume<br>
&gt; [2013-03-22 16:42:04.159003] I [client.c:2090:client_rpc_notify]<br>
&gt; 1-usrweb-client-5: disconnected<br>
&gt; [2013-03-22 16:42:04.159074] E<br>
&gt; [client-handshake.c:1717:client_query_portmap_cbk] 1-usrweb-client-7:<br>
&gt; failed to get the port number for remote subvolume<br>
&gt; [2013-03-22 16:42:04.159223] I [client.c:2090:client_rpc_notify]<br>
&gt; 1-usrweb-client-7: disconnected<br>
&gt; [2013-03-22 16:42:04.161765] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 1-usrweb-client-3: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:42:04.161868] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 1-usrweb-client-2: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:42:04.162355] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 1-usrweb-client-1: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:42:04.162449] E<br>
&gt; [client-handshake.c:1717:client_query_portmap_cbk] 1-usrweb-client-6:<br>
&gt; failed to get the port number for remote subvolume<br>
&gt; [2013-03-22 16:42:04.162529] E<br>
&gt; [client-handshake.c:1717:client_query_portmap_cbk] 1-usrweb-client-4:<br>
&gt; failed to get the port number for remote subvolume<br>
&gt; [2013-03-22 16:42:04.162625] I [client.c:2090:client_rpc_notify]<br>
&gt; 1-usrweb-client-4: disconnected<br>
&gt; [2013-03-22 16:42:04.162708] E [afr-common.c:3665:afr_notify]<br>
&gt; 1-usrweb-replicate-2: All subvolumes are down. Going offline until<br>
&gt; atleast one of them comes back up.<br>
&gt; [2013-03-22 16:42:04.162765] I [client.c:2090:client_rpc_notify]<br>
&gt; 1-usrweb-client-6: disconnected<br>
&gt; [2013-03-22 16:42:04.162805] E [afr-common.c:3665:afr_notify]<br>
&gt; 1-usrweb-replicate-3: All subvolumes are down. Going offline until<br>
&gt; atleast one of them comes back up.<br>
&gt; [2013-03-22 16:42:05.715027] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 1-usrweb-client-0: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:42:05.715447] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 1-usrweb-client-0:<br>
&gt; Connected to <a href="http://10.0.8.240:24010" target="_blank">10.0.8.240:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:42:05.715501] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 1-usrweb-client-0:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:42:05.715767] I [afr-common.c:3628:afr_notify]<br>
&gt; 1-usrweb-replicate-0: Subvolume &#39;usrweb-client-0&#39; came back up; going<br>
&gt; online.<br>
&gt; [2013-03-22 16:42:05.715836] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 1-usrweb-client-0:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:42:07.722528] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 1-usrweb-client-5: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:42:07.727863] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 1-usrweb-client-7: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:42:07.732813] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 1-usrweb-client-3: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:42:07.733314] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 1-usrweb-client-3:<br>
&gt; Connected to <a href="http://10.0.8.243:24010" target="_blank">10.0.8.243:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:42:07.733358] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 1-usrweb-client-3:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:42:07.733524] I [afr-common.c:3628:afr_notify]<br>
&gt; 1-usrweb-replicate-1: Subvolume &#39;usrweb-client-3&#39; came back up; going<br>
&gt; online.<br>
&gt; [2013-03-22 16:42:07.733731] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 1-usrweb-client-3:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:42:07.738423] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 1-usrweb-client-2: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:42:07.738819] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 1-usrweb-client-2:<br>
&gt; Connected to <a href="http://10.0.8.242:24010" target="_blank">10.0.8.242:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:42:07.738860] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 1-usrweb-client-2:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:42:07.739276] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 1-usrweb-client-2:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:42:07.744321] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 1-usrweb-client-1: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:42:07.744874] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 1-usrweb-client-1:<br>
&gt; Connected to <a href="http://10.0.8.241:24010" target="_blank">10.0.8.241:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:42:07.744916] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 1-usrweb-client-1:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:42:07.798486] I [fuse-bridge.c:4191:fuse_graph_setup]<br>
&gt; 0-fuse: switched to graph 1<br>
&gt; [2013-03-22 16:42:07.799081] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 1-usrweb-client-1:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:42:07.799444] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 1-usrweb-client-6: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:42:07.799591] I [rpc-clnt.c:1657:rpc_clnt_reconfig]<br>
&gt; 1-usrweb-client-4: changing port to 24010 (from 0)<br>
&gt; [2013-03-22 16:42:10.771491] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 1-usrweb-client-5: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:42:10.776211] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 1-usrweb-client-5:<br>
&gt; Connected to <a href="http://10.0.8.245:24010" target="_blank">10.0.8.245:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:42:10.776323] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 1-usrweb-client-5:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:42:10.776500] I [afr-common.c:3628:afr_notify]<br>
&gt; 1-usrweb-replicate-2: Subvolume &#39;usrweb-client-5&#39; came back up; going<br>
&gt; online.<br>
&gt; [2013-03-22 16:42:10.776836] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 1-usrweb-client-5:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:42:10.777113] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 1-usrweb-client-7: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:42:10.777615] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 1-usrweb-client-7:<br>
&gt; Connected to <a href="http://10.0.8.247:24010" target="_blank">10.0.8.247:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:42:10.777676] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 1-usrweb-client-7:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:42:10.777866] I [afr-common.c:3628:afr_notify]<br>
&gt; 1-usrweb-replicate-3: Subvolume &#39;usrweb-client-7&#39; came back up; going<br>
&gt; online.<br>
&gt; [2013-03-22 16:42:10.778129] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 1-usrweb-client-7:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:42:11.784150] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 1-usrweb-client-6: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:42:11.787025] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 1-usrweb-client-6:<br>
&gt; Connected to <a href="http://10.0.8.246:24010" target="_blank">10.0.8.246:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:42:11.787141] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 1-usrweb-client-6:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:42:11.788193] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 1-usrweb-client-6:<br>
&gt; Server lk version = 1<br>
&gt; [2013-03-22 16:42:11.789908] I<br>
&gt; [client-handshake.c:1636:select_server_supported_programs]<br>
&gt; 1-usrweb-client-4: Using Program GlusterFS 3.3.1, Num (1298437),<br>
&gt; Version (330)<br>
&gt; [2013-03-22 16:42:11.790334] I<br>
&gt; [client-handshake.c:1433:client_setvolume_cbk] 1-usrweb-client-4:<br>
&gt; Connected to <a href="http://10.0.8.244:24010" target="_blank">10.0.8.244:24010</a>, attached to remote volume<br>
&gt; &#39;/srv/gluster/volusrweb&#39;.<br>
&gt; [2013-03-22 16:42:11.790398] I<br>
&gt; [client-handshake.c:1445:client_setvolume_cbk] 1-usrweb-client-4:<br>
&gt; Server and Client lk-version numbers are not same, reopening the fds<br>
&gt; [2013-03-22 16:42:11.790726] I<br>
&gt; [client-handshake.c:453:client_set_lk_version_cbk] 1-usrweb-client-4:<br>
&gt; Server lk version = 1<br>
&gt;<br>
&gt; ------------------------------<br>
&gt;<br>
&gt; #!/usr/bin/perl<br>
&gt;<br>
&gt; open(FIND, &quot;find . -print |&quot;) || die &quot;Coundn&#39;t run find: $!\n&quot;;<br>
&gt;<br>
&gt; $counter = 0;<br>
&gt; FILE:<br>
&gt; while ($filename = &lt;FIND&gt;)<br>
&gt; {<br>
&gt; chop $filename;<br>
&gt; next FILE unless -T$filename;<br>
&gt; if(!open(TEXTFILE, &quot;$filename&quot;))<br>
&gt; {<br>
&gt; print STDERR &quot;Can&#39;t open $filename - continuing...\n&quot;;<br>
&gt; next FILE;<br>
&gt; }<br>
&gt; while (&lt;TEXTFILE&gt;)<br>
&gt; {<br>
&gt; $tempfile[$counter] = $_;<br>
&gt; $counter = $counter + 1;<br>
&gt; if (index($tempfile[$counter - 1],$ARGV[0]) &gt;= 0)<br>
&gt; {<br>
&gt; $totalchanges = $totalchanges +1;<br>
&gt; $dummy=`cp -p $filename blocktemp.txt\n`;<br>
&gt; print $dummy;<br>
&gt; print &quot;$filename\n&quot;;<br>
&gt; open(TEMPFILE, &quot;&gt; blocktemp.txt&quot;);<br>
&gt; $tempfile[$counter -1] =~ s/$ARGV[0]/$ARGV[1]/g;<br>
&gt; for($i = 0; $i &lt; $counter; $i++)<br>
&gt; {<br>
&gt; print TEMPFILE &quot;$tempfile[$i]&quot;;<br>
&gt; }<br>
&gt; while (&lt;TEXTFILE&gt;)<br>
&gt; {<br>
&gt; $storage = $_;<br>
&gt; if (index($storage,$ARGV[0]) &gt;= 0)<br>
&gt; {<br>
&gt; $storage =~ s/$ARGV[0]/$ARGV[1]/g;<br>
&gt; $totalchanges = $totalchanges +1;<br>
&gt; }<br>
&gt; print TEMPFILE &quot;$storage&quot;;<br>
&gt; }<br>
&gt; close(TEXTFILE);<br>
&gt; close(TEMPFILE);<br>
&gt; $dummy2=`cp -p blocktemp.txt $filename`;<br>
&gt; print $dummy2;<br>
&gt; $dummy3=`rm blocktemp.txt`;<br>
&gt; print $dummy3;<br>
&gt; }<br>
&gt; }<br>
&gt; close(TEXTFILE);<br>
&gt; $counter = 0;<br>
&gt; }<br>
&gt; print &quot;$totalchanges lines changed\n&quot;;<br>
&gt;<br>
&gt; ---------------------------<br>
&gt;<br>
&gt; #!/bin/bash<br>
&gt;<br>
&gt; FILES=$(find . -type f)<br>
&gt;<br>
&gt; for f in $FILES<br>
&gt; do<br>
&gt; cp -p $f tempfile.tmp<br>
&gt; sed -i &quot;s/$1/$2/g&quot; tempfile.tmp<br>
&gt; cp -p tempfile.tmp $f<br>
&gt; rm tempfile.tmp<br>
&gt; done<br>
&gt;<br>
&gt; --<br>
&gt; Patrick Regan<br>
</div></div>&gt; _______________________________________________<br>
&gt; Gluster-users mailing list<br>
&gt; <a href="mailto:Gluster-users@gluster.org">Gluster-users@gluster.org</a><br>
&gt; <a href="http://supercolony.gluster.org/mailman/listinfo/gluster-users" target="_blank">http://supercolony.gluster.org/mailman/listinfo/gluster-users</a><br>
&gt;<br>
<br>
</blockquote></div><br></div></div>