At least 30 persons were reported killed and more than 40 wounded in an eight-hour battle between government troops and communist rebels in the southern Philippines, amid signs that the guerrillas are stepping up a military campaign against the administration of President Ferdinand Marcos.

The battle yesterday, at the town of Bayog about 90 miles northeast of Zamboanga on the southern island of Mindanao, killed 20 guerrillas of the communist New People's Army and wounded 30 others, the military reported today. It said 10 members of an infantry battalion, including a lieutenant, were killed and 13 wounded in the clash, one of the heaviest in a recent upsurge in fighting on Mindanao.

The southern military commander, Maj. Gen Delfin Castro, ordered all roads in the area closed, and an Army spokesman said the infantry battalion was still pursuing the guerrillas, who had attacked an Army camp.

This latest major clash comes amid indications of growing willingness by the New People's Army to engage government troops in more conventional battles instead of limiting operations to hit-and-run guerrilla raids.

Politically, the Communists seem to be gaining more popular acceptance.

In the largest recent leftist demonstration against American military bases, about 5,000 persons in front of the U.S. Embassy Nov. 30 openly chanted slogans supporting the guerrilla army.

Prorebel posters have been proliferating on walls for the first time, and some noncommunist political groups have been supporting the position of the communist army.

These developments have coincided with a period of persistent rumors that Marcos is in ill health.

Government and western diplomatic sources say that the new tactics of the rebel army may be a test of capabilities with a view to advancing to a new stage of Maoist "people's war" against the government but that the insurgents may be finding the effort too costly.

In any case, the fighting has raised concerns in the south that the security situation there is deteriorating.

The government maintains that the situation is under control, but opposition politicians and some local military commanders have expressed alarm lately about growing rebel strength.

Some of these concerns were aroused last month when about 200 communist insurgents riding in trucks commandeered from a logging camp attacked the fortified base camp of an Army company at Lianga Bay in the Mindanao province of Surigao del Sur, according to government and diplomatic sources.

A diplomat said the rebels had "penetrated and overrun" the base and captured a number of weapons, including machine guns, after having cut nearby bridges and deployed blocking forces to prevent reinforcements in a "very professional" operation. However, rebel losses were "quite high," the diplomat said.

According to Defense Minister Juan Ponce Enrile, 37 rebels were killed in that attack.

But he denied that they had succeeded in overrunning the base, insisting instead that the 40 to 45 troops had managed to hold off the attackers.

"That was their first effort at conventional-type warfare" instead of the usual ambushes, Enrile said in an interview Thursday, "but it gave them a little bit of second thoughts, and it has not been repeated since."

However, in what appeared to be a similar attack, the military reported today, four soldiers were and four wounded Wednesday when 100 guerrillas attacked about 30 soldiers at an Army installation in Mindanao's Davao del Norte Province.

The military said the rebels, wearing fatigue uniforms and driving two dump trucks, were driven back after a half-hour gun battle, losing three of their number killed and eight wounded.

Sketchy reports of yesterday's attack at Bayog also indicated that the rebels had attempted a concerted assault against a sizable military detachment.

In the interview, Enrile said the new armed forces acting chief of staff, Lt. Gen. Fidel Ramos, had boosted military morale in recent field trips and had just sent Marcos a "very far-ranging study of the overall counterinsurgency situation."

Enrile said the classified document reviews the military's problems and proposes solutions, including recommendations to coordinate military and civilian government efforts in areas of insurgency.

"We have to continue our military effort and improve on our political action in order to retain the loyalty of people who support the government, win the confidence of people who are not committed either way and try to recover some of the people who support the insurgents," Enrile said.

Enrile estimated the rebels' strength at 8,000 to 8,500 armed fighters. However, Ramos last week gave a figure of 10,000 to 12,000.

Earlier this year the government and military were putting the number at less than 5,000.

Ramos reported last month that the New People's Army had killed 2,650 persons, including 800 government troops and 65 civilian government officials, and caused about $10 million worth of property damage in about 3,500 ambushes, raids and other incidents during the first 10 months of the year.

He said 895 communist guerrillas were killed in clashes during this period.

In a meeting Friday, Enrile informed Marcos that "the situation in Mindanao is stabilizing," the president's office reported. It quoted Marcos as expressing satisfaction over military and civilian authorities' handling of the situation.

However, a former opposition legislator from Mindanao, Reuben Canoy, warned that the island "may fall to the Communists in five years or less" unless drastic steps are taken.

Calling for a major development effort, Canoy said the military was no longer able to control the situation and was losing the battle because it lacked popular support.

He said the rebels were acquiring more recruits and firepower, enabling them to overrun military installations and occupy towns.

At the same time, the new mayor of Zamboanga, Susan de los Reyes, appealed for help in a deteriorating security situation in the southern city, where her popular predecessor, opposition mayor Cesar Climaco, was assassinated Nov. 14.

Since the assassination by an unidentified gunman, a number of violent incidents have rocked the city, including a protracted gun battle between Philippine marines and members of an armed Moslem clan suspected of involvement in the mayor's murder.

Four persons were killed and 18 wounded in the battle, which ended with the surrender of 17 clan members, who included seven soldiers and policemen.

De los Reyes complained that following Climaco's death, four families have been fighting for control of smuggling and extortion in the city and that their members include military officers and soldiers.

In addition, there have been reports that communist rebels may be stepping up their activities in the city.

In the latest incident, one government militiaman was killed and 13 others wounded in Zamboanga yesterday when unknown men threw a powerful bomb at their headquarters, the military reported.