Paula Bronstein, Getty Images
A family sleeps outside in a park Tuesday in Chengdu, which was near the epicenter of the 7.9 magnitude earthquake.

CHENGDU, China — Eight days after a massive earthquake struck southwestern China, the government began to grapple Tuesday with what may be its biggest quandary: what to do with what it said are the 5 million people left homeless by the disaster.

As the confirmed death toll rose to more than 40,000 on Tuesday, Chinese authorities issued an urgent appeal for tents. "The quake zones need more than 3 million tents," said Li Chengyun, the vice governor of hard-hit Sichuan province, according to the state-run news media. "If the public wants to donate, please donate tents."

The vice minister for civil affairs, Jiang Li, said that nearly 280,000 tents had been sent to the area and that 700,000 more had been ordered. But as he spoke, refugees continued to pour out of the devastated mountain regions, most bringing with them little more than the clothes on their backs.

"All these refugees have lost their homes," Li told The Associated Press. "Their clothes and possessions are buried. We are doing what we can to help them."

At one sporting goods store in Mianyang, dozens of people clamored for tents, pushing and shouting outside the small storefront and waving fistfuls of cash in the air. A worker at the store stood atop a counter facing them and handed out tents in black bags after taking their cash.

Parked on the street outside the store, men selling tents from their white van were similarly mobbed. Policemen were among those trying to buy tents.

Small tents cost $39, medium-size ones $46 and large ones $58.

When China began a three-day national mourning period on Monday, people across this country quietly understood it as marking an unofficial end to the search and rescue phase after the disastrous earthquake, which the government said had probably killed more than 50,000 people.

Yet reports of miraculous rescues, while diminishing, continued to be heard. The Chinese state news media reported Tuesday that 129 students and 10 teachers had been rescued in an isolated small town in Wenchuan County.

Early reports provided few details about the condition of the students or details of their rescue. The survivors were said to have been ferried to Chengdu, Sichuan's provincial capital, aboard eight military helicopters and taken immediately for medical care.

China's propaganda authorities seemed to reassert their control over the nation's news media on Tuesday. Newspapers around the country, which had enjoyed unusual freedom during the crisis, adopted solemn, color-free front pages and, in one commonly repeated headline, urged the nation to move forward with the exclamation, "Go, China!"

While many reporters and editors said that the uniformity signaled that a propaganda campaign was unmistakably under way, they said they mostly approved of the overwhelming emphasis on upbeat stories, national unity and the avoidance of hard questions.

"Whether it's time to ask questions, such as why most of the buildings that collapsed were school buildings, the conclusion of our newspaper is that, the moment for reflection has not come yet," said a Shanghai newspaper editor, who spoke anonymously because of the Chinese authorities' insistence that journalists not speak with foreign reporters.