Fix chown happening before file is written on first start.