Table of Contents for
Absolute FreeBSD, 3rd Edition
Close
Version ebook
/
Retour
Absolute FreeBSD, 3rd Edition
by Michael W. Lucas
Published by No Starch Press, 2018
Cover Page
Absolute FreeBSD®, 3rd Edition
Title Page
Copyright Page
About the Author
About the Technical Reviewers
BRIEF CONTENTS
CONTENTS IN DETAIL
FOREWORD by Marshall Kirk McKusick
ACKNOWLEDGMENTS
INTRODUCTION
1 GETTING MORE HELP
2 BEFORE YOU INSTALL
3 INSTALLING
4 START ME UP! THE BOOT PROCESS
5 READ THIS BEFORE YOU BREAK SOMETHING ELSE! (BACKUP AND RECOVERY)
6 KERNEL GAMES
7 THE NETWORK
8 CONFIGURING NETWORKING
9 SECURING YOUR SYSTEM
10 DISKS, PARTITIONING, AND GEOM
11 THE UNIX FILE SYSTEM
12 THE Z FILE SYSTEM
13 FOREIGN FILESYSTEMS
14 EXPLORING /ETC
15 MAKING YOUR SYSTEM USEFUL
16 CUSTOMIZING SOFTWARE WITH PORTS
17 ADVANCED SOFTWARE MANAGEMENT
18 UPGRADING FREEBSD
19 ADVANCED SECURITY FEATURES
20 SMALL SYSTEM SERVICES
21 SYSTEM PERFORMANCE AND MONITORING
22 JAILS
23 THE FRINGE OF FREEBSD
24 PROBLEM REPORTS AND PANICS
AFTERWORD
BIBLIOGRAPHY
INDEX
Absolute FreeBSD®, 3rd Edition
Absolute FreeBSD®, 3rd Edition
Absolute FreeBSD®, 3rd Edition
Absolute FreeBSD®, 3rd Edition
Absolute FreeBSD®, 3rd Edition
Contents in Detail
Cover Page
Title Page
Copyright Page
About the Author
About the Technical Reviewers
BRIEF CONTENTS
CONTENTS IN DETAIL
FOREWORD by Marshall Kirk McKusick
ACKNOWLEDGMENTS
INTRODUCTION
What Is FreeBSD?
FreeBSD Development
Other BSDs
Other Unixes
FreeBSD’s Strengths
Who Should Use FreeBSD?
Who Should Run Another BSD?
Who Should Run a Proprietary Operating System?
How to Read This Book
What Must You Know?
For the New System Administrator
Notes on the Third Edition
Contents of This Book
1 GETTING MORE HELP
Why Not Beg for Help?
Man Pages
FreeBSD.org
Other Websites
Using FreeBSD Problem-Solving Resources
Asking for Help
2 BEFORE YOU INSTALL
Default Files
Configuration with UCL
FreeBSD Hardware
Disks and Filesystems
Getting FreeBSD
Network Installs
3 INSTALLING
Core Settings
Distribution Selection
Disk Partitioning
Network and Service Configuration
Finishing the Install
4 START ME UP! THE BOOT PROCESS
Power-On
The Loader
Single-User Mode
The Loader Prompt
Loader Configuration
Boot Options
Startup Messages
Multiuser Startup
The rc.d Startup System
Serial Consoles
5 READ THIS BEFORE YOU BREAK SOMETHING ELSE! (BACKUP AND RECOVERY)
System Backups
Backup Tapes
BSD tar(1)
Recording What Happened
Repairing a Broken System
6 KERNEL GAMES
What Is the Kernel?
Kernel State: sysctl
The Kernel Environment
Kernel Modules
Build Your Own Kernel
Building a Kernel
Custom Kernel Configuration
Inclusions, Exclusions, and Expanding the Kernel
7 THE NETWORK
Network Layers
The Network in Practice
Getting Bits and Hexes
Network Stacks
IPv4 Addresses and Netmasks
IPv6 Addresses and Subnets
TCP/IP Basics
Understanding Ethernet
8 CONFIGURING NETWORKING
Network Prerequisites
The Domain Name Service
Network Activity
Optimizing Network Performance
Network Adapter Teaming
Virtual LANs
9 SECURING YOUR SYSTEM
Who Is the Enemy?
FreeBSD Security Announcements
User Security
Shells and /etc/shells
root, Groups, and Management
Tweaking User Security
File Flags
Securelevels
Network Targets
Putting It All Together
10 DISKS, PARTITIONING, AND GEOM
Disks Lie
Device Nodes
The Common Access Method
The GEOM Storage Architecture
Hard Disks, Partitions, and Schemes
The Filesystem Table: /etc/fstab
What’s Mounted Now?
Disk Labeling
GEOM Withering
The gpart(8) Command
Scheming Disks
The GPT Partitioning Scheme
The MBR Partitioning Scheme
BSD Labels
11 THE UNIX FILE SYSTEM
UFS Components
Mounting and Unmounting Filesystems
UFS Resiliency
Creating and Tuning UFS Filesystems
UFS Snapshots
UFS Recovery and Repair
UFS Space Reservations
How Full Is a Partition?
Adding New UFS storage
12 THE Z FILE SYSTEM
Datasets
ZFS Pools
Virtual Devices
Managing Pools
Copy-On-Write
Snapshots
Compression
Pool Integrity and Repair
Boot Environments
13 FOREIGN FILESYSTEMS
FreeBSD Mount Commands
Using Removable Media
Memory Filesystems
devfs
Miscellaneous Filesystems
The Network File System
The Common Internet File System
Serving CIFS Shares
14 EXPLORING /ETC
/etc Across Unix Species
/etc/adduser.conf
/etc/aliases
/etc/amd.map
/etc/auto_master
/etc/blacklistd.conf
/etc/bluetooth, /etc/bluetooth.device.conf, and /etc/defaults/bluetooth.device.conf
/etc/casper
/etc/crontab and /etc/cron.d
/etc/csh.*
/etc/ddb.conf
/etc/devd.conf
/etc/devfs.conf, /etc/devfs.rules, and /etc/defaults/devfs.rules
/etc/dhclient.conf
/etc/disktab
/etc/dma/
/etc/freebsd-update.conf
/etc/fstab
/etc/ftp.*
/etc/group
/etc/hostid
/etc/hosts
/etc/hosts.allow
/etc/hosts.equiv
/etc/hosts.lpd
/etc/inetd.conf
/etc/libmap.conf
/etc/localtime
/etc/locate.rc
/etc/login.*
/etc/mail
/etc/mail.rc
/etc/mail/mailer.conf
/etc/make.conf
/etc/master.passwd
/etc/motd
/etc/mtree
/etc/netconfig
/etc/netstart
/etc/network.subr
/etc/newsyslog.conf
/etc/nscd.conf
/etc/nsmb.conf
/etc/nsswitch.conf
/etc/ntp/, /etc/ntp.conf
/etc/opie*
/etc/pam.d/*
/etc/passwd
/etc/pccard_ether
/etc/periodic.conf and /etc/defaults/periodic.conf
/etc/pf.conf, /etc/pf.os
/etc/phones
/etc/portsnap.conf
/etc/ppp/
/etc/printcap
/etc/profile
/etc/protocols
/etc/pwd.db
/etc/rc*
/et/regdomain.xml
/etc/remote
/etc/resolv.conf
/etc/rpc
/etc/security/
/etc/services
/etc/shells
/etc/skel/
/etc/snmpd.config
/etc/spwd.db
/etc/src.conf
/etc/ssh/
/etc/ssl/
/etc/sysctl.conf
/etc/syslog.conf, /etc/syslog.conf.d/
/etc/termcap, /etc/termcap.small
/etc/ttys
/etc/unbound/
/etc/wall_cmos_clock
/etc/zfs/
15 MAKING YOUR SYSTEM USEFUL
Ports and Packages
Packages
Package Repositories
Package Branches
Upgrading Packages
16 CUSTOMIZING SOFTWARE WITH PORTS
Making Software
Source Code and Software
The Ports Collection
The Ports Index
What’s In a Port?
Private Package Repositories
All Poudrieres, Large and Small
Updating Poudriere
More Poudriere
17 ADVANCED SOFTWARE MANAGEMENT
Using Multiple Processors: SMP
Threads, Threads, and More Threads
Startup and Shutdown Scripts
Managing Shared Libraries
Remapping Shared Libraries
Running Software from the Wrong OS
Using Linux Mode
Running Software from the Wrong Architecture or Release
18 UPGRADING FREEBSD
FreeBSD Versions
Upgrade Methods
Binary Updates
Upgrading via Source
Building FreeBSD from Source
Shrinking FreeBSD
Packages and System Upgrades
Updating Installed Ports
19 ADVANCED SECURITY FEATURES
Unprivileged Users
Network Traffic Control
Default Accept vs. Default Deny
TCP Wrappers
Packet Filtering
Blacklistd(8)
Public-Key Encryption
Global Security Settings
Preparing for Intrusions with mtree(1)
Monitoring System Security
Package Security
If You’re Hacked
20 SMALL SYSTEM SERVICES
Secure Shell
Email
Network Time
Name Service Switching
inetd
DHCP
Printing and Print Servers
TFTP
Scheduling Tasks
21 SYSTEM PERFORMANCE AND MONITORING
Computer Resources
Checking the Network
General Bottleneck Analysis with vmstat(8)
Disk I/O
CPU, Memory, and I/O with top(1)
Following Processes
Paging and Swapping
Performance Tuning
Status Mail
Logging with syslogd
Log File Management
FreeBSD and SNMP
22 JAILS
Jail Basics
Jail Host Server Setup
Jail Setup
Managing Jails
More Jail Options
Jailing Ancient FreeBSD
Last Jail Notes
23 THE FRINGE OF FREEBSD
Terminals
Managing Cloudy FreeBSD
Diskless FreeBSD
Diskless Farm Configuration
Finalizing Setup
Storage Encryption
24 PROBLEM REPORTS AND PANICS
Bug Reports
System Panics
Recognizing Panics
Responding to a Panic
AFTERWORD
The FreeBSD Community
Why Do We Do It?
What Can You Do?
If Nothing Else
Getting Things Done
BIBLIOGRAPHY
References
Books I've Written
INDEX
i
ii
iii
iv
v
vi
vii
viii
ix
x
xi
xii
xiii
xiv
xv
xvi
xvii
xviii
xix
xx
xxi
xxii
xxiii
xxiv
xxv
xxvi
xxvii
xxviii
xxix
xxx
xxxi
xxxii
xxxiii
xxxiv
xxxv
xxxvi
xxxvii
xxxviii
xxxix
xl
xli
xlii
xliii
xliv
xlv
xlvi
xlvii
xlviii
xlix
l
li
lii
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654