TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Beej's Guide to Network Programming

333 pointsby nnainabout 8 years ago

20 comments

Uptrendaabout 8 years ago
Oh boy, this one brings me back. I can&#x27;t tell you how many times I read this guide back in the day. Beej was the bomb when it came to network programming. Another great resource for network programming is <a href="http:&#x2F;&#x2F;www.madwizard.org&#x2F;programming&#x2F;tutorials&#x2F;netcpp&#x2F;" rel="nofollow">http:&#x2F;&#x2F;www.madwizard.org&#x2F;programming&#x2F;tutorials&#x2F;netcpp&#x2F;</a> which is aimed more at Windows users. Failing that, there&#x27;s the classic Unix Network Programming Vol 1 and 2 which gives a good outline of what to expect.<p>As it turns out, there are some really subtle aspects of network programming and these guides tend to cover them well.
评论 #13986007 未加载
评论 #13988319 未加载
评论 #13989071 未加载
jshmrsnabout 8 years ago
While we&#x27;re sharing network programming guides, the Gaffer on Games guide on multiplayer networking is another great read <a href="http:&#x2F;&#x2F;gafferongames.com&#x2F;networking-for-game-programmers&#x2F;" rel="nofollow">http:&#x2F;&#x2F;gafferongames.com&#x2F;networking-for-game-programmers&#x2F;</a>
评论 #13988585 未加载
digganabout 8 years ago
Haven&#x27;t come across this before and it looks like a really valuable resource and since it&#x27;s licensed under Creative Commons, I took the freedom to rehost it on IPFS here: <a href="https:&#x2F;&#x2F;ipfs.io&#x2F;ipfs&#x2F;QmeZJ6QQ4gztfrNDFHfBtBi4KGv6w87PcVKqqJKuM8UWiS&#x2F;" rel="nofollow">https:&#x2F;&#x2F;ipfs.io&#x2F;ipfs&#x2F;QmeZJ6QQ4gztfrNDFHfBtBi4KGv6w87PcVKqqJK...</a><p>Another question for all the folks here at HN, is there more resources like this that would be considered as &quot;definitive guide&quot; as many mentioned, related to networking or distributed systems?
评论 #13985562 未加载
pvgabout 8 years ago
Comes up so often, we&#x27;ve practically run out of things to say about it.<p><a href="https:&#x2F;&#x2F;hn.algolia.com&#x2F;?query=Beej&#x27;s%20Guide%20to%20Network%20Programming&amp;sort=byDate&amp;dateRange=all&amp;type=story&amp;storyText=false&amp;prefix&amp;page=0" rel="nofollow">https:&#x2F;&#x2F;hn.algolia.com&#x2F;?query=Beej&#x27;s%20Guide%20to%20Network%...</a>
评论 #13984792 未加载
评论 #13984796 未加载
评论 #13984638 未加载
评论 #13984554 未加载
评论 #13988787 未加载
trolliedabout 8 years ago
It really is the definitive guide. I remember reading it when I was doing my Computer Science degree back in 1996.
评论 #13984319 未加载
评论 #13988166 未加载
评论 #13987027 未加载
评论 #13984806 未加载
评论 #13984846 未加载
susamabout 8 years ago
This is a very entertaining guide on socket programming that I came across about 10 years ago. An excerpt from the guide: Stream sockets are reliable two-way connected communication streams. If you output two items into the socket in the order &quot;1, 2&quot;, they will arrive in the order &quot;1, 2&quot; at the opposite end. They will also be error-free. I&#x27;m so certain, in fact, they will be error-free, that I&#x27;m just going to put my fingers in my ears and chant la la la la if anyone tries to claim otherwise.<p>Last year, I decided to read the recently published newer version of this guide that describes how to write code that works for both IPv4 and IPv6.<p>An archive of examples and experimental code that I wrote while reading this book: <a href="https:&#x2F;&#x2F;github.com&#x2F;susam&#x2F;lab&#x2F;tree&#x2F;master&#x2F;c&#x2F;beej-guide-to-network-programming" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;susam&#x2F;lab&#x2F;tree&#x2F;master&#x2F;c&#x2F;beej-guide-to-net...</a>
justin66about 8 years ago
It&#x27;s honestly kind of nice to have multiple sources treating the same material a different way. This, Stevens&#x27; <i>UNIX Network Programming,</i> and Kerrisk&#x27;s <i>The Linux Programming Interface</i> are all a student should need to get started with socket programming.
评论 #13988956 未加载
评论 #13986358 未加载
seifertericabout 8 years ago
I remember reading through the original version around my first year as an engineering student at Chico state around 2004. Only later did I realized that this guide that I learned so much from was hosted on the Chico State engineering servers! somehow I overlooked the URL. I followed the trail and realized that Beej was an alumni from Chico as well and had some sort of group (I forget the name). I emailed him to see if it was still active and he responded but alas it was not. They were responsible for rigging up the the soda machine in the computer science department to the network and I believe you could check the current stock levels of the different soda types.
aaronmdjonesabout 8 years ago
I recall reading this start to end, twice, around 2009. I read it again a few years ago as it had been updated to include things like references to libevent.
pietromennaabout 8 years ago
He also have other guides! This are old but gold guides! I learned C with his guides and also learned network with this one.
nauticalabout 8 years ago
I learnt a lot of things from this book . Its a really good to start . (Around ~2007 if I am not wrong )
annerajbabout 8 years ago
This reminds me of my networking class! I remember being provided Beej&#x27;s Guide and it being indespensable. Still 8 years later when I need to verify something about networking I go look it up and make sure i am doing it right.
darasanabout 8 years ago
Brings back lots of memories - had it permanently open in my browser when I wrote a P2P file transfer &#x2F; messenger app for a project about 10 years ago. Socket programming is so much fun :-)
a_t48about 8 years ago
Beej&#x27;s is great. Crack it open every time I have to work with network sockets (on my third reliable UDP library now...).
rahedabout 8 years ago
I really liked Lincoln Stein&#x27;s Network Programming with Perl. Excelent examples and clearly explained from the basics.
n3x10e8about 8 years ago
I am finding this guide very helpful. Are there guides for other Linux concepts just like this guide.
m0narchabout 8 years ago
I just used this guide for my Network Programming class last fall. I love it so much.
chrismoosabout 8 years ago
This is classic -- one of the main reasons I started programming in C.
d0mabout 8 years ago
I read it over and over again 15 years ago, great resource.
knownabout 8 years ago
Nostalgia
评论 #13992092 未加载