allow changing log level at runtime; fix errors due to cloexec not being set on lockfile