use file open/write instead of writeatomic to work around permission problem for Issue #3.