Please write a simple daemon which does this:
- Open the file, using the same fopen() statement that you use in the real daemon.
- If it succeeds, syslog that it succeeded.
- If it fails, syslog that it failed and syslog the errno.
Then try this daemon at system reboot and then restart it explicitly.
Do they both fail? Both succeed? One succeed, and one fail?