MQ

MQ

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  Add user permission to all queues

    Posted Wed October 30, 2024 06:20 PM

    $ dspmqver
    Name:        IBM MQ
    Version:     9.3.0.2

    I'm trying to query local queues using a Zabbix agent.
    Basically, the agent runs this command.

    echo 'DISPLAY QLOCAL(*) WHERE(CURDEPTH GE 0)' | runmqsc QMName

    However, the Zabbix user is not authorized.

    Starting MQSC for queue manager QMName.
    AMQ8135E: Not authorized.

    No MQSC commands read.

    I tried to add the zabbix user to the mqm user group, but it didn't work.

    usermod -aG mqm zabbix

    When I checked the logs, I found that the user did not have sufficient privileges to access the QM.

    AMQ8077W: Entity 'zabbix' has insufficient authority to access object
    QMName [qmgr].
     
    EXPLANATION:
    The specified entity is not authorized to access the required object. The
    following requested permissions are unauthorized: connect

    So, I added the connect permission.

    SET AUTHREC OBJTYPE(QMGR) GROUP('zabbix') AUTHADD(CONNECT)

    Then I got a new permission error.

    AMQ8245W: Entity 'zabbix' has insufficient authority to display object
    QMName [qmgr].
     
    EXPLANATION:
    The specified entity is not authorized to display the required object. The
    following requested permissions are unauthorized: dsp

    I then added the dsp permission.

    SET AUTHREC OBJTYPE(QMGR) GROUP('zabbix') AUTHADD(DSP)

    But, this time, the query resulted in an error for each queue.

    AMQ8245W: Entity 'zabbix' has insufficient authority to display object
    QE.TEST [queue].

    EXPLANATION:
    The specified entity is not authorized to display the required object. The
    following requested permissions are unauthorized: dsp

    Since there are many queues for each QM, I could not figure out how to add permission to the Zabbix user for all queues.

    Can you guys help out?



    ------------------------------
    Daniel Daniel Maia Dias
    ------------------------------


  • 2.  RE: Add user permission to all queues

    Posted Wed October 30, 2024 08:05 PM

    Hi Daniel - please see my answer on the first copy of your question you posted.

    Cheers,
    Morag



    ------------------------------
    Morag Hughson
    MQ Technical Education Specialist
    MQGem Software Limited
    Website: https://www.mqgem.com
    ------------------------------