Season 1: Castle learns that Kate's mother died. He talks Espisito into letting him take a look at the case file (somewhere around the 2nd or 3rd episode). He brings up using his resources to help Kate find the killer (I think the 5th episode). Kate basically bites his head off and tells him that if looks into her mother's murder, their partnership is over. Castle being Castle doesn't listen and his pathologist friend, Dr. Clark Murray,tells him that Kate's mother's murder fits a pattern of murders with a distinctive signature. Martha tells Castle he has to tell Kate. And tell her he does in the season finale, but you don't actually get to see that conversation, just the very beginning of it.
Season 2: At the start of the season, the relationship between Castle and Kate is strained because of Castle's digging into her mother's murder but Castle eventually apologizes. Her mother's murder isn't revisited again until "Sucker Punch" (13th episode). The investigation into the murder of an Irish mobster leads back to Kate's mother when Lanie notices that the way the mobster was killed is identical to the previous murders Castle discovered through Dr. Murray's observations of the stabbings. After Lanie confers with Dr. Murray, she reveals to Kate that the man who murdered the mobster is the same man who murdered her mother. Eventually Beckett discovers that the brother of the mobster, Dick Coonan, is the assassin who killed his brother and killed her mother. Kate is forced to shoot Coonan when he takes Castle hostage and she isn't able to save him and thus loses a connection to her mother's murder.
Season 3: Again in this season, the murder of Kate's mother is not revisited again until the 13th episode, "Knockdown". Beckett gets a call from a retired cop named John Reglan, who was the lead detective in the murder case of Joanna Beckett. He tells Beckett to meet him as he has information for her about her mother's murder. Before he can impart any information beyond telling Beckett that there was more to death of Kate's mother than she knew, he's taken out by a sniper shot. The person who kills Reglan is Hal Lockwood. Beckett tracks down another retired cop, Dave McCallister, who was Reglan's partner. He first misleads Beckett by throwing her onto the trail of this drug lord that used to rule the neighborhood where her mother was killed. Her resulting interrogation of Vulcan Simmons gets her thrown off the case.
Castle tries to encourage Beckett to continue investigating and Kate reveals to Castle her murder board for her mother's death. Together, they learn that Joanna Beckett did lead a series of protests against the bad elements in the neighborhood where she died but in the days leading up to her death, Kate's mother had taken on the case of a mobster in prison for life who claims he was innocent, Joe Pulgatti. Talking to Pulgatti, he reveals to Beckett that her mother and her mother's friends were all murdered because of what took place back then. Back then, there were rumors that mobsters from all five families were being kidnapped and held for ransom and that it was a trio of cops who were doing it. When this trio tried to kidnap Pulgatti, Pulgatti was not alone at the time, there was an undercover FBI Agent named Armand there too. In trying to prevent the kidnapping, Armand was shot and killed and Pulgatti went to prison for the crime since the cops could easily frame him.
Beckett gets put back on the case and brings in McCallister who confirms the story. He also tells them that all this investigating into Joanna's death has made the people behind the consipracy nervous and that's why Lockwood was sent out to silence Reglan. McCallister doesn't say more than that and resigns himself to living on borrowed time. Eventually Beckett captures Lockwood with the help of Castle. She promises Lockwood she will be in weekly to see him to find out who else was behind her mother's death.
Cut to the season finale, "Knockout". Hal Lockwood uses his assassination of McCallister as means of engineering an escape from the courthouse. After Hal Lockwood's escape, Castle and Beckett try to determine who the 3rd cop is. Eventually all roads lead to Captain Montgomery. When he was younger, he was a rookie cop who accompanied Reglan and McCallister on their kidnapping raids. And it was his gun that Armand went after and in the ensuing scuffle, Armand was shot and killed. He used his chance to help and mold Beckett as a means of his redemption. He also made a deal to protect Beckett by not allowing her to get to far into the reasons and people behind her mother's death. Due to Beckett's investigational obsession returning, the main guy behind it all was once again nervous as to what Beckett might discover and engineered Lockwood's escape who sent a warning to Montgomery. Either help Lockwood set up Beckett or put your own family in danger. Montgomery did neither. He sent files and documents he kept as insurance (I'm guessing) to someone, I think Castle, and then met Beckett at the airport to confess everything. Then he had Castle take Beckett away to protect her and he had his last shot at redemption by taking out the shooters and Lockwood. The one more important piece of information that Montgomery told Beckett was that there was another man who discovered their shooting of the undercover FBI agent and took all the ransom money the trio had accumulated as the price for his silence. This man then used that money to become richer and more powerful and very connected. The finale ends of course with the cliffhanger of Kate getting shot at Montgomery's funeral and Castle's confessions of his feelings.
A great twist and possible theory as to who the mastermind is that I and others have put forth is that the mastermind is the mayor, Castle's friend.
Anyway, hope all this helps.