Forced on the defensive on the battlefield, Libya’s rebels are also struggling in the economic war of attrition with Moammar Gaddafi, despite the backing of the West.

Global efforts to isolate Gaddafi and cut off his economic lifeline have put significant pressure on his government. But President Obama and other NATO leaders may find that sanctions do not bring Gaddafi to his knees as quickly as they would hope, if at all.

The panic that gripped the Libyan economy at the height of the crisis has substantially abated, and the government has implemented a series of measures to cope with the sanctions and the loss of hundreds of thousands of foreign workers.

The economic situation appears more chaotic in the rebel-held east, with the collapse of much of the public sector and the shuttering of oil production.

“In the long run, sanctions will be quite devastating,” said Mustafa Fetouri, MBA program director at the Academy of Graduate Studies in Tripoli. “But we have had this situation before, and we have the experience to deal with it.”

Keeping the economy afloat amid tight international sanctions is costly, and Finance Minister Abdulhafid Zlitni said in an interview that the government’s money might run out “in a few months.”

Nevertheless, the British-educated economist was optimistic that this would buy Gaddafi’s government enough time — to probe for gaps in the international community’s resolve, to find a compromise that keeps Gaddafi in power or just to persuade old friends to help.

“Just go back to history,” Zlitni said. “When sanctions were imposed in the 1990s, Africans just broke them. They came over here with their planes and their presents.”

The current sanctions are considerably tougher than those imposed by the United Nations in 1992 and 1993 because of Libya’s alleged role in the bombing of a Pan Am airliner over Lockerbie, Scotland.

Nevertheless, cracks are appearing in the global coalition to isolate Gaddafi, after the African Union proposed a peace plan this week that called for a cease-fire and dialogue but would seem to leave Gaddafi firmly in power. Gaddafi backed the plan, but the rebels rejected it.

“In the international arena, we are seeing a lot of interventions to find an end to this, and this is what makes me optimistic this is going to end soon,” Zlitni said.

The bite of sanctions

In the meantime, sanctions are clearly having an effect in the areas under Gaddafi’s control, though his government appears to have found a way to manage.

In Tripoli, fuel is being rationed to a tank a week, while cash withdrawals from banks have been capped at the equivalent of $400 a month. Interest rates will be doubled this week to attract money, much of which is traditionally kept at home, back into the banking system.

The government has increased public-sector salaries by 50 percent to encourage Libyans back to work to fill the gaps left by the exodus of a substantial proportion of the workforce.

That exodus left fuel pumps unmanned and bakeries, normally run by Egyptians, shuttered. But Libyans are gradually stepping in. The huge lines of a week ago at gas stations have all but disappeared, and bread shortages have eased after young women were enlisted to help. On the black market, the Libyan dinar shot up to 3 against the dollar, from 1.3 before the crisis, before pulling back to less than 2.

Hospitals are functioning, but many factories and shops remain closed, construction work has stalled, and imported foods are beginning to disappear from the shelves. The price of cooking oil has risen more than fourfold, as has the cost of a packet of spaghetti.

But Libya has more than a decade of experience living with, and subverting, sanctions. And the harder they bite ordinary people, the easier it will be for Gaddafi to blame the West, as he is doing with some success, Fetouri said.

Growing concern in east

In the east, the fighting and the temporary partition of the country have all but destroyed the economy. Most of the country’s oil comes from the east, but Gaddafi’s forces have worked hard to disrupt production, which has halted. Rebels shipped out a tanker of crude last week, with Qatar acting as middleman, but just two tankers worth of oil remain in stock.

The vast majority of Libyans in the east work in the public sector and were paid out of Tripoli before the fighting began. Rebels have managed to keep salaries coming, but money is running out. Electricity is cut off for two hours a day, and unless oil production resumes, the diesel needed to power the generators will run out within two to three months, officials say.

Across the rebel stronghold of Benghazi, city engineers, doctors, lawyers and businessmen sit at home and wait for the violence to end. Lines for bread and gas are lengthening.

Gaddafi loyalists retain control of Ras Lanuf, home to the country’s largest refinery, and there is continued fighting over the oil town of Brega. Rebels still believe they have the stronger hand economically as long as they control the border with Egypt and receive international support.

But for now, securing the oil fields “is our biggest source of concern,” said Ali Tarhouni, finance minister in the Transitional National Council, the self-appointed rebel government.

In Tripoli, Zlitni is trying to make a virtue out of a necessity, arguing that western Libya will just have to live without oil.

“Oil is not always a good thing. It is a depleting asset; one day it will stop,” he said. “If people don’t realize this and pull up their socks, there is going to be a disaster.”

Oil revenue has made many Libyans lazy, he said. “If you have children, sometimes you have to smack them to make them behave themselves. You don’t like to do it, but you have to.”

Correspondent Leila Fadel contributed to this report from Benghazi.