Alexandria Sheriff Michael Norris easily turned aside a Republican challenger yesterday, capturing 57 percent of the vote in a party primary to defeat Edward L. Clark, a retired railroad agent.

In the only other primary in Northern Virginia, Republican Richard N. Vannoy, a 50-year-old business manager and associate pastor of Calvary Road Baptist Church in Alexandria, edged out Robert E. Murphy, a 52-year-old merchant, for the right to oppose Democratic state Del. Vivian E. Watts of Fairfax County in the fall elections. The vote in the Annandale district was 397 to 359.

The turnout in Alexandria also was light despite what some called a dirty campaign that focused on allegations about Norris' life style and his friendships with gays.

"The other side put on a valiant effort," said Norris, who received 1,040 votes to Clark's 738. "But the majority of the people here are not willing to buy any more garbage," said the sheriff. "The best man won."

Norris, Alexandria's sheriff since 1977, will face Jim Dunning, a federal probation administrator, in Virginia's Nov. 5 elections. Dunning is running as an independent because he is barred as a federal employe from running a partisan campaign. Last week he gained the endorsement of Alexandria's Democratic Party.

Clark, 65, who retired in 1981 after a career as a railroad police officer, could not be reached for comment, but his supporters were still angry at the sheriff. "What Norris has done and the way he acts is embarrassing," said William M. Glasgow, Clark's campaign chairman. "I think the people of Alexandria deserve what they get."

For Norris, 37, the victory was seen by some as a show of support for the job he has done as sheriff. Clark said repeatedly during the campaign that Norris was a good sheriff, but that many Alexandrians were critical of his life style.

Norris received wide praise in the past for improvements made during his tenure as sheriff. But the voluble law officer frequently entangled himself in controversy.

Clark, who was making his first bid at elective office, had been encouraged by a group of Republicans who said they were offended by statements about his friendships with gays that Norris made last year in a Washington Post interview. Norris has said that his comments were taken out of context.

But the sheriff, a former Alexandria police officer, acknowledged that he has caused controversy during his stewardship of the sheriff's office, which oversees security at the city courthouse, runs the local jail and serves court papers.

Most recently, he was named as a principal figure in a widely publicized police drug investigation in Alexandria but a special grand jury found no merit to the allegations.

Many people in Alexandria say he will face a tougher battle this fall. "I look forward to a tough and good race in the fall," said Mayor-elect Jim Moran, a Democrat. "I think it will be a campaign run on the issues."

Vannoy, a conservative, will challenge Watts, who is highly regarded in the state legislature and considered a strong candidate.

Both Vannoy and Murphy were relatively unknown, although Murphy ran an unsuccessful campaign for the GOP nomination for state Senate in 1983 against former Fairfax City Mayor John W. Russell, who also won the general election.

Vannoy, making his first bid for office, had the support of Republican leaders. He outspent Murphy 3 to 1 in the 29,000-voter district.

"I think it's going to be an awfully tough race," Vannoy said in an interview last night. Watts "will be a formidable opponent. I'm coming from zero name identification and I'll have to work triply hard."