IBM TS 4300: Got empty SNMP response

hi,

the line is not added, but executed as your checkmk/omd site user :slight_smile:

Gerd

2 Likes

Hello Gerd,

Please tell me how to execute a installed mkp package in a command line and redirect the output to the checkmk web interface for the monitoring!

Thanks for your answer!

Ben

PS:

  1. I have already read the following article Checkmk extension packages (MKPs) - Integrating extensions from the community into Checkmk

  2. The mkp file is installed and enabled.
    OMD[test]:~/local/share/check_mk/agents/plugins$ mkp -v list
    Name Title Files


        ibm_tape_library-4300 IBM TS4300 discovery fix 1
  1. OMD[test]:~/local/share/check_mk/agents/plugins$ check_mk -P show ibm_tape_library-4300
    Package file: /omd/sites/muc/var/check_mk/packages/ibm_tape_library-4300
    Name: ibm_tape_library-4300
    Version: 0.0.5
    Packaged on Checkmk Version: 2.1.0p33
    Required Checkmk Version: 2.1.0b1
    Valid until Checkmk version: No version limitation
    Title: IBM TS4300 discovery fix

  2. OMD[test]:~/local/share/check_mk/agents/plugins$ mkp
    Usage: check_mk [-v] -P|–package COMMAND [ARGS]

Available commands are:
create NAME … Collect unpackaged files into new package NAME
pack NAME … Create package file from installed package
release NAME … Drop installed package NAME, release packaged files
find … Find and display unpackaged files
list … List all installed packages
list NAME … List files of installed package
list PACK.mkp … List files of uninstalled package file
show NAME … Show information about installed package
show PACK.mkp … Show information about uninstalled package file
install PACK.mkp … Install or update package from file PACK.mkp
remove NAME VERSION … Uninstall and delete package NAME
disable NAME … Disable package NAME
enable NAME VERSION … Enable previously disabled package NAME
disable-outdated … Disable outdated packages

This is how to install an use the mkp:

OMD[central22]:~$ mkp add ibm_tape_library-4300-0.0.5.mkp 
ibm_tape_library-4300 0.0.5

OMD[central22]:~$ mkp enable ibm_tape_library-4300 0.0.5
[ibm_tape_library-4300 0.0.5]: Installing

# not sure if this is necessary 
OMD[central22]:~$ omd restart

# now you should be able to discover your lib on the cli:
OMD[central22]:~$ cmk -IIvv <name-of-your-ibm_tape_library-4300>

It basically just overshadows the shipped stock version of the check with an extended scan function.

What is contained?

OMD[central22]:~$ mkp files ibm_tape_library-4300 
/omd/sites/central22/local/lib/python3/cmk/base/check_legacy_includes/ibm_tape_library.py

What is the change about?

OMD[central22]:~$ diff lib/python3/cmk/base/check_legacy_includes/ibm_tape_library.py ~/local/lib/python3/cmk/base/check_legacy_includes/ibm_tape_library.py 
6d5
< 
8,9c7,9
<     return oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.32925.1")
< 
---
>     return oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.32925.1") or oid(
>         ".1.3.6.1.4.1.14851.3.1.3.5.0"
>     ).startswith("IBM TS4300 Tape Library")
1 Like

Is there any news here? The mkp. File did nothing for me.

JFYI, there is now an mkp for Checkmk 2.3.0 as well.
The former mpk only worked for 2.1.0 and perhaps 2.2.0 (I did not test/verify)

https://exchange.checkmk.com/p/ibm-tape-library-4300#versions

https://exchange.checkmk.com/packages/ibm-tape-library-4300/2025/ibm_tape_library-4300-2.3.0-0.0.6.mkp

As before this is just a minimal change in the scan function:

OMD[central23]:~$ diff -u share/check_mk/checks/ibm_tl_media_access_devices local/share/check_mk/checks/ibm_tl_media_access_devices 
--- share/check_mk/checks/ibm_tl_media_access_devices	2025-08-25 08:53:46.000000000 +0200
+++ local/share/check_mk/checks/ibm_tl_media_access_devices	2025-10-02 10:37:24.730044249 +0200
@@ -79,6 +79,7 @@
     detect=any_of(
         startswith(".1.3.6.1.2.1.1.2.0", ".1.3.6.1.4.1.32925.1"),
         startswith(".1.3.6.1.2.1.1.2.0", ".1.3.6.1.4.1.2.6.254"),
+        startswith(".1.3.6.1.4.1.14851.3.1.3.5.0","IBM TS4300 Tape Library"),
     ),
     fetch=[
         SNMPTree(

OMD[central23]:~$ diff -u share/check_mk/checks/ibm_tl_changer_devices local/share/check_mk/checks/ibm_tl_changer_devices 
--- share/check_mk/checks/ibm_tl_changer_devices	2025-08-25 08:53:46.000000000 +0200
+++ local/share/check_mk/checks/ibm_tl_changer_devices	2025-10-02 10:37:14.548101119 +0200
@@ -40,6 +40,7 @@
     detect=any_of(
         startswith(".1.3.6.1.2.1.1.2.0", ".1.3.6.1.4.1.32925.1"),
         startswith(".1.3.6.1.2.1.1.2.0", ".1.3.6.1.4.1.2.6.254"),
+        startswith(".1.3.6.1.4.1.14851.3.1.3.5.0","IBM TS4300 Tape Library"),
     ),
     fetch=SNMPTree(
         base=".1.3.6.1.4.1.14851.3.1.11.2.1",

There is currently no fix/workaround for 2.4.0 because it’s not possible to overshadow the shipped legacy (plugin API v0) check plugins in 2.4.0 but the check will be migrated to the new check plugin API v2 soon.

Once this will is released I am going also create an mpk for 2.4.0 to make this TS4300 discoverable.

5 Likes

There is now also an mkp for 2.4.0 at https://exchange.checkmk.com/p/ibm-tape-library-4300

mo-ki was so nice to migrated these check plugins to the new cmk.agent_based.v2 API in the git master branch (upcomming checkmk 2.5.0) https://github.com/Checkmk/checkmk/tree/master/cmk/plugins/ibm_tl/agent_based

I just backported this to 2.4.0 as mkp and added the scan function fix.

3 Likes