The official Middle East News Agency said the clashes had erupted between the Libyan army and Islamist militias on a road leading up to the Ras Ajdir crossing on the border with Tunisia.
It said the bodies of the two victims were later taken to a state-run hospital in the area.
The agency, meanwhile, quoted Adel Hadura, a spokesman for Egyptian expatriates in Libya, as describing the condition of the four wounded victims as "critical."
He said the dead and wounded victims worked at a quarry near the border crossing point.
Libya has been dogged by political instability since the 2011 ouster and death of long-ruling strongman Muammar Gaddafi.
In the more than three years since, rival militias have frequently locked horns, often bringing violence to the country's main cities, including capital Tripoli.
Comments appearing to trivialize racial hatred have president isolated, even within own party
The accident happened late Friday when around 650 people were celebrating inside the tent in Sankt Johann am Walde in the north of the country.
The Trump administration, wary of international involvements but eager for progress in the grueling Afghan war, has been weighing a range of options. It had originally promised a new plan by mid-July.
Melika Salihbeg Bosnawi, an important poet and intellectual of Bosnia and Herzegovina, died at the age of 72
In this gusty rural region near the Pacific coast, the wind is so strong it sometimes flips over cars and even trailer trucks.
The suspected extremists behind Spain's twin terror attacks are thought to have formed a cell in the foothills of the Pyrenees mountains where they allegedly planned large-scale assaults.
The officers had been checking on suspicious people in an area known for drug activity around 9:30 pm Friday (0130 GMT Saturday). Five minutes later, authorities received a call that officers had been shot.
The 74-year-old left for the British capital on May 7 with his prolonged absence causing tensions back home where calls have grown for him to either return or resign.
A planned referendum on the secession of northern Iraq's Kurdish region on Sep. 25 is opposed by the majority of the international community while Israel supports it.
It said that armed police then arrived and used their weapons on the attacker and "liquidated" him.
The suspect's "identity is known to the police. He is an 18-year-old Moroccan citizen," it said, providing no other details about him.
Salim al-Jubouri’s Civil Rally for Reform promises to find solutions to battered Iraq’s chronic problems
"A 22-year-old foreign national has been arrested over suspected links to terrorist activity," a coastguard spokeswoman told AFP.
'We want Syria governed by Syrians, not by the United States, not by any other forces,' spokeswoman says
Alt-right luminary departs post after mutual agreement with Trump's new chief of staff, White House says
Ould Ghada, prominent opposition figure, was arrested last week