[Solved] Re: Unable to get volume name (GlusterFS 3.3 on Solaris 11)

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

 



>> I looked at the source code, it seems "dict_get_str (dict, "volname",
>> &volname)" did not succeed. Any hint about it?

I found the reason:
$ vi ./cli/src/cli-rpc-ops.c

        ret = dict_allocate_and_serialize (dict,
                                           &req.dict.dict_val,
                                           (size_t *)&req.dict.dict_len);

size_t is ulong_t, while  dict_len's type is uint_t, on 64-bit
Big-Endian system like SPARC, it causes the wrong result: dict_len
becomes 0.
I find that same changes are needed at too many places , so I decided
to give up building 64-bit SPARC.

Then tried building 32-bit by modifying configure.ac, configure to remove "-m64"
$ CFLAGS="-m32 -g" ./configure

Run gluster volume create ... got bus error again (this is SPARC), the
problem is in hashfn.c

libglusterfs/src$ vi hashfn.c
change
#define get16bits(d) (*((const uint16_t *) (d)))
To:
static inline uint16_t get16bits(const char *data)
{
  return ((*data & 0x00ffU)|(*(data+1) & 0xff00U));
}

Then things look fine.

BTW, the previous " signal ILL" was caused  by openssl checking
processor capabilities, it's not a problem.  $ echo "ignore ILL" >
~/.dbxrc , solve the debugging issue.

Regards,
Xinfeng Liu



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

  Powered by Linux