Promotion rivals Cardiff had attempted to ambush Leeds' plans to make O'Brien's loan move permanent, but the central defender turned down a better deal from the Welsh club.
After their draw with Middlesbrough, Grayson said of O'Brien: "His overall experience is vital to us because we've got a young team with experienced defenders like Paddy Kisnorbo and Richard Naylor out.
"So to have him around and sign him after major competition for his signature is obviously very pleasing.
"We've spoken already about what we're trying to achieve here and players have got to see the bigger picture and see what's in the group and what we're capable of doing.
"He wouldn't have been happy dropping out of the Premier League to come to a club that was happy with mid-table mediocrity."