Help - Install net-snmp-perl

Issues related to applications and software problems and general support
Post Reply
Movah
Posts: 5
Joined: 2011/11/01 19:45:54

Help - Install net-snmp-perl

Post by Movah » 2020/02/07 19:11:31

Trying to get some pre-requisites installed for Netdisco on CentOS8 but can't seem to get net-snmp-perl installed. Any suggestions on where and how to get this installed? or possibly is there an alternative that maybe I already have installed?
On Fedora/Red-Hat:
root:~# yum install perl-core perl-DBD-Pg net-snmp-perl net-snmp-devel openssl-devel curl postgresql-server postgresql-contrib make automake gcc
Here is what I get when trying to install. All of the others on the list above installed.

[Ndisco@Mynet.com ~]$ sudo dnf install -y net-snmp-perl
Last metadata expiration check: 0:10:02 ago on Fri 07 Feb 2020 09:52:40 AM EST.
No match for argument: net-snmp-perl
Error: Unable to find a match: net-snmp-perl

User avatar
TrevorH
Forum Moderator
Posts: 29910
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Help - Install net-snmp-perl

Post by TrevorH » 2020/02/07 20:21:49

It appears to be in EPEL

Code: Select all

perl-Net-SNMP.noarch                6.0.1-25.epel8.playground.1                    epel-playground
CentOS 6 will die in November 2020 - migrate sooner rather than later!
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 is dead, do not use it.
Full time Geek, part time moderator. Use the FAQ Luke

Movah
Posts: 5
Joined: 2011/11/01 19:45:54

Re: Help - Install net-snmp-perl

Post by Movah » 2020/02/07 21:15:56

Thanks for reply, so installing the epel would also get that?

User avatar
TrevorH
Forum Moderator
Posts: 29910
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Help - Install net-snmp-perl

Post by TrevorH » 2020/02/07 21:42:38

EPEL (more exactly "Fedora Extra Packages for Enterprise Linux) is a Red Hat sponsored third party yum repo that supplies things that are not in the main distro. You need to install the epel-release package that's in the CentOS extrtas repo and then you will have acsess to about another 4600 packages int he main EPEL repo with about the same number currently in the epel-testing and epel-playground repos (respectively less and less tested) both of which are disabled by default. So the process is install epel-release, yum install the package you want.
CentOS 6 will die in November 2020 - migrate sooner rather than later!
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 is dead, do not use it.
Full time Geek, part time moderator. Use the FAQ Luke

Movah
Posts: 5
Joined: 2011/11/01 19:45:54

Re: Help - Install net-snmp-perl

Post by Movah » 2020/02/10 13:21:53

Thanks for the help, finally got it.

just FYI I was getting the error below, and had to run "dnf config-manager --set-enabled PowerTools" before and then the install worked.


yum --enablerepo=epel install perl-Net-SNMP.noarch
Last metadata expiration check: 0:00:17 ago on Mon 10 Feb 2020 08:18:07 AM EST.
Error:
Problem: conflicting requests
- nothing provides perl(Digest::SHA1) >= 1.02 needed by perl-Net-SNMP-6.0.1-25.el8.1.noarch
(try to add '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)

sml
Posts: 116
Joined: 2020/01/17 09:01:44

Re: Help - Install net-snmp-perl

Post by sml » 2020/02/10 17:29:17

Digest::SHA1 is in PowerTools:

Code: Select all

yum --enablerepo=PowerTools,epel install perl-Net-SNMP

User avatar
TrevorH
Forum Moderator
Posts: 29910
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Help - Install net-snmp-perl

Post by TrevorH » 2020/02/10 17:37:08

PowerTools has so much stuff in it that it's worth permanently enabling as the OP did.
CentOS 6 will die in November 2020 - migrate sooner rather than later!
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 is dead, do not use it.
Full time Geek, part time moderator. Use the FAQ Luke

User avatar
lowen
Posts: 4
Joined: 2020/06/03 15:56:11
Location: Rosman, NC
Contact:

Re: Help - Install net-snmp-perl

Post by lowen » 2020/06/03 16:12:23

Ok, so a bit of a necropost here, but since this forum thread comes up high on the list when you search for 'netdisco CentOS 8' I thought I'd reply here.

So, first off, the package "net-snmp-perl" is NOT the same as "perl-Net-SNMP" and this will trip you up trying to get netdisco to build.

The package 'net-snmp-perl' is not built by default in CentOS 8 anymore, and is not in any of the standard repositories. There is a third-party repository with the package, called the 'OKay' repository, but, in my case, I decided to rebuild net-snmp-perl from sources; I've been looking for a good reason to try out building from git.centos.org, and this is a reasonably good test case. I'm not going to muddy things up with lots of comments; this flow should be pretty self-explanatory.

Here's the process:

First, as root, enable EPEL, then:

Code: Select all

dnf config-manager --set-enabled PowerTools
dnf group install "Development Tools"
dnf install rpmdevtools rpmlint perl-Expect mariadb-devel perl-core perl-DBD-Pg  openssl-devel postgresql-server postgresql-contrib automake

Installing of 'mysql-devel' will NOT work for building net-snmp-perl; you'll get an error related to my_bool.

As a normal user (since I'm installing netdisco, I'm using that user; I'm also an rsync junkie, so I use rsync here instead of ln -s or cp -a....) EDIT: also note that the previously posted "~/net-snmp-perl" won't actually work correctly; using `pwd` is better:

Code: Select all

git clone https://git.centos.org/centos-git-common.git
git clone https://git.centos.org/rpms/net-snmp.git
mkdir bin
rsync -avHAX centos-git-common/ bin
cd net-snmp
git checkout c8
get_sources.sh
rpmbuild --define "%_topdir `pwd`" --define '%netsnmp_check 0' -ba SPECS/net-snmp.spec
As root again (or of course using sudo is fine):

Code: Select all

cd /home/netdisco/net-snmp/RPMS/x86_64
yum install net-snmp-5.8*.rpm net-snmp-perl-5.8*.rpm net-snmp-devel-5.8*.rpm net-snmp-libs-5.8*.rpm net-snmp-agent-libs-5.8*.rpm
Your build of netdisco should then Just Work. And, yes, I know I'm mixing yum and dnf willy-nilly.....and after this process you'll need to exclude net-snmp* from yum updates and you'll need to keep track of those yourself. You might be able to automate that, use createrepo and friends, and have your own local repository.... all of which are left as an exercise for the reader. Thanks go out to multiple people on the centos mailing list and elsewhere for pieces of this recipe.....

Enjoy!
--
Thus spake Tandy Xenix System III version 3.2: "Bughlt: Sckmud Shut her down Scotty, she's sucking mud again!"

Post Reply

Return to “CentOS 8 - General Support”