System Programming in Linux: A Hands-On Introduction

Front Cover
No Starch Press, Inc, Oct 14, 2025 - Computers - 1048 pages
Learn to write real Linux software—not just run it.

Most programmers never learn how Linux really works. Why? Because system programming is rarely taught, and the tools can be intimidating without the right guidance. As a result, many developers stick to high-level languages and frameworks—writing code that runs on Linux without understanding how it interacts with Linux.

In today’s world, that’s not enough to stand out. Especially as more companies turn to AI to write their software, the question becomes: How do you stay relevant in an AI-driven world? You learn how things really work.

If you’ve ever wondered how processes are created, how memory and files are managed, or how programs communicate in a Unix environment, System Programming in Linux will make it all make sense.

This is a hands-on guide to writing software that interfaces directly with the Linux operating system. You’ll go beyond shell commands and abstractions to understand what the kernel is doing—and how to leverage it through your own code. Rather than telling you how to solve each problem, Professor Stewart N. Weiss guides you through the process of discovering the solution yourself.

Start with the core concepts of Unix and Linux, then work your way up to advanced topics like process control, signals, interprocess communication, threading, and non-blocking I/O. Each chapter includes conceptual diagrams, annotated source code, and practical projects to help you immediately apply what you’ve learned.

You’ll explore topics such as:
  • The structure of Unix and Linux operating systems—and why it matters
  • Using system calls to create and manage processes
  • The mechanics of signals, timers, and interprocess communication
  • Using synchronization tools to write multithreaded programs
  • Interacting with filesystems, devices, and terminals
  • Building text-based user interfaces using ncurses
  • Developing programs that are robust, efficient, and portable

At Hunter College, Professor Weiss built the course this book is based on, and he has helped thousands of students go from confusion to confidence in his over 40 years of teaching programming. His clear, conversational style; technical depth; and focus on real-world application make this one of the most approachable and powerful system programming books available.

As Linux continues to dominate development, server, and embedded environments, understanding the system behind your software isn’t just helpful; it’s essential.

Whether you’re a student, developer, or sysadmin, this book gives you the tools to work directly with Linux and the insight to understand what’s really happening under the hood.
 

Contents

Core Concepts
1
Fundamentals of System Programming
49
Time Dates and Locales
93
Basic Concepts of File IO
149
File IO and Login Accounting
187
Overview of Filesystems and Files
247
The Directory Hierarchy
311
Introduction to Signals
383
ClientServer Applications and Daemons
679
Introduction to Threads
709
Thread Synchronization
739
Alternative Methods of IO
791
Terminals and Terminal IO
833
Interactive Programming and the ncurses Library
877
Creating Libraries
943
Unicode and UTF8
955

Timers and Sleep Functions
435
Process Fundamentals
491
Process Creation and Termination
539
Introduction to Interprocess Communication
597
Pipes and FIFOs
645
Date and Time Format Specifiers
961
Bibliography
965
Index
969
Copyright

Other editions - View all

Common terms and phrases

About the author (2025)

Stewart N. Weiss is a professor emeritus of Hunter College, having taught in the computer science department for 38 years. He was also on the faculty of the Graduate Center of the City University of New York. He developed courses in Unix system programming, parallel computing, software testing, and open source software development. Weiss holds a PhD in computer science from the Courant Institute of Mathematical Science of New York University. He has been working with Unix and C since 1983 and is passionate about sharing his knowledge of Unix and Linux systems.

Bibliographic information