作業中の単純なトリガーを取得できませんproftpd
。これが私がしたことです:
<IfModule mod_exec.c>
ExecEngine on
ExecOptions logStderr logStdout
ExecLog /var/log/proftpd/exec.log
ExecOnCommand APPE,STOR /usr/local/bin/proftptest.sh %u %f
</IfModule>
ただし、次のように失敗し続けます。
Jan 21 17:31:07 mod_exec/0.9.9[22514]: already saw this Exec, skipping
Jan 21 17:31:07 mod_exec/0.9.9[22514]: already saw this Exec, skipping
Jan 21 17:31:07 mod_exec/0.9.9[22514]: preparing to execute '/usr/local/bin/proftptest.sh' with uid 117 (euid 117), gid 65534 (egid 65534)
Jan 21 17:31:07 mod_exec/0.9.9[22514]: + '/usr/local/bin/proftptest.sh': argv[1] = ftp
Jan 21 17:31:07 mod_exec/0.9.9[22514]: + '/usr/local/bin/proftptest.sh': argv[2] = /home/ftp/incoming/Examples.txt
Jan 21 17:31:07 mod_exec/0.9.9[22514]: error: unable to open /dev/null for stdin: No such file or directory
Jan 21 17:31:07 mod_exec/0.9.9[22514]: STOR ExecOnCommand '/usr/local/bin/proftptest.sh' failed: No such file or directory
Jan 21 17:31:07 mod_exec/0.9.9[22514]: already saw this Exec, skipping
Jan 21 17:31:07 mod_exec/0.9.9[22514]: already saw this Exec, skipping
ただし、スクリプトは問題ないようです(ユーザーセッション、デフォルト環境から実行):
$ ls -al /usr/local/bin/proftptest.sh
-rwxr-xr-x 1 root root 97 Jan 21 17:25 /usr/local/bin/proftptest.sh
私は DefaultRoot を使用していません:
$ grep Default /etc/proftpd/proftpd.conf
DefaultServer on
# DefaultRoot ~
何が欠けている可能性がありますか?