시스템 열린 파일 설정을 영구적으로 변경하고 싶지만 작동하지 않습니다.Debian Stretch에서 일반 사용자 용으로 열린 파일 (ulimit -n)을 영구적으로 변경하는 방법은 무엇입니까?
내 로그인 사용자는 root
이 아닌 일반 사용자입니다. 나는 다음과 같은 작업을했다 :
파일/etc/sysctl.conf
$ grep 'fs.file-max' /etc/sysctl.conf
fs.file-max = 800000
파일 /etc/security/limits.conf
는 CentOS는/오픈 수세에 작품 설정/etc/security/limits.conf
$ grep nofile /etc/security/limits.conf
# - nofile - max number of open files
* soft nofile 655360
* hard nofile 655360
을하지만, 데비안에없는 작품.
는 파일 /etc/pam.d/common-session{,-noninteractive}
로
session required pam_limits.so
추가 이미 그것을 가지고 /etc/pam.d/login
파일. 절대 경로
/lib/x86_64-linux-gnu/security/pam_limits.so
ulimit -n
재부팅실행 후, 출력은 여전히 기본값 1,024이다.
$ ulimit -n
1024
효과를 보려면 어떻게해야합니까?
는 당신이 봤어 :
는 systemd 서비스로이 파일에 사용자 ID와 같은 설정 한계를 교체 파일
/etc/systemd/system/[email protected]/limit.conf
만들기? https://serverfault.com/questions/610130/how-to-set-ulimit-value-permanently –