In my opinion, the doubled pawns in F file is not the problem maker.
You do not have a f6 knight which will cause h file easy to break.(white can achieve that by e5 g5 in many opening strategies), so when you lose that knight position, Nf8 or Bg6 or g6 Bg7 h5(h6) is in need if you want to be solid in most cases. But it is based on you game's context.
This is a position from a game played earlier today as Black.
I didn't post the whole game, because I didn't want to destract from the question. It is really just the example that got me thinking about this.As you can see, the Black King doesn't look very safe. There is an attack mounting from the front, and the c-file pawns are blocking off his escape, while also making it very difficult to get other pieces across to defend him.
The position reminds me of other games (from both sides)where gxf turns a regular castle position into a death trap.
In this game however the pawns were doubled before I castled. I didn't think much of it at the time, but after the Queen moved across it did get quite dangerous. During my analysis I started to wonder if castling Kingside had been a mistake. Sbeing as f7 was always going to be blocked, cramping any escape from the corner.
So my question is. Is it a good rule of thumb to avoid castling on the Kingside when pawns are double on the f-file? Conversly on the Queenside when pawns are doubled on the c-file?