Park Geun-hye, right, interim leader of the ruling Saenuri Party, and party members smile as they watch a television reports from Wednesday’s parliamentary elections. (Kim Kyung-Hoon /Reuters)

President Lee Myung-bak’s ruling party emerged Thursday from a tight electoral race with a tenuous majority in parliament, avoiding a political setback just eight months before a presidential vote.

With all 300 National Assembly seats up for grabs in the quadrennial race Wednesday, the ruling conservative Saenuri Party — predicted just weeks ago as headed for defeat — was expected to win 152 seats, enough to prevent a split legislature.

The opposition Democratic United Party was on track to claim 127 seats, according to South Korea’s national election commission, and a minor liberal party, the Unified Progressive Party, was seen as likely to win 13.

The outcome signaled new promise for a conservative party afflicted by a string of recent scandals and dwindling support; the party, renamed earlier this year, has tried to distance itself from the unpopular Lee, while also energizing its base of older voters and committing to a few liberal reforms. Wednesday’s results, political analysts said, suggested that conservative party leader Park Geun-hye was pulling off the makeover — and emerging as a top candidate to replace Lee in the Blue House.

Political analysts had predicted a neck-and-neck race, reflecting a national shift to the left since Lee took office in early 2008 with broad support. His tenure has coincided with a widening income gap and escalating concerns about education costs and access to social welfare programs, issues that could also tip the presidential election scheduled for December.

Wednesday’s election provides the first clues to voter sentiments that could also drive the presidential race. South Korean voters, polls suggest, have become increasingly focused on economic and social equality issues and also feel that Lee has failed to resolve tensions on the peninsula by holding too hard a line against North Korea. Both main South Korean parties have recently advocated more engagement with the North.

Because National Assembly members are elected to four-year terms and presidents to five-year terms, this is the first time in 20 years that South Korea has conducted both elections in the same year. On Wednesday, 246 seats were directly up for grabs, with the remaining 54 to be divided among the parties based on their share of votes.

Polls of likely voters in the presidential race show Park, daughter of former South Korean president Park Chung-hee, gaining in popularity over the past two months to become the clear conservative front-runner.

“After this election, Park Geun-hye’s leadership is expected to be more concrete,” said Sohn Seok-choon, a professor at Seoul’s Konkuk University.

But Korean politics are famously fickle, and Park could face a number of tough opponents, including software executive Ahn Cheol-soo, a favorite among younger voters and progressives.

Ahn has not yet announced plans to run for president, but he posted a YouTube video this week encouraging voters to turn out. (Political analysts had said that a high voter turnout would help the liberals.) Ahn joked that he’d put on a miniskirt and dance if the voter turnout hit 70 percent.

According to South Korea’s Yonhap news agency, the turnout Wednesday was 54 percent.

Special correspondent Yoonjung Seo contributed to this report.