Saying it was his day to die, Karl Thomas Holmberg unleashed a barrage of high-powered rifle rounds through his bedroom door at police officers who had come to his home in Glendorado Township, Minn., to serve a warrant.

The police fired back before retreating, but, remarkably, no one died in the exchange Thursday morning inside Holmberg's house in rural Benton County.

The details of the close-range shootout were provided Friday in the Benton County attorney's criminal complaint against the 64-year-old Holmberg, who faces six charges of attempted murder of a police officer and six charges of first-degree assault of a police officer.

Holmberg, who was shot in the foot, was released from the hospital Friday afternoon and booked into Benton County jail.

All the police officers are expected to survive, but two who had substantial injuries remained hospitalized at North Memorial Health Hospital in Robbinsdale. One of the two was shot in the right arm while the other was shot in the chest and hip.

According to the complaint:

Members of the Sherburne County Drug Task Force on Thursday at 7:10 a.m. went to Holmberg's house at 225 190th Av. NE. near Princeton and knocked on his door while shouting "Police! Search warrant!" several times.

Holmberg was watching the police on a video monitor from his bedroom, according to his wife, Dorine, who was in the house and later interviewed by investigators. He told her it was "his day to die," and had several guns laid out on the bed, she told investigators.

Six members of the drug task force knocked down the front door and entered into a living area, where they could hear a man's voice.

When the door was kicked in, Holmberg began saying something like, 'Don't do it, don't do it," according to his wife. He then opened fire through his bedroom door with a rifle shooting .223-caliber rounds. He told herto join the fight and when she refused, he called her a coward.

The officers quickly retreated from the house. All but one had been shot: Officer A (the undercover officers were not identified in the criminal complaint) was shot in the right arm, Officer B in the chest and hip, and Officer C in the hand. All three officers were flown by helicopter to North Memorial. Officers D and E were shot and taken by ambulance to St. Cloud Hospital where they were treated and released.

After hours of negotiations, Holmberg surrendered to authorities and was arrested. He told BCA investigators who interviewed him at North Memorial that he didn't think police had the right to be at his house. He said he told them to leave before shooting.

A search of his home found the .223 rifle, handguns, a shotgun and one of the officer's weapons along with .223 shell casings in the bedroom and shell casings in the living room.

Holmberg's criminal history includes a felony drug conviction in 2006 and another conviction for the same offense in the mid-1980s, according to court records. He was given a one-year stay of imposition of sentence for the 1986 drug possession charge, and was on probation from 1999 to 2003 in Benton County for a drug-related charge of aiding and abetting, according to the Minnesota Department of Corrections. He was also on supervision for a fifth-degree drug charge in Kandiyohi County from 2006.

The near-deadly shootout came during one of the riskiest maneuvers in law enforcement, breaching a door to serve a warrant. Law enforcement officials who are not connected to the Benton County incident but have had experience serving warrants said it's incredibly difficult because so much is unknown.

"Your heart just sinks for the officers and their families, knowing they went to work just like they've done so much in the past, and there's someone out there trying to kill them just for doing their job," said Ken Sass, the statewide gang and drug coordinator for the Minnesota Department of Public Safety.

During his years with the St. Paul Police Department working in narcotics enforcement, Sass estimated he went on hundreds of drug search warrants.

"Just tactically, you're all bunched up by the front door, all in one spot," he said, explaining the risk. "It's called the 'fatal funnel' for a reason, when you go into a doorway or a new room."

Maj. Rick Palaia, who is in charge of the Hennepin County Sheriff's Office investigative bureau, said there are so many unknowns serving such warrants. "You don't have a for-sure way to know who's in there. ... You don't know who the guests are, how many weapons they have, where the weapons are, if they are under the influence of drugs or alcohol. You don't know what their mindset is when you're going through that door."

The police officers shot in Glendorado will all survive, but the shooting will still be traumatic for them and their families, added Sass.

"The fact they're not mortally injured doesn't diminish the facts of the incident they went through. Getting shot at is a horrible situation. Getting injured is further horrible. It's still a very dangerous, pointed moment for everyone out there."