ファイル履歴の表示(ファイルを変更したユーザーのリスト)

ファイル履歴の表示(ファイルを変更したユーザーのリスト)

ファイルを変更したユーザーのリストを表示し、ファイルの履歴を提供するコマンドがありますか?

私はこれがsvn / gitなどで可能であることを知っています。しかし、SVNにない設定ファイルがあり、誰かがそれを修正しました。

ベストアンサー1

以前に何らかの種類の監査を有効にしていない場合は、ファイルが変更された後に報告するツールはありません。ファイルが最後に変更された日時は取得できますが、改訂履歴は取得できません。

次に、パッケージをインストール、設定、およびアクティブ化できますauditd

auditctlマニュアルページから:

-w path
    Insert  a  watch for the file system object at path. You cannot insert
    a watch to the top level directory. This is prohibited by the  kernel. 
    Wildcards  are not supported either and will generate a warning. The way
    that watches work is by tracking the inode internally. If you place a 
    watch on a file, its the same as  using  the  -F  path  option  on a 
    syscall rule. If you place a watch on a directory, its the same as using
    the -F dir option on a syscall rule.  The  -w form  of  writing watches 
    is for backwards compatibility and the syscall based form is more
    expressive. Unlike most syscall auditing rules,  watches  do  not impact
    performance  based on the number of rules sent to the kernel. The only 
    valid options when using a watch are the -p and -k. If you  need to     
    anything fancy like audit a specific user accessing a file, then use 
    the syscall auditing form with the path or dir fields.

質問にこれについてのさらなる議論があります。隠しファイル生成履歴

おすすめ記事