Tim Lambesis, frontman of the heavy metal band As I Lay Dying, was arrested Tuesday on charges of plotting to kill his estranged wife.

The musician, taken into custody in Oceanside, Calif., sought out the help of an undercover detective in the scheme, Reuters quoted San Diego County Sheriff's Department spokeswoman Jan Caldwell saying.

"The information came to us late last week. We acted quickly on it. I believe that we averted a great tragedy," she said.

Caldwell gave no clues about why Lambesis, 32, would want to kill his wife since the investigation is still in progress and it’s not known how police found out about the alleged murder plot.

A representative for As I Lay Dying’s record label, Metal Blade, has not yet commented on the frontman’s arrest.

Lambesis is the founding member of the band whose 2007 album “An Ocean Between Us” debuted at No. 8 on the Billboard 200 list. Their latest album, “Awakened” was released last year.

As I Lay Dying, which was nominated for a Grammy in 2008, had been scheduled to embark on a U.S. tour later this month, according to the band’s website.

In 2009, Lambesis missed some tour dates while his band was touring with Lamb of God since he was in the middle of adopting a child from Ethiopia, BlabberMouth.net wrote.

In January the musician told Loudwire the adoption process inspired some of his lyrics:

"My kids are adopted and I've visited their country; they're from Ethiopia, and that was eye-opening to what the world is really like, at least a third of the world. I think that just influences my entire worldview. Even if I'm not necessarily writing a song about humanitarian work, I'm writing a song about what truly makes us happy in life, and those types of think that have been influenced by my experiences."

The singer is scheduled to appear in San Diego District Court on Wednesday or Thursday.