/[gentoo]/xml/htdocs/doc/en/gentoo-freebsd.xml
Gentoo

Contents of /xml/htdocs/doc/en/gentoo-freebsd.xml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.21 - (show annotations) (download) (as text)
Fri Oct 6 21:48:25 2006 UTC (7 years, 6 months ago) by nightmorph
Branch: MAIN
Changes since 1.20: +359 -109 lines
File MIME type: application/xml
updated gentoo-freebsd guide for bug 149766

1 <?xml version="1.0" encoding="UTF-8"?>
2 <!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/gentoo-freebsd.xml,v 1.20 2006/05/26 19:29:27 nightmorph Exp $ -->
3 <!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
4
5 <guide link="/doc/en/gentoo-freebsd.xml">
6 <title>A short guide to Gentoo/FreeBSD</title>
7
8 <author title="Author">
9 <mail link="ignacio.arquelatour@gmail.com">Ignacio Arque-Latour</mail>
10 </author>
11 <author title="Author">
12 <mail link="citizen428@gentoo.org">Michael Kohl</mail>
13 </author>
14 <author title="Author">
15 <mail link="angusyoung@gentoo.org">Otavio R. Piske</mail>
16 </author>
17 <author title="Author">
18 <mail link="ka0ttic@gentoo.org">Aaron Walker</mail>
19 </author>
20 <author title="Author">
21 <mail link="chriswhite@gentoo.org">Chris White</mail>
22 </author>
23
24 <abstract>
25 This document gives some general information on FreeBSD, as well as
26 installation instructions for Gentoo/FreeBSD. It also includes some reference
27 for people interested in helping out with development.
28 </abstract>
29
30 <!-- The content of this document is licensed under the CC-BY-SA license -->
31 <!-- See http://creativecommons.org/licenses/by-sa/2.5 -->
32 <license/>
33
34 <version>2.6</version>
35 <date>2006-10-06</date>
36
37 <chapter>
38 <title>Introduction to FreeBSD</title>
39 <section>
40 <title>What is FreeBSD?</title>
41 <body>
42
43 <p>
44 <uri link="http://www.freebsd.org/">FreeBSD</uri> is a free (<uri
45 link="http://www.freebsd.org/copyright/freebsd-license.html">license</uri>)
46 Unix-like operating system. Back in 1993 when development of <uri
47 link="http://www.386bsd.org/">386BSD</uri> stopped, two projects were born:
48 <uri link="http://www.netbsd.org/">NetBSD</uri>, commonly known to run on a
49 huge number of architectures, and FreeBSD which supports the x86, amd64, ia64,
50 sparc64 and alpha platforms.FreeBSD is renowned for its stability, performance
51 and security, thus being used from small to huge companies all over the world.
52 FreeBSD's current production release version is 6.1, which is also used as the
53 foundation for the Gentoo/FreeBSD project. The previous 5.x branch is being
54 continued by the FreeBSD project as a service release, but is no longer worked
55 on by the Gentoo/FreeBSD developers.
56 </p>
57
58 </body>
59 </section>
60 <section>
61 <title>What is Gentoo/FreeBSD?</title>
62 <body>
63
64 <p>
65 <uri link="/proj/en/gentoo-alt/bsd/fbsd/">Gentoo/FreeBSD</uri> is a subproject
66 of the <uri link="/proj/en/gentoo-alt/">Gentoo/Alt project</uri>, with the
67 goal of providing a fully-capable FreeBSD operating system featuring design
68 sensibilities taken from Gentoo Linux, such as the init system and the Portage
69 package management system.
70 </p>
71
72 </body>
73 </section>
74 <section>
75 <title>FreeBSD and Linux</title>
76 <body>
77
78 <p>
79 Users migrating from Linux to FreeBSD commonly consider the two operating
80 systems "almost the same". In fact, FreeBSD really shares a lot of similarities
81 with Linux distributions in general. Nevertheless, it has some key differences
82 that are worth noting:
83 </p>
84
85 <ul>
86 <li>
87 Contrary to Linux, which actually only refers to the kernel, FreeBSD is a
88 complete operating system, consisting of a C library, userland tools and
89 much more. This development approach makes the overall system very
90 consistent.
91 </li>
92 <li>
93 Contrary to the Linux kernel, FreeBSD development is not led by one person,
94 but instead managed by a small group of people called the <uri
95 link="http://www.freebsd.org/doc/en_US.ISO8859-1/articles/contributors/staff-core.html">Core
96 Team</uri>.
97 </li>
98 </ul>
99
100 <p>
101 Besides, FreeBSD also has some technical differences which set it apart
102 from Linux. Some of them are very important to know, even if you don't plan on
103 joining the Gentoo/FreeBSD development effort:
104 </p>
105
106 <ul>
107 <li>
108 To get run-time dynamic linking functions like <c>dlopen()</c>, programs do
109 not need to be linked against libdl like on GNU/Linux. Instead they are
110 linked against libc.
111 </li>
112 <li>
113 FreeBSD doesn't have an official tool for kernel compilation, thus you'll
114 have to resolve feature dependencies on your own.
115 </li>
116 <li>
117 FreeBSD uses UFS/UFS-2 as its filesystems and has no official support for
118 e.g. ReiserFS or XFS. However, there are projects for adding read-only
119 support for these filesystems. Accessing ext2/ext3 partitions is already
120 possible, but you cannot install your system on them.
121 </li>
122 </ul>
123
124 </body>
125 </section>
126 </chapter>
127
128 <chapter>
129 <title>Installing Gentoo/FreeBSD</title>
130 <section>
131 <title>Booting the CD</title>
132 <body>
133
134 <p>
135 After this short introduction, it's about time to finally install
136 Gentoo/FreeBSD. Unfortunately, we currently lack our own installation media, so
137 you have to choose between two alternative installation methods. The first
138 would be to use an existing FreeBSD installation to partition your hard drive
139 and use it as a base for installing Gentoo/FreeBSD. This guide will describe how
140 to use the <uri link="http://www.freesbie.org/">FreeSBIE LiveCD</uri> as
141 an installation medium for Gentoo/FreeBSD.
142 </p>
143
144 <note>
145 If you are intending to use FreeSBIE for installing Gentoo/FreeBSD, please make
146 sure to use a version based on FreeBSD 6.0! Experimental versions can be downloaded
147 from <uri link="http://torrent.freesbie.org/">FreeSBIE's Bittorrent tracker</uri> and
148 version 20060118 has been tested to work for the purposes described in this document.
149 </note>
150
151 <p>
152 First, boot the CD in order to begin the installation process. You'll be
153 presented with a login screen. The username is <c>freesbie</c>, and there is
154 no password. Next, run <c>sudo su</c> to become root, and optionally setup a
155 password. If you want to pass time during the installation process, you can run
156 <c>startx</c> to enter into an Xfce environment, suitable for web browsing,
157 AIM, and other things. Unlike Linux, FreeBSD bases the name of your interface
158 on the driver for the interface. For example, the Intel EtherExpress driver
159 (fxp) appears as fxp0 (driver fxp, first network card). To see what your
160 interface is, use <c>ifconfig</c>:
161 </p>
162
163 <pre caption="Finding out the network interface name using ifconfig">
164 # <i>ifconfig</i>
165 fxp0: flags=8843&lt;UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST&gt; mtu 1500
166 options=8&lt;VLAN_MTU&gt;
167 inet6 fe80::2d0::b7ff:febc:4fe3%fxp0 prefixlen 64 scopeid 0x1
168 inet 192.168.0.106 netmask 0xffffff00 broadcast 192.168.0.255
169 ether 00:d0:b7:bc:4f:e3
170 media: Ethernet autoselect (100baseTX &lt;full-duplex&gt;)
171 status: active
172 lo0: flags=8007&lt;LOOPBACK,MULTICAST&gt; mtu 16384
173 </pre>
174
175 <p>
176 If the original DHCP request during the CD bootup failed, you can use the
177 <c>dhclient</c> command to obtain an IP:
178 </p>
179
180 <pre caption="Obtaining a DHCP address using dhclient">
181 # <i>dhclient fxp0</i>
182 DHCPDISCOVER on fxp0 to 255.255.255.255 port 67 interval 9
183 DHCPOFFER from 192.168.0.1
184 DHCPREQUEST on fxp0 to 255.255.255.255 port 67
185 DHCPACK from 192.168.0.1
186 bound to 192.168.0.106 -- renewal in 302400 seconds
187 </pre>
188
189 <note>
190 The output presented here will differ based on your network.
191 </note>
192
193 <p>
194 Next, create the chroot for your installation:
195 </p>
196
197 <pre caption="Making the chroot directory">
198 # <i>mkdir /mnt/gentoo</i>
199 </pre>
200
201 <note>
202 There is a bug in the <uri
203 link="http://dev.gentoo.org/~flameeyes/minimal-freesbie-drizzt.iso.bz2">
204 minimal Freesbie CD</uri> that prevents the creation of the
205 <path>/mnt/gentoo</path> mount point. To avoid this, use <path>/mnt</path>
206 instead of <path>/mnt/gentoo</path> in the following sections.
207 </note>
208
209 </body>
210 </section>
211 <section>
212 <title>Partitioning the Drive</title>
213 <body>
214
215 <p>
216 Now that we have a mount point, it's time to partition the drive. This is done
217 with the <c>sysinstall</c> command:
218 </p>
219
220 <pre caption="Running the sysinstall command to fdisk the drive">
221 # <i>sysinstall diskPartitionEditor diskPartitionWrite</i>
222 </pre>
223
224 <p>
225 We recommend that you use the default layout. Press enter at the dialog, then
226 press <b>a</b> followed by <b>q</b> to accept the default layout. The next
227 screen will present you with the option of a bootloader. For this option,
228 choose "None" as we'll be installing the bootloader later on. Next comes the
229 actual partition sizing and mount points.
230 </p>
231
232 <p>
233 This next step also uses <c>sysinstall</c>, but with different arguments:
234 </p>
235
236 <pre caption="Running sysinstall to setup partition sizing and mount points">
237 # <i>sysinstall diskLabelEditor diskLabelCommit</i>
238 </pre>
239
240 <p>
241 Here, we'll refrain from using the automatic layout, and create one giant root
242 partition, followed by a swap partition. Hit <b>c</b> to create a new
243 partition. A dialog prompts you to enter a size. Go ahead and do so, using
244 MB/GB for setting different sizes, or C for cylinders. For root, choose FS as
245 the partition type, and set the mount point as <path>/mnt/gentoo</path>. <e>If
246 you do not adjust the mount point, it will overwrite the FreeSBIE
247 environment!</e>. As <path>/boot</path> is not a separate partition, you'll
248 need to disable soft-updates, or your system will not boot! To do so, use the
249 arrow keys to navigate to your newly created partition, then hit the <b>s</b>
250 key, until "Newfs" contains no <b>+S</b>. Now navigate the arrow keys until
251 the "Disk" line is highlighted, and hit <b>c</b> again to create a swap
252 partition. Generally, we recommend a swap space that is twice the size of your
253 RAM. Choose SWAP as the partition type, and don't worry about soft-updates, as
254 it does not apply to swap. Now we're finished, so hit <b>q</b> to finish the
255 process.
256 </p>
257
258 <p>
259 This will finalize the partitioning process, and format the drive in UFS for
260 FreeBSD to utilize. This will also mount the drive for you at the mount point
261 specified earlier (<path>/mnt/gentoo</path>). You can verify this worked by
262 running <c>mount</c>:
263 </p>
264
265 <pre caption="Verifying the new disk layout was mounted with mount">
266 # <i>mount</i>
267 ...
268 /dev/ad0s1d on /mnt/gentoo (ufs, local)
269 </pre>
270
271 <p>
272 Now that you have mounted the target partition, it is time to start on the Gentoo
273 setup.
274 </p>
275
276 </body>
277 </section>
278 <section>
279 <title>Gentoo Setup</title>
280 <body>
281
282 <p>
283 First, we need to download a stage3 tarball and unpack it into the chroot.
284 Point your browser to
285 <uri>http://gentoo.osuosl.org/experimental/x86/freebsd/stages/</uri>, grab the
286 latest snapshot, and unpack it into the mountpoint:
287 </p>
288
289 <pre caption="Obtaining and unpacking a stage3 tarball">
290 # <i>cd /mnt/gentoo/</i>
291 <comment>(Any other Gentoo mirror which includes the experimental/ directory will also work.)</comment>
292 # <i>wget http://gentoo.osuosl.org/experimental/x86/freebsd/stages/gentoo-freebsd-6.1-stage-20060802.tar.bz2</i>
293 # <i>tar -jxvpf gentoo-freebsd-6.1-stage-20060802.tar.bz2</i>
294 <comment>(You can delete the tarball with the following command if you want to.)</comment>
295 # <i>rm gentoo-freebsd-6.1-stage-20060802.tar.bz2</i>
296 </pre>
297
298 <p>
299 Before chrooting into the newly-extracted stage, you first must obtain an
300 up-to-date copy of the Gentoo/FreeBSD overlay. The easiest way to achieve this
301 is to to get our latest snapshot which you then extract to
302 <path>/mnt/gentoo/usr/local/portage</path>.
303 </p>
304
305 <pre caption="Getting the Gentoo/FreeBSD Portage overlay">
306 # <i>cd /mnt/gentoo/usr/local/portage</i>
307 # <i>wget http://gentoo.osuosl.org/experimental/snapshots/portage-alt-overlay-latest.tar.bz2</i>
308 # <i>tar -xjf portage-alt-overlay-latest.tar.bz2</i>
309 <comment>(You now can safely delete the snapshot with the following command.)</comment>
310 # <i>rm portage-alt-overlay-latest.tar.bz2</i>
311 </pre>
312
313 <p>
314 Alternatively, you can use Subversion to check out the current version of the
315 overlay. To do this, please refer to the <uri
316 link="/proj/en/gentoo-alt/contribute/index.xml?part=1&amp;chap=3">Gentoo/ALT
317 overlay documentation</uri>.
318 </p>
319
320 <p>
321 In order for your install to work, you need to mount the <path>/dev</path>
322 filesystem from the currently running system into the Gentoo/FreeBSD mount
323 point before proceeding with the chroot.
324 </p>
325
326 <pre caption="Mounting the /dev filesystem and chrooting">
327 # <i>mount -t devfs none /mnt/gentoo/dev/</i>
328 # <i>cp /etc/resolv.conf /mnt/gentoo/etc</i>
329 # <i>chroot /mnt/gentoo/ /bin/bash</i>
330 # <i>env-update &amp;&amp; source /etc/profile</i>
331 </pre>
332
333 <p>
334 After you got hold of the Gentoo/FreeBSD overlay, it's time to link
335 <path>/etc/make.profile</path> to the correct profile and add get your
336 <path>/etc/make.conf</path> ready for Gentoo/FreeBSD.
337 </p>
338
339 <p>
340 Now, you have to obtain a copy of the main Gentoo Portage tree, which depending
341 on your connection might take quite a while.
342 </p>
343
344 <pre caption="Obtaining the Portage tree">
345 # <i>emerge --sync</i>
346 <comment>(It's also possible to retrieve the Portage tree in another way:)</comment>
347 # <i>cd /</i>
348 # <i>wget http://gentoo.osuosl.org/snapshots/portage-latest.tar.bz2</i>
349 # <i>tar -xjf portage-latest.tar.bz2 -C /usr/</i>
350 # <i>emerge --metadata</i>
351 </pre>
352
353 <pre caption="Setting up the profile and editing /etc/make.conf">
354 # <i>ln -sf /usr/portage/profiles/default-bsd/fbsd/6.1/x86/ /etc/make.profile</i>
355 # <i>nano /etc/make.conf</i>
356 <comment>(Please make sure you add at least the following entries:)</comment>
357 CHOST="i686-gentoo-freebsd6.1"
358 ACCEPT_KEYWORDS="~x86-fbsd"
359 FEATURES="-sandbox collision-protect"
360 PORTDIR_OVERLAY="/usr/local/portage/portage-alt-overlay"
361 </pre>
362
363 <note>
364 Sandbox is disabled as it has not yet been ported to Gentoo/FreeBSD.
365 </note>
366
367 <note>
368 You can have a very limited system by using ~x86-fbsd keyword alone; you might
369 want to put ~x86 in your ACCEPT_KEYWORDS if you want access to more packages
370 but you might find broken dependencies and non-working packages; please rather
371 use package.keywords when testing packages and report working ones on <uri
372 link="http://bugs.gentoo.org">Bugzilla</uri> for the product Gentoo/Alt.
373 </note>
374
375 <p>
376 If you want, you can now rebuild the system's core packages.
377 </p>
378
379 <pre caption="Rebuilding the FreeBSD core packages (optional)">
380 # <i>emerge -e system</i>
381 </pre>
382
383 </body>
384 </section>
385 </chapter>
386 <chapter>
387 <title>Setting up for Booting</title>
388 <section>
389 <title>Kernel Installation</title>
390 <body>
391
392 <p>
393 If you ran <c>emerge -e system</c>, the sources for the FreeBSD kernel were
394 installed to <path>/usr/src/sys</path>. If you skipped this step, you can get
395 them in the following way:
396 </p>
397
398 <pre caption="Getting the FreeBSD kernel sources">
399 # <i>emerge freebsd-sources</i>
400 </pre>
401
402 <p>
403 Configuring and compiling a custom kernel is quite different from compiling
404 Linux, so if you are not familiar with the process we encourage you to have a
405 look at <uri
406 link="http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig.html">
407 chapter 8</uri> of the FreeBSD handbook. For now, you can do an installation of
408 the GENERIC kernel, which works on most systems. To begin, enter the source
409 directory for the kernel:
410 </p>
411
412 <impo>
413 Please note that currently only the "Traditional" way of building the kernel is
414 supported on Gentoo/FreeBSD!
415 </impo>
416
417 <pre caption="Entering the kernel source directory">
418 # <i>cd /usr/src/sys/</i>
419 </pre>
420
421 <p>
422 Looking over the layout, you'll see various architectures and subdirectories
423 for various parts of the kernel. To begin the installation, we head into the
424 <path>i386/conf/</path> directory:
425 </p>
426
427 <pre caption="The kernel configuration directory">
428 # <i>cd i386/conf/</i>
429 # <i>ls</i>
430 .cvsignore GENERIC Makefile PAE
431 DEFAULTS GENERIC.hints NOTES SMP
432 </pre>
433
434 <p>
435 The main files to note are <path>GENERIC</path> and <path>GENERIC.hints</path>.
436 As it will be needed by the installation of the kernel, go ahead and copy
437 <path>GENERIC.hints</path> file to <path>/boot/device.hints</path>:
438 </p>
439
440 <pre caption="Copying over the GENERIC.hints file">
441 # <i>cp GENERIC.hints /boot/device.hints</i>
442 </pre>
443
444 <p>
445 This file is used by the kernel drivers for basic configuration information
446 such as IRQ settings. Now it's time to configure the kernel. FreeBSD uses the
447 <c>config</c> command to do this. <c>config</c> uses the given file (in this
448 instance GENERIC) to copy over the required build files to a
449 <path>compile</path> directory in the parent directory. <path>GENERIC</path> is
450 similiar to the <path>.config</path> file for the Linux kernel. Run
451 <c>config</c> to produce the build directory:
452 </p>
453
454 <pre caption="Configuring the kernel build">
455 # <i>config GENERIC</i>
456 Kernel build directory is ../compile/GENERIC
457 Don't forget to ''make cleandepend; make depend''
458 </pre>
459
460 <p>
461 <c>config</c> has created a GENERIC build directory for us in the parent
462 directory. <c>cd</c> into it, then run the following to do a complete build:
463 </p>
464
465 <pre caption="Building and installing the kernel">
466 # <i>cd ../compile/GENERIC</i>
467 # <i>make cleandepend &amp;&amp; make depend &amp;&amp; make &amp;&amp; make install</i>
468 </pre>
469
470 <p>
471 This will give us a complete kernel to work with. Now we'll need to setup the
472 bootloader for the kernel to boot. The next chapter will discuss two methods of
473 setting up the bootloader: <c>grub</c> and <c>boot0</c>.
474 </p>
475
476 </body>
477 </section>
478 <section>
479 <title>Setting up the bootloader (grub)</title>
480 <body>
481
482 <p>
483 As of grub 0.97-r1, UFS slices are readable to <c>grub</c>. This lets us use
484 <c>grub</c> as a bootloader, the prefered method for those coming from a Linux
485 background. To begin, emerge <c>grub</c> and setup the label as bootable.
486 Remember to replace <c>adXsY</c> with the actual number and slice of your disk.
487 </p>
488
489 <pre caption="Emerge grub">
490 # <i>emerge grub</i>
491 # <i>disklabel -B adXsY</i>
492 </pre>
493
494 <p>
495 Now run <c>grub</c> to bring up the command prompt, and set up the partition as
496 shown:
497 </p>
498
499 <pre caption="Setting up grub">
500 <comment>(This is done to prevent disk error 29)</comment>
501 # <i>sysctl kern.geom.debugflags=16</i>
502 # <i>grub</i>
503 <comment>(Example using ad0s1d)</comment>
504 grub&gt; <i>root (hd0,0,d)</i>
505 Filesystem type is ufs2, partition type 0xa5
506
507 grub&gt; <i>setup (hd0)</i>
508 Checking if "/boot/grub/stage1" exists... yes
509 Checking if "/boot/grub/stage2" exists... yes
510 Checking if "/boot/grub/ufs2_stage1_5" exists... yes
511 Running "embed /boot/grub/ufs2_stage1_5 (hd0)"... 14 sectors are embedded.
512 succeeded
513 Running "install /boot/grub/stage1 (hd0) (hd0)1+14 p (hd0,0,d)/boot/grub/stage
514 2 /boot/grub/menu.lst"... succeeded
515 Done.
516
517 grub&gt; quit
518 </pre>
519
520 <p>
521 When you first boot, you may not receive a grub menu. If so, run this at the
522 prompt:
523 </p>
524
525 <pre caption="Booting the kernel with no menu">
526 grub&gt; <i>find /boot/grub/stage1</i>
527 <comment>(The output here is what you'll use in the next command)</comment>
528 (hd0,0,d)
529
530 grub&gt; <i>kernel (hd0,0,d)/boot/loader</i>
531 [FreeBSD-a.out, loadaddr=0x200000, text=0x1000, data=0x3a000, bss=0x0, entry=0x200000]
532
533 grub&gt; <i>boot</i>
534 </pre>
535
536 <p>
537 The next section will look at using the alternative bootloader, <c>boot0</c>.
538 </p>
539
540 </body>
541 </section>
542 <section>
543 <title>Setting up the bootloader (boot0)</title>
544 <body>
545
546 <impo>
547 <c>boot0</c> is the FreeBSD bootloader. Previously, it was the only supported
548 bootloader until <c>grub</c> was introduced into ports with UFS slice support.
549 To install and configure <c>boot0</c>, run the following. Remember to replace
550 <c>adXsY</c> with the actual number and slice of your disk.
551 </impo>
552
553 <pre caption="Installing and setting up boot0">
554 # <i>emerge boot0</i>
555 <comment>(Leave the chroot environment)</comment>
556 # <i>exit</i>
557 <comment>(Issued from outside the chroot)</comment>
558 # <i>fdisk -B -b /mnt/gentoo/boot/boot0 /dev/adX</i>
559 # <i>chroot /mnt/gentoo /bin/bash</i>
560 # <i>disklabel -B adXsY</i>
561 </pre>
562
563 <p>
564 If you need additional information on setting up <c>boot0</c>, please consult
565 <uri
566 link="http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/boot.html">chapter
567 12</uri> of the FreeBSD handbook. Now it's time to do some basic system
568 configuration and settings.
569 </p>
570
571 </body>
572 </section>
573 <section>
574 <title>System configuration</title>
575 <body>
576
577 <p>
578 First, we are going to setup the filesystem mounting points in
579 <path>/etc/fstab</path>.
580 </p>
581
582 <pre caption="Editing the filesystem in /etc/fstab">
583 # <i>nano /etc/fstab</i>
584 <comment>(This is an example, replace X and Y with the correct numbers for your hard disk.)</comment>
585 #Device Mountpoint Fstype Options Dump Pass
586 /dev/adXsYb none swap sw 0 0
587 /dev/adXsYa / ufs rw 1 1
588 /dev/adXsYe /usr/home ufs rw 2 2
589 /dev/adXsYd /tmp ufs rw 2 2
590 /dev/acdX /cdrom cd9660 ro,noauto 0 0
591 </pre>
592
593 <p>
594 Now would also be a good time to set up your network connection before the final
595 reboot. You can find all the information necessary to configure your network in
596 the <uri link="/doc/en/handbook/handbook-x86.xml?part=4&amp;chap=1">Gentoo
597 Handbook</uri>. To have your network interface activated at boot time, you have
598 to add it to the default runlevel:
599 </p>
600
601 <pre caption="Adding your network adapter to the default runlevel">
602 # <i>rc-update add net.fxp0 default</i>
603 </pre>
604
605 <p>
606 Your system's hostname can be changed in <path>/etc/conf.d/hostname</path>.
607 </p>
608
609 <pre caption="Setting up the machine's hostname">
610 # <i>nano /etc/conf.d/hostname</i>
611 <comment>(Set the HOSTNAME variable to your hostname)</comment>
612 HOSTNAME="tux"
613 </pre>
614
615 <p>
616 You should also configure your domain name, which is done in the
617 <path>/etc/conf.d/domainname</path> file:
618 </p>
619
620 <pre caption="Setting the domainname">
621 # <i>nano /etc/conf.d/domainname</i>
622 <comment>(Set the DNSDOMAIN variable to your domain name)</comment>
623 DNSDOMAIN="homenetwork"
624 </pre>
625
626 <p>
627 If you have a NIS domain, you need to define it in the
628 <path>/etc/conf.d/domainname</path> file:
629 </p>
630
631 <pre caption="Setting the NIS domainname">
632 # <i>nano /etc/conf.d/domainname</i>
633 <comment>(Set the NISDOMAIN variable to your NIS domain name)</comment>
634 NISDOMAIN="my-nisdomain"
635 </pre>
636
637 <p>
638 In case you need to use another keyboard layout for your language, you have to
639 set the correct value in <path>/etc/conf.d/syscons</path>. The following example
640 uses the Spanish layout, so you'll have to adjust it to your need if you want to
641 use another one.
642 </p>
643
644 <pre caption="Changing your keyboard layout (Optional)">
645 # <i>nano /etc/conf.d/syscons</i>
646 KEYMAP="spanish.iso.acc"
647 <comment>(Possible layouts can be found in /usr/share/syscons/keymaps).</comment>
648 </pre>
649
650 <p>
651 Now would be a good time to set a password for the <c>root</c> user and to add
652 another user account for your day-to-day work.
653 </p>
654
655 <pre caption="Changing the root password and adding a new user">
656 # <i>passwd</i>
657 # <i>adduser</i>
658 Username: <i>fred</i>
659 Full Name: <i>Fred Smith</i>
660 <comment>(Accepting the default here, just hit Enter.)</comment>
661 Uid (Leave empty for default):
662 <comment>(OK to accept the default here as well; hit Enter.)</comment>
663 Login group [fred]:
664 <comment>(Enter your groups here, space separated. They must exist.)</comment>
665 Login group is fred. Invite fred into other groups? []: wheel portage
666 <comment>(OK to accept the default here, hit Enter)</comment>
667 Login class [default]:
668 <comment>(Somewhat of a personal preference. Make sure the shell exists in /etc/shells)</comment>
669 Shell (sh bash tcsh csh esh ksh zsh sash nologin) [sh] <i>bash</i>
670 <comment>(OK to accept the default here, hit Enter for all these)</comment>
671 User password-based authentication [yes]
672 Use an empty password (yes/no) [no]:
673 Use a random password? (yes/no) [no]:
674 Enter password: <i>password goes here</i>
675 Enter password again: <i>retype it</i>
676 <comment>(OK to accept the default here, hit Enter)</comment>
677 Lock out the account after creation? [no]:
678 Username : fred
679 Password : *****
680 Full Name : Fred Smith
681 <comment>(This will vary)</comment>
682 Uid : 1002
683 Class :
684 Groups : fred wheel portage
685 Home : /home/fred
686 Shell : /bin/bash
687 Locked : no
688 <comment>(Confirm the information is correct)</comment>
689 OK? (yes/no): <i>yes</i>
690 adduser: INFO: Sucessfully added (fred) to the user database
691 Add another user? (yes/no): <i>no</i>
692 Goodbye!
693 #
694 </pre>
695
696 <p>
697 Congratulations, you have just finished your Gentoo/FreeBSD installation which
698 you can start exploring after the final reboot. Have fun!
699 </p>
700
701 <pre caption="Rebooting the system">
702 # <i>exit</i>
703 # <i>reboot</i>
704 </pre>
705
706 </body>
707 </section>
708 </chapter>
709
710 <chapter>
711 <title>Developing for Gentoo/FreeBSD</title>
712 <section>
713 <title>How to help</title>
714 <body>
715
716 <p>
717 There are many things you could help with, depending on your skill level and
718 spare time:
719 </p>
720
721 <ul>
722 <li>
723 Working on current ebuilds: this means working closely with ebuild
724 maintainers in order to create patches or modify ebuilds in a way that can
725 be accepted into the main tree.
726 </li>
727 <li>
728 Security: if you are into security, we need you! Although security
729 advisories from the FreeBSD project are tracked and fixed, we can always
730 use help in this area.
731 </li>
732 <li>
733 Contacts: we need people who can get in touch with FreeBSD developers to
734 maintain contacts between us and the original project to exchange patches
735 and discuss various problems and their solutions. Note that this should
736 never involve any kind of spamming of mailing lists or IRC channels.
737 </li>
738 <li>
739 Testing: the more people are actively using Gentoo/FreeBSD, the more bugs
740 will be discovered, which helps us improving the quality of the port. If
741 you are good at describing bugs or problems, we definitely want to hear
742 from you.
743 </li>
744 <li>
745 Other areas where we need help include: system ebuilds, baselayout,
746 creation of installation CDs, documentation, kernel hacking.
747 </li>
748 </ul>
749
750 </body>
751 </section>
752
753 <section>
754 <title>Known issues</title>
755 <body>
756
757 <p>
758 At the moment, there are still quite a lot of known issues. Here are the ones
759 really worth noting:
760 </p>
761
762 <ul>
763 <li>
764 Some init scripts depend on the clock service which we don't provide right
765 now. You can just remove it from the dependencies of the script and report
766 that on our <uri link="http://bugs.gentoo.org/">bugzilla</uri>. Please
767 remember to use the "Gentoo BSD" product for your submission.
768 </li>
769 <li>glib and gnome in general need a lot of fixes to be backported.</li>
770 <li>
771 The init system currently provided by Gentoo/FreeBSD's baselayout package is
772 not the same version used by Gentoo Linux and lacks some of its features. Work
773 on making newer versions working is underway.
774 </li>
775 </ul>
776
777 </body>
778 </section>
779 </chapter>
780
781 <chapter>
782 <title>Contact</title>
783 <section>
784 <body>
785
786 <p>
787 A list of Gentoo/FreeBSD developers can be found at the <uri
788 link="/proj/en/gentoo-alt/bsd/fbsd/">project page</uri>. Other ways to contact
789 Gentoo/FreeBSD developers include our IRC Channel <c>#gentoo-bsd</c> on
790 Freenode, as well as the <uri link="/main/en/lists.xml">gentoo-bsd mailing
791 list</uri>.
792 </p>
793
794 </body>
795 </section>
796 </chapter>
797 </guide>

  ViewVC Help
Powered by ViewVC 1.1.20