aboutsummaryrefslogtreecommitdiff
path: root/zh_TW.Big5/books/handbook/cutting-edge/chapter.xml
blob: 08ea2f4dd1720f3a4f873d51fedfc7d4acc9cc81 (plain) (blame)
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
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
<?xml version="1.0" encoding="big5"?>
<!--
     The FreeBSD Documentation Project

     $FreeBSD$
     Original revision: 1.225
-->

<chapter id="cutting-edge">
  <chapterinfo>
    <authorgroup>
      <author>
	<firstname>Jim</firstname>
	<surname>Mock</surname>
	<contrib>Restructured, reorganized, and parts updated by </contrib>
      </author>
      <!-- Mar 2000 -->
    </authorgroup>
    <authorgroup>
      <author>
	<firstname>Jordan</firstname>
	<surname>Hubbard</surname>
	<contrib>Original work by </contrib>
      </author>
      <author>
	<firstname>Poul-Henning</firstname>
	<surname>Kamp</surname>
      </author>
      <author>
	<firstname>John</firstname>
	<surname>Polstra</surname>
      </author>
      <author>
	<firstname>Nik</firstname>
	<surname>Clayton</surname>
      </author>
    </authorgroup>
    <!-- with feedback from various others -->
  </chapterinfo>

  <title>§ó·s¡B¤É¯Å FreeBSD</title>

  <sect1 id="cutting-edge-synopsis">
    <title>·§­z</title>

    <para>&os; ¬O­Ó«ùÄòµo®iªº§@·~¨t²Î¡C¹ï©ó³ßÅw°l¨D·sÂA¡B¨ë¿Eªº¨Ï¥ÎªÌ¦Ó¨¥¡A
      ¦³«Ü¦h¤èªk¥i¥H¨Ï±zªº¨t²Î»´ÃP§ó·s¬°³Ì·sª©¡C
      ª`·N¡G¨Ã«D¨C­Ó¤H³£¾A¦X³o»ò°µ¡I¡@¥»³¹¥D­n¬O¨ó§U±z¨M©w¨ì©³­n¸ò¶}µoª©¥»¡A
      ©Î¬O­n¨Ï¥Î¸ûí©wªºÄÀ¥Xª©¡C
      </para>

    <para>Ū§¹³o³¹¡A±z±N¤F¸Ñ¡J</para>

    <itemizedlist>
      <listitem><para>&os.stable; »P &os.current;¡@³o¨â¤À¤äªº¤£¦P¤§³B¡F</para>
      </listitem>
      <listitem><para>¦p¦ó¥H
	  <application>CSup</application>,
	  <application>CVSup</application>,
	  <application>CVS</application> ©Î
	  <application>CTM</application> ¨Ó§ó·s§Aªº¨t²Î</para>
      </listitem>
      <listitem><para>¦p¦ó¥H <command>make buildworld</command>
      µ¥«ü¥O¨Ó­«·s½sĶ¡B¦w¸Ë¾ã­Ó base system¡C</para>
      </listitem>

    </itemizedlist>

    <para>¦b¶}©l¾\Ū³o³¹¤§«e¡A±z»Ý­n¡J</para>

    <itemizedlist>
      <listitem><para>¥ý³]¦n§Aªººô¸ô(<xref linkend="advanced-networking"/>)¡C
	</para>
      </listitem>
      <listitem><para>ª¾¹D¦p¦ó³z¹L port/package ¦w¸Ë³nÅé(<xref
	linkend="ports"/>)¡C</para></listitem>
    </itemizedlist>
  </sect1>

  <sect1 id="current-stable">
    <title>&os.current; vs. &os.stable;</title>
    <indexterm><primary>-CURRENT</primary></indexterm>
    <indexterm><primary>-STABLE</primary></indexterm>

    <para>FreeBSD ¦³¨â­Óµo®i¤À¤ä¡G&os.current; ¤Î
      &os.stable;¡C¥»¸`±N·|³°Äò¤¶²Ð¡A¨Ã¤¶²Ð¥¦­Ì¤À§O¤S¬O¦p¦ó§ó·s¡C
      ­º¥ý¡A¥ý¤¶²Ð &os.current;¡A±µµÛ¦A¤¶²Ð &os.stable;¡C</para>

    <sect2 id="current">
      <title>¨Ï¥Î³Ì·sªº &os; CURRENT</title>

      <para>³o¸Ì¦A¦¸±j½Õ¡A&os.current; ¬O &os; ¶}µoªº <quote>³Ì«e½u</quote>¡C
	&os.current; ¨Ï¥ÎªÌ¶·¦³¸û±jªº§Þ³N¯à¤O¡A
	¦Ó¥BÀ³¸Ó­n¦³¯à¤O¦Û¤v¸Ñ¨M§xÃøªº¨t²Î°ÝÃD¡C  ­Y±z¬O &os; ·s¤â¡A
	¨º»ò½Ð¦b¦w¸Ë«e³Ì¦n¥ý¤T«ä¡C</para>

      <sect3>
	<title>¤°»ò¬O &os.current;¡H</title>
	<indexterm><primary>snapshot</primary></indexterm>

	<para>&os.current; ¬O &os; ªº³Ì·sª©¡C¥¦¥]§t¡G
	  ¤´¦b¬ãµo¶¥¬q¡B¹êÅç©Ê½èªº­×§ï¡B¹L´ç®É´Áªº¾÷¨î¡A
	  ³o¨ÇªF¦è¦b¤U¤@¦¸¥¿¦¡ relase ªºª©¥»¥i¯à·|¦³¡A¤]¥i¯à¤£·|¦³ªº¡C
	  ¾¨ºÞ¦³³\¦h &os; ¶}µoªÌ¨C¤Ñ³£·|½sĶ &os.current; source code¡A
	  ¦ý¦³®É³o¨Ç­ì©l½X¬OµLªk½sĶ¦¨¥\¡C  ÁöµM¡A³o¨Ç°ÝÃD³q±`·|¾¨§Ö¸Ñ¨M¡A
	  ¦ý &os.current; ¨ì©³¬O±a¨Ó¯E§T©Î¬O¦h¤F·Q­n¥Îªº·s¥\¯à¡B§ïµ½¡A
	  ³oÂI¥D­n¨ú¨M©ó±z§ó·s­ì©l½Xªº®É¾÷¬°¦ó¦Ó©w¡I</para>
      </sect3>

      <sect3>
	<title>½Ö»Ý­n &os.current;¡H</title>

	<para>&os.current; ¾A¦X¤U¦C³o¤TÃþ¤H¡G</para>

	<orderedlist>
	  <listitem>
	    <para>&os; ªÀ¸s¦¨­û¡G¿n·¥±Mª`©ó source tree ªº¬Y¤@³¡¥÷¡A
	      ¥H¤Î»{¬°«O«ù¬° <quote>current(³Ì·sª¬ºA)</quote>
	      ¬°µ´¹ï»Ý¨Dªº¤H¡C</para>
	  </listitem>

	  <listitem>
	    <para>&os; ªÀ¸s¦¨­û¡G¬°¤F½T«O &os.current;
	      ¯à°÷¾¨¥i¯à¦aºû«ù¦b³Ìí©wªºª¬ºA¡A
	      ¦Ó¥D°Êªá®É¶¡¸Ñ¨M°ÝÃDªº´ú¸ÕªÌ¡C  ¦¹¥~¡AÁÙ¦³¹ï &os;
	      ¯à´£¥X¨ãÅé«Øij¥H¤Î§ïµ½¤è¦V¡A¨Ã´£¥X patch ­×¥¿Àɪº¤H¡C</para>
	  </listitem>

	  <listitem>
	    <para>¥u¬OÃö¤ß©ÎªÌ·Q°Ñ¦Ò(¤ñ¦p¡A¥u¬O<emphasis>¾\Ū</emphasis>¡A
	      ¦Ó«D°õ¦æ)ªº¤H¡C
	      ³o¨Ç¤H¦³®É¤]·|°µ¨Çµù¸Ñ¡A©Î°^Äm­ì©l½X¡C</para>
	  </listitem>
	</orderedlist>
      </sect3>

      <sect3>
	<title>&os.current; <emphasis>¨Ã¤£¬O</emphasis> ¤°»ò¡H</title>

	<orderedlist>
	  <listitem>
	    <para>°l¨D³Ì·s¥\¯à¡C  Å¥»¡¸Ì­±¦³¨Ç«Ü»Åªº·s¥\¯à¡A
	      ¨Ã§Æ±æ¦¨¬°±z©P³òªº¤H¤¤²Ä¤@­Ó¹Á¸Õªº¤H¡A
	      ¦]¦¹±N &os.current; µø¬°¨ú±o·mÂAª©ªº±¶®|¡C
	      ¾¨ºÞ¡A±z¯à°÷¦]¦¹­º¥ýÁA¸Ñ¨ì³Ì·sªº¥\¯à¡A
	      ¦ý³o¤]·N¨ýµÛ­Y¥X²{·sªº bug ®É¡A±z¤]¬O­º·í¨ä½Ä¡C</para>
	  </listitem>

	  <listitem>
	    <para>­×´_ bug ªº³t¦¨ªk¡C  ¦]¬° &os.current;
	      ªº¥ô¦óª©¥»¦b­×´_¤wª¾ bug ªº¦P®É¡A¤S¥i¯à·|²£¥Í·sªº bug¡C
	      </para>
	  </listitem>

	  <listitem>
	    <para>µL©Ò¤£¦bªº <quote>officially supported</quote>¡C
	      §Ú­Ì·|ºÉ¤O¨ó§U¤W­z &os.current; ªº¨º¤TºØÃþ§Oªº
	      <quote>legitimate</quote> ¨Ï¥ÎªÌ¡A
	      ¦ý§Ú­Ì<emphasis>¨S®É¶¡</emphasis>¬°¥L­Ì´£¨Ñ§Þ³N¤ä´©¡C
	      ³o¤£¥Nªí§Ú­Ì«Ü´c¦H¡A©Î¬O¤£·QÀ°§U¤H(­Y¬Oªº¸Ü¡A
	      §Ú­Ì¤]¤£·|¬° &os; §V¤O¤F)
	      ¡A¹ê¦b¬O¦]¬°§Ú­Ì¤À¨­¥F³N¡AµLªk¨C¤Ñ¦^µª¼Æ¦Ê­Ó°ÝÃD¡A
	      <emphasis>¦Ó¦P®É</emphasis>Ä~Äò¶}µo &os;¡C
	      ¥i¥H½T©wªº¤@ÂI´N¬O¡A
	      ¦b§ïµ½ &os; ©Î¬O¦^µª¤j¶q¦³Ãö¹êÅç½Xªº°ÝÃD¤§¶¡¡A
	      ­Y­n°µ­Ó¿ï¾Üªº¸Ü¡A¶}µoªÌ·|¿ï¾Ü«eªÌ¡C</para>
	  </listitem>
	</orderedlist>
      </sect3>

      <sect3>
	<title>¨Ï¥Î &os.current;</title>

	<orderedlist>
	  <listitem>
	    <para>¥[¤J &a.current.name;<indexterm><primary>-CURRENT</primary><secondary>using</secondary></indexterm> ¤Î &a.cvsall.name; ½×¾Â¡C
	      ³o¤£³æ¥u¬O­Ó«Øij¡A¤]¬O <emphasis>¥²¶·</emphasis> §@ªº¡C
	      ­Y±z¨S­q¾\ <emphasis>&a.current.name;</emphasis>
	      ¡A¨º»ò´N·|¿ù¹L§O¤H¹ï¥Ø«e¨t²Îª¬ºAªº»¡©ú¡A¦Ó¬\¯Ó¦b§O¤H¤w¸Ñªº°ÝÃD¡C
	      §ó­«­nªº¬O¡A¥i¯à·|¿ù¥¢¤@¨Ç¹ï¤v¨­©ÒºÞ¨t²Î¦w¦M¬Û·í­«­nªº¤½§i¡C
	      </para>

	    <para>¦b &a.cvsall.name; ¤W«h¥i¥H¬Ý¨ì¨C­Ó commit ¬ö¿ý¡A
	      ¦]¬°³o¨Ç°O¿ý·|³s±a¼vÅT¨ä¥L¬ÛÃö¸ê°T¡C</para>

	    <para>­n­q¾\³o¨Ç½×¾Â©Î¨ä¥L½×¾Â¡A½Ð°Ñ¦Ò &a.mailman.lists.link;
	      ¨ÃÂI¿ï·Q­q¾\ªº³¡¤À§Y¥i¡C  ¦Ü©ó¨ä¥L«áÄò¨BÆJ¦p¦ó¶i¦æ¡A
	      ¦b¨º¸Ì·|¦³»¡©ú¡C</para>
	  </listitem>

	  <listitem>
	    <para>±q &os; <link linkend="mirrors">mirror ¯¸</link>
	      ¨ú±o­ì©l½X¡C  ¦³¨âºØ¤è¦¡¥i¥H¹F¦¨¡G</para>

	    <orderedlist>
	      <listitem>
		<para>¥H <link linkend="cvsup">csup</link><indexterm><primary><command>cvsup</command></primary></indexterm> ©Î
		  <link linkend="cvsup">cvsup</link> µ{¦¡·f°t¦ì©ó
		  <filename>/usr/share/examples/cvsup</filename> ÀɦW¬°
		  <filename>standard-supfile</filename> ªº
		  <filename>supfile</filename>¡C
		  ³o¬O¤j®a³Ì±`±ÀÂ˪º¤è¦¡¡A¦]¬°¥¦¥i¥HÅý±z§â¾ã­Ó tree ³£§ì¦^¨Ó¡A
		  ¤§«á´N¥u¨ú¦³§ó·sªº³¡¤À§Y¥i¡C
		  ¦¹¥~¡A³\¦h¤H·|§â <command>csup</command> ©Î
		  <command>cvsup</command> ©ñ¨ì
		  <command>cron</command><indexterm><primary><command>cron</command></primary></indexterm> ¥H©w´Á¦Û°Ê§ó·s¡C
 		  ±z¶·­n¦Û­q«e­zªº <filename>supfile</filename> ½d¨ÒÀÉ¡A
		  ¨Ã°w¹ï¦Û¨­ºô¸ôÀô¹Ò¥H½Õ¾ã <link linkend="cvsup">csup</link>
		  ©Î <link linkend="cvsup">cvsup</link><indexterm><primary>-CURRENT</primary><secondary>Syncing with <application>CVSup</application></secondary></indexterm> ¬ÛÃö³]©w¡C</para>
	      </listitem>

	      <listitem>
		<para>¨Ï¥Î <application><link
		  linkend="ctm">CTM</link></application><indexterm><primary>-CURRENT</primary><secondary>Syncing with CTM</secondary></indexterm> ¤u¨ã¡C  ­Yºô¸ôÀô¹Ò¤£¨Î
		  (¤Wºô¶O¥Î¶Q¡A©Î¥u¯à¥Î email ¦Ó¤w)
		  <application>CTM</application> ·|¤ñ¸û¾A¦X±zªº»Ý¨D¡C
		  µM¦Ó¡A³o¤]¦³¤@¨Çª§Ä³¨Ã¥B±`§ì¨ì¤@¨Ç¦³°ÝÃDªºÀɮסC  ¦]¦¹¡A
		  «Ü¤Ö¤H·|¥Î¥¦¡C  ³o¤]µù©w¤F¤£¯àªø´Á¨Ì¿à³o­Ó§ó·s¤è¦¡¡C
		  ­Y¬O¨Ï¥Î 9600&nbsp;bps modem ©ÎÀW¼e§ó¤jªº¤WºôªÌ¡A«Øij¨Ï¥Î
		  <application><link linkend="cvsup">CVSup</link></application>
		  ¡C</para>
	      </listitem>
	    </orderedlist>
	  </listitem>

	  <listitem>
	    <para>­Y§ì source code ¬O­n¥Î¨Ó¶]ªº¡A¦Ó¤£¶È¥u¬O¬Ý¬Ý¦Ó¤w¡A
	      ¨º»ò´N§ì <emphasis>¾ã­Ó</emphasis> &os.current;¡A¦Ó¤£­n¥u§ì³¡¤À¡C
	      ¦]¬°¤j³¡¤Àªº source code ³£·|¬Û¨Ì¨ì¨ä¥L source code Àô¸`³¡¤À¡A
	      ­Y¬O±z¥u½sĶ¨ä¤¤¤@³¡¥÷¡A«OÃÒ·|«Ü³Â·Ð¡C</para>

	    <para>¦b½sĶ &os.current;<indexterm><primary>-CURRENT</primary><secondary>compiling</secondary></indexterm> ¤§«e¡A½Ð¥J²Ó¾\Ū
	      <filename>/usr/src</filename> ¤ºªº <filename>Makefile</filename>¡C
	      ¾¨ºÞ¥u¬O¤É¯Å³¡¤ÀªF¦è¦Ó¤w¡A±z¦Ü¤Ö¤]­n¥ý <link linkend="makeworld">
	      ¸Ë·sªº kernel ¥H¤Î­«·s½sĶ world</link>¡C  ¦¹¥~¡A¦h¦h¾\Ū
	      &a.current; ¥H¤Î <filename>/usr/src/UPDATING</filename>
	      ¤]¬O¥²¶·ªº¡A
	      ¤~¯àª¾¹D¥Ø«e¶i«×¬O«ç¼Ë¥H¤Î¤U¤@ª©·|¦³¤°»ò·sªF¦è¡C</para>
	  </listitem>

	  <listitem>
	    <para>¼ö¦å¡I­Y±z¥¿¦b¶] &os.current;¡A
	      §Ú­Ì«Ü·Qª¾¹D±z¹ï©ó¥¦ªº·Qªk¬O¤°»ò¡A¤×¨ä¬O¥[±j­þ¨Ç¥\¯à¡A
	      ©Î¸Ó­×¥¿­þ¨Ç¿ù»~ªº«Øij¡C  ¦pªG±z¦b«Øij®É¯àªþ¤W¬ÛÃöµ{¦¡½Xªº¸Ü¡A
	      ¨º¯u¬O¤Ó´Î¤F¡I</para>
	  </listitem>
	</orderedlist>
      </sect3>
    </sect2>

    <sect2 id="stable">
      <title>¨Ï¥Î³Ì·sªº &os; STABLE</title>

      <sect3>
	<title>¤°»ò¬O &os.stable;¡H</title>
	<indexterm><primary>-STABLE</primary></indexterm>

	<para>&os.stable; ¬O§Ú­Ìªº¶}µo¤À¤ä¡A¥D­nªºµo¦æª©´N¥Ñ¦¹¦Ó¨Ó¡C
	  ³o­Ó¤À¤ä·|¥H¤£¦P³t«×§@­×§ïÅܤơA¨Ã¥B°²³]³o¨Ç¬O²Ä¤@¦¸¶i¤J &os.current;
	  ¶i¦æ´ú¸Õ¡C  µM¦Ó¡A³o <emphasis>¤´µM</emphasis> ÄÝ©ó¶}µo¤¤ªº¤À¤ä¡A
	  ¤]´N¬O»¡¦b¬Y¨Ç®É­Ô¡A&os.stable; ¥i¯à·|¡B¤]¥i¯à¤£·|²Å¦X¤@¨Ç¯S®í»Ý¨D¡C
	  ¥¦¥u¤£¹L¬O¥t¤@­Ó¶}µo¤À¤ä¦Ó¤w¡A¥i¯à¤£¤Ó¾A¦X¤@¯ë¨Ï¥ÎªÌ¡C</para>
      </sect3>

      <sect3>
	<title>½Ö»Ý­n &os.stable;¡H</title>

	<para>­Y±z¦³¿³½ì¥h°lÂÜ¡B°^Äm FreeBSD ¶}µo¹Lµ{©Î§@¨Ç°^Äm¡A
	  ¤×¨ä¬O·|¸ò FreeBSD ±µ¤U¨Óªº <quote>ÃöÁä©Ê</quote> µo¦æ¦³Ãö¡A
	  À³¸Ó¦Ò¼{±Ä¥Î &os.stable;¡C</para>

	<para>ÁöµM¦w¥þº|¬}ªº­×¸É¤]·|¶i¤J &os.stable; ¤À¤ä¡A
	  ¦ý¤£¥²¶È¶È¦]¦¹¦Ó <emphasis>»Ý­n</emphasis> ¥h¥Î &os.stable;¡C
	  FreeBSD ¨C¶µ security advisory(¦w¥þ¤½§i)
	  ³£·|¸Ñ»¡¦p¦ó¥h­×´_¦³¨ü¨ì¼vÅTªºª©¥»
	  <footnote><para>µM¦Ó¡A³o¤]¤£¤@©w¬O¥¿½T¡A§Ú­Ì¤£¥i¯à¥Ã»·¤ä´© FreeBSD
	    ©õ¤éªº¦UºØµo¦æª©¥»¡A¾¨ºÞ¨C­Óµo¦æª©µo§G¤§«á¡A³£¤´·|«ùÄò¤ä´©¼Æ¦~¤§¤[¡C
	    ­Y±ýÁA¸Ñ FreeBSD ¥Ø«e¹ï©óª©ªº¤ä´©¬Fµ¦²Ó¸`¡A½Ð°Ñ¾\ <ulink
  	    url="&url.base;/security/">http://www.FreeBSD.org/security/</ulink>
	    ¡C</para>
	  </footnote>
	  ¡A­Y¶È¦]¬°¦w¥þ¦]¯À¦Ó¥h±Ä¥Î¶}µo¤À¤ä¡AÁöµM·|¸Ñ¨M²{¦³¤wª¾°ÝÃD¡A
	  ¦ý¤]¥i¯à±a¨Ó¤@¨Ç¼çÂ꺰ÝÃD¡C</para>

	<para>¾¨ºÞ§Ú­ÌºÉ¤O½T«O &os.stable; ¤À¤ä¦b¥ô¦ó®É­Ô§¡¯à¥¿½T½sĶ¡B¹B§@¡A
	  ¦ý¨S¤H¯à°÷¾á«O¥¦ÀH®É³£¥i¥H²Å¦X¤W­z¥Øªº¡C  ¦¹¥~¡AÁöµM­ì©l½X¦b¶i¤J
	  &os.stable; ¤§«e¡A³£·|¥ý¦b &os.current; ¶}µo§¹²¦¡A¦ý¨Ï¥Î &os.current;
	  ªº¤H²¦³º»·¤ñ &os.stable; ¨Ï¥ÎªÌ¨Óªº¤Ö¡A©Ò¥H³q±`¦³¨Ç°ÝÃD¡A¥i¯à¦b
	  &os.current; ¤ñ¸û¨S¤Hª`·N¨ì¡AÀHµÛ &os.stable;
	  ¨Ï¥ÎªÌªº¼sªx¨Ï¥Î¤~·|¯B²{¡C</para>

	<para>¥Ñ©ó¤W­z³o¨Ç²z¥Ñ¡A§Ú­Ì<emphasis>¨Ã¤£±ÀÂË</emphasis> ª¼¥Ø°lÀH
	  &os.stable;¡A¦Ó¥B§ó­«­nªº¬O¡A§O¦b­ì©l½X©|¥¼¸g§¹¾ã´ú¸Õ¤§«e¡A
	  ´N½Ä°Ê§â production server Âಾ¨ì &os.stable; Àô¹Ò¡C</para>

	<para>­Y±z¨S¦³³o¨Ç¦hªº®É¶¡¡Bºë¯«ªº¸Ü¡A¨º±ÀÂ˱z¨Ï¥Î³Ì·sªº FreeBSD
	  µo¦æª©§Y¥i¡A¨Ã±Ä¥Î¨ä©Ò´£¨Ñªº binary §ó·s¾÷¨î¨Ó§¹¦¨¤É¯ÅÂಾ¡C</para>
      </sect3>

      <sect3>
	<title>¨Ï¥Î &os.stable;</title>

	<orderedlist>
	  <listitem>
	    <para>­q¾\ &a.stable.name;<indexterm><primary>-STABLE</primary><secondary>using</secondary></indexterm> list¡C  ¥i¥HÅý±zÀH®ÉÁA¸Ñ &os.stable;
	      ªº³nÅé½sĶ®Éªº¬Û¨ÌÃö«Y¡A¥H¤Î¨ä¥L»Ý¯S§Oª`·Nªº°ÝÃD¡C
	      ¶}µoªÌ¦b¦Ò¼{¤@¨Ç¦³ª§Ä³ªº­×¥¿©Î§ó·s®É¡A´N·|¥ý¦b³o¸Ìµo«H»¡©ú¡A
	      µ¹¨Ï¥ÎªÌ¦³¾÷·|¥i¥H¤ÏÀ³¡A
	      ¬Ý¥L­Ì¹ï©Ò´£ªº§ó§ï¬O§_¦³¤°»ò«Øij©Î°ÝÃD¡C</para>

	    <para>¦Ó &a.cvsall.name; list ³oÃä¥i¥H¬Ý¨ì¨C­Ó commit log¡A
	      ¨ä¤¤¥]¬A¤F³\¦h¤¤ªÖªº¸ê°T¡A¨Ò¦p¤@¨Ç¥i¯àµo¥ÍªºÃä»Ú®ÄÀ³µ¥µ¥¡C</para>

	    <para>·Q­n¥[¤J³o¨Ç³q«H½×¾Âªº¸Ü¡A¥u­n¨ì &a.mailman.lists.link;
	      ÂI¤U·Q­q¾\ªº list §Y¥i¡C  ¨ä¾lªº¨BÆJ¦bºô­¶¤W·|¦³»¡©ú¡C</para>
	  </listitem>

	  <listitem>
	    <para>­Y¥´ºâ­n¦w¸Ë¤@­Ó¥þ·sªº¨t²Î¡A¨Ã¥B§Æ±æ¸Ë  &os.stable;
	      ¨C¤ë©w´Áªº snapshot¡A¨º»ò½Ð°Ñ¾\ <ulink
	      url="&url.base;/snapshots/">Snapshots</ulink> ºô­¶¥HÁA¸Ñ¬ÛÃö²Ó¸`¡C
	      ¦¹¥~¡A¤]¥i±q <link linkend="mirrors">mirror ¯¸</link>
	      ¨Ó¦w¸Ë³Ì·sªº &os.stable; µo¦æª©¡A¨Ã³z¹L¤U¦Cªºªº»¡©ú¨Ó§ó·s¨ì³Ì·sªº
	      &os.stable; ­ì©l½X¡C</para>

	    <para>­Y¤w¸Ëªº¬O &os; ¥H«eªºª©¥»¡A¦Ó·Q³z¹L­ì©l½X¤è¦¡¨Ó¤É¯Å¡A
	      ¨º»ò¤]¬O¥i¥H§Q¥Î &os; <link linkend="mirrors">mirror ¯¸</link>
	      ¨Ó§¹¦¨¡C  ¥H¤U¤¶²Ð¨âºØ¤è¦¡¡G</para>

	    <orderedlist>
	      <listitem>
		<para>¥H <link linkend="cvsup">csup</link><indexterm><primary><command>cvsup</command></primary></indexterm> ©Î
		  <link linkend="cvsup">cvsup</link> µ{¦¡·f°t¦ì©ó
		  <filename>/usr/share/examples/cvsup</filename> ÀɦW¬°
		  <filename>stable-supfile</filename> ªº
		  <filename>supfile</filename>¡C  ³o¬O¤j®a³Ì±`±ÀÂ˪º¤è¦¡¡A
		  ¦]¬°¥¦¥i¥HÅý§A§â¾ã­Ó tree ³£§ì¦^¨Ó¡A
		  ¤§«á´N¥u¨ú¦³§ó·sªº³¡¤À§Y¥i¡C
		  ¦¹¥~¡A³\¦h¤H·|§â <command>csup</command> ©Î
		  <command>cvsup</command> ©ñ¨ì <command>cron</command><indexterm><primary><command>cron</command></primary></indexterm>
		  ¥H©w´Á¦Û°Ê§ó·s¡C  ±z¶·­n¦Û­q«e­zªº
		  <filename>supfile</filename> ½d¨ÒÀÉ¡A¨Ã°w¹ï¦Û¨­ºô¸ôÀô¹Ò¥H½Õ¾ã
		  <link linkend="cvsup">csup</link> ©Î
		  <link linkend="cvsup">cvsup</link><indexterm><primary>-STABLE</primary><secondary>syncing with <application>CVSup</application></secondary></indexterm> ¬ÛÃö³]©w¡C</para>
	      </listitem>

	      <listitem>
		<para>¨Ï¥Î <application><link
		  linkend="ctm">CTM</link></application><indexterm><primary>-STABLE</primary><secondary>syncing with CTM</secondary></indexterm> §ó·s¤u¨ã¡C
		  ­Yºô¸ô¤£§Ö©Îºô¸ô¶O¥Î¶Q¡A¨º»ò¥i¥H¦Ò¼{±Ä¥Î¡C</para>
	      </listitem>
	   </orderedlist>
	 </listitem>

	  <listitem>
	    <para>¤@¯ë¦Ó¨¥¡A­Y±`»Ý¦s¨ú³Ì·s­ì©l½X¡A¦Ó¤£­p¸ûºô¸ôÀW¼eªº¸Ü¡A
	      ¥i¥H¨Ï¥Î <command>csup</command> ©Î <command>cvsup</command>
	      ©Î <command>ftp</command>¡C  §_«h¡A´N¦Ò¼{
	      <application>CTM</application>¡C</para>
	  </listitem>

	  <listitem>
	    <para>¦b½sĶ &os.stable;<indexterm><primary>-STABLE</primary><secondary>compiling</secondary></indexterm> ¤§«e¡A½Ð¥ý¥J²Ó¾\Ū
	      <filename>/usr/src</filename> ¤ºªº <filename>Makefile</filename>
	      ÀÉ¡C  ¾¨ºÞ¥u¬O¤É¯Å³¡¤ÀªF¦è¦Ó¤w¡A±z¦Ü¤Ö¤]­n¥ý <link
	      linkend="makeworld">¸Ë·sªº kernel ¥H¤Î­«·s½sĶ world</link>¡C
	      ¦¹¥~¡A¦h¦h¾\Ū &a.stable; ¥H¤Î
	      <filename>/usr/src/UPDATING</filename> ¤]¬O¥²³Æªº¡A
	      ³o¼Ë¤~¯àª¾¹D¥Ø«e¶i«×¬O«ç¼Ë¡A¥H¤Î¤U¤@ª©·|¦³­þ¨Ç·sªF¦è¡C</para>
	  </listitem>
	</orderedlist>
      </sect3>
    </sect2>
  </sect1>

  <sect1 id="synching">
    <title>§ó·s§Aªº Source</title>

    <para>&os; ­p¹º­ì©l½X¦³³\¦h³z¹Lºô¸ô(©Î email)ªº¤è¦¡¨Ó§ó·s¡A
      µL½×¬O§ó·s¨º¤@¶ô»â°ì¡A³o¨Ç¥þ¥Ñ±z¦Û¦æ¨M©w¡C  §Ú­Ì¥D­n´£¨Ñªº¬O <link
      linkend="anoncvs">Anonymous CVS</link>¡B<link linkend="cvsup">CVSup</link>
      ¡B<link linkend="ctm">CTM</link>¡C</para>

    <warning>
      <para>ÁöµM¥i¥H¥u§ó·s³¡¤À­ì©l½X¡A¦ý°ß¤@¤ä´©ªº§ó·s¬yµ{¬O§ó·s¾ã­Ó tree¡A
	¨Ã¥B­«½s userland(¤ñ¦p¡G¥Ñ¨Ï¥ÎªÌ¥h°õ¦æªº©Ò¦³µ{¦¡¡A¹³¬O
	<filename>/bin</filename>¡B<filename>/sbin</filename> ¤ºªºµ{¦¡)¥H¤Î
	kernel ­ì©l½X¡C
        ­Y¥u§ó·s³¡¤Àªº source tree¡B©Î¥u¦³ kernel ³¡¤À¡B©Î¥u¦³ userland
	³¡¤À¡A³q±`·|³y¦¨¤@¨Ç¿ù»~¡A¹³¬O¡G½sĶ¿ù»~¡Bkernel panic¡B¸ê®Æ·´·lµ¥
	¡C</para>
    </warning>

    <indexterm>
      <primary>CVS</primary>
      <secondary>anonymous</secondary>
    </indexterm>

    <para><application>Anonymous CVS</application> ¤Î
      <application>CVSup</application> §¡¬O±Ä <emphasis>pull</emphasis>
      ¼Ò¦¡¨Ó§ó·s­ì©l½X¡C  ¥H <application>CVSup</application> ¬°¨Ò¡A
      ¨Ï¥ÎªÌ(©Î <command>cron</command> script)·|°õ¦æ <command>cvsup</command>
      µ{¦¡¡A«áªÌ·|»P¬Y¤@¥x <command>cvsupd</command> ¦øªA¾¹§@¨Ç¤¬°Ê¡A
      ¥H§ó·s¬ÛÃö­ì©l½XÀɮסC  ±z©Ò¦¬¨ì§ó·s·|¬O·í®É³Ì·sªº¡A
      ¦Ó¥B¥u·|¦¬¨ì»Ý§ó·sªº³¡¤À¡C  ¦¹¥~¡A¤]¥i¥H«Ü»´ÃP¥h³]©w­n§ó·sªº½d³ò¡C
      §ó·s·|¥Ñ¦øªA¾¹¸ò¥»¾÷¤ñ¹ï¤§«á¡A¥á¥X·í®É±z©Ò»Ý­nªº§ó·sÀÉ®×µ¹§A¡C
      <application>Anonymous CVS</application> ªº·§©À¬Û¹ï©ó
      <application>CVSup</application> ¨Ó±o§ó²³æ¨Ç¡A¦]¬°¥¦¥u¬O
      <application>CVS</application> ªº©µ¦ù¦Ó¤w¡A¤@¼ËÅý§A¥i±q»·ºÝªº
      CVS repository ¨ú¥X³Ì·s­ì©l½X¡C  µM¦Ó <application>CVSup</application>
      ¦b³o¤è­±·|§ó¦³®Ä²v¡A¤£¹L <application>Anonymous CVS</application>
      ¹ï·s¤â¦Ó¨¥¡A¬O¥Î°_¨Ó¤ñ¸û²³æ¡C</para>

    <indexterm>
      <primary><application>CTM</application></primary>
    </indexterm>
    <para>¥t¤@ºØ¤è¦¡«h¬O <application>CTM</application>¡C
      ¥¦¨Ã¤£¬O¥H¥æ½Í¦¡¤¶­±¨Ó¤ñ¹ï±z©Ò¾Ö¦³ªº sources ©M¦øªA¾¹¤Wªº sources
      ©Î¬O±z¨ú±oªº§ó·s³¡¥÷¡C  ¬Û¤Ïªº¡A·|¦³¤@­Ó script
      ÀɱMªù¥Î¨Ó¿ëÃÑÅܧó¹LªºÀɮסA³o­Óµ{¦¡¬O¥Ñ CTM ¦øªA¾¹¨Ó°õ¦æ¡A
      ¨C¤Ñ·|¤ñ¹ï¼Æ¦¸¡A¨Ã§â¨â¦¸°õ¦æ´Á¶¡¤ºÅܧó¹LªºÀÉ®×¥[¥HÀ£ÁY¡A
      ¨Ãµ¹¥¦­Ì¤@­Ó§Ç¸¹¡AµM«á´N¥[¥H½s½X(¥u¥Î printable ASCII ¦r¤¸)¡A
      ¨Ã¥H email ªº¤è¦¡±H¥X¡C  ·í±z¦¬¨ì¥¦ªº®É­Ô¡A³o¨Ç <quote>CTM deltas</quote>
      ´N¥i¥H¥Ñ &man.ctm.rmail.1; µ{¦¡¨Ó³B²z¡A¸Óµ{¦¡·|¦Û°Ê¸Ñ½X¡B½T»{¡B
      ®M¥Î³o¨ÇÅܧó¡C ³oµ{§Ç¤ñ <application>CVSup</application> ¨Ó»¡¬O§Ö±o¦h¤F¡A
      ¦Ó¥B¡A³o­Ó¼Ò¦¡¹ï§Ú­Ìªº¦øªA¾¹¨Ó»¡¬O¤ñ¸û»´ÃPªº¡A¦]¬°³o¬O¤@­Ó
      <emphasis>push</emphasis> ªº¼Ò¦¡¡A¦Ó«D <emphasis>pull</emphasis>
      ªº¼Ò¦¡¡C</para>

    <para>·íµM¡A³o¼Ë°µ¤]·|±a¨Ó¤@¨Ç¤£«K¡C  ­Y¤£¤p¤ß§â±z³¡¥÷ªºµ{¦¡²M°£±¼¤F¡A
      <application>CVSup</application> ·|°»´ú¥X¨Ó¡A¨Ã¦Û°Ê¬°±z§â¤£¨¬ªº³¡¥÷¸É»ô¡C
      <application>CTM</application> ¨Ã¤£·|¬°±z°µ³o¨Ç°Ê§@¡C
      ­Y²M±¼¤F±zªº³¡¥÷ source (¦Ó¥B¨S³Æ¥÷)¡A±z¥i¥H±qÀY¶}©l(±q³Ì·sªº CVS
      <quote>base delta</quote>)¨Ã¥Î <application>CTM</application> ¨Ó­««Ø¥¦­Ì
      ¡A©Î¬O¥Î <application>Anonymous CVS</application> ¨Ó§¹¦¨¡A
      ¥u­n§â¤£¥¿½Tªº¦a¤è¬å±¼¡A¦A­«·s°µ¦P¨Bªº°Ê§@§Y¥i¡C</para>
  </sect1>

  <sect1 id="makeworld">
    <title>­«·s½sĶ <quote>world</quote></title>

    <indexterm>
      <primary>Rebuilding <quote>world</quote></primary>
    </indexterm>
    <para>¦b§ó·s &os; ªº source tree ¨ì³Ì·s¤§«á(µL½×¬O &os.stable;¡B
      &os.current; µ¥µ¥)¡A±µ¤U¨Ó´N¥i¥H¥Î³o¨Ç source tree ¨Ó­«·s½sĶ¨t²Î
      ¡C</para>

    <warning>
      <title>°µ¦n³Æ¥÷</title>

      <para>¦b§@¥ô¦ó¤j°Ê§@ <emphasis>¤§«e</emphasis>
	­n°O±o¥ý§â¨t²Î§@³Æ¥÷ªº­«­n©ÊµL¶·±j½Õ¡C ¾¨ºÞ­«·s½sĶ world ¬O
	(¥u­n¦³·Ó¤å¥ó«ü¥Ü¥h§@ªº¸Ü)¤@¥ó«Ü²³æªº¨Æ±¡¡A¦ý¥X¿ù¤]¬O¦b©ÒÃø§Kªº¡C
	¥t¥~¡A§O¤H¦b source tree ¤£·V·d²Vªº¿ù»~¡A¤]¥i¯à·|³y¦¨¨t²ÎµLªk¶}¾÷
	¡C</para>

      <para>½Ð½T»{¦Û¤v¤w§@§´¬ÛÃö³Æ¥÷¡A¨Ã¥B¤âÃ䦳 fixit ºÏ¤ù©Î¶}¾÷¥úºÐ¡C
	±z¥i¯à¥Ã»·¤]¥Î¤£¨ì³o¨ÇªF¦è¡A
	¦ý¦w¥þ²Ä¤@Á`¤ñ¨Æ«á»¡©êºp¨Ó±o¦n§a¡I</para>
    </warning>

    <warning>
      <title>­q¾\¬ÛÃöªº Mailing List</title>

      <indexterm><primary>mailing list</primary></indexterm>
      <para>&os.stable; ¥H¤Î &os.current; ¤À¤ä¡A¥»½è¤W´N¬OÄÝ©ó <emphasis>
	¶}µo¶¥¬q</emphasis>¡C  ¬° &os; §@°^Ämªº¤]³£¬O¤H¡A°¸º¸¤]·|¥Ç¿ù»~¡C</para>

      <para>¦³®É­Ô³o¨Ç¿ù»~¨ÃµL¤jê¡A¥u¬O·|Åý¨t²Î²£¥Í·sªº¿ù»~ĵ§i¦Ó¤w¡C
	¦³®É«h¬O¨aÃø¡A¥i¯à·|¾É­P¤£¯à¶}¾÷©ÎÀɮרt²Îªº·´·l(©Î§óÁV)¡C</para>

      <para>­Y¹J¨ìÃþ¦ü°ÝÃD¡A¶K«Ê¼ÐÃD¬° <quote>heads up(ª`·N)</quote>
	¶}ÀYªº«H¨ì¬ÛÃöªº mailing list¡A¨ÃÁ¿²M·¡°ÝÃDÂI¥H¤Î·|¼vÅT­þ¨Ç¨t²Î¡C
	¦b°ÝÃDÀò¸Ñ¨M«á¡A¦A¶K¼ÐÃD¬° <quote>all clear(¤w¸Ñ¨M)</quote>
	¶}ÀYªºÁn©ú«H¡C</para>

      <para>­Y¥Îªº¬O &os.stable; ©Î &os.current;¡A«o¤S¤£¾\Ū &a.stable; ©Î
	&a.current; ªº°Q½×¡A¨º»ò·|¬O¦Û§ä³Â·Ð¦Ó¤w¡C</para>
    </warning>

    <warning>
      <title>¤£­n¥Î <command>make world</command></title>

      <para>¤@°ï¦­´ÁªºÂ¤å¥ó³£·|«Øij»¡¨Ï¥Î <command>make world</command>¡C
	³o¼Ë°µ·|¸õ¹L¤@¨Ç­«­n¨BÆJ¡A«Øij¥u¦³¦b§Aª¾¹D¦Û¤v¦b§@¤°»ò¡A¦A³o»ò°µ¡C
	¦bµ´¤j¦h¼Æªº±¡ªp¤U¡A½Ð¤£­n¶Ã¥Î <command>make world</command>¡A
	¦Ó¸Ó§ï¥Î¤U­±¤¶²Ðªº¤è¦¡¡C</para>
    </warning>

    <sect2>
      <title>§ó·s¨t²Îªº¼Ð·Ç¤è¦¡</title>

      <para>­n¤É¯Å¨t²Î«e¡A¤@©w­n¥ý¬d¾\ <filename>/usr/src/UPDATING</filename>
	¤å¥ó¡A¥HÁA¸Ñ buildworld ¤§«e»Ý­n§@­þ¨Ç¨Æ±¡©Îª`·N¨Æ¶µ¡A
	µM«á¤~¥Î¤U¦C¨BÆJ¡G</para>

      <screen>&prompt.root; <userinput>make buildworld</userinput>
&prompt.root; <userinput>make buildkernel</userinput>
&prompt.root; <userinput>make installkernel</userinput>
&prompt.root; <userinput>reboot</userinput></screen>

      <note>
	<para>¦b¤Ö¼Æª¬ªp¡A¥i¯à»Ý­n¥ý¦b <maketarget>buildworld</maketarget>
	  ¨BÆJ¤§«e¥ý§@ <command>mergemaster -p</command> ¤~¯à§¹¦¨¡C
	  ¦Ü©ó¦ó®É»Ý­n©Î¤£»Ý­n¡A½Ð°Ñ¾\ <filename>UPDATING</filename> ¤ºªº»¡©ú¡C
	  ¤@¯ë¨Ó»¡¡A¥u­n¤£¬O¶i¦æ¸óª©¸¹(major)ªº &os; ª©¥»¤É¯Å¡A
	  ´N¥i²¤¹L³o¨BÆJ¡C</para>
      </note>

      <para>§¹¦¨ <maketarget>installkernel</maketarget> ¤§«á¡A»Ý­n­«¶}¾÷¨Ã¤Á¨ì
	single user ¼Ò¦¡(Á|¨Ò¡G¤]¥i¥H¦b loader ´£¥Ü²Å¸¹«á­±¥[¤W
	<command>boot -s</command>)¡C  ±µ¤U¨Ó°õ¦æ¡G</para>

      <screen>&prompt.root; <userinput>mergemaster -p</userinput>
&prompt.root; <userinput>make installworld</userinput>
&prompt.root; <userinput>mergemaster</userinput>
&prompt.root; <userinput>reboot</userinput></screen>

      <warning>
	<title>Read Further Explanations</title>

	<para>¤W­z¨BÆJ¥u¬O¨ó§U±z¤É¯ÅªºÂ²³æ»¡©ú¦Ó¤w¡A­Y­n²M·¡ÁA¸Ñ¨C¤@¨BÆJ¡A
	  ¤×¨ä¬O­Y±ý¦Û¦æ¥´³y kernel ³]©w¡A´N§ó¸Ó¾\Ū¤U­±ªº¤º®e¡C</para>
      </warning>
    </sect2>

    <sect2>
      <title>¾\Ū <filename>/usr/src/UPDATING</filename></title>

      <para>¦b§@¥ô¦ó¨Æ±¡¤§«e¡A½Ð°È¥²¥ý¾\Ū
	<filename>/usr/src/UPDATING</filename> (©Î¦b source code ¤ºÃþ¦üªº¤å¥ó)
	¡C  ³o¥÷¤å¥ó·|¼g¨ì¥i¯à¾D¹Jªº°ÝÃD¡A©Î«ü©w¨º¨Ç·|°õ¦æªº«ü¥O¶¶§Ç¬°¦ó¡C
	¦pªG§A¾÷¾¹²{¦bªº <filename>UPDATING</filename>
	¤å¥ó»P³oÃ䪺´y­z¦³½Ä¬ð¡B¥Ù¬Þ¤§³B¡A¨º»ò½Ð¥H¾÷¾¹¤Wªº
	<filename>UPDATING</filename> ¬°·Ç¡C</para>

      <important>
	<para>µM¦Ó¡A¦p¦P¥ý«e©Ò­z¡A³æ³æ¥u¾a¾\Ū <filename>UPDATING</filename>
	  ¨Ã¤£¯à§¹¥þ¨ú¥N mailing list¡C  ³o¨âªÌ³£¬O¤¬¸Éªº¡A¦Ó¤£¬Û±Æ¥¸¡C</para>
      </important>
    </sect2>

    <sect2>
      <title>Àˬd <filename>/etc/make.conf</filename></title>
      <indexterm>
        <primary><filename>make.conf</filename></primary>
      </indexterm>

      <para>Àˬd
	<filename>/usr/share/examples/etc/make.conf</filename>
	¥H¤Î
	<filename>/etc/make.conf</filename>¡C  ²Ä¤@¥÷¤å¥ó¤D¬O¤@¨Ç¨t²Î¹w³]­È
	&ndash; ¤£¹L¡A¤j³¡¤À³£³Qµù¸Ñ°_¨Ó¡C  ¬°¤F¦b­«·s½sĶ®É¯à°÷¨Ï¥Î³o¨Ç¡A
	½Ð§â³o¨Ç³]©w¥[¨ì <filename>/etc/make.conf</filename>¡C  ½Ðª`·N¦b
	<filename>/etc/make.conf</filename> ªº¥ô¦ó³]©w¤]·|¼vÅT¨ì¨C¦¸¨Ï¥Î
	<command>make</command> ªºµ²ªG¡A
	¦]¦¹³]©w¤@¨Ç¾A¦X¦Û¤v¨t²Îªº¿ï¶µ·|¬O¤£¿ùªº§@ªk¡C</para>

      <para>¤@¯ë¨Ï¥ÎªÌ³q±`·|±q
	<filename>/usr/share/examples/etc/make.conf</filename> ½Æ»s
	<makevar>CFLAGS</makevar> ¥H¤Î <makevar>NO_PROFILE</makevar>
	¤§Ãþªº³]©w¨ì <filename>/etc/make.conf</filename>¡A¨Ã¸Ñ°£¬ÛÃöµù¸Ñ¦L°O
	¡C</para>

      <para>¦¹¥~¡A¤]¥i¥H¸Õ¸Õ¬Ý¨ä¥L³]©w (<makevar>COPTFLAGS</makevar>¡B
	<makevar>NOPORTDOCS</makevar> µ¥µ¥)¡A¬O§_²Å¦X¦Û¤v©Ò»Ý¡C</para>
    </sect2>

    <sect2>
      <title>§ó·s <filename>/etc</filename> ¤ºªº³]©wÀÉ</title>

      <para>¦b <filename>/etc</filename> ¥Ø¿ý·|¦³¨t²Îªº¬ÛÃö³]©wÀÉ¡A
	¥H¤Î¶}¾÷®Éªº¦U¶µªA°È±Ò°Ê script¡C  ¦³¨Ç script ÀH FreeBSD
	ª©¥»ªº¤£¦P¦Ó¦³¨Ç®t²§¡C</para>

      <para>¨ä¤¤¦³¨Ç³]©wÀÉ·|¦b¨C¤é¹B§@ªº¨t²Î¸Ì¤]·|¥Î¨ì¡C  ¤×¨ä¬O
	<filename>/etc/group</filename>¡C</para>

      <para>¦³®É­Ô¦b <command>make installworld</command> ¦w¸Ë¹Lµ{¤¤¡A
	·|»Ý­n¥ý«Ø¥ß¬Y¨Ç¯S©w±b¸¹©Î¸s²Õ¡C  ¦b¶i¦æ¤É¯Å¤§«e¡A¥¦­Ì¥i¯à¨Ã¤£¦s¦b¡A
	¦]¦¹¤É¯Å®É´N·|³y¦¨°ÝÃD¡C  ¦³®É­Ô <command>make buildworld</command>
	·|¥ýÀˬd³o¨Ç©Ò»Ýªº±b¸¹©Î¸s²Õ¬O§_¤w¦³¦s¦b¡C</para>

      <para>Á|­Ó³o¼Ëªº¨Ò¤l¡A¹³¬O¬Y¦¸¤É¯Å¤§«á¥²¶··s¼W <username>smmsp</username>
	±b¸¹¡C  ­Y¨Ï¥ÎªÌ©|¥¼·s¼W¸Ó±b¸¹´N­n§¹¦¨¤É¯Å¾Þ§@ªº¸Ü¡A
	·|¦b &man.mtree.8; ¹Á¸Õ«Ø¥ß <filename>/var/spool/clientmqueue</filename>
	®Éµo¥Í¥¢±Ñ¡C</para>

      <para>¸Ñªk¬O¦b buildworld ¶¥¬q¤§«e¡A¥ý°õ¦æ &man.mergemaster.8; ¨Ã·f°t
	<option>-p</option> ¿ï¶µ¡C  ¥¦·|¤ñ¹ï¨º¨Ç°õ¦æ
	<maketarget>buildworld</maketarget> ©Î
	<maketarget>installworld</maketarget> ©Ò»Ý¤§ÃöÁä³]©wÀÉ¡C
	­Y§A©Ò¥Îªº¬O¦­´Á¤´¥¼¤ä´© <option>-p</option> ªº
	<command>mergemaster</command> ª©¥»¡A¨º»òª½±µ¨Ï¥Î source tree
	¤ºªº·sª©§Y¥i¡G</para>

      <screen>&prompt.root; <userinput>cd /usr/src/usr.sbin/mergemaster</userinput>
&prompt.root; <userinput>./mergemaster.sh -p</userinput></screen>

      <tip>
	<para>­Y±z¬O°¾°õ¨g(paranoid)¡A
	  ¥i¥H¹³¤U­±³o¼Ë¥h¸ÕµÛÀˬd¨t²Î¤W¦³­þ¨ÇÀÉ®×ÄÝ©ó¤w§ï¦W©Î³Q§R°£ªº¸s²Õ
	  ¡G</para>

	<screen>&prompt.root; <userinput>find / -group <replaceable>GID</replaceable> -print</userinput></screen>

	<para>³o·|Åã¥Ü©Ò¦³²Å¦X­n§äªº <replaceable>GID</replaceable> ¸s²Õ
	  (¥i¥H¬O¸s²Õ¦WºÙ¡A©ÎªÌ¬O¸s²Õªº¼Æ¦r¥N¸¹)ªº©Ò¦³ÀɮסC</para>
      </tip>
    </sect2>

    <sect2 id="makeworld-singleuser">
      <title>¤Á´«¨ì Single User ¼Ò¦¡</title>
      <indexterm><primary>single-user mode</primary></indexterm>

      <para>±z¥i¯à·|·Q¦b single user ¼Ò¦¡¤U½sĶ¨t²Î¡C
	°£¤F¥i¥H©úÅã§ó§Ö§¹¦¨¤§¥~¡A¦w¸Ë¹Lµ{¤¤±N·|²o¯A³\¦h­«­nªº¨t²ÎÀɮסA
	¥]¬A©Ò¦³¨t²Î binaries¡Blibraries¡Binclude ÀÉ®×µ¥¡C
	­Y¦b¹B§@¤¤ªº¨t²Î(¤×¨ä¦³³\¦h¨Ï¥ÎªÌ¦b¥Îªº®É­Ô)¤º§ó§ï³o¨ÇÀɮסA
	¨ºÂ²ª½¬O¦Û§ä³Â·Ðªº§@ªk¡C</para>

      <indexterm><primary>multi-user mode</primary></indexterm>
      <para>¥t¤@ºØ¼Ò¦¡¬O¥ý¦b multi-user ¼Ò¦¡¤U½sĶ¦n¨t²Î¡AµM«á¦A¤Á¨ì single user
	¼Ò¦¡¥h¦w¸Ë¡C  ­Y±z¤ñ¸û³ßÅw³oºØ¤è¦¡¡A¥u»Ý¦b build(½sĶ¹Lµ{) §¹¦¨¤§«á¡A
	¦A¥h°õ¦æ¤U­±ªº¨BÆJ§Y¥i¡C  ¤@ª½¨ì¥i¤Á´« single user ¼Ò¦¡®É¡A¦A¥h°õ¦æ
	<maketarget>installkernel</maketarget> ©Î
	<maketarget>installworld</maketarget> §Y¥i¡C</para>

      <para>¤Á´«¬° root ¨­¥÷¥´¡G</para>

      <screen>&prompt.root; <userinput>shutdown now</userinput></screen>

      <para>³o¼Ë´N·|±q­ì¥»ªº multi-user ¼Ò¦¡¤Á´«¨ì single user ¼Ò¦¡¡C</para>

      <para>°£¦¹¤§¥~¤]¥i¥H­«¶}¾÷¡A±µµÛ¦b¶}¾÷¿ï³æ³B¿ï¾Ü
	<quote>single user</quote> ¿ï¶µ¡C  ¦p¦¹¤@¨Ó´N·|¶i¤J single user ¼Ò¦¡¡A
	µM«á¦b shell ´£¥Ü²Å¸¹³B¿é¤J¡G</para>

      <screen>&prompt.root; <userinput>fsck -p</userinput>
&prompt.root; <userinput>mount -u /</userinput>
&prompt.root; <userinput>mount -a -t ufs</userinput>
&prompt.root; <userinput>swapon -a</userinput></screen>

      <para>³o¼Ë·|¥ýÀˬdÀɮרt²Î¡A¨Ã­«·s±N <filename>/</filename>
	§ï¥H¥iŪ¼gªº¼Ò¦¡±¾¸ü¡A¥H¤Î <filename>/etc/fstab</filename>
	¤º©Ò³]©wªº¨ä¥L UFS Àɮרt²Î¡A³Ì«á±Ò¥Î swap ºÏ°Ï¡C</para>


        <note>
          <para>­Y CMOS ®ÉÄÁ¬O³]¬°·í¦a®É¶¡¡A¦Ó«D GMT ®É°Ï(­Y &man.date.1;
	    «ü¥O¨SÅã¥Ü¥¿½Tªº®É¶¡¡B®É°Ï)¡A¨º¥i¯à»Ý­n¦A¿é¤J¤U¦C«ü¥O¡G</para>
<screen>&prompt.root; <userinput>adjkerntz -i</userinput></screen>

          <para>³o¨BÆJ¥i¥H½T»{±zªº·í¦a®É°Ï³]©w¬O§_¥¿½T &mdash;
	    §_«h¤é«á·|³y¦¨¤@¨Ç°ÝÃD¡C</para>
        </note>

    </sect2>

    <sect2>
      <title>²¾°£ <filename>/usr/obj</filename></title>

      <para>¦b­«·s½sĶ¨t²Îªº¹Lµ{¤¤¡A½sĶµ²ªG·|©ñ¨ì(¹w³]±¡ªp)
	<filename>/usr/obj</filename> ¤º¡C  ³o¸Ì­±ªº¥Ø¿ý·|¹ïÀ³¨ì
	<filename>/usr/src</filename> ªº¥Ø¿ýµ²ºc¡C</para>

      <para>¬å±¼³o¥Ø¿ý¡A¥i¥HÅý¥H«áªº <command>make buildworld</command>
	¹Lµ{§ó§Ö¤@¨Ç¡A¦Ó¥B¥iÁקK¥H«e½sĶªºªF¦è¸ò²{¦bªº²V²c¦b¤@°_ªº¬Û¨Ì¿ù¶Ã
	¡C</para>

      <para>¦Ó¦³¨Ç <filename>/usr/obj</filename> ¤ºªºÀÉ®×¥i¯à·|³]©w¤£¥i§ó°Êªº
	flag(²Ó¸`½Ð°Ñ¾\ &man.chflags.1;)¡A¦Ó¥²¶·¥ý®³±¼³o¨Ç flag ³]©w¤~¦æ
	¡C</para>

      <screen>&prompt.root; <userinput>cd /usr/obj</userinput>
&prompt.root; <userinput>chflags -R noschg *</userinput>
&prompt.root; <userinput>rm -rf *</userinput></screen>
    </sect2>

    <sect2 id="cutting-edge-compilebase">
      <title>­«·s½sĶ Base System</title>

      <sect3>
	<title>«O¯d½sĶªº¬ö¿ý</title>

	<para>«Øij¾i¦¨¦n²ßºD¡A§â°õ¦æ &man.make.1; ®É²£¥Íªº¬ö¿ý¦s°_¨Ó¡C
	  ³o¼Ë­Y¦³­þÃä¥X¿ù¡A´N·|¦³¿ù»~°T®§ªº¬ö¿ý¡C  ÁöµM³æ³æ³o¼Ë¡A
	  §A¥i¯à¤£ª¾¹D¦p¦ó¤ÀªR¬O­þÃä¥X¤F§Ã¡A¦ý­Y§â§A°ÝÃD°O¿ý¶K¨ì &os; ¬ÛÃöªº
	  mailing list ´N¥i¥H¦³¤H¥i¥HÀ°¦£¬Ý¬O«ç»ò¤@¦^¨Æ±¡¡C</para>

	<para>³Ì²³æªº¤è¬O´N¬O¥Î &man.script.1; «ü¥O¡A¨Ã¥[¤W°Ñ¼Æ
	  (§A·Q¦s©ñ°O¿ýªºÀɮצì¸m¡BÀɦW)§Y¥i¡C
	  ³o¨BÆJÀ³¸Ó¦b­«·s½sĶ¨t²Î®É´N­n§@¡AµM«á¦b§¹¦¨½sĶ«á¿é¤J
	  <userinput>exit</userinput> §Y¥iÂ÷¶}¡C</para>

	<screen>&prompt.root; <userinput>script /var/tmp/mw.out</userinput>
Script started, output file is /var/tmp/mw.out
&prompt.root; <userinput>make TARGET</userinput>
<emphasis>&hellip; compile, compile, compile &hellip;</emphasis>
&prompt.root; <userinput>exit</userinput>
Script done, &hellip;</screen>

	<para>¹ï¤F¡AÁÙ¦³¤@ÂI¾¨¶q<emphasis>§O§â</emphasis>Àɮצs¨ì
	  <filename>/tmp</filename> ¥Ø¿ý¤º¡C  ¦]¬°­«¶}¾÷¤§«á¡A
	  ³o¥Ø¿ý¤ºªºªF¦è³£·|³Q²MªÅ¡C  ¤ñ¸û§´µ½ªº¦a¤è¬O
	  <filename>/var/tmp</filename> (¦p¤W¨Ò©Ò¥Ü) ©ÎªÌ¬O
	  <username>root</username> ªº®a¥Ø¿ý¡C</para>
      </sect3>

      <sect3 id="make-buildworld">
	<title>½sĶ Base System</title>

	<para>­º¥ý½Ð¥ý¤Á´«¨ì <filename>/usr/src</filename> ¥Ø¿ý¡G</para>

	<screen>&prompt.root; <userinput>cd /usr/src</userinput></screen>

	<para>(·íµM¡A°£«D§A§â source code ©ñ¨ì¨ä¥L¦a¤è¡A­Y¯u¬O³o¼Ë¡A
	  ´N¤Á´«¨ì¨º­Ó¥Ø¿ý§Y¥i)¡C</para>
	<indexterm><primary><command>make</command></primary></indexterm>

	<para>¨Ï¥Î &man.make.1; «ü¥O¨Ó­«·s½sĶ world¡C
	  ³o«ü¥O·|±q <filename>Makefile</filename> ÀÉ(³oÀÉ·|¼g &os;
	  ªºµ{¦¡¸Ó¦p¦ó­«·s½sĶ¡B¥H­þ¨Ç¶¶§Ç¨Ó½sĶµ¥µ¥)¥hŪ¨ú¬ÛÃö«ü¥O¡C</para>

	<para>¤@¯ë¤U«ü¥Oªº®æ¦¡¦p¤U¡G</para>

	<screen>&prompt.root; <userinput>make -<replaceable>x</replaceable> -D<replaceable>VARIABLE</replaceable> <replaceable>target</replaceable></userinput></screen>

	<para>¦b³o­Ó¨Ò¤l¡A<option>-<replaceable>x</replaceable></option>
	  ¬O§A·Q¶Çµ¹ &man.make.1; ªº¿ï¶µ¡A²Ó¸`»¡©ú½Ð°Ñ¾\ &man.make.1; »¡©ú¡A
	  ¸Ì­±¦³¬ÛÃö½d¨Ò»¡©ú¡C</para>

	<para><option>-D<replaceable>VARIABLE</replaceable></option>
	  «h¬O§âÅܼƳ]©w¶Çµ¹ <filename>Makefile</filename>¡C  ³o¨ÇÅܼƷ|±±¨î
	  <filename>Makefile</filename> ªº¦æ¬°¡C  ³o¨Ç³]©w»P
	  <filename>/etc/make.conf</filename> ªºÅܼƳ]©w¬O¤@¼Ë¡A
	  ¥u¬O¥t¤@ºØ³]©w¤è¦¡¦Ó¤w¡C</para>

	<screen>&prompt.root; <userinput>make -DNO_PROFILE <replaceable>target</replaceable></userinput></screen>

	<para>¤W­±ªº¨Ò¤l«h¬O¥t¤@ºØ³]©w¤è¦¡¡A¤]´N¬O­þ¨Ç¤£­n¡C
	  ³o­Ó¨Ò¤l¤¤ªº·N«ä¬O¤£¥h½sĶ profiled libraries¡A®ÄªG´N¦p¦P³]©w¦b
	  <filename>/etc/make.conf</filename> ªº</para>

	<programlisting>NO_PROFILE=    true 	#    Avoid compiling profiled libraries</programlisting>

	<para><replaceable>target</replaceable> «h¬O§i¶D &man.make.1;
	  ¸Ó¥h°µ­þ¨Ç¡C  ¨C­Ó <filename>Makefile</filename> ³£·|©w¸q¤£¦Pªº
	  <quote>targets</quote>¡AµM«á¨Ì±z©Òµ¹ªº target ´N·|¨M©w·|°µ­þ¨Ç°Ê§@
	  ¡C</para>

	<para>Some targets are listed in the
	  <filename>Makefile</filename>, but are not meant for you to run.
	  Instead, they are used by the build process to break out the
	  steps necessary to rebuild the system into a number of
	  sub-steps.</para>

	<para>Most of the time you will not need to pass any parameters to
	    &man.make.1;, and so your command like will look like
	    this:</para>

	<screen>&prompt.root; <userinput>make <replaceable>target</replaceable></userinput></screen>

	<para>Where <replaceable>target</replaceable> will be one of
	  many build options.  The first target should always be
	  <makevar>buildworld</makevar>.</para>

	<para>As the names imply, <maketarget>buildworld</maketarget>
	  builds a complete new tree under <filename>/usr/obj</filename>,
	  and <maketarget>installworld</maketarget>, another target, installs this tree on
	  the current machine.</para>

	<para>Having separate options is very useful for two reasons.  First, it allows you
	  to do the build safe in the knowledge that no components of
	  your running system will be affected.  The build is
	  <quote>self hosted</quote>.  Because of this, you can safely
	  run <maketarget>buildworld</maketarget> on a machine running
	  in multi-user mode with no fear of ill-effects.  It is still
	  recommended that you run the
	  <maketarget>installworld</maketarget> part in single user
	  mode, though.</para>

	<para>Secondly, it allows you to use NFS mounts to upgrade
	  multiple machines on your network.  If you have three machines,
	  <hostid>A</hostid>, <hostid>B</hostid> and <hostid>C</hostid> that you want to upgrade, run <command>make
	  buildworld</command> and <command>make installworld</command> on
	  <hostid>A</hostid>.  <hostid>B</hostid> and <hostid>C</hostid> should then NFS mount <filename>/usr/src</filename>
	  and <filename>/usr/obj</filename> from <hostid>A</hostid>, and you can then run
	  <command>make installworld</command> to install the results of
	  the build on <hostid>B</hostid> and <hostid>C</hostid>.</para>

	<para>Although the <maketarget>world</maketarget> target still exists,
	  you are strongly encouraged not to use it.</para>

	<para>Run</para>

	<screen>&prompt.root; <userinput>make buildworld</userinput></screen>

        <para>It is possible to specify a <option>-j</option> option to
          <command>make</command> which will cause it to spawn several
          simultaneous processes.  This is most useful on multi-CPU machines.
          However, since much of the compiling process is IO bound rather
          than CPU bound it is also useful on single CPU machines.</para>

	<para>On a typical single-CPU machine you would run:</para>

	  <screen>&prompt.root; <userinput>make -j4 buildworld</userinput></screen>

	<para>&man.make.1; will then have up to 4 processes running at any one
	  time.  Empirical evidence posted to the mailing lists shows this
	  generally gives the best performance benefit.</para>

	<para>If you have a multi-CPU machine and you are using an SMP
	  configured kernel try values between 6 and 10 and see how they speed
	  things up.</para>
      </sect3>

      <sect3>
	<title>Timings</title>
	<indexterm>
	  <primary>rebuilding <quote>world</quote></primary>
	  <secondary>timings</secondary>
	</indexterm>

        <para>Many factors influence the build time, but fairly recent
          machines may only take a one or two hours to build
          the &os.stable; tree, with no tricks or shortcuts used during the
          process.  A &os.current; tree will take somewhat longer.</para>
      </sect3>
    </sect2>

    <sect2>
      <title>Compile and Install a New Kernel</title>
      <indexterm>
        <primary>kernel</primary>
	<secondary>compiling</secondary>
      </indexterm>

      <para>To take full advantage of your new system you should recompile the
	kernel.  This is practically a necessity, as certain memory structures
	may have changed, and programs like &man.ps.1; and &man.top.1; will
	fail to work until the kernel and source code versions are the
	same.</para>

      <para>The simplest, safest way to do this is to build and install a
	kernel based on <filename>GENERIC</filename>.  While
	<filename>GENERIC</filename> may not have all the necessary devices
	for your system, it should contain everything necessary to boot your
	system back to single user mode.  This is a good test that the new
	system works properly.  After booting from
	<filename>GENERIC</filename> and verifying that your system works you
	can then build a new kernel based on your normal kernel	configuration
	file.</para>

      <para>On &os; it is important to <link
        linkend="make-buildworld">build world</link> before building a
        new kernel.</para>

      <note><para>If you want to build a custom kernel, and already have a configuration
	file, just use <literal>KERNCONF=<replaceable>MYKERNEL</replaceable></literal>
	like this:</para>

      <screen>&prompt.root; <userinput>cd /usr/src</userinput>
&prompt.root; <userinput>make buildkernel KERNCONF=<replaceable>MYKERNEL</replaceable></userinput>
&prompt.root; <userinput>make installkernel KERNCONF=<replaceable>MYKERNEL</replaceable></userinput></screen>
      </note>

      <para>Note that if you have raised <literal>kern.securelevel</literal>
	above 1 <emphasis>and</emphasis> you have set either the
	<literal>noschg</literal> or similar flags to your kernel binary, you
	might find it necessary to drop into single user mode to use
	<maketarget>installkernel</maketarget>.  Otherwise you should be able
	to run both these commands from multi user mode without
	problems.  See &man.init.8; for details about
	<literal>kern.securelevel</literal> and &man.chflags.1; for details
	about the various file flags.</para>
    </sect2>

    <sect2>
      <title>Reboot into Single User Mode</title>
      <indexterm><primary>single-user mode</primary></indexterm>

      <para>You should reboot into single user mode to test the new kernel
	works.  Do this by following the instructions in
	<xref linkend="makeworld-singleuser"/>.</para>
    </sect2>

    <sect2 id="make-installworld">
      <title>Install the New System Binaries</title>

      <para>If you were building a version of &os; recent enough to have
	used <command>make buildworld</command> then you should now use
	<maketarget>installworld</maketarget> to install the new system
	binaries.</para>

      <para>Run</para>

      <screen>&prompt.root; <userinput>cd /usr/src</userinput>
&prompt.root; <userinput>make installworld</userinput></screen>

      <note>
	<para>If you specified variables on the <command>make
	    buildworld</command> command line, you must specify the same
	  variables in the <command>make installworld</command> command
	  line.  This does not necessarily hold true for other options;
	  for example, <option>-j</option> must never be used with
	  <maketarget>installworld</maketarget>.</para>

	<para>For example, if you ran:</para>

	<screen>&prompt.root; <userinput>make -DNO_PROFILE buildworld</userinput></screen>

	<para>you must install the results with:</para>

	<screen>&prompt.root; <userinput>make -DNO_PROFILE installworld</userinput></screen>

	<para>otherwise it would try to install profiled libraries that
	  had not been built during the <command>make buildworld</command>
	  phase.</para>
      </note>
    </sect2>

    <sect2>
      <title>Update Files Not Updated by <command>make installworld</command></title>

      <para>Remaking the world will not update certain directories (in
	particular, <filename>/etc</filename>, <filename>/var</filename> and
	<filename>/usr</filename>) with new or changed configuration files.</para>

      <para>The simplest way to update these files is to use
        &man.mergemaster.8;, though it is possible to do it manually
        if you would prefer to do that.  Regardless of which way you
	choose, be sure to make a backup of <filename>/etc</filename> in
	case anything goes wrong.</para>

    <sect3 id="mergemaster">
      <sect3info>
	<authorgroup>
	  <author>
	    <firstname>Tom</firstname>
	    <surname>Rhodes</surname>
	    <contrib>Contributed by </contrib>
	  </author>
	</authorgroup>
      </sect3info>
      <title><command>mergemaster</command></title>
        <indexterm><primary><command>mergemaster</command></primary></indexterm>

      <para>The &man.mergemaster.8; utility is a Bourne script that will
        aid you in determining the differences between your configuration files
        in <filename>/etc</filename>, and the configuration files in
        the source tree <filename>/usr/src/etc</filename>. This is
        the recommended solution for keeping the system configuration files up to date
        with those located in the source tree.</para>

      <para>To begin simply type <command>mergemaster</command> at your prompt, and
        watch it start going.  <command>mergemaster</command> will then build a
        temporary root environment, from <filename>/</filename> down, and populate
        it with various system configuration files.  Those files are then compared
        to the ones currently installed in your system.  At this point, files that
        differ will be shown in &man.diff.1; format, with the <option>+</option> sign
        representing added or modified lines, and <option>-</option> representing
        lines that will be either removed completely, or replaced with a new line.
        See the &man.diff.1; manual page for more information about the &man.diff.1;
        syntax and how file differences are shown.</para>

      <para>&man.mergemaster.8; will then show you each file that displays variances,
        and at this point you will have the option of either deleting the new file (referred
        to as the temporary file), installing the temporary file in its unmodified state,
        merging the temporary file with the currently installed file, or viewing the
        &man.diff.1; results again.</para>

      <para>Choosing to delete the temporary file will tell &man.mergemaster.8; that we
        wish to keep our current file unchanged, and to delete the new version.
        This option is not recommended, unless you see no
        reason to change the current file.  You can get help at any time by
        typing <keycap>?</keycap> at the &man.mergemaster.8; prompt.  If the user
        chooses to skip a file, it will be presented again after all other files
        have been dealt with.</para>

      <para>Choosing to install the unmodified temporary file will replace the
        current file with the new one.  For most unmodified files, this is the best
        option.</para>

      <para>Choosing to merge the file will present you with a text editor,
        and the contents of both files.  You can now merge them by
        reviewing both files side by side on the screen, and choosing parts from
        both to create a finished product.  When the files are compared side by side,
        the <keycap>l</keycap> key will select the left contents and the
        <keycap>r</keycap> key will select contents from your right.
        The final output will be a file consisting of both parts, which can then be
        installed.  This option is customarily used for files where settings have been
        modified by the user.</para>

      <para>Choosing to view the &man.diff.1; results again will show you the file differences
        just like &man.mergemaster.8; did before prompting you for an option.</para>

      <para>After &man.mergemaster.8; is done with the system files you will be
        prompted for other options.  &man.mergemaster.8; may ask if you want to rebuild
        the password file and will finish up with an option to
        remove left-over temporary files.</para>
      </sect3>

      <sect3>
	<title>Manual Update</title>

      <para>If you wish to do the update manually, however,
        you cannot just copy over the files from
	<filename>/usr/src/etc</filename> to <filename>/etc</filename> and
	have it work.  Some of these files must be <quote>installed</quote>
	first.  This is because the <filename>/usr/src/etc</filename>
	directory <emphasis>is not</emphasis> a copy of what your
	<filename>/etc</filename> directory should look like.  In addition,
	there are files that should be in <filename>/etc</filename> that are
	not in <filename>/usr/src/etc</filename>.</para>

      <para>If you are using &man.mergemaster.8; (as recommended),
        you can skip forward to the <link linkend="cutting-edge-rebooting">next
	section</link>.</para>

      <para>The simplest way to do this by hand is to install the
	files into a new directory, and then work through them looking
	for differences.</para>

      <warning>
	<title>Backup Your Existing <filename>/etc</filename></title>

	<para>Although, in theory, nothing is going to touch this directory
	  automatically, it is always better to be sure.  So copy your
	  existing <filename>/etc</filename> directory somewhere safe.
	  Something like:</para>

	<screen>&prompt.root; <userinput>cp -Rp /etc /etc.old</userinput></screen>

	<para><option>-R</option> does a recursive copy, <option>-p</option>
	  preserves times, ownerships on files and suchlike.</para>
      </warning>

      <para>You need to build a dummy set of directories to install the new
	<filename>/etc</filename> and other files into.
	<filename>/var/tmp/root</filename> is a reasonable choice, and
	there are a number of subdirectories required under this as
	well.</para>

      <screen>&prompt.root; <userinput>mkdir /var/tmp/root</userinput>
&prompt.root; <userinput>cd /usr/src/etc</userinput>
&prompt.root; <userinput>make DESTDIR=/var/tmp/root distrib-dirs distribution</userinput></screen>

      <para>This will build the necessary directory structure and install the
	files.  A lot of the subdirectories that have been created under
	<filename>/var/tmp/root</filename> are empty and should be deleted.
	The simplest way to do this is to:</para>

      <screen>&prompt.root; <userinput>cd /var/tmp/root</userinput>
&prompt.root; <userinput>find -d . -type d | xargs rmdir 2&gt;/dev/null</userinput></screen>

      <para>This will remove all empty directories.  (Standard error is
        redirected to <filename>/dev/null</filename> to prevent the warnings
        about the directories that are not empty.)</para>

      <para><filename>/var/tmp/root</filename> now contains all the files that
	should be placed in appropriate locations below
	<filename>/</filename>.  You now have to go through each of these
	files, determining how they differ with your existing files.</para>

      <para>Note that some of the files that will have been installed in
	<filename>/var/tmp/root</filename> have a leading <quote>.</quote>.  At the
	time of writing the only files like this are shell startup files in
	<filename>/var/tmp/root/</filename> and
	<filename>/var/tmp/root/root/</filename>, although there may be others
	(depending on when you are reading this).  Make sure you use
	<command>ls -a</command> to catch them.</para>

      <para>The simplest way to do this is to use &man.diff.1; to compare the
	two files:</para>

      <screen>&prompt.root; <userinput>diff /etc/shells /var/tmp/root/etc/shells</userinput></screen>

      <para>This will show you the differences between your
	<filename>/etc/shells</filename> file and the new
	<filename>/var/tmp/root/etc/shells</filename> file.  Use these to decide whether to
	merge in changes that you have made or whether to copy over your old
	file.</para>

      <tip>
	<title>Name the New Root Directory
	  (<filename>/var/tmp/root</filename>) with a Time Stamp, so You Can
	  Easily Compare Differences Between Versions</title>

	<para>Frequently rebuilding the world means that you have to update
	<filename>/etc</filename> frequently as well, which can be a bit of
	  a chore.</para>

	<para>You can speed this process up by keeping a copy of the last set
	  of changed files that you merged into <filename>/etc</filename>.
	  The following procedure gives one idea of how to do this.</para>

	<procedure>
	  <step>
	    <para>Make the world as normal.  When you want to update
	      <filename>/etc</filename> and the other directories, give the
	      target directory a name based on the current date.  If you were
	      doing this on the 14th of February 1998 you could do the
	      following:</para>

	    <screen>&prompt.root; <userinput>mkdir /var/tmp/root-19980214</userinput>
&prompt.root; <userinput>cd /usr/src/etc</userinput>
&prompt.root; <userinput>make DESTDIR=/var/tmp/root-19980214 \
    distrib-dirs distribution</userinput></screen>
	  </step>

	  <step>
	    <para>Merge in the changes from this directory as outlined
	      above.</para>

	    <para><emphasis>Do not</emphasis> remove the
	      <filename>/var/tmp/root-19980214</filename> directory when you
	      have finished.</para>
	  </step>

	  <step>
	    <para>When you have downloaded the latest version of the source
	      and remade it, follow step 1.  This will give you a new
	      directory, which might be called
	      <filename>/var/tmp/root-19980221</filename> (if you wait a week
	      between doing updates).</para>
	  </step>

	  <step>
	    <para>You can now see the differences that have been made in the
	      intervening week using &man.diff.1; to create a recursive diff
	      between the two directories:</para>

	    <screen>&prompt.root; <userinput>cd /var/tmp</userinput>
&prompt.root; <userinput>diff -r root-19980214 root-19980221</userinput></screen>

	    <para>Typically, this will be a much smaller set of differences
	      than those between
	      <filename>/var/tmp/root-19980221/etc</filename> and
	      <filename>/etc</filename>.  Because the set of differences is
	      smaller, it is easier to migrate those changes across into your
	      <filename>/etc</filename> directory.</para>
	  </step>

	  <step>
	    <para>You can now remove the older of the two
	      <filename>/var/tmp/root-*</filename> directories:</para>

	    <screen>&prompt.root; <userinput>rm -rf /var/tmp/root-19980214</userinput></screen>
	  </step>

	  <step>
	    <para>Repeat this process every time you need to merge in changes
	      to <filename>/etc</filename>.</para>
	  </step>
	</procedure>

	<para>You can use &man.date.1; to automate the generation of the
	  directory names:</para>

	<screen>&prompt.root; <userinput>mkdir /var/tmp/root-`date "+%Y%m%d"`</userinput></screen>
      </tip>
      </sect3>
    </sect2>

    <sect2 id="cutting-edge-rebooting">
      <title>Rebooting</title>

      <para>You are now done.  After you have verified that everything appears
	to be in the right place you can reboot the system.  A simple
	&man.shutdown.8; should do it:</para>

      <screen>&prompt.root; <userinput>shutdown -r now</userinput></screen>
    </sect2>

    <sect2>
      <title>Finished</title>

      <para>You should now have successfully upgraded your &os; system.
	Congratulations.</para>

      <para>If things went slightly wrong, it is easy to rebuild a particular
        piece of the system.  For example, if you accidentally deleted
        <filename>/etc/magic</filename> as part of the upgrade or merge of
        <filename>/etc</filename>, the &man.file.1; command will stop working.
        In this case, the fix would be to run:</para>

	<screen>&prompt.root; <userinput>cd /usr/src/usr.bin/file</userinput>
&prompt.root; <userinput>make all install</userinput></screen>
    </sect2>

    <sect2>
      <title>Questions</title>

      <qandaset>
	<qandaentry>
	  <question>
	    <para>Do I need to re-make the world for every change?</para>
	  </question>

	  <answer>
            <para>There is no easy answer to this one, as it depends on the
	      nature of the change.  For example, if you just ran <application>CVSup</application>, and
	      it has shown the following files as being updated:</para>

	    <screen><filename>src/games/cribbage/instr.c</filename>
<filename>src/games/sail/pl_main.c</filename>
<filename>src/release/sysinstall/config.c</filename>
<filename>src/release/sysinstall/media.c</filename>
<filename>src/share/mk/bsd.port.mk</filename></screen>

	    <para>it probably is not worth rebuilding the entire world.
	      You could just go to the appropriate sub-directories and
	      <command>make all install</command>, and that's about it.  But
	      if something major changed, for example
	      <filename>src/lib/libc/stdlib</filename> then you should either
	      re-make the world, or at least those parts of it that are
	      statically linked (as well as anything else you might have added
	      that is statically linked).</para>

	    <para>At the end of the day, it is your call.  You might be happy
	      re-making the world every fortnight say, and let changes
	      accumulate over that fortnight.  Or you might want to re-make
	      just those things that have changed, and be confident you can
	      spot all the dependencies.</para>

	    <para>And, of course, this all depends on how often you want to
	      upgrade, and whether you are tracking &os.stable; or
	      &os.current;.</para>
	  </answer>
	</qandaentry>

	<qandaentry>
	  <question>
	    <para>My compile failed with lots of signal 11<indexterm>
	      <primary>signal 11</primary></indexterm> (or other signal
	      number) errors.  What has happened?</para>
	  </question>

	  <answer>
	    <para>This is normally indicative of hardware problems.
	      (Re)making the world is an effective way to stress test your
	      hardware, and will frequently throw up memory problems.  These
	      normally manifest themselves as the compiler mysteriously dying
	      on receipt of strange signals.</para>

	    <para>A sure indicator of this is if you can restart the make and
	      it dies at a different point in the process.</para>

	    <para>In this instance there is little you can do except start
	      swapping around the components in your machine to determine
	      which one is failing.</para>
	  </answer>
	</qandaentry>

	<qandaentry>
	  <question>
	    <para>Can I remove <filename>/usr/obj</filename> when I have
	      finished?</para>
	  </question>

	  <answer>
	    <para>The short answer is yes.</para>

	    <para><filename>/usr/obj</filename> contains all the object files
	      that were produced during the compilation phase.  Normally, one
	      of the first steps in the <command>make buildworld</command> process is to
	      remove this directory and start afresh.  In this case, keeping
	      <filename>/usr/obj</filename> around after you have finished
	      makes little sense, and will free up a large chunk of disk space
	      (currently about 340&nbsp;MB).</para>

	    <para>However, if you know what you are doing you can have
	      <command>make buildworld</command> skip this step.  This will make subsequent
	      builds run much faster, since most of sources will not need to
	      be recompiled.  The flip side of this is that subtle dependency
	      problems can creep in, causing your build to fail in odd ways.
	      This frequently generates noise on the &os; mailing lists,
	      when one person complains that their build has failed, not
	      realizing that it is because they have tried to cut
	      corners.</para>
	  </answer>
	</qandaentry>

	<qandaentry>
	  <question>
	    <para>Can interrupted builds be resumed?</para>
	  </question>

	  <answer>
	    <para>This depends on how far through the process you got before
	      you found a problem.</para>

	    <para><emphasis>In general</emphasis> (and this is not a hard and
	      fast rule) the <command>make buildworld</command> process builds new
	      copies of essential tools (such as &man.gcc.1;, and
	      &man.make.1;) and the system libraries.  These tools and
	      libraries are then installed.  The new tools and libraries are
	      then used to rebuild themselves, and are installed again. The
	      entire system (now including regular user programs, such as
		&man.ls.1; or &man.grep.1;) is then rebuilt with the new
	      system files.</para>

	    <para>If you are at the last stage, and you know it (because you
	      have looked through the output that you were storing) then you
	      can (fairly safely) do:</para>

	    <screen><emphasis>&hellip; fix the problem &hellip;</emphasis>
&prompt.root; <userinput>cd /usr/src</userinput>
&prompt.root; <userinput>make -DNO_CLEAN all</userinput></screen>

	    <para>This will not undo the work of the previous
	      <command>make buildworld</command>.</para>

	    <para>If you see the message:</para>

	      <screen>--------------------------------------------------------------
Building everything..
--------------------------------------------------------------</screen>

	    <para>in the <command>make buildworld</command> output then it is
	      probably fairly safe to do so.</para>

	    <para>If you do not see that message, or you are not sure, then it
	      is always better to be safe than sorry, and restart the build
	      from scratch.</para>
	  </answer>
	</qandaentry>

	<qandaentry>
	  <question>
	    <para>How can I speed up making the world?</para>
          </question>

          <answer>
	    <itemizedlist>
	      <listitem>
		<para>Run in single user mode.</para>
	      </listitem>

	      <listitem>
		<para>Put the <filename>/usr/src</filename> and
		  <filename>/usr/obj</filename> directories on separate
		  file systems held on separate disks.  If possible, put these
		  disks on separate disk controllers.</para>
	      </listitem>

	      <listitem>
		<para>Better still, put these file systems across multiple
		  disks using the &man.ccd.4; (concatenated disk
		  driver) device.</para>
	      </listitem>

	      <listitem>
		<para>Turn off profiling (set <quote>NO_PROFILE=true</quote> in
		  <filename>/etc/make.conf</filename>).  You almost certainly
		  do not need it.</para>
	      </listitem>

	      <listitem>
		<para>Also in <filename>/etc/make.conf</filename>, set
		  <makevar>CFLAGS</makevar> to something like <option>-O
		  -pipe</option>.  The optimization <option>-O2</option> is much
		  slower, and the optimization difference between
		  <option>-O</option> and <option>-O2</option> is normally
		  negligible.  <option>-pipe</option> lets the compiler use
		  pipes rather than temporary files for communication, which
		  saves disk access (at the expense of memory).</para>
	      </listitem>

	      <listitem>
		<para>Pass the <option>-j<replaceable>n</replaceable></option> option to &man.make.1; to
		  run multiple processes in parallel.  This usually helps
		  regardless of whether you have a single or a multi processor
		  machine.</para>
	      </listitem>

	      <listitem><para>The file system holding
		  <filename>/usr/src</filename> can be mounted (or remounted)
		  with the <option>noatime</option> option.  This prevents the
		  file system from recording the file access time.  You probably
		  do not need this information anyway.</para>

		  <screen>&prompt.root; <userinput>mount -u -o noatime /usr/src</userinput></screen>

		  <warning>
		    <para>The example assumes <filename>/usr/src</filename> is
		      on its own file system.  If it is not (if it is a part of
		      <filename>/usr</filename> for example) then you will
		      need to use that file system mount point, and not
		      <filename>/usr/src</filename>.</para>
		  </warning>
	      </listitem>

	      <listitem>
		<para>The file system holding <filename>/usr/obj</filename> can
		  be mounted (or remounted) with the <option>async</option>
		  option.  This causes disk writes to happen asynchronously.
		  In other words, the write completes immediately, and the
		  data is written to the disk a few seconds later.  This
		  allows writes to be clustered together, and can be a
		  dramatic performance boost.</para>

		<warning>
		  <para>Keep in mind that this option makes your file system
		    more fragile.  With this option there is an increased
		    chance that, should power fail, the file system will be in
		    an unrecoverable state when the machine restarts.</para>

		  <para>If <filename>/usr/obj</filename> is the only thing on
		    this file system then it is not a problem.  If you have
		    other, valuable data on the same file system then ensure
		    your backups are fresh before you enable this
		    option.</para>
		</warning>

		<screen>&prompt.root; <userinput>mount -u -o async /usr/obj</userinput></screen>

		<warning>
		  <para>As above, if <filename>/usr/obj</filename> is not on
		    its own file system, replace it in the example with the
		    name of the appropriate mount point.</para>
		</warning>
	      </listitem>
	    </itemizedlist>
	  </answer>
	</qandaentry>

        <qandaentry>
          <question>
            <para>What do I do if something goes wrong?</para>
          </question>

          <answer>
            <para>Make absolutely sure your environment has no
              extraneous cruft from earlier builds.  This is simple
              enough.</para>

            <screen>&prompt.root; <userinput>chflags -R noschg /usr/obj/usr</userinput>
&prompt.root; <userinput>rm -rf /usr/obj/usr</userinput>
&prompt.root; <userinput>cd /usr/src</userinput>
&prompt.root; <userinput>make cleandir</userinput>
&prompt.root; <userinput>make cleandir</userinput></screen>

            <para>Yes, <command>make cleandir</command> really should
              be run twice.</para>

            <para>Then restart the whole process, starting
              with <command>make buildworld</command>.</para>

            <para>If you still have problems, send the error and the
              output of <command>uname -a</command> to &a.questions;.
              Be prepared to answer other questions about your
              setup!</para>
          </answer>
        </qandaentry>
      </qandaset>
    </sect2>
  </sect1>

  <sect1 id="small-lan">
    <sect1info>
      <authorgroup>
	<author>
	  <firstname>Mike</firstname>
	  <surname>Meyer</surname>
	  <contrib>Contributed by </contrib>
	</author>
      </authorgroup>
    </sect1info>
    <title>Tracking for Multiple Machines</title>
    <indexterm>
      <primary>NFS</primary>
      <secondary>installing multiple machines</secondary>
    </indexterm>

    <para>If you have multiple machines that you want to track the
      same source tree, then having all of them download sources and
      rebuild everything seems like a waste of resources: disk space,
      network bandwidth, and CPU cycles.  It is, and the solution is
      to have one machine do most of the work, while the rest of the
      machines mount that work via NFS.  This section outlines a
      method of doing so.</para>

    <sect2 id="small-lan-preliminaries">
      <title>Preliminaries</title>

      <para>First, identify a set of machines that is going to run
	the same set of binaries, which we will call a
	<emphasis>build set</emphasis>.  Each machine can have a
	custom kernel, but they will be running the same userland
	binaries.  From that set, choose a machine to be the
	<emphasis>build machine</emphasis>.  It is going to be the
	machine that the world and kernel are built on. Ideally, it
	should be a fast machine that has sufficient spare CPU to
	run <command>make buildworld</command> and
	<command>make buildkernel</command>.  You will also want to
	choose a machine to be the <emphasis>test
	machine</emphasis>, which will test software updates before they
	are put into production.  This <emphasis>must</emphasis> be a
	machine that you can afford to have down for an extended
	period of time.  It can be the build machine, but need not be.</para>

      <para>All the machines in this build set need to mount
	<filename>/usr/obj</filename> and
	<filename>/usr/src</filename> from the same machine, and at
	the same point.  Ideally, those are on two different drives
	on the build machine, but they can be NFS mounted on that machine
	as well.  If you have multiple build sets,
	<filename>/usr/src</filename> should be on one build machine, and
	NFS mounted on the rest.</para>

      <para>Finally make sure that
	<filename>/etc/make.conf</filename> on all the machines in
	the build set agrees with the build machine.  That means that
	the build machine must build all the parts of the base
	system that any machine in the build set is going to
	install.  Also, each build machine should have its kernel
	name set with <makevar>KERNCONF</makevar> in
	<filename>/etc/make.conf</filename>, and the build machine
	should list them all in <makevar>KERNCONF</makevar>, listing
	its own kernel first.  The build machine must have the kernel
	configuration files for each machine in
	<filename>/usr/src/sys/<replaceable>arch</replaceable>/conf</filename>
	if it is going to build their kernels.</para>
    </sect2>

    <sect2>
      <title>The Base System</title>

      <para>Now that all that is done, you are ready to build
	everything.  Build the kernel and world as described in <xref
	linkend="make-buildworld"/> on the build machine,
	but do not install anything.  After the build has finished, go
	to the test machine, and install the kernel you just
	built.  If this machine mounts <filename>/usr/src</filename>
	and <filename>/usr/obj</filename> via NFS, when you reboot
	to single user you will need to enable the network and mount
	them.  The easiest way to do this is to boot to multi-user,
	then run <command>shutdown now</command> to go to single user
	mode.  Once there, you can install the new kernel and world and run
	<command>mergemaster</command> just as you normally would.  When
	done, reboot to return to normal multi-user operations for this
	machine.</para>

      <para>After you are certain that everything on the test
	machine is working properly, use the same procedure to
	install the new software on each of the other machines in
	the build set.</para>
    </sect2>

    <sect2>
      <title>Ports</title>

      <para>The same ideas can be used for the ports tree.  The first
	critical step is mounting <filename>/usr/ports</filename> from
	the same machine to all the machines in the build set.  You can
	then set up <filename>/etc/make.conf</filename> properly to share
	distfiles.  You should set <makevar>DISTDIR</makevar> to a
	common shared directory that is writable by whichever user
	<username>root</username> is mapped to by your NFS mounts.  Each
	machine should set <makevar>WRKDIRPREFIX</makevar> to a
	local build directory.  Finally, if you are going to be
	building and distributing packages, you should set
	<makevar>PACKAGES</makevar> to a directory similar to
	<makevar>DISTDIR</makevar>.</para>
    </sect2>
  </sect1>
</chapter>