Re: libgfapi as non-root

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Behrooz,

The error says about "testvol2" where the 'gluster volume info' you provided is on "testvol"

 [2015-03-25 22:50:08.079884] E [glfs-mgmt.c:599:mgmt_getspec_
cbk] 0-glfs-mgmt: failed to fetch volume file (key:testvol2)

Can you please cross-check on this ?

--Humble


On Thu, Mar 26, 2015 at 4:30 AM, Behrooz Shafiee <shafiee01@xxxxxxxxx> wrote:
Hello everyone,

 I want to use libgfapi c api in my code. I have installed glusterfs on my host with two bricks and created a volume called 'testvol'; however, in my code 'glfs_init' fails with -1 when I run my program without sudo access. If I run it as root it will connect fine. I saw an email in the mailing list with this solution:
1. add ” option rpc-auth-allow-insecure on” to *.vol file
2. set <volname> server.allow-insecure on
3. stop and start the volume

so I added ” option rpc-auth-allow-insecure on” to every .vol file in /var/lib/glusterd/vols/testvol including (testvol.IP.media-behrooz-Backup-gluster-brick1.vol  testvol-rebalance.vol  trusted-testvol.tcp-fuse.vol
testvol.IP.media-behrooz-Backup-gluster-brick2.vol  testvol.tcp-fuse.vol) as well as /etc/glusterfs/glusterd.vol. And also set testvol server.allow-insecure on and stop and start. Here is the info of my volume:

Volume Name: testvol
Type: Replicate
Volume ID: 3754bf24-d6b0-4af7-a4c9-d2a63c55455c
Status: Started
Number of Bricks: 1 x 2 = 2
Transport-type: tcp
Bricks:
Brick1: IP:/media/behrooz/Backup/gluster/brick1
Brick2: IP:/media/behrooz/Backup/gluster/brick2
Options Reconfigured:
server.allow-insecure: on
auth.allow: *

But still no luck and here is what I see in my program output:
[2015-03-25 22:50:08.079273] W [socket.c:611:__socket_rwv] 0-gfapi: readv on 129.97.170.232:24007 failed (No data available)
[2015-03-25 22:50:08.079806] E [rpc-clnt.c:362:saved_frames_unwind] (--> /usr/lib/x86_64-linux-gnu/libglusterfs.so.0(_gf_log_callingfn+0x186)[0x7fdb253f3da6] (--> /usr/lib/x86_64-linux-gnu/libgfrpc.so.0(saved_frames_unwind+0x1de)[0x7fdb2589cc7e] (--> /usr/lib/x86_64-linux-gnu/libgfrpc.so.0(saved_frames_destroy+0xe)[0x7fdb2589cd8e] (--> /usr/lib/x86_64-linux-gnu/libgfrpc.so.0(rpc_clnt_connection_cleanup+0x82)[0x7fdb2589e602] (--> /usr/lib/x86_64-linux-gnu/libgfrpc.so.0(rpc_clnt_notify+0x48)[0x7fdb2589ed98] ))))) 0-gfapi: forced unwinding frame type(GlusterFS Handshake) op(GETSPEC(2)) called at 2015-03-25 22:50:08.079120 (xid=0x1)
[2015-03-25 22:50:08.079884] E [glfs-mgmt.c:599:mgmt_getspec_cbk] 0-glfs-mgmt: failed to fetch volume file (key:testvol2)
[2015-03-25 22:50:08.079908] E [glfs-mgmt.c:696:mgmt_rpc_notify] 0-glfs-mgmt: failed to connect with remote-host: IP (No data available)
[2015-03-25 22:50:08.079924] I [glfs-mgmt.c:701:mgmt_rpc_notify] 0-glfs-mgmt: Exhausted all volfile servers


And I use:
glusterfs 3.6.2 built on Feb  7 2015 06:29:50



Any help or comment is highly appreciated!

Thanks,
--
Behrooz

_______________________________________________
Gluster-users mailing list
Gluster-users@xxxxxxxxxxx
http://www.gluster.org/mailman/listinfo/gluster-users

_______________________________________________
Gluster-users mailing list
Gluster-users@xxxxxxxxxxx
http://www.gluster.org/mailman/listinfo/gluster-users

[Index of Archives]     [Gluster Development]     [Linux Filesytems Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux