/var/log/mail.log가 확장되는 것을 방지하는 방법은 무엇입니까?

/var/log/mail.log가 확장되는 것을 방지하는 방법은 무엇입니까?

저는 Ubuntu 11.10(oneiric)을 사용하고 있습니다.

/var/log/mail내 서버에는 지속적인 부풀림이 있습니다.

Aug  5 10:48:25 domU-12-31-39-0B-C4-54 sm-msp-queue[13360]: q71He1xw027248: to=postmaster, delay=3+17:03:10, xdelay=00:00:00, mailer=relay, pri=23074446, relay=[127.0.0.1] [127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
Aug  5 10:48:25 domU-12-31-39-0B-C4-54 sm-msp-queue[13308]: q717K1wk024979: to=postmaster, delay=4+03:23:18, xdelay=00:00:00, mailer=relay, pri=25779463, relay=[127.0.0.1] [127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
Aug  5 10:48:25 domU-12-31-39-0B-C4-54 sm-msp-queue[13360]: q71He1xx027248: to=postmaster, delay=3+17:03:10, xdelay=00:00:00, mailer=relay, pri=23075343, relay=[127.0.0.1] [127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
...

나는 sendmail을 직접 사용하지 않으며 비활성화하는 것을 선호합니다.

sendmail이 시작되지 않는 것 같습니다:

$ sudo /etc/init.d/sendmail start 
* Starting Mail Transport Agent (MTA) sendmail
451 4.0.0 /etc/mail/sendmail.cf: line 100: fileclass: 
cannot open '/etc/mail/local-host-names': Group writable directory

나에게 올바른 권한이 있다고 생각합니다.

$ ls -ld /etc/mail/local-host-names
-rw-r--r-- 1 root root 52 2011-12-04 06:58 /etc/mail/local-host-names

그런데... 상위 폴더의 권한은 정상인가요?

g$ ls -ld / /etc /etc/mail
drwxr-xr-x 23 root  root  4096 2012-05-23 08:38 /
drwxrwxr-x 99 root  root  4096 2012-08-05 07:29 /etc
drwxr-sr-x  7 smmta smmsp 4096 2011-12-04 06:58 /etc/mail

sendmail을 수정하거나 비활성화하고 싶습니다. 나는 시도했다:

$ sudo update-rc.d sendmail disable
update-rc.d: warning: sendmail start runlevel arguments (none) do not match LSB Default-Start values (2 3 4 5)
update-rc.d: warning: sendmail stop runlevel arguments (none) do not match LSB Default-Stop values (1)
 Disabling system startup links for /etc/init.d/sendmail ...
 Removing any system startup links for /etc/init.d/sendmail ...
   /etc/rc0.d/K19sendmail
   /etc/rc1.d/K19sendmail
   /etc/rc2.d/K79sendmail
   /etc/rc3.d/K79sendmail
   /etc/rc4.d/K79sendmail
   /etc/rc5.d/K79sendmail
   /etc/rc6.d/K19sendmail
 Adding system startup for /etc/init.d/sendmail ...
   /etc/rc0.d/K19sendmail -> ../init.d/sendmail
   /etc/rc1.d/K19sendmail -> ../init.d/sendmail
   /etc/rc6.d/K19sendmail -> ../init.d/sendmail
   /etc/rc2.d/K79sendmail -> ../init.d/sendmail
   /etc/rc3.d/K79sendmail -> ../init.d/sendmail
   /etc/rc4.d/K79sendmail -> ../init.d/sendmail
   /etc/rc5.d/K79sendmail -> ../init.d/sendmail

하지만 여전히 mail.log에서 같은 오류가 발생합니다.

내가 본 다른 링크들:

답변1

/etc에 대한 올바른 권한이 없다고 생각합니다. 또한 그룹 쓰기도 불가능합니다. 노력하다

sudo chmod g-w /etc

이것이 도움이 됩니까?

관련 정보