Error yang muncul di log

2015/07/12 09:23:31 [warn] 4253#0: 2048 worker_connections exceed open file resource limit: 1024

Solusi Pertama

Tambahkan worker_rlimit_nofile 30000; dibawah

user  www-data;
worker_processes  1;

sehingga menjadi

user  www-data;
worker_processes  1;
worker_rlimit_nofile 450000;

lalu restart nginx

service nginx restart

Solusi Kedua

Tambahkan dibagian paling bawah /etc/security/limits.conf

*         hard    nofile      450000
*         soft    nofile      450000
root      hard    nofile      450000
root      soft    nofile      450000

lalu restart nginx

service nginx restart

Solusi Ketiga

Tambahkan dibaris paling bawah /etc/sysctl.conf

fs.file-max = 2097152

lalu reload sysctl

sysctl -p

lalu restart nginx

service nginx restart

Bila belum berhasil juga, gabungkan ketiga solusi diatas, baru restart nginx

service nginx restart

Leave a comment

Your email address will not be published. Required fields are marked *