A Marine opened fire on two of his comrades on Marine Corps Base Quantico in Virginia late Thursday, then turned the gun on himself, military officials said.
The incident left all three Marines dead, The Associated Press reported.
According to Marine Corps spokesman Agustin Solivan, the suspected gunman shot one Marine, then barricaded himself inside the staff barracks area of the Officer Candidates School.
When police entered the barracks early Friday, officers found two more bodies, including that of the gunman. He died from an apparent self-inflicted gunshot wound, Solivan said.
The names of the dead were being withheld pending notification of next of kin. The suspected gunman and both victims -- a man and a woman -- were staff members at the school, a senior defense official told NBC News.
A relationship dispute is believed to be the motive for the shooting.
The incident prompted a base-wide lockdown. On the Quantico Facebook page, base residents were ordered to remain inside with doors locked, and to follow all instructions being delivered over the public address system.
The base lockdown was lifted just before 3 a.m. on Friday.
More from the Associated Press:
By MATTHEW BARAKAT
QUANTICO, Va. — A Marine killed a male and female colleague in a shooting at a base in northern Virginia before killing himself, officials said early Friday.
Authorities were called to the scene at Marine Corps Base Quantico around 10:30 p.m. Thursday, where they found one Marine dead at a barracks, base commander Col. David W. Maxwell told reporters.
Authorities later found a second victim dead, along with the body of the suspected gunman, who died of self-inflicted gunshot wound.
A base spokesman initially described the situation as a standoff. Maxwell said later in the morning that there was no standoff. Base spokesman Lt. Agustin Solivan later clarified that after the first shooting, police had the shooter "isolated" in a barracks dorm room at the base's Officer Candidates School.
No names were immediately released but officials said all three were staff members at the school.
Solivan said the shooting was isolated to the school and authorities were confident there were no other casualties. The base was put on lockdown after the shooting but the lockdown was lifted early Friday. During the lockdown, residents were warned over a loudspeaker to stay inside.
The shooting is the second tragedy the Marine Corps has faced this week. Seven members of the 2nd Marine Expeditionary Force were killed Monday when a mortar shell exploded in its firing tube during an exercise at Hawthorne Army Depot in Nevada. Eight others were injured.
The Quantico base, which is about 37 miles south of Washington, is also home to the FBI's training academy. Its Officer Candidates School is the equivalent of basic training for Marines interested in becoming officers.
According to a Marine Corps website, the mission of Officer Candidates School is to train, screen and evaluate candidates. The training includes both academics and physical training such as endurance hikes and obstacles courses. Marines become second lieutenants on graduation from the 10-week program.
In 2010, the Quantico base was one of several targets of an ex-Marine reservist who, during five nighttime shootings, fired on military targets including the Pentagon. Yonathan Melaku, on two separate occasions, fired at the National Museum of the Marine Corps in Quantico. No one was injured and Melaku was ultimately sentenced to 25 years in prison.
Also on HuffPost:
Swat team members secure the scene near Sparks Middle School in Sparks, Nev., after a shooting there on Monday, Oct. 21, 2013. Authorities are reporting that two people were killed and two wounded at the Nevada middle school. (AP Photo/Kevin Clifford)
Sandy Hook Elementary
Molly Delaney, left, holds her 11-year-old daughter, Milly Delaney, during a service in honor of the victims who died a day earlier when a gunman opened fire at Sandy Hook Elementary School in Newtown, Conn., as people gathered at St. John's Episcopal Church , Saturday, Dec. 15, 2012, in the Sandy Hook village of Newtown, Conn. The massacre of 26 children and adults at Sandy Hook Elementary school elicited horror and soul-searching around the world even as it raised more basic questions about why the gunman, 20-year-old Adam Lanza, would have been driven to such a crime and how he chose his victims.
Police secure the scene near Sparks Middle School after a shooting in Sparks, Nev., on Monday, Oct. 21, 2013. Authorities are reporting that two people were killed and two wounded at the Nevada middle school. (AP Photo/Kevin Clifford)
Clackamas Town Center
A security guard looks over the food court at the Clackamas Town Center mall as it opens, on Friday, Dec 14, 2012 in Portland, Ore. The mall is reopening, three days after a gunman killed two people and wounded a third amid a holiday shopping crowd estimated at 10,000. The shooter, Jacob Tyler Roberts, killed himself after the attack Tuesday afternoon.
St. Vincent's Hospital Shooting
Birmingham police arrive at the scene of a shooting at St. Vincent's Hospital on Saturday, Dec. 15, 2012 in Birmingham, Ala. Authorities in Alabama say a man opened fire the hospital, wounding an officer and two employees before he was fatally shot by police. Birmingham Police Sgt. Johnny Williams says the officer and employees suffered injuries that are not considered life-threatening.
Sikh Temple Shooting
Mourners attend the funeral and memorial service for the six victims of the Sikh temple of Wisconsin mass shooting in Oak Creek, Wis., Friday, Aug 10, 2012. The public service was held in the Oak Creek High School. Three other people were wounded in the shooting last Sunday at the temple. Wade Michael Page, 40, killed five men and one woman, and injured two other men. Authorities say Page then ambushed the first police officer who responded, shooting him nine times and leaving him in critical condition. A second officer then shot Page in the stomach, and Page took his own life with a shot to the head. (AP Photo/Jeffrey Phelps)
July 2012: Aurora, Colorado
A policeman stands outside a Century 16 movie theater in Aurora, Colo., where a heavily armed man opened fire, killing at least 12 people and injuring 50 others.
May 2012: Seattle, Wash.
Friends, family and employees react after a shooting at Cafe Racer in Seattle on May 30, 2012. A lone gunman killed four people Wednesday -- three were shot to death at a cafe, and a fourth in a carjacking. The gunman later killed himself.
April 2012: Oakland, California
Alameda County Community Food Bank workers move a memorial from a parking spot next to Oikos University in Oakland, Calif., Monday, April 23, 2012. Some students and staff members have arrived to resume class at Oikus University, the small California Christian college where seven people were shot to death earlier in April.
November 2009: Fort Hood, Texas
Panou Xiong, center, is comforted by family and friends following a Remembrance Ceremony commemorating the one-year anniversary of the worst mass shooting on a U.S. military base, where 13 people were killed and dozens wounded,, Nov. 5, 2010 in Fort Hood, Texas. Xiong's son, Pfc. Kham Xiong, was killed in the shooting. <em><strong>CORRECTION:</strong> This slide originally said that the Fort Hood shooting took place in November 2010. The shooting took place in November 2009.</em>
March 2009: Kinston, Alabama
The charred Kinston, Ala. living room where suspected gunman Michael McLendon allegedly killed his mother Lisa McLendon, is photographed Wednesday, March 11, 2009. Authorities were working Wednesday to learn why a gunman set off on a rampage, killing 10 people across two rural Alabama counties.
August 2007: Blacksburg, Va.
An unidentified family member of slain Virginia Tech student Daniel Alejandro Prez Cueva, pauses at his memorial stone after the dedication of the memorial for the victims of the Virginia Tech shooting in Blacksburg, Va., Sunday, Aug. 19, 2007. More than 10,000 people gathered on the main campus lawn as Virginia Tech dedicated 32 memorial stones for those killed by a student in a mass shooting on campus last April.
April 1999: Littleton, Colo.
This aerial shows the news media compound near Columbine High School in Littleton, Colo., April 21, 1999. Media from around the world poured into the area after 15 people were killed during a shooting spree inside the school.