When two Nigerian tribal dignitaries visited Israel this summer, government officials here literally rolled out the red carpet and treated them to a well-publicized meeting with then-prime minister Yitzhak Shamir.

One day later, the Nigerian government, which has no diplomatic relations with Israel, took the unusual step of publicly disowning the visitors. Foreign Minister Ibrahim Gambari told a press conference in Lagos that his government was "embarrassed" by the unofficial trip, and the two dignitaries later were suspended from their ceremonial government positions.

The sequence of events illustrates the hopes Israel harbors and the obstacles it faces as it conducts a wide-ranging campaign to regain a diplomatic foothold in black Africa.

Eleven years after its diplomats were expelled from most of the continent in the aftermath of the 1973 Arab-Israeli war, Israel is slowly and painstakingly attempting to edge its way back.

Dangling economic and military incentives in front of governments sorely in need of both, Israel has persuaded two states -- Zaire and Liberia -- to reestablish full diplomatic ties, and it maintains second-level "interest offices" to manage diplomatic and consular affairs in eight more. In other countries including Nigeria, black Africa's most populous nation and biggest diplomatic prize, Israel has established a network of economic ties that officials hope some day will lead to more formal relations.

For Israel, the attempted return to Africa is an effort to break through the diplomatic isolation that has separated it from most of the Third World and edged it into unwelcome international pariah status, alongside right-wing governments such as South Africa, Taiwan and Chile. Coupled with a rapid expansion of Israeli trade and economic involvement in Africa, it is also seen as a way of countering Arab influence while pursuing Israel's strategic and financial interests.

But the road back has been difficult. The only two African leaders so far to return to the diplomatic fold -- Zaire's Mobutu Sese Seko and Liberia's Samuel Doe -- operate dictatorships. Israel's military and intelligence support for them has helped contribute to an unwanted image as a hired gun whose expertise is sought by African leaders more concerned with personal survival than national prosperity.

"Africa was our first and most serious diplomatic setback, so it's only natural for Israel to try to go back now," said Naomi Chazan, head of the African studies department at Hebrew University here. "My quarrel is with how we have gone about it. There's a strong conflict between two images: the Israel that makes deserts bloom and the bully, macho, militaristic defender of fragile regimes. It's counterproductive to try to be both."

Israeli diplomats would not speak for publication on the issue. But knowledgeable sources here said Israel sells arms regularly to six black African states and has "occasional" dealings with several others.

The only customer the government publicly has acknowledged is Zaire, which published reports suggest has bought between $8 million and $16 million worth of Israeli military equipment during the past two years. Other regular clients are said to include Chad, Gabon and the Central African Republic.

There also are unconfirmed reports here that during the past two years, Israel has supplied military assistance to the Marxist government of Ethiopia, which under the late emperor Haile Selassie was one of Israel's staunchest African allies. Israeli diplomats have acknowledged that their country shares some military interests with Ethiopia -- specifically concern over control of the strategic Bab el-Mandeb Strait near the mouth of the Red Sea -- but have publicly denied reports of military assistance.

Hanan Aynor, recently retired chief of the Foreign Ministry's Africa desk and a former ambassador to four African states, acknowledged his country's image problem in Africa but defended its effort to restore ties there.

"We have to guard ourselves not to be oversensitive," Aynor said. He noted that many western nations, including the United States, have given military assistance to Zaire. "We're no better or worse than anyone else. We deal with those countries who are willing to have us."

But even those who, like Aynor, are most in favor of Israel's new initiative concede the country probably can never recapture the status it enjoyed during the first decade of African independence.

Perceiving themselves as natural allies of the newly independent Africans, the Israelis poured in agricultural, health and military specialists in the 1960s and built hospitals and clinics. They gave training and financial support to black nationalists opposing colonial regimes in Mozambique and Rhodesia and trained between 6,000 and 7,000 African students in Israel. At one time, Israel boasted 27 embassies in Africa -- more than the United States.

In return, the African states were among Israel's staunchest supporters in the United Nations. "It was a glorious chapter in our short history," recalled Aynor.

But the chapter came to a sudden end in 1973. By the end of that year, every black-ruled state except Malawi, Swaziland and Lesotho, all of which operated under the influence of white-ruled South Africa, had severed relations. At the time, Israeli diplomats attributed the setback to Arab pressure.

In retrospect, the Israelis now are more willing to concede that other matters were also involved -- that the cutoff reflected a growing African assertion of solidarity with other Third World nations and the ascendancy of the Organization of African Unity, whose members include nearly a dozen Arab and Moslem-dominated countries.

African unity has been fractured seriously in recent years and African self-confidence drained in a decade marked by drought, political unrest and economic decline. There is disenchantment with the Arab states, which many Africans contend never have fulfilled earlier promises of financial assistance, along with a decline in the influence of Moscow, which had strongly encouraged the diplomatic break with Israel.

"Internal domestic needs are again dictating African foreign policies," said Chazan. "Countries are looking for alternatives."