Australia's Jack Miller secured his maiden MotoGP victory at the Dutch TT at Assen in torrential conditions which saw the race red flagged and then restarted when the weather improved.
The race began under wet conditions but the track began to dry during the early laps. Valentino Rossi led on the first lap and began to stretch out a lead over second-placed Andrea Dovizioso before Aspar's Yonny Hernandez made a move for the lead.
As Dovizioso began to close on Rossi, the rain intensified, causing Hernandez to fall, handing the lead back to Rossi whilst Scott Redding joined the action at the front of the field.
With Danilo Petrucci taking over second and Dovizioso the lead, conditions began to worsen and the race was red-flagged with 12 laps remaining.
Dovizioso started on pole for the restart, followed by Petrucci and Rossi but the lead immediately changed as Dovizioso rolled through the gravel, ending his race and victory hopes.
Rossi was the next man to crash out from the lead a lap later, handing the lead to Marquez, with Miller second. The pair swapped positions a few laps later, leaving Miller with just four lead laps to claim his maiden win.
Marquez finished second ahead of Britain's Scott Redding to complete the Assen podium.