I found the ultimate solution to my problem: Switch to Linux :)<div><br><div>One more question: On Linux, which command is better to rotate log files?</div><div><br></div><div>nginx -s reopen </div><div><br></div><div>or </div>
<div><br></div><div>kill -USR1 <nginx-pid></div><div><div><br></div></div><div>I think using nginx -s reopen is better because its more clear and you don't have to grab the pid. On the other hand, using kill may be more unixy and work better with some existing system rotation scripts. But I think that's moot anyway because using the USR1 signal to rotate logs is not really standard. It probably doesn't really matter. I'm thinking that using kill to rotate the logs is just sort of a "legacy" way of doing it before the -s reopen option was added...</div>
</div><div><br></div>