Too many open files
Alex JOST
jost+lists at dimejo.at
Mon Dec 14 18:07:30 CET 2015
Am 14.12.2015 um 17:31 schrieb Alex:
> Hi,
>
> I'm using amavisd-new-2.10.1 on fedora22 and occasionally receive "too
> many open files" where it's necessary to just restart amavisd to get
> it going again.
>
> 837D0346927 2973 Sun Dec 13 23:11:20 donotreply at nexusworldservices.com
> (host 127.0.0.1[127.0.0.1] said: 451 4.5.0 Error in processing,
> id=25071-05-40, check_init2 FAILED: Could not open /etc/resolv.conf:
> Too many open files at /usr/sbin/amavisd line 17747. (in reply to end
> of DATA command))
>
> I've search around quite a bit, and the only suggestions I see are to
> use ulimit to increase it. This won't survive a reboot, so I wondered
> how to do it at the system level instead?
>
> Will this even fix the problem? I notice now amavisd is using quite a
> few more than the normal 1024 limit already:
>
> # lsof |grep amavis|wc -l
> 1772
>
> # ulimit -n
> 1024
>
> Is this a PAM setting that I must change?
>
> Any help greatly appreciated.
> Thanks,
> Alex
Fedora uses systemd which sets the limits per service. You need to
override the default service. This should work:
mkdir /etc/systemd/system/amavisd.service.d
cd /etc/systemd/system/amavisd.service.d
echo -e "[Service]\nLimitNOFILE=5000" > 10-limits.conf
systemctl daemon-reload
--
Alex JOST
More information about the amavis-users
mailing list