Thanks RVP will test this out.. I was manually running the pid but had to redo 
this everytime the device was restarted .. so seems like your item1 change is 
the solution. I did change the version # in the conf file earlier ..

-----Original Message-----
From: RVP <r...@sdf.org> 
Sent: Tuesday, June 11, 2024 4:50 AM
To: Derrick Lobo <derrick.l...@givex.com>
Cc: netbsd-users <netbsd-users@netbsd.org>
Subject: RE: EXT MAIL : log rotation with syslogng on netbsd 10

On Tue, 11 Jun 2024, Derrick Lobo wrote:

> Anyone knows what could be wrong here.. is there a new logrotate for netbsd 
> 10 which does not work with syslogng
>

Installed syslog-ng just now and newsyslog rotated the logs just fine.

I had only to make 2 fairly obvious changes:

1. In /etc/rc.d/syslogng, change the default pidfile name:

```
# pidfile="/var/run/${ngname}.pid"
pidfile="/var/run/syslogd.pid"
```
    (I was too lazy to fix-up /etc/newsyslog.conf for syslog-ng...)


2. Add a `@version: 3.38' directive at the start of the syslog2ng-generated
    /usr/pkg/etc/syslog-ng/syslog-ng.conf file:

```
$ head /usr/pkg/etc/syslog-ng/syslog-ng.conf
@version: 3.38

options { dir_perm(0755); perm(0644); chain_hostnames(no);
           keep_hostname(yes); };

source local {
         unix-dgram("/var/run/log");
         udp(ip(0.0.0.0) port(514));
         internal();
};
$
```

-RVP

Reply via email to