I spent 10 years doing tech support on Macs. I'm quite sure the fan noise has nothing to due with your OS.
If your Mac is still under warranty, I'd suggest you call or visit the nearest Apple store to get it fixed.
If your Mac is not under warranty, I recommend you visit
https://www.ifixit.com/Search?query=replace+fan.
They have parts for Macs and iDevices all the way back to 2005 (and possibly beyond).
They also have handy-dandy tool kits for safely opening your Mac AND both video and printable detailed how-tos to help you diagnose and fix your machine.