For safety, I'd amend that slightly:
1) Start a new file (using tempnam()) with the new info
2) Read the old file
3) Append the old file to the new file
4) Delete the old file
5) Rename the new file to the old name
That way there's no downtime while the file is absent and you can check to see if you really do have a new file before deleting the old one 🙂
Then I'd ask myself if I'd be better off using a database.