The extreme heat caused a high rate of wear from accidents and mechanical problems, although Petronas Yamaha rider Quartararo avoided all of that to claim his second straight win and take command of the Championship.
Quartararo came into Turn 1 from pole first, with Vinales and Rossi making a 1-2-3 for Yamaha on the opening laps.
Vinales went too far on the last corner at the end of the lap, allowing Rossi to move up front and Quartararo to quickly put the daylight behind him.
On lap five, Quartararo was 2.1s clear while Vinales struggled to pass Rossi while Ducati pairing Jack Miller and Francesco Bagnaia of Pramac finished.
Vinales – who looked one of the strongest throughout practice – was unable to pull away from Rossi, who finished second with his ability to brake better than his teammate.
All of this allowed Quartararo to take a four second lead on Lap 10, while Bagnaia made a mistake for Vinales at Turn 6 when the Yamaha went too far to finish second.
Rossi had managed to pass pursuers Bagnaia and Vinales but his old rear tire preservation problem started to worry him about 12 laps into the race and he was passed by Bagnaia when he overshot at Turn 6.
Bagnaia was able to edge Rossi by more than two seconds but was denied the first podium on lap 20 when his Ducati started smoking, forcing him to go off the track.
Vinales rallied and chased a struggling Rossi, eventually making a move on the penultimate lap when Rossi went too far at Turn 9.
Quartararo crossed to the checkered flag while Vinales led Rossi to the first all-Yamaha podium in MotoGP since 2014.
LCR Honda rider Takaaki Nakagami started to catch up to Rossi but couldn’t quite overtake the 41-year-old Yamaha rider and had to settle for a career-best fourth place.
Joan Mir took his Suzuki to fifth place – his best result in MotoGP – ahead of Andrea Dovizioso, who bounced back from 14th on the grid on the top Ducatis at the finish.
Pol Espargaro was the only KTM to finish seventh at the end of a miserable day for the Austrian manufacturer. Brad Binder crashed – after wiping out Tech3’s Miguel Oliveira at the start – and Iker Lecuona retired early.
Alex Marquez moved up from last to eighth on the sole Repsol-Honda after reigning World Champion brother Marc pulled out on Saturday due to pain from his broken arm.
Johann Zarco was ninth on the Avintia Ducati while Alex Rins heroically took his Suzuki to 10th despite a broken shoulder.
Tito Rabat (Avintia), Aprilia’s Bradley Smith and the injured Cal Crutchlow (LCR Honda) were the last of the 13 survivors.
Second Petronas Yamaha Franco Morbidelli was on course for a first podium after chasing Rossi in the final stages but was sidelined by a similar engine issue to the one that knocked Rossi out of the Jerez race last week.
Miller crashed out of the podium fight at Turn 9 on Lap 11, while factory Ducati’s Danilo Petrucci and Aprilia’s Aleix Espargaro also retired.