[Pkg-net-snmp-devel] Add PID file to snmpd

Craig Small csmall at debian.org
Sat Apr 28 22:50:46 BST 2018


It would most likely be systemd. I suspect you have a file in the /etc
directory that doesn't have the -p option
systemctl status snmpd should give you more information too



On Sun, 29 Apr 2018 at 02:56 Josu Lazkano <josu.lazkano at gmail.com> wrote:

> Thanks Craig for the reply.
>
> I don't know if I am using systemd or not. I use standar system of
> Debien Stretch.
>
> Which file need I review in my case?
>
> Thanks for your help.
>
> Kind regards.
>
> 2018-04-28 13:46 GMT+02:00 Craig Small <csmall at debian.org>:
> > Hi Josu,
> >   The init script is only used for non-systemd setups, so first you need
> to
> > work out what you have there.  If you are not using systemd, then the
> snmpd
> > parameters come from /etc/default/snmpd and /etc/init.d/snmpd
> >
> > If you are using systemd then the parameters by default come from
> > /lib/systemd/system/snmpd.service  However, local changes are found in
> > /etc/systemd/system/snmpd.service
> >
> > I would guess a local change somewhere is stopping snmpd from creating a
> > pid. It uses the -p option to do so, you should see something like this
> in
> > ps:
> >   2022 ?        Ss     0:00 /usr/sbin/snmpd -Lsd -Lf /dev/null -u
> > Debian-snmp -g Debian-snmp -I -smux mteTrigger mteTriggerConf -f -p
> > /run/snmpd.pid
> >
> > For example, I had an old /etc/systemd/system/snmpd.service lying around
> > that stopped it for me.
> >
> >  - Craig
> >
> >
> > On Sun, 22 Apr 2018 at 21:12 Josu Lazkano <josu.lazkano at gmail.com>
> wrote:
> >>
> >> Hello,
> >>
> >> I am using snmpd in Debian server, it really works great.
> >>
> >> The problem is that there is no PID file for the service.
> >>
> >> In the init script is configured by default in /run/snmpd.pid, but
> >> there is no file there.
> >>
> >> How could I configure to get the PID file in the filesystem?
> >>
> >> Thanks in advance.
> >>
> >> Kind regards.
> >>
> >> --
> >> Josu Lazkano
> >>
> >> _______________________________________________
> >> Pkg-net-snmp-devel mailing list
> >> Pkg-net-snmp-devel at alioth-lists.debian.net
> >>
> >>
> https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-net-snmp-devel
> >
> > --
> > Craig Small             https://dropbear.xyz/     csmall at :
> dropbear.xyz
> > Debian GNU/Linux        https://www.debian.org/   csmall at : debian.org
> > Mastodon: @smallsees at social.dropbear.xyz             Twitter: @smallsees
> > GPG fingerprint:      5D2F B320 B825 D939 04D2  0519 3938 F96B DF50 FEA5
>
>
>
> --
> Josu Lazkano
>
-- 
Craig Small             https://dropbear.xyz/     csmall at : dropbear.xyz
Debian GNU/Linux        https://www.debian.org/   csmall at : debian.org
Mastodon: @smallsees at social.dropbear.xyz             Twitter: @smallsees
GPG fingerprint:      5D2F B320 B825 D939 04D2  0519 3938 F96B DF50 FEA5
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-net-snmp-devel/attachments/20180428/7089604a/attachment.html>


More information about the Pkg-net-snmp-devel mailing list