writing physical file i/o (not ready)