Shots were fired at a police car after officers approached a parked BMW during a routine check in Gloucestershire.
The blue Series 3 BMW, registration L401 JOL, was in a lay-by on the B4008 next to junction 12 of the M5.
When the officers approached the car, outside Blooms Garden Centre, it was driven on to the M5 and two shots were fired by a passenger. No-one was hit.
The M5 was closed in both directions between junctions 12 and 13 for several hours, but reopened later.
Queues formed as the Bank Holiday weekend got under way, and water was handed out by police officers to the hundreds of stranded motorists.
The B4008, from junction 12 of the M5 towards Stonehouse was also closed and diversion signs put in place.
Police have been searching the area
Police followed the BMW after the shooting, which took place at about 0400 BST, but lost sight of the car just before junction 13, near Stroud.
"As the vehicle drove onto the carriageway, someone believed to be in the back of the vehicle fired two shots in the direction of the police vehicle," said Kate Nelmes, of Gloucestershire Police.
"A lot of inquiries are being carried out to trace that vehicle and we would appeal to anyone who knows who is responsible and where they and the vehicle are now, to get in touch with us."