Valentino Rossi beat his Yamaha teammate and title rival Jorge Lorenzo to the fastest time in opening practice for the San Marino Grand Prix at Misano.
Dani Pedrosa completed the top three, although his Honda slowed to a halt on its way back to the pits at the end of the session.
Indianapolis winner Lorenzo had led the way for most of the afternoon, hitting the front early on and staying there until briefly pipped by Pedrosa with 20 minutes to go.
In response, Lorenzo reeled off a sequence of ever-faster laps that put him 0.6sec clear of the competition and seemingly on course for a dominant position at the head of the times.
But just as Lorenzo's hold on first place looked safe, his teammate – who had been around half a second off the pace until that point – pulled out a 1m35.404s lap to beat him by 0.026sec.
Rossi then shaved another tenth off his time on his last run, while Lorenzo was unable to improve and had to settle for second.
Alex de Angelis was the only man to fall in the session, but rebounded strongly to split the factory Hondas in fourth.
Fresh from his career best second place at Indianapolis, the Gresini Honda rider's opening run actually put him at the head of the order for a while, but he then fell on the exit of the first chicane. He was able to rejoin soon afterwards, and escaped a near-miss on the entry to Turn 1 that saw Randy de Puniet's LCR Honda come within inches of plowing into the back of him before the Frenchman jinked onto the run-off instead.
Having survived that incident, de Angelis produced a late surge to grab fourth, pushing Pedrosa's works team-mate Andrea Dovizioso down to fifth.
Tech 3 Yamaha's Colin Edwards completed the top six, while Mika Kallio and Nicky Hayden gave Ducati seventh and 10th places on its home ground.
Further back, the man who has taken Kallio's vacant Pramac Ducati seat – Aleix Espargaro – caught the eye with 13th place, two spots ahead of his teammate Niccolo Canepa, at the start of his second MotoGP weekend.
Pos Rider Bike Time Gap
1. Valentino Rossi Yamaha 1m35.304s
2. Jorge Lorenzo Yamaha 1m35.430s + 0.126s
3. Dani Pedrosa Honda 1m36.080s + 0.776s
4. Alex de Angelis Gresini Honda 1m36.096s + 0.792s
5. Andrea Dovizioso Honda 1m36.316s + 1.012s
6. Colin Edwards Tech 3 Yamaha 1m36.350s + 1.046s
7. Mika Kallio Ducati 1m36.419s + 1.115s
8. Loris Capirossi Suzuki 1m36.508s + 1.204s
9. James Toseland Tech 3 Yamaha 1m36.588s + 1.284s
10. Nicky Hayden Ducati 1m36.608s + 1.304s
11. Randy de Puniet LCR Honda 1m37.056s + 1.752s
12. Toni Elias Gresini Honda 1m37.057s + 1.753s
13. Aleix Espargaro Pramac Ducati 1m37.126s + 1.822s
14. Chris Vermeulen Suzuki 1m37.134s + 1.830s
15. Niccolo Canepa Pramac Ducati 1m37.306s + 2.002s
16. Marco Melandri Hayate Kawasaki 1m37.454s + 2.150s
17. Gabor Talmacsi Scot Honda 1m37.869s + 2.565s