I think you would have to read in all the data and write it to a new file, you could either keep the data in RAM or simply write to another file then delete the original, and then rename the temp one. So obviously that is a lot of data and memory.
My main question is are you trying to use a text file as a circular buffer? If so can you tell us more about the data, ie is it strings of a constant length? Does a user ever need to read the file or could we head binary?
A solution would be to truly make the file a binary file, so you could actually seek through the file easier, and maybe make the first data chunk the location of the most recent write. The obvious danger is then writing over existing data. This solution is still risky because of the data writes.
You may want to look at some of the other file formats like HWS which maintains a hierarchy of data for you so you can simply add and remove data from it. However, a user will not be able to easily read it.