diff --git a/en_US.ISO8859-1/books/faq/book.xml b/en_US.ISO8859-1/books/faq/book.xml index 546decb6c6..11ebe38646 100644 --- a/en_US.ISO8859-1/books/faq/book.xml +++ b/en_US.ISO8859-1/books/faq/book.xml @@ -1,6431 +1,6431 @@ 13-CURRENT"> X"> head/"> X"> 12-STABLE"> stable/12/"> X"> 11-STABLE"> stable/11/"> ]> Frequently Asked Questions for &os; &rel2.relx; and &rel.relx; The &os; Documentation Project 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 The &os; Documentation Project &legalnotice; &tm-attrib.freebsd; &tm-attrib.adobe; &tm-attrib.ibm; &tm-attrib.ieee; &tm-attrib.intel; &tm-attrib.linux; &tm-attrib.microsoft; &tm-attrib.netbsd; &tm-attrib.opengroup; &tm-attrib.sgi; &tm-attrib.sun; &tm-attrib.general; $FreeBSD$ This is the Frequently Asked Questions (FAQ) for &os; versions &rel.relx; and &rel2.relx;. Every effort has been made to make this FAQ as informative as possible; if you have any suggestions as to how it may be improved, send them to the &a.doc;. The latest version of this document is always available from the &os; website. It may also be downloaded as one large HTML file with HTTP or as a variety of other formats from the &os; FTP server. Introduction What is &os;? &os; is a modern operating system for desktops, laptops, servers, and embedded systems with support for a large number of platforms. It is based on U.C. Berkeley's 4.4BSD-Lite release, with some 4.4BSD-Lite2 enhancements. It is also based indirectly on William Jolitz's port of U.C. Berkeley's Net/2 to the &i386;, known as 386BSD, though very little of the 386BSD code remains. &os; is used by companies, Internet Service Providers, researchers, computer professionals, students and home users all over the world in their work, education and recreation. For more detailed information on &os;, refer to the &os; Handbook. What is the goal of the &os; Project? The goal of the &os; Project is to provide a stable and fast general purpose operating system that may be used for any purpose without strings attached. Does the &os; license have any restrictions? Yes. Those restrictions do not control how the code is used, but how to treat the &os; Project itself. The license itself is available at license and can be summarized like this: Do not claim that you wrote this. Do not sue us if it breaks. Do not remove or modify the license. Many of us have a significant investment in the project and would certainly not mind a little financial compensation now and then, but we definitely do not insist on it. We believe that our first and foremost mission is to provide code to any and all comers, and for whatever purpose, so that the code gets the widest possible use and provides the widest possible benefit. This, we believe, is one of the most fundamental goals of Free Software and one that we enthusiastically support. Code in our source tree which falls under the GNU General Public License (GPL) or GNU Library General Public License (LGPL) comes with slightly more strings attached, though at least on the side of enforced access rather than the usual opposite. Due to the additional complexities that can evolve in the commercial use of GPL software, we do, however, endeavor to replace such software with submissions under the more relaxed &os; license whenever possible. Can &os; replace my current operating system? For most people, yes. But this question is not quite that cut-and-dried. Most people do not actually use an operating system. They use applications. The applications are what really use the operating system. &os; is designed to provide a robust and full-featured environment for applications. It supports a wide variety of web browsers, office suites, email readers, graphics programs, programming environments, network servers, and much more. Most of these applications can be managed through the Ports Collection. If an application is only available on one operating system, that operating system cannot just be replaced. Chances are, there is a very similar application on &os;, however. As a solid office or Internet server or a reliable workstation, &os; will almost certainly do everything you need. Many computer users across the world, including both novices and experienced &unix; administrators, use &os; as their only desktop operating system. Users migrating to &os; from another &unix;-like environment will find &os; to be similar. &windows; and &macos; users may be interested in instead using FuryBSD, + xlink:href="https://ghostbsd.org/">GhostBSD, GhostBSD - or MidnightBSD + or NomadBSD three &os;-based desktop distributions. Non-&unix; users should expect to invest some additional time learning the &unix; way of doing things. This FAQ and the &os; Handbook are excellent places to start. Why is it called &os;? It may be used free of charge, even by commercial users. Full source for the operating system is freely available, and the minimum possible restrictions have been placed upon its use, distribution and incorporation into other work (commercial or non-commercial). Anyone who has an improvement or bug fix is free to submit their code and have it added to the source tree (subject to one or two obvious provisions). It is worth pointing out that the word free is being used in two ways here: one meaning at no cost and the other meaning do whatever you like. Apart from one or two things you cannot do with the &os; code, for example pretending you wrote it, you can really do whatever you like with it. What are the differences between &os; and NetBSD, OpenBSD, and other open source BSD operating systems? James Howard wrote a good explanation of the history and differences between the various projects, called The BSD Family Tree which goes a fair way to answering this question. Some of the information is out of date, but the history portion in particular remains accurate. Most of the BSDs share patches and code, even today. All of the BSDs have common ancestry. The design goals of &os; are described in , above. The design goals of the other most popular BSDs may be summarized as follows: OpenBSD aims for operating system security above all else. The OpenBSD team wrote &man.ssh.1; and &man.pf.4;, which have both been ported to &os;. NetBSD aims to be easily ported to other hardware platforms. DragonFly BSD is a fork of &os; 4.8 that has since developed many interesting features of its own, including the HAMMER file system and support for user-mode vkernels. What is the latest version of &os;? At any point in the development of &os;, there can be multiple parallel branches. &rel.relx; releases are made from the &rel.stable; branch, and &rel2.relx; releases are made from the &rel2.stable; branch. Up until the release of 12.0, the &rel2.relx; series was the one known as -STABLE. However, as of &rel.head.relx;, the &rel2.relx; branch will be designated for an extended support status and receive only fixes for major problems, such as security-related fixes. Releases are made every few months. While many people stay more up-to-date with the &os; sources (see the questions on &os.current; and &os.stable;) than that, doing so is more of a commitment, as the sources are a moving target. More information on &os; releases can be found on the Release Engineering page and in &man.release.7;. What is &os;-CURRENT? &os.current; is the development version of the operating system, which will in due course become the new &os.stable; branch. As such, it is really only of interest to developers working on the system and die-hard hobbyists. See the relevant section in the Handbook for details on running -CURRENT. Users not familiar with &os; should not use &os.current;. This branch sometimes evolves quite quickly and due to mistake can be un-buildable at times. People that use &os.current; are expected to be able to analyze, debug, and report problems. What is the &os;-STABLE concept? &os;-STABLE is the development branch from which major releases are made. Changes go into this branch at a slower pace and with the general assumption that they have first been tested in &os;-CURRENT. However, at any given time, the sources for &os;-STABLE may or may not be suitable for general use, as it may uncover bugs and corner cases that were not yet found in &os;-CURRENT. Users who do not have the resources to perform testing should instead run the most recent release of &os;. &os;-CURRENT, on the other hand, has been one unbroken line since 2.0 was released. For more detailed information on branches see &os; Release Engineering: Creating the Release Branch, the status of the branches and the upcoming release schedule can be found on the Release Engineering Information page. Version &rel121.current; is the latest release from the &rel.stable; branch; it was released in &rel121.current.date;. Version &rel1.current; is the latest release from the &rel2.stable; branch; it was released in &rel1.current.date;. When are &os; releases made? The &a.re; releases a new major version of &os; about every 18 months and a new minor version about every 8 months, on average. Release dates are announced well in advance, so that the people working on the system know when their projects need to be finished and tested. A testing period precedes each release, to ensure that the addition of new features does not compromise the stability of the release. Many users regard this caution as one of the best things about &os;, even though waiting for all the latest goodies to reach -STABLE can be a little frustrating. More information on the release engineering process (including a schedule of upcoming releases) can be found on the release engineering pages on the &os; Web site. For people who need or want a little more excitement, binary snapshots are made weekly as discussed above. When are &os; snapshots made? &os; snapshot releases are made based on the current state of the -CURRENT and -STABLE branches. The goals behind each snapshot release are: To test the latest version of the installation software. To give people who would like to run -CURRENT or -STABLE but who do not have the time or bandwidth to follow it on a day-to-day basis an easy way of bootstrapping it onto their systems. To preserve a fixed reference point for the code in question, just in case we break something really badly later. (Although Subversion normally prevents anything horrible like this happening.) To ensure that all new features and fixes in need of testing have the greatest possible number of potential testers. No claims are made that any -CURRENT snapshot can be considered production quality for any purpose. If a stable and fully tested system is needed, stick to full releases. Snapshot releases are directly available from snapshot. Official snapshots are generated on a regular basis for all actively developed branches. Who is responsible for &os;? The key decisions concerning the &os; project, such as the overall direction of the project and who is allowed to add code to the source tree, are made by a core team of 9 people. There is a much larger team of more than 350 committers who are authorized to make changes directly to the &os; source tree. However, most non-trivial changes are discussed in advance in the mailing lists, and there are no restrictions on who may take part in the discussion. Where can I get &os;? Every significant release of &os; is available via anonymous FTP from the &os; FTP site: The latest &rel.stable; release, &rel121.current;-RELEASE can be found in the &rel121.current;-RELEASE directory. Snapshot releases are made monthly for the -CURRENT and -STABLE branch, these being of service purely to bleeding-edge testers and developers. The latest &rel2.stable; release, &rel1.current;-RELEASE can be found in the &rel1.current;-RELEASE directory. Information about obtaining &os; on CD, DVD, and other media can be found in the Handbook. How do I access the Problem Report database? The Problem Report database of all user change requests may be queried by using our web-based PR query interface. The web-based problem report submission interface can be used to submit problem reports through a web browser. Before submitting a problem report, read Writing &os; Problem Reports, an article on how to write good problem reports. Documentation and Support What good books are there about &os;? The project produces a wide range of documentation, available online from this link: https://www.FreeBSD.org/docs.html. Is the documentation available in other formats, such as plain text (ASCII), or PDF? Yes. The documentation is available in a number of different formats and compression schemes on the &os; FTP site, in the /ftp/doc/ directory. The documentation is categorized in a number of different ways. These include: The document's name, such as faq, or handbook. The document's language and encoding. These are based on the locale names found under /usr/share/locale on a &os; system. The current languages and encodings are as follows: Name Meaning en_US.ISO8859-1 English (United States) bn_BD.ISO10646-1 Bengali or Bangla (Bangladesh) da_DK.ISO8859-1 Danish (Denmark) de_DE.ISO8859-1 German (Germany) el_GR.ISO8859-7 Greek (Greece) es_ES.ISO8859-1 Spanish (Spain) fr_FR.ISO8859-1 French (France) hu_HU.ISO8859-2 Hungarian (Hungary) it_IT.ISO8859-15 Italian (Italy) ja_JP.eucJP Japanese (Japan, EUC encoding) ko_KR.UTF-8 Korean (Korea, UTF-8 encoding) mn_MN.UTF-8 Mongolian (Mongolia, UTF-8 encoding) nl_NL.ISO8859-1 Dutch (Netherlands) pl_PL.ISO8859-2 Polish (Poland) pt_BR.ISO8859-1 Portuguese (Brazil) ru_RU.KOI8-R Russian (Russia, KOI8-R encoding) tr_TR.ISO8859-9 Turkish (Turkey) zh_CN.UTF-8 Simplified Chinese (China, UTF-8 encoding) zh_TW.UTF-8 Traditional Chinese (Taiwan, UTF-8 encoding) Some documents may not be available in all languages. The document's format. We produce the documentation in a number of different output formats. Each format has its own advantages and disadvantages. Some formats are better suited for online reading, while others are meant to be aesthetically pleasing when printed on paper. Having the documentation available in any of these formats ensures that our readers will be able to read the parts they are interested in, either on their monitor, or on paper after printing the documents. The currently available formats are: Format Meaning html-split A collection of small, linked, HTML files. html One large HTML file containing the entire document pdf Adobe's Portable Document Format txt Plain text The compression and packaging scheme. Where the format is html-split, the files are bundled up using &man.tar.1;. The resulting .tar is then compressed using the compression schemes detailed in the next point. All the other formats generate one file. For example, article.pdf, book.html, and so on. These files are then compressed using either the zip or bz2 compression schemes. &man.tar.1; can be used to uncompress these files. So the PDF version of the Handbook, compressed using bzip2 will be stored in a file called book.pdf.bz2 in the handbook/ directory. After choosing the format and compression mechanism, download the compressed files, uncompress them, and then copy the appropriate documents into place. For example, the split HTML version of the FAQ, compressed using &man.bzip2.1;, can be found in doc/en_US.ISO8859-1/books/faq/book.html-split.tar.bz2 To download and uncompress that file, type: &prompt.root; fetch https://download.freebsd.org/ftp/doc/en_US.ISO8859-1/books/faq/book.html-split.tar.bz2 &prompt.root; tar xvf book.html-split.tar.bz2 If the file is compressed, tar will automatically detect the appropriate format and decompress it correctly, resulting in a collection of .html files. The main one is called index.html, which will contain the table of contents, introductory material, and links to the other parts of the document. Where do I find info on the &os; mailing lists? What &os; news groups are available? Refer to the Handbook entry on mailing-lists and the Handbook entry on newsgroups. Are there &os; IRC (Internet Relay Chat) channels? Yes, most major IRC networks host a &os; chat channel: Channel #FreeBSDhelp on EFNet is a channel dedicated to helping &os; users. Channel #FreeBSD on Freenode is a general help channel with many users at any time. The conversations have been known to run off-topic for a while, but priority is given to users with &os; questions. Other users can help with the basics, referring to the Handbook whenever possible and providing links for learning more about a particular topic. This is primarily an English speaking channel, though it does have users from all over the world. Non-native English speakers should try to ask the question in English first and then relocate to ##freebsd-lang as appropriate. Channel #FreeBSD on DALNET is available at irc.dal.net in the US and irc.eu.dal.net in Europe. Channel #FreeBSD on UNDERNET is available at us.undernet.org in the US and eu.undernet.org in Europe. Since it is a help channel, be prepared to read the documents you are referred to. Channel #FreeBSD on RUSNET is a Russian language channel dedicated to helping &os; users. This is also a good place for non-technical discussions. Channel #bsdchat on Freenode is a Traditional Chinese (UTF-8 encoding) language channel dedicated to helping &os; users. This is also a good place for non-technical discussions. The &os; wiki has a good list of IRC channels. Each of these channels are distinct and are not connected to each other. Since their chat styles differ, try each to find one suited to your chat style. Are there any web based forums to discuss &os;? The official &os; forums are located at https://forums.FreeBSD.org/. Where can I get commercial &os; training and support? iXsystems, Inc., parent company of the &os; Mall, provides commercial &os; and TrueOS software support, in addition to &os; development and tuning solutions. BSD Certification Group, Inc. provides system administration certifications for DragonFly BSD, &os;, NetBSD, and OpenBSD. Refer to their site for more information. Any other organizations providing training and support should contact the Project to be listed here. Installation Nik Clayton
nik@FreeBSD.org
Which platform should I download? I have a 64 bit capable &intel; CPU, but I only see amd64. &arch.amd64; is the term &os; uses for 64-bit compatible x86 architectures (also known as "x86-64" or "x64"). Most modern computers should use &arch.amd64;. Older hardware should use &arch.i386;. When installing on a non-x86-compatible architecture, select the platform which best matches the hardware. Which file do I download to get &os;? On the Getting &os; page, select [iso] next to the architecture that matches the hardware. Any of the following can be used: file description disc1.iso Contains enough to install &os; and a minimal set of packages. dvd1.iso Similar to disc1.iso but with additional packages. memstick.img A bootable image sufficient for writing to a USB stick. bootonly.iso A minimal image that requires network access during installation to completely install &os;. Full instructions on this procedure and a little bit more about installation issues in general can be found in the Handbook entry on installing &os;. What do I do if the install image does not boot? This can be caused by not downloading the image in binary mode when using FTP. Some FTP clients default their transfer mode to ascii and attempt to change any end-of-line characters received to match the conventions used by the client's system. This will almost invariably corrupt the boot image. Check the SHA-256 checksum of the downloaded boot image: if it is not exactly that on the server, then the download process is suspect. When using a command line FTP client, type binary at the FTP command prompt after getting connected to the server and before starting the download of the image. Where are the instructions for installing &os;? Installation instructions can be found at Handbook entry on installing &os;. How can I make my own custom release or install disk? Customized &os; installation media can be created by building a custom release. Follow the instructions in the Release Engineering article. Can &windows; co-exist with &os;? (x86-specific) If &windows; is installed first, then yes. &os;'s boot manager will then manage to boot &windows; and &os;. If &windows; is installed afterwards, it will overwrite the boot manager. If that happens, see the next section. Another operating system destroyed my Boot Manager. How do I get it back? (x86-specific) This depends upon the boot manager. The &os; boot selection menu can be reinstalled using &man.boot0cfg.8;. For example, to restore the boot menu onto the disk ada0: &prompt.root; boot0cfg -B ada0 The non-interactive MBR bootloader can be installed using &man.gpart.8;: &prompt.root; gpart bootcode -b /boot/mbr ada0 For more complex situations, including GPT disks, see &man.gpart.8;. Do I need to install the source? In general, no. There is nothing in the base system which requires the presence of the source to operate. Some ports, like sysutils/lsof, will not build unless the source is installed. In particular, if the port builds a kernel module or directly operates on kernel structures, the source must be installed. Do I need to build a kernel? Usually not. The supplied GENERIC kernel contains the drivers an ordinary computer will need. &man.freebsd-update.8;, the &os; binary upgrade tool, cannot upgrade custom kernels, another reason to stick with the GENERIC kernel when possible. For computers with very limited RAM, such as embedded systems, it may be worthwhile to build a smaller custom kernel containing just the required drivers. Should I use DES, Blowfish, or MD5 passwords and how do I specify which form my users receive? &os; uses SHA512 by default. DES passwords are still available for backwards compatibility with operating systems that still use the less secure password format. &os; also supports the Blowfish and MD5 password formats. Which password format to use for new passwords is controlled by the passwd_format login capability in /etc/login.conf, which takes values of des, blf (if these are available) or md5. See the &man.login.conf.5; manual page for more information about login capabilities. What are the limits for FFS file systems? For FFS file systems, the largest file system is practically limited by the amount of memory required to &man.fsck.8; the file system. &man.fsck.8; requires one bit per fragment, which with the default fragment size of 4 KB equates to 32 MB of memory per TB of disk. This does mean that on architectures which limit userland processes to 2 GB (e.g., &i386;), the maximum &man.fsck.8;'able filesystem is ~60 TB. If there was not a &man.fsck.8; memory limit the maximum filesystem size would be 2 ^ 64 (blocks) * 32 KB => 16 Exa * 32 KB => 512 ZettaBytes. The maximum size of a single FFS file is approximately 2 PB with the default block size of 32 KB. Each 32 KB block can point to 4096 blocks. With triple indirect blocks, the calculation is 32 KB * 12 + 32 KB * 4096 + 32 KB * 4096^2 + 32 KB * 4096^3. Increasing the block size to 64 KB will increase the max file size by a factor of 16. Why do I get an error message, readin failed after compiling and booting a new kernel? The world and kernel are out of sync. This is not supported. Be sure to use make buildworld and make buildkernel to update the kernel. Boot the system by specifying the kernel directly at the second stage, pressing any key when the | shows up before loader is started. Is there a tool to perform post-installation configuration tasks? Yes. bsdconfig provides a nice interface to configure &os; post-installation.
Hardware Compatibility General I want to get a piece of hardware for my &os; system. Which model/brand/type is best? This is discussed continually on the &os; mailing lists but is to be expected since hardware changes so quickly. Read through the Hardware Notes for &os; &rel121.current; or &rel1.current; and search the mailing list archives before asking about the latest and greatest hardware. Chances are a discussion about that type of hardware took place just last week. Before purchasing a laptop, check the archives for &a.questions;, or possibly a specific mailing list for a particular hardware type. What are the limits for memory? &os; as an operating system generally supports as much physical memory (RAM) as the platform it is running on does. Keep in mind that different platforms have different limits for memory; for example &i386; without PAE supports at most 4 GB of memory (and usually less than that because of PCI address space) and &i386; with PAE supports at most 64 GB memory. As of &os; 10, AMD64 platforms support up to 4 TB of physical memory. Why does &os; report less than 4 GB memory when installed on an &i386; machine? The total address space on &i386; machines is 32-bit, meaning that at most 4 GB of memory is addressable (can be accessed). Furthermore, some addresses in this range are reserved by hardware for different purposes, for example for using and controlling PCI devices, for accessing video memory, and so on. Therefore, the total amount of memory usable by the operating system for its kernel and applications is limited to significantly less than 4 GB. Usually, 3.2 GB to 3.7 GB is the maximum usable physical memory in this configuration. To access more than 3.2 GB to 3.7 GB of installed memory (meaning up to 4 GB but also more than 4 GB), a special tweak called PAE must be used. PAE stands for Physical Address Extension and is a way for 32-bit x86 CPUs to address more than 4 GB of memory. It remaps the memory that would otherwise be overlaid by address reservations for hardware devices above the 4 GB range and uses it as additional physical memory (see &man.pae.4;). Using PAE has some drawbacks; this mode of memory access is a little bit slower than the normal (without PAE) mode and loadable modules (see &man.kld.4;) are not supported. This means all drivers must be compiled into the kernel. The most common way to enable PAE is to build a new kernel with the special ready-provided kernel configuration file called PAE, which is already configured to build a safe kernel. Note that some entries in this kernel configuration file are too conservative and some drivers marked as unready to be used with PAE are actually usable. A rule of thumb is that if the driver is usable on 64-bit architectures (like AMD64), it is also usable with PAE. When creating a custom kernel configuration file, PAE can be enabled by adding the following line: options PAE PAE is not much used nowadays because most new x86 hardware also supports running in 64-bit mode, known as AMD64 or &intel; 64. It has a much larger address space and does not need such tweaks. &os; supports AMD64 and it is recommended that this version of &os; be used instead of the &i386; version if 4 GB or more memory is required. Architectures and Processors Does &os; support architectures other than the x86? Yes. &os; divides support into multiple tiers. Tier 1 architectures, such as i386 or amd64; are fully supported. Tiers 2 and 3 are supported on a best-effort basis. A full explanation of the tier system is available in the Committer's Guide. A complete list of supported architectures can be found on the platforms page. Does &os; support Symmetric Multiprocessing (SMP)? &os; supports symmetric multi-processor (SMP) on all non-embedded platforms (e.g, &arch.i386;, &arch.amd64;, etc.). SMP is also supported in arm and MIPS kernels, although some CPUs may not support this. &os;'s SMP implementation uses fine-grained locking, and performance scales nearly linearly with number of CPUs. &man.smp.4; has more details. What is microcode? How do I install &intel; CPU microcode updates? Microcode is a method of programmatically implementing hardware level instructions. This allows for CPU bugs to be fixed without replacing the on board chip. Install sysutils/devcpu-data, then add: microcode_update_enable="YES" to /etc/rc.conf Peripherals What kind of peripherals does &os; support? See the complete list in the Hardware Notes for &os; &rel121.current; or &rel1.current;. Keyboards and Mice Is it possible to use a mouse outside the X Window system? The default console driver, &man.vt.4;, provides the ability to use a mouse pointer in text consoles to cut & paste text. Run the mouse daemon, &man.moused.8;, and turn on the mouse pointer in the virtual console: &prompt.root; moused -p /dev/xxxx -t yyyy &prompt.root; vidcontrol -m on Where xxxx is the mouse device name and yyyy is a protocol type for the mouse. The mouse daemon can automatically determine the protocol type of most mice, except old serial mice. Specify the auto protocol to invoke automatic detection. If automatic detection does not work, see the &man.moused.8; manual page for a list of supported protocol types. For a PS/2 mouse, add moused_enable="YES" to /etc/rc.conf to start the mouse daemon at boot time. Additionally, to use the mouse daemon on all virtual terminals instead of just the console, add allscreens_flags="-m on" to /etc/rc.conf. When the mouse daemon is running, access to the mouse must be coordinated between the mouse daemon and other programs such as X Windows. Refer to the FAQ Why does my mouse not work with X? for more details on this issue. How do I cut and paste text with a mouse in the text console? It is not possible to remove data using the mouse. However, it is possible to copy and paste. Once the mouse daemon is running as described in the previous question, hold down button 1 (left button) and move the mouse to select a region of text. Then, press button 2 (middle button) to paste it at the text cursor. Pressing button 3 (right button) will extend the selected region of text. If the mouse does not have a middle button, it is possible to emulate one or remap buttons using mouse daemon options. See the &man.moused.8; manual page for details. My mouse has a fancy wheel and buttons. Can I use them in &os;? The answer is, unfortunately, It depends. These mice with additional features require specialized driver in most cases. Unless the mouse device driver or the user program has specific support for the mouse, it will act just like a standard two, or three button mouse. For the possible usage of wheels in the X Window environment, refer to that section. How do I use my delete key in sh and csh? For the Bourne Shell, add the following lines to ~/.shrc. See &man.sh.1; and &man.editrc.5;. bind ^[[3~ ed-delete-next-char # for xterm For the C Shell, add the following lines to ~/.cshrc. See &man.csh.1;. bindkey ^[[3~ delete-char # for xterm Other Hardware Workarounds for no sound from my &man.pcm.4; sound card? Some sound cards set their output volume to 0 at every boot. Run the following command every time the machine boots: &prompt.root; mixer pcm 100 vol 100 cd 100 Does &os; support power management on my laptop? &os; supports the ACPI features found in modern hardware. Further information can be found in &man.acpi.4;. Troubleshooting Why is &os; finding the wrong amount of memory on &i386; hardware? The most likely reason is the difference between physical memory addresses and virtual addresses. The convention for most PC hardware is to use the memory area between 3.5 GB and 4 GB for a special purpose (usually for PCI). This address space is used to access PCI hardware. As a result real, physical memory cannot be accessed by that address space. What happens to the memory that should appear in that location is hardware dependent. Unfortunately, some hardware does nothing and the ability to use that last 500 MB of RAM is entirely lost. Luckily, most hardware remaps the memory to a higher location so that it can still be used. However, this can cause some confusion when watching the boot messages. On a 32-bit version of &os;, the memory appears lost, since it will be remapped above 4 GB, which a 32-bit kernel is unable to access. In this case, the solution is to build a PAE enabled kernel. See the entry on memory limits for more information. On a 64-bit version of &os;, or when running a PAE-enabled kernel, &os; will correctly detect and remap the memory so it is usable. During boot, however, it may seem as if &os; is detecting more memory than the system really has, due to the described remapping. This is normal and the available memory will be corrected as the boot process completes. Why do my programs occasionally die with Signal 11 errors? Signal 11 errors are caused when a process has attempted to access memory which the operating system has not granted it access to. If something like this is happening at seemingly random intervals, start investigating the cause. These problems can usually be attributed to either: If the problem is occurring only in a specific custom application, it is probably a bug in the code. If it is a problem with part of the base &os; system, it may also be buggy code, but more often than not these problems are found and fixed long before us general FAQ readers get to use these bits of code (that is what -CURRENT is for). It is probably not a &os; bug if the problem occurs compiling a program, but the activity that the compiler is carrying out changes each time. For example, if make buildworld fails while trying to compile ls.c into ls.o and, when run again, it fails in the same place, this is a broken build. Try updating source and try again. If the compile fails elsewhere, it is almost certainly due to hardware. In the first case, use a debugger such as &man.gdb.1; to find the point in the program which is attempting to access a bogus address and fix it. In the second case, verify which piece of hardware is at fault. Common causes of this include: The hard disks might be overheating: Check that the fans are still working, as the disk and other hardware might be overheating. The processor running is overheating: This might be because the processor has been overclocked, or the fan on the processor might have died. In either case, ensure that the hardware is running at what it is specified to run at, at least while trying to solve this problem. If it is not, clock it back to the default settings.) Regarding overclocking, it is far cheaper to have a slow system than a fried system that needs replacing! Also the community is not sympathetic to problems on overclocked systems. Dodgy memory: if multiple memory SIMMS/DIMMS are installed, pull them all out and try running the machine with each SIMM or DIMM individually to narrow the problem down to either the problematic DIMM/SIMM or perhaps even a combination. Over-optimistic motherboard settings: the BIOS settings, and some motherboard jumpers, provide options to set various timings. The defaults are often sufficient, but sometimes setting the wait states on RAM too low, or setting the RAM Speed: Turbo option will cause strange behavior. A possible idea is to set to BIOS defaults, after noting the current settings first. Unclean or insufficient power to the motherboard. Remove any unused I/O boards, hard disks, or CD-ROMs, or disconnect the power cable from them, to see if the power supply can manage a smaller load. Or try another power supply, preferably one with a little more power. For instance, if the current power supply is rated at 250 Watts, try one rated at 300 Watts. Read the section on Signal 11 for a further explanation and a discussion on how memory testing software or hardware can still pass faulty memory. There is an extensive FAQ on this at the SIG11 problem FAQ. Finally, if none of this has helped, it is possibly a bug in &os;. Follow these instructions to send a problem report. My system crashes with either Fatal trap 12: page fault in kernel mode, or panic:, and spits out a bunch of information. What should I do? The &os; developers are interested in these errors, but need more information than just the error message. Copy the full crash message. Then consult the FAQ section on kernel panics, build a debugging kernel, and get a backtrace. This might sound difficult, but does not require any programming skills. Just follow the instructions. What is the meaning of the error maxproc limit exceeded by uid %i, please see tuning(7) and login.conf(5)? The &os; kernel will only allow a certain number of processes to exist at one time. The number is based on the kern.maxusers &man.sysctl.8; variable. kern.maxusers also affects various other in-kernel limits, such as network buffers. If the machine is heavily loaded, increase kern.maxusers. This will increase these other system limits in addition to the maximum number of processes. To adjust the kern.maxusers value, see the File/Process Limits section of the Handbook. While that section refers to open files, the same limits apply to processes. If the machine is lightly loaded but running a very large number of processes, adjust the kern.maxproc tunable by defining it in /boot/loader.conf. The tunable will not get adjusted until the system is rebooted. For more information about tuning tunables, see &man.loader.conf.5;. If these processes are being run by a single user, adjust kern.maxprocperuid to be one less than the new kern.maxproc value. It must be at least one less because one system program, &man.init.8;, must always be running. Why do full screen applications on remote machines misbehave? The remote machine may be setting the terminal type to something other than xterm which is required by the &os; console. Alternatively the kernel may have the wrong values for the width and height of the terminal. Check the value of the TERM environment variable is xterm. If the remote machine does not support that try vt100. Run stty -a to check what the kernel thinks the terminal dimensions are. If they are incorrect, they can be changed by running stty rows RR cols CC. Alternatively, if the client machine has x11/xterm installed, then running resize will query the terminal for the correct dimensions and set them. Why does it take so long to connect to my computer via ssh or telnet? The symptom: there is a long delay between the time the TCP connection is established and the time when the client software asks for a password (or, in &man.telnet.1;'s case, when a login prompt appears). The problem: more likely than not, the delay is caused by the server software trying to resolve the client's IP address into a hostname. Many servers, including the Telnet and SSH servers that come with &os;, do this to store the hostname in a log file for future reference by the administrator. The remedy: if the problem occurs whenever connecting the client computer to any server, the problem is with the client. If the problem only occurs when someone connects to the server computer, the problem is with the server. If the problem is with the client, the only remedy is to fix the DNS so the server can resolve it. If this is on a local network, consider it a server problem and keep reading. If this is on the Internet, contact your ISP. If the problem is with the server on a local network, configure the server to resolve address-to-hostname queries for the local address range. See &man.hosts.5; and &man.named.8; for more information. If this is on the Internet, the problem may be that the local server's resolver is not functioning correctly. To check, try to look up another host such as www.yahoo.com. If it does not work, that is the problem. Following a fresh install of &os;, it is also possible that domain and name server information is missing from /etc/resolv.conf. This will often cause a delay in SSH, as the option UseDNS is set to yes by default in /etc/ssh/sshd_config. If this is causing the problem, either fill in the missing information in /etc/resolv.conf or set UseDNS to no in sshd_config as a temporary workaround. Why does file: table is full show up repeatedly in &man.dmesg.8;? This error message indicates that the number of available file descriptors have been exhausted on the system. Refer to the kern.maxfiles section of the Tuning Kernel Limits section of the Handbook for a discussion and solution. Why does the clock on my computer keep incorrect time? The computer has two or more clocks, and &os; has chosen to use the wrong one. Run &man.dmesg.8;, and check for lines that contain Timecounter. The one with the highest quality value that &os; chose. &prompt.root; dmesg | grep Timecounter Timecounter "i8254" frequency 1193182 Hz quality 0 Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000 Timecounter "TSC" frequency 2998570050 Hz quality 800 Timecounters tick every 1.000 msec Confirm this by checking the kern.timecounter.hardware &man.sysctl.3;. &prompt.root; sysctl kern.timecounter.hardware kern.timecounter.hardware: ACPI-fast It may be a broken ACPI timer. The simplest solution is to disable the ACPI timer in /boot/loader.conf: debug.acpi.disabled="timer" Or the BIOS may modify the TSC clock—perhaps to change the speed of the processor when running from batteries, or going into a power saving mode, but &os; is unaware of these adjustments, and appears to gain or lose time. In this example, the i8254 clock is also available, and can be selected by writing its name to the kern.timecounter.hardware &man.sysctl.3;. &prompt.root; sysctl kern.timecounter.hardware=i8254 kern.timecounter.hardware: TSC -> i8254 The computer should now start keeping more accurate time. To have this change automatically run at boot time, add the following line to /etc/sysctl.conf: kern.timecounter.hardware=i8254 What does the error swap_pager: indefinite wait buffer: mean? This means that a process is trying to page memory from disk, and the page attempt has hung trying to access the disk for more than 20 seconds. It might be caused by bad blocks on the disk drive, disk wiring, cables, or any other disk I/O-related hardware. If the drive itself is bad, disk errors will appear in /var/log/messages and in the output of dmesg. Otherwise, check the cables and connections. What is a lock order reversal? The &os; kernel uses a number of resource locks to arbitrate contention for certain resources. When multiple kernel threads try to obtain multiple resource locks, there's always the potential for a deadlock, where two threads have each obtained one of the locks and blocks forever waiting for the other thread to release one of the other locks. This sort of locking problem can be avoided if all threads obtain the locks in the same order. A run-time lock diagnostic system called &man.witness.4;, enabled in &os.current; and disabled by default for stable branches and releases, detects the potential for deadlocks due to locking errors, including errors caused by obtaining multiple resource locks with a different order from different parts of the kernel. The &man.witness.4; framework tries to detect this problem as it happens, and reports it by printing a message to the system console about a lock order reversal (often referred to also as LOR). It is possible to get false positives, as &man.witness.4; is conservative. A true positive report does not mean that a system is dead-locked; instead it should be understood as a warning that a deadlock could have happened here. Problematic LORs tend to get fixed quickly, so check the &a.current; before posting to it. What does Called ... with the following non-sleepable locks held mean? This means that a function that may sleep was called while a mutex (or other unsleepable) lock was held. The reason this is an error is because mutexes are not intended to be held for long periods of time; they are supposed to only be held to maintain short periods of synchronization. This programming contract allows device drivers to use mutexes to synchronize with the rest of the kernel during interrupts. Interrupts (under &os;) may not sleep. Hence it is imperative that no subsystem in the kernel block for an extended period while holding a mutex. To catch such errors, assertions may be added to the kernel that interact with the &man.witness.4; subsystem to emit a warning or fatal error (depending on the system configuration) when a potentially blocking call is made while holding a mutex. In summary, such warnings are non-fatal, however with unfortunate timing they could cause undesirable effects ranging from a minor blip in the system's responsiveness to a complete system lockup. For additional information about locking in &os; see &man.locking.9;. Why does buildworld/installworld die with the message touch: not found? This error does not mean that the &man.touch.1; utility is missing. The error is instead probably due to the dates of the files being set sometime in the future. If the CMOS clock is set to local time, run adjkerntz -i to adjust the kernel clock when booting into single-user mode. User Applications Where are all the user applications? Refer to the ports page for info on software packages ported to &os;. Most ports should work on all supported versions of &os;. Those that do not are specifically marked as such. Each time a &os; release is made, a snapshot of the ports tree at the time of release is also included in the ports/ directory. &os; supports compressed binary packages to easily install and uninstall ports. Use &man.pkg.7; to control the installation of packages. How do I download the Ports tree? Should I be using Subversion? Any of the methods listed here work: Use portsnap for most use cases. Refer to Using the Ports Collection for instructions on how to use this tool. Use Subversion if custom patches to the ports tree are needed or if running &os.current;. Refer to Using Subversion for details. Why can I not build this port on my &rel2.relx; -, or &rel.relx; -STABLE machine? If the installed &os; version lags significantly behind -CURRENT or -STABLE, update the Ports Collection using the instructions in Using the Ports Collection. If the system is up-to-date, someone might have committed a change to the port which works for -CURRENT but which broke the port for -STABLE. Submit a bug report, since the Ports Collection is supposed to work for both the -CURRENT and -STABLE branches. I just tried to build INDEX using make index, and it failed. Why? First, make sure that the Ports Collection is up-to-date. Errors that affect building INDEX from an up-to-date copy of the Ports Collection are high-visibility and are thus almost always fixed immediately. There are rare cases where INDEX will not build due to odd cases involving OPTIONS_SET being set in make.conf. If you suspect that this is the case, try to make INDEX with those variables turned off before reporting it to &a.ports;. I updated the sources, now how do I update my installed ports? &os; does not include a port upgrading tool, but it does have some tools to make the upgrade process somewhat easier. Additional tools are available to simplify port handling and are described the Upgrading Ports section in the &os; Handbook. Do I need to recompile every port each time I perform a major version update? Yes! While a recent system will run with software compiled under an older release, things will randomly crash and fail to work once other ports are installed or updated. When the system is upgraded, various shared libraries, loadable modules, and other parts of the system will be replaced with newer versions. Applications linked against the older versions may fail to start or, in other cases, fail to function properly. For more information, see the section on upgrades in the &os; Handbook. Do I need to recompile every port each time I perform a minor version update? In general, no. &os; developers do their utmost to guarantee binary compatibility across all releases with the same major version number. Any exceptions will be documented in the Release Notes, and advice given there should be followed. Why is /bin/sh so minimal? Why does &os; not use bash or another shell? Many people need to write shell scripts which will be portable across many systems. That is why &posix; specifies the shell and utility commands in great detail. Most scripts are written in Bourne shell (&man.sh.1;), and because several important programming interfaces (&man.make.1;, &man.system.3;, &man.popen.3;, and analogues in higher-level scripting languages like Perl and Tcl) are specified to use the Bourne shell to interpret commands. Because the Bourne shell is so often and widely used, it is important for it to be quick to start, be deterministic in its behavior, and have a small memory footprint. The existing implementation is our best effort at meeting as many of these requirements simultaneously as we can. To keep /bin/sh small, we have not provided many of the convenience features that other shells have. That is why other more featureful shells like bash, scsh, &man.tcsh.1;, and zsh are available. Compare the memory utilization of these shells by looking at the VSZ and RSS columns in a ps -u listing. Kernel Configuration I would like to customize my kernel. Is it difficult? Not at all! Check out the kernel config section of the Handbook. The new kernel will be installed to the /boot/kernel directory along with its modules, while the old kernel and its modules will be moved to the /boot/kernel.old directory. If a mistake is made in the configuration, simply boot the previous version of the kernel. Why is my kernel so big? GENERIC kernels shipped with &os; are compiled in debug mode. Kernels built in debug mode contain debug data in separate files that are used for debugging. &os; releases prior to 11.0 store these debug files in the same directory as the kernel itself, /boot/kernel/. In &os; 11.0 and later the debug files are stored in /usr/lib/debug/boot/kernel/. Note that there will be little or no performance loss from running a debug kernel, and it is useful to keep one around in case of a system panic. When running low on disk space, there are different options to reduce the size of /boot/kernel/ and /usr/lib/debug/. To not install the symbol files, make sure the following line exists in /etc/src.conf: WITHOUT_KERNEL_SYMBOLS=yes For more information see &man.src.conf.5;. If you want to avoid building debug files altogether, make sure that both of the following are true: This line does not exist in the kernel configuration file: makeoptions DEBUG=-g Do not run &man.config.8; with . Either of the above settings will cause the kernel to be built in debug mode. To build and install only the specified modules, list them in /etc/make.conf: MODULES_OVERRIDE= accf_http ipfw Replace accf_httpd ipfw with a list of needed modules. Only the listed modules will be built. This reduces the size of the kernel directory and decreases the amount of time needed to build the kernel. For more information, read /usr/share/examples/etc/make.conf. Unneeded devices can be removed from the kernel to further reduce the size. See for more information. To put any of these options into effect, follow the instructions to build and install the new kernel. For reference, the &os; 11 &arch.amd64; kernel (/boot/kernel/kernel) is approximately 25 MB. Why does every kernel I try to build fail to compile, even GENERIC? There are a number of possible causes for this problem: The source tree is different from the one used to build the currently running system. When attempting an upgrade, read /usr/src/UPDATING, paying particular attention to the COMMON ITEMS section at the end. The make buildkernel did not complete successfully. The make buildkernel target relies on files generated by the make buildworld target to complete its job correctly. Even when building &os;-STABLE, it is possible that the source tree was fetched at a time when it was either being modified or it was broken. Only releases are guaranteed to be buildable, although &os;-STABLE builds fine the majority of the time. Try re-fetching the source tree and see if the problem goes away. Try using a different mirror in case the previous one is having problems. Which scheduler is in use on a running system? The name of the scheduler currently being used is directly available as the value of the kern.sched.name sysctl: &prompt.user; sysctl kern.sched.name kern.sched.name: ULE What is kern.sched.quantum? kern.sched.quantum is the maximum number of ticks a process can run without being preempted in the 4BSD scheduler. Disks, File Systems, and Boot Loaders How can I add my new hard disk to my &os; system? See the Adding Disks section in the &os; Handbook. How do I move my system over to my huge new disk? The best way is to reinstall the operating system on the new disk, then move the user data over. This is highly recommended when tracking -STABLE for more than one release or when updating a release instead of installing a new one. Install booteasy on both disks with &man.boot0cfg.8; and dual boot until you are happy with the new configuration. Skip the next paragraph to find out how to move the data after doing this. Alternatively, partition and label the new disk with either &man.sade.8; or &man.gpart.8;. If the disks are MBR-formatted, booteasy can be installed on both disks with &man.boot0cfg.8; so that the computer can dual boot to the old or new system after the copying is done. Once the new disk set up, the data cannot just be copied. Instead, use tools that understand device files and system flags, such as &man.dump.8;. Although it is recommended to move the data while in single-user mode, it is not required. When the disks are formatted with UFS, never use anything but &man.dump.8; and &man.restore.8; to move the root file system. These commands should also be used when moving a single partition to another empty partition. The sequence of steps to use dump to move the data from one UFS partitions to a new partition is: newfs the new partition. mount it on a temporary mount point. cd to that directory. dump the old partition, piping output to the new one. For example, to move /dev/ada1s1a with /mnt as the temporary mount point, type: &prompt.root; newfs /dev/ada1s1a &prompt.root; mount /dev/ada1s1a /mnt &prompt.root; cd /mnt &prompt.root; dump 0af - / | restore rf - Rearranging partitions with dump takes a bit more work. To merge a partition like /var into its parent, create the new partition large enough for both, move the parent partition as described above, then move the child partition into the empty directory that the first move created: &prompt.root; newfs /dev/ada1s1a &prompt.root; mount /dev/ada1s1a /mnt &prompt.root; cd /mnt &prompt.root; dump 0af - / | restore rf - &prompt.root; cd var &prompt.root; dump 0af - /var | restore rf - To split a directory from its parent, say putting /var on its own partition when it was not before, create both partitions, then mount the child partition on the appropriate directory in the temporary mount point, then move the old single partition: &prompt.root; newfs /dev/ada1s1a &prompt.root; newfs /dev/ada1s1d &prompt.root; mount /dev/ada1s1a /mnt &prompt.root; mkdir /mnt/var &prompt.root; mount /dev/ada1s1d /mnt/var &prompt.root; cd /mnt &prompt.root; dump 0af - / | restore rf - The &man.cpio.1; and &man.pax.1; utilities are also available for moving user data. These are known to lose file flag information, so use them with caution. Which partitions can safely use Soft Updates? I have heard that Soft Updates on / can cause problems. What about Journaled Soft Updates? Short answer: Soft Updates can usually be safely used on all partitions. Long answer: Soft Updates has two characteristics that may be undesirable on certain partitions. First, a Soft Updates partition has a small chance of losing data during a system crash. The partition will not be corrupted as the data will simply be lost. Second, Soft Updates can cause temporary space shortages. When using Soft Updates, the kernel can take up to thirty seconds to write changes to the physical disk. When a large file is deleted the file still resides on disk until the kernel actually performs the deletion. This can cause a very simple race condition. Suppose one large file is deleted and another large file is immediately created. The first large file is not yet actually removed from the physical disk, so the disk might not have enough room for the second large file. This will produce an error that the partition does not have enough space, even though a large chunk of space has just been released. A few seconds later, the file creation works as expected. If a system should crash after the kernel accepts a chunk of data for writing to disk, but before that data is actually written out, data could be lost. This risk is extremely small, but generally manageable. These issues affect all partitions using Soft Updates. So, what does this mean for the root partition? Vital information on the root partition changes very rarely. If the system crashed during the thirty-second window after such a change is made, it is possible that data could be lost. This risk is negligible for most applications, but be aware that it exists. If the system cannot tolerate this much risk, do not use Soft Updates on the root file system! / is traditionally one of the smallest partitions. If /tmp is on /, there may be intermittent space problems. Symlinking /tmp to /var/tmp will solve this problem. Finally, &man.dump.8; does not work in live mode (-L) on a filesystem, with Journaled Soft Updates (SU+J). Can I mount other foreign file systems under &os;? &os; supports a variety of other file systems. UFS UFS CD-ROMs can be mounted directly on &os;. Mounting disk partitions from Digital UNIX and other systems that support UFS may be more complex, depending on the details of the disk partitioning for the operating system in question. ext2/ext3 &os; supports ext2fs and ext3fs partitions. See &man.ext2fs.5; for more information. NTFS FUSE based NTFS support is available as a port (sysutils/fusefs-ntfs). For more information see ntfs-3g. FAT &os; includes a read-write FAT driver. For more information, see &man.mount.msdosfs.8;. ZFS &os; includes a port of &sun;'s ZFS driver. The current recommendation is to use it only on &arch.amd64; platforms with sufficient memory. For more information, see &man.zfs.8;. &os; includes the Network File System NFS and the &os; Ports Collection provides several FUSE applications to support many other file systems. How do I mount a secondary DOS partition? The secondary DOS partitions are found after all the primary partitions. For example, if E is the second DOS partition on the second SCSI drive, there will be a device file for slice 5 in /dev. To mount it: &prompt.root; mount -t msdosfs /dev/da1s5 /dos/e Is there a cryptographic file system for &os;? Yes, &man.gbde.8; and &man.geli.8;. See the Encrypting Disk Partitions section of the &os; Handbook. How do I boot &os; and &linux; using GRUB? To boot &os; using GRUB, add the following to either /boot/grub/menu.lst or /boot/grub/grub.conf, depending upon which is used by the &linux; distribution. title &os; 9.1 root (hd0,a) kernel /boot/loader Where hd0,a points to the root partition on the first disk. To specify the slice number, use something like this (hd0,2,a). By default, if the slice number is omitted, GRUB searches the first slice which has the a partition. How do I boot &os; and &linux; using BootEasy? Install LILO at the start of the &linux; boot partition instead of in the Master Boot Record. Then boot LILO from BootEasy. This is recommended when running &windows; and &linux; as it makes it simpler to get &linux; booting again if &windows; is reinstalled. How do I change the boot prompt from ??? to something more meaningful? This cannot be accomplished with the standard boot manager without rewriting it. There are a number of other boot managers in the sysutils category of the Ports Collection. How do I use a new removable drive? If the drive already has a file system on it, use a command like this: &prompt.root; mount -t msdosfs /dev/da0s1 /mnt If the drive will only be used with &os; systems, partition it with UFS or ZFS. This will provide long filename support, improvement in performance, and stability. If the drive will be used by other operating systems, a more portable choice, such as msdosfs, is better. &prompt.root; dd if=/dev/zero of=/dev/da0 count=2 &prompt.root; gpart create -s GPT /dev/da0 &prompt.root; gpart add -t freebsd-ufs /dev/da0 Finally, create a new file system: &prompt.root; newfs /dev/da0p1 and mount it: &prompt.root; mount /dev/da0s1 /mnt It is a good idea to add a line to /etc/fstab (see &man.fstab.5;) so you can just type mount /mnt in the future: /dev/da0p1 /mnt ufs rw,noauto 0 0 Why do I get Incorrect super block when mounting a CD? The type of device to mount must be specified. This is described in the Handbook section on Using Data CDs. Why do I get Device not configured when mounting a CD? This generally means that there is no CD in the drive, or the drive is not visible on the bus. Refer to the Using Data CDs section of the Handbook for a detailed discussion of this issue. Why do all non-English characters in filenames show up as ? on my CDs when mounted in &os;? The CD probably uses the Joliet extension for storing information about files and directories. This is discussed in the Handbook section on Using Data CD-ROMs. A CD burned under &os; cannot be read under any other operating system. Why? This means a raw file was burned to the CD, rather than creating an ISO 9660 file system. Take a look at the Handbook section on Using Data CDs. How can I create an image of a data CD? This is discussed in the Handbook section on Writing Data to an ISO File System. For more on working with CD-ROMs, see the Creating CDs Section in the Storage chapter in the Handbook. Why can I not mount an audio CD? Trying to mount an audio CD will produce an error like cd9660: /dev/cd0: Invalid argument. This is because mount only works on file systems. Audio CDs do not have file systems; they just have data. Instead, use a program that reads audio CDs, such as the audio/xmcd package or port. How do I mount a multi-session CD? By default, &man.mount.8; will attempt to mount the last data track (session) of a CD. To load an earlier session, use the command line argument. Refer to &man.mount.cd9660.8; for specific examples. How do I let ordinary users mount CD-ROMs, DVDs, USB drives, and other removable media? As root set the sysctl variable vfs.usermount to 1. &prompt.root; sysctl vfs.usermount=1 To make this persist across reboots, add the line vfs.usermount=1 to /etc/sysctl.conf so that it is reset at system boot time. Users can only mount devices they have read permissions to. To allow users to mount a device permissions must be set in /etc/devfs.conf. For example, to allow users to mount the first USB drive add: # Allow all users to mount a USB drive. own /dev/da0 root:operator perm /dev/da0 0666 All users can now mount devices they could read onto a directory that they own: &prompt.user; mkdir ~/my-mount-point &prompt.user; mount -t msdosfs /dev/da0 ~/my-mount-point Unmounting the device is simple: &prompt.user; umount ~/my-mount-point Enabling vfs.usermount, however, has negative security implications. A better way to access &ms-dos; formatted media is to use the emulators/mtools package in the Ports Collection. The device name used in the previous examples must be changed according to the configuration. The du and df commands show different amounts of disk space available. What is going on? This is due to how these commands actually work. du goes through the directory tree, measures how large each file is, and presents the totals. df just asks the file system how much space it has left. They seem to be the same thing, but a file without a directory entry will affect df but not du. When a program is using a file, and the file is deleted, the file is not really removed from the file system until the program stops using it. The file is immediately deleted from the directory listing, however. As an example, consider a file large enough to affect the output of du and df. A file being viewed with more can be deleted wihout causing an error. The entry is removed from the directory so no other program or user can access it. However, du shows that it is gone as it has walked the directory tree and the file is not listed. df shows that it is still there, as the file system knows that more is still using that space. Once the more session ends, du and df will agree. This situation is common on web servers. Many people set up a &os; web server and forget to rotate the log files. The access log fills up /var. The new administrator deletes the file, but the system still complains that the partition is full. Stopping and restarting the web server program would free the file, allowing the system to release the disk space. To prevent this from happening, set up &man.newsyslog.8;. Note that Soft Updates can delay the freeing of disk space and it can take up to 30 seconds for the change to be visible. How can I add more swap space? This section of the Handbook describes how to do this. Why does &os; see my disk as smaller than the manufacturer says it is? Disk manufacturers calculate gigabytes as a billion bytes each, whereas &os; calculates them as 1,073,741,824 bytes each. This explains why, for example, &os;'s boot messages will report a disk that supposedly has 80 GB as holding 76,319 MB. Also note that &os; will (by default) reserve 8% of the disk space. How is it possible for a partition to be more than 100% full? A portion of each UFS partition (8%, by default) is reserved for use by the operating system and the root user. &man.df.1; does not count that space when calculating the Capacity column, so it can exceed 100%. Notice that the Blocks column is always greater than the sum of the Used and Avail columns, usually by a factor of 8%. For more details, look up in &man.tunefs.8;. ZFS What is the minimum amount of RAM one should have to run ZFS? A minimum of 4GB of RAM is required for comfortable usage, but individual workloads can vary widely. What is the ZIL and when does it get used? The ZIL (ZFS intent log) is a write log used to implement posix write commitment semantics across crashes. Normally writes are bundled up into transaction groups and written to disk when filled (Transaction Group Commit). However syscalls like &man.fsync.2; require a commitment that the data is written to stable storage before returning. The ZIL is needed for writes that have been acknowledged as written but which are not yet on disk as part of a transaction. The transaction groups are timestamped. In the event of a crash the last valid timestamp is found and missing data is merged in from the ZIL. Do I need a SSD for ZIL? By default, ZFS stores the ZIL in the pool with all the data. If an application has a heavy write load, storing the ZIL in a separate device that has very fast synchronous, sequential write performance can improve overall system performance. For other workloads, a SSD is unlikely to make much of an improvement. What is the L2ARC? The L2ARC is a read cache stored on a fast device such as an SSD. This cache is not persistent across reboots. Note that RAM is used as the first layer of cache and the L2ARC is only needed if there is insufficient RAM. L2ARC needs space in the ARC to index it. So, perversely, a working set that fits perfectly in the ARC will not fit perfectly any more if a L2ARC is used because part of the ARC is holding the L2ARC index, pushing part of the working set into the L2ARC which is slower than RAM. Is enabling deduplication advisable? Generally speaking, no. Deduplication takes up a significant amount of RAM and may slow down read and write disk access times. Unless one is storing data that is very heavily duplicated, such as virtual machine images or user backups, it is possible that deduplication will do more harm than good. Another consideration is the inability to revert deduplication status. If data is written when deduplication is enabled, disabling dedup will not cause those blocks which were deduplicated to be replicated until they are next modified. Deduplication can also lead to some unexpected situations. In particular, deleting files may become much slower. I cannot delete or create files on my ZFS pool. How can I fix this? This could happen because the pool is 100% full. ZFS requires space on the disk to write transaction metadata. To restore the pool to a usable state, truncate the file to delete: &prompt.user; truncate -s 0 unimportant-file File truncation works because a new transaction is not started, new spare blocks are created instead. On systems with additional ZFS dataset tuning, such as deduplication, the space may not be immediately available Does ZFS support TRIM for Solid State Drives? ZFS TRIM support was added to &os; 10-CURRENT with revision r240868. ZFS TRIM support was added to all &os;-STABLE branches in r252162 and r251419, respectively. ZFS TRIM is enabled by default, and can be turned off by adding this line to /etc/sysctl.conf: vfs.zfs.trim.enabled=0 ZFS TRIM support was added to GELI as of r286444. Please see &man.geli.8; and the switch. System Administration Where are the system start-up configuration files? The primary configuration file is /etc/defaults/rc.conf which is described in &man.rc.conf.5;. System startup scripts such as /etc/rc and /etc/rc.d, which are described in &man.rc.8;, include this file. Do not edit this file! Instead, to edit an entry in /etc/defaults/rc.conf, copy the line into /etc/rc.conf and change it there. For example, if to start &man.named.8;, the included DNS server: &prompt.root; echo 'named_enable="YES"' >> /etc/rc.conf To start up local services, place shell scripts in the /usr/local/etc/rc.d directory. These shell scripts should be set executable, the default file mode is 555. How do I add a user easily? Use the &man.adduser.8; command, or the &man.pw.8; command for more complicated situations. To remove the user, use the &man.rmuser.8; command or, if necessary, &man.pw.8;. Why do I keep getting messages like root: not found after editing /etc/crontab? This is normally caused by editing the system crontab. This is not the correct way to do things as the system crontab has a different format to the per-user crontabs. The system crontab has an extra field, specifying which user to run the command as. &man.cron.8; assumes this user is the first word of the command to execute. Since no such command exists, this error message is displayed. To delete the extra, incorrect crontab: &prompt.root; crontab -r Why do I get the error, you are not in the correct group to su root when I try to su to root? This is a security feature. In order to su to root, or any other account with superuser privileges, the user account must be a member of the wheel group. If this feature were not there, anybody with an account on a system who also found out root's password would be able to gain superuser level access to the system. To allow someone to su to root, put them in the wheel group using pw: &prompt.root; pw groupmod wheel -m lisa The above example will add user lisa to the group wheel. I made a mistake in rc.conf, or another startup file, and now I cannot edit it because the file system is read-only. What should I do? Restart the system using boot -s at the loader prompt to enter single-user mode. When prompted for a shell pathname, press Enter and run mount -urw / to re-mount the root file system in read/write mode. You may also need to run mount -a -t ufs to mount the file system where your favorite editor is defined. If that editor is on a network file system, either configure the network manually before mounting the network file systems, or use an editor which resides on a local file system, such as &man.ed.1;. In order to use a full screen editor such as &man.vi.1; or &man.emacs.1;, run export TERM=xterm so that these editors can load the correct data from the &man.termcap.5; database. After performing these steps, edit /etc/rc.conf to fix the syntax error. The error message displayed immediately after the kernel boot messages should indicate the number of the line in the file which is at fault. Why am I having trouble setting up my printer? See the Handbook entry on printing for troubleshooting tips. How can I correct the keyboard mappings for my system? Refer to the Handbook section on using localization, specifically the section on console setup. Why can I not get user quotas to work properly? It is possible that the kernel is not configured to use quotas. In this case, add the following line to the kernel configuration file and recompile the kernel: options QUOTA Refer to the Handbook entry on quotas for full details. Do not turn on quotas on /. Put the quota file on the file system that the quotas are to be enforced on: File System Quota file /usr /usr/admin/quotas /home /home/admin/quotas Does &os; support System V IPC primitives? Yes, &os; supports System V-style IPC, including shared memory, messages and semaphores, in the GENERIC kernel. With a custom kernel, support may be loaded with the sysvshm.ko, sysvsem.ko and sysvmsg.ko kernel modules, or enabled in the custom kernel by adding the following lines to the kernel configuration file: options SYSVSHM # enable shared memory options SYSVSEM # enable for semaphores options SYSVMSG # enable for messaging Recompile and install the kernel. What other mail-server software can I use instead of Sendmail? The Sendmail server is the default mail-server software for &os;, but it can be replaced with another MTA installed from the Ports Collection. Available ports include mail/exim, mail/postfix, and mail/qmail. Search the mailing lists for discussions regarding the advantages and disadvantages of the available MTAs. I have forgotten the root password! What do I do? Do not panic! Restart the system, type boot -s at the Boot: prompt to enter single-user mode. At the question about the shell to use, hit Enter which will display a &prompt.root; prompt. Enter mount -urw / to remount the root file system read/write, then run mount -a to remount all the file systems. Run passwd root to change the root password then run &man.exit.1; to continue booting. If you are still prompted to give the root password when entering the single-user mode, it means that the console has been marked as insecure in /etc/ttys. In this case, it will be required to boot from a &os; installation disk, choose the Live CD or Shell at the beginning of the install process and issue the commands mentioned above. Mount the specific partition in this case and then chroot to it. For example, replace mount -urw / with mount /dev/ada0p1 /mnt; chroot /mnt for a system on ada0p1. If the root partition cannot be mounted from single-user mode, it is possible that the partitions are encrypted and it is impossible to mount them without the access keys. For more information see the section about encrypted disks in the &os; Handbook. How do I keep ControlAltDelete from rebooting the system? When using &man.vt.4;, the default console driver, this can be done by setting the following &man.sysctl.8;: &prompt.root; sysctl kern.vt.kbd_reboot=0 How do I reformat DOS text files to &unix; ones? Use this &man.perl.1; command: &prompt.user; perl -i.bak -npe 's/\r\n/\n/g' file(s) where file(s) is one or more files to process. The modification is done in-place, with the original file stored with a .bak extension. Alternatively, use &man.tr.1;: &prompt.user; tr -d '\r' < dos-text-file > unix-file dos-text-file is the file containing DOS text while unix-file will contain the converted output. This can be quite a bit faster than using perl. Yet another way to reformat DOS text files is to use the converters/dosunix port from the Ports Collection. Consult its documentation about the details. How do I re-read /etc/rc.conf and re-start /etc/rc without a reboot? Go into single-user mode and then back to multi-user mode: &prompt.root; shutdown now &prompt.root; return &prompt.root; exit I tried to update my system to the latest -STABLE, but got -BETAx, -RC or -PRERELEASE! What is going on? Short answer: it is just a name. RC stands for Release Candidate. It signifies that a release is imminent. In &os;, -PRERELEASE is typically synonymous with the code freeze before a release. (For some releases, the -BETA label was used in the same way as -PRERELEASE.) Long answer: &os; derives its releases from one of two places. Major, dot-zero, releases, such as 9.0-RELEASE are branched from the head of the development stream, commonly referred to as -CURRENT. Minor releases, such as 6.3-RELEASE or 5.2-RELEASE, have been snapshots of the active -STABLE branch. Starting with 4.3-RELEASE, each release also now has its own branch which can be tracked by people requiring an extremely conservative rate of development (typically only security advisories). When a release is about to be made, the branch from which it will be derived from has to undergo a certain process. Part of this process is a code freeze. When a code freeze is initiated, the name of the branch is changed to reflect that it is about to become a release. For example, if the branch used to be called 6.2-STABLE, its name will be changed to 6.3-PRERELEASE to signify the code freeze and signify that extra pre-release testing should be happening. Bug fixes can still be committed to be part of the release. When the source code is in shape for the release the name will be changed to 6.3-RC to signify that a release is about to be made from it. Once in the RC stage, only the most critical bugs found can be fixed. Once the release (6.3-RELEASE in this example) and release branch have been made, the branch will be renamed to 6.3-STABLE. For more information on version numbers and the various Subversion branches, refer to the Release Engineering article. I tried to install a new kernel, and the &man.chflags.1; failed. How do I get around this? Short answer: the security level is greater than 0. Reboot directly to single-user mode to install the kernel. Long answer: &os; disallows changing system flags at security levels greater than 0. To check the current security level: &prompt.root; sysctl kern.securelevel The security level cannot be lowered in multi-user mode, so boot to single-user mode to install the kernel, or change the security level in /etc/rc.conf then reboot. See the &man.init.8; manual page for details on securelevel, and see /etc/defaults/rc.conf and the &man.rc.conf.5; manual page for more information on rc.conf. I cannot change the time on my system by more than one second! How do I get around this? Short answer: the system is at a security level greater than 1. Reboot directly to single-user mode to change the date. Long answer: &os; disallows changing the time by more that one second at security levels greater than 1. To check the security level: &prompt.root; sysctl kern.securelevel The security level cannot be lowered in multi-user mode. Either boot to single-user mode to change the date or change the security level in /etc/rc.conf and reboot. See the &man.init.8; manual page for details on securelevel, and see /etc/defaults/rc.conf and the &man.rc.conf.5; manual page for more information on rc.conf. Why is rpc.statd using 256 MB of memory? No, there is no memory leak, and it is not using 256 MB of memory. For convenience, rpc.statd maps an obscene amount of memory into its address space. There is nothing terribly wrong with this from a technical standpoint; it just throws off things like &man.top.1; and &man.ps.1;. &man.rpc.statd.8; maps its status file (resident on /var) into its address space; to save worrying about remapping the status file later when it needs to grow, it maps the status file with a generous size. This is very evident from the source code, where one can see that the length argument to &man.mmap.2; is 0x10000000, or one sixteenth of the address space on an IA32, or exactly 256 MB. Why can I not unset the schg file flag? The system is running at securelevel greater than 0. Lower the securelevel and try again. For more information, see the FAQ entry on securelevel and the &man.init.8; manual page. What is vnlru? vnlru flushes and frees vnodes when the system hits the kern.maxvnodes limit. This kernel thread sits mostly idle, and only activates when there is a huge amount of RAM and users are accessing tens of thousands of tiny files. What do the various memory states displayed by top mean? Active: pages recently statistically used. Inactive: pages recently statistically unused. Laundry: pages recently statistically unused but known to be dirty, that is, whose contents needs to be paged out before they can be reused. Free: pages without data content, which can be immediately reused. Wired: pages that are fixed into memory, usually for kernel purposes, but also sometimes for special use in processes. Pages are most often written to disk (sort of a VM sync) when they are in the laundry state, but active or inactive pages can also be synced. This depends upon the CPU tracking of the modified bit being available, and in certain situations there can be an advantage for a block of VM pages to be synced, regardless of the queue they belong to. In most common cases, it is best to think of the laundry queue as a queue of relatively unused pages that might or might not be in the process of being written to disk. The inactive queue contains a mix of clean and dirty pages; clean pages near the head of the queue are reclaimed immediately to alleviate a free page shortage, and dirty pages are moved to the laundry queue for deferred processing. There are some other flags (e.g., busy flag or busy count) that might modify some of the described rules. How much free memory is available? There are a couple of kinds of free memory. The most common is the amount of memory immediately available without reclaiming memory already in use. That is the size of the free pages queue plus some other reserved pages. This amount is exported by the vm.stats.vm.v_free_count &man.sysctl.8;, shown, for instance, by &man.top.1;. Another kind of free memory is the total amount of virtual memory available to userland processes, which depends on the sum of swap space and usable memory. Other kinds of free memory descriptions are also possible, but it is relatively useless to define these, but rather it is important to make sure that the paging rate is kept low, and to avoid running out of swap space. What is /var/empty? /var/empty is a directory that the &man.sshd.8; program uses when performing privilege separation. The /var/empty directory is empty, owned by root and has the schg flag set. This directory should not be deleted. I just changed /etc/newsyslog.conf. How can I check if it does what I expect? To see what &man.newsyslog.8; will do, use the following: &prompt.user; newsyslog -nrvv My time is wrong, how can I change the timezone? Use &man.tzsetup.8;. The X Window System and Virtual Consoles What is the X Window System? The X Window System (commonly X11) is the most widely available windowing system capable of running on &unix; or &unix; like systems, including &os;. The X.Org Foundation administers the X protocol standards, with the current reference implementation, version 11 release &xorg.version;, so references are often shortened to X11. Many implementations are available for different architectures and operating systems. An implementation of the server-side code is properly known as an X server. I want to run &xorg;, how do I go about it? To install &xorg; do one of the following: Use the x11/xorg meta-port, which builds and installs every &xorg; component. Use x11/xorg-minimal, which builds and installs only the necessary &xorg; components. Install &xorg; from &os; packages: &prompt.root; pkg install xorg After the installation of &xorg;, follow the instructions from the X11 Configuration section of the &os; Handbook. I tried to run X, but I get a No devices detected. error when I type startx. What do I do now? The system is probably running at a raised securelevel. It is not possible to start X at a raised securelevel because X requires write access to &man.io.4;. For more information, see at the &man.init.8; manual page. There are two solutions to the problem: set the securelevel back down to zero or run &man.xdm.1; (or an alternative display manager) at boot time before the securelevel is raised. See for more information about running &man.xdm.1; at boot time. Why does my mouse not work with X? When using &man.vt.4;, the default console driver, &os; can be configured to support a mouse pointer on each virtual screen. To avoid conflicting with X, &man.vt.4; supports a virtual device called /dev/sysmouse. All mouse events received from the real mouse device are written to the &man.sysmouse.4; device via &man.moused.8;. To use the mouse on one or more virtual consoles, and use X, see and set up &man.moused.8;. Then edit /etc/X11/xorg.conf and make sure the following lines exist: Section "InputDevice" Option "Protocol" "SysMouse" Option "Device" "/dev/sysmouse" ..... Starting with &xorg; version 7.4, the InputDevice sections in xorg.conf are ignored in favor of autodetected devices. To restore the old behavior, add the following line to the ServerLayout or ServerFlags section: Option "AutoAddDevices" "false" Some people prefer to use /dev/mouse under X. To make this work, /dev/mouse should be linked to /dev/sysmouse (see &man.sysmouse.4;) by adding the following line to /etc/devfs.conf (see &man.devfs.conf.5;): link sysmouse mouse This link can be created by restarting &man.devfs.5; with the following command (as root): &prompt.root; service devfs restart My mouse has a fancy wheel. Can I use it in X? Yes, if X is configured for a 5 button mouse. To do this, add the lines Buttons 5 and ZAxisMapping 4 5 to the InputDevice section of /etc/X11/xorg.conf, as seen in this example: Section "InputDevice" Identifier "Mouse1" Driver "mouse" Option "Protocol" "auto" Option "Device" "/dev/sysmouse" Option "Buttons" "5" Option "ZAxisMapping" "4 5" EndSection The mouse can be enabled in Emacs by adding these lines to ~/.emacs: ;; wheel mouse (global-set-key [mouse-4] 'scroll-down) (global-set-key [mouse-5] 'scroll-up) My laptop has a Synaptics touchpad. Can I use it in X? Yes, after configuring a few things to make it work. In order to use the Xorg synaptics driver, first remove moused_enable from rc.conf. To enable synaptics, add the following line to /boot/loader.conf: hw.psm.synaptics_support="1" Add the following to /etc/X11/xorg.conf: Section "InputDevice" Identifier "Touchpad0" Driver "synaptics" Option "Protocol" "psm" Option "Device" "/dev/psm0" EndSection And be sure to add the following into the ServerLayout section: InputDevice "Touchpad0" "SendCoreEvents" How do I use remote X displays? For security reasons, the default setting is to not allow a machine to remotely open a window. To enable this feature, start X with the optional argument: &prompt.user; startx -listen_tcp What is a virtual console and how do I make more? Virtual consoles provide several simultaneous sessions on the same machine without doing anything complicated like setting up a network or running X. When the system starts, it will display a login prompt on the monitor after displaying all the boot messages. Type in your login name and password to start working on the first virtual console. To start another session, perhaps to look at documentation for a program or to read mail while waiting for an FTP transfer to finish, hold down Alt and press F2. This will display the login prompt for the second virtual console. To go back to the original session, press AltF1. The default &os; installation has eight virtual consoles enabled. AltF1, AltF2, AltF3, and so on will switch between these virtual consoles. To enable more of virtual consoles, edit /etc/ttys (see &man.ttys.5;) and add entries for ttyv8 to ttyvc, after the comment on Virtual terminals: # Edit the existing entry for ttyv8 in /etc/ttys and change # "off" to "on". ttyv8 "/usr/libexec/getty Pc" xterm on secure ttyv9 "/usr/libexec/getty Pc" xterm on secure ttyva "/usr/libexec/getty Pc" xterm on secure ttyvb "/usr/libexec/getty Pc" xterm on secure The more virtual terminals, the more resources that are used. This can be problematic on systems with 8 MB RAM or less. Consider changing secure to insecure. In order to run an X server, at least one virtual terminal must be left to off for it to use. This means that only eleven of the Alt-function keys can be used as virtual consoles so that one is left for the X server. For example, to run X and eleven virtual consoles, the setting for virtual terminal 12 should be: ttyvb "/usr/libexec/getty Pc" xterm off secure The easiest way to activate the virtual consoles is to reboot. How do I access the virtual consoles from X? Use CtrlAltFn to switch back to a virtual console. Press CtrlAltF1 to return to the first virtual console. Once at a text console, use AltFn to move between them. To return to the X session, switch to the virtual console running X. If X was started from the command line using startx, the X session will attach to the next unused virtual console, not the text console from which it was invoked. For eight active virtual terminals, X will run on the ninth, so use AltF9. How do I start XDM on boot? There are two schools of thought on how to start &man.xdm.1;. One school starts xdm from /etc/ttys (see &man.ttys.5;) using the supplied example, while the other runs xdm from rc.local (see &man.rc.8;) or from an X script in /usr/local/etc/rc.d. Both are equally valid, and one may work in situations where the other does not. In both cases the result is the same: X will pop up a graphical login prompt. The &man.ttys.5; method has the advantage of documenting which vty X will start on and passing the responsibility of restarting the X server on logout to &man.init.8;. The &man.rc.8; method makes it easy to kill xdm if there is a problem starting the X server. If loaded from &man.rc.8;, xdm should be started without any arguments. xdm must start after &man.getty.8; runs, or else getty and xdm will conflict, locking out the console. The best way around this is to have the script sleep 10 seconds or so then launch xdm. When starting xdm from /etc/ttys, there still is a chance of conflict between xdm and &man.getty.8;. One way to avoid this is to add the vt number in /usr/local/lib/X11/xdm/Xservers: :0 local /usr/local/bin/X vt4 The above example will direct the X server to run in /dev/ttyv3. Note the number is offset by one. The X server counts the vty from one, whereas the &os; kernel numbers the vty from zero. Why do I get Couldn't open console when I run xconsole? When X is started with startx, the permissions on /dev/console will not get changed, resulting in things like xterm -C and xconsole not working. This is because of the way console permissions are set by default. On a multi-user system, one does not necessarily want just any user to be able to write on the system console. For users who are logging directly onto a machine with a VTY, the &man.fbtab.5; file exists to solve such problems. In a nutshell, make sure an uncommented line of the form is in /etc/fbtab (see &man.fbtab.5;): /dev/ttyv0 0600 /dev/console It will ensure that whomever logs in on /dev/ttyv0 will own the console. Why does my PS/2 mouse misbehave under X? The mouse and the mouse driver may have become out of synchronization. In rare cases, the driver may also erroneously report synchronization errors: psmintr: out of sync (xxxx != yyyy) If this happens, disable the synchronization check code by setting the driver flags for the PS/2 mouse driver to 0x100. This can be easiest achieved by adding hint.psm.0.flags="0x100" to /boot/loader.conf and rebooting. How do I reverse the mouse buttons? Type xmodmap -e "pointer = 3 2 1". Add this command to ~/.xinitrc or ~/.xsession to make it happen automatically. How do I install a splash screen and where do I find them? The detailed answer for this question can be found in the Boot Time Splash Screens section of the &os; Handbook. Can I use the Windows keys on my keyboard in X? Yes. Use &man.xmodmap.1; to define which functions the keys should perform. Assuming all Windows keyboards are standard, the keycodes for these three keys are the following: 115Windows key, between the left-hand Ctrl and Alt keys 116Windows key, to the right of AltGr 117Menu, to the left of the right-hand Ctrl To have the left Windows key print a comma, try this. &prompt.root; xmodmap -e "keycode 115 = comma" To have the Windows key-mappings enabled automatically every time X is started, either put the xmodmap commands in ~/.xinitrc or, preferably, create a ~/.xmodmaprc and include the xmodmap options, one per line, then add the following line to ~/.xinitrc: xmodmap $HOME/.xmodmaprc For example, to map the 3 keys to be F13, F14, and F15, respectively. This would make it easy to map them to useful functions within applications or the window manager. To do this, put the following in ~/.xmodmaprc. keycode 115 = F13 keycode 116 = F14 keycode 117 = F15 For the x11-wm/fvwm2 desktop manager, one could map the keys so that F13 iconifies or de-iconifies the window the cursor is in, F14 brings the window the cursor is in to the front or, if it is already at the front, pushes it to the back, and F15 pops up the main Workplace menu even if the cursor is not on the desktop, which is useful when no part of the desktop is visible. The following entries in ~/.fvwmrc implement the aforementioned setup: Key F13 FTIWS A Iconify Key F14 FTIWS A RaiseLower Key F15 A A Menu Workplace Nop How can I get 3D hardware acceleration for &opengl;? The availability of 3D acceleration depends on the version of &xorg; and the type of video chip. For an nVidia chip, use the binary drivers provided for &os; by installing one of the following ports: The latest versions of nVidia cards are supported by the x11/nvidia-driver port. Older drivers are available as x11/nvidia-driver-### nVidia provides detailed information on which card is supported by which driver on their web site: http://www.nvidia.com/object/IO_32667.html. For Matrox G200/G400, check the x11-drivers/xf86-video-mga port. For ATI Rage 128 and Radeon see &man.ati.4x;, &man.r128.4x; and &man.radeon.4x;. Networking Where can I get information on diskless booting? Diskless booting means that the &os; box is booted over a network, and reads the necessary files from a server instead of its hard disk. For full details, see the Handbook entry on diskless booting. Can a &os; box be used as a dedicated network router? Yes. Refer to the Handbook entry on advanced networking, specifically the section on routing and gateways. Does &os; support NAT or Masquerading? Yes. For instructions on how to use NAT over a PPP connection, see the Handbook entry on PPP. To use NAT over some other sort of network connection, look at the natd section of the Handbook. How can I set up Ethernet aliases? If the alias is on the same subnet as an address already configured on the interface, add netmask 0xffffffff to this command: &prompt.root; ifconfig ed0 alias 192.0.2.2 netmask 0xffffffff Otherwise, specify the network address and netmask as usual: &prompt.root; ifconfig ed0 alias 172.16.141.5 netmask 0xffffff00 More information can be found in the &os; Handbook. Why can I not NFS-mount from a &linux; box? Some versions of the &linux; NFS code only accept mount requests from a privileged port; try to issue the following command: &prompt.root; mount -o -P linuxbox:/blah /mnt Why does mountd keep telling me it can't change attributes and that I have a bad exports list on my &os; NFS server? The most frequent problem is not understanding the correct format of /etc/exports. Review &man.exports.5; and the NFS entry in the Handbook, especially the section on configuring NFS. How do I enable IP multicast support? Install the net/mrouted package or port and add mrouted_enable="YES" to /etc/rc.conf start this service at boot time. Why do I have to use the FQDN for hosts on my site? See the answer in the &os; Handbook. Why do I get an error, Permission denied, for all networking operations? If the kernel is compiled with the IPFIREWALL option, be aware that the default policy is to deny all packets that are not explicitly allowed. If the firewall is unintentionally misconfigured, restore network operability by typing the following as root: &prompt.root; ipfw add 65534 allow all from any to any Consider setting firewall_type="open" in /etc/rc.conf. For further information on configuring this firewall, see the Handbook chapter. Why is my ipfw fwd rule to redirect a service to another machine not working? Possibly because network address translation (NAT) is needed instead of just forwarding packets. A fwd rule only forwards packets, it does not actually change the data inside the packet. Consider this rule: 01000 fwd 10.0.0.1 from any to foo 21 When a packet with a destination address of foo arrives at the machine with this rule, the packet is forwarded to 10.0.0.1, but it still has the destination address of foo. The destination address of the packet is not changed to 10.0.0.1. Most machines would probably drop a packet that they receive with a destination address that is not their own. Therefore, using a fwd rule does not often work the way the user expects. This behavior is a feature and not a bug. See the FAQ about redirecting services, the &man.natd.8; manual, or one of the several port redirecting utilities in the Ports Collection for a correct way to do this. How can I redirect service requests from one machine to another? FTP and other service requests can be redirected with the sysutils/socket package or port. Replace the entry for the service in /etc/inetd.conf to call socket, as seen in this example for ftpd: ftp stream tcp nowait nobody /usr/local/bin/socket socket ftp.example.com ftp where ftp.example.com and ftp are the host and port to redirect to, respectively. Where can I get a bandwidth management tool? There are three bandwidth management tools available for &os;. &man.dummynet.4; is integrated into &os; as part of &man.ipfw.4;. ALTQ has been integrated into &os; as part of &man.pf.4;. Bandwidth Manager from Emerging Technologies is a commercial product. Why do I get /dev/bpf0: device not configured? The running application requires the Berkeley Packet Filter (&man.bpf.4;), but it was removed from a custom kernel. Add this to the kernel config file and build a new kernel: device bpf # Berkeley Packet Filter How do I mount a disk from a &windows; machine that is on my network, like smbmount in &linux;? Use the SMBFS toolset. It includes a set of kernel modifications and a set of userland programs. The programs and information are available as &man.mount.smbfs.8; in the base system. What are these messages about: Limiting icmp/open port/closed port response in my log files? This kernel message indicates that some activity is provoking it to send a large amount of ICMP or TCP reset (RST) responses. ICMP responses are often generated as a result of attempted connections to unused UDP ports. TCP resets are generated as a result of attempted connections to unopened TCP ports. Among others, these are the kinds of activities which may cause these messages: Brute-force denial of service (DoS) attacks (as opposed to single-packet attacks which exploit a specific vulnerability). Port scans which attempt to connect to a large number of ports (as opposed to only trying a few well-known ports). The first number in the message indicates how many packets the kernel would have sent if the limit was not in place, and the second indicates the limit. This limit is controlled using net.inet.icmp.icmplim. This example sets the limit to 300 packets per second: &prompt.root; sysctl net.inet.icmp.icmplim=300 To disable these messages without disabling response limiting, use net.inet.icmp.icmplim_output to disable the output: &prompt.root; sysctl net.inet.icmp.icmplim_output=0 Finally, to disable response limiting completely, set net.inet.icmp.icmplim to 0. Disabling response limiting is discouraged for the reasons listed above. What are these arp: unknown hardware address format error messages? This means that some device on the local Ethernet is using a MAC address in a format that &os; does not recognize. This is probably caused by someone experimenting with an Ethernet card somewhere else on the network. This is most commonly seen on cable modem networks. It is harmless, and should not affect the performance of the &os; system. Why do I keep seeing messages like: 192.168.0.10 is on fxp1 but got reply from 00:15:17:67:cf:82 on rl0, and how do I disable it? Because a packet is coming from outside the network unexpectedly. To disable them, set net.link.ether.inet.log_arp_wrong_iface to 0. How do I compile an IPv6 only kernel? Configure your kernel with these settings: include GENERIC ident GENERIC-IPV6ONLY makeoptions MKMODULESENV+="WITHOUT_INET_SUPPORT=" nooptions INET nodevice gre Security What is a sandbox? Sandbox is a security term. It can mean two things: A process which is placed inside a set of virtual walls that are designed to prevent someone who breaks into the process from being able to break into the wider system. The process is only able to run inside the walls. Since nothing the process does in regards to executing code is supposed to be able to breach the walls, a detailed audit of its code is not needed in order to be able to say certain things about its security. The walls might be a user ID, for example. This is the definition used in the &man.security.7; and &man.named.8; man pages. Take the ntalk service, for example (see &man.inetd.8;). This service used to run as user ID root. Now it runs as user ID tty. The tty user is a sandbox designed to make it more difficult for someone who has successfully hacked into the system via ntalk from being able to hack beyond that user ID. A process which is placed inside a simulation of the machine. It means that someone who is able to break into the process may believe that he can break into the wider machine but is, in fact, only breaking into a simulation of that machine and not modifying any real data. The most common way to accomplish this is to build a simulated environment in a subdirectory and then run the processes in that directory chrooted so that / for that process is this directory, not the real / of the system). Another common use is to mount an underlying file system read-only and then create a file system layer on top of it that gives a process a seemingly writeable view into that file system. The process may believe it is able to write to those files, but only the process sees the effects — other processes in the system do not, necessarily. An attempt is made to make this sort of sandbox so transparent that the user (or hacker) does not realize that he is sitting in it. &unix; implements two core sandboxes. One is at the process level, and one is at the userid level. Every &unix; process is completely firewalled off from every other &unix; process. One process cannot modify the address space of another. A &unix; process is owned by a particular userid. If the user ID is not the root user, it serves to firewall the process off from processes owned by other users. The user ID is also used to firewall off on-disk data. What is securelevel? securelevel is a security mechanism implemented in the kernel. When the securelevel is positive, the kernel restricts certain tasks; not even the superuser (root) is allowed to do them. The securelevel mechanism limits the ability to: Unset certain file flags, such as schg (the system immutable flag). Write to kernel memory via /dev/mem and /dev/kmem. Load kernel modules. Alter firewall rules. To check the status of the securelevel on a running system: &prompt.root; sysctl -n kern.securelevel The output contains the current value of the securelevel. If it is greater than 0, at least some of the securelevel's protections are enabled. The securelevel of a running system cannot be lowered as this would defeat its purpose. If a task requires that the securelevel be non-positive, change the kern_securelevel and kern_securelevel_enable variables in /etc/rc.conf and reboot. For more information on securelevel and the specific things all the levels do, consult &man.init.8;. Securelevel is not a silver bullet; it has many known deficiencies. More often than not, it provides a false sense of security. One of its biggest problems is that in order for it to be at all effective, all files used in the boot process up until the securelevel is set must be protected. If an attacker can get the system to execute their code prior to the securelevel being set (which happens quite late in the boot process since some things the system must do at start-up cannot be done at an elevated securelevel), its protections are invalidated. While this task of protecting all files used in the boot process is not technically impossible, if it is achieved, system maintenance will become a nightmare since one would have to take the system down, at least to single-user mode, to modify a configuration file. This point and others are often discussed on the mailing lists, particularly the &a.security;. Search the archives here for an extensive discussion. A more fine-grained mechanism is preferred. What is this UID 0 toor account? Have I been compromised? Do not worry. toor is an alternative superuser account, where toor is root spelled backwards. It is intended to be used with a non-standard shell so the default shell for root does not need to change. This is important as shells which are not part of the base distribution, but are instead installed from ports or packages, are installed in /usr/local/bin which, by default, resides on a different file system. If root's shell is located in /usr/local/bin and the file system containing /usr/local/bin) is not mounted, root will not be able to log in to fix a problem and will have to reboot into single-user mode in order to enter the path to a shell. Some people use toor for day-to-day root tasks with a non-standard shell, leaving root, with a standard shell, for single-user mode or emergencies. By default, a user cannot log in using toor as it does not have a password, so log in as root and set a password for toor before using it to login. Serial Communications This section answers common questions about serial communications with &os;. How do I get the boot: prompt to show on the serial console? See this section of the Handbook. How do I tell if &os; found my serial ports or modem cards? As the &os; kernel boots, it will probe for the serial ports for which the kernel is configured. Either watch the boot messages closely or run this command after the system is up and running: &prompt.user; grep -E '^(sio|uart)[0-9]' < /var/run/dmesg.boot sio0: <16550A-compatible COM port> port 0x3f8-0x3ff irq 4 flags 0x10 on acpi0 sio0: type 16550A sio1: <16550A-compatible COM port> port 0x2f8-0x2ff irq 3 on acpi0 sio1: type 16550A This example shows two serial ports. The first is on IRQ4, port address 0x3f8, and has a 16550A-type UART chip. The second uses the same kind of chip but is on IRQ3 and is at port address 0x2f8. Internal modem cards are treated just like serial ports, except that they always have a modem attached to the port. The GENERIC kernel includes support for two serial ports using the same IRQ and port address settings in the above example. If these settings are not right for the system, or if there are more modem cards or serial ports than the kernel is configured for, reconfigure using the instructions in building a kernel for more details. How do I access the serial ports on &os;? (x86-specific) The third serial port, sio2, or COM3, is on /dev/cuad2 for dial-out devices, and on /dev/ttyd2 for dial-in devices. What is the difference between these two classes of devices? When opening /dev/ttydX in blocking mode, a process will wait for the corresponding cuadX device to become inactive, and then wait for the carrier detect line to go active. When the cuadX device is opened, it makes sure the serial port is not already in use by the ttydX device. If the port is available, it steals it from the ttydX device. Also, the cuadX device does not care about carrier detect. With this scheme and an auto-answer modem, remote users can log in and local users can still dial out with the same modem and the system will take care of all the conflicts. How do I enable support for a multi-port serial card? The section on kernel configuration provides information about configuring the kernel. For a multi-port serial card, place an &man.sio.4; line for each serial port on the card in the &man.device.hints.5; file. But place the IRQ specifiers on only one of the entries. All of the ports on the card should share one IRQ. For consistency, use the last serial port to specify the IRQ. Also, specify the following option in the kernel configuration file: options COM_MULTIPORT The following /boot/device.hints example is for an AST 4-port serial card on IRQ 12: hint.sio.4.at="isa" hint.sio.4.port="0x2a0" hint.sio.4.flags="0x701" hint.sio.5.at="isa" hint.sio.5.port="0x2a8" hint.sio.5.flags="0x701" hint.sio.6.at="isa" hint.sio.6.port="0x2b0" hint.sio.6.flags="0x701" hint.sio.7.at="isa" hint.sio.7.port="0x2b8" hint.sio.7.flags="0x701" hint.sio.7.irq="12" The flags indicate that the master port has minor number 7 (0x700), and all the ports share an IRQ (0x001). Can I set the default serial parameters for a port? See the Serial Communications section in the &os; Handbook. Why can I not run tip or cu? The built-in &man.tip.1; and &man.cu.1; utilities can only access the /var/spool/lock directory via user uucp and group dialer. Use the dialer group to control who has access to the modem or remote systems by adding user accounts to dialer. Alternatively, everyone can be configured to run &man.tip.1; and &man.cu.1; by typing: &prompt.root; chmod 4511 /usr/bin/cu &prompt.root; chmod 4511 /usr/bin/tip Miscellaneous Questions &os; uses a lot of swap space even when the computer has free memory left. Why? &os; will proactively move entirely idle, unused pages of main memory into swap in order to make more main memory available for active use. This heavy use of swap is balanced by using the extra free memory for caching. Note that while &os; is proactive in this regard, it does not arbitrarily decide to swap pages when the system is truly idle. Thus, the system will not be all paged out after leaving it idle overnight. Why does top show very little free memory even when I have very few programs running? The simple answer is that free memory is wasted memory. Any memory that programs do not actively allocate is used within the &os; kernel as disk cache. The values shown by &man.top.1; labeled as Inact and Laundry are cached data at different aging levels. This cached data means the system does not have to access a slow disk again for data it has accessed recently, thus increasing overall performance. In general, a low value shown for Free memory in &man.top.1; is good, provided it is not very low. Why will chmod not change the permissions on symlinks? Symlinks do not have permissions, and by default, &man.chmod.1; will follow symlinks to change the permissions on the source file, if possible. For the file, foo with a symlink named bar, this command will always succeed. &prompt.user; chmod g-w bar However, the permissions on bar will not have changed. When changing modes of the file hierarchies rooted in the files instead of the files themselves, use either or together with to make this work. See &man.chmod.1; and &man.symlink.7; for more information. does a recursive &man.chmod.1;. Be careful about specifying directories or symlinks to directories to &man.chmod.1;. To change the permissions of a directory referenced by a symlink, use &man.chmod.1; without any options and follow the symlink with a trailing slash (/). For example, if foo is a symlink to directory bar, to change the permissions of foo (actually bar), do something like: &prompt.user; chmod 555 foo/ With the trailing slash, &man.chmod.1; will follow the symlink, foo, to change the permissions of the directory, bar. Can I run DOS binaries under &os;? Yes. A DOS emulation program, emulators/doscmd, is available in the &os; Ports Collection. If doscmd will not suffice, emulators/pcemu emulates an 8088 and enough BIOS services to run many DOS text-mode applications. It requires the X Window System. The Ports Collection also has emulators/dosbox. The main focus of this application is emulating old DOS games using the local file system for files. What do I need to do to translate a &os; document into my native language? See the Translation FAQ in the &os; Documentation Project Primer. Why does my email to any address at FreeBSD.org bounce? The FreeBSD.org mail system implements some Postfix checks on incoming mail and rejects mail that is either from misconfigured relays or otherwise appears likely to be spam. Some of the specific requirements are: The IP address of the SMTP client must "reverse-resolve" to a forward confirmed hostname. The fully-qualified hostname given in the SMTP conversation (either HELO or EHLO) must resolve to the IP address of the client. Other advice to help mail reach its destination include: Mail should be sent in plain text, and messages sent to mailing lists should generally be no more than 200KB in length. Avoid excessive cross posting. Choose one mailing list which seems most relevant and send it there. If you still have trouble with email infrastructure at FreeBSD.org, send a note with the details to postmaster@freebsd.org; Include a date/time interval so that logs may be reviewed — and note that we only keep one week's worth of mail logs. (Be sure to specify the time zone or offset from UTC.) Where can I find a free &os; account? While &os; does not provide open access to any of their servers, others do provide open access &unix; systems. The charge varies and limited services may be available. Arbornet, Inc, also known as M-Net, has been providing open access to &unix; systems since 1983. Starting on an Altos running System III, the site switched to BSD/OS in 1991. In June of 2000, the site switched again to &os;. M-Net can be accessed via telnet and SSH and provides basic access to the entire &os; software suite. However, network access is limited to members and patrons who donate to the system, which is run as a non-profit organization. M-Net also provides an bulletin board system and interactive chat. What is the cute little red guy's name? He does not have one, and is just called the BSD daemon. If you insist upon using a name, call him beastie. Note that beastie is pronounced BSD. More about the BSD daemon is available on his home page. Can I use the BSD daemon image? Perhaps. The BSD daemon is copyrighted by Marshall Kirk McKusick. Check his Statement on the Use of the BSD Daemon Figure for detailed usage terms. In summary, the image can be used in a tasteful manner, for personal use, so long as appropriate credit is given. Before using the logo commercially, contact &a.mckusick.email; for permission. More details are available on the BSD Daemon's home page. Do you have any BSD daemon images I could use? Xfig and eps drawings are available under /usr/share/examples/BSD_daemon/. I have seen an acronym or other term on the mailing lists and I do not understand what it means. Where should I look? Refer to the &os; Glossary. Why should I care what color the bikeshed is? The really, really short answer is that you should not. The somewhat longer answer is that just because you are capable of building a bikeshed does not mean you should stop others from building one just because you do not like the color they plan to paint it. This is a metaphor indicating that you need not argue about every little feature just because you know enough to do so. Some people have commented that the amount of noise generated by a change is inversely proportional to the complexity of the change. The longer and more complete answer is that after a very long argument about whether &man.sleep.1; should take fractional second arguments, &a.phk.email; posted a long message entitled A bike shed (any color will do) on greener grass.... The appropriate portions of that message are quoted below.
&a.phk.email; on &a.hackers.name;, October 2, 1999 What is it about this bike shed? Some of you have asked me. It is a long story, or rather it is an old story, but it is quite short actually. C. Northcote Parkinson wrote a book in the early 1960s, called Parkinson's Law, which contains a lot of insight into the dynamics of management. [snip a bit of commentary on the book] In the specific example involving the bike shed, the other vital component is an atomic power-plant, I guess that illustrates the age of the book. Parkinson shows how you can go into the board of directors and get approval for building a multi-million or even billion dollar atomic power plant, but if you want to build a bike shed you will be tangled up in endless discussions. Parkinson explains that this is because an atomic plant is so vast, so expensive and so complicated that people cannot grasp it, and rather than try, they fall back on the assumption that somebody else checked all the details before it got this far. Richard P. Feynmann gives a couple of interesting, and very much to the point, examples relating to Los Alamos in his books. A bike shed on the other hand. Anyone can build one of those over a weekend, and still have time to watch the game on TV. So no matter how well prepared, no matter how reasonable you are with your proposal, somebody will seize the chance to show that he is doing his job, that he is paying attention, that he is here. In Denmark we call it setting your fingerprint. It is about personal pride and prestige, it is about being able to point somewhere and say There! I did that. It is a strong trait in politicians, but present in most people given the chance. Just think about footsteps in wet cement.
The &os; Funnies How cool is &os;? Q. Has anyone done any temperature testing while running &os;? I know &linux; runs cooler than DOS, but have never seen a mention of &os;. It seems to run really hot. A. No, but we have done numerous taste tests on blindfolded volunteers who have also had 250 micrograms of LSD-25 administered beforehand. 35% of the volunteers said that &os; tasted sort of orange, whereas &linux; tasted like purple haze. Neither group mentioned any significant variances in temperature. We eventually had to throw the results of this survey out entirely anyway when we found that too many volunteers were wandering out of the room during the tests, thus skewing the results. We think most of the volunteers are at Apple now, working on their new scratch and sniff GUI. It is a funny old business we are in! Seriously, &os; uses the HLT (halt) instruction when the system is idle thus lowering its energy consumption and therefore the heat it generates. Also if you have ACPI (Advanced Configuration and Power Interface) configured, then &os; can also put the CPU into a low power mode. Who is scratching in my memory banks?? Q. Is there anything odd that &os; does when compiling the kernel which would cause the memory to make a scratchy sound? When compiling (and for a brief moment after recognizing the floppy drive upon startup, as well), a strange scratchy sound emanates from what appears to be the memory banks. A. Yes! You will see frequent references to daemons in the BSD documentation, and what most people do not know is that this refers to genuine, non-corporeal entities that now possess your computer. The scratchy sound coming from your memory is actually high-pitched whispering exchanged among the daemons as they best decide how to deal with various system administration tasks. If the noise gets to you, a good fdisk /mbr from DOS will get rid of them, but do not be surprised if they react adversely and try to stop you. In fact, if at any point during the exercise you hear the satanic voice of Bill Gates coming from the built-in speaker, take off running and do not ever look back! Freed from the counterbalancing influence of the BSD daemons, the twin demons of DOS and &windows; are often able to re-assert total control over your machine to the eternal damnation of your soul. Now that you know, given a choice you would probably prefer to get used to the scratchy noises, no? How many &os; hackers does it take to change a lightbulb? One thousand, one hundred and sixty-nine: Twenty-three to complain to -CURRENT about the lights being out; Four to claim that it is a configuration problem, and that such matters really belong on -questions; Three to submit PRs about it, one of which is misfiled under doc and consists only of it's dark; One to commit an untested lightbulb which breaks buildworld, then back it out five minutes later; Eight to flame the PR originators for not including patches in their PRs; Five to complain about buildworld being broken; Thirty-one to answer that it works for them, and they must have updated at a bad time; One to post a patch for a new lightbulb to -hackers; One to complain that he had patches for this three years ago, but when he sent them to -CURRENT they were just ignored, and he has had bad experiences with the PR system; besides, the proposed new lightbulb is non-reflexive; Thirty-seven to scream that lightbulbs do not belong in the base system, that committers have no right to do things like this without consulting the Community, and WHAT IS -CORE DOING ABOUT IT!? Two hundred to complain about the color of the bicycle shed; Three to point out that the patch breaks &man.style.9;; Seventeen to complain that the proposed new lightbulb is under GPL; Five hundred and eighty-six to engage in a flame war about the comparative advantages of the GPL, the BSD license, the MIT license, the NPL, and the personal hygiene of unnamed FSF founders; Seven to move various portions of the thread to -chat and -advocacy; One to commit the suggested lightbulb, even though it shines dimmer than the old one; Two to back it out with a furious flame of a commit message, arguing that &os; is better off in the dark than with a dim lightbulb; Forty-six to argue vociferously about the backing out of the dim lightbulb and demanding a statement from -core; Eleven to request a smaller lightbulb so it will fit their Tamagotchi if we ever decide to port &os; to that platform; Seventy-three to complain about the SNR on -hackers and -chat and unsubscribe in protest; Thirteen to post unsubscribe, How do I unsubscribe?, or Please remove me from the list, followed by the usual footer; One to commit a working lightbulb while everybody is too busy flaming everybody else to notice; Thirty-one to point out that the new lightbulb would shine 0.364% brighter if compiled with TenDRA (although it will have to be reshaped into a cube), and that &os; should therefore switch to TenDRA instead of GCC; One to complain that the new lightbulb lacks fairings; Nine (including the PR originators) to ask what is MFC?; Fifty-seven to complain about the lights being out two weeks after the bulb has been changed. &a.nik.email; adds: I was laughing quite hard at this. And then I thought, Hang on, shouldn't there be '1 to document it.' in that list somewhere? And then I was enlightened :-) &a.tabthorpe.email; says: None, real &os; hackers are not afraid of the dark! Where does data written to /dev/null go? It goes into a special data sink in the CPU where it is converted to heat which is vented through the heatsink / fan assembly. This is why CPU cooling is increasingly important; as people get used to faster processors, they become careless with their data and more and more of it ends up in /dev/null, overheating their CPUs. If you delete /dev/null (which effectively disables the CPU data sink) your CPU may run cooler but your system will quickly become constipated with all that excess data and start to behave erratically. If you have a fast network connection you can cool down your CPU by reading data out of /dev/random and sending it off somewhere; however you run the risk of overheating your network connection and / or angering your ISP, as most of the data will end up getting converted to heat by their equipment, but they generally have good cooling, so if you do not overdo it you should be OK. Paul Robinson adds: There are other methods. As every good sysadmin knows, it is part of standard practice to send data to the screen of interesting variety to keep all the pixies that make up your picture happy. Screen pixies (commonly mis-typed or re-named as pixels) are categorized by the type of hat they wear (red, green or blue) and will hide or appear (thereby showing the color of their hat) whenever they receive a little piece of food. Video cards turn data into pixie-food, and then send them to the pixies — the more expensive the card, the better the food, so the better behaved the pixies are. They also need constant stimulation — this is why screen savers exist. To take your suggestions further, you could just throw the random data to console, thereby letting the pixies consume it. This causes no heat to be produced at all, keeps the pixies happy and gets rid of your data quite quickly, even if it does make things look a bit messy on your screen. Incidentally, as an ex-admin of a large ISP who experienced many problems attempting to maintain a stable temperature in a server room, I would strongly discourage people sending the data they do not want out to the network. The fairies who do the packet switching and routing get annoyed by it as well. My colleague sits at the computer too much, how can I prank her? Install games/sl and wait for her to mistype sl for ls. Advanced Topics How can I learn more about &os;'s internals? See the &os; Architecture Handbook. Additionally, much general &unix; knowledge is directly applicable to &os;. How can I contribute to &os;? What can I do to help? We accept all types of contributions: documentation, code, and even art. See the article on Contributing to &os; for specific advice on how to do this. And thanks for the thought! What are snapshots and releases? There are currently &rel.numbranch; active/semi-active branches in the &os; Subversion Repository. (Earlier branches are only changed very rarely, which is why there are only &rel.numbranch; active branches of development): &rel2.releng; AKA &rel2.stable; &rel.releng; AKA &rel.stable; &rel.head.releng; AKA -CURRENT AKA &rel.head; HEAD is not an actual branch tag. It is a symbolic constant for the current, non-branched development stream known as -CURRENT. Right now, -CURRENT is the &rel.head.relx; development stream; the &rel.stable; branch, &rel.releng;, forked off from -CURRENT in &rel.relengdate; and the &rel2.stable; branch, &rel2.releng;, forked off from -CURRENT in &rel2.relengdate;. How can I make the most of the data I see when my kernel panics? Here is typical kernel panic: Fatal trap 12: page fault while in kernel mode fault virtual address = 0x40 fault code = supervisor read, page not present instruction pointer = 0x8:0xf014a7e5 stack pointer = 0x10:0xf4ed6f24 frame pointer = 0x10:0xf4ed6f28 code segment = base 0x0, limit 0xfffff, type 0x1b = DPL 0, pres 1, def32 1, gran 1 processor eflags = interrupt enabled, resume, IOPL = 0 current process = 80 (mount) interrupt mask = trap number = 12 panic: page fault This message is not enough. While the instruction pointer value is important, it is also configuration dependent as it varies depending on the kernel image. If it is a GENERIC kernel image from one of the snapshots, it is possible for somebody else to track down the offending function, but for a custom kernel, only you can tell us where the fault occurred. To proceed: Write down the instruction pointer value. Note that the 0x8: part at the beginning is not significant in this case: it is the 0xf0xxxxxx part that we want. When the system reboots, do the following: &prompt.user; nm -n kernel.that.caused.the.panic | grep f0xxxxxx where f0xxxxxx is the instruction pointer value. The odds are you will not get an exact match since the symbols in the kernel symbol table are for the entry points of functions and the instruction pointer address will be somewhere inside a function, not at the start. If you do not get an exact match, omit the last digit from the instruction pointer value and try again: &prompt.user; nm -n kernel.that.caused.the.panic | grep f0xxxxx If that does not yield any results, chop off another digit. Repeat until there is some sort of output. The result will be a possible list of functions which caused the panic. This is a less than exact mechanism for tracking down the point of failure, but it is better than nothing. However, the best way to track down the cause of a panic is by capturing a crash dump, then using &man.kgdb.1; to generate a stack trace on the crash dump. In any case, the method is this: Make sure that the following line is included in the kernel configuration file: makeoptions DEBUG=-g # Build kernel with gdb(1) debug symbols Change to the /usr/src directory: &prompt.root; cd /usr/src Compile the kernel: &prompt.root; make buildkernel KERNCONF=MYKERNEL Wait for &man.make.1; to finish compiling. &prompt.root; make installkernel KERNCONF=MYKERNEL Reboot. If KERNCONF is not included, the GENERIC kernel will instead be built and installed. The &man.make.1; process will have built two kernels. /usr/obj/usr/src/sys/MYKERNEL/kernel and /usr/obj/usr/src/sys/MYKERNEL/kernel.debug. kernel was installed as /boot/kernel/kernel, while kernel.debug can be used as the source of debugging symbols for &man.kgdb.1;. To capture a crash dump, edit /etc/rc.conf and set dumpdev to point to either the swap partition or AUTO. This will cause the &man.rc.8; scripts to use the &man.dumpon.8; command to enable crash dumps. This command can also be run manually. After a panic, the crash dump can be recovered using &man.savecore.8;; if dumpdev is set in /etc/rc.conf, the &man.rc.8; scripts will run &man.savecore.8; automatically and put the crash dump in /var/crash. &os; crash dumps are usually the same size as physical RAM. Therefore, make sure there is enough space in /var/crash to hold the dump. Alternatively, run &man.savecore.8; manually and have it recover the crash dump to another directory with more room. It is possible to limit the size of the crash dump by using options MAXMEM=N where N is the size of kernel's memory usage in KBs. For example, for 1 GB of RAM, limit the kernel's memory usage to 128 MB, so that the crash dump size will be 128 MB instead of 1 GB. Once the crash dump has been recovered , get a stack trace as follows: &prompt.user; kgdb /usr/obj/usr/src/sys/MYKERNEL/kernel.debug /var/crash/vmcore.0 (kgdb) backtrace Note that there may be several screens worth of information. Ideally, use &man.script.1; to capture all of them. Using the unstripped kernel image with all the debug symbols should show the exact line of kernel source code where the panic occurred. The stack trace is usually read from the bottom up to trace the exact sequence of events that lead to the crash. &man.kgdb.1; can also be used to print out the contents of various variables or structures to examine the system state at the time of the crash. If a second computer is available, &man.kgdb.1; can be configured to do remote debugging, including setting breakpoints and single-stepping through the kernel code. If DDB is enabled and the kernel drops into the debugger, a panic and a crash dump can be forced by typing panic at the ddb prompt. It may stop in the debugger again during the panic phase. If it does, type continue and it will finish the crash dump. Why has dlsym() stopped working for ELF executables? The ELF toolchain does not, by default, make the symbols defined in an executable visible to the dynamic linker. Consequently dlsym() searches on handles obtained from calls to dlopen(NULL, flags) will fail to find such symbols. To search, using dlsym(), for symbols present in the main executable of a process, link the executable using the option to the ELF linker (&man.ld.1;). How can I increase or reduce the kernel address space on i386? By default, the kernel address space is 1 GB (2 GB for PAE) for i386. When running a network-intensive server or using ZFS, this will probably not be enough. Add the following line to the kernel configuration file to increase available space and rebuild the kernel: options KVA_PAGES=N To find the correct value of N, divide the desired address space size (in megabytes) by four. (For example, it is 512 for 2 GB.) Acknowledgments This innocent little Frequently Asked Questions document has been written, rewritten, edited, folded, spindled, mutilated, eviscerated, contemplated, discombobulated, cogitated, regurgitated, rebuilt, castigated, and reinvigorated over the last decade, by a cast of hundreds if not thousands. Repeatedly. We wish to thank every one of the people responsible, and we encourage you to join them in making this FAQ even better.
diff --git a/en_US.ISO8859-1/books/handbook/bsdinstall/chapter.xml b/en_US.ISO8859-1/books/handbook/bsdinstall/chapter.xml index 3a40f23413..c20e796c67 100644 --- a/en_US.ISO8859-1/books/handbook/bsdinstall/chapter.xml +++ b/en_US.ISO8859-1/books/handbook/bsdinstall/chapter.xml @@ -1,3018 +1,3018 @@ Installing &os; Jim Mock Restructured, reorganized, and parts rewritten by Gavin Atkinson Updated for bsdinstall by Warren Block Allan Jude Updated for root-on-ZFS by Synopsis installation There are several different ways of getting &os; to run, depending on the environment. Those are: Virtual Machine images, to download and import on a virtual environment of choice. These can be downloaded from the Download FreeBSD page. There are images for KVM (qcow2), VMWare (vmdk), Hyper-V (vhd), and raw device images that are universally supported. These are not installation images, but rather the preconfigured (already installed) instances, ready to run and perform post-installation tasks. Virtual Machine images available at Amazon's AWS Marketplace, Microsoft Azure Marketplace, and Google Cloud Platform, to run on their respective hosting services. For more information on deploying &os; on Azure please consult the relevant chapter in the Azure Documentation. SD card images, for embedded systems such as Raspberry Pi or BeagleBone Black. These can be downloaded from the Download FreeBSD page. These files must be uncompressed and written as a raw image to an SD card, from which the board will then boot. Installation images, to install &os; on a hard drive for the usual desktop, laptop, or server systems. The rest of this chapter describes the fourth case, explaining how to install &os; using the text-based installation program named bsdinstall. In general, the installation instructions in this chapter are written for the &i386; and AMD64 architectures. Where applicable, instructions specific to other platforms will be listed. There may be minor differences between the installer and what is shown here, so use this chapter as a general guide rather than as a set of literal instructions. Users who prefer to install &os; using a graphical installer may be interested in - FuryBSD, - GhostBSD or + GhostBSD, MidnightBSD. + xlink:href="https://www.midnightbsd.org">MidnightBSD or + NomadBSD. After reading this chapter, you will know: The minimum hardware requirements and &os; supported architectures. How to create the &os; installation media. How to start bsdinstall. The questions bsdinstall will ask, what they mean, and how to answer them. How to troubleshoot a failed installation. How to access a live version of &os; before committing to an installation. Before reading this chapter, you should: Read the supported hardware list that shipped with the version of &os; to be installed and verify that the system's hardware is supported. Minimum Hardware Requirements The hardware requirements to install &os; vary by architecture. Hardware architectures and devices supported by a &os; release are listed on the &os; Release Information page. The &os; download page also has recommendations for choosing the correct image for different architectures. A &os; installation requires a minimum of 96 MB of RAM and 1.5 GB of free hard drive space. However, such small amounts of memory and disk space are really only suitable for custom applications like embedded appliances. General-purpose desktop systems need more resources. 2-4 GB RAM and at least 8 GB hard drive space is a good starting point. These are the processor requirements for each architecture: &arch.amd64; This is the most common desktop and laptop processor type, used in most modern systems. &intel; calls it Intel64. Other manufacturers sometimes call it x86-64. Examples of &arch.amd64; compatible processors include: &amd.athlon;64, &amd.opteron;, multi-core &intel; &xeon;, and &intel; &core; 2 and later processors. &arch.i386; Older desktops and laptops often use this 32-bit, x86 architecture. Almost all i386-compatible processors with a floating point unit are supported. All &intel; processors 486 or higher are supported. &os; will take advantage of Physical Address Extensions (PAE) support on CPUs with this feature. A kernel with the PAE feature enabled will detect memory above 4 GB and allow it to be used by the system. However, using PAE places constraints on device drivers and other features of &os;. &arch.powerpc; All New World ROM &apple; &mac; systems with built-in USB are supported. SMP is supported on machines with multiple CPUs. A 32-bit kernel can only use the first 2 GB of RAM. &arch.sparc64; Systems supported by &os;/&arch.sparc64; are listed at the FreeBSD/sparc64 Project. SMP is supported on all systems with more than 1 processor. A dedicated disk is required as it is not possible to share a disk with another operating system at this time. Pre-Installation Tasks Once it has been determined that the system meets the minimum hardware requirements for installing &os;, the installation file should be downloaded and the installation media prepared. Before doing this, check that the system is ready for an installation by verifying the items in this checklist: Back Up Important Data Before installing any operating system, always backup all important data first. Do not store the backup on the system being installed. Instead, save the data to a removable disk such as a USB drive, another system on the network, or an online backup service. Test the backup before starting the installation to make sure it contains all of the needed files. Once the installer formats the system's disk, all data stored on that disk will be lost. Decide Where to Install &os; If &os; will be the only operating system installed, this step can be skipped. But if &os; will share the disk with another operating system, decide which disk or partition will be used for &os;. In the &arch.i386; and &arch.amd64; architectures, disks can be divided into multiple partitions using one of two partitioning schemes. A traditional Master Boot Record (MBR) holds a partition table defining up to four primary partitions. For historical reasons, &os; calls these primary partition slices. One of these primary partitions can be made into an extended partition containing multiple logical partitions. The GUID Partition Table (GPT) is a newer and simpler method of partitioning a disk. Common GPT implementations allow up to 128 partitions per disk, eliminating the need for logical partitions. The &os; boot loader requires either a primary or GPT partition. If all of the primary or GPT partitions are already in use, one must be freed for &os;. To create a partition without deleting existing data, use a partition resizing tool to shrink an existing partition and create a new partition using the freed space. A variety of free and commercial partition resizing tools are listed at http://en.wikipedia.org/wiki/List_of_disk_partitioning_software. GParted Live (http://gparted.sourceforge.net/livecd.php) is a free live CD which includes the GParted partition editor. GParted is also included with many other Linux live CD distributions. When used properly, disk shrinking utilities can safely create space for creating a new partition. Since the possibility of selecting the wrong partition exists, always backup any important data and verify the integrity of the backup before modifying disk partitions. Disk partitions containing different operating systems make it possible to install multiple operating systems on one computer. An alternative is to use virtualization () which allows multiple operating systems to run at the same time without modifying any disk partitions. Collect Network Information Some &os; installation methods require a network connection in order to download the installation files. After any installation, the installer will offer to setup the system's network interfaces. If the network has a DHCP server, it can be used to provide automatic network configuration. If DHCP is not available, the following network information for the system must be obtained from the local network administrator or Internet service provider: Required Network Information IP address Subnet mask IP address of default gateway Domain name of the network IP addresses of the network's DNS servers Check for &os; Errata Although the &os; Project strives to ensure that each release of &os; is as stable as possible, bugs occasionally creep into the process. On very rare occasions those bugs affect the installation process. As these problems are discovered and fixed, they are noted in the &os; Errata (https://www.freebsd.org/releases/&rel121.current;R/errata.html) on the &os; web site. Check the errata before installing to make sure that there are no problems that might affect the installation. Information and errata for all the releases can be found on the release information section of the &os; web site (https://www.freebsd.org/releases/index.html). Prepare the Installation Media The &os; installer is not an application that can be run from within another operating system. Instead, download a &os; installation file, burn it to the media associated with its file type and size (CD, DVD, or USB), and boot the system to install from the inserted media. &os; installation files are available at www.freebsd.org/where.html#download. Each installation file's name includes the release version of &os;, the architecture, and the type of file. For example, to install &os; 12.1 on an &arch.amd64; system from a DVD, download FreeBSD-12.1-RELEASE-amd64-dvd1.iso, burn this file to a DVD, and boot the system with the DVD inserted. Installation files are available in several formats. The formats vary depending on computer architecture and media type. Additional installation files are included for computers that boot with UEFI (Unified Extensible Firmware Interface). The names of these files include the string uefi. File types: -bootonly.iso: This is the smallest installation file as it only contains the installer. A working Internet connection is required during installation as the installer will download the files it needs to complete the &os; installation. This file should be burned to a CD using a CD burning application. -disc1.iso: This file contains all of the files needed to install &os;, its source, and the Ports Collection. It should be burned to a CD using a CD burning application. -dvd1.iso: This file contains all of the files needed to install &os;, its source, and the Ports Collection. It also contains a set of popular binary packages for installing a window manager and some applications so that a complete system can be installed from media without requiring a connection to the Internet. This file should be burned to a DVD using a DVD burning application. -memstick.img: This file contains all of the files needed to install &os;, its source, and the Ports Collection. It should be burned to a USB stick using the instructions below. -mini-memstick.img: Like -bootonly.iso, does not include installation files, but downloads them as needed. A working internet connection is required during installation. Write this file to a USB stick as shown in . After downloading the image file, download CHECKSUM.SHA256 from the same directory. Calculate a checksum for the image file. &os; provides &man.sha256.1; for this, used as sha256 imagefilename. Other operating systems have similar programs. Compare the calculated checksum with the one shown in CHECKSUM.SHA256. The checksums must match exactly. If the checksums do not match, the image file is corrupt and must be downloaded again. Writing an Image File to <acronym>USB</acronym> The *.img file is an image of the complete contents of a memory stick. It cannot be copied to the target device as a file. Several applications are available for writing the *.img to a USB stick. This section describes two of these utilities. Before proceeding, back up any important data on the USB stick. This procedure will erase the existing data on the stick. Using <command>dd</command> to Write the Image This example uses /dev/da0 as the target device where the image will be written. Be very careful that the correct device is used as this command will destroy the existing data on the specified target device. The &man.dd.1; command-line utility is available on BSD, &linux;, and &macos; systems. To burn the image using dd, insert the USB stick and determine its device name. Then, specify the name of the downloaded installation file and the device name for the USB stick. This example burns the &arch.amd64; installation image to the first USB device on an existing &os; system. &prompt.root; dd if=FreeBSD-12.1-RELEASE-amd64-memstick.img of=/dev/da0 bs=1M conv=sync If this command fails, verify that the USB stick is not mounted and that the device name is for the disk, not a partition. Some operating systems might require this command to be run with &man.sudo.8;. The &man.dd.1; syntax varies slightly across different platforms; for example, &macos; requires a lower-case . Systems like &linux; might buffer writes. To force all writes to complete, use &man.sync.8;. Using &windows; to Write the Image Be sure to give the correct drive letter as the existing data on the specified drive will be overwritten and destroyed. Obtaining <application>Image Writer for &windows;</application> Image Writer for &windows; is a free application that can correctly write an image file to a memory stick. Download it from https://sourceforge.net/projects/win32diskimager/ and extract it into a folder. Writing the Image with Image Writer Double-click the Win32DiskImager icon to start the program. Verify that the drive letter shown under Device is the drive with the memory stick. Click the folder icon and select the image to be written to the memory stick. Click [ Save ] to accept the image file name. Verify that everything is correct, and that no folders on the memory stick are open in other windows. When everything is ready, click [ Write ] to write the image file to the memory stick. You are now ready to start installing &os;. Starting the Installation By default, the installation will not make any changes to the disk(s) before the following message: Your changes will now be written to disk. If you have chosen to overwrite existing data, it will be PERMANENTLY ERASED. Are you sure you want to commit your changes? The install can be exited at any time prior to this warning. If there is a concern that something is incorrectly configured, just turn the computer off before this point and no changes will be made to the system's disks. This section describes how to boot the system from the installation media which was prepared using the instructions in . When using a bootable USB stick, plug in the USB stick before turning on the computer. When booting from CD or DVD, turn on the computer and insert the media at the first opportunity. How to configure the system to boot from the inserted media depends upon the architecture. Booting on &i386; and &arch.amd64; These architectures provide a BIOS menu for selecting the boot device. Depending upon the installation media being used, select the CD/DVD or USB device as the first boot device. Most systems also provide a key for selecting the boot device during startup without having to enter the BIOS. Typically, the key is either F10, F11, F12, or Escape. If the computer loads the existing operating system instead of the &os; installer, then either: The installation media was not inserted early enough in the boot process. Leave the media inserted and try restarting the computer. The BIOS changes were incorrect or not saved. Double-check that the right boot device is selected as the first boot device. This system is too old to support booting from the chosen media. In this case, the Plop Boot Manager () can be used to boot the system from the selected media. Booting on &powerpc; On most machines, holding C on the keyboard during boot will boot from the CD. Otherwise, hold Command Option O F , or Windows Alt O F on non-&apple; keyboards. At the 0 > prompt, enter boot cd:,\ppc\loader cd:0 &os; Boot Menu Once the system boots from the installation media, a menu similar to the following will be displayed:
&os; Boot Loader Menu
By default, the menu will wait ten seconds for user input before booting into the &os; installer or, if &os; is already installed, before booting into &os;. To pause the boot timer in order to review the selections, press Space. To select an option, press its highlighted number, character, or key. The following options are available. Boot Multi User: This will continue the &os; boot process. If the boot timer has been paused, press 1, upper- or lower-case B, or Enter. Boot Single User: This mode can be used to fix an existing &os; installation as described in . Press 2 or the upper- or lower-case S to enter this mode. Escape to loader prompt: This will boot the system into a repair prompt that contains a limited number of low-level commands. This prompt is described in . Press 3 or Esc to boot into this prompt. Reboot: Reboots the system. Kernel: Loads a different kernel. Configure Boot Options: Opens the menu shown in, and described under, .
&os; Boot Options Menu
The boot options menu is divided into two sections. The first section can be used to either return to the main boot menu or to reset any toggled options back to their defaults. The next section is used to toggle the available options to On or Off by pressing the option's highlighted number or character. The system will always boot using the settings for these options until they are modified. Several options can be toggled using this menu: ACPI Support: If the system hangs during boot, try toggling this option to Off. Safe Mode: If the system still hangs during boot even with ACPI Support set to Off, try setting this option to On. Single User: Toggle this option to On to fix an existing &os; installation as described in . Once the problem is fixed, set it back to Off. Verbose: Toggle this option to On to see more detailed messages during the boot process. This can be useful when troubleshooting a piece of hardware. After making the needed selections, press 1 or Backspace to return to the main boot menu, then press Enter to continue booting into &os;. A series of boot messages will appear as &os; carries out its hardware device probes and loads the installation program. Once the boot is complete, the welcome menu shown in will be displayed.
Welcome Menu
Press Enter to select the default of [ Install ] to enter the installer. The rest of this chapter describes how to use this installer. Otherwise, use the right or left arrows or the colorized letter to select the desired menu item. The [ Shell ] can be used to access a &os; shell in order to use command line utilities to prepare the disks before installation. The [ Live CD ] option can be used to try out &os; before installing it. The live version is described in . To review the boot messages, including the hardware device probe, press the upper- or lower-case S and then Enter to access a shell. At the shell prompt, type more /var/run/dmesg.boot and use the space bar to scroll through the messages. When finished, type exit to return to the welcome menu.
Using <application>bsdinstall</application> This section shows the order of the bsdinstall menus and the type of information that will be asked before the system is installed. Use the arrow keys to highlight a menu option, then Space to select or deselect that menu item. When finished, press Enter to save the selection and move onto the next screen. Selecting the Keymap Menu Before starting the process, bsdinstall will load the keymap files as show in .
Keymap Loading
After the keymaps have been loaded bsdinstall displays the menu shown in . Use the up and down arrows to select the keymap that most closely represents the mapping of the keyboard attached to the system. Press Enter to save the selection.
Keymap Selection Menu
Pressing Esc will exit this menu and use the default keymap. If the choice of keymap is not clear, United States of America ISO-8859-1 is also a safe option. In addition, when selecting a different keymap, the user can try the keymap and ensure it is correct before proceeding as shown in .
Keymap Testing Menu
Setting the Hostname The next bsdinstall menu is used to set the hostname for the newly installed system.
Setting the Hostname
Type in a hostname that is unique for the network. It should be a fully-qualified hostname, such as machine3.example.com.
Selecting Components to Install Next, bsdinstall will prompt to select optional components to install.
Selecting Components to Install
Deciding which components to install will depend largely on the intended use of the system and the amount of disk space available. The &os; kernel and userland, collectively known as the base system, are always installed. Depending on the architecture, some of these components may not appear: base-dbg - Base tools like cat, ls among many others with debug symbols activated. kernel-dbg - Kernel and modules with debug symbols activated. lib32-dbg - Compatibility libraries for running 32-bit applications on a 64-bit version of &os; with debug symbols activated. lib32 - Compatibility libraries for running 32-bit applications on a 64-bit version of &os;. ports - The &os; Ports Collection is a collection of files which automates the downloading, compiling and installation of third-party software packages. discusses how to use the Ports Collection. The installation program does not check for adequate disk space. Select this option only if sufficient hard disk space is available. The &os; Ports Collection takes up about &ports.size; of disk space. src - The complete &os; source code for both the kernel and the userland. Although not required for the majority of applications, it may be required to build device drivers, kernel modules, or some applications from the Ports Collection. It is also used for developing &os; itself. The full source tree requires 1 GB of disk space and recompiling the entire &os; system requires an additional 5 GB of space. tests - &os; Test Suite.
Installing from the Network The menu shown in only appears when installing from a -bootonly.iso or -mini-memstick.img as this installation media does not hold copies of the installation files. Since the installation files must be retrieved over a network connection, this menu indicates that the network interface must be configured first. If this menu is shown in any step of the process remember to follow the instructions in .
Installing from the Network
Allocating Disk Space The next menu is used to determine the method for allocating disk space.
Partitioning Choices
bsdinstall gives the user four methods for allocating disk space: Auto (UFS) partitioning automatically sets up the disk partitions using the UFS file system. Manual partitioning allows advanced users to create customized partitions from menu options. Shell opens a shell prompt where advanced users can create customized partitions using command-line utilities like &man.gpart.8;, &man.fdisk.8;, and &man.bsdlabel.8;. Auto (ZFS) partitioning creates a root-on-ZFS system with optional GELI encryption support for boot environments. This section describes what to consider when laying out the disk partitions. It then demonstrates how to use the different partitioning methods. Designing the Partition Layout partition layout /etc /var /usr When laying out file systems, remember that hard drives transfer data faster from the outer tracks to the inner. Thus, smaller and heavier-accessed file systems should be closer to the outside of the drive, while larger partitions like /usr should be placed toward the inner parts of the disk. It is a good idea to create partitions in an order similar to: /, swap, /var, and /usr. The size of the /var partition reflects the intended machine's usage. This partition is used to hold mailboxes, log files, and printer spools. Mailboxes and log files can grow to unexpected sizes depending on the number of users and how long log files are kept. On average, most users rarely need more than about a gigabyte of free disk space in /var. Sometimes, a lot of disk space is required in /var/tmp. When new software is installed, the packaging tools extract a temporary copy of the packages under /var/tmp. Large software packages, like Firefox or LibreOffice may be tricky to install if there is not enough disk space under /var/tmp. The /usr partition holds many of the files which support the system, including the &os; Ports Collection and system source code. At least 2 gigabytes of space is recommended for this partition. When selecting partition sizes, keep the space requirements in mind. Running out of space in one partition while barely using another can be a hassle. swap sizing swap partition As a rule of thumb, the swap partition should be about double the size of physical memory (RAM). Systems with minimal RAM may perform better with more swap. Configuring too little swap can lead to inefficiencies in the VM page scanning code and might create issues later if more memory is added. On larger systems with multiple SCSI disks or multiple IDE disks operating on different controllers, it is recommended that swap be configured on each drive, up to four drives. The swap partitions should be approximately the same size. The kernel can handle arbitrary sizes but internal data structures scale to 4 times the largest swap partition. Keeping the swap partitions near the same size will allow the kernel to optimally stripe swap space across disks. Large swap sizes are fine, even if swap is not used much. It might be easier to recover from a runaway program before being forced to reboot. By properly partitioning a system, fragmentation introduced in the smaller write heavy partitions will not bleed over into the mostly read partitions. Keeping the write loaded partitions closer to the disk's edge will increase I/O performance in the partitions where it occurs the most. While I/O performance in the larger partitions may be needed, shifting them more toward the edge of the disk will not lead to a significant performance improvement over moving /var to the edge. Guided Partitioning Using UFS When this method is selected, a menu will display the available disk(s). If multiple disks are connected, choose the one where &os; is to be installed.
Selecting from Multiple Disks
Once the disk is selected, the next menu prompts to install to either the entire disk or to create a partition using free space. If [ Entire Disk ] is chosen, a general partition layout filling the whole disk is automatically created. Selecting [ Partition ] creates a partition layout from the unused space on the disk.
Selecting Entire Disk or Partition
After [ Entire Disk ] is chosen bsdinstall displays a dialog indicating that the disk will be erased.
Confirmation
The next menu shows a list with the partition schemes types. GPT is usually the most appropriate choice for amd64 computers. Older computers that are not compatible with GPT should use MBR. The other partition schemes are generally used for uncommon or older computers. More information is available in .
Select Partition Scheme
After the partition layout has been created, review it to ensure it meets the needs of the installation. Selecting [ Revert ] will reset the partitions to their original values and pressing [ Auto ] will recreate the automatic &os; partitions. Partitions can also be manually created, modified, or deleted. When the partitioning is correct, select [ Finish ] to continue with the installation.
Review Created Partitions
Once the disks are configured, the next menu provides the last chance to make changes before the selected drives are formatted. If changes need to be made, select [ Back ] to return to the main partitioning menu. [ Revert & Exit ] exits the installer without making any changes to the drive. Select [ Commit ] to start the installation process.
Final Confirmation
To continue with the installation process go to .
Manual Partitioning Selecting this method opens the partition editor:
Manually Create Partitions
Highlight the installation drive (ada0 in this example) and select [ Create ] to display a menu of available partition schemes:
Manually Create Partitions
GPT is usually the most appropriate choice for &arch.amd64; computers. Older computers that are not compatible with GPT should use MBR. The other partition schemes are generally used for uncommon or older computers. Partitioning Schemes Abbreviation Description APM Apple Partition Map, used by &powerpc;. BSD BSD label without an MBR, sometimes called dangerously dedicated mode as non-BSD disk utilities may not recognize it. GPT GUID Partition Table (http://en.wikipedia.org/wiki/GUID_Partition_Table). MBR Master Boot Record (http://en.wikipedia.org/wiki/Master_boot_record). VTOC8 Volume Table Of Contents used by Sun SPARC64 and UltraSPARC computers.
After the partitioning scheme has been selected and created, select [ Create ] again to create the partitions. The Tab key is used to move the cursor between fields.
Manually Create Partitions
A standard &os; GPT installation uses at least three partitions: freebsd-boot - Holds the &os; boot code. freebsd-ufs - A &os; UFS file system. freebsd-zfs - A &os; ZFS file system. More information about ZFS is available in . freebsd-swap - &os; swap space. Refer to &man.gpart.8; for descriptions of the available GPT partition types. Multiple file system partitions can be created and some people prefer a traditional layout with separate partitions for /, /var, /tmp, and /usr. See for an example. The Size may be entered with common abbreviations: K for kilobytes, M for megabytes, or G for gigabytes. Proper sector alignment provides the best performance, and making partition sizes even multiples of 4K bytes helps to ensure alignment on drives with either 512-byte or 4K-byte sectors. Generally, using partition sizes that are even multiples of 1M or 1G is the easiest way to make sure every partition starts at an even multiple of 4K. There is one exception: the freebsd-boot partition should be no larger than 512K due to current boot code limitations. A Mountpoint is needed if the partition will contain a file system. If only a single UFS partition will be created, the mountpoint should be /. The Label is a name by which the partition will be known. Drive names or numbers can change if the drive is connected to a different controller or port, but the partition label does not change. Referring to labels instead of drive names and partition numbers in files like /etc/fstab makes the system more tolerant to hardware changes. GPT labels appear in /dev/gpt/ when a disk is attached. Other partitioning schemes have different label capabilities and their labels appear in different directories in /dev/. Use a unique label on every partition to avoid conflicts from identical labels. A few letters from the computer's name, use, or location can be added to the label. For instance, use labroot or rootfslab for the UFS root partition on the computer named lab. Creating Traditional Split File System Partitions For a traditional partition layout where the /, /var, /tmp, and /usr directories are separate file systems on their own partitions, create a GPT partitioning scheme, then create the partitions as shown. Partition sizes shown are typical for a 20G target disk. If more space is available on the target disk, larger swap or /var partitions may be useful. Labels shown here are prefixed with ex for example, but readers should use other unique label values as described above. By default, &os;'s gptboot expects the first UFS partition to be the / partition. Partition Type Size Mountpoint Label freebsd-boot 512K freebsd-ufs 2G / exrootfs freebsd-swap 4G exswap freebsd-ufs 2G /var exvarfs freebsd-ufs 1G /tmp extmpfs freebsd-ufs accept the default (remainder of the disk) /usr exusrfs After the custom partitions have been created, select [ Finish ] to continue with the installation and go to .
Guided Partitioning Using Root-on-ZFS This partitioning mode only works with whole disks and will erase the contents of the entire disk. The main ZFS configuration menu offers a number of options to control the creation of the pool.
<acronym>ZFS</acronym> Partitioning Menu
Here is a summary of the options which can be used in this menu: Install - Proceed with the installation with the selected options. Pool Type/Disks - Allow to configure the Pool Type and the disk(s) that will constitute the pool. The automatic ZFS installer currently only supports the creation of a single top level vdev, except in stripe mode. To create more complex pools, use the instructions in to create the pool. Rescan Devices - Repopulate the list of available disks. Disk Info - Disk Info menu can be used to inspect each disk, including its partition table and various other information such as the device model number and serial number, if available. Pool Name - Establish the name of the pool. The default name is zroot. Force 4K Sectors? - Force the use of 4K sectors. By default, the installer will automatically create partitions aligned to 4K boundaries and force ZFS to use 4K sectors. This is safe even with 512 byte sector disks, and has the added benefit of ensuring that pools created on 512 byte disks will be able to have 4K sector disks added in the future, either as additional storage space or as replacements for failed disks. Press the Enter key to chose to activate it or not. Encrypt Disks? - Encrypting the disks allows the user to encrypt the disks using GELI. More information about disk encryption is available in . Press the Enter key to chose activate it or not. Partition Scheme - Allow to choose the partition scheme. GPT is the recommended option in most cases. Press the Enter key to chose between the different options. Swap Size - Establish the amount of swap space. Mirror Swap? - Allows the user to mirror the swap between the disks. Be aware, enabling mirror swap will break crash dumps. Press the Enter key to activate it or not. Encrypt Swap? - Allow the user the possibility to encrypt the swap. Encrypts the swap with a temporary key each time that the system boots and discards it on reboot. Press the Enter key to chose activate it or not. More information about swap encryption in . Select T to configure the Pool Type and the disk(s) that will constitute the pool.
<acronym>ZFS</acronym> Pool Type
Here is a summary of the Pool Type which can be selected in this menu: stripe - Striping provides maximum storage of all connected devices, but no redundancy. If just one disk fails the data on the pool is lost irrevocably. mirror - Mirroring stores a complete copy of all data on every disk. Mirroring provides a good read perfomance because data is read from all disks in parallel. Write performance is slower as the data must be written to all disks in the pool. Allows all but one disk to fail. This option requires at least two disks. raid10 - Striped mirrors. Provides the best performance, but the least storage. This option needs at least an even number of disks and a minimum of four disks. raidz1 - Single Redundant RAID. Allow one disk to fail concurrently. This option needs at least three disks. raidz2 - Double Redundant RAID. Allows two disks to fail concurrently. This option needs at least four disks. raidz3 - Triple Redundant RAID. Allows three disks to fail concurrently. This option needs at least five disks. Once a Pool Type has been selected, a list of available disks is displayed, and the user is prompted to select one or more disks to make up the pool. The configuration is then validated, to ensure enough disks are selected. If not, select <Change Selection> to return to the list of disks, or <Back> to change the Pool Type.
Disk Selection
Invalid Selection
If one or more disks are missing from the list, or if disks were attached after the installer was started, select - Rescan Devices to repopulate the list of available disks.
Rescan Devices
To avoid accidentally erasing the wrong disk, the - Disk Info menu can be used to inspect each disk, including its partition table and various other information such as the device model number and serial number, if available.
Analyzing a Disk
Select N to configure the Pool Name. Enter the desired name then select <OK> to establish it or <Cancel> to return to the main menu and leave the default name.
Pool Name
Select S to set the amount of swap. Enter the desired amount of swap and then select <OK> to establish it or <Cancel> to return to the main menu and let the default amount.
Swap Amount
Once all options have been set to the desired values, select the >>> Install option at the top of the menu. The installer then offers a last chance to cancel before the contents of the selected drives are destroyed to create the ZFS pool.
Last Chance
If GELI disk encryption was enabled, the installer will prompt twice for the passphrase to be used to encrypt the disks. And after that the initializing of the encryption begins.
Disk Encryption Password
Initializing Encryption
The installation then proceeds normally. To continue with the installation go to .
Shell Mode Partitioning When creating advanced installations, the bsdinstall partitioning menus may not provide the level of flexibility required. Advanced users can select the Shell option from the partitioning menu in order to manually partition the drives, create the file system(s), populate /tmp/bsdinstall_etc/fstab, and mount the file systems under /mnt. Once this is done, type exit to return to bsdinstall and continue the installation.
Fetching Distribution Files Installation time will vary depending on the distributions chosen, installation media, and speed of the computer. A series of messages will indicate the progress. First, the installer formats the selected disk(s) and initializes the partitions. Next, in the case of a bootonly media or mini memstick, it downloads the selected components:
Fetching Distribution Files
Next, the integrity of the distribution files is verified to ensure they have not been corrupted during download or misread from the installation media:
Verifying Distribution Files
Finally, the verified distribution files are extracted to the disk:
Extracting Distribution Files
Once all requested distribution files have been extracted, bsdinstall displays the first post-installation configuration screen. The available post-configuration options are described in the next section.
Accounts, Time Zone, Services and Hardening Setting the <systemitem class="username">root</systemitem> Password First, the root password must be set. While entering the password, the characters being typed are not displayed on the screen. After the password has been entered, it must be entered again. This helps prevent typing errors.
Setting the <systemitem class="username">root</systemitem> Password
Setting the Time Zone The next series of menus are used to determine the correct local time by selecting the geographic region, country, and time zone. Setting the time zone allows the system to automatically correct for regional time changes, such as daylight savings time, and perform other time zone related functions properly. The example shown here is for a machine located in the mainland time zone of Spain, Europe. The selections will vary according to the geographical location.
Select a Region
The appropriate region is selected using the arrow keys and then pressing Enter.
Select a Country
Select the appropriate country using the arrow keys and press Enter.
Select a Time Zone
The appropriate time zone is selected using the arrow keys and pressing Enter.
Confirm Time Zone
Confirm the abbreviation for the time zone is correct.
Select Date
The appropriate date is selected using the arrow keys and then pressing [ Set Date ]. Otherwise, the date selection can be skipped by pressing [ Skip ].
Select Time
The appropriate time is selected using the arrow keys and then pressing [ Set Time ]. Otherwise, the time selection can be skipped by pressing [ Skip ].
Enabling Services The next menu is used to configure which system services will be started whenever the system boots. All of these services are optional. Only start the services that are needed for the system to function.
Selecting Additional Services to Enable
Here is a summary of the services which can be enabled in this menu: local_unbound - Enable the DNS local unbound. It is necessary to keep in mind that this is the unbound of the base system and is only meant for use as a local caching forwarding resolver. If the objective is to set up a resolver for the entire network install dns/unbound. sshd - The Secure Shell (SSH) daemon is used to remotely access a system over an encrypted connection. Only enable this service if the system should be available for remote logins. moused - Enable this service if the mouse will be used from the command-line system console. ntpdate - Enable the automatic clock synchronization at boot time. The functionality of this program is now available in the &man.ntpd.8; daemon. After a suitable period of mourning, the &man.ntpdate.8; utility will be retired. ntpd - The Network Time Protocol (NTP) daemon for automatic clock synchronization. Enable this service if there is a &windows;, Kerberos, or LDAP server on the network. powerd - System power control utility for power control and energy saving. dumpdev - Enabling crash dumps is useful in debugging issues with the system, so users are encouraged to enable crash dumps.
Enabling Hardening Security Options The next menu is used to configure which security options will be enabled. All of these options are optional. But their use is encouraged.
Selecting Hardening Security Options
Here is a summary of the options which can be enabled in this menu: hide_uids - Hide processes running as other users to prevent the unprivileged users to see other running processes in execution by other users (UID) preventing information leakage. hide_gids - Hide processes running as other groups to prevent the unprivileged users to see other running processes in execution by other groups (GID) preventing information leakage. hide_jail - Hide processes running in jails to prevent the unprivileged users to see processes running inside the jails. read_msgbuf - Disabling reading kernel message buffer for unprivileged users prevent from using &man.dmesg.8; to view messages from the kernel's log buffer. proc_debug - Disabling process debugging facilities for unprivileged users disables a variety of unprivileged inter-process debugging services, including some procfs functionality, ptrace(), and ktrace(). Please note that this will also prevent debugging tools, for instance &man.lldb.1;, &man.truss.1;, &man.procstat.1;, as well as some built-in debugging facilities in certain scripting language like PHP, etc., from working for unprivileged users. random_pid - Randomize the PID of newly created processes. clear_tmp - Clean /tmp when the system starts up. disable_syslogd - Disable opening syslogd network socket. By default &os; runs syslogd in a secure way with -s. That prevents the daemon from listening for incoming UDP requests at port 514. With this option enabled syslogd will run with the flag -ss which prevents syslogd from opening any port. To get more information consult &man.syslogd.8;. disable_sendmail - Disable the sendmail mail transport agent. secure_console - When this option is enabled, the prompt requests the root password when entering single-user mode. disable_ddtrace - &dtrace; can run in a mode that will actually affect the running kernel. Destructive actions may not be used unless they have been explicitly enabled. To enable this option when using &dtrace; use -w. To get more information consult &man.dtrace.1;.
Add Users The next menu prompts to create at least one user account. It is recommended to login to the system using a user account rather than as root. When logged in as root, there are essentially no limits or protection on what can be done. Logging in as a normal user is safer and more secure. Select [ Yes ] to add new users.
Add User Accounts
Follow the prompts and input the requested information for the user account. The example shown in creates the asample user account.
Enter User Information
Here is a summary of the information to input: Username - The name the user will enter to log in. A common convention is to use the first letter of the first name combined with the last name, as long as each username is unique for the system. The username is case sensitive and should not contain any spaces. Full name - The user's full name. This can contain spaces and is used as a description for the user account. Uid - User ID. Typically, this is left blank so the system will assign a value. Login group - The user's group. Typically this is left blank to accept the default. Invite user into other groups? - Additional groups to which the user will be added as a member. If the user needs administrative access, type wheel here. Login class - Typically left blank for the default. Shell - Type in one of the listed values to set the interactive shell for the user. Refer to for more information about shells. Home directory - The user's home directory. The default is usually correct. Home directory permissions - Permissions on the user's home directory. The default is usually correct. Use password-based authentication? - Typically yes so that the user is prompted to input their password at login. Use an empty password? - Typically no as it is insecure to have a blank password. Use a random password? - Typically no so that the user can set their own password in the next prompt. Enter password - The password for this user. Characters typed will not show on the screen. Enter password again - The password must be typed again for verification. Lock out the account after creation? - Typically no so that the user can login. After entering everything, a summary is shown for review. If a mistake was made, enter no and try again. If everything is correct, enter yes to create the new user.
Exit User and Group Management
If there are more users to add, answer the Add another user? question with yes. Enter no to finish adding users and continue the installation. For more information on adding users and user management, see .
Final Configuration After everything has been installed and configured, a final chance is provided to modify settings.
Final Configuration
Use this menu to make any changes or do any additional configuration before completing the installation. Add User - Described in . Root Password - Described in . Hostname - Described in . Network - Described in . Services - Described in . System Hardening - Described in . Time Zone - Described in . Handbook - Download and install the &os; Handbook. After any final configuration is complete, select Exit.
Manual Configuration
bsdinstall will prompt if there are any additional configuration that needs to be done before rebooting into the new system. Select [ Yes ] to exit to a shell within the new system or [ No ] to proceed to the last step of the installation.
Complete the Installation
If further configuration or special setup is needed, select [ Live CD ] to boot the install media into Live CD mode. If the installation is complete, select [ Reboot ] to reboot the computer and start the new &os; system. Do not forget to remove the &os; install media or the computer may boot from it again. As &os; boots, informational messages are displayed. After the system finishes booting, a login prompt is displayed. At the login: prompt, enter the username added during the installation. Avoid logging in as root. Refer to for instructions on how to become the superuser when administrative access is needed. The messages that appeared during boot can be reviewed by pressing Scroll-Lock to turn on the scroll-back buffer. The PgUp, PgDn, and arrow keys can be used to scroll back through the messages. When finished, press Scroll-Lock again to unlock the display and return to the console. To review these messages once the system has been up for some time, type less /var/run/dmesg.boot from a command prompt. Press q to return to the command line after viewing. If sshd was enabled in , the first boot may be a bit slower as the system will generate the RSA and DSA keys. Subsequent boots will be faster. The fingerprints of the keys will be displayed, as seen in this example: Generating public/private rsa1 key pair. Your identification has been saved in /etc/ssh/ssh_host_key. Your public key has been saved in /etc/ssh/ssh_host_key.pub. The key fingerprint is: 10:a0:f5:af:93:ae:a3:1a:b2:bb:3c:35:d9:5a:b3:f3 root@machine3.example.com The key's randomart image is: +--[RSA1 1024]----+ | o.. | | o . . | | . o | | o | | o S | | + + o | |o . + * | |o+ ..+ . | |==o..o+E | +-----------------+ Generating public/private dsa key pair. Your identification has been saved in /etc/ssh/ssh_host_dsa_key. Your public key has been saved in /etc/ssh/ssh_host_dsa_key.pub. The key fingerprint is: 7e:1c:ce:dc:8a:3a:18:13:5b:34:b5:cf:d9:d1:47:b2 root@machine3.example.com The key's randomart image is: +--[ DSA 1024]----+ | .. . .| | o . . + | | . .. . E .| | . . o o . . | | + S = . | | + . = o | | + . * . | | . . o . | | .o. . | +-----------------+ Starting sshd. Refer to for more information about fingerprints and SSH. &os; does not install a graphical environment by default. Refer to for more information about installing and configuring a graphical window manager. Proper shutdown of a &os; computer helps protect data and hardware from damage. Do not turn off the power before the system has been properly shut down! If the user is a member of the wheel group, become the superuser by typing su at the command line and entering the root password. Then, type shutdown -p now and the system will shut down cleanly, and if the hardware supports it, turn itself off.
Network Interfaces Configuring Network Interfaces Next, a list of the network interfaces found on the computer is shown. Select the interface to configure.
Choose a Network Interface
If an Ethernet interface is selected, the installer will skip ahead to the menu shown in . If a wireless network interface is chosen, the system will instead scan for wireless access points:
Scanning for Wireless Access Points
Wireless networks are identified by a Service Set Identifier (SSID), a short, unique name given to each network. SSIDs found during the scan are listed, followed by a description of the encryption types available for that network. If the desired SSID does not appear in the list, select [ Rescan ] to scan again. If the desired network still does not appear, check for problems with antenna connections or try moving the computer closer to the access point. Rescan after each change is made.
Choosing a Wireless Network
Next, enter the encryption information for connecting to the selected wireless network. WPA2 encryption is strongly recommended as older encryption types, like WEP, offer little security. If the network uses WPA2, input the password, also known as the Pre-Shared Key (PSK). For security reasons, the characters typed into the input box are displayed as asterisks.
WPA2 Setup
Next, choose whether or not an IPv4 address should be configured on the Ethernet or wireless interface:
Choose <acronym>IPv4</acronym> Networking
There are two methods of IPv4 configuration. DHCP will automatically configure the network interface correctly and should be used if the network provides a DHCP server. Otherwise, the addressing information needs to be input manually as a static configuration. Do not enter random network information as it will not work. If a DHCP server is not available, obtain the information listed in from the network administrator or Internet service provider. If a DHCP server is available, select [ Yes ] in the next menu to automatically configure the network interface. The installer will appear to pause for a minute or so as it finds the DHCP server and obtains the addressing information for the system.
Choose <acronym>IPv4</acronym> <acronym>DHCP</acronym> Configuration
If a DHCP server is not available, select [ No ] and input the following addressing information in this menu:
<acronym>IPv4</acronym> Static Configuration
IP Address - The IPv4 address assigned to this computer. The address must be unique and not already in use by another piece of equipment on the local network. Subnet Mask - The subnet mask for the network. Default Router - The IP address of the network's default gateway. The next screen will ask if the interface should be configured for IPv6. If IPv6 is available and desired, choose [ Yes ] to select it.
Choose IPv6 Networking
IPv6 also has two methods of configuration. StateLess Address AutoConfiguration (SLAAC) will automatically request the correct configuration information from a local router. Refer to rfc4862 for more information. Static configuration requires manual entry of network information. If an IPv6 router is available, select [ Yes ] in the next menu to automatically configure the network interface. The installer will appear to pause for a minute or so as it finds the router and obtains the addressing information for the system.
Choose IPv6 SLAAC Configuration
If an IPv6 router is not available, select [ No ] and input the following addressing information in this menu:
IPv6 Static Configuration
IPv6 Address - The IPv6 address assigned to this computer. The address must be unique and not already in use by another piece of equipment on the local network. Default Router - The IPv6 address of the network's default gateway. The last network configuration menu is used to configure the Domain Name System (DNS) resolver, which converts hostnames to and from network addresses. If DHCP or SLAAC was used to autoconfigure the network interface, the Resolver Configuration values may already be filled in. Otherwise, enter the local network's domain name in the Search field. DNS #1 and DNS #2 are the IPv4 and/or IPv6 addresses of the DNS servers. At least one DNS server is required.
DNS Configuration
Once the interface is configured, select a mirror site that is located in the same region of the world as the computer on which &os; is being installed. Files can be retrieved more quickly when the mirror is close to the target computer, reducing installation time.
Choosing a Mirror
Troubleshooting installation troubleshooting This section covers basic installation troubleshooting, such as common problems people have reported. Check the Hardware Notes (https://www.freebsd.org/releases/index.html) document for the version of &os; to make sure the hardware is supported. If the hardware is supported and lock-ups or other problems occur, build a custom kernel using the instructions in to add support for devices which are not present in the GENERIC kernel. The default kernel assumes that most hardware devices are in their factory default configuration in terms of IRQs, I/O addresses, and DMA channels. If the hardware has been reconfigured, a custom kernel configuration file can tell &os; where to find things. Some installation problems can be avoided or alleviated by updating the firmware on various hardware components, most notably the motherboard. Motherboard firmware is usually referred to as the BIOS. Most motherboard and computer manufacturers have a website for upgrades and upgrade information. Manufacturers generally advise against upgrading the motherboard BIOS unless there is a good reason for doing so, like a critical update. The upgrade process can go wrong, leaving the BIOS incomplete and the computer inoperative. If the system hangs while probing hardware during boot, or it behaves strangely during install, ACPI may be the culprit. &os; makes extensive use of the system ACPI service on the &arch.i386; and &arch.amd64; platforms to aid in system configuration if it is detected during boot. Unfortunately, some bugs still exist in both the ACPI driver and within system motherboards and BIOS firmware. ACPI can be disabled by setting the hint.acpi.0.disabled hint in the third stage boot loader: set hint.acpi.0.disabled="1" This is reset each time the system is booted, so it is necessary to add hint.acpi.0.disabled="1" to the file /boot/loader.conf. More information about the boot loader can be found in . Using the Live <acronym>CD</acronym> The welcome menu of bsdinstall, shown in , provides a [ Live CD ] option. This is useful for those who are still wondering whether &os; is the right operating system for them and want to test some of the features before installing. The following points should be noted before using the [ Live CD ]: To gain access to the system, authentication is required. The username is root and the password is blank. As the system runs directly from the installation media, performance will be significantly slower than that of a system installed on a hard disk. This option only provides a command prompt and not a graphical interface.
diff --git a/en_US.ISO8859-1/books/handbook/desktop/chapter.xml b/en_US.ISO8859-1/books/handbook/desktop/chapter.xml index 9daff7a2f3..9fbd69a5dc 100644 --- a/en_US.ISO8859-1/books/handbook/desktop/chapter.xml +++ b/en_US.ISO8859-1/books/handbook/desktop/chapter.xml @@ -1,919 +1,920 @@ Desktop Applications Synopsis While &os; is popular as a server for its performance and stability, it is also suited for day-to-day use as a desktop. With over &os.numports; applications available as &os; packages or ports, it is easy to build a customized desktop that runs a wide variety of desktop applications. This chapter demonstrates how to install numerous desktop applications, including web browsers, productivity software, document viewers, and financial software. Users who prefer to install a pre-built desktop version of FreeBSD rather than configuring one from scratch should refer to FuryBSD, - GhostBSD or + xlink:href="https://ghostbsd.org">GhostBSD, MidnightBSD. + xlink:href="https://www.midnightbsd.org">MidnightBSD + or NomadBSD. Readers of this chapter should know how to: Install additional software using packages or ports as described in . Install X and a window manager as described in . For information on how to configure a multimedia environment, refer to . Browsers browsers web &os; does not come with a pre-installed web browser. Instead, the www category of the Ports Collection contains many browsers which can be installed as a package or compiled from the Ports Collection. The KDE and GNOME desktop environments include their own HTML browser. Refer to for more information on how to set up these complete desktops. Some lightweight browsers include www/dillo2, www/links, and www/w3m. This section demonstrates how to install the following popular web browsers and indicates if the application is resource-heavy, takes time to compile from ports, or has any major dependencies. Application Name Resources Needed Installation from Ports Notes Firefox medium heavy &os;, &linux;, and localized versions are available Konqueror medium heavy Requires KDE libraries Chromium medium heavy Requires Gtk+ Firefox Firefox Firefox is an open source browser that features a standards-compliant HTML display engine, tabbed browsing, popup blocking, extensions, improved security, and more. Firefox is based on the Mozilla codebase. To install the package of the latest release version of Firefox, type: &prompt.root; pkg install firefox To instead install Firefox Extended Support Release (ESR) version, use: &prompt.root; pkg install firefox-esr The Ports Collection can instead be used to compile the desired version of Firefox from source code. This example builds www/firefox, where firefox can be replaced with the ESR or localized version to install. &prompt.root; cd /usr/ports/www/firefox &prompt.root; make install clean Konqueror Konqueror Konqueror is more than a web browser as it is also a file manager and a multimedia viewer. Supports WebKit as well as its own KHTML. WebKit is a rendering engine used by many modern browsers including Chromium. Konqueror can be installed as a package by typing: &prompt.root; pkg install konqueror To install from the Ports Collection: &prompt.root; cd /usr/ports/x11-fm/konqueror/ &prompt.root; make install clean Chromium Chromium Chromium is an open source browser project that aims to build a safer, faster, and more stable web browsing experience. Chromium features tabbed browsing, popup blocking, extensions, and much more. Chromium is the open source project upon which the Google Chrome web browser is based. Chromium can be installed as a package by typing: &prompt.root; pkg install chromium Alternatively, Chromium can be compiled from source using the Ports Collection: &prompt.root; cd /usr/ports/www/chromium &prompt.root; make install clean The executable for Chromium is /usr/local/bin/chrome, not /usr/local/bin/chromium. Productivity When it comes to productivity, users often look for an office suite or an easy-to-use word processor. While some desktop environments like KDE provide an office suite, there is no default productivity package. Several office suites and graphical word processors are available for &os;, regardless of the installed window manager. This section demonstrates how to install the following popular productivity software and indicates if the application is resource-heavy, takes time to compile from ports, or has any major dependencies. Application Name Resources Needed Installation from Ports Major Dependencies Calligra light heavy KDE AbiWord light light Gtk+ or GNOME The Gimp light heavy Gtk+ Apache OpenOffice heavy huge &jdk; and Mozilla LibreOffice somewhat heavy huge Gtk+, or KDE/ GNOME, or &jdk; Calligra Calligra office suite Calligra The KDE desktop environment includes an office suite which can be installed separately from KDE. Calligra includes standard components that can be found in other office suites. Words is the word processor, Sheets is the spreadsheet program, Stage manages slide presentations, and Karbon is used to draw graphical documents. In &os;, editors/calligra can be installed as a package or a port. To install the package: &prompt.root; pkg install calligra If the package is not available, use the Ports Collection instead: &prompt.root; cd /usr/ports/editors/calligra &prompt.root; make install clean AbiWord AbiWord AbiWord is a free word processing program similar in look and feel to µsoft; Word. It is fast, contains many features, and is user-friendly. AbiWord can import or export many file formats, including some proprietary ones like µsoft; .rtf. To install the AbiWord package: &prompt.root; pkg install abiword If the package is not available, it can be compiled from the Ports Collection: &prompt.root; cd /usr/ports/editors/abiword &prompt.root; make install clean The GIMP The GIMP For image authoring or picture retouching, The GIMP provides a sophisticated image manipulation program. It can be used as a simple paint program or as a quality photo retouching suite. It supports a large number of plugins and features a scripting interface. The GIMP can read and write a wide range of file formats and supports interfaces with scanners and tablets. To install the package: &prompt.root; pkg install gimp Alternately, use the Ports Collection: &prompt.root; cd /usr/ports/graphics/gimp &prompt.root; make install clean The graphics category (freebsd.org/ports/graphics.html) of the Ports Collection contains several GIMP-related plugins, help files, and user manuals. Apache OpenOffice Apache OpenOffice office suite Apache OpenOffice Apache OpenOffice is an open source office suite which is developed under the wing of the Apache Software Foundation's Incubator. It includes all of the applications found in a complete office productivity suite: a word processor, spreadsheet, presentation manager, and drawing program. Its user interface is similar to other office suites, and it can import and export in various popular file formats. It is available in a number of different languages and internationalization has been extended to interfaces, spell checkers, and dictionaries. The word processor of Apache OpenOffice uses a native XML file format for increased portability and flexibility. The spreadsheet program features a macro language which can be interfaced with external databases. Apache OpenOffice is stable and runs natively on &windows;, &solaris;, &linux;, &os;, and &macos; X. More information about Apache OpenOffice can be found at openoffice.org. For &os; specific information refer to porting.openoffice.org/freebsd/. To install the Apache OpenOffice package: &prompt.root; pkg install apache-openoffice Once the package is installed, type the following command to launch Apache OpenOffice: &prompt.user; openoffice-X.Y.Z where X.Y.Z is the version number of the installed version of Apache OpenOffice. The first time Apache OpenOffice launches, some questions will be asked and a .openoffice.org folder will be created in the user's home directory. If the desired Apache OpenOffice package is not available, compiling the port is still an option. However, this requires a lot of disk space and a fairly long time to compile: &prompt.root; cd /usr/ports/editors/openoffice-4 &prompt.root; make install clean To build a localized version, replace the previous command with: &prompt.root; make LOCALIZED_LANG=your_language install clean Replace your_language with the correct language ISO-code. A list of supported language codes is available in files/Makefile.localized, located in the port's directory. LibreOffice LibreOffice office suite LibreOffice LibreOffice is a free software office suite developed by documentfoundation.org. It is compatible with other major office suites and available on a variety of platforms. It is a rebranded fork of Apache OpenOffice and includes applications found in a complete office productivity suite: a word processor, spreadsheet, presentation manager, drawing program, database management program, and a tool for creating and editing mathematical formulæ. It is available in a number of different languages and internationalization has been extended to interfaces, spell checkers, and dictionaries. The word processor of LibreOffice uses a native XML file format for increased portability and flexibility. The spreadsheet program features a macro language which can be interfaced with external databases. LibreOffice is stable and runs natively on &windows;, &linux;, &os;, and &macos; X. More information about LibreOffice can be found at libreoffice.org. To install the English version of the LibreOffice package: &prompt.root; pkg install libreoffice The editors category (freebsd.org/ports/editors.html) of the Ports Collection contains several localizations for LibreOffice. When installing a localized package, replace libreoffice with the name of the localized package. Once the package is installed, type the following command to run LibreOffice: &prompt.user; libreoffice During the first launch, some questions will be asked and a .libreoffice folder will be created in the user's home directory. If the desired LibreOffice package is not available, compiling the port is still an option. However, this requires a lot of disk space and a fairly long time to compile. This example compiles the English version: &prompt.root; cd /usr/ports/editors/libreoffice &prompt.root; make install clean To build a localized version, cd into the port directory of the desired language. Supported languages can be found in the editors category (freebsd.org/ports/editors.html) of the Ports Collection. Document Viewers Some new document formats have gained popularity since the advent of &unix; and the viewers they require may not be available in the base system. This section demonstrates how to install the following document viewers: Application Name Resources Needed Installation from Ports Major Dependencies Xpdf light light FreeType gv light light Xaw3d Geeqie light light Gtk+ or GNOME ePDFView light light Gtk+ Okular light heavy KDE Xpdf Xpdf PDF viewing For users that prefer a small &os; PDF viewer, Xpdf provides a light-weight and efficient viewer which requires few resources. It uses the standard X fonts and does not require any additional toolkits. To install the Xpdf package: &prompt.root; pkg install xpdf If the package is not available, use the Ports Collection: &prompt.root; cd /usr/ports/graphics/xpdf &prompt.root; make install clean Once the installation is complete, launch xpdf and use the right mouse button to activate the menu. <application>gv</application> gv PDF viewing PostScript viewing gv is a &postscript; and PDF viewer. It is based on ghostview, but has a nicer look as it is based on the Xaw3d widget toolkit. gv has many configurable features, such as orientation, paper size, scale, and anti-aliasing. Almost any operation can be performed with either the keyboard or the mouse. To install gv as a package: &prompt.root; pkg install gv If a package is unavailable, use the Ports Collection: &prompt.root; cd /usr/ports/print/gv &prompt.root; make install clean Geeqie Geeqie Geeqie is a fork from the unmaintained GQView project, in an effort to move development forward and integrate the existing patches. Geeqie is an image manager which supports viewing a file with a single click, launching an external editor, and thumbnail previews. It also features a slideshow mode and some basic file operations, making it easy to manage image collections and to find duplicate files. Geeqie supports full screen viewing and internationalization. To install the Geeqie package: &prompt.root; pkg install geeqie If the package is not available, use the Ports Collection: &prompt.root; cd /usr/ports/graphics/geeqie &prompt.root; make install clean ePDFView ePDFView PDF viewing ePDFView is a lightweight PDF document viewer that only uses the Gtk+ and Poppler libraries. It is currently under development, but already opens most PDF files (even encrypted), save copies of documents, and has support for printing using CUPS. To install ePDFView as a package: &prompt.root; pkg install epdfview If a package is unavailable, use the Ports Collection: &prompt.root; cd /usr/ports/graphics/epdfview &prompt.root; make install clean Okular Okular PDF viewing Okular is a universal document viewer based on KPDF for KDE. It can open many document formats, including PDF, &postscript;, DjVu, CHM, XPS, and ePub. To install Okular as a package: &prompt.root; pkg install okular If a package is unavailable, use the Ports Collection: &prompt.root; cd /usr/ports/graphics/okular &prompt.root; make install clean Finance For managing personal finances on a &os; desktop, some powerful and easy-to-use applications can be installed. Some are compatible with widespread file formats, such as the formats used by Quicken and Excel. This section covers these programs: Application Name Resources Needed Installation from Ports Major Dependencies GnuCash light heavy GNOME Gnumeric light heavy GNOME KMyMoney light heavy KDE GnuCash GnuCash GnuCash is part of the GNOME effort to provide user-friendly, yet powerful, applications to end-users. GnuCash can be used to keep track of income and expenses, bank accounts, and stocks. It features an intuitive interface while remaining professional. GnuCash provides a smart register, a hierarchical system of accounts, and many keyboard accelerators and auto-completion methods. It can split a single transaction into several more detailed pieces. GnuCash can import and merge Quicken QIF files. It also handles most international date and currency formats. To install the GnuCash package: &prompt.root; pkg install gnucash If the package is not available, use the Ports Collection: &prompt.root; cd /usr/ports/finance/gnucash &prompt.root; make install clean Gnumeric Gnumeric spreadsheet Gnumeric Gnumeric is a spreadsheet program developed by the GNOME community. It features convenient automatic guessing of user input according to the cell format with an autofill system for many sequences. It can import files in a number of popular formats, including Excel, Lotus 1-2-3, and Quattro Pro. It has a large number of built-in functions and allows all of the usual cell formats such as number, currency, date, time, and much more. To install Gnumeric as a package: &prompt.root; pkg install gnumeric If the package is not available, use the Ports Collection: &prompt.root; cd /usr/ports/math/gnumeric &prompt.root; make install clean KMyMoney KMyMoney spreadsheet KMyMoney KMyMoney is a personal finance application created by the KDE community. KMyMoney aims to provide the important features found in commercial personal finance manager applications. It also highlights ease-of-use and proper double-entry accounting among its features. KMyMoney imports from standard Quicken QIF files, tracks investments, handles multiple currencies, and provides a wealth of reports. To install KMyMoney as a package: &prompt.root; pkg install kmymoney-kde4 If the package is not available, use the Ports Collection: &prompt.root; cd /usr/ports/finance/kmymoney-kde4 &prompt.root; make install clean diff --git a/en_US.ISO8859-1/books/handbook/introduction/chapter.xml b/en_US.ISO8859-1/books/handbook/introduction/chapter.xml index 34fec5a301..0df8e1f8ec 100644 --- a/en_US.ISO8859-1/books/handbook/introduction/chapter.xml +++ b/en_US.ISO8859-1/books/handbook/introduction/chapter.xml @@ -1,1162 +1,1162 @@ Introduction Jim Mock Restructured, reorganized, and parts rewritten by Synopsis Thank you for your interest in &os;! The following chapter covers various aspects of the &os; Project, such as its history, goals, development model, and so on. After reading this chapter you will know: How &os; relates to other computer operating systems. The history of the &os; Project. The goals of the &os; Project. The basics of the &os; open-source development model. And of course: where the name &os; comes from. Welcome to &os;! 4.4BSD-Lite &os; is an Open Source, standards-compliant Unix-like operating system for x86 (both 32 and 64 bit), &arm;, AArch64, &risc-v;, &mips;, &power;, &powerpc;, and Sun &ultrasparc; computers. It provides all the features that are nowadays taken for granted, such as preemptive multitasking, memory protection, virtual memory, multi-user facilities, SMP support, all the Open Source development tools for different languages and frameworks, and desktop features centered around X Window System, KDE, or GNOME. Its particular strengths are: Liberal Open Source license, which grants you rights to freely modify and extend its source code and incorporate it in both Open Source projects and closed products without imposing restrictions typical to copyleft licenses, as well as avoiding potential license incompatibility problems. Strong TCP/IP networking TCP/IP networking - &os; implements industry standard protocols with ever increasing performance and scalability. This makes it a good match in both server, and routing/firewalling roles - and indeed many companies and vendors use it precisely for that purpose. Fully integrated OpenZFS support, including root-on-ZFS, ZFS Boot Environments, fault management, administrative delegation, support for jails, &os; specific documentation, and system installer support. Extensive security features, from the Mandatory Access Control framework to Capsicum capability and sandbox mechanisms. Over 30 thousand prebuilt packages for all supported architectures, and the Ports Collection which makes it easy to build your own, customized ones. Documentation - in addition to Handbook and books from different authors that cover topics ranging from system administration to kernel internals, there are also the &man.man.1; pages, not only for userspace daemons, utilities, and configuration files, but also for kernel driver APIs (section 9) and individual drivers (section 4). Simple and consistent repository structure and build system - &os; uses a single repository for all of its components, both kernel and userspace. This, along with an unified and easy to customize build system and a well thought out development process makes it easy to integrate &os; with build infrastructure for your own product. Staying true to Unix philosophy, preferring composability instead of monolithic all in one daemons with hardcoded behavior. binary compatibility Linux Binary compatibility with Linux, which makes it possible to run many Linux binaries without the need for virtualisation. &os; is based on the 4.4BSD-Lite 4.4BSD-Lite release from Computer Systems Research Group (CSRG) Computer Systems Research Group (CSRG) at the University of California at Berkeley, and carries on the distinguished tradition of BSD systems development. In addition to the fine work provided by CSRG, the &os; Project has put in many thousands of man-hours into extending the functionality and fine-tuning the system for maximum performance and reliability in real-life load situations. &os; offers performance and reliability on par with other Open Source and commercial offerings, combined with cutting-edge features not available anywhere else. What Can &os; Do? The applications to which &os; can be put are truly limited only by your own imagination. From software development to factory automation, inventory control to azimuth correction of remote satellite antennae; if it can be done with a commercial &unix; product then it is more than likely that you can do it with &os; too! &os; also benefits significantly from literally thousands of high quality applications developed by research centers and universities around the world, often available at little to no cost. Because the source code for &os; itself is freely available, the system can also be customized to an almost unheard of degree for special applications or projects, and in ways not generally possible with operating systems from most major commercial vendors. Here is just a sampling of some of the applications in which people are currently using &os;: Internet Services: The robust TCP/IP networking built into &os; makes it an ideal platform for a variety of Internet services such as: Web servers IPv4 and IPv6 routing Firewalls firewall and NAT NAT (IP masquerading) gateways FTP servers FTP servers electronic mail email email Email servers And more... Education: Are you a student of computer science or a related engineering field? There is no better way of learning about operating systems, computer architecture and networking than the hands on, under the hood experience that &os; can provide. A number of freely available CAD, mathematical and graphic design packages also make it highly useful to those whose primary interest in a computer is to get other work done! Research: With source code for the entire system available, &os; is an excellent platform for research in operating systems as well as other branches of computer science. &os;'s freely available nature also makes it possible for remote groups to collaborate on ideas or shared development without having to worry about special licensing agreements or limitations on what may be discussed in open forums. Networking: Need a new router? router A name server (DNS)? DNS Server A firewall to keep people out of your internal network? &os; can easily turn that unused PC sitting in the corner into an advanced router with sophisticated packet-filtering capabilities. Embedded: &os; makes an excellent platform to build embedded systems upon. embedded With support for the &arm;, &mips; and &powerpc; platforms, coupled with a robust network stack, cutting edge features and the permissive BSD license &os; makes an excellent foundation for building embedded routers, firewalls, and other devices. X Window System GNOME KDE Desktop: &os; makes a fine choice for an inexpensive desktop solution using the freely available X11 server. &os; offers a choice from many open-source desktop environments, including the standard GNOME and KDE graphical user interfaces. &os; can even boot diskless from a central server, making individual workstations even cheaper and easier to administer. Software Development: The basic &os; system comes with a full suite of development tools including a full C/C++ Compiler compiler and debugger suite. Support for many other languages are also available through the ports and packages collection. &os; is available to download free of charge, or can be obtained on either CD-ROM or DVD. Please see for more information about obtaining &os;. Who Uses &os;? users large sites running &os; &os; has been known for its web serving capabilities - sites that run on &os; include Hacker News, Netcraft, NetEase, Netflix, Sina, Sony Japan, Rambler, Yahoo!, and Yandex. &os;'s advanced features, proven security, predictable release cycle, and permissive license have led to its use as a platform for building many commercial and open source appliances, devices, and products. Many of the world's largest IT companies use &os;: Apache Apache - The Apache Software Foundation runs most of its public facing infrastructure, including possibly one of the largest SVN repositories in the world with over 1.4 million commits, on &os;. Apple Apple - OS X borrows heavily from &os; for the network stack, virtual file system, and many userland components. Apple iOS also contains elements borrowed from &os;. Cisco Cisco - IronPort network security and anti-spam appliances run a modified &os; kernel. Citrix Citrix - The NetScaler line of security appliances provide layer 4-7 load balancing, content caching, application firewall, secure VPN, and mobile cloud network access, along with the power of a &os; shell. Dell EMC Isilon Isilon - Isilon's enterprise storage appliances are based on &os;. The extremely liberal &os; license allowed Isilon to integrate their intellectual property throughout the kernel and focus on building their product instead of an operating system. Quest KACE Quest KACE - The KACE system management appliances run &os; because of its reliability, scalability, and the community that supports its continued development. iXsystems iXsystems - The TrueNAS line of unified storage appliances is based on &os;. In addition to their commercial products, iXsystems also manages development of the open source projects TrueOS and FreeNAS. Juniper Juniper - The JunOS operating system that powers all Juniper networking gear (including routers, switches, security, and networking appliances) is based on &os;. Juniper is one of many vendors that showcases the symbiotic relationship between the project and vendors of commercial products. Improvements generated at Juniper are upstreamed into &os; to reduce the complexity of integrating new features from &os; back into JunOS in the future. McAfee McAfee - SecurOS, the basis of McAfee enterprise firewall products including Sidewinder is based on &os;. NetApp NetApp - The Data ONTAP GX line of storage appliances are based on &os;. In addition, NetApp has contributed back many features, including the new BSD licensed hypervisor, bhyve. Netflix Netflix - The OpenConnect appliance that Netflix uses to stream movies to its customers is based on &os;. Netflix has made extensive contributions to the codebase and works to maintain a zero delta from mainline &os;. Netflix OpenConnect appliances are responsible for delivering more than 32% of all Internet traffic in North America. Sandvine Sandvine - Sandvine uses &os; as the basis of their high performance real-time network processing platforms that make up their intelligent network policy control products. Sony Sony - The PlayStation 4 gaming console runs a modified version of &os;. Sophos Sophos - The Sophos Email Appliance product is based on a hardened &os; and scans inbound mail for spam and viruses, while also monitoring outbound mail for malware as well as the accidental loss of sensitive information. Spectra Logic Spectra Logic - The nTier line of archive grade storage appliances run &os; and OpenZFS. Stormshield Stormshield - Stormshield Network Security appliances are based on a hardened version of &os;. The BSD license allows them to integrate their own intellectual property with the system while returning a great deal of interesting development to the community. The Weather Channel The Weather Channel - The IntelliStar appliance that is installed at each local cable provider's headend and is responsible for injecting local weather forecasts into the cable TV network's programming runs &os;. Verisign Verisign - Verisign is responsible for operating the .com and .net root domain registries as well as the accompanying DNS infrastructure. They rely on a number of different network operating systems including &os; to ensure there is no common point of failure in their infrastructure. Voxer Voxer - Voxer powers their mobile voice messaging platform with ZFS on &os;. Voxer switched from a Solaris derivative to &os; because of its superior documentation, larger and more active community, and more developer friendly environment. In addition to critical features like ZFS and DTrace, &os; also offers TRIM support for ZFS. Fudo Security Fudo Security - The FUDO security appliance allows enterprises to monitor, control, record, and audit contractors and administrators who work on their systems. Based on all of the best security features of &os; including ZFS, GELI, Capsicum, HAST, and auditdistd. &os; has also spawned a number of related open source projects: BSD Router BSD Router - A &os; based replacement for large enterprise routers designed to run on standard PC hardware. FreeNAS FreeNAS - A customized &os; designed to be used as a network file server appliance. Provides a python based web interface to simplify the management of both the UFS and ZFS file systems. Includes support for NFS, SMB/CIFS, AFP, FTP, and iSCSI. Includes an extensible plugin system based on &os; jails. GhostBSD GhostBSD - is derived from &os;, uses the GTK environment to provide a beautiful looks and comfortable experience on the modern BSD platform offering a natural and native &unix; work environment. mfsBSD mfsBSD - A toolkit for building a &os; system image that runs entirely from memory. NAS4Free NAS4Free - A file server distribution based on &os; with a PHP powered web interface. OPNSense OPNsense - OPNsense is an open source, easy-to-use and easy-to-build FreeBSD based firewall and routing platform. OPNsense includes most of the features available in expensive commercial firewalls, and more in many cases. It brings the rich feature set of commercial offerings with the benefits of open and verifiable sources. TrueOS TrueOS - TrueOS is based on the legendary security and stability of &os;. TrueOS follows &os;-CURRENT, with the latest drivers, security updates, and packages available. - - FuryBSD - - FuryBSD - - is a brand new, open source &os; desktop. - FuryBSD pays homage to desktop BSD projects of the past - like PC-BSD and TrueOS with its graphical interface and - adds additional tools like a live, hybrid USB/DVD image. - FuryBSD is completely free to use and distributed under - the BSD license. - - MidnightBSD MidnightBSD - is a &os; derived operating system developed with desktop users in mind. It includes all the software you'd expect for your daily tasks: mail, web browsing, word processing, gaming, and much more. + + NomadBSD + + NomadBSD + - is a persistent live system for USB flash + drives, based on &os;. Together with automatic hardware + detection and setup, it is configured to be used as a + desktop system that works out of the box, but can also be + used for data recovery, for educational purposes, or to + test &os;'s hardware compatibility. + + pfSense pfSense - A firewall distribution based on &os; with a huge array of features and extensive IPv6 support. ZRouter ZRouter - An open source alternative firmware for embedded devices based on &os;. Designed to replace the proprietary firmware on off-the-shelf routers. A list of testimonials from companies basing their products and services on &os; can be found at the FreeBSD Foundation website. Wikipedia also maintains a list of products based on &os;. About the &os; Project The following section provides some background information on the project, including a brief history, project goals, and the development model of the project. A Brief History of &os; 386BSD Patchkit Hubbard, Jordan Williams, Nate Grimes, Rod FreeBSD Project history The &os; Project had its genesis in the early part of 1993, partially as the brainchild of the Unofficial 386BSDPatchkit's last 3 coordinators: Nate Williams, Rod Grimes and Jordan Hubbard. 386BSD The original goal was to produce an intermediate snapshot of 386BSD in order to fix a number of problems that the patchkit mechanism was just not capable of solving. The early working title for the project was 386BSD 0.5 or 386BSD Interim in reference of that fact. Jolitz, Bill 386BSD was Bill Jolitz's operating system, which had been up to that point suffering rather severely from almost a year's worth of neglect. As the patchkit swelled ever more uncomfortably with each passing day, they decided to assist Bill by providing this interim cleanup snapshot. Those plans came to a rude halt when Bill Jolitz suddenly decided to withdraw his sanction from the project without any clear indication of what would be done instead. Greenman, David Walnut Creek CDROM The trio thought that the goal remained worthwhile, even without Bill's support, and so they adopted the name "&os;" coined by David Greenman. The initial objectives were set after consulting with the system's current users and, once it became clear that the project was on the road to perhaps even becoming a reality, Jordan contacted Walnut Creek CDROM with an eye toward improving &os;'s distribution channels for those many unfortunates without easy access to the Internet. Walnut Creek CDROM not only supported the idea of distributing &os; on CD but also went so far as to provide the project with a machine to work on and a fast Internet connection. Without Walnut Creek CDROM's almost unprecedented degree of faith in what was, at the time, a completely unknown project, it is quite unlikely that &os; would have gotten as far, as fast, as it has today. 4.3BSD-Lite Net/2 U.C. Berkeley 386BSD Free Software Foundation The first CD-ROM (and general net-wide) distribution was &os; 1.0, released in December of 1993. This was based on the 4.3BSD-Lite (Net/2) tape from U.C. Berkeley, with many components also provided by 386BSD and the Free Software Foundation. It was a fairly reasonable success for a first offering, and they followed it with the highly successful &os; 1.1 release in May of 1994. Novell U.C. Berkeley Net/2 AT&T Around this time, some rather unexpected storm clouds formed on the horizon as Novell and U.C. Berkeley settled their long-running lawsuit over the legal status of the Berkeley Net/2 tape. A condition of that settlement was U.C. Berkeley's concession that large parts of Net/2 were encumbered code and the property of Novell, who had in turn acquired it from AT&T some time previously. What Berkeley got in return was Novell's blessing that the 4.4BSD-Lite release, when it was finally released, would be declared unencumbered and all existing Net/2 users would be strongly encouraged to switch. This included &os;, and the project was given until the end of July 1994 to stop shipping its own Net/2 based product. Under the terms of that agreement, the project was allowed one last release before the deadline, that release being &os; 1.1.5.1. &os; then set about the arduous task of literally re-inventing itself from a completely new and rather incomplete set of 4.4BSD-Lite bits. The Lite releases were light in part because Berkeley's CSRG had removed large chunks of code required for actually constructing a bootable running system (due to various legal requirements) and the fact that the Intel port of 4.4 was highly incomplete. It took the project until November of 1994 to make this transition, and in December it released &os; 2.0 to the world. Despite being still more than a little rough around the edges, the release was a significant success and was followed by the more robust and easier to install &os; 2.0.5 release in June of 1995. Since that time, &os; has made a series of releases each time improving the stability, speed, and feature set of the previous version. For now, long-term development projects continue to take place in the 10.X-CURRENT (trunk) branch, and snapshot releases of 10.X are continually made available from the snapshot server as work progresses. &os; Project Goals Jordan Hubbard Contributed by FreeBSD Project goals The goals of the &os; Project are to provide software that may be used for any purpose and without strings attached. Many of us have a significant investment in the code (and project) and would certainly not mind a little financial compensation now and then, but we are definitely not prepared to insist on it. We believe that our first and foremost mission is to provide code to any and all comers, and for whatever purpose, so that the code gets the widest possible use and provides the widest possible benefit. This is, I believe, one of the most fundamental goals of Free Software and one that we enthusiastically support. GNU General Public License (GPL) GNU Lesser General Public License (LGPL) BSD Copyright That code in our source tree which falls under the GNU General Public License (GPL) or Library General Public License (LGPL) comes with slightly more strings attached, though at least on the side of enforced access rather than the usual opposite. Due to the additional complexities that can evolve in the commercial use of GPL software we do, however, prefer software submitted under the more relaxed BSD license when it is a reasonable option to do so. The &os; Development Model Satoshi Asami Contributed by FreeBSD Project development model The development of &os; is a very open and flexible process, being literally built from the contributions of thousands of people around the world, as can be seen from our list of contributors. &os;'s development infrastructure allow these thousands of contributors to collaborate over the Internet. We are constantly on the lookout for new developers and ideas, and those interested in becoming more closely involved with the project need simply contact us at the &a.hackers;. The &a.announce; is also available to those wishing to make other &os; users aware of major areas of work. Useful things to know about the &os; Project and its development process, whether working independently or in close cooperation: The SVN repositories CVS CVS Repository Concurrent Versions System CVS Subversion Subversion Repository SVN Subversion For several years, the central source tree for &os; was maintained by CVS (Concurrent Versions System), a freely available source code control tool. In June 2008, the Project switched to using SVN (Subversion). The switch was deemed necessary, as the technical limitations imposed by CVS were becoming obvious due to the rapid expansion of the source tree and the amount of history already stored. The Documentation Project and Ports Collection repositories also moved from CVS to SVN in May 2012 and July 2012, respectively. Please refer to the Obtaining the Source section for more information on obtaining the &os; src/ repository and Using the Ports Collection for details on obtaining the &os; Ports Collection. The committers list The committers committers are the people who have write access to the Subversion tree, and are authorized to make modifications to the &os; source (the term committer comes from commit, the source control command which is used to bring new changes into the repository). Anyone can submit a bug to the Bug Database. Before submitting a bug report, the &os; mailing lists, IRC channels, or forums can be used to help verify that an issue is actually a bug. The FreeBSD core team The &os; core team core team would be equivalent to the board of directors if the &os; Project were a company. The primary task of the core team is to make sure the project, as a whole, is in good shape and is heading in the right directions. Inviting dedicated and responsible developers to join our group of committers is one of the functions of the core team, as is the recruitment of new core team members as others move on. The current core team was elected from a pool of committer candidates in June 2020. Elections are held every 2 years. Like most developers, most members of the core team are also volunteers when it comes to &os; development and do not benefit from the project financially, so commitment should also not be misconstrued as meaning guaranteed support. The board of directors analogy above is not very accurate, and it may be more suitable to say that these are the people who gave up their lives in favor of &os; against their better judgement! Outside contributors Last, but definitely not least, the largest group of developers are the users themselves who provide feedback and bug fixes to us on an almost constant basis. The primary way of keeping in touch with &os;'s more non-centralized development is to subscribe to the &a.hackers; where such things are discussed. See for more information about the various &os; mailing lists. The &os; Contributors List contributors is a long and growing one, so why not join it by contributing something back to &os; today? Providing code is not the only way of contributing to the project; for a more complete list of things that need doing, please refer to the &os; Project web site. In summary, our development model is organized as a loose set of concentric circles. The centralized model is designed for the convenience of the users of &os;, who are provided with an easy way of tracking one central code base, not to keep potential contributors out! Our desire is to present a stable operating system with a large set of coherent application programs that the users can easily install and use — this model works very well in accomplishing that. All we ask of those who would join us as &os; developers is some of the same dedication its current people have to its continued success! Third Party Programs In addition to the base distributions, &os; offers a ported software collection with thousands of commonly sought-after programs. At the time of this writing, there were over &os.numports; ports! The list of ports ranges from http servers, to games, languages, editors, and almost everything in between. The entire Ports Collection requires approximately &ports.size;. To compile a port, you simply change to the directory of the program you wish to install, type make install, and let the system do the rest. The full original distribution for each port you build is retrieved dynamically so you need only enough disk space to build the ports you want. Almost every port is also provided as a pre-compiled package, which can be installed with a simple command (pkg install) by those who do not wish to compile their own ports from source. More information on packages and ports can be found in . Additional Documentation All supported &os; versions provide an option in the installer to install additional documentation under /usr/local/share/doc/freebsd during the initial system setup. Documentation may also be installed at any later time using packages as described in . You may view the locally installed manuals with any HTML capable browser using the following URLs: The FreeBSD Handbook /usr/local/share/doc/freebsd/handbook/index.html The FreeBSD FAQ /usr/local/share/doc/freebsd/faq/index.html You can also view the master (and most frequently updated) copies at https://www.FreeBSD.org/. diff --git a/en_US.ISO8859-1/books/handbook/x11/chapter.xml b/en_US.ISO8859-1/books/handbook/x11/chapter.xml index 0ebd1bb20f..41c753186e 100644 --- a/en_US.ISO8859-1/books/handbook/x11/chapter.xml +++ b/en_US.ISO8859-1/books/handbook/x11/chapter.xml @@ -1,2226 +1,2228 @@ The X Window System Synopsis An installation of &os; using bsdinstall does not automatically install a graphical user interface. This chapter describes how to install and configure &xorg;, which provides the open source X Window System used to provide a graphical environment. It then describes how to find and install a desktop environment or window manager. Users who prefer an installation method that automatically configures the &xorg; should refer - to FuryBSD, - GhostBSD or + to GhostBSD, MidnightBSD. + xlink:href="https://www.midnightbsd.org">MidnightBSD + or + NomadBSD. For more information on the video hardware that &xorg; supports, refer to the x.org website. After reading this chapter, you will know: The various components of the X Window System, and how they interoperate. How to install and configure &xorg;. How to install and configure several window managers and desktop environments. How to use &truetype; fonts in &xorg;. How to set up your system for graphical logins (XDM). Before reading this chapter, you should: Know how to install additional third-party software as described in . Terminology While it is not necessary to understand all of the details of the various components in the X Window System and how they interact, some basic knowledge of these components can be useful. X server X was designed from the beginning to be network-centric, and adopts a client-server model. In this model, the X server runs on the computer that has the keyboard, monitor, and mouse attached. The server's responsibility includes tasks such as managing the display, handling input from the keyboard and mouse, and handling input or output from other devices such as a tablet or a video projector. This confuses some people, because the X terminology is exactly backward to what they expect. They expect the X server to be the big powerful machine down the hall, and the X client to be the machine on their desk. X client Each X application, such as XTerm or Firefox, is a client. A client sends messages to the server such as Please draw a window at these coordinates, and the server sends back messages such as The user just clicked on the OK button. In a home or small office environment, the X server and the X clients commonly run on the same computer. It is also possible to run the X server on a less powerful computer and to run the X applications on a more powerful system. In this scenario, the communication between the X client and server takes place over the network. window manager X does not dictate what windows should look like on-screen, how to move them around with the mouse, which keystrokes should be used to move between windows, what the title bars on each window should look like, whether or not they have close buttons on them, and so on. Instead, X delegates this responsibility to a separate window manager application. There are dozens of window managers available. Each window manager provides a different look and feel: some support virtual desktops, some allow customized keystrokes to manage the desktop, some have a Start button, and some are themeable, allowing a complete change of the desktop's look-and-feel. Window managers are available in the x11-wm category of the Ports Collection. Each window manager uses a different configuration mechanism. Some expect configuration file written by hand while others provide graphical tools for most configuration tasks. desktop environment KDE and GNOME are considered to be desktop environments as they include an entire suite of applications for performing common desktop tasks. These may include office suites, web browsers, and games. focus policy The window manager is responsible for the mouse focus policy. This policy provides some means for choosing which window is actively receiving keystrokes and it should also visibly indicate which window is currently active. One focus policy is called click-to-focus. In this model, a window becomes active upon receiving a mouse click. In the focus-follows-mouse policy, the window that is under the mouse pointer has focus and the focus is changed by pointing at another window. If the mouse is over the root window, then this window is focused. In the sloppy-focus model, if the mouse is moved over the root window, the most recently used window still has the focus. With sloppy-focus, focus is only changed when the cursor enters a new window, and not when exiting the current window. In the click-to-focus policy, the active window is selected by mouse click. The window may then be raised and appear in front of all other windows. All keystrokes will now be directed to this window, even if the cursor is moved to another window. Different window managers support different focus models. All of them support click-to-focus, and the majority of them also support other policies. Consult the documentation for the window manager to determine which focus models are available. widgets Widget is a term for all of the items in the user interface that can be clicked or manipulated in some way. This includes buttons, check boxes, radio buttons, icons, and lists. A widget toolkit is a set of widgets used to create graphical applications. There are several popular widget toolkits, including Qt, used by KDE, and GTK+, used by GNOME. As a result, applications will have a different look and feel, depending upon which widget toolkit was used to create the application. Installing <application>&xorg;</application> On &os;, &xorg; can be installed as a package or port. The binary package can be installed quickly but with fewer options for customization: &prompt.root; pkg install xorg To build and install from the Ports Collection: &prompt.root; cd /usr/ports/x11/xorg &prompt.root; make install clean Either of these installations results in the complete &xorg; system being installed. Binary packages are the best option for most users. A smaller version of the X system suitable for experienced users is available in x11/xorg-minimal. Most of the documents, libraries, and applications will not be installed. Some applications require these additional components to function. <application>&xorg;</application> Configuration Warren Block Originally contributed by &xorg; &xorg; Quick Start &xorg; supports most common video cards, keyboards, and pointing devices. Video cards, monitors, and input devices are automatically detected and do not require any manual configuration. Do not create xorg.conf or run a step unless automatic configuration fails. If &xorg; has been used on this computer before, move or remove any existing configuration files: &prompt.root; mv /etc/X11/xorg.conf ~/xorg.conf.etc &prompt.root; mv /usr/local/etc/X11/xorg.conf ~/xorg.conf.localetc Add the user who will run &xorg; to the video or wheel group to enable 3D acceleration when available. To add user jru to whichever group is available: &prompt.root; pw groupmod video -m jru || pw groupmod wheel -m jru The twm window manager is included by default. It is started when &xorg; starts: &prompt.user; startx On some older versions of &os;, the system console must be set to &man.vt.4; before switching back to the text console will work properly. See . User Group for Accelerated Video Access to /dev/dri is needed to allow 3D acceleration on video cards. It is usually simplest to add the user who will be running X to either the video or wheel group. Here, &man.pw.8; is used to add user slurms to the video group, or to the wheel group if there is no video group: &prompt.root; pw groupmod video -m slurms || pw groupmod wheel -m slurms Kernel Mode Setting (<acronym>KMS</acronym>) When the computer switches from displaying the console to a higher screen resolution for X, it must set the video output mode. Recent versions of &xorg; use a system inside the kernel to do these mode changes more efficiently. Older versions of &os; use &man.sc.4;, which is not aware of the KMS system. The end result is that after closing X, the system console is blank, even though it is still working. The newer &man.vt.4; console avoids this problem. Add this line to /boot/loader.conf to enable &man.vt.4;: kern.vty=vt Configuration Files Manual configuration is usually not necessary. Please do not manually create configuration files unless autoconfiguration does not work. Directory &xorg; looks in several directories for configuration files. /usr/local/etc/X11/ is the recommended directory for these files on &os;. Using this directory helps keep application files separate from operating system files. Storing configuration files in the legacy /etc/X11/ still works. However, this mixes application files with the base &os; files and is not recommended. Single or Multiple Files It is easier to use multiple files that each configure a specific setting than the traditional single xorg.conf. These files are stored in the xorg.conf.d/ subdirectory of the main configuration file directory. The full path is typically /usr/local/etc/X11/xorg.conf.d/. Examples of these files are shown later in this section. The traditional single xorg.conf still works, but is neither as clear nor as flexible as multiple files in the xorg.conf.d/ subdirectory. Video Cards Because of changes made in recent versions of &os;, it is now possible to use graphics drivers provided by the Ports framework or as packages. As such, users can use one of the following drivers available from graphics/drm-kmod. &i915kms; &radeonkms; &amdgpu; 2D and 3D acceleration is supported on most &i915kms; graphics cards provided by &intel;. Driver name: i915kms 2D and 3D acceleration is supported on most older &radeonkms; graphics cards provided by &amd;. Driver name: radeonkms 2D and 3D acceleration is supported on most newer &amdgpu; graphics cards provided by &amd;.. Driver name: amdgpu For reference, please see or for a list of supported GPUs. &intel; 3D acceleration is supported on most &intel; graphics up to Ivy Bridge (HD Graphics 2500, 4000, and P4000), including Iron Lake (HD Graphics) and Sandy Bridge (HD Graphics 2000). Driver name: intel For reference, see . &amd; Radeon 2D and 3D acceleration is supported on Radeon cards up to and including the HD6000 series. Driver name: radeon For reference, see . NVIDIA Several NVIDIA drivers are available in the x11 category of the Ports Collection. Install the driver that matches the video card. For reference, see . Hybrid Combination Graphics Some notebook computers add additional graphics processing units to those built into the chipset or processor. Optimus combines &intel; and NVIDIA hardware. Switchable Graphics or Hybrid Graphics are a combination of an &intel; or &amd; processor and an &amd; Radeon GPU. Implementations of these hybrid graphics systems vary, and &xorg; on &os; is not able to drive all versions of them. Some computers provide a BIOS option to disable one of the graphics adapters or select a discrete mode which can be used with one of the standard video card drivers. For example, it is sometimes possible to disable the NVIDIA GPU in an Optimus system. The &intel; video can then be used with an &intel; driver. BIOS settings depend on the model of computer. In some situations, both GPUs can be left enabled, but creating a configuration file that only uses the main GPU in the Device section is enough to make such a system functional. Other Video Cards Drivers for some less-common video cards can be found in the x11-drivers directory of the Ports Collection. Cards that are not supported by a specific driver might still be usable with the x11-drivers/xf86-video-vesa driver. This driver is installed by x11/xorg. It can also be installed manually as x11-drivers/xf86-video-vesa. &xorg; attempts to use this driver when a specific driver is not found for the video card. x11-drivers/xf86-video-scfb is a similar nonspecialized video driver that works on many UEFI and &arm; computers. Setting the Video Driver in a File To set the &intel; driver in a configuration file: Select &intel; Video Driver in a File /usr/local/etc/X11/xorg.conf.d/driver-intel.conf Section "Device" Identifier "Card0" Driver "intel" # BusID "PCI:1:0:0" EndSection If more than one video card is present, the BusID identifier can be uncommented and set to select the desired card. A list of video card bus IDs can be displayed with pciconf -lv | grep -B3 display. To set the Radeon driver in a configuration file: Select Radeon Video Driver in a File /usr/local/etc/X11/xorg.conf.d/driver-radeon.conf Section "Device" Identifier "Card0" Driver "radeon" EndSection To set the VESA driver in a configuration file: Select <acronym>VESA</acronym> Video Driver in a File /usr/local/etc/X11/xorg.conf.d/driver-vesa.conf Section "Device" Identifier "Card0" Driver "vesa" EndSection To set the scfb driver for use with a UEFI or &arm; computer: Select <literal>scfb</literal> Video Driver in a File /usr/local/etc/X11/xorg.conf.d/driver-scfb.conf Section "Device" Identifier "Card0" Driver "scfb" EndSection Monitors Almost all monitors support the Extended Display Identification Data standard (EDID). &xorg; uses EDID to communicate with the monitor and detect the supported resolutions and refresh rates. Then it selects the most appropriate combination of settings to use with that monitor. Other resolutions supported by the monitor can be chosen by setting the desired resolution in configuration files, or after the X server has been started with &man.xrandr.1;. Using &man.xrandr.1; Run &man.xrandr.1; without any parameters to see a list of video outputs and detected monitor modes: &prompt.user; xrandr Screen 0: minimum 320 x 200, current 3000 x 1920, maximum 8192 x 8192 DVI-0 connected primary 1920x1200+1080+0 (normal left inverted right x axis y axis) 495mm x 310mm 1920x1200 59.95*+ 1600x1200 60.00 1280x1024 85.02 75.02 60.02 1280x960 60.00 1152x864 75.00 1024x768 85.00 75.08 70.07 60.00 832x624 74.55 800x600 75.00 60.32 640x480 75.00 60.00 720x400 70.08 DisplayPort-0 disconnected (normal left inverted right x axis y axis) HDMI-0 disconnected (normal left inverted right x axis y axis) This shows that the DVI-0 output is being used to display a screen resolution of 1920x1200 pixels at a refresh rate of about 60 Hz. Monitors are not attached to the DisplayPort-0 and HDMI-0 connectors. Any of the other display modes can be selected with &man.xrandr.1;. For example, to switch to 1280x1024 at 60 Hz: &prompt.user; xrandr --mode 1280x1024 --rate 60 A common task is using the external video output on a notebook computer for a video projector. The type and quantity of output connectors varies between devices, and the name given to each output varies from driver to driver. What one driver calls HDMI-1, another might call HDMI1. So the first step is to run &man.xrandr.1; to list all the available outputs: &prompt.user; xrandr Screen 0: minimum 320 x 200, current 1366 x 768, maximum 8192 x 8192 LVDS1 connected 1366x768+0+0 (normal left inverted right x axis y axis) 344mm x 193mm 1366x768 60.04*+ 1024x768 60.00 800x600 60.32 56.25 640x480 59.94 VGA1 connected (normal left inverted right x axis y axis) 1280x1024 60.02 + 75.02 1280x960 60.00 1152x864 75.00 1024x768 75.08 70.07 60.00 832x624 74.55 800x600 72.19 75.00 60.32 56.25 640x480 75.00 72.81 66.67 60.00 720x400 70.08 HDMI1 disconnected (normal left inverted right x axis y axis) DP1 disconnected (normal left inverted right x axis y axis) Four outputs were found: the built-in panel LVDS1, and external VGA1, HDMI1, and DP1 connectors. The projector has been connected to the VGA1 output. &man.xrandr.1; is now used to set that output to the native resolution of the projector and add the additional space to the right side of the desktop: &prompt.user; xrandr --output VGA1 --auto --right-of LVDS1 --auto chooses the resolution and refresh rate detected by EDID. If the resolution is not correctly detected, a fixed value can be given with --mode instead of the --auto statement. For example, most projectors can be used with a 1024x768 resolution, which is set with --mode 1024x768. &man.xrandr.1; is often run from .xinitrc to set the appropriate mode when X starts. Setting Monitor Resolution in a File To set a screen resolution of 1024x768 in a configuration file: Set Screen Resolution in a File /usr/local/etc/X11/xorg.conf.d/screen-resolution.conf Section "Screen" Identifier "Screen0" Device "Card0" SubSection "Display" Modes "1024x768" EndSubSection EndSection The few monitors that do not have EDID can be configured by setting HorizSync and VertRefresh to the range of frequencies supported by the monitor. Manually Setting Monitor Frequencies /usr/local/etc/X11/xorg.conf.d/monitor0-freq.conf Section "Monitor" Identifier "Monitor0" HorizSync 30-83 # kHz VertRefresh 50-76 # Hz EndSection Input Devices Keyboards Keyboard Layout The standardized location of keys on a keyboard is called a layout. Layouts and other adjustable parameters are listed in &man.xkeyboard-config.7;. A United States layout is the default. To select an alternate layout, set the XkbLayout and XkbVariant options in an InputClass. This will be applied to all input devices that match the class. This example selects a French keyboard layout. Setting a Keyboard Layout /usr/local/etc/X11/xorg.conf.d/keyboard-fr.conf Section "InputClass" Identifier "KeyboardDefaults" MatchIsKeyboard "on" Option "XkbLayout" "fr" EndSection Setting Multiple Keyboard Layouts Set United States, Spanish, and Ukrainian keyboard layouts. Cycle through these layouts by pressing Alt Shift . x11/xxkb or x11/sbxkb can be used for improved layout switching control and current layout indicators. /usr/local/etc/X11/xorg.conf.d/kbd-layout-multi.conf Section "InputClass" Identifier "All Keyboards" MatchIsKeyboard "yes" Option "XkbLayout" "us, es, ua" EndSection Closing &xorg; From the Keyboard X can be closed with a combination of keys. By default, that key combination is not set because it conflicts with keyboard commands for some applications. Enabling this option requires changes to the keyboard InputDevice section: Enabling Keyboard Exit from X /usr/local/etc/X11/xorg.conf.d/keyboard-zap.conf Section "InputClass" Identifier "KeyboardDefaults" MatchIsKeyboard "on" Option "XkbOptions" "terminate:ctrl_alt_bksp" EndSection Mice and Pointing Devices If using xorg-server 1.20.8 or later under &os; &rel121.current; and not using &man.moused.8;, add kern.evdev.rcpt_mask=12 to /etc/sysctl.conf. Many mouse parameters can be adjusted with configuration options. See &man.mousedrv.4x; for a full list. Mouse Buttons The number of buttons on a mouse can be set in the mouse InputDevice section of xorg.conf. To set the number of buttons to 7: Setting the Number of Mouse Buttons /usr/local/etc/X11/xorg.conf.d/mouse0-buttons.conf Section "InputDevice" Identifier "Mouse0" Option "Buttons" "7" EndSection Manual Configuration In some cases, &xorg; autoconfiguration does not work with particular hardware, or a different configuration is desired. For these cases, a custom configuration file can be created. Do not create manual configuration files unless required. Unnecessary manual configuration can prevent proper operation. A configuration file can be generated by &xorg; based on the detected hardware. This file is often a useful starting point for custom configurations. Generating an xorg.conf: &prompt.root; Xorg -configure The configuration file is saved to /root/xorg.conf.new. Make any changes desired, then test that file (using so there is a visible background) with: &prompt.root; Xorg -retro -config /root/xorg.conf.new After the new configuration has been adjusted and tested, it can be split into smaller files in the normal location, /usr/local/etc/X11/xorg.conf.d/. Using Fonts in <application>&xorg;</application> Type1 Fonts The default fonts that ship with &xorg; are less than ideal for typical desktop publishing applications. Large presentation fonts show up jagged and unprofessional looking, and small fonts are almost completely unintelligible. However, there are several free, high quality Type1 (&postscript;) fonts available which can be readily used with &xorg;. For instance, the URW font collection (x11-fonts/urwfonts) includes high quality versions of standard type1 fonts (Times Roman, Helvetica, Palatino and others). The Freefonts collection (x11-fonts/freefonts) includes many more fonts, but most of them are intended for use in graphics software such as the Gimp, and are not complete enough to serve as screen fonts. In addition, &xorg; can be configured to use &truetype; fonts with a minimum of effort. For more details on this, see the &man.X.7; manual page or . To install the above Type1 font collections from binary packages, run the following commands: &prompt.root; pkg install urwfonts Alternatively, to build from the Ports Collection, run the following commands: &prompt.root; cd /usr/ports/x11-fonts/urwfonts &prompt.root; make install clean And likewise with the freefont or other collections. To have the X server detect these fonts, add an appropriate line to the X server configuration file (/etc/X11/xorg.conf), which reads: FontPath "/usr/local/share/fonts/urwfonts/" Alternatively, at the command line in the X session run: &prompt.user; xset fp+ /usr/local/share/fonts/urwfonts &prompt.user; xset fp rehash This will work but will be lost when the X session is closed, unless it is added to the startup file (~/.xinitrc for a normal startx session, or ~/.xsession when logging in through a graphical login manager like XDM). A third way is to use the new /usr/local/etc/fonts/local.conf as demonstrated in . &truetype; Fonts TrueType Fonts fonts TrueType &xorg; has built in support for rendering &truetype; fonts. There are two different modules that can enable this functionality. The freetype module is used in this example because it is more consistent with the other font rendering back-ends. To enable the freetype module just add the following line to the "Module" section of /etc/X11/xorg.conf. Load "freetype" Now make a directory for the &truetype; fonts (for example, /usr/local/share/fonts/TrueType) and copy all of the &truetype; fonts into this directory. Keep in mind that &truetype; fonts cannot be directly taken from an &apple; &mac;; they must be in &unix;/&ms-dos;/&windows; format for use by &xorg;. Once the files have been copied into this directory, use mkfontscale to create a fonts.dir, so that the X font renderer knows that these new files have been installed. mkfontscale can be installed as a package: &prompt.root; pkg install mkfontscale Then create an index of X font files in a directory: &prompt.root; cd /usr/local/share/fonts/TrueType &prompt.root; mkfontscale Now add the &truetype; directory to the font path. This is just the same as described in : &prompt.user; xset fp+ /usr/local/share/fonts/TrueType &prompt.user; xset fp rehash or add a FontPath line to xorg.conf. Now Gimp, LibreOffice, and all of the other X applications should now recognize the installed &truetype; fonts. Extremely small fonts (as with text in a high resolution display on a web page) and extremely large fonts (within LibreOffice) will look much better now. Anti-Aliased Fonts anti-aliased fonts fonts anti-aliased All fonts in &xorg; that are found in /usr/local/share/fonts/ and ~/.fonts/ are automatically made available for anti-aliasing to Xft-aware applications. Most recent applications are Xft-aware, including KDE, GNOME, and Firefox. To control which fonts are anti-aliased, or to configure anti-aliasing properties, create (or edit, if it already exists) the file /usr/local/etc/fonts/local.conf. Several advanced features of the Xft font system can be tuned using this file; this section describes only some simple possibilities. For more details, please see &man.fonts-conf.5;. XML This file must be in XML format. Pay careful attention to case, and make sure all tags are properly closed. The file begins with the usual XML header followed by a DOCTYPE definition, and then the <fontconfig> tag: <?xml version="1.0"?> <!DOCTYPE fontconfig SYSTEM "fonts.dtd"> <fontconfig> As previously stated, all fonts in /usr/local/share/fonts/ as well as ~/.fonts/ are already made available to Xft-aware applications. To add another directory outside of these two directory trees, add a line like this to /usr/local/etc/fonts/local.conf: <dir>/path/to/my/fonts</dir> After adding new fonts, and especially new font directories, rebuild the font caches: &prompt.root; fc-cache -f Anti-aliasing makes borders slightly fuzzy, which makes very small text more readable and removes staircases from large text, but can cause eyestrain if applied to normal text. To exclude font sizes smaller than 14 point from anti-aliasing, include these lines: <match target="font"> <test name="size" compare="less"> <double>14</double> </test> <edit name="antialias" mode="assign"> <bool>false</bool> </edit> </match> <match target="font"> <test name="pixelsize" compare="less" qual="any"> <double>14</double> </test> <edit mode="assign" name="antialias"> <bool>false</bool> </edit> </match> fonts spacing Spacing for some monospaced fonts might also be inappropriate with anti-aliasing. This seems to be an issue with KDE, in particular. One possible fix is to force the spacing for such fonts to be 100. Add these lines: <match target="pattern" name="family"> <test qual="any" name="family"> <string>fixed</string> </test> <edit name="family" mode="assign"> <string>mono</string> </edit> </match> <match target="pattern" name="family"> <test qual="any" name="family"> <string>console</string> </test> <edit name="family" mode="assign"> <string>mono</string> </edit> </match> (this aliases the other common names for fixed fonts as "mono"), and then add: <match target="pattern" name="family"> <test qual="any" name="family"> <string>mono</string> </test> <edit name="spacing" mode="assign"> <int>100</int> </edit> </match> Certain fonts, such as Helvetica, may have a problem when anti-aliased. Usually this manifests itself as a font that seems cut in half vertically. At worst, it may cause applications to crash. To avoid this, consider adding the following to local.conf: <match target="pattern" name="family"> <test qual="any" name="family"> <string>Helvetica</string> </test> <edit name="family" mode="assign"> <string>sans-serif</string> </edit> </match> After editing local.conf, make certain to end the file with the </fontconfig> tag. Not doing this will cause changes to be ignored. Users can add personalized settings by creating their own ~/.config/fontconfig/fonts.conf. This file uses the same XML format described above. LCD screen Fonts LCD screen One last point: with an LCD screen, sub-pixel sampling may be desired. This basically treats the (horizontally separated) red, green and blue components separately to improve the horizontal resolution; the results can be dramatic. To enable this, add the line somewhere in local.conf: <match target="font"> <test qual="all" name="rgba"> <const>unknown</const> </test> <edit name="rgba" mode="assign"> <const>rgb</const> </edit> </match> Depending on the sort of display, rgb may need to be changed to bgr, vrgb or vbgr: experiment and see which works best. The X Display Manager Seth Kingsley Originally contributed by X Display Manager &xorg; provides an X Display Manager, XDM, which can be used for login session management. XDM provides a graphical interface for choosing which display server to connect to and for entering authorization information such as a login and password combination. This section demonstrates how to configure the X Display Manager on &os;. Some desktop environments provide their own graphical login manager. Refer to for instructions on how to configure the GNOME Display Manager and for instructions on how to configure the KDE Display Manager. Configuring <application>XDM</application> To install XDM, use the x11/xdm package or port. Once installed, XDM can be configured to run when the machine boots up by editing this entry in /etc/ttys: ttyv8 "/usr/local/bin/xdm -nodaemon" xterm off secure Change the off to on and save the edit. The ttyv8 in this entry indicates that XDM will run on the ninth virtual terminal. The XDM configuration directory is located in /usr/local/etc/X11/xdm. This directory contains several files used to change the behavior and appearance of XDM, as well as a few scripts and programs used to set up the desktop when XDM is running. summarizes the function of each of these files. The exact syntax and usage of these files is described in &man.xdm.1;. XDM Configuration Files File Description Xaccess The protocol for connecting to XDM is called the X Display Manager Connection Protocol (XDMCP). This file is a client authorization ruleset for controlling XDMCP connections from remote machines. By default, this file does not allow any remote clients to connect. Xresources This file controls the look and feel of the XDM display chooser and login screens. The default configuration is a simple rectangular login window with the hostname of the machine displayed at the top in a large font and Login: and Password: prompts below. The format of this file is identical to the app-defaults file described in the &xorg; documentation. Xservers The list of local and remote displays the chooser should provide as login choices. Xsession Default session script for logins which is run by XDM after a user has logged in. This points to a customized session script in ~/.xsession. Xsetup_* Script to automatically launch applications before displaying the chooser or login interfaces. There is a script for each display being used, named Xsetup_*, where * is the local display number. Typically these scripts run one or two programs in the background such as xconsole. xdm-config Global configuration for all displays running on this machine. xdm-errors Contains errors generated by the server program. If a display that XDM is trying to start hangs, look at this file for error messages. These messages are also written to the user's ~/.xsession-errors on a per-session basis. xdm-pid The running process ID of XDM.
Configuring Remote Access By default, only users on the same system can login using XDM. To enable users on other systems to connect to the display server, edit the access control rules and enable the connection listener. To configure XDM to listen for any remote connection, comment out the DisplayManager.requestPort line in /usr/local/etc/X11/xdm/xdm-config by putting a ! in front of it: ! SECURITY: do not listen for XDMCP or Chooser requests ! Comment out this line if you want to manage X terminals with xdm DisplayManager.requestPort: 0 Save the edits and restart XDM. To restrict remote access, look at the example entries in /usr/local/etc/X11/xdm/Xaccess and refer to &man.xdm.1; for further information.
Desktop Environments Valentino Vaschetto Contributed by This section describes how to install three popular desktop environments on a &os; system. A desktop environment can range from a simple window manager to a complete suite of desktop applications. Over a hundred desktop environments are available in the x11-wm category of the Ports Collection. GNOME GNOME GNOME is a user-friendly desktop environment. It includes a panel for starting applications and displaying status, a desktop, a set of tools and applications, and a set of conventions that make it easy for applications to cooperate and be consistent with each other. More information regarding GNOME on &os; can be found at https://www.FreeBSD.org/gnome. That web site contains additional documentation about installing, configuring, and managing GNOME on &os;. This desktop environment can be installed from a package: &prompt.root; pkg install gnome3 To instead build GNOME from ports, use the following command. GNOME is a large application and will take some time to compile, even on a fast computer. &prompt.root; cd /usr/ports/x11/gnome3 &prompt.root; make install clean GNOME requires /proc to be mounted. Add this line to /etc/fstab to mount this file system automatically during system startup: proc /proc procfs rw 0 0 GNOME uses D-Bus and HAL for a message bus and hardware abstraction. These applications are automatically installed as dependencies of GNOME. Enable them in /etc/rc.conf so they will be started when the system boots: dbus_enable="YES" hald_enable="YES" After installation, configure &xorg; to start GNOME. The easiest way to do this is to enable the GNOME Display Manager, GDM, which is installed as part of the GNOME package or port. It can be enabled by adding this line to /etc/rc.conf: gdm_enable="YES" It is often desirable to also start all GNOME services. To achieve this, add a second line to /etc/rc.conf: gnome_enable="YES" GDM will start automatically when the system boots. A second method for starting GNOME is to type startx from the command-line after configuring ~/.xinitrc. If this file already exists, replace the line that starts the current window manager with one that starts /usr/local/bin/gnome-session. If this file does not exist, create it with this command: &prompt.user; echo "exec /usr/local/bin/gnome-session" > ~/.xinitrc A third method is to use XDM as the display manager. In this case, create an executable ~/.xsession: &prompt.user; echo "exec /usr/local/bin/gnome-session" > ~/.xsession KDE KDE KDE is another easy-to-use desktop environment. This desktop provides a suite of applications with a consistent look and feel, a standardized menu and toolbars, keybindings, color-schemes, internationalization, and a centralized, dialog-driven desktop configuration. More information on KDE can be found at http://www.kde.org/. For &os;-specific information, consult http://freebsd.kde.org. To install the KDE package, type: &prompt.root; pkg install x11/kde5 To instead build the KDE port, use the following command. Installing the port will provide a menu for selecting which components to install. KDE is a large application and will take some time to compile, even on a fast computer. &prompt.root; cd /usr/ports/x11/kde5 &prompt.root; make install clean KDE requires /proc to be mounted. Add this line to /etc/fstab to mount this file system automatically during system startup: proc /proc procfs rw 0 0 KDE uses D-Bus and HAL for a message bus and hardware abstraction. These applications are automatically installed as dependencies of KDE. Enable them in /etc/rc.conf so they will be started when the system boots: dbus_enable="YES" hald_enable="YES" KDE display manager Since KDE Plasma 5, the KDE Display Manager, KDM is no longer developed. A possible replacement is SDDM. To install it, type: &prompt.root; pkg install x11/sddm Add this line to /etc/rc.conf: sddm_enable="YES" A second method for launching KDE Plasma is to type startx from the command line. For this to work, the following line is needed in ~/.xinitrc: exec ck-launch-session startplasma-x11 A third method for starting KDE Plasma is through XDM. To do so, create an executable ~/.xsession as follows: &prompt.user; echo "exec ck-launch-session startplasma-x11" > ~/.xsession Once KDE Plasma is started, refer to its built-in help system for more information on how to use its various menus and applications. Xfce Xfce is a desktop environment based on the GTK+ toolkit used by GNOME. However, it is more lightweight and provides a simple, efficient, easy-to-use desktop. It is fully configurable, has a main panel with menus, applets, and application launchers, provides a file manager and sound manager, and is themeable. Since it is fast, light, and efficient, it is ideal for older or slower machines with memory limitations. More information on Xfce can be found at http://www.xfce.org. To install the Xfce package: &prompt.root; pkg install xfce Alternatively, to build the port: &prompt.root; cd /usr/ports/x11-wm/xfce4 &prompt.root; make install clean Xfce uses D-Bus for a message bus. This application is automatically installed as dependency of Xfce. Enable it in /etc/rc.conf so it will be started when the system boots: dbus_enable="YES" Unlike GNOME or KDE, Xfce does not provide its own login manager. In order to start Xfce from the command line by typing startx, first create ~/.xinitrc with this command: &prompt.user; echo ". /usr/local/etc/xdg/xfce4/xinitrc" > ~/.xinitrc An alternate method is to use XDM. To configure this method, create an executable ~/.xsession: &prompt.user; echo ". /usr/local/etc/xdg/xfce4/xinitrc" > ~/.xsession Installing Compiz Fusion One way to make using a desktop computer more pleasant is with nice 3D effects. Installing the Compiz Fusion package is easy, but configuring it requires a few steps that are not described in the port's documentation. Setting up the &os; nVidia Driver Desktop effects can cause quite a load on the graphics card. For an nVidia-based graphics card, the proprietary driver is required for good performance. Users of other graphics cards can skip this section and continue with the xorg.conf configuration. To determine which nVidia driver is needed see the FAQ question on the subject. Having determined the correct driver to use for your card, installation is as simple as installing any other package. For example, to install the latest driver: &prompt.root; pkg install x11/nvidia-driver The driver will create a kernel module, which needs to be loaded at system startup. Add the following line to /boot/loader.conf: nvidia_load="YES" To immediately load the kernel module into the running kernel issue a command like kldload nvidia. However, it has been noted that some versions of &xorg; will not function properly if the driver is not loaded at boot time. After editing /boot/loader.conf, a reboot is recommended. With the kernel module loaded, you normally only need to change a single line in xorg.conf to enable the proprietary driver: Find the following line in /etc/X11/xorg.conf: Driver "nv" and change it to: Driver "nvidia" Start the GUI as usual, and you should be greeted by the nVidia splash. Everything should work as usual. Configuring <literal>xorg.conf</literal> for Desktop Effects To enable Compiz Fusion, /etc/X11/xorg.conf needs to be modified: Add the following section to enable composite effects: Section "Extensions" Option "Composite" "Enable" EndSection Locate the Screen section which should look similar to the one below: Section "Screen" Identifier "Screen0" Device "Card0" Monitor "Monitor0" ... and add the following two lines (after Monitor will do): DefaultDepth 24 Option "AddARGBGLXVisuals" "True" Locate the Subsection that refers to the screen resolution that you wish to use. For example, if you wish to use 1280x1024, locate the section that follows. If the desired resolution does not appear in any subsection, you may add the relevant entry by hand: SubSection "Display" Viewport 0 0 Modes "1280x1024" EndSubSection A color depth of 24 bits is needed for desktop composition, change the above subsection to: SubSection "Display" Viewport 0 0 Depth 24 Modes "1280x1024" EndSubSection Finally, confirm that the glx and extmod modules are loaded in the Module section: Section "Module" Load "extmod" Load "glx" ... The preceding can be done automatically with x11/nvidia-xconfig by running (as root): &prompt.root; nvidia-xconfig --add-argb-glx-visuals &prompt.root; nvidia-xconfig --composite &prompt.root; nvidia-xconfig --depth=24 Installing and Configuring Compiz Fusion Installing Compiz Fusion is as simple as any other package: &prompt.root; pkg install x11-wm/compiz-fusion When the installation is finished, start your graphic desktop and at a terminal, enter the following commands (as a normal user): &prompt.user; compiz --replace --sm-disable --ignore-desktop-hints ccp & &prompt.user; emerald --replace & Your screen will flicker for a few seconds, as your window manager (e.g., Metacity if you are using GNOME) is replaced by Compiz Fusion. Emerald takes care of the window decorations (i.e., close, minimize, maximize buttons, title bars and so on). You may convert this to a trivial script and have it run at startup automatically (e.g., by adding to Sessions in a GNOME desktop): #! /bin/sh compiz --replace --sm-disable --ignore-desktop-hints ccp & emerald --replace & Save this in your home directory as, for example, start-compiz and make it executable: &prompt.user; chmod +x ~/start-compiz Then use the GUI to add it to Startup Programs (located in System, Preferences, Sessions on a GNOME desktop). To actually select all the desired effects and their settings, execute (again as a normal user) the Compiz Config Settings Manager: &prompt.user; ccsm In GNOME, this can also be found in the System, Preferences menu. If you have selected gconf support during the build, you will also be able to view these settings using gconf-editor under apps/compiz. Troubleshooting If the mouse does not work, you will need to first configure it before proceeding. In recent Xorg versions, the InputDevice sections in xorg.conf are ignored in favor of the autodetected devices. To restore the old behavior, add the following line to the ServerLayout or ServerFlags section of this file: Option "AutoAddDevices" "false" Input devices may then be configured as in previous versions, along with any other options needed (e.g., keyboard layout switching). As previously explained the hald daemon will, by default, automatically detect your keyboard. There are chances that your keyboard layout or model will not be correct, desktop environments like GNOME, KDE or Xfce provide tools to configure the keyboard. However, it is possible to set the keyboard properties directly either with the help of the &man.setxkbmap.1; utility or with a hald's configuration rule. For example if, one wants to use a PC 102 keys keyboard coming with a french layout, we have to create a keyboard configuration file for hald called x11-input.fdi and saved in the /usr/local/etc/hal/fdi/policy directory. This file should contain the following lines: <?xml version="1.0" encoding="iso-8859-1"?> <deviceinfo version="0.2"> <device> <match key="info.capabilities" contains="input.keyboard"> <merge key="input.x11_options.XkbModel" type="string">pc102</merge> <merge key="input.x11_options.XkbLayout" type="string">fr</merge> </match> </device> </deviceinfo> If this file already exists, just copy and add to your file the lines regarding the keyboard configuration. You will have to reboot your machine to force hald to read this file. It is possible to do the same configuration from an X terminal or a script with this command line: &prompt.user; setxkbmap -model pc102 -layout fr /usr/local/share/X11/xkb/rules/base.lst lists the various keyboard, layouts and options available. &xorg; tuning The xorg.conf.new configuration file may now be tuned to taste. Open the file in a text editor such as &man.emacs.1; or &man.ee.1;. If the monitor is an older or unusual model that does not support autodetection of sync frequencies, those settings can be added to xorg.conf.new under the "Monitor" section: Section "Monitor" Identifier "Monitor0" VendorName "Monitor Vendor" ModelName "Monitor Model" HorizSync 30-107 VertRefresh 48-120 EndSection Most monitors support sync frequency autodetection, making manual entry of these values unnecessary. For the few monitors that do not support autodetection, avoid potential damage by only entering values provided by the manufacturer. X allows DPMS (Energy Star) features to be used with capable monitors. The &man.xset.1; program controls the time-outs and can force standby, suspend, or off modes. If you wish to enable DPMS features for your monitor, you must add the following line to the monitor section: Option "DPMS" xorg.conf While the xorg.conf.new configuration file is still open in an editor, select the default resolution and color depth desired. This is defined in the "Screen" section: Section "Screen" Identifier "Screen0" Device "Card0" Monitor "Monitor0" DefaultDepth 24 SubSection "Display" Viewport 0 0 Depth 24 Modes "1024x768" EndSubSection EndSection The DefaultDepth keyword describes the color depth to run at by default. This can be overridden with the command line switch to &man.Xorg.1;. The Modes keyword describes the resolution to run at for the given color depth. Note that only VESA standard modes are supported as defined by the target system's graphics hardware. In the example above, the default color depth is twenty-four bits per pixel. At this color depth, the accepted resolution is 1024 by 768 pixels. Finally, write the configuration file and test it using the test mode given above. One of the tools available to assist you during troubleshooting process are the &xorg; log files, which contain information on each device that the &xorg; server attaches to. &xorg; log file names are in the format of /var/log/Xorg.0.log. The exact name of the log can vary from Xorg.0.log to Xorg.8.log and so forth. If all is well, the configuration file needs to be installed in a common location where &man.Xorg.1; can find it. This is typically /etc/X11/xorg.conf or /usr/local/etc/X11/xorg.conf. &prompt.root; cp xorg.conf.new /etc/X11/xorg.conf The &xorg; configuration process is now complete. &xorg; may be now started with the &man.startx.1; utility. The &xorg; server may also be started with the use of &man.xdm.1;. Configuration with &intel; <literal>i810</literal> Graphics Chipsets &intel; i810 graphic chipset Configuration with &intel; i810 integrated chipsets requires the agpgart AGP programming interface for &xorg; to drive the card. See the &man.agp.4; driver manual page for more information. This will allow configuration of the hardware as any other graphics board. Note on systems without the &man.agp.4; driver compiled in the kernel, trying to load the module with &man.kldload.8; will not work. This driver has to be in the kernel at boot time through being compiled in or using /boot/loader.conf. Adding a Widescreen Flatpanel to the Mix widescreen flatpanel configuration This section assumes a bit of advanced configuration knowledge. If attempts to use the standard configuration tools above have not resulted in a working configuration, there is information enough in the log files to be of use in getting the setup working. Use of a text editor will be necessary. Current widescreen (WSXGA, WSXGA+, WUXGA, WXGA, WXGA+, et.al.) formats support 16:10 and 10:9 formats or aspect ratios that can be problematic. Examples of some common screen resolutions for 16:10 aspect ratios are: 2560x1600 1920x1200 1680x1050 1440x900 1280x800 At some point, it will be as easy as adding one of these resolutions as a possible Mode in the Section "Screen" as such: Section "Screen" Identifier "Screen0" Device "Card0" Monitor "Monitor0" DefaultDepth 24 SubSection "Display" Viewport 0 0 Depth 24 Modes "1680x1050" EndSubSection EndSection &xorg; is smart enough to pull the resolution information from the widescreen via I2C/DDC information so it knows what the monitor can handle as far as frequencies and resolutions. If those ModeLines do not exist in the drivers, one might need to give &xorg; a little hint. Using /var/log/Xorg.0.log one can extract enough information to manually create a ModeLine that will work. Simply look for information resembling this: (II) MGA(0): Supported additional Video Mode: (II) MGA(0): clock: 146.2 MHz Image Size: 433 x 271 mm (II) MGA(0): h_active: 1680 h_sync: 1784 h_sync_end 1960 h_blank_end 2240 h_border: 0 (II) MGA(0): v_active: 1050 v_sync: 1053 v_sync_end 1059 v_blanking: 1089 v_border: 0 (II) MGA(0): Ranges: V min: 48 V max: 85 Hz, H min: 30 H max: 94 kHz, PixClock max 170 MHz This information is called EDID information. Creating a ModeLine from this is just a matter of putting the numbers in the correct order: ModeLine <name> <clock> <4 horiz. timings> <4 vert. timings> So that the ModeLine in Section "Monitor" for this example would look like this: Section "Monitor" Identifier "Monitor1" VendorName "Bigname" ModelName "BestModel" ModeLine "1680x1050" 146.2 1680 1784 1960 2240 1050 1053 1059 1089 Option "DPMS" EndSection Now having completed these simple editing steps, X should start on your new widescreen monitor. Troubleshooting Compiz Fusion I have installed Compiz Fusion, and after running the commands you mention, my windows are left without title bars and buttons. What is wrong? You are probably missing a setting in /etc/X11/xorg.conf. Review this file carefully and check especially the DefaultDepth and AddARGBGLXVisuals directives. When I run the command to start Compiz Fusion, the X server crashes and I am back at the console. What is wrong? If you check /var/log/Xorg.0.log, you will probably find error messages during the X startup. The most common would be: (EE) NVIDIA(0): Failed to initialize the GLX module; please check in your X (EE) NVIDIA(0): log file that the GLX module has been loaded in your X (EE) NVIDIA(0): server, and that the module is the NVIDIA GLX module. If (EE) NVIDIA(0): you continue to encounter problems, Please try (EE) NVIDIA(0): reinstalling the NVIDIA driver. This is usually the case when you upgrade &xorg;. You will need to reinstall the x11/nvidia-driver package so glx is built again.
diff --git a/en_US.ISO8859-1/htdocs/advocacy/myths.xml b/en_US.ISO8859-1/htdocs/advocacy/myths.xml index 753e6ca507..731f633fe8 100644 --- a/en_US.ISO8859-1/htdocs/advocacy/myths.xml +++ b/en_US.ISO8859-1/htdocs/advocacy/myths.xml @@ -1,398 +1,399 @@ ]> &title; $FreeBSD$

As the BSD projects (including DragonFlyBSD, &os;, NetBSD, and OpenBSD) have grown in size, a number of persistent myths have grown up around them. Some of these are perpetuated by well meaning but misguided individuals, others by people pursuing their own agendas.

This page aims to dispel those myths while remaining as dispassionate as possible.

Note: Throughout this page, ''*BSD'' refers to all of the BSD Projects. Where a myth or response is specific to a particular project it is indicated as such.
If you are aware of an omission or error on this page, please let the &os; Documentation Project mailing list know.

Myths

Index

Myth: *BSD has a closed development model, it's more ''Cathedral'' than ''Bazaar''

Eric Raymond wrote an influential paper, ''The Cathedral and the Bazaar'' in which the Linux development model (and the model Eric used for fetchmail) is held up as an example of how to do ''open'' development. By contrast, the model employed by *BSD is often characterized as closed.

The implicit value judgment is that ''bazaar'' (open) is good, and ''cathedral'' (closed) is bad.

If anything, *BSD's development model is probably more akin to the ''bazaar'' that Eric describes than either Linux or fetchmail.

Consider the following;


Myth: You cannot make your own distributions or derivative works of *BSD

You can. You just need to say in the documentation and source files where the code is derived from. Multiple derivative projects exist:

Similarly to DragonflyBSD, OpenBSD was not a standalone project, it started as a spinoff from the NetBSD project, and has since evolved its own distinctive approach.


Myth: *BSD makes a great server, but a poor (&unix;) desktop

*BSD makes a great server. It also makes a great desktop. Many of the requirements for a server (responsiveness under load, stability, effective use of system resources) are the same requirements as for a desktop machine.

*BSD has access to the same desktop tools (KDE, GNOME, Firefox, windowmanagers) as Linux. And ''office'' applications such as LibreOffice suite work under *BSD too.


Myth: The BSD codebase is old, outdated, and dying

While the BSD codebase may be more than 20 years old, it is neither outdated nor dying. Many professional users like the stability that years of testing has provided FreeBSD.

Technological enhancements continue to be added to *BSD.


Myth: The *BSD projects are at war with one another, splinter groups form each week

No. While occasional advocacy may get a touch heated, the *BSD flavors continue to work with one another. FreeBSD's Alpha port was initially heavily based on the work done by the NetBSD team. Both NetBSD and OpenBSD used the FreeBSD ports collection to bootstrap their own port sets. FreeBSD and NetBSD both integrate security fixes first discovered by the OpenBSD team.

The FreeBSD and NetBSD projects separated more than twenty years ago. OpenBSD and DragonflyBSD are the only new BSD projects to split off in the last twenty years.


Myth: You can't cluster *BSD systems (parallel computing)

The following URLs should disprove this;

Note, that freebsd-cluster mailing list is available for further discussion about clustering of FreeBSD.


Myth: There's no commercial support for *BSD

FreeBSD: The FreeBSD Commercial Vendors Page lists companies that offer commercial support for FreeBSD.

The FreeBSD Mall also offer commercial support, along with shirts, hats, books, software, and promotional items.

OpenBSD: The OpenBSD Commercial Consulting Page lists companies that offer commercial support for OpenBSD.


Myth: There are no applications for *BSD

The free software community started running on predominantly BSD systems (SunOS and similar). *BSD users can generally compile software written for these systems without needing to make any changes.

In addition, each *BSD project uses a ''ports'' system to make the building of ported software much easier.

FreeBSD: There are currently more than 30,000 applications ready to download and install in the FreeBSD ports collection. On i386 and AMD64, the Linux emulation layer will also run the vast majority of Linux applications. On the AMD64 architectures there is a compatibility layer to run 32-bit FreeBSD binaries.

NetBSD: The Linux emulation layer will run the vast majority of i386 Linux applications, and the majority of SunOS4 applications can be run on a SPARCStation.

OpenBSD: There are currently more than 8000 applications ready to download and install in the OpenBSD ports collection. The Linux emulation layer will also run the vast majority of i386 Linux applications, and the majority of SunOS4 applications can be run on a SPARCStation.

Both NetBSD and OpenBSD are able to use applications in FreeBSD's ports collection with minimal effort. Their lower number of ported applications reflects this.

It is true that most companies when porting to PC Unix will choose Linux first. Fortunately, *BSD's Linux emulation layer will run these programs (Acrobat, StarOffice, Mathematica, WordPerfect, Quake, Intel ICC compiler, Compaq's Alpha compiler ...) with few, if any, problems.

As a historical note, the first version of Netscape Navigator that ran on FreeBSD with Java support was the Linux version. These day you can also use a native FreeBSD version of Mozilla with a native Java plugin, all compiled conveniently from ports.


Myth: *BSD is better than (insert other system)

This is user opinion only.


Myth: (insert some other system) is better than *BSD

This is user opinion only.


Contributors

Members of the FreeBSD, NetBSD, and OpenBSD projects have contributed to this page;

Nik Clayton <nik@FreeBSD.org>
Jordan Hubbard <jkh@FreeBSD.org>
Ian F. Darwin <ian@DarwinSys.com>
Adrian Filipi-Martin <adrian@ubergeeks.com>
Tom Rhodes <trhodes@FreeBSD.org>
diff --git a/en_US.ISO8859-1/htdocs/advocacy/whyusefreebsd.xml b/en_US.ISO8859-1/htdocs/advocacy/whyusefreebsd.xml index 62e007c332..16942c4a9d 100644 --- a/en_US.ISO8859-1/htdocs/advocacy/whyusefreebsd.xml +++ b/en_US.ISO8859-1/htdocs/advocacy/whyusefreebsd.xml @@ -1,209 +1,209 @@ ]> &title; $FreeBSD$

Why Choose &os;?

Why would you consider using &os;? We think that there are lots of reasons. Here is a selection of reasons that some of our existing users gave for their choice of operating system.

The Community

&os; is a community-driven operating system despite it being to a partial degree sponsored corporately. &os; has active mailing lists, forums, and IRC channels where experienced users and developers are always willing to help the less experienced.

The community is largely driven by technology, not ideology, and is focused on building the best possible system and making &os; as widely used as possible, not on pushing any other agendas.

There is no dictator—benevolent or otherwise—for the project. The Core Team is elected and is nominally responsible for overseeing the goals of the project, but this is a very light touch. Core mediates disputes between developers, but rarely needs to take an active role in development, beyond their separate contributions as individual developers.

Stability

Stability means many different things. &os; very rarely crashes (and when it does it is usually due to hardware faults), but while that was a great boast a decade ago, now it is an expected feature for any operating system.

Stability in &os; means much more than that. It means that upgrading the system does not require upgrading the user. Configuration interfaces do change over time, but only when there is a good reason. If you learned how to use &os; in 2000, most of your knowledge would still be relevant.

Backwards compatibility is very important to the &os; team, and any release in a major release series is expected to be able to run any code—including kernel modules—that ran on an earlier version. The entire base system is developed together, including the kernel, the core utilities, and the configuration system, so upgrades are usually painless. Included tools like mergemaster help update configuration files with little or no manual intervention.

Early Adoption and Collaboration With Other Projects

&os; has been one of the first adopters of the LLVM infrastructure, including the clang compiler and the libc++ stack. The entire &os; system, including kernel and userspace, can build with clang, and from &os; both clang and the permissively-licensed libc++ are included, giving a modern, BSD-licensed C++ stack. Several &os; developers are also active contributors to LLVM, ensuring that both projects thrive together.

This same collaboration works downstream, with projects like - FuryBSD, GhostBSD, MidnightBSD and pfSense building on top of + GhostBSD, MidnightBSD, NomadBSD and pfSense building on top of the &os; base to provide desktop and firewall oriented distributions, respectively. These projects are not forks, they base their work on the latest version of &os; and customize the system for specific uses.

Simple Configuration

&os; service initialization is very simple. Each service, whether part of the base system or installed from a port, comes with a script that is responsible for starting and stopping it (and often some other options). The /etc/rc.conf file contains a list of variables for enabling and configuring services. Want to enable ssh? Just add sshd_enable="YES" to your rc.conf file. This system makes it easy to see at a glance everything that will be started when your system boots.

The rc system that reads this file understands dependencies between services and so can automatically launch them in parallel, or wait until one is finished before starting the things that it needs. You get all of the benefits of a modern configuration system, without a complex interface.

Ports

The ports tree contains a large collection of third-party software, including older versions of some things where the userbase is divided about the benefits of upgrading, and a lot of niche programs. The chances are that anything you want to run which works on &os; will be there.

Unlike some other systems, &os; maintains a clean division between the base system and third-party ports and packages. All third-party software goes in /usr/local, so if you want to repurpose a machine, it is trivial to simply delete all installed packages and then start installing the ones that you want.

The pkg(8) tool makes working with binary packages even easier, although source installs are still supported for people who want the level of configurability that this implies.

Security

Security is vital in any network-connected machine. &os; provides a number of tools for ensuring that you can maintain a secure system, such as:

And, of course, all of the standard features that are expected from a modern &unix; system including IPSec, SSH, and so on.

ZFS

Cheap snapshots, clones, end-to-end checksums, deduplication, compression, and no need to decide partition sizes on install. Using ZFS for a few days makes going back to a more traditional volume manager painful. If you want to test something with ZFS, it is trivial to just create a snapshot and roll back if it didn't work.

ZFS lets you clone an existing jail in under a second, no matter how big the jail itself is.

GEOM

Even without ZFS, &os; comes with a rich storage system. GEOM layers providers and consumers in arbitrary ways, allowing you to use two networked machines for high-availability storage, use your choice of RAID level, or add features like compression or encryption.

Working Sound

&os; 4.x introduced in-kernel sound mixing, so that multiple applications could play sound at the same time even with cheap sound cards with no hardware mixing support. &os; 5.x automatically allocated new channels to applications, without any configuration.

Now, &os; has low-latency sound mixing with per-application volume controls and full support for the OSS 4 APIs out of the box. There is no need to configure a userspace sound daemon. The same audio APIs that were used a decade ago still work on &os;, including some compatibility modes to allow applications that try to manipulate the global volume to only change their own. If you want to watch DVDs with 5.1 surround sound, just install your favourite media player and press play.

My System, How I Want It

&os; gives you an easy-to-use, working, &unix;-like system. This base system can then be extended easily. If you want to run KDE or GNOME, then just install the metapackage for the version that you prefer. If you want a headless server, then it is equally easy to install the server tools that you want.

It is easy to run the &os; installer via a serial port and to configure the entire system from the terminal. It is also easy to install and use an existing desktop environment. The decisions about the kind of system you want to use are left to you.

If you are deploying &os; in a corporate environment, then it is very easy to customise both the base system and the set of installed packages for your specific requirements. The build system provides numerous tuneable variables allowing you to build exactly the base system that meets your needs.

diff --git a/en_US.ISO8859-1/htdocs/projects/newbies.xml b/en_US.ISO8859-1/htdocs/projects/newbies.xml index db704b409a..5a889a8392 100644 --- a/en_US.ISO8859-1/htdocs/projects/newbies.xml +++ b/en_US.ISO8859-1/htdocs/projects/newbies.xml @@ -1,137 +1,138 @@ ]> &title; $FreeBSD$

Getting &os;

The latest &os; releases are available here. Before you begin, please carefully read the installation instructions.

Learning about &os;

Questions and Support

Learning about &os;-derived projects

&os; is widely used as a building block for other commercial and open-source operating systems. Some of the most widely used and publicly available systems are listed below.

How to Contribute

Everyone has something to contribute to the &os; community, even newbies! Some are busy working with the new advocacy group and some have become involved with the Documentation Project as reviewers. Other &os; newbies might have particular skills and experiences to share, either computer related or not, or just want to meet new newbies and make them feel welcome. There are always people around who help others simply because they like to.

Friends who run &os; are a great resource. No book can replace chatting on the phone or across a pizza with someone who has the same interests, enjoys similar accomplishments, and faces the same challenges. If you do not have many friends who use &os;, consider using your old &os; CDs to create some more.

User groups are good places to meet other &os; users. If there is no one nearby, you might consider starting one!

For more information on getting involved in the community, see the Contributing to &os; article.

diff --git a/en_US.ISO8859-1/htdocs/where.xml b/en_US.ISO8859-1/htdocs/where.xml index 1b91724cda..66bdc6ef5f 100644 --- a/en_US.ISO8859-1/htdocs/where.xml +++ b/en_US.ISO8859-1/htdocs/where.xml @@ -1,560 +1,562 @@ ]> &title; $FreeBSD$

Choosing an Architecture

Most users of &os; will have hardware for either the amd64, i386, or armv6 architectures.

Modern PCs use the amd64 architecture, including those with Intel® branded processors. Computers with more than 3 GB of memory should use amd64. If the computer is an older, 32-bit only model, use i386. For embedded devices and single-board computers (SBC) such as the Raspberry Pi, Beagle Bone Black, Panda Board, and Zed Board, use the armv6 SD card image which supports ARMv6 and ARMv7 processors.

All other users should reference the complete list of supported &os; platforms.

Choosing an Image

The &os; installer can be downloaded in a number of different formats including CD (disc1), DVD (dvd1), and Network Install (bootonly) sized ISO Disc Images, as well as regular and mini USB memory stick images. Recent versions of &os; are also offered as prebuilt expandable Virtual Machine images, and as SD Card images for embedded platforms.

&os; Deployment Statistics

While &os; does not gather deployment statistics, having statistical information available is essential. Please consider installing the sysutils/bsdstats package, which collects hardware and software statistics, helping developers understand how to best focus their efforts. The information collected is available at the bsdstats.org website.

&os; &rel122.current;-RELEASE

Installer Images Virtual Machine Images SD Card Images Documentation

&os; &rel121.current;-RELEASE

Installer Images Virtual Machine Images SD Card Images Documentation

&os; &rel114.current;-RELEASE

Installer Images Virtual Machine Images SD Card Images Documentation

&beta.desc; &beta.second;

Development Snapshots

If you are interested in a purely experimental snapshot release of &os;-CURRENT (AKA &rel.head;-CURRENT), aimed at developers and bleeding-edge testers only, then please see the &os; Snapshot Releases page. For more information about past, present and future releases in general, please visit the release information page.

&os; &rel.head;-CURRENT

Installer Images Virtual Machine Images SD Card Images Documentation

 

&os; &rel122.current;-STABLE

Installer Images Virtual Machine Images SD Card Images Documentation

 

&os; &rel114.current;-STABLE

Installer Images Virtual Machine Images SD Card Images Documentation

If you plan on getting &os; via HTTP or FTP, please check the listing of mirror sites in the Handbook to see if there is a site closer to you.

Install &os;

There are many options for installing &os;, including installation from CD-ROM, DVD, USB Memory Stick or even directly using anonymous FTP, HTTP, or NFS. Please read through the &os; installation guide before downloading the entire &os; distribution.

Purchase &os; Media

&os; can be acquired on CD-ROM or DVD from FreeBSD Mall, or one of the other CD-ROM and DVD Publishers.

Past Releases

For downloading past releases, please visit the FTP archive.

&os;-derived Operating System Distributions

&os; is widely used as a building block for other commercial and open-source operating systems. The projects below are widely used and of particular interest to &os; users.

Applications and Utility Software

The Ports Collection

The &os; Ports Collection is a diverse collection of utility and application software that has been ported to &os;.

See Installing Applications: Packages and Ports in the Handbook.

For information about how you can contribute your favorite piece of software to the Ports Collection, have a look at The Porter's Handbook and the article Contributing to &os;.