Troubled rapper DMX was sentenced to one year in prison by an Arizona judge on Thursday after admitting he violated his probation by drinking alcohol, court officials said.

The rapper, whose real name is Earl Simmons, was on probation for attempted aggravated assault and using a fake name to avoid paying a $7,500 hospital bill.

Arizona Superior Court Commissioner Christine Mulleneaux said DMX would receive credit for 113 days already served in prison while he awaiting trial.

The rapper, whose albums include "It's Dark and Hell is Hot," is two days shy of his 40th birthday. He has a long history of legal problems in Arizona that include drug, theft and animal abuse charges.