Blame SOURCES/redhat-bugzilla-2139012-pmdasnmp-config.patch

952062
commit 4014e295f7b5f541439774bd3c88924d3c061325
952062
Author: Masatake YAMATO <yamato@redhat.com>
952062
Date:   Thu Oct 20 13:55:43 2022 +0900
952062
952062
    pmdas/snmp: install the agent specific configuration file to PMDATMPDIR
952062
    
952062
    When running ./Install of the agent, the following line is printed in
952062
    /var/log/pcp/pmcd/snmp.log.
952062
    
952062
      Log for pmdasnmp on pcp-netsnmp started Tue Oct 18 22:45:23 2022
952062
    
952062
      opening /var/lib/pcp/pmdas/snmp/snmp.conf No such file or directory at /var/lib/pcp/pmdas/snmp/pmdasnmp.pl line 90.
952062
    
952062
    As a result, pmdasnmp.pl cannot read its configuration file though it
952062
    is "./Install"ed.
952062
    
952062
    Signed-off-by: Masatake YAMATO <yamato@redhat.com>
952062
952062
diff --git a/src/pmdas/snmp/GNUmakefile b/src/pmdas/snmp/GNUmakefile
952062
index ce0e3e8036..7bf5471a76 100644
952062
--- a/src/pmdas/snmp/GNUmakefile
952062
+++ b/src/pmdas/snmp/GNUmakefile
952062
@@ -44,7 +44,7 @@ install_pcp install: default
952062
 	$(INSTALL) -m 755 -t $(PMDATMPDIR) Install Remove $(PMDAADMDIR)
952062
 	$(INSTALL) -m 644 -t $(PMDATMPDIR)/pmda$(IAM).pl pmda$(IAM).pl $(PMDAADMDIR)/pmda$(IAM).pl
952062
 	$(INSTALL) -m 755 -d $(PMDACONFIG)
952062
-	$(INSTALL) -m 644 snmp.conf $(PMDACONFIG)/snmp.conf
952062
+	$(INSTALL) -m 644 -t $(PMDATMPDIR)/$(IAM).conf $(IAM).conf $(PMDACONFIG)/$(IAM).conf
952062
 	@$(INSTALL_MAN)
952062
 else
952062
 build-me:
952062