%20%EB%94%94%EB%A0%89%ED%84%B0%EB%A6%AC%EC%97%90%20%EC%9E%88%EB%8A%94%20%EC%8A%A4%ED%81%AC%EB%A6%BD%ED%8A%B8%EB%A5%BC%20%EC%82%AD%EC%A0%9C%ED%95%98%EC%A7%80%20%EC%95%8A%EA%B3%A0%20%EB%B9%84%ED%99%9C%EC%84%B1%ED%99%94%ED%95%98%EB%8A%94%20%EB%B0%A9%EB%B2%95%EC%9D%80%20%EB%AC%B4%EC%97%87%EC%9E%85%EB%8B%88%EA%B9%8C%3F.png)
많은 것들이 "디렉토리"를 의미하는 접미사가 붙은 디렉터리를 사용하여 구성되며 /etc
, .d
Unix에서는 이러한 접미사가 필요하지 않지만 이름 충돌을 피하기 위해 존재합니다.
구글링하기 힘드네요. 스크립트 중 하나를 비활성화하고 싶지만 /etc/update-motd.d/
비활성화할 수 없습니다. .d
그러한 디렉토리에서 스크립트를 비활성화하는 방법은 무엇입니까 ?
답변1
이는 해당 디렉토리와 배포판에 따라 크게 달라집니다. 예를 들어:
update-motd.d
Ubuntu의 스크립트는 실행 가능해야 합니다.update-motd
맨페이지설명하다:Executable scripts in /etc/update-motd.d/* are executed by pam_motd(8)
Ubuntu의 파일에는 다음 을 포함 하는
profile.d
확장자가 있어야 합니다 ..sh
/etc/profile
if [ -d /etc/profile.d ]; then for i in /etc/profile.d/*.sh; do if [ -r $i ]; then . $i
파일은 다음 위치에 있습니다.
sudoers.d
확장자가 없거나 다음으로 끝나서는 안 됩니다~
.... For example, given: #includedir /etc/sudoers.d sudo will read each file in /etc/sudoers.d, skipping file names that end in ‘~’ or contain a ‘.’
등.
세 가지 사항 모두 데비안에도 적용될 것입니다.