A Centereach doctor was sentenced Wednesday to 32 months in prison for illegally prescribing the narcotic painkiller oxycodone.

Michael Randall also was sentenced to 2 years supervised release by U.S. District Judge Sandra Feuerstein in federal court in Central Islip.

Before he was sentenced, Randall broke into tears as he read a statement that said: “I’m sorry I became reckless while treating my patients in my office … I am ashamed and humiliated … I will no longer be known as ‘the compassionate doctor.’ ”

Feds: Doctor illegally prescribed painkillers

The courtroom was filled with dozens of Randall’s patients, several using walkers and one in a wheelchair, with a several left outside in the hallway because all the seats were taken in the courtroom.

A number of his patients inside the courtroom burst out into gasps and tears when the prison sentence was imposed, apparently hoping he would get probation.

Randall, who will lose his license, had been arrested in May of 2014 and eventually charged in a 24-count indictment with illegally prescribing oxycodone, oxymorphone, methadone, and the muscle relaxant carisoprodol, which is also known as soma.

advertisement | advertise on newsday

But Randall eventually pleaded to one count of illegally prescribing oxycodone.

Randall also figured in the case of a former Patchogue man who was arrested in March for the killing of his wife five years ago, according to the Suffolk District Attorney’s office.

Joseph Jones, of Centereach, killed his wife, Nicole Tesla, because they both were addicted to oxycodone and she accused him of taking her pills, according to Assistant District Attorney Robert Biancavilla. Jones has pleaded not guilty.

Biancavilla said that Tesla had gotten her oxycodone pills from Randall.

Randall’s attorney, Anthony Colleluori, said at the time of Jones’ arrest it was not necessary for Biancavilla to mention his client in connection with the homicide case.

“It’s fine to kick a guy when he is down, but we don’t believe he was responsible for her death,” Colleluori said of his client Randall.

After Wednesday’s sentencing of Randall, Colleluori, said that he was grateful that the judge had sentenced his client under the guidelines. Feuerstein could have sentenced Randall to as much as 71 months in prison and three years supervised release.

Eastern District prosecutor Charles Rose declined to comment.