[Bugs] [Bug 1341942] glusterd coredump due to assert failed with GF_ASSERT ( GD_OP_HEAL_VOLUME == op)

bugzilla at redhat.com bugzilla at redhat.com
Tue Jun 7 14:02:17 UTC 2016


https://bugzilla.redhat.com/show_bug.cgi?id=1341942



--- Comment #3 from George <george.lian at nokia.com> ---
(In reply to Mohammed Rafi KC from comment #1)
> if possible, can you upload generated core file? was there any parallel cli
> commands running from any other server ?

core file uploaded as the attachment.
maybe CLI run parallel, don't sure.

the function glusterd_volume_heal_use_rsp_dict in 3.6.9 is 
        GF_ASSERT (rsp_dict);

        op = glusterd_op_get_op ();
        GF_ASSERT (GD_OP_HEAL_VOLUME == op);



and I just find in newest code in git repository the function
"glusterd_volume_heal_use_rsp_dict" is changed as the below:


        GF_ASSERT (rsp_dict);

        ret = dict_get_bin (aggr, "transaction_id", (void **)&txn_id);
        if (ret)
                goto out;
        gf_msg_debug (THIS->name, 0, "transaction ID = %s",
                uuid_utoa (*txn_id));

        ret = glusterd_get_txn_opinfo (txn_id, &txn_op_info);
        if (ret) {
                gf_msg_callingfn (THIS->name, GF_LOG_ERROR, 0,
                        GD_MSG_TRANS_OPINFO_GET_FAIL,
                        "Unable to get transaction opinfo "
                        "for transaction ID : %s",
                        uuid_utoa (*txn_id));
                goto out;
        }

        op = txn_op_info.op;
        GF_ASSERT (GD_OP_HEAL_VOLUME == op); 

it should resove the GF_assert issue what I happen, but I am still confuse:
1) as the code in 3.6.9, I suppose if the first parameter is NULL, it will find
the dict from global variable "opinfo.op" to get the dict.
but from the latest code, it has no this logic.  is it acceptable?

2) for the latest code, the added code seems only to check txn_op_info.op is
valid or not, and seems no other use. it really confuse me.

3) and the else branch of code script in function as the below seems never will
be ENTER!

         if (aggr) {
                ctx_dict = aggr;

        } else {
                ctx_dict = txn_op_info.op_ctx;
        }

REASON: IF aggr is NULL, it will goto out in previous code, if it not null,
else branch will not enter, so else branch never will be ENTER.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
Unsubscribe from this bug https://bugzilla.redhat.com/token.cgi?t=K0tbjd4NSJ&a=cc_unsubscribe


More information about the Bugs mailing list