The man, who threw the rock at the bottom of a 75-foot ravine, was pronounced dead at the scene after first-aid efforts failed, San Diego County sheriff's Lt. Glenn Giannantonio said Tuesday.
The agent declined to be treated at a hospital for an injury that Giannantonio described as minor. The agent and the man who died were not immediately identified.
The Border Patrol said in a statement that the agent feared for his life.
Two other people in the country illegally were arrested, the Border Patrol said. Kelly Thornton, a spokeswoman for the U.S. attorney's office in San Diego, said they will not be charged with a crime.
Two Border Patrol agents on foot had separated to cut off the group, and one of the agents was hit in the face with the rock, prompting him to fire, Giannantonio said. He didn't know how many times the man was shot.
The Border Patrol said the agent was attacked with rocks, including one that hit him in the head.
The shooting, which took place about 6:30 a.m. 4 miles east of San Diego's Otay Mesa border crossing, came amid debate over whether lethal force is justified as a response to rock attacks. The Border Patrol has long maintained that rocks are deadly weapons.
The Police Executive Research Forum, a nonprofit group that led a government-commissioned review, has recommended that the Border Patrol and its parent agency, Customs and Border Protection, or CBP, prohibit deadly force against rock-throwers and assailants in vehicles, Border Patrol Chief Mike Fisher told The Associated Press last year. The CBP rejected the proposed limits, which Fisher called "very restrictive."
Under current policy, agents can use deadly force if they have a reasonable belief that their lives or the lives of others are in danger.
Agents were attacked with rocks 339 times in the 2011 fiscal year, more than any other type of assault, according to the Department of Homeland Security inspector general. They responded with gunfire 33 times and with less-than-lethal force — a category that includes pepper spray and batons — 118 times.
Rock attacks fell to 185 instances in fiscal 2012, becoming the second-most-common type of assault. Agents fired guns 22 times and responded 42 times with less-than-lethal force.
The San Diego County Sheriff's Department is leading the investigation into Tuesday's shooting.
A spokesman for the union representing Border Patrol agents said he was confident the investigation would find the agent did nothing wrong.
"The easiest way to stop these incidents from happening is to stop attacking Border Patrol agents," said Shawn Moran of the National Border Patrol Council.
Mitra Ebadolahi, an attorney for the American Civil Liberties Union of San Diego and Imperial counties, said there wasn't enough public information to say if the agent was justified but that the episode raised familiar questions about whether the Border Patrol can respond to rock attacks with nonlethal force.
She said she was troubled that there appeared to be no independent witnesses.
"It's imperative for the agency to behave honestly and transparently," Ebadolahi said.
Copyright 2014 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.