gluster / gluster-block

A framework for gluster block storage
GNU General Public License v2.0
74 stars 32 forks source link

Unable to create block in CentOS 7 or Fedora 31 #258

Closed poxin13 closed 4 years ago

poxin13 commented 4 years ago

Getting same error on both systems due to outdated targetcli/rtslib, etc. Latest version installed via yum or dnf. Not sure how to proceed. Do they need complied from source?

gluster-block create gv0/block-volume ha 3 10.3.34.100,10.3.34.101,10.3.34.102 1GiB

[root@gfs00 gluster-block]# gluster-block create gv0/block-volume ha 3 10.3.34.100,10.3.34.101,10.3.34.102 1GiB
Version check failed between block servers. (the capability 'create_io_timeout' is not supported on host 10.3.34.100 yet, please upgrade.)
RESULT:FAIL
INFO: starting with tcmu-runner version - 1.5.2
INFO: starting with targetcli version - 2.1.fb49
INFO: starting with rtslib version <= 2.1.69
INFO: starting with configshell version < 1.1.25

WARNING: the 'hw_block_size' needs atleast rtslib >= 2.1.69, so disabling its capability [at capabilities.c+156 :<gbSetCapabilties>]

WARNING: reload needs atleast targetcli >=2.1.fb50 and rtslib >= 2.1.71, so disabling its capability [at capabilities.c+166 :<gbSetCapabilties>]

WARNING: io timeout needs atleast configshell >=1.1.25 and tcmu-runner >= 1.5.0, so disabling its capability [at capabilities.c+176 :<gbSetCapab>
poxin13 commented 4 years ago

Compiled latest versions from source, no issues on starting of services. Still getting an error creating a block.

INFO: starting with tcmu-runner version - 1.5.2
INFO: starting with targetcli version - 2.1.51
INFO: starting with rtslib version - 2.1.71
INFO: starting with configshell version - 1.1.27
[root@gfs00 gluster-block]# gluster-block create gv0/block-volume ha 3 10.3.34.100,10.3.34.101,10.3.34.102 1GiB
failed to configure on 10.3.34.100 configure failed
failed to configure on 10.3.34.101 configure failed
failed to configure on 10.3.34.102 configure failed
RESULT:FAIL

gluster-blockd.txt gluster-block-configshell.txt gluster-block-gfapi.txt

Looks like via targetcli, it is creating something in the process targetcli ls.txt

lxbsz commented 4 years ago

BTW, could you see any error in the tcmu-runner*.log ?

poxin13 commented 4 years ago

These are from tcmu-runner.log and tcmu-runner-glfs.log

2019-12-03 13:17:44.752 1416 [INFO] load_our_module:547: Inserted module 'target_core_user'
2019-12-03 13:42:02.139 1416 [ERROR] tcmu_glfs_open:540 glfs/block-volume: glfs_fsetxattr failed: Invalid argument
2019-12-03 13:42:13.128 1416 [ERROR] device_add:610: handler open failed for uio0
2019-12-03 13:42:13.181 1416 [ERROR] tcmu_glfs_open:540 glfs/block-volume: glfs_fsetxattr failed: Invalid argument
2019-12-03 13:42:24.172 1416 [ERROR] device_add:610: handler open failed for uio0
2019-12-03 13:46:26.981 1416 [ERROR] tcmu_glfs_open:540 glfs/block-test: glfs_fsetxattr failed: Invalid argument
2019-12-03 13:46:37.973 1416 [ERROR] device_add:610: handler open failed for uio0
2019-12-03 13:46:38.026 1416 [ERROR] tcmu_glfs_open:540 glfs/block-test: glfs_fsetxattr failed: Invalid argument
2019-12-03 13:46:49.017 1416 [ERROR] device_add:610: handler open failed for uio0
2019-12-03 13:47:48.668 1416 [ERROR] tcmu_glfs_open:540 glfs/block-test: glfs_fsetxattr failed: Invalid argument
2019-12-03 13:47:59.660 1416 [ERROR] device_add:610: handler open failed for uio0
2019-12-03 13:47:59.712 1416 [ERROR] tcmu_glfs_open:540 glfs/block-test: glfs_fsetxattr failed: Invalid argument
2019-12-03 13:48:10.703 1416 [ERROR] device_add:610: handler open failed for uio0
2019-12-03 13:52:28.968 1416 [ERROR] tcmu_glfs_open:540 glfs/block-volume: glfs_fsetxattr failed: Invalid argument
2019-12-03 13:52:39.959 1416 [ERROR] device_add:610: handler open failed for uio0
2019-12-03 13:52:40.010 1416 [ERROR] tcmu_glfs_open:540 glfs/block-volume: glfs_fsetxattr failed: Invalid argument
2019-12-03 13:52:51.003 1416 [ERROR] device_add:610: handler open failed for uio0
2019-12-03 14:03:51.131 1416 [CRIT] main:1390: Exiting...
+------------------------------------------------------------------------------+
[2019-12-03 18:52:39.995894] I [MSGID: 114046] [client-handshake.c:1104:client_setvolume_cbk] 0-gv0-client-0: Connected to gv0-client-0, attached to remote volume '/tank/bri>
[2019-12-03 18:52:39.995917] I [MSGID: 108005] [afr-common.c:5277:__afr_handle_child_up_event] 0-gv0-replicate-0: Subvolume 'gv0-client-0' came back up; going online.
[2019-12-03 18:52:39.996135] E [MSGID: 101172] [events.c:88:_gf_event] 0-gv0-replicate-0: inet_pton failed with return code 0 [Invalid argument]
[2019-12-03 18:52:39.996809] I [rpc-clnt.c:1962:rpc_clnt_reconfig] 0-gv0-client-2: changing port to 49152 (from 0)
[2019-12-03 18:52:39.996849] I [socket.c:863:__socket_shutdown] 0-gv0-client-2: intentional socket shutdown(24)
[2019-12-03 18:52:39.997367] I [MSGID: 114057] [client-handshake.c:1373:select_server_supported_programs] 0-gv0-client-1: Using Program GlusterFS 4.x v1, Num (1298437), Vers>
[2019-12-03 18:52:39.998380] I [MSGID: 114046] [client-handshake.c:1104:client_setvolume_cbk] 0-gv0-client-1: Connected to gv0-client-1, attached to remote volume '/tank/bri>
[2019-12-03 18:52:39.998414] I [MSGID: 108002] [afr-common.c:5646:afr_notify] 0-gv0-replicate-0: Client-quorum is met
[2019-12-03 18:52:39.998602] E [MSGID: 101172] [events.c:88:_gf_event] 0-gv0-replicate-0: inet_pton failed with return code 0 [Invalid argument]
[2019-12-03 18:52:40.001551] I [MSGID: 114057] [client-handshake.c:1373:select_server_supported_programs] 0-gv0-client-2: Using Program GlusterFS 4.x v1, Num (1298437), Vers>
[2019-12-03 18:52:40.002347] I [MSGID: 114046] [client-handshake.c:1104:client_setvolume_cbk] 0-gv0-client-2: Connected to gv0-client-2, attached to remote volume '/tank/bri>
[2019-12-03 18:52:40.004566] I [MSGID: 104041] [glfs-resolve.c:952:__glfs_active_subvol] 0-gv0: switched to graph 67667330-302e-636c-6f75-64312e6c6f63 (0)
[2019-12-03 18:52:40.009883] W [MSGID: 114031] [client-rpc-fops_v2.c:1678:client4_0_fsetxattr_cbk] 0-gv0-client-0: remote operation failed [Invalid argument]
[2019-12-03 18:52:40.009980] W [MSGID: 114031] [client-rpc-fops_v2.c:1678:client4_0_fsetxattr_cbk] 0-gv0-client-2: remote operation failed [Invalid argument]
[2019-12-03 18:52:40.010070] W [MSGID: 114031] [client-rpc-fops_v2.c:1678:client4_0_fsetxattr_cbk] 0-gv0-client-1: remote operation failed [Invalid argument]
[2019-12-03 18:52:40.011274] I [socket.c:863:__socket_shutdown] 0-gfapi: intentional socket shutdown(19)
[2019-12-03 18:52:40.111523] I [MSGID: 114021] [client.c:2443:notify] 0-gv0-client-0: current graph is no longer active, destroying rpc_client
[2019-12-03 18:52:40.111638] I [timer.c:85:gf_timer_call_cancel] (-->/usr/lib64/glusterfs/7.0/xlator/protocol/client.so(+0x13861) [0x7fa1820b1861] -->/lib64/libgfrpc.so.0(rp>
[2019-12-03 18:52:40.111700] I [timer.c:85:gf_timer_call_cancel] (-->/usr/lib64/glusterfs/7.0/xlator/protocol/client.so(+0x13861) [0x7fa1820b1861] -->/lib64/libgfrpc.so.0(rp>
[2019-12-03 18:52:40.111757] I [timer.c:85:gf_timer_call_cancel] (-->/lib64/libgfrpc.so.0(rpc_clnt_disable+0x92) [0x7fa1e1d54f62] -->/lib64/libgfrpc.so.0(+0x1387d) [0x7fa1e1>
[2019-12-03 18:52:40.111801] I [MSGID: 114021] [client.c:2443:notify] 0-gv0-client-1: current graph is no longer active, destroying rpc_client
[2019-12-03 18:52:40.111863] I [timer.c:85:gf_timer_call_cancel] (-->/usr/lib64/glusterfs/7.0/xlator/protocol/client.so(+0x13861) [0x7fa1820b1861] -->/lib64/libgfrpc.so.0(rp>
[2019-12-03 18:52:40.111897] I [MSGID: 114018] [client.c:2341:client_rpc_notify] 0-gv0-client-0: disconnected from gv0-client-0. Client process will keep trying to connect t>
[2019-12-03 18:52:40.111936] I [timer.c:85:gf_timer_call_cancel] (-->/usr/lib64/glusterfs/7.0/xlator/protocol/client.so(+0x13861) [0x7fa1820b1861] -->/lib64/libgfrpc.so.0(rp>
[2019-12-03 18:52:40.111997] I [timer.c:85:gf_timer_call_cancel] (-->/lib64/libgfrpc.so.0(rpc_clnt_disable+0x92) [0x7fa1e1d54f62] -->/lib64/libgfrpc.so.0(+0x1387d) [0x7fa1e1>
[2019-12-03 18:52:40.112029] I [MSGID: 114021] [client.c:2443:notify] 0-gv0-client-2: current graph is no longer active, destroying rpc_client
[2019-12-03 18:52:40.112052] I [MSGID: 114018] [client.c:2341:client_rpc_notify] 0-gv0-client-1: disconnected from gv0-client-1. Client process will keep trying to connect t>
[2019-12-03 18:52:40.112089] I [timer.c:85:gf_timer_call_cancel] (-->/usr/lib64/glusterfs/7.0/xlator/protocol/client.so(+0x13861) [0x7fa1820b1861] -->/lib64/libgfrpc.so.0(rp>
[2019-12-03 18:52:40.112086] W [MSGID: 108001] [afr-common.c:5652:afr_notify] 0-gv0-replicate-0: Client-quorum is not met
[2019-12-03 18:52:40.112160] I [timer.c:85:gf_timer_call_cancel] (-->/usr/lib64/glusterfs/7.0/xlator/protocol/client.so(+0x13861) [0x7fa1820b1861] -->/lib64/libgfrpc.so.0(rp>
[2019-12-03 18:52:40.112217] I [timer.c:85:gf_timer_call_cancel] (-->/lib64/libgfrpc.so.0(rpc_clnt_disable+0x92) [0x7fa1e1d54f62] -->/lib64/libgfrpc.so.0(+0x1387d) [0x7fa1e1>
[2019-12-03 18:52:40.112275] I [MSGID: 114018] [client.c:2341:client_rpc_notify] 0-gv0-client-2: disconnected from gv0-client-2. Client process will keep trying to connect t>
[2019-12-03 18:52:40.112366] E [MSGID: 101172] [events.c:88:_gf_event] 0-gv0-replicate-0: inet_pton failed with return code 0 [Invalid argument]
[2019-12-03 18:52:40.112450] E [MSGID: 108006] [afr-common.c:5354:__afr_handle_child_down_event] 0-gv0-replicate-0: All subvolumes are down. Going offline until at least one>
[2019-12-03 18:52:40.112648] E [MSGID: 101172] [events.c:88:_gf_event] 0-gv0-replicate-0: inet_pton failed with return code 0 [Invalid argument]
[2019-12-03 18:52:40.112790] W [inode.c:1864:inode_table_destroy] (-->/lib64/libgfapi.so.0(glfs_fini+0x45d) [0x7fa1e1d9e52d] -->/lib64/libglusterfs.so.0(inode_table_destroy_>
[2019-12-03 18:52:40.112885] W [inode.c:1864:inode_table_destroy] (-->/lib64/libgfapi.so.0(glfs_fini+0x45d) [0x7fa1e1d9e52d] -->/lib64/libglusterfs.so.0(inode_table_destroy_>
[2019-12-03 18:52:50.001542] I [io-stats.c:4037:fini] 0-gv0: io-stats translator unloaded
[2019-12-03 18:52:50.001825] I [MSGID: 101191] [event-epoll.c:738:event_dispatch_epoll_worker] 0-epoll: Exited thread with index 2
[2019-12-03 18:52:50.001898] I [MSGID: 101191] [event-epoll.c:738:event_dispatch_epoll_worker] 0-epoll: Exited thread with index 1
[2019-12-03 18:52:51.002272] I [timer.c:85:gf_timer_call_cancel] (-->/lib64/libglusterfs.so.0(gf_log_fini+0x19) [0x7fa1e1c337b9] -->/lib64/libglusterfs.so.0(gf_log_disable_s>
lxbsz commented 4 years ago

What's version of your gluster packages ?

At the same time in tcmu-runner please revert https://github.com/open-iscsi/tcmu-runner/commit/6db2a468c62b8828aacce57e75e24e3846a9d9fe and have a try.

Thanks.

poxin13 commented 4 years ago

glusterfs 7.0 tcmu-runner 1.5.2

I'll try that suggestion next

poxin13 commented 4 years ago

Reverted to open-iscsi/tcmu-runner@6db2a46

[root@gfs00 gluster-block]# gluster-block create gv0/block-volume ha 3 10.3.34.100,10.3.34.101,10.3.34.102 1GiB
failed to configure on 10.3.34.100 configure failed
failed to configure on 10.3.34.101 configure failed
failed to configure on 10.3.34.102 configure failed
RESULT:FAIL

tcmu-runner.log

2019-12-03 22:42:22.596 238548 [ERROR] tcmu_glfs_open:540 glfs/block-volume: glfs_fsetxattr failed: Invalid argument
2019-12-03 22:42:33.561 238548 [ERROR] add_device:540: handler open failed for uio0
2019-12-03 22:42:33.614 238548 [ERROR] tcmu_glfs_open:540 glfs/block-volume: glfs_fsetxattr failed: Invalid argument
2019-12-03 22:42:44.605 238548 [ERROR] add_device:540: handler open failed for uio0

gluster-block-configshell.log

[ERROR] 2019-12-03 22:42:44 No such path /backstores/user:glfs/block-volume
[INFO] 2019-12-03 22:42:44 Created target iqn.2016-12.org.gluster-block:50a5b560-13b6-42ce-a514-0cb7647438d6.
[INFO] 2019-12-03 22:42:44 Created TPG 1.
[INFO] 2019-12-03 22:42:44 Created TPG 2.
[INFO] 2019-12-03 22:42:44 Created TPG 3.
[ERROR] 2019-12-03 22:42:44 storage object or path not valid
[ERROR] 2019-12-03 22:42:44 No such path /iscsi/iqn.2016-12.org.gluster-block:50a5b560-13b6-42ce-a514-0cb7647438d6/tpg1/luns/lun0
[INFO] 2019-12-03 22:42:44 Using default IP port 3260
[INFO] 2019-12-03 22:42:44 Created network portal 10.3.34.100:3260.
[INFO] 2019-12-03 22:42:44 The TPGT has been enabled.
[ERROR] 2019-12-03 22:42:45 storage object or path not valid
[ERROR] 2019-12-03 22:42:45 No such path /iscsi/iqn.2016-12.org.gluster-block:50a5b560-13b6-42ce-a514-0cb7647438d6/tpg2/luns/lun0
[INFO] 2019-12-03 22:42:45 Using default IP port 3260
[INFO] 2019-12-03 22:42:45 Created network portal 10.3.34.101:3260.
[ERROR] 2019-12-03 22:42:45 storage object or path not valid
[ERROR] 2019-12-03 22:42:45 No such path /iscsi/iqn.2016-12.org.gluster-block:50a5b560-13b6-42ce-a514-0cb7647438d6/tpg3/luns/lun0
[INFO] 2019-12-03 22:42:45 Using default IP port 3260
[INFO] 2019-12-03 22:42:45 Created network portal 10.3.34.102:3260.
[ERROR] 2019-12-03 22:42:45 No such path /backstores/user:glfs/block-volume

gluster-blockd.log

[2019-12-04 03:42:45.292149] INFO: command exit code, -1 [at block_create.c+691 :<block_create_common>]
[2019-12-04 03:42:45.334481] ERROR: failed in remote create for block block-volume on host 10.3.34.100 volume gv0 [at block_create.c+341 :<glusterBlockCreateRemote>]
[2019-12-04 03:42:45.678689] ERROR: failed in remote create for block block-volume on host 10.3.34.102 volume gv0 [at block_create.c+341 :<glusterBlockCreateRemote>]
[2019-12-04 03:42:46.118059] ERROR: failed in remote create for block block-volume on host 10.3.34.101 volume gv0 [at block_create.c+341 :<glusterBlockCreateRemote>]
[2019-12-04 03:42:46.118175] WARNING: glusterBlockCreateRemoteAsync: return -1 failed in remote async create for block block-volume on volume gv0 with hosts 10.3.34.100,10.3>
[2019-12-04 03:42:46.181485] INFO: delete request, blockname=block-volume filename=50a5b560-13b6-42ce-a514-0cb7647438d6 [at block_delete.c+463 :<block_delete_1_svc_st>]
[2019-12-04 03:42:46.879183] ERROR: Block 'block-volume' may be not loaded. [at block_svc_routines.c+111 :<blockCheckBlockLoadedStatus>]
[2019-12-04 03:42:46.882507] ERROR: Block 'block-volume' already deleted. [at block_svc_routines.c+154 :<blockCheckBlockLoadedStatus>]
[2019-12-04 03:42:46.900608] ERROR: failed in remote delete for block block-volume on host 10.3.34.100 volume gv0 [at block_delete.c+48 :<glusterBlockDeleteRemote>]
[2019-12-04 03:42:46.958554] ERROR: failed in remote delete for block block-volume on host 10.3.34.102 volume gv0 [at block_delete.c+48 :<glusterBlockDeleteRemote>]
[2019-12-04 03:42:47.111128] ERROR: failed in remote delete for block block-volume on host 10.3.34.101 volume gv0 [at block_delete.c+48 :<glusterBlockDeleteRemote>]
[2019-12-04 03:42:47.195206] INFO: create cli return success, volume=gv0 blockname=block-volume [at block_create.c+1163 :<block_create_cli_1_svc_st>]

gluster-block-gfapi.log

[2019-12-04 03:42:18.309655] I [MSGID: 114046] [client-handshake.c:1104:client_setvolume_cbk] 0-gv0-client-0: Connected to gv0-client-0, attached to remote volume '/tank/bri>
[2019-12-04 03:42:18.309681] I [MSGID: 108005] [afr-common.c:5277:__afr_handle_child_up_event] 0-gv0-replicate-0: Subvolume 'gv0-client-0' came back up; going online.
[2019-12-04 03:42:18.309945] E [MSGID: 101172] [events.c:88:_gf_event] 0-gv0-replicate-0: inet_pton failed with return code 0 [Invalid argument]
[2019-12-04 03:42:18.310689] I [rpc-clnt.c:1962:rpc_clnt_reconfig] 0-gv0-client-2: changing port to 49152 (from 0)
[2019-12-04 03:42:18.310716] I [MSGID: 114057] [client-handshake.c:1373:select_server_supported_programs] 0-gv0-client-1: Using Program GlusterFS 4.x v1, Num (1298437), Vers>
[2019-12-04 03:42:18.310726] I [socket.c:863:__socket_shutdown] 0-gv0-client-2: intentional socket shutdown(16)
[2019-12-04 03:42:18.311766] I [MSGID: 114046] [client-handshake.c:1104:client_setvolume_cbk] 0-gv0-client-1: Connected to gv0-client-1, attached to remote volume '/tank/bri>
[2019-12-04 03:42:18.311798] I [MSGID: 108002] [afr-common.c:5646:afr_notify] 0-gv0-replicate-0: Client-quorum is met
[2019-12-04 03:42:18.311994] E [MSGID: 101172] [events.c:88:_gf_event] 0-gv0-replicate-0: inet_pton failed with return code 0 [Invalid argument]
[2019-12-04 03:42:18.315515] I [MSGID: 114057] [client-handshake.c:1373:select_server_supported_programs] 0-gv0-client-2: Using Program GlusterFS 4.x v1, Num (1298437), Vers>
[2019-12-04 03:42:18.316606] I [MSGID: 114046] [client-handshake.c:1104:client_setvolume_cbk] 0-gv0-client-2: Connected to gv0-client-2, attached to remote volume '/tank/bri>
[2019-12-04 03:42:18.319741] I [MSGID: 104041] [glfs-resolve.c:952:__glfs_active_subvol] 0-gv0: switched to graph 67667330-302e-636c-6f75-64312e6c6f63 (0)
[2019-12-04 03:42:18.335083] W [dict.c:611:dict_del] (-->/usr/lib64/glusterfs/7.0/xlator/cluster/replicate.so(+0x187e6) [0x7fb842e517e6] -->/usr/lib64/glusterfs/7.0/xlator/c>
[2019-12-04 03:42:18.335116] E [MSGID: 101046] [dht-common.c:11245:dht_pt_fgetxattr_cbk] 0-gv0-dht: dict is null
[2019-12-04 03:42:18.335133] E [MSGID: 101046] [dht-common.c:11246:dht_pt_fgetxattr_cbk] 0-gv0-dht: dict is null
[2019-12-04 03:42:47.184798] I [MSGID: 133022] [shard.c:3680:shard_delete_shards] 0-gv0-shard: Deleted shards of gfid=34658ff8-dd63-49ec-99b8-b84a019b555c from backend
[2019-12-04 03:42:47.192575] I [MSGID: 133022] [shard.c:3680:shard_delete_shards] 0-gv0-shard: Deleted shards of gfid=9d9584ca-4b07-4958-bf1e-2906d33daf62 from backend
[2019-12-04 03:42:47.196218] ERROR: glfs_open(block-volume) failed[No such file or directory] [at glfs-operations.c+797 :<blockGetMetaInfo>]
lxbsz commented 4 years ago

Reverted to open-iscsi/tcmu-runner@6db2a46

[root@gfs00 gluster-block]# gluster-block create gv0/block-volume ha 3 10.3.34.100,10.3.34.101,10.3.34.102 1GiB
failed to configure on 10.3.34.100 configure failed
failed to configure on 10.3.34.101 configure failed
failed to configure on 10.3.34.102 configure failed
RESULT:FAIL

tcmu-runner.log

2019-12-03 22:42:22.596 238548 [ERROR] tcmu_glfs_open:540 glfs/block-volume: glfs_fsetxattr failed: Invalid argument
2019-12-03 22:42:33.561 238548 [ERROR] add_device:540: handler open failed for uio0
2019-12-03 22:42:33.614 238548 [ERROR] tcmu_glfs_open:540 glfs/block-volume: glfs_fsetxattr failed: Invalid argument
2019-12-03 22:42:44.605 238548 [ERROR] add_device:540: handler open failed for uio0

You seem not revert it or there has something wrong with your operations, I still can see the glfs_fsetxattr error.

If the revert is successful, there shouldn't have this error.

You should make the tcmu-runner and install/restart it.

poxin13 commented 4 years ago

Attempted again, can confirm the original was removed, and reinstalled with that commit. Verified glfs.c file line 605 to spot check if if (ret < 0 || ret != length) { was removed for example. Same error as before.

[root@gfs00 home]# git clone https://github.com/open-iscsi/tcmu-runner.git
Cloning into 'tcmu-runner'...
remote: Enumerating objects: 21, done.
remote: Counting objects: 100% (21/21), done.
remote: Compressing objects: 100% (18/18), done.
remote: Total 4522 (delta 6), reused 9 (delta 3), pack-reused 4501
Receiving objects: 100% (4522/4522), 1.62 MiB | 11.04 MiB/s, done.
Resolving deltas: 100% (3043/3043), done.
[root@gfs00 home]# cd tcmu-runner
[root@gfs00 tcmu-runner]# git reset --hard 6db2a468c62b8828aacce57e75e24e3846a9d9fe
HEAD is now at 6db2a46 glfs: add lock support
lxbsz commented 4 years ago

Attempted again, can confirm the original was removed, and reinstalled with that commit. Verified glfs.c file line 605 to spot check if if (ret < 0 || ret != length) { was removed for example. Same error as before.

[root@gfs00 home]# git clone https://github.com/open-iscsi/tcmu-runner.git
Cloning into 'tcmu-runner'...
remote: Enumerating objects: 21, done.
remote: Counting objects: 100% (21/21), done.
remote: Compressing objects: 100% (18/18), done.
remote: Total 4522 (delta 6), reused 9 (delta 3), pack-reused 4501
Receiving objects: 100% (4522/4522), 1.62 MiB | 11.04 MiB/s, done.
Resolving deltas: 100% (3043/3043), done.
[root@gfs00 home]# cd tcmu-runner
[root@gfs00 tcmu-runner]# git reset --hard 6db2a468c62b8828aacce57e75e24e3846a9d9fe
HEAD is now at 6db2a46 glfs: add lock support
commit 1385e13a8628bbc210cf8d05c6e4ea3082ccf6a5
Merge: 9c84f7a 6db2a46
Author: mikechristie <mikenc@gmail.com>
Date:   Mon Aug 19 17:43:42 2019 -0500

    Merge pull request #554 from lxbsz/lock

    glfs: add lock support

commit 6db2a468c62b8828aacce57e75e24e3846a9d9fe (origin/lock)
Author: Xiubo Li <xiubli@redhat.com>
Date:   Mon Jun 3 11:41:02 2019 +0800

    glfs: add lock support

    This will avoid the data crruption between multiple nodes case,more
    detail please see:
    https://review.gluster.org/#/c/glusterfs-specs/+/21925/6/accepted/fencing.md

    Signed-off-by: Xiubo Li <xiubli@redhat.com>

commit f8a81e9a77ee5c8f803a0bd6e9ac72479ab8bd20
Author: Xiubo Li <xiubli@redhat.com>
Date:   Thu Aug 1 09:35:03 2019 +0800

    alua: make the lock done as INFO message

You should reset --hard to "f8a81e9a77ee5c8f803a0bd6e9ac72479ab8bd20" instead.

Or directly revert f8a81e9a77ee5c8f803a0bd6e9ac72479ab8bd20.

poxin13 commented 4 years ago

Thank you @lxbsz.

[root@gfs00 log]# gluster-block create gv0/block-volume ha 3 10.3.34.100,10.3.34.101,10.3.34.102 1GiB
IQN: iqn.2016-12.org.gluster-block:9d543862-5441-46ad-a986-2df401af8076
PORTAL(S):  10.3.34.100:3260 10.3.34.101:3260 10.3.34.102:3260
RESULT: SUCCESS
lxbsz commented 4 years ago

The lock relating code in gluster has been released since 7.6.6, so for 7.0 version the GFAPI_VERSION766 shouldn't be set in tcmu-runner, but from your result it seem there has bugs.