8. Networking and Sockets
The IPC mechanisms in Chapters 6 and 7 have their uses, of course, but many modern applications need to send data between machines, not just between processes on the same machine. By “between machines,” I don’t just mean machines across the room or even in the same building. I mean anywhere in the world, using the Internet.
The basic mechanism for going between machines—networking—is called sockets. There are eight basic socket system calls, five of which are unique to sockets: socket, bind, listen, accept, connect, read, write, and close. However, because sockets, and especially the underlying communication protocols, can get complicated, there are 60 or so other system calls involved, all of which are described in ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access