When I first learned to output to files in java, I accidentally generated a file a few GB in size. Opening a text file larger than your RAM is a BAD idea. (in fact, even a few MB takes a lot of freezing for Notepad)
How did you generate a GB size file by accident? I'm assuming text?