mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-20 05:14:08 -07:00
Merge pull request #1249 from chipitsine/centos7_nolimit
CentOS 7: increase number of open files
This commit is contained in:
commit
6fc3a45932
1 changed files with 10 additions and 0 deletions
|
@ -852,6 +852,11 @@ if [ "$nginx" = 'yes' ]; then
|
||||||
wget $vestacp/logrotate/nginx -O /etc/logrotate.d/nginx
|
wget $vestacp/logrotate/nginx -O /etc/logrotate.d/nginx
|
||||||
echo > /etc/nginx/conf.d/vesta.conf
|
echo > /etc/nginx/conf.d/vesta.conf
|
||||||
mkdir -p /var/log/nginx/domains
|
mkdir -p /var/log/nginx/domains
|
||||||
|
if [ "$release" -eq 7 ]; then
|
||||||
|
mkdir /etc/systemd/system/nginx.service.d/
|
||||||
|
echo "[Service]" > /etc/systemd/system/nginx.service.d/limits.conf
|
||||||
|
echo "LimitNOFILE=500000" >> /etc/systemd/system/nginx.service.d/limits.conf
|
||||||
|
fi
|
||||||
chkconfig nginx on
|
chkconfig nginx on
|
||||||
service nginx start
|
service nginx start
|
||||||
check_result $? "nginx start failed"
|
check_result $? "nginx start failed"
|
||||||
|
@ -890,6 +895,11 @@ if [ "$apache" = 'yes' ]; then
|
||||||
chmod a+x /var/log/httpd
|
chmod a+x /var/log/httpd
|
||||||
mkdir -p /var/log/httpd/domains
|
mkdir -p /var/log/httpd/domains
|
||||||
chmod 751 /var/log/httpd/domains
|
chmod 751 /var/log/httpd/domains
|
||||||
|
if [ "$release" -eq 7 ]; then
|
||||||
|
mkdir /etc/systemd/system/httpd.service.d/
|
||||||
|
echo "[Service]" > /etc/systemd/system/httpd.service.d/limits.conf
|
||||||
|
echo "LimitNOFILE=500000" >> /etc/systemd/system/httpd.service.d/limits.conf
|
||||||
|
fi
|
||||||
chkconfig httpd on
|
chkconfig httpd on
|
||||||
service httpd start
|
service httpd start
|
||||||
check_result $? "httpd start failed"
|
check_result $? "httpd start failed"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue