Making friends is good. This isn't about not making friends. This is about how to keep your job. Your boss gives you a job but your coworkers can take it away. Don't listen to advice that is meant for high level businessmen when you're not one. Don't mix worlds, don't find opportunities to create enemies, don't try to turn your workplace into your social life.
I think this advice is too absolute. So many people, in my experience, make positive and long-lasting friendships at work that I just can’t see your advice as being generally good. If anything, in some work cultures I think this kind of aloofness could be very negative - you could end up an outsider: unprotected, uninformed, and alone. I think you could also struggle to build the kinds of networks that can get you into the next job, or open doors in the future.
At the end of the day it’s obviously a personal choice about how you want to treat your work life. YMMV, etc...
This strikes me as a touch too misanthropic.
I went to school on a temporary basis with a whole load of people, who just happened to be my age. It was the same at university - people who happened to pick the same courses as I did. I never chose any of these people, yet I'm lucky enough to have made some wonderful friends, and I think that if I never took the risk to get to know anyone properly (not much risk, IMO - most people aren't putting up a facade that hides some horrible reality, at least not in my experience) my life would be much poorer.
Maybe give your colleagues another chance?