A Southern California doctor accused of links to five overdose deaths and writing prescriptions for narcotics he knew would be sold on the street was arrested Tuesday.

Dzung Ahn Pham of Irvine in Orange County was charged with two federal counts of illegally distributing oxycodone.

He sold powerful narcotic prescriptions to drug addicts and dealers who resold the pills, according to the a criminal complaint. At least five people who received and filled prescriptions from Pham died of drug overdoses between 2014 and 2017, the Department of Justice's Central District of California said in a press release.

Prosecutors say that among Pham's text messages was one expressing concern after he received information that one of his prescriptions was tied to Ian David Long, the gunman who killed 12 people at the Borderline Bar and Grill in Thousand Oaks, the release said.

Dr Dzung Pham Irvine Village Urgent Care

Pham prescribed an undercover agent with the Drug Enforcement Administration hydrocodone, Valium, and muscle relaxer carisoprodol in the course of two visits. That combination of drugs is sometimes referred to as a "triple threat" for its deadliness, according to the criminal complaint.

The doctor allegedly charged $100 to $150 per office visit at an urgent care center he owns, and over the last five years deposited more than $5 million into personal bank accounts.

Investigators found Pham's prescriptions were banned by CVS Pharmacy years ago after he failed justify the number of opioid pills he was prescribing.

Pham is scheduled to appear in United States District Court in Santa Ana on Tuesday and faces a maximum sentence of 40 years in prison if convicted.