SANTA CLARA -- Travis Johnson's summer included some rare relaxation while he kept himself in shape waiting and hoping for a call from an NFL team.

Turns out, the team just down the street was the one that made that phone call and signed the former San Jose State star to a three-year contract. Johnson made his practice debut on Tuesday.

He said he was driving home from a wedding on Sunday when the 49ers called asking if he was willing to make the switch to inside linebacker. A collegiate defensive end, he had already transitioned to outside linebacker because of his 6-foot-1, 240-pound frame.

The 49ers, needing to sign a player to replace injured linebacker Darius Fleming, brought Johnson to the 49ers facility on Monday for a workout.

"After the workout they said, 'Do you want to play for us?'," Johnson recalled. "I said, 'Of course.' "

Outside of the relaxation, the summer time hadn't been easy for Johnson. He enjoyed having some free time to spend with his wife Hannah, whom he married in April. But it was tough thinking about the prospect of not playing football.

"I didn't know when or where I'd get a shot," Johnson said. "It could be tomorrow, it could be a year from now. I just kept working and just getting ready as best I could."

Now the lifelong 49ers fan, who played high school ball roughly four miles away at The King's Academy in Sunnyvale and then about 12 miles away at Spartan Stadium, is living his dream.

"It was awesome to be able to stay here," Johnson said. "Because you're around the Niners and grow up watching the Niners and then you get to play for them, it's just a great feeling. It's cool to be able to go out on the field with them."

He's still very much in the learning mode, trying to pick up the nuances of playing middle linebacker. He's always been an edge rusher, so switching to outside linebacker wasn't as much of a challenge. But moving inside definitely is.

"It's a whole new world I feel out there," Johnson said. "D-end and outside linebacker, you're blitzing a lot, what I've been doing my whole life. Now there's some blitzing, but it's all up the middle, and now you're playing in coverage and I haven't really played in coverage before, especially in a game."

During his first practice Tuesday, Johnson mostly observed and took the field for some special teams work. As he learns the defensive playbook, he hopes to see some time on the field. Realistically, it's going to be tough for him to earn a spot on the 53-man roster.

"When you bring in a guy like that as this stage, you don't really know what you're hoping for," defensive coordinator Vic Fangio said. "He's going to get his chances as a linebacker, primarily as an inside right now, maybe eventually outside. When he gets his opportunity, he's going to have to show something to catch our eye to count him in the mix."

With Johnson's strong work ethic, he could showcase himself as a player who could be valuable on the practice squad and eventually work himself into a role with this or any other NFL team.

"I just knew that I could play and if someone took that shot with me they'd be able to see it," he said. "I was hoping for something, I got it, now it's time to make the most of it."

Follow Jimmy Durkin at Twitter.com/Jimmy_Durkin.