Translated message

A translation of this page exists in English.

rsyslog によって作成されたログファイルの権限を設定する方法

Solution Verified - Updated -

Issue

  • ログファイル (例:/var/log/messages) のデフォルトの権限を変更して、誰でも読み取り可能または書き込み可能にするにはどうすればよいですか?
  • /etc/logrotate.d/syslog 内の create ディレクティブを使用してシステムログファイルの権限を変更しても、rsyslog v5 (RHEL6 など) では機能しません。logrotate で何が設定されているかに関係なく、ログファイルには必ず 600 の権限が与えられます。
  • rsyslog オプション $umask および $FileCreateMode を使用しても、ログ権限が更新されません。

Environment

  • Red Hat Enterprise Linux 5
  • Red Hat Enterprise Linux 6
  • Red Hat Enterprise Linux 7
  • Red Hat Enterprise Linux 8
  • Red Hat Enterprise Linux 9
  • rsyslog

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content