Hurricane Dorian is set to slam the Bahamas as a dangerous category 4 storm, pounding the islands with up to two days of torrential rain, high waves and damaging winds before taking aim at the US mainland.