Murray, a former eighth-round draft pick from Sweden, is headed into his fourth NHL season after breaking into the Sharks' regular lineup for the first time last year. The physical defenseman had one goal and nine assists in 66 games, with a plus-20 rating and 98 penalty minutes.
ESPN.com's Pierre LeBrun reported the deal is worth $10 million and will be worth $2.50 million annually.
"He brings an ingredient of toughness in addition to the rest of his game," Sharks general manager Doug Wilson said. "He's shown tremendous growth over the last few years, and we look forward to that continuing."
The signing cements Murray's spot on the Sharks' revamped defense alongside newcomers Rob Blake, Dan Boyle and Brad Lukowich, who has missed most of the Sharks' first workouts of training camp with a minor injury.
Pierre LeBrun covers the NHL for ESPN.com. Information from The Associated Press was used in this report.