# SNMPD geht nicht :(

## ConiKost

Hallo!

Ich habe mir heute net-snmp emerged.

Das hat geklappt. Aber ich kann es nicht starten!

Wo ist der Fehler?

```

BlackBox snmp # /etc/init.d/snmpd start

 * Caching service dependencies ...                                                                                                                    [ ok ]

 * Starting net-snmpd ...

/usr/sbin/snmpd: error while loading shared libraries: libnetsnmpagent.so.9: cannot open shared object file: No such file or directory                 [ !! ]

```

```

conikost@BlackBox ~ $ sudo emerge --info

Portage 2.1.1_rc1-r2 (default-linux/x86/2006.1, gcc-4.1.1/vanilla, glibc-2.4-r3, 2.6.17-gentoo-r7 i586)

=================================================================

System uname: 2.6.17-gentoo-r7 i586 Geode(TM) Integrated Processor by AMD PCS

Gentoo Base System version 1.12.4

Last Sync: Thu, 31 Aug 2006 19:50:01 +0000

ccache version 2.4 [enabled]

app-admin/eselect-compiler: 2.0.0_rc2-r1

dev-lang/python:     2.4.3-r3

dev-python/pycrypto: 2.0.1-r5

dev-util/ccache:     2.4-r2

dev-util/confcache:  0.4.2-r1

sys-apps/sandbox:    1.2.18.1

sys-devel/autoconf:  2.13, 2.60

sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2

sys-devel/binutils:  2.17

sys-devel/gcc-config: 1.3.13-r3

sys-devel/libtool:   1.5.22

virtual/os-headers:  2.6.17

ACCEPT_KEYWORDS="x86 ~x86"

AUTOCLEAN="yes"

CBUILD="i586-pc-linux-gnu"

CFLAGS="-march=k6-2 -Os -mmmx -m3dnow -pipe -fomit-frame-pointer -mfpmath=387"

CHOST="i586-pc-linux-gnu"

CONFIG_PROTECT="/etc /var/bind"

CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/eselect/compiler /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/splash /etc/terminfo"

CXXFLAGS="-march=k6-2 -Os -mmmx -m3dnow -pipe -fomit-frame-pointer -mfpmath=387 -fvisibility-inlines-hidden"

DISTDIR="/usr/portage/distfiles"

EMERGE_DEFAULT_OPTS=""

FEATURES="autoconfig ccache distlocks metadata-transfer parallel-fetch sandbox sfperms strict"

GENTOO_MIRRORS="ftp://pandemonium.tiscali.de/pub/gentoo/"

LANG="de_DE.utf8"

LC_ALL="de_DE.utf8"

LDFLAGS="-Wl,-O1"

LINGUAS="de"

MAKEOPTS="-j2"

PKGDIR="/usr/portage/packages"

PORTAGE_RSYNC_EXTRA_OPTS="--exclude-from=/etc/portage/rsync_excludes"

PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'"

PORTAGE_TMPDIR="/var/tmp"

PORTDIR="/usr/portage"

PORTDIR_OVERLAY="/usr/portage/local"

SYNC="rsync://rsync.de.gentoo.org/gentoo-portage"

USE="x86 3dnow a52 aac aalib acpi alsa apache2 bash-completion bzip2 cdinstall cgi clamav crypt cups dbus dedicated dts dvd elibc_glibc fbcon ftp gd gif gpm hal iconv imap innodb input_devices_keyboard input_devices_mouse java javascript jpeg jpeg2k kernel_linux linguas_de lm_sensors mailwrapper mmx mng mp3 mpeg mysql mysqli ncurses nls nptl odbc ogg pam pcre php png ppds quicktime readline samba sdl session skey slang spell ssl symlink szip tcpd threads tiff truetype unicode upnp usb userland_GNU v4l vcd vhosts video_cards_cyrix video_cards_fbdev video_cards_nsc video_cards_v4l video_cards_vesa video_cards_vga vorbis wifi win32codecs xml xvid zlib"

Unset:  CTARGET, INSTALL_MASK

```

----------

## dp20eic

Guten Morgen,

 *ConiKost wrote:*   

> Hallo!
> 
> ```
> 
> BlackBox snmp # /etc/init.d/snmpd start
> ...

 

Steht doch da, net-snmpd sucht eine lib "libnetsnmpagent.so.9" die es bei Dir nicht gibt, libnetsnm... ist nur ein link auf eine gleichnamige lib mit 9.0.0 am Ende.

1.) was sagt den "slocate libnetsnmpagent.so", bei mir 

     --># slocate libnetsnmpagent.so

     -->/usr/lib64/libnetsnmpagent.so.9

     -->/usr/lib64/libnetsnmpagent.so.9.0.0

     -->/usr/lib64/libnetsnmpagent.so

2.) equery b libnetsnmpagent.so.9 gibt bei mir

    --># equery b libnetsnmpagent.so.9

    -->[ Searching for file(s) libnetsnmpagent.so.9 in *... ]

    -->net-analyzer/net-snmp-5.2.2-r3 (/usr/lib64/libnetsnmpagent.so.9 -> libnetsnmpagent.so.9.0.0)

3.) # ls -la /usr/lib64/libnetsnmpagent.*

    -->-rw-r--r-- 1 root root 506330 10. Aug 18:20 /usr/lib64/libnetsnmpagent.a

    -->-rw-r--r-- 1 root root    790 10. Aug 18:20 /usr/lib64/libnetsnmpagent.la

    -->lrwxrwxrwx 1 root root     24 10. Aug 18:20 /usr/lib64/libnetsnmpagent.so -> libnetsnmpagent.so.9.0.0

    -->lrwxrwxrwx 1 root root     24 10. Aug 18:20 /usr/lib64/libnetsnmpagent.so.9 -> libnetsnmpagent.so.9.0.0

    -->-rwxr-xr-x 1 root root 236936 10. Aug 18:20 /usr/lib64/libnetsnmpagent.so.9.0.0

evtl. fehlt nur der link von libnetsnmpagent.so.9.0.0 nach libnetsnmpagent.so.9 kannst Du dann evtl. von Hand anlegen.

4.) hier noch was bei mir ldd ausspuckt,

# ldd /usr/sbin/snmpd

        libnetsnmpmibs.so.9 => /usr/lib64/libnetsnmpmibs.so.9 (0x0000003c7e000000)

        libsensors.so.3 => /usr/lib64/libsensors.so.3 (0x00000033af600000)

-->        libnetsnmpagent.so.9 => /usr/lib64/libnetsnmpagent.so.9 (0x0000003c7de00000)

        libnetsnmphelpers.so.9 => /usr/lib64/libnetsnmphelpers.so.9 (0x0000003c7e200000)

        libwrap.so.0 => /lib/libwrap.so.0 (0x0000003d92400000)

        libnetsnmp.so.9 => /usr/lib64/libnetsnmp.so.9 (0x0000003c7dc00000)

        libcrypto.so.0.9.7 => /usr/lib64/libcrypto.so.0.9.7 (0x00000033b0800000)

        libperl.so.1 => /usr/lib64/libperl.so.1 (0x00000033aa400000)

        libpthread.so.0 => /lib/libpthread.so.0 (0x00000033aa200000)

        libnsl.so.1 => /lib/libnsl.so.1 (0x00000033b0400000)

        libdl.so.2 => /lib/libdl.so.2 (0x00000033aa000000)

        libm.so.6 => /lib/libm.so.6 (0x00000033a9e00000)

        libcrypt.so.1 => /lib/libcrypt.so.1 (0x00000033b0600000)

        libutil.so.1 => /lib/libutil.so.1 (0x00000033ae000000)

        libc.so.6 => /lib/libc.so.6 (0x00000033a9a00000)

        libsysfs.so.2 => /lib/libsysfs.so.2 (0x00000033af800000)

        /lib64/ld-linux-x86-64.so.2 (0x00000033a9800000)

5.) evtl. mal ein revdep-rebuild duchführen.

   --> man revdep-rebuild

   --> revdep-rebuild

noch viel Spass und schönes Wochenende

BErnd

----------

