in reply to Re: SNMPTT error
in thread SNMPTT error

Hi, im having difficulties to find this script. I can't locate and i try the way you say but nothing ....

[root@mpnagios snmptt_1.4]# which snmp_perl_trapd.pl /usr/bin/which: no snmp_perl_trapd.pl in (/usr/lib64/qt-3.3/bin:/usr/l +ocal/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin) [root@mpnagios snmptt_1.4]# whereis snmp_perl_trapd.pl snmp_perl_trapd: [root@mpnagios snmptt_1.4]#

Is there a way to download from or installed or something ....

Replies are listed 'Best First'.
Re^3: SNMPTT error
by taint (Chaplain) on Dec 03, 2013 at 15:16 UTC

    Well. You pretty much answered your own question;

    /usr/share/snmp/
    isn't in your PATH ENV. So You can either add it. Or you can remove the current copy, and choose
    make install PREFIX=/one/of/the/current/paths/in/your/$PATH
    You might try the first suggestion. After adding /usr/share/snmp/ to your current list of paths. You may need to issue a rehash. To slurp it into your working ENV.

    Best wishes

    --Chris

    #!/usr/bin/perl -Tw
    use Perl::Always or die;
    my $perl_version = (5.12.5);
    print $perl_version;

      They reported the error as:

      "Can't open perl script "/usr/share/snmp/snmp_perl_trapd.pl": No such file or directory"

      The fact the directory isn't in their PATH simpy means that your suggestions for finding the file won't look there. If you're simply looking for a file ls -al /path/to/file.pl will tell you what you need to know about it. Since the full path is being used and the file does not exist, they get the error message displayed.

      "You may need to issue a rehash. To slurp it into your working ENV."

      Results in "Sorry, no data found for `rehash'."

        Couple of things;
        "Can't open perl script "/usr/share/snmp/snmp_perl_trapd.pl" could just as easily mean the x bit isn't set.
        Secondly, the path it was listing, wasn't within the OP's PATH list.
        Lastly, I indicated "may" regarding rehash. This, of course, would depend on the OP's shell. So, it might be pertinent, and then again, might not. But doesn't hurt to mention, in case it does. Does it?

        --Chris

        #!/usr/bin/perl -Tw
        use Perl::Always or die;
        my $perl_version = (5.12.5);
        print $perl_version;