A tractor driven by a Palestinian man rammed into a bus in central Jerusalem early Monday afternoon, close to the “seam” between the western and eastern parts of the city.

A male pedestrian, later named as Avraham Walz, 29, was run over by the tractor as it headed toward the bus and was killed. The tractor driver, identified as East Jerusalem resident Muhammed Naif El-Ja’abis, 23, turned the bus over onto its side during the attack, making several efforts to do so before he succeeded. The bus driver as well as five others were lightly hurt.

Police said the attack, which took place at the end of Shmuel Hanavi Street, near the Olive Tree Hotel, was nationalistically motivated.

A police officer and Prisons Service official who realized what was happening ran up to the tractor and fired a volley of shots at the terrorist as he sat in the cab and killed him, Jerusalem police chief Yossi  Pariente said.

The tractor driver was identified by Palestinians on social media as Muhammed Naif El-Ja’abis from the East Jerusalem neighborhood of Jabel Mukaber.

Security personnel inspect the scene where an excavator driver from the Est Jerusalem neighborhood of Jabel Mukaber overturned a bus on Shmuel HaNavi street in Jerusalem on Monday, August 4, 2014 (photo credit: Yonatan Sindel/Flash90)

Security personnel inspect the scene where an excavator driver from the Est Jerusalem neighborhood of Jabel Mukaber overturned a bus on Shmuel HaNavi street in Jerusalem on Monday, August 4, 2014 (photo credit: Yonatan Sindel/Flash90)

Internal Security Minister Yitzhak Aharonovitch said the terrorist was known to the authorities from a previous incident, and that his family was being questioned.

Praising the actions of the police, he said, “The quick response saved lives.” Aharonovitch added that officials had considered the possibility that there could be an attack against the background of the ongoing Israeli military campaign against Hamas in Gaza. “We took that into account at the start of the operation down south,” he said.

Security officials told Channel 2 news that Ja’abis may have carried out the attack for revenge after his cousin’s home was demolished two weeks ago.

An amateur cellphone video of the incident showed that after knocking the bus over on its side the tractor driver tried to continue attacking the vehicle by swinging the mechanical digging arm into it.

The attacker worked at a building site nearby, Pariente said. He said three of those lightly injured were on the bus. He said the quick action of those who shot the attacker “averted a much more serious incident.”

The bus was an Illit company vehicle, which ferries passengers from Jerusalem to the settlement of Beitar Illit 10 kilometers south of the city.

File photo of Avraham Walz,  who was killed Monday in a terror attack in Jerusalem, after a tractor driver ran him over on August 04, 2014 (photo credit: Nati Shohat/Flash 90)

File photo of Avraham Walz, who was killed Monday in a terror attack in Jerusalem, after a tractor driver ran him over on August 04, 2014 (photo credit: Nati Shohat/Flash 90)

Jerusalem Mayor Nir Barkat praised the police officers who prevented the attack. At the same time, he urged Jerusalemites, “Do not take the law into your own hands” — a warning against revenge attacks.

“It could have been a terrible disaster if not for the resourcefulness” of the security forces who shot the attacker dead, Barkat said.

In 2008, Jerusalem suffered a spate of terror attacks involving tractors. In July that year, an East Jerusalem resident killed three people and wounded 30, after he rammed his construction vehicle into buses and cars and trampled pedestrians on Rashi, Jaffa and Sarei Israel streets in the city. He was shot dead at the scene.

Three weeks later, another Palestinian man used his tractor to plow into vehicles on King David street in Jerusalem, making his way to Keren Hayesod Street, where he was shot and killed by a Border Police officer. Twenty-four people were injured in that incident.

 Muhammed Naif El-Ja’abis (screen capture: Channel 2)

Muhammed Naif El-Ja’abis (screen capture: Channel 2)

In September that same year, another East Jerusalem resident rammed a private vehicle into IDF soldiers and civilians standing near the Old City. Several people were wounded and the driver was shot and killed.

Since the murder of Palestinian teenager Mohammed Abu Khdeir on July 2 likely by Jewish extremists, sporadic disturbances from Arab residents have peaked in the Old City and outlying neighborhoods. Dozens of Palestinians have been arrested for rioting, stone throwing, and shooting.

The apparently nationalistic murder of Abu Khdeir came on the heals of the funerals of three Israeli teenagers, Naftali Fraenkel, Gil-ad Shaar and Eyal Yifrach, kidnapped and executed by two Hamas terrorists from Hebron who are still at large, Israel has charged.

On July 26, Israeli border police arrested a 20-year-old Palestinian woman in Jerusalem’s Old City who tried to carry out a stabbing attack. “I wanted to stab a soldier or policeman over the situation in Gaza,” she said. Another Palestinian youth was arrested on Jerusalem’s tram July 13 with a pocket knife.