https://www.funtoo.org/api.php?action=feedcontributions&user=Duncan.britton&feedformat=atomFuntoo - User contributions [en]2024-03-29T09:12:06ZUser contributionsMediaWiki 1.36.2https://www.funtoo.org/index.php?title=GNOME_First_Steps&diff=12183GNOME First Steps2015-07-19T19:47:18Z<p>Duncan.britton: Finished updating lower part of the page. Will come back in later and add links to and descriptions of other gnome applications, i.e. file-roller, nautilus, and gnome-terminal.</p>
<hr />
<div><blockquote><br />
GNOME 3 is an easy and elegant way to use your computer. It is designed to put you in control and bring freedom to everybody. GNOME 3 is developed by the GNOME community, a diverse, international group of contributors that is supported by an independent, non-profit foundation." [http://gnome.org GNOME]<br />
</blockquote><br />
<br />
=== Prerequisites === <br />
Before attempting to emerge Gnome, make sure that you have installed and tested the [[X Window System]] on your computer.<br />
<br />
=== Preparing to emerge ===<br />
<br />
After verifying that you have installed the X Window system on your computer, change your system flavor to desktop, and enable the gnome profile mix-in. To accomplish this, run the following:<br />
{{console|body=<br />
###i## epro flavor desktop<br />
###i## epro mix-ins +gnome<br />
}}<br />
By enabling the gnome mix-in, various settings, including the {{c|USE}} portage variable, will be optimized to provide you with a relatively painless Gnome install.<br />
<br />
=== Emerging ===<br />
The Funtoo Linux repositories include two ebuild "meta packages" that can be used to install Gnome. One of them, {{c|gnome-light}} installs a bare-bones gnome desktop with few "extra" applications and games that can be found in the {{c|gnome-extra}} and {{c|games-*}} portage categories, respectively. If you are interested in having a Gnome desktop with extra applications like a photo viewer, text editor, sound player, font viewer, etc, immediately after installing the Gnome packages, consider emerging the {{c|gnome}} package instead of {{c|gnome-light}}.<br />
{{Note|Individual Gnome applications can be installed on top of a {{c|gnome-light}} installation, allowing you to only install the applications you need and limit unnecessary bloat.}}<br />
Below are two lists comparing some of the different packages installed by default with a {{c|gnome-light}} and {{c|gnome}} installation:<br />
{{TableStart}}<br />
<tr class="info"><th>{{c|gnome-light}}</th><th>{{c|gnome}}</th></tr><br />
<tr><td>'''Includes:'''<br />
* {{c|gnome-terminal}}<br />
* {{c|nautilus}} (the default Gnome file manager)<br />
* {{c|gnome-shell}} (can be removed using the -gnome-shell {{c|USE}} flag at installation)<br />
* {{c|gnome-control-center}}<br />
</td><td> '''Includes:'''<br />
* {{c|gnome-terminal}}<br />
* {{c|nautilus}}<br />
* {{c|gnome-shell}}<br />
* {{c|gnome-control-center}}<br />
* {{c|gnome-contacts}}<br />
* {{c|eog}} (an image viewing application)<br />
* {{c|gnome-weather}}<br />
* {{c|gnome-maps}}<br />
... and many other applications.<br />
</td></tr><br />
<tr><td> '''Best for:'''<br />
* Users who want a smaller installation that uses less disk space<br />
* Users who are comfortable installing additional packages that they require when the need arises<br />
</td><td>'''Best for:'''<br />
* Users who want a full-featured Gnome desktop right after installation<br />
* Users who don't mind extra resources being used by additional applications installed on the system<br />
</td></tr><br />
<tr><td>'''How to install:'''<br />
{{console|body=###i## emerge gnome-light}}<br />
</td><td>'''How to install:'''<br />
{{console|body=###i## emerge gnome}}<br />
</td></tr><br />
{{TableEnd}}<br />
<br />
=== A few finishing touches ===<br />
==== OpenGL ====<br />
GNOME uses OpenGL by default to help it provide nice animations and other eye candy, so you'll want to make sure that you use {{c|eselect opengl}} to ensure that the proper OpenGL implementation for your video card is selected. If this is not done, GNOME won't start, so it's important to check this. Type {{c|eselect opengl list}} as root to list OpenGL implementations, and {{c|eselect opengl set X}}, again as root, to set your OpenGL implementation to the one that you deem suitable.<br />
==== Setting up xdm (GUI log-in) ====<br />
Most users of Gnome are satisfied using {{c|gdm}}, the Gnome display manager, to log in to Gnome. To clarify: a display manager provides a graphical interface during system startup that allows users to log in to a desktop environment. <br />
<br />
By default, GNOME displays the {{f|/etc/motd}} file for several seconds after you log in via GDM. The best way to eliminate this delay is to remove the unnecessary {{f|/etc/motd}} file, which only contains information related to when your stage3 was built:<br />
{{console|body=<br />
###i## rm /etc/motd<br />
}}<br />
By default, after installing Gnome, GDM is not enabled. To enable GDM, edit {{f|/etc/conf.d/xdm}} and set the {{c|DISPLAYMANAGER}} variable to {{c|gdm}} instead of the default, {{c|xdm}}. When finished, your {{f|/etc/conf.d/xdm}} file should look like:<br />
<br />
{{file|name=/etc/conf.d/xdm|body=<br />
# We always try and start X on a static VT. The various DMs normally default<br />
# to using VT7. If you wish to use the xdm init script, then you should ensure<br />
# that the VT checked is the same VT your DM wants to use. We do this check to<br />
# ensure that you haven't accidentally configured something to run on the VT<br />
# in your /etc/inittab file so that you don't get a dead keyboard.<br />
CHECKVT=7<br />
<br />
# What display manager do you use ?<br />
# NOTE: If this is set in /etc/rc.conf, that setting will override this one.<br />
DISPLAYMANAGER="gdm"<br />
}}<br />
Once you finish configuring that file, add the {{c|xdm}} service to the default runlevel so that GDM will start automatically when your system has finished loading other services.<br />
<br />
{{Note|Funtoo's {{f|/etc/init.d/xdm}} initscript has been modified to start the requisite services {{c|dbus}}, {{c|openrc-settingsd}} and {{c|consolekit}} prior to starting GDM.}}<br />
<br />
{{console|body=<br />
###i## rc-update add xdm default<br />
}}<br />
The above command adds xdm to the list of services to be started at boot. Since your system has already started, the xdm service will be started the next time the system is started. To run the xdm service now, you can execute the following command, which runs any services in the list of services to start at boot that are currently not running:<br />
<br />
{{console|body=###i## rc}}<br />
==== Setting up xinitrc (text-based log-in) ====<br />
If, instead of using a display manager like GDM, you would rather log into the console and start Gnome from there, add the following to your {{f|~/.xinitrc}} file:<br />
{{file|name=~/.xinitrc|body=<br />
# Fix Missing Applications in Gnome<br />
export XDG_MENU_PREFIX=gnome-<br />
<br />
# Properly Launch the Desired X Session<br />
exec ck-launch-session gnome-session<br />
}}<br />
{{Note|If you need support for different input sources, there is no longer a need to configure IBus or SCIM in your {{f|~.xinitrc}} file as GNOME uses IBus natively. Simply configure it in the Gnome Control Center under the Region & Language section.}}<br />
=== Upgrading from GNOME 3.12 ===<br />
To update either {{c|gnome-light}} or {{c|gnome}} to a newer version, run the following command:<br />
<br />
{{console|body=###i## emerge -vauDN world}}<br />
=== Subsystems ===<br />
==== Bluetooth ====<br />
For bluetooth support under Gnome, ensure that:<br />
# Bluetooth support is enabled within your kernel (using modules is fine).<br />
# Your bluetooth hardware is turned on.<br />
<br />
After ensuring those two things, the {{c|bluetooth}} startup script can be added to the default runlevel and started:<br />
{{console|body=<br />
###i## rc-update add bluetooth default<br />
###i## rc<br />
}}<br />
Once the {{c|rc}} command has been run, the {{c|bluetooth}} init file has been run, meaning that you should now be able to navigate to the Gnome Control Center's '''Bluetooth''' section to turn bluetooth on. The icon next to devices should now animate and you should be able to discover and add devices such as bluetooth keyboards and mice.<br />
<br />
{{Note|Additional kernel drivers may be necessary for certain input devices. For example, for the bluetooth Apple Magic Trackpad, the following option must be enabled in your kernel:<br />
<br />
{{kernelop|title=Device Drivers,HID support,HID bus support,Special HID drivers|desc=<br />
<M> Apple Magic Mouse/Trackpad multi-touch support<br />
}}}}<br />
<br />
==== Printing ====<br />
To enable printing support, add the {{c|cupsd}} init file to the default runlevel and then start the cupsd service by running the {{c|rc}} command:<br />
<br />
{{console|body=<br />
###i## rc-update add cupsd default<br />
###i## rc<br />
}}<br />
You should now be able to navigate to the Gnome Control Center's '''Printers''' sections and add printers to your system. After adding printers to your system, you should, hopefully, be able to print to them. If you have troubles with the default printer drivers, consider reading <br />
<br />
==== Scanning ====<br />
<br />
To enable scanning support, add your user account (and the accounts of any other users who may need to scan) to the {{c|lp}} group. By adding your user account to this group, you will have access to any locally attached scanner:<br />
{{console|body=###i## gpasswd -a <username> lp}}<br />
After adding yourself and any other desired users to the {{c|lp}} local printing group, install {{c|xsane}}, a graphical scanning frontend, by running the following command: <br />
{{console|body=###i## emerge xsane}}<br />
When you run {{c|xsane}}, it should be able to access your scanner.<br />
<br />
=== Automatically Starting Applications at Login ===<br />
When using an old-fashioned {{~/.xinitrc}}, loading applications when X starts is relatively easy, simply add different applications to launch on separate lines in the file. When using GDM, this can also be accomplished with ease by editing the {{f|~/.xprofile}} file. Here is a sample {{f|~/.xprofile}} that runs the {{c|xflux}} application to dim a computer's monitor at night:<br />
<br />
{{file|name=~/.xprofile|body=<br />
xflux -z 87107<br />
}}<br />
<br />
{{Note|Remember to add an {{c|&}} at the end of any command that doesn't return directly to the shell prompt after running.}}<br />
<br />
=== Games ===<br />
Gnome has a plethora of games that can be added to your installation of either {{c|gnome-light}} or {{c|gnome}}. By default, the majority of Gnome games are not included in the {{c|gnome}} and {{c|gnome-light}} packages. If you are interested in playing games under Gnome, or for that matter, any other desktop environment, you will want to add your user account to the {{c|games}} group. This can be accomplished easily by running the following command:<br />
{{console|body=###i## gpasswd -a $USER games}}<br />
The above command appends games to the list of groups that you are already a member of. Once your user account has been added to the {{c|games}} group, you should log out and log back in to apply the changes to your user at log-in. Below is a list of games that were developed by the Gnome team with the Gnome desktop environment in mind:<br />
<br />
*gnome-sudoku <br />
*gnome-mastermind<br />
*gnome-nibbles<br />
*gnome-robots<br />
*gnome-chess<br />
*gnome-hearts<br />
*gnome-mahjongg<br />
*gnome-mines<br />
*gnome-klotski<br />
*gnome-tetravex<br />
*gnomeboyadvance<br />
*gnome-mud<br />
<br />
To install any of the above games, simply run an:<br />
{{console|body=###i## emerge <gamename>}}<br />
=== Significant Known Issues (Workarounds Available) ===<br />
<br />
*[https://bugs.funtoo.org/browse/FL-1678 FL-1678]: Bluetooth interface gives wrong pairing key<br />
<br />
*[https://bugs.funtoo.org/browse/FL-1687 FL-1687]: Wallpaper corruption when resuming from suspend<br />
<br />
[[Category:Desktop]]<br />
[[Category:First Steps]]<br />
[[Category:Official Documentation]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=GNOME_First_Steps&diff=12147GNOME First Steps2015-07-18T21:17:48Z<p>Duncan.britton: Updated more of the page</p>
<hr />
<div><blockquote><br />
GNOME 3 is an easy and elegant way to use your computer. It is designed to put you in control and bring freedom to everybody. GNOME 3 is developed by the GNOME community, a diverse, international group of contributors that is supported by an independent, non-profit foundation." [http://gnome.org GNOME]<br />
</blockquote><br />
<br />
=== Prerequisites === <br />
Before attempting to emerge Gnome, make sure that you have installed and tested the [[X Window System]] on your computer.<br />
<br />
=== Preparing to emerge ===<br />
<br />
After verifying that you have installed the X Window system on your computer, change your system flavor to desktop, and enable the gnome profile mix-in. To accomplish this, run the following:<br />
{{console|body=<br />
###i## epro flavor desktop<br />
###i## epro mix-ins +gnome<br />
}}<br />
By enabling the gnome mix-in, various settings, including the {{c|USE}} portage variable, will be optimized to provide you with a relatively painless Gnome install.<br />
<br />
=== Emerging ===<br />
The Funtoo Linux repositories include two ebuild "meta packages" that can be used to install Gnome. One of them, {{c|gnome-light}} installs a bare-bones gnome desktop with few "extra" applications and games that can be found in the {{c|gnome-extra}} and {{c|games-*}} portage categories, respectively. If you are interested in having a Gnome desktop with extra applications like a photo viewer, text editor, sound player, font viewer, etc, immediately after installing the Gnome packages, consider emerging the {{c|gnome}} package instead of {{c|gnome-light}}.<br />
{{Note|Individual Gnome applications can be installed on top of a {{c|gnome-light}} installation, allowing you to only install the applications you need and limit unnecessary bloat.}}<br />
Below are two lists comparing some of the different packages installed by default with a {{c|gnome-light}} and {{c|gnome}} installation:<br />
{{TableStart}}<br />
<tr class="info"><th>{{c|gnome-light}}</th><th>{{c|gnome}}</th></tr><br />
<tr><td>'''Includes:'''<br />
* {{c|gnome-terminal}}<br />
* {{c|nautilus}} (the default Gnome file manager)<br />
* {{c|gnome-shell}} (can be removed using the -gnome-shell {{c|USE}} flag at installation)<br />
* {{c|gnome-control-center}}<br />
</td><td> '''Includes:'''<br />
* {{c|gnome-terminal}}<br />
* {{c|nautilus}}<br />
* {{c|gnome-shell}}<br />
* {{c|gnome-control-center}}<br />
* {{c|gnome-contacts}}<br />
* {{c|eog}} (an image viewing application)<br />
* {{c|gnome-weather}}<br />
* {{c|gnome-maps}}<br />
... and many other applications.<br />
</td></tr><br />
<tr><td> '''Best for:'''<br />
* Users who want a smaller installation that uses less disk space<br />
* Users who are comfortable installing additional packages that they require when the need arises<br />
</td><td>'''Best for:'''<br />
* Users who want a full-featured Gnome desktop right after installation<br />
* Users who don't mind extra resources being used by additional applications installed on the system<br />
</td></tr><br />
<tr><td>'''How to install:'''<br />
{{console|body=###i## emerge gnome-light}}<br />
</td><td>'''How to install:'''<br />
{{console|body=###i## emerge gnome}}<br />
</td></tr><br />
{{TableEnd}}<br />
<br />
=== A few finishing touches ===<br />
==== OpenGL ====<br />
GNOME uses OpenGL by default to help it provide nice animations and other eye candy, so you'll want to make sure that you use {{c|eselect opengl}} to ensure that the proper OpenGL implementation for your video card is selected. If this is not done, GNOME won't start, so it's important to check this. Type {{c|eselect opengl list}} as root to list OpenGL implementations, and {{c|eselect opengl set X}}, again as root, to set your OpenGL implementation to the one that you deem suitable.<br />
==== Setting up xdm (GUI log-in) ====<br />
Most users of Gnome are satisfied using {{c|gdm}}, the Gnome display manager, to log in to Gnome. To clarify: a display manager provides a graphical interface during system startup that allows users to log in to a desktop environment. <br />
<br />
By default, GNOME displays the {{f|/etc/motd}} file for several seconds after you log in via GDM. The best way to eliminate this delay is to remove the unnecessary {{f|/etc/motd}} file, which only contains information related to when your stage3 was built:<br />
{{console|body=<br />
###i## rm /etc/motd<br />
}}<br />
By default, after installing Gnome, GDM is not enabled. To enable GDM, edit {{f|/etc/conf.d/xdm}} and set the {{c|DISPLAYMANAGER}} variable to {{c|gdm}} instead of the default, {{c|xdm}}. When finished, your {{f|/etc/conf.d/xdm}} file should look like:<br />
<br />
{{file|name=/etc/conf.d/xdm|body=<br />
# We always try and start X on a static VT. The various DMs normally default<br />
# to using VT7. If you wish to use the xdm init script, then you should ensure<br />
# that the VT checked is the same VT your DM wants to use. We do this check to<br />
# ensure that you haven't accidentally configured something to run on the VT<br />
# in your /etc/inittab file so that you don't get a dead keyboard.<br />
CHECKVT=7<br />
<br />
# What display manager do you use ?<br />
# NOTE: If this is set in /etc/rc.conf, that setting will override this one.<br />
DISPLAYMANAGER="gdm"<br />
}}<br />
Once you finish configuring that file, add the {{c|xdm}} service to the default runlevel so that GDM will start automatically when your system has finished loading other services.<br />
<br />
{{Note|Funtoo's {{f|/etc/init.d/xdm}} initscript has been modified to start the requisite services {{c|dbus}}, {{c|openrc-settingsd}} and {{c|consolekit}} prior to starting GDM.}}<br />
<br />
{{console|body=<br />
###i## rc-update add xdm default<br />
}}<br />
The above command adds xdm to the list of services to be started at boot. Since your system has already started, the xdm service will be started the next time the system is started. To run the xdm service now, you can execute the following command, which runs any services in the list of services to start at boot that are currently not running:<br />
<br />
{{console|body=###i## rc}}<br />
==== Setting up xinitrc (text-based log-in) ====<br />
If, instead of using a display manager like GDM, you would rather log into the console and start Gnome from there, add the following to your {{f|~/.xinitrc}} file:<br />
{{file|name=~/.xinitrc|body=<br />
# Fix Missing Applications in Gnome<br />
export XDG_MENU_PREFIX=gnome-<br />
<br />
# Properly Launch the Desired X Session<br />
exec ck-launch-session gnome-session<br />
}}<br />
{{Note|If you need support for different input sources, there is no longer a need to configure IBus or SCIM in your {{f|~.xinitrc}} file as GNOME uses IBus natively. Simply configure it in the Gnome Control Center under the Region & Language section.}}<br />
=== Upgrading from GNOME 3.12 ===<br />
To update either {{c|gnome-light}} or {{c|gnome}} to a newer version, run the following command:<br />
<br />
{{console|body=###i## emerge -vauDN world}}<br />
=== Subsystems ===<br />
==== Bluetooth ====<br />
For bluetooth support under Gnome, ensure that:<br />
# Bluetooth support is enabled within your kernel (using modules is fine).<br />
# Your bluetooth hardware is turned on.<br />
<br />
After ensuring those two things, the {{c|bluetooth}} startup script can be added to the default runlevel and started:<br />
{{console|body=<br />
###i## rc-update add bluetooth default<br />
###i## rc<br />
}}<br />
Once the {{c|rc}} command has been run, the {{c|bluetooth}} init file has been run, meaning that you should now be able to navigate to the Gnome Control Center's ''Bluetooth'' section to turn bluetooth on. The icon next to devices should now animate and you should be able to discover and add devices such as bluetooth keyboards and mice.<br />
<br />
{{Note|Additional kernel drivers may be necessary for certain input devices. For example, for the bluetooth Apple Magic Trackpad, the following option must be enabled in your kernel:<br />
<br />
{{kernelop|title=Device Drivers,HID support,HID bus support,Special HID drivers|desc=<br />
<M> Apple Magic Mouse/Trackpad multi-touch support<br />
}}}}<br />
<br />
==== Printing ====<br />
To enable printing support, add the {{c|cupsd}} init file to the default runlevel:<br />
<br />
{{console|body=<br />
###i## rc-update add cupsd default<br />
###i## rc<br />
}}<br />
<br />
You should now be able to navigate to the Gnome Control Center's ''Printers'' sections and add printers to your system. After adding printers to your system, you should, hopefully, be able to print to them. If you have troubles with the default printer drivers, consider reading <br />
<br />
==== Scanning ====<br />
<br />
To enable scanning support, add your user account to the <code>lp</code> group. This will allow your user to access the USB scanner.<br />
<br />
Then, <code>emerge xsane</code>, and run it. It should be able to access your scanner.<br />
<br />
=== Automatically Starting Applications at Login ===<br />
<br />
When using an old-fashioned <code>.xinitrc</code>, starting up applications when X starts is relatively easy. When using GDM, this can still be accomplished, by using the <code>~/.xprofile</code> file. Here's my sample <code>.xprofile</code> to start <code>xflux</code> to dim the screen at night:<br />
<br />
<pre><br />
xflux -z 87107<br />
</pre><br />
<br />
{{Note|Remember to add a <code>&</code> at the end of any command that doesn't return to the shell prompt after running.}}<br />
<br />
=== games ===<br />
Gnome has several games that can be added on to your install. By default most games are not included in gnome's emerge.<br />
<br />
Users wishing to play games need to be added to the games group:<br />
{{console|body=###i## gpasswd -a $USER games}}<br />
<br />
game list:<br />
;gnome-sudoku <br />
;gnome-mastermind<br />
;gnome-nibbles<br />
;gnome-robots<br />
;gnome-chess<br />
;gnome-hearts<br />
;gnome-mahjongg<br />
;gnome-mines<br />
;gnome-klotski<br />
;gnome-tetravex<br />
<br />
game system emulators:<br />
<br />
;gnomeboyadvance<br />
;gnome-mud<br />
<br />
=== Significant Known Issues (Workarounds Available) ===<br />
<br />
[https://bugs.funtoo.org/browse/FL-1678 FL-1678]: Bluetooth interface gives wrong pairing key<br />
<br />
[https://bugs.funtoo.org/browse/FL-1687 FL-1687]: Wallpaper corruption when resuming from suspend<br />
<br />
[[Category:Desktop]]<br />
[[Category:First Steps]]<br />
[[Category:Official Documentation]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=GNOME_First_Steps&diff=12146GNOME First Steps2015-07-18T20:35:14Z<p>Duncan.britton: Updated the beginning of the page to include a table comparing gnome and gnome-light</p>
<hr />
<div><blockquote><br />
GNOME 3 is an easy and elegant way to use your computer. It is designed to put you in control and bring freedom to everybody. GNOME 3 is developed by the GNOME community, a diverse, international group of contributors that is supported by an independent, non-profit foundation." [http://gnome.org GNOME]<br />
</blockquote><br />
<br />
=== Prerequisites === <br />
Before attempting to emerge Gnome, make sure that you have installed and tested the [[X Window System]] on your computer.<br />
<br />
=== Preparing to emerge ===<br />
<br />
After verifying that you have installed the X Window system on your computer, change your system flavor to desktop, and enable the gnome profile mix-in. To accomplish this, run the following:<br />
{{console|body=<br />
###i## epro flavor desktop<br />
###i## epro mix-ins +gnome<br />
}}<br />
By enabling the gnome mix-in, various settings, including the {{c|USE}} portage variable, will be optimized to provide you with a relatively painless Gnome install.<br />
<br />
=== Emerging ===<br />
The Funtoo Linux repositories include two ebuild "meta packages" that can be used to install Gnome. One of them, {{c|gnome-light}} installs a bare-bones gnome desktop with few "extra" applications and games that can be found in the {{c|gnome-extra}} and {{c|games-*}} portage categories, respectively. If you are interested in having a Gnome desktop with extra applications like a photo viewer, text editor, sound player, font viewer, etc, immediately after installing the Gnome packages, consider emerging the {{c|gnome}} package instead of {{c|gnome-light}}.<br />
{{Note|Individual Gnome applications can be installed on top of a {{c|gnome-light}} installation, allowing you to only install the applications you need and limit unnecessary bloat.}}<br />
Below are two lists comparing some of the different packages installed by default with a {{c|gnome-light}} and {{c|gnome}} installation:<br />
{{TableStart}}<br />
<tr class="info"><th>{{c|gnome-light}}</th><th>{{c|gnome}}</th></tr><br />
<tr><td>'''Includes:'''<br />
* {{c|gnome-terminal}}<br />
* {{c|nautilus}} (the default Gnome file manager)<br />
* {{c|gnome-shell}} (can be removed using the -gnome-shell {{c|USE}} flag at installation)<br />
* {{c|gnome-control-center}}<br />
</td><td> '''Includes:'''<br />
* {{c|gnome-termina}}<br />
* {{c|nautilus}}<br />
* {{c|gnome-shell}}<br />
* {{c|gnome-control-center}}<br />
* {{c|gnome-contacts}}<br />
* {{c|eog}} (an image viewing application)<br />
* {{c|gnome-weather}}<br />
* {{c|gnome-maps}}<br />
... and many other applications.<br />
</td></tr><br />
<tr><td> '''Best for:'''<br />
* Users who want a smaller installation that uses less disk space<br />
* Users who are comfortable installing additional packages that they require when the need arises<br />
</td><td>'''Best for:'''<br />
* Users who want a full-featured Gnome desktop right after installation<br />
* Users who don't mind extra resources being used by additional applications installed on the system<br />
</td></tr><br />
<tr><td>'''How to install:'''<br />
{{console|body=###i## emerge gnome-light}}<br />
</td><td>'''How to install:'''<br />
{{console|body=###i## emerge gnome}}<br />
</td></tr><br />
{{TableEnd}}<br />
<br />
==== Finalizing Setup ====<br />
<br />
===== OpenGL =====<br />
<br />
GNOME uses OpenGL by default -- so you'll want to make sure that you use {{c|eselect opengl}} to ensure that the proper OpenGL implementation for your video card is selected. If this is not done, GNOME won't start, so it's important to check this. Type {{c|eselect opengl list}} as root to list OpenGL implementations, and {{c|eselect opengl set X}} to set your OpenGL implementation to the proper one.<br />
<br />
===== Setting up xdm (GUI log-in) =====<br />
<br />
====== /etc/motd ======<br />
<br />
Typically, you will want to use <code>gdm</code>, the GNOME display manager, to log in to GNOME. This will allow you to log in graphically, rather than using the text console.<br />
<br />
By default, GNOME displays the {{f|/etc/motd}} file for several seconds after you log in via GDM. The best way to eliminate this delay is to remove the unnecessary {{f|/etc/motd}} -- it contains information related to when your stage3 was built:<br />
<br />
{{console|body=<br />
# ##i##rm /etc/motd<br />
}}<br />
<br />
To enable gdm, edit <code>/etc/conf.d/xdm</code> and set <code>DISPLAYMANAGER</code> to <code>gdm</code> instead of <code>xdm</code>. Then, perform the following steps to add <code>xdm</code> to the default runlevel, and have it start automatically from now on when your system starts:<br />
<br />
{{Note|Funtoo's <code>/etc/init.d/xdm</code> initscript has been modified to start the requisite services <code>dbus</code>, <code>openrc-settingsd</code> and <code>consolekit</code> prior to starting <code>gdm</code>.}}<br />
<br />
{{console|recipe=setup|desc=Enable the GNOME display manager|body=<br />
# ##i## rc-update add xdm default<br />
}}<br />
<br />
Then, if you want to start it now do:<br />
<br />
{{console|body=<br />
# ##i##rc<br />
}}<br />
<br />
When your system restarts, it will start GDM by default.<br />
<br />
===== Setting up xinitrc (text log-in) =====<br />
<br />
Adding the following to your <code>~/.xinitrc</code> file is sufficient:<br />
<br />
<pre><br />
# Fix Missing Applications in Gnome<br />
export XDG_MENU_PREFIX=gnome-<br />
<br />
# Properly Launch the Desired X Session<br />
exec ck-launch-session gnome-session<br />
</pre><br />
<br />
Additionaly, if you need support for different input sources, there is no longer a need to configure IBus or SCIM in your <code>.xinitrc</code> file as GNOME uses IBus natively. Simply configure it in the Control Center under Region & Language.<br />
<br />
==== Upgrading from GNOME 3.12 ====<br />
<br />
To update either ''gnome'' or ''gnome-light'' run the following command:<br />
<br />
{{console|body=<br />
# ##i## emerge -vauDN world<br />
}}<br />
=== Subsystems ===<br />
<br />
==== Bluetooth ====<br />
<br />
For bluetooth support, ensure that:<br />
<br />
# Bluetooth support is enabled in your kernel (using modules is fine).<br />
# Your bluetooth hardware is turned on.<br />
# Add the <code>bluetooth</code> startup script to the default runlevel, and start it.<br />
<br />
This can be done as follows:<br />
<br />
<console><br />
# ##i##rc-update add bluetooth default<br />
# ##i##rc<br />
</console><br />
<br />
Once this is done, you should now be able to navigate to ''Settings'' -> ''Bluetooth'' and turn bluetooth on. The icon next to devices should now animate and you should be able to discover and add devices such as keyboards.<br />
<br />
{{Note|1=<br />
Additional kernel drivers may need to be enabled for certain input devices. For example, for the bluetooth Apple Magic Trackpad, the following option must be enabled in your kernel:<br />
<br />
{{kernelop|title=Device Drivers,HID support,HID bus support,Special HID drivers|desc=<br />
<M> Apple Magic Mouse/Trackpad multi-touch support<br />
}}}}<br />
<br />
==== Printing ====<br />
<br />
To enable printing support, add <code>cupsd</code> to the default runlevel:<br />
<br />
<console><br />
# ##i##rc-update add cupsd default<br />
# ##i##rc<br />
</console><br />
<br />
You should now be able to navigate to ''Settings'' -> ''Printers'' and add printers to your system, and print.<br />
<br />
==== Scanning ====<br />
<br />
To enable scanning support, add your user account to the <code>lp</code> group. This will allow your user to access the USB scanner.<br />
<br />
Then, <code>emerge xsane</code>, and run it. It should be able to access your scanner.<br />
<br />
=== Automatically Starting Applications at Login ===<br />
<br />
When using an old-fashioned <code>.xinitrc</code>, starting up applications when X starts is relatively easy. When using GDM, this can still be accomplished, by using the <code>~/.xprofile</code> file. Here's my sample <code>.xprofile</code> to start <code>xflux</code> to dim the screen at night:<br />
<br />
<pre><br />
xflux -z 87107<br />
</pre><br />
<br />
{{Note|Remember to add a <code>&</code> at the end of any command that doesn't return to the shell prompt after running.}}<br />
<br />
=== games ===<br />
Gnome has several games that can be added on to your install. By default most games are not included in gnome's emerge.<br />
<br />
Users wishing to play games need to be added to the games group:<br />
{{console|body=###i## gpasswd -a $USER games}}<br />
<br />
game list:<br />
;gnome-sudoku <br />
;gnome-mastermind<br />
;gnome-nibbles<br />
;gnome-robots<br />
;gnome-chess<br />
;gnome-hearts<br />
;gnome-mahjongg<br />
;gnome-mines<br />
;gnome-klotski<br />
;gnome-tetravex<br />
<br />
game system emulators:<br />
<br />
;gnomeboyadvance<br />
;gnome-mud<br />
<br />
=== Significant Known Issues (Workarounds Available) ===<br />
<br />
[https://bugs.funtoo.org/browse/FL-1678 FL-1678]: Bluetooth interface gives wrong pairing key<br />
<br />
[https://bugs.funtoo.org/browse/FL-1687 FL-1687]: Wallpaper corruption when resuming from suspend<br />
<br />
[[Category:Desktop]]<br />
[[Category:First Steps]]<br />
[[Category:Official Documentation]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Install&diff=12144Install2015-07-18T17:31:47Z<p>Duncan.britton: Fixed a minor problem -- "{[" instead of "{{"</p>
<hr />
<div>{{#widget:AddThis}}<br />
= Install Funtoo Linux = <br />
__NOTITLE__<br />
<languages/><br />
{{Announce|To help us translate this documentation, {{CreateAccount}}, log in to the wiki, and click the "Translate this page" link, above. You will be able to select small parts of the install docs and translate these parts to your native language.}}<br />
<translate><br />
== Introduction == <!--T:2--> <br />
<br />
<!--T:3--><br />
This document was written to help you install Funtoo Linux on PC-compatible systems, while keeping distracting options regarding system configuration to a minimum.<br />
<br />
<!--T:4--><br />
If you've had previous experience installing Gentoo Linux then a lot of steps will be familiar, but you should still read through as there are a few differences. If you're new to installing a Gentoo-based Linux, or new to Linux entirely -- welcome! We have attempted to make these installation instructions understandable to new users as well.<br />
<br />
<!--T:5--><br />
{{Note|If you are installing Funtoo Linux on [[Funtoo Linux Installation on ARM|ARM]] architecture, please see [[Funtoo Linux Installation on ARM]] for notable differences regarding ARM support. }}<br />
<br />
== Installation Overview == <!--T:6--> <br />
<br />
<!--T:7--><br />
This is a basic overview of the Funtoo installation process:<br />
<br />
<!--T:8--><br />
# [[#Live CD|Download and boot the live CD of your choice]].<br />
# [[#Prepare Hard Disk|Prepare your disk]].<br />
# [[#Creating filesystems|Create]] and [[#Mounting filesystems|mount]] filesystems.<br />
# [[#Installing the Stage 3 tarball|Install the Funtoo stage tarball]] of your choice.<br />
# [[#Chroot into Funtoo|Chroot into your new system]].<br />
# [[#Downloading the Portage tree|Download the Portage tree]].<br />
# [[#Configuring your system|Configure your system]] and [[#Configuring your network|network]].<br />
# [[#Configuring and installing the Linux kernel|Install a kernel]].<br />
# [[#Installing a Bootloader|Install a bootloader]].<br />
# [[#Finishing Steps|Complete final steps]].<br />
# [[#Restart your system|Reboot and enjoy]].<br />
<br />
=== Live CD === <!--T:9--> <br />
<br />
<!--T:10--><br />
In order to install Funtoo Linux, you will first need to boot your computer using a Linux-based Live CD or USB stick. We recommend the Gentoo-based [http://www.sysresccd.org/ System Rescue CD] as it contains lots of tools and utilities and supports both 32-bit and 64-bit systems. It can be burned to CD/DVD or installed on a USB stick. Download it here:<br />
<br />
<!--T:11--><br />
* Download from '''[http://ftp.osuosl.org/pub/funtoo/distfiles/sysresccd/systemrescuecd-x86-4.5.0.iso osuosl.org]'''<br />
* Download from '''[http://build.funtoo.org/distfiles/sysresccd/systemrescuecd-x86-4.5.0.iso funtoo.org]'''<br />
<br />
<!--T:12--><br />
{{Note|If using an older version of System Rescue CD, '''be sure to select the <code>rescue64</code> kernel at the boot menu if you are installing a 64-bit system'''. By default, System Rescue CD used to boot in 32-bit mode though the latest version attempts to automatically detect 64-bit processors.}}<br />
<br />
==== Network Access ==== <!--T:13--> <br />
<br />
<!--T:14--><br />
Once you have booted System Rescue CD, see if you have Internet access. Internet access is required for installing Funtoo Linux:<br />
</translate><br />
<br />
<console><br />
# ##i##ping www.google.com<br />
PING www.google.com (216.58.217.36) 56(84) bytes of data.<br />
64 bytes from den03s10-in-f4.1e100.net (216.58.217.36): icmp_seq=1 ttl=57 time=30.1 ms<br />
</console><br />
<br />
<translate><br />
<!--T:15--><br />
If the ping is successful (you see <code>64 bytes</code> messages as above,) then your Network is set up. Hit Control-C to stop the ping. <br />
<br />
<!--T:16--><br />
If you need to set up a WiFi connection for Internet access, then this needs to be done using the System Rescue CD graphical environment. Run <code>startx</code> to start a graphical session:<br />
</translate><br />
<console><br />
# ##i##startx<br />
</console><br />
<br />
[[File:NetworkManagerIcon.PNG|left|caption]]<br />
<br />
<translate><br />
<!--T:17--><br />
Then, use the NetworkManager applet (icon in lower right of graphical session, in taskbar) to connect to a WiFi network of your choice. Next, open a terminal inside your graphical environment, and you should be able to use the terminal to complete the rest of the steps.<br />
<br />
==== Remote Install ==== <!--T:18--> <br />
<br />
<!--T:19--><br />
Alternatively, you can log into System Rescue CD over the network via SSH to perform the install from another computer, and this may be more convenient way to install Funtoo Linux.<br />
<br />
<!--T:20--><br />
If you'd like to complete the install remotely, here's how. First, you will need to ensure that System Rescue CD has a functioning network connection. Then, you will need to set a root password for System Rescue CD:<br />
</translate><br />
{{console|body=<br />
###i## passwd<br />
New password: ##i##********<br />
Retype new password: ##i##********<br />
passwd: password updated successfully<br />
}}<br />
<translate><br />
<!--T:21--><br />
Once you have typed in a password, you will now need to determine the IP address of System Rescue CD, and then you can use {{c|ssh}} to connect to it. To determine the IP address currently being used by System Rescue CD, type {{c|ifconfig}}:</translate><br />
<br />
{{console|body=<br />
###i## ifconfig<br />
}}<br />
<translate><!--T:22--><br />
One of the interfaces should have an IP address (listed as {{c|inet addr:}}) from your LAN. You can then connect remotely, from another system on your LAN, to System Rescue CD, and perform steps from the comfort of an existing OS. On your remote system, type the following, replacing {{c|1.2.3.4}} with the IP address of System Rescue CD. Connecting from an existing Linux or MacOS system would look something like this:</translate><br />
<br />
{{console|body=<br />
(remote system) $ ##i##ssh root@1.2.3.4<br />
Password: ##i##**********}}<br />
<translate><!--T:23--><br />
{{Note|If you'd like to connect remotely from an existing Microsoft Windows system, you'll need to download an SSH client for Windows, such as [http://www.chiark.greenend.org.uk/~sgtatham/putty/ PuTTY].}}<br />
<br />
<!--T:24--><br />
After you've logged in via SSH, you're now connected remotely to System Rescue CD and can perform the installation steps.<br />
<br />
=== Prepare Hard Disk === <!--T:25--> <br />
<br />
<!--T:26--><br />
In this section, we'll learn about the different ways that Funtoo Linux can boot from a hard disk. By "boot", we mean the process by which Linux starts after you press the power button on your desktop, laptop or server. You can think of "booting" as a process that starts with your computer's firmware (built-in software) running, and then "finding" the Linux kernel and running it. The Linux kernel then takes over, identifies all your hardware, and starts.<br />
<br />
==== Background ==== <!--T:27--> <br />
<br />
<!--T:28--><br />
{{Note|If you are an absolute beginner to Linux, you may be less confused if you skip to the next section, [[#Which to Use?|Which to Use?]]}}<br />
<br />
<!--T:29--><br />
In earlier times, there was only one way to boot a PC-compatible computer. All of our desktops and servers had standard firmware called the "PC BIOS," all our hard drives used Master Boot Records at the beginning of the disk, where the PC BIOS would "look" to find boot loader code which would in turn load Linux, and our hard drives were partitioned into different regions using the standard MBR partition scheme. That was just how it was done. And we liked it that way!<br />
<br />
<!--T:30--><br />
Then, along came EFI and UEFI, which are new-style firmware designed to boot systems, along with GPT partition tables to define disk partitions on disks larger than 2.2TB. All of the sudden, we had a variety of options for installing and booting Linux systems, turning what once was a one-method-fits-all approach into something a lot more complex.<br />
<br />
<!--T:31--><br />
Let's take a moment to review the options available to you for configuring a hard drive to boot Funtoo Linux. This Install Guide uses, and recommends, the old-school method of BIOS booting and using an MBR. It works and (except for rare cases) is universally supported. There's nothing wrong with it. If your system disk is 2TB or smaller in size, it won't prevent you from using all of your disk's capacity, either.<br />
<br />
<!--T:32--><br />
But, there are some situations where the old-school method isn't optimal. If you have a system disk >2TB in size, then MBR partitions won't allow you to access all your storage. So that's one reason. Another reason is that there are some so-called "PC" systems out there that don't support BIOS booting anymore, and force you to use UEFI to boot. So, out of compassion for people who fall into this predicament, this Install Guide documents UEFI booting too.<br />
<br />
<!--T:33--><br />
Our recommendation is still to go old-school unless you have reason not to. The boot loader we will be using to load the Linux kernel in this guide is called GRUB, so we call this method the '''BIOS + GRUB (MBR)''' method. It's the traditional method of setting up a PC-compatible system to boot Linux.<br />
<br />
<!--T:34--><br />
If you need to use UEFI to boot, we recommend not using the MBR at all for booting, as some systems support this, but others don't. Instead, we recommend using UEFI to boot GRUB, which in turn will load Linux. We refer to this method as the '''UEFI + GRUB (GPT)''' method.<br />
<br />
<!--T:35--><br />
And yes, there are even more methods, some of which are documented on the [[Boot Methods]] page. We used to recommend a '''BIOS + GRUB (GPT)''' method but it is not consistently supported across a wide variety of hardware.<br />
<br />
==== Which to Use? ==== <!--T:36--><br />
<br />
<!--T:37--><br />
'''The big question is -- which boot method should you use?''' Here's how to tell.<br />
<br />
<!--T:38--><br />
;Principle 1 - Old School: If you can reliably boot System Rescue CD and it shows you an initial light blue menu, you are booting the CD using the BIOS, and it's likely that you can thus boot Funtoo Linux using the BIOS. So, go old-school and use BIOS booting, ''unless'' you have some reason to use UEFI, such as having a >2.2TB system disk. In that case, see Principle 2, as your system may also support UEFI booting.<br />
<br />
<!--T:39--><br />
;Principle 2 - New School: If you can reliably boot System Rescue CD and it shows you an initial black and white menu -- congratulations, your system is configured to support UEFI booting. This means that you are ready to install Funtoo Linux to boot via UEFI. Your system may still support BIOS booting, but just be trying UEFI first. You can poke around in your BIOS boot configuration and play with this.<br />
<br />
<!--T:40--><br />
{{Note|'''Advanced Users May Wonder:''' What's the Big Difference between Old School and New School?: Here's the deal. If you go with old-school MBR partitions, your {{f|/boot}} partition will be an ext2 filesystem, and you'll use {{c|fdisk}} to create your MBR partitions. If you go with new-school GPT partitions and UEFI booting, your {{f|/boot}} partition will be a vfat filesystem, because this is what UEFI is able to read, and you will use {{c|gdisk}} to create your GPT partitions. And you'll install GRUB a bit differently. That's about all it comes down to, in case you were curious.}}<br />
<br />
<!--T:41--><br />
To install Funtoo Linux to boot via the New School UEFI method, you must boot System Rescue CD using UEFI. If you successfully boot sysresccd with UEFI, you will see an initial black and white screen to select the mode in which you will boot system rescue cd. Otherwise, if you see a blue screen with black text, UEFI will not be active and you will not be able to set up UEFI booting later in the install process!<br />
<br />
<!--T:42--><br />
{{Note|'''Some motherboards may appear to support UEFI, but don't.''' Do your research. For example, the Award BIOS in my Gigabyte GA-990FXA-UD7 rev 1.1 has an option to enable UEFI boot for CD/DVD. '''This is not sufficient for enabling UEFI boot for hard drives and installing Funtoo Linux.''' UEFI must be supported for both removable media (so you can boot System Rescue CD using UEFI) as well as fixed media (so you can boot your new Funtoo Linux installation.) It turns out that later revisions of this board (rev 3.0) have a new BIOS that fully supports UEFI boot. This may point to a third principle -- know thy hardware.}}<br />
<br />
==== Old-School (BIOS/MBR) Method ==== <!--T:43--> <br />
<br />
<!--T:44--><br />
{{Note|Use this method if you are booting using your BIOS, and if your System Rescue CD initial boot menu was light blue. If you're going to use the new-school method, [[#New-School (UEFI/GPT) Method|click here to jump down to UEFI/GPT.]]}}<br />
<br />
<!--T:46--><br />
First, it's a good idea to make sure that you've found the correct hard disk to partition. Try this command and verify that {{f|/dev/sda}} is the disk that you want to partition:<br />
</translate><br />
{{console|body=<br />
###i## fdisk -l /dev/sda<br />
<br />
Disk /dev/sda: 640.1 GB, 640135028736 bytes, 1250263728 sectors<br />
Units = sectors of 1 * 512 = 512 bytes<br />
Sector size (logical/physical): 512 bytes / 512 bytes<br />
I/O size (minimum/optimal): 512 bytes / 512 bytes<br />
Disk label type: gpt<br />
<br />
# Start End Size Type Name<br />
1 2048 1250263694 596.2G Linux filesyste Linux filesystem<br />
}}<br />
<translate><!--T:47--><br />
Now, it is recommended that you erase any existing MBR or GPT partition tables on the disk, which could confuse the system's BIOS at boot time. We accomplish this using {{c|sgdisk}}:<br />
{{Warning|This will make any existing partitions inaccessible! You are '''strongly''' cautioned and advised to backup any critical data before proceeding.}}</translate><br />
<br />
{{console|body=<br />
###i## sgdisk --zap-all /dev/sda<br />
<br />
Creating new GPT entries.<br />
GPT data structures destroyed! You may now partition the disk using fdisk or<br />
other utilities.<br />
}}<br />
<translate><!--T:48--><br />
This output is also nothing to worry about, as the command still succeded:</translate><br />
<br />
{{console|body=<br />
***************************************************************<br />
Found invalid GPT and valid MBR; converting MBR to GPT format<br />
in memory. <br />
***************************************************************<br />
}}<translate><br />
<!--T:50--><br />
Now we will use {{c|fdisk}} to create the MBR partition table and partitions:<br />
</translate><br />
{{console|body=<br />
###i## fdisk /dev/sda<br />
}}<br />
<translate><br />
<!--T:51--><br />
Within {{c|fdisk}}, follow these steps:<br />
<br />
<!--T:52--><br />
'''Empty the partition table''':<br />
</translate><br />
{{console|body=<br />
Command (m for help): ##i##o ↵<br />
}}<br />
<translate><!--T:53--><br />
'''Create Partition 1''' (boot):</translate><br />
<br />
{{console|body=<br />
Command (m for help): ##i##n ↵<br />
Partition type (default p): ##i##↵<br />
Partition number (1-4, default 1): ##i##↵<br />
First sector: ##i##↵<br />
Last sector: ##i##+128M ↵<br />
}}<br />
<translate><!--T:54--><br />
'''Create Partition 2''' (swap):</translate><br />
<br />
{{console|body=<br />
Command (m for help): ##i##n ↵<br />
Partition type (default p): ##i##↵<br />
Partition number (2-4, default 2): ##i##↵<br />
First sector: ##i##↵<br />
Last sector: ##i##+2G ↵<br />
Command (m for help): ##i##t ↵ <br />
Partition number (1,2, default 2): ##i## ↵<br />
Hex code (type L to list all codes): ##i##82 ↵<br />
}}<br />
<translate><!--T:55--><br />
'''Create the root partition:'''</translate><br />
<br />
{{console|body=<br />
Command (m for help): ##i##n ↵<br />
Partition type (default p): ##i##↵<br />
Partition number (3,4, default 3): ##i##↵<br />
First sector: ##i##↵<br />
Last sector: ##i##↵<br />
}}<br />
<translate><!--T:56--><br />
'''Verify the partition table:'''</translate><br />
<br />
{{console|body=<br />
Command (m for help): ##i##p<br />
<br />
Disk /dev/sda: 298.1 GiB, 320072933376 bytes, 625142448 sectors<br />
Units: sectors of 1 * 512 = 512 bytes<br />
Sector size (logical/physical): 512 bytes / 512 bytes<br />
I/O size (minimum/optimal): 512 bytes / 512 bytes<br />
Disklabel type: dos<br />
Disk identifier: 0x82abc9a6<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/sda1 2048 264191 131072 83 Linux<br />
/dev/sda2 264192 4458495 2097152 82 Linux swap / Solaris<br />
/dev/sda3 4458496 625142447 310341976 83 Linux<br />
}}<br />
<translate><!--T:57--><br />
'''Write the parition table to disk:'''</translate><br />
<br />
{{console|body=Command (m for help): ##i##w}}<br />
<translate><!--T:58--><br />
Your new MBR partition table will now be written to your system disk.<br />
<br />
<!--T:59--><br />
{{Note|You're done with partitioning! Now, jump over to [[#Creating filesystems|Creating filesystems]].}}<br />
<br />
==== New-School (UEFI/GPT) Method ==== <!--T:60--> <br />
<br />
<!--T:61--><br />
{{Note|Use this method if you are interested in booting using UEFI, and if your System Rescue CD initial boot menu was black and white. If it was light blue, this method will not work.}}<br />
<br />
<!--T:62--><br />
The {{c|gdisk}} commands to create a GPT partition table are as follows. Adapt sizes as necessary, although these defaults will work for most users. Start {{c|gdisk}}:<br />
</translate><br />
{{console|body=###i## gdisk /dev/sda}}<br />
<translate><!--T:63--><br />
Within {{c|gdisk}}, follow these steps:<br />
<br />
<!--T:64--><br />
'''Create a new empty partition table''' (This ''will'' erase all data on the disk when saved):<br />
</translate><br />
{{console|body=<br />
Command: ##i##o ↵<br />
This option deletes all partitions and creates a new protective MBR.<br />
Proceed? (Y/N): ##i##y ↵<br />
}}<br />
<translate><!--T:65--><br />
'''Create Partition 1''' (boot):</translate><br />
<br />
{{console|body=<br />
Command: ##i##n ↵<br />
Partition Number: ##i##1 ↵<br />
First sector: ##i##↵<br />
Last sector: ##i##+500M ↵<br />
Hex Code: ##i##EF00 ↵<br />
}}<br />
<translate><!--T:66--><br />
'''Create Partition 2''' (swap):</translate><br />
<br />
{{console|body=<br />
Command: ##i##n ↵<br />
Partition Number: ##i##2 ↵<br />
First sector: ##i##↵<br />
Last sector: ##i##+4G ↵<br />
Hex Code: ##i##8200 ↵<br />
}}<br />
<translate><!--T:67--><br />
'''Create Partition 3''' (root):</translate><br />
<br />
{{console|body=<br />
Command: ##i##n ↵<br />
Partition Number: ##i##3 ↵<br />
First sector: ##i##↵<br />
Last sector: ##i##↵##!i## (for rest of disk)<br />
Hex Code: ##i##↵<br />
}}<br />
<translate><!--T:68--><br />
Along the way, you can type "{{c|p}}" and hit Enter to view your current partition table. If you make a mistake, you can type "{{c|d}}" to delete an existing partition that you created. When you are satisfied with your partition setup, type "{{c|w}}" to write your configuration to disk:<br />
<br />
<!--T:69--><br />
'''Write Partition Table To Disk''':<br />
</translate><br />
{{console|body=<br />
Command: ##i##w ↵<br />
Do you want to proceed? (Y/N): ##i##Y ↵<br />
}}<translate><br />
<!--T:70--><br />
The partition table will now be written to the disk and {{c|gdisk}} will close.<br />
<br />
<!--T:71--><br />
Now, your GPT/GUID partitions have been created, and will show up as the following ''block devices'' under Linux:<br />
<br />
<!--T:72--><br />
* {{c|/dev/sda1}}, which will be used to hold the {{c|/boot}} filesystem, <br />
<br />
<!--T:73--><br />
* {{c|/dev/sda2}}, which will be used for swap space, and <br />
<br />
<!--T:74--><br />
* {{c|/dev/sda3}}, which will hold your root filesystem.<br />
<br />
{{Tip|You can verify that the block devices above were correctly created by running the command {{c|lsblk}}.}}<br />
==== Creating filesystems ==== <!--T:75--> <br />
<br />
<!--T:76--><br />
{{Note|This section covers both BIOS ''and'' UEFI installs. Don't skip it!}}<br />
<br />
<!--T:77--><br />
Before your newly-created partitions can be used, the block devices that were created in the previous step need to be initialized with filesystem ''metadata''. This process is known as ''creating a filesystem'' on the block devices. After filesystems are created on the block devices, they can be mounted and used to store files.<br />
<br />
<!--T:78--><br />
Let's keep this simple. Are you using old-school MBR partitions? If so, let's create an ext2 filesystem on {{f|/dev/sda1}}:<br />
</translate><br />
{{console|body=###i## mkfs.ext2 /dev/sda1}}<br />
<translate><!--T:79--><br />
If you're using new-school GPT partitions for UEFI, you'll want to create a vfat filesystem on {{c|/dev/sda1}}, because this is what UEFI is able to read:<br />
</translate><br />
{{console|body=###i## mkfs.vfat -F 32 /dev/sda1}}<br />
<translate><!--T:80--><br />
Now, let's create a swap partition. This partition will be used as disk-based virtual memory for your Funtoo Linux system.<br />
<br />
<!--T:81--><br />
You will not create a filesystem on your swap partition, since it is not used to store files. But it is necessary to initialize it using the {{c|mkswap}} command. Then we'll run the {{c|swapon}} command to make your newly-initialized swap space immediately active within the live CD environment, in case it is needed during the rest of the install process:<br />
</translate><br />
{{console|body=<br />
# ##i##mkswap /dev/sda2<br />
# ##i##swapon /dev/sda2<br />
}}<translate><br />
<!--T:82--><br />
Now, we need to create a root filesystem. This is where Funtoo Linux will live. We generally recommend ext4 or XFS root filesystems. If you're not sure, choose ext4. Here's how to create a root ext4 filesystem:</translate><br />
<br />
{{console|body=###i## mkfs.ext4 /dev/sda3}}<br />
<translate><!--T:83--><br />
...and here's how to create an XFS root filesystem, if you prefer to use XFS instead of ext4:</translate><br />
<br />
{{console|body=###i## mkfs.xfs /dev/sda3}}<br />
<translate><!--T:84--><br />
Your filesystems (and swap) have all now been initialized, so that that can be mounted (attached to your existing directory heirarchy) and used to store files. We are ready to begin installing Funtoo Linux on these brand-new filesystems.<br />
<br />
<!--T:85--><br />
{{Warning|When deploying an OpenVZ host, please use ext4 exclusively. The Parallels development team tests extensively with ext4, and modern versions of {{c|openvz-rhel6-stable}} are '''not''' compatible with XFS, and you may experience kernel bugs.}}<br />
<br />
==== Mounting filesystems ==== <!--T:86--> <br />
<br />
<!--T:87--><br />
Mount the newly-created filesystems as follows, creating {{c|/mnt/funtoo}} as the installation mount point:<br />
</translate><br />
{{console|body=<br />
###i## mkdir /mnt/funtoo<br />
###i## mount /dev/sda3 /mnt/funtoo<br />
###i## mkdir /mnt/funtoo/boot<br />
###i## mount /dev/sda1 /mnt/funtoo/boot<br />
}}<br />
<translate><!--T:88--><br />
Optionally, if you have a separate filesystem for {{f|/home}} or anything else:</translate><br />
<br />
{{console|body=<br />
###i## mkdir /mnt/funtoo/home<br />
###i## mount /dev/sda4 /mnt/funtoo/home<br />
}}<br />
<translate><!--T:89--><br />
If you have {{f|/tmp}} or {{f|/var/tmp}} on a separate filesystem, be sure to change the permissions of the mount point to be globally-writeable after mounting, as follows:</translate><br />
{{console|body=###i## chmod 1777 /mnt/funtoo/tmp}}<translate><br />
<br />
==== Setting the Date ==== <!--T:90--> <br />
<br />
<!--T:91--><br />
{{Important|If your system's date and time are too far off (typically by months or years,) then it may prevent Portage from properly downloading source tarballs. This is because some of our sources are downloaded via HTTPS, which use SSL certificates and are marked with an activation and expiration date. However, if your system time is relatively close to correct, you can probably skip this step for now.}}<br />
<br />
<!--T:92--><br />
Now is a good time to verify the date and time are correctly set to UTC. Use the {{c|date}} command to verify the date and time:<br />
</translate><br />
{{console|body=<br />
###i## date<br />
Fri Jul 15 19:47:18 UTC 2011<br />
}}<br />
<translate><!--T:93--><br />
If the date and/or time need to be corrected, do so using {{c|date MMDDhhmmYYYY}}, keeping in mind {{c|hhmm}} are in 24-hour format. The example below changes the date and time to "July 16th, 2011 @ 8:00PM" UTC:</translate><br />
<br />
{{console|body=<br />
###i## date 071620002011<br />
Fri Jul 16 20:00:00 UTC 2011<br />
}}<br />
<translate><!--T:94--><br />
Once you have set the system clock, it's a very good idea to copy the time to the hardware clock, so it persists across reboots:</translate><br />
<br />
{{console|body=###i## hwclock --systohc}}<br />
<translate><br />
=== Installing the Stage 3 tarball === <!--T:95--> <br />
<br />
<!--T:96--><br />
Now that filesystems are created and your hardware and system clock are set, the next step is downloading the initial Stage 3 tarball. The Stage 3 is a pre-compiled system used as a starting point to install Funtoo Linux. Notice: if you're using virtual machines (like Vbox) generic stage3 images are preferred rather than cpu-optimized ones.<br />
<br />
<!--T:97--><br />
To download the correct build of Funtoo Linux for your system, head over to the [[Subarches]] page. Subarches are builds of Funtoo Linux that are designed to run on a particular type of CPU, to offer the best possible performance. They also take advantage of the instruction sets available for each CPU.<br />
<br />
<!--T:98--><br />
The [[Subarches]] page lists all CPU-optimized versions of Funtoo Linux. Find the one that is appropriate for the type of CPU that your system has, and then click on its name in the first column (such as {{c|corei7}}, for example.) You will then go to a page dedicated to that subarch, and the available stage3's available for download will be listed.<br />
<br />
<!--T:99--><br />
For most subarches, you will have several stage3's available to choose from. This next section will help you understand which one to pick.<br />
<br />
==== Which Build? ==== <!--T:100--> <br />
<br />
<!--T:101--><br />
'''If you're not sure, pick {{c|funtoo-current}}.'''<br />
<br />
<!--T:102--><br />
Funtoo Linux has various different 'builds':<br />
<br />
<!--T:103--><br />
{{TableStart}}<br />
{{2ColHead|Build|Description}}<br />
<tr><td>{{c|funtoo-current}}</td><td>The most commonly-selected build of Funtoo Linux. Receives rapid updates and preferred by desktop users.</td></tr><br />
<tr><td>{{c|funtoo-stable}}</td><td>Emphasizes less-frequent package updates and trusted, reliable versions of packages over the latest versions.</td></tr><br />
{{TableEnd}}<br />
<br />
==== Which Variant? ==== <!--T:104--> <br />
<br />
<!--T:105--><br />
'''If you're not sure, pick {{c|standard}}.'''<br />
<br />
<!--T:106--><br />
Our "regular" stage3's are listed with a variant of {{c|standard}}. The following variant builds are available:<br />
<br />
<!--T:107--><br />
{{TableStart}}<br />
{{2ColHead|Variant|Description}}<br />
<tr><td>{{c|standard}}</td><td>The "standard" version of Funtoo Linux</td></tr><br />
<tr><td>{{c|pure64}}</td><td>A 64-bit build that drops multilib (32-bit compatibility) support. Can be ideal for server systems.</td></tr><br />
<tr><td>{{c|hardened}}</td><td>Includes PIE/SSP toolchain for enhanced security. PIE does require the use of PaX in the kernel, while SSP works with any kernel, and provides enhanced security in user-space to avoid stack-based exploits. For expert users.</td></tr><br />
{{TableEnd}}<br />
<br />
==== Download the Stage3 ==== <!--T:108--> <br />
<br />
<!--T:109--><br />
Once you have found the stage3 that you would like to download, use {{c|wget}} to download the Stage 3 tarball you have chosen to use as the basis for your new Funtoo Linux system. It should be saved to the {{f|/mnt/funtoo}} directory as follows:<br />
</translate><br />
{{console|body=<br />
###i## cd /mnt/funtoo<br />
###i## wget http://build.funtoo.org/funtoo-current/x86-64bit/generic_64/stage3-latest.tar.xz<br />
}}<br />
<translate><!--T:110--><br />
Note that 64-bit systems can run 32-bit or 64-bit stages, but 32-bit systems can only run 32-bit stages. Make sure that you select a Stage 3 build that is appropriate for your CPU. If you are not certain, it is a safe bet to choose the {{c|generic_64}} or {{c|generic_32}} stage. Consult the [[Subarches]] page for more information.<br />
<br />
<!--T:111--><br />
Once the stage is downloaded, extract the contents with the following command, substituting in the actual name of your stage 3 tarball:</translate><br />
{{console|body=<br />
###i## tar xpf stage3-latest.tar.xz<br />
}}<translate><br />
<!--T:112--><br />
{{Important|It is very important to use {{c|tar's}} "{{c|'''p'''}}" option when extracting the Stage 3 tarball - it tells {{c|tar}} to ''preserve'' any permissions and ownership that exist within the archive. Without this option, your Funtoo Linux filesystem permissions will be incorrect.}}<br />
<br />
=== Chroot into Funtoo === <!--T:113--><br />
To install Funtoo Linux, the {{c|chroot}} command is first used. The chroot command will "switch into" the new Funtoo Linux system, so the commands you execute after running "chroot" will run within your newly-extracted Funtoo Linux system.<br />
<br />
<!--T:114--><br />
Before chrooting, there are a few things that need to be done to set up the chroot environment. You will need to mount {{f|/proc}}, {{f|/sys}} and {{f|/dev}} inside your new system. Use the following commands to do so:</translate><br />
{{console|body=<br />
# ##i##cd /mnt/funtoo<br />
# ##i##mount -t proc none proc<br />
# ##i##mount --rbind /sys sys<br />
# ##i##mount --rbind /dev dev<br />
}}<translate><br />
<!--T:115--><br />
You'll also want to copy over {{f|resolv.conf}} in order to have proper resolution of Internet hostnames from inside the chroot:</translate><br />
{{console|body=<br />
# ##i##cp /etc/resolv.conf /mnt/funtoo/etc/<br />
}}<translate><br />
<!--T:116--><br />
Now you can chroot into your new system. Use <code>env</code> before <code>chroot</code> to ensure that no environment settings from the installation media are pulled in to your new system:</translate><br />
<br />
{{console|body=###i## env -i HOME=/root TERM=$TERM chroot . bash -l}}<br />
<translate><!--T:117--><br />
{{Note|For users of live CDs with 64-bit kernels installing 32-bit systems: Some software may use {{c|uname -r}} to check whether the system is 32 or 64-bit. You may want append linux32 to the chroot command as a workaround, but it's generally not needed.}}<br />
{{Important|If you receive the error "{{c|chroot: failed to run command `/bin/bash': Exec format error}}", it is most likely because you are running a 32-bit kernel and trying to execute 64-bit code. Make sure that you have selected the proper type of kernel when booting SystemRescueCD.}}<br />
<br />
<!--T:118--><br />
It's also a good idea to change the default command prompt while inside the chroot. This will avoid confusion if you have to change terminals. Use this command:<br />
{{console|body=# ##i##export PS1="(chroot) $PS1"}}<br />
Test internet name resolution from within the chroot:<br />
{{console|body=###i## ping -c 5 google.com}}<br />
If you can't ping, make sure {{f|/etc/resolv.conf}} doesn't contain things like {{c|127.0.x.x}} addresses, if it does, change the {{c|127.0.x.x}} entry to {{c|8.8.8.8}} -- Google's public dns address. Make sure to replace this with your dns of choice once the system is installed.<br />
<br />
<br />
Congratulations! You are now chrooted inside a Funtoo Linux system. Now it's time to get Funtoo Linux properly configured so that Funtoo Linux will start successfully, without any manual assistance, when your system is restarted.<br />
=== Downloading the Portage tree === <!--T:119--> <br />
<br />
<!--T:120--><br />
{{note|For an alternative way to do this, see [[Installing Portage From Snapshot]].}}<br />
Now it's time to install a copy of the Portage repository, which contains package scripts (ebuilds) that tell portage how to build and install thousands of different software packages. To create the Portage repository, simply run <code>emerge --sync</code> from within the chroot. This will automatically clone the portage tree from [https://github.com/funtoo/ports-2012 GitHub]:<br />
</translate><br />
<br />
{{console|body=<br />
(chroot) ###i## emerge --sync<br />
}}<br />
<translate><br />
<!--T:121--><br />
{{important|If you receive the error with initial {{c|emerge --sync}} due to git protocol restrictions, set the {{c|SYNC}} variable in {{c|/etc/portage/make.conf}} to <br />
{{c|"https://github.com/funtoo/ports-2012.git"}}<br />
}}<br />
<br />
=== Configuring your system === <!--T:123--><br />
As is expected from a Linux distribution, Funtoo Linux has its share of configuration files. The one file you are absolutely required to edit in order to ensure that Funtoo Linux boots successfully is {{f|/etc/fstab}}. The others are optional. <br />
<br />
==== Using Nano ==== <!--T:124--> <br />
<br />
<!--T:125--><br />
The default editor included in the chroot environment is called {{c|nano}}. To edit one of the files below, run nano as follows:<br />
<br />
<!--T:126--><br />
{{console|body=<br />
(chroot) ###i## nano /etc/fstab<br />
}}<br />
When in the editor, you can use arrow keys to move the cursor, and common keys like backspace and delete will work as expected. To save the file, press Control-X, and answer {{c|y}} when prompted to save the modified buffer if you would like to save your changes.<br />
<br />
==== Configuration Files ==== <!--T:127--> <br />
<br />
<!--T:128--><br />
Here are a full list of files that you may want to edit, depending on your needs:<br />
{{TableStart}}<br />
{{3ColHead|File|Do I need to change it?|Description}}<br />
<tr class="danger"><br />
<td>{{c|/etc/fstab}}</td><br />
<td>'''YES - required'''</td><br />
<td>Mount points for all filesystems to be used at boot time. This file must reflect your disk partition setup. We'll guide you through modifying this file below.</td><br />
</tr><tr><br />
<td>{{c|/etc/localtime}}</td><br />
<td>''Maybe - recommended''</td><br />
<td>Your timezone, which will default to UTC if not set. This should be a symbolic link to something located under /usr/share/zoneinfo (e.g. /usr/share/zoneinfo/America/Montreal) </td><br />
</tr><tr><br />
<td>{{c|/etc/make.conf}} (symlink) - also known as:<br/>{{c|/etc/portage/make.conf}}</td><br />
<td>''Maybe - recommended''</td><br />
<td>Parameters used by gcc (compiler), portage, and make. It's a good idea to set MAKEOPTS. This is covered later in this document.</td><br />
</tr><tr><br />
<td>{{c|/etc/conf.d/hostname}}</td><br />
<td>''Maybe - recommended''</td><br />
<td>Used to set system hostname. Set the {{c|hostname}} variable to the fully-qualified (with dots, ie. {{c|foo.funtoo.org}}) name if you have one. Otherwise, set to the local system hostname (without dots, ie. {{c|foo}}). Defaults to {{c|localhost}} if not set.</td><br />
</tr><tr><br />
<td>{{c|/etc/hosts}}</td><br />
<td>''No''</td><br />
<td> You no longer need to manually set the hostname in this file. This file is automatically generated by {{c|/etc/init.d/hostname}}.</td><br />
</tr><tr><br />
<td>{{c|/etc/conf.d/keymaps}}</td><br />
<td>Optional</td><br />
<td>Keyboard mapping configuration file (for console pseudo-terminals). Set if you have a non-US keyboard. See [[Funtoo Linux Localization]].</td><br />
</tr><tr><br />
<td>{{c|/etc/conf.d/hwclock}}</td><br />
<td>Optional</td><br />
<td>How the time of the battery-backed hardware clock of the system is interpreted (UTC or local time). Linux uses the battery-backed hardware clock to initialize the system clock when the system is booted.</td><br />
</tr><tr><br />
<td>{{c|/etc/conf.d/modules}}</td><br />
<td>Optional</td><br />
<td>Kernel modules to load automatically at system startup. Typically not required. See [[Additional Kernel Resources]] for more info.</td><br />
</tr><tr><br />
<td>{{c|/etc/conf.d/consolefont}}</td><br />
<td>Optional</td><br />
<td>Allows you to specify the default console font. To apply this font, enable the consolefont service by running rc-update add consolefont.</td><br />
</tr><tr><br />
<td>{{c|profiles}}</td><br />
<td>Optional</td><br />
<td>Some useful portage settings that may help speed up intial configuration.</td><br />
</tr><br />
{{TableEnd}}<br />
<br />
<!--T:129--><br />
If you're installing an English version of Funtoo Linux, you're in luck, as most of the configuration files can be used as-is. If you're installing for another locale, don't worry. We will walk you through the necessary configuration steps on the [[Funtoo Linux Localization]] page, and if needed, there's always plenty of friendly, helpful support available. (See [[#Community portal|Community]])<br />
<br />
<!--T:130--><br />
Let's go ahead and see what we have to do. Use {{c|nano -w <name_of_file>}} to edit files -- the "{{c|-w}}" argument disables word-wrapping, which is handy when editing configuration files. You can copy and paste from the examples.<br />
<br />
<!--T:131--><br />
{{Warning|It's important to edit your {{c|/etc/fstab}} file before you reboot! You will need to modify both the "fs" and "type" columns to match the settings for your partitions and filesystems that you created with {{c|gdisk}} or {{c|fdisk}}. Skipping this step may prevent Funtoo Linux from booting successfully.}}<br />
<br />
==== /etc/fstab ==== <!--T:132--><br />
<br />
<!--T:133--><br />
{{f|/etc/fstab}} is used by the {{c|mount}} command which is run when your system boots. Lines in this file inform {{c|mount}} about filesystems to be mounted and how they should be mounted. In order for the system to boot properly, you must edit {{f|/etc/fstab}} and ensure that it reflects the partition configuration you used earlier in the install process. If you can't remember the partition configuration that you used earlier, the {{c|lsblk}} command may be of help to you:<br />
</translate><br />
{{console|body=<br />
(chroot) ###i## nano -w /etc/fstab<br />
}}<br />
{{file|name=/etc/fstab|desc=An example fstab file|body=<br />
# The root filesystem should have a pass number of either 0 or 1.<br />
# All other filesystems should have a pass number of 0 or greater than 1.<br />
#<br />
# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.<br />
#<br />
# See the manpage fstab(5) for more information.<br />
#<br />
# <fs> <mountpoint> <type> <opts> <dump/pass><br />
<br />
/dev/sda1 /boot ext2 noauto,noatime 1 2<br />
/dev/sda2 none swap sw 0 0<br />
/dev/sda3 / ext4 noatime 0 1<br />
#/dev/cdrom /mnt/cdrom auto noauto,ro 0 0<br />
}}<br />
<translate><br />
<!--T:134--><br />
{{Note|Currently, our default {{f|/etc/fstab}}file has the root filesystem as {{c|/dev/sda4}} and the swap partition as {{c|/dev/sda3}}. These will need to be changed to {{c|/dev/sda3}} and {{c|/dev/sda2}}, respectively.}}<br />
<br />
<!--T:135--><br />
{{Note|If you're using UEFI to boot, change the {{f|/dev/sda1}} line so that it says {{c|vfat}} instead of {{c|ext2}}. Similarly, make sure that the {{f|/dev/sda3}} line specifies either {{c|xfs}} or {{c|ext4}}, depending on which filesystem you chose earlier on in the installation process when you created filesystems.}}<br />
<br />
==== /etc/localtime ==== <!--T:136--> <br />
<br />
<!--T:137--><br />
{{f|/etc/localtime}} is used to specify the timezone that your machine is in, and defaults to UTC. If you would like your Funtoo Linux system to use local time, you should replace {{f|/etc/localtime}} with a symbolic link to the timezone that you wish to use. <br />
<br />
<!--T:138--><br />
{{console|body=<br />
(chroot) ###i## ln -sf /usr/share/zoneinfo/MST7MDT /etc/localtime<br />
}}<br />
The above sets the timezone to Mountain Standard Time (with daylight savings). Type {{c|ls /usr/share/zoneinfo}} to list available timezones. There are also sub-directories containing timezones described by location.<br />
<br />
==== /etc/portage/make.conf ==== <!--T:139--> <br />
<br />
<!--T:140--><br />
{{c|MAKEOPTS}} can be used to define how many parallel compilations should occur when you compile a package, which can speed up compilation significantly. A rule of thumb is the number of CPUs (or CPU threads) in your system plus one. If, for example, you have a dual core processor without [[wikipedia:Hyper-threading|hyper-threading]], then you would set {{c|MAKEOPTS}} to 3:<br />
<br />
<!--T:141--><br />
<pre><br />
MAKEOPTS="-j3" <br />
</pre><br />
<br />
<!--T:142--><br />
If you are unsure about how many processors/threads you have, then use {{c|nproc}} to help you.<br />
{{console|body=<br />
(chroot) ###i## nproc<br />
16<br />
}}<br />
Set {{c|MAKEOPTS}} to this number plus one:<br />
<br />
<!--T:143--><br />
<pre><br />
MAKEOPTS="-j17"<br />
</pre><br />
<br />
<!--T:144--><br />
{{c|USE}} flags define what functionality is enabled when packages are built. It is not recommended to add a lot of USE flags during installation; you should wait until you have a working, bootable system before changing your USE flags. A USE flag prefixed with a minus ("{{c|-}}") sign tells Portage not to use the flag when compiling. A Funtoo guide to USE flags will be available in the future. For now, you can find out more information about USE flags in the [http://www.gentoo.org/doc/en/handbook/handbook-amd64.xml?part=2&chap=2 Gentoo Handbook].<br />
<br />
<!--T:145--><br />
{{c|LINGUAS}} tells Portage which local language to compile the system and applications in (those who use LINGUAS variable like OpenOffice). It is not usually necessary to set this if you use English. If you want another language such as French (fr) or German (de), set LINGUAS appropriately:<br />
<br />
<!--T:146--><br />
<pre><br />
LINGUAS="fr"<br />
</pre><br />
<br />
==== /etc/conf.d/hwclock ==== <!--T:147--><br />
If you dual-boot with Windows, you'll need to edit this file and change the value of '''clock''' from '''UTC''' to '''local''', because Windows will set your hardware clock to local time every time you boot Windows. Otherwise you normally wouldn't need to edit this file.<br />
{{console|body=<br />
(chroot) ###i## nano -w /etc/conf.d/hwclock<br />
}}<br />
==== Localization ====<br />
<br />
<!--T:148--><br />
By default, Funtoo Linux is configured with Unicode (UTF-8) enabled, and for the US English locale and keyboard. If you would like to configure your system to use a non-English locale or keyboard, see [[Funtoo Linux Localization]].<br />
<br />
=== Introducing Portage === <!--T:149--> <br />
<br />
<!--T:150--><br />
Portage, the Funtoo Linux package manager has a command called <code>emerge</code> which is used to build and install packages from source. It also takes care of installing all of the package's dependencies. You call emerge like this:<br />
<br />
<!--T:151--><br />
<console><br />
(chroot) # ##i##emerge packagename<br />
</console><br />
<br />
<!--T:152--><br />
When you install a package by specifying its name in the command-line, Portage records its name in the <code>/var/lib/portage/world</code> file. It does so because it assumes that, since you have installed it by name, you want to consider it part of your system and want to keep the package updated in the future. This is a handy feature, since when packages are being added to the <code>world</code> set, we can update our entire system by typing:<br />
<br />
<!--T:153--><br />
<console><br />
(chroot) # ##i##emerge --sync<br />
(chroot) # ##i##emerge -auDN @world<br />
</console><br />
<br />
<!--T:154--><br />
This is the "official" way to update your Funtoo Linux system. Above, we first update our Portage tree using git to grab the latest ebuilds (scripts), and then run an emerge command to update the <code>world</code> set of packages. The options specified tell <code>emerge</code> to:<br />
<br />
<!--T:155--><br />
* '''<code>a</code>''' - show us what will be emerged, and '''ask''' us if we want to proceed<br />
* '''<code>u</code>''' - '''update''' the packages we specify -- don't emerge them again if they are already emerged.<br />
* '''<code>D</code>''' - Consider the entire dependency tree of packages when looking for updates. In other words, do a '''deep''' update.<br />
* '''<code>N</code>''' - Update any packages that have changed ('''new''') USE settings.<br />
<br />
<!--T:156--><br />
You should also consider passing <code>--with-bdeps=y</code> when emerging @world, at least once in a while. This will update build dependencies as well.<br />
<br />
<!--T:157--><br />
Of course, sometimes we want to install a package but not add it to the <code>world</code> file. This is often done because you only want the package installed temporarily or because you know the package in question is a dependnecy of another package. If this behavior is desired, you call emerge like this:<br />
<br />
<!--T:158--><br />
<console><br />
(chroot) # ##i##emerge -1 packagename<br />
</console><br />
<br />
<!--T:159--><br />
Advanced users may be interested in the [[Emerge]] wiki page.<br />
<br />
==== Updating World ==== <!--T:160--> <br />
<br />
<!--T:161--><br />
Now is actually a very good time to update the entire system and it can be a good idea to do so prior to first boot.<br />
<br />
<!--T:162--><br />
<console><br />
(chroot) # ##i##emerge --sync<br />
(chroot) # ##i##emerge -auDN @world<br />
</console><br />
<br />
<!--T:163--><br />
{{fancyimportant|1=<br />
Make sure you read any post emerge messages and follow their instructions. This is especially true if you have upgraded perl or python.}}<br />
<br />
=== Kernel === <!--T:164--> <br />
<br />
<!--T:165--><br />
Starting mid-May 2015, Funtoo Linux stage3's include a pre-built {{c|debian-sources}} kernel to make installation faster and easier. To see if debian-sources is installed, type:<br />
</translate><br />
{{console|body=<br />
(chroot) # ##i##emerge -s debian-sources<br />
Searching... <br />
[ Results for search key : ##b##debian-sources##!b## ]<br />
[ Applications found : ##b##1##!b## ]<br />
<br />
* ##b##sys-kernel/debian-sources##!b##<br />
##g##Latest version available:##!g## 3.19.3<br />
##g##Latest version installed:##!g## 3.19.3<br />
##g##Size of files:##!g## 81,292 kB<br />
##g##Homepage:##!g## http://www.debian.org<br />
##g##Description:##!g## Debian Sources (and optional binary kernel)<br />
##g##License:##!g## GPL-2<br />
}}<br />
<translate><br />
<!--T:166--><br />
If a version is listed under {{c|Latest version installed}}, then debian-sources is already pre-built for you and you can skip the rest of the Kernel section, and proceed to the [[#Installing a Bootloader|Installing a Bootloader section]].<br />
<br />
==== Building the Kernel ==== <!--T:167--> <br />
<br />
<!--T:168--><br />
If you need to build a kernel for Funtoo Linux, please follow these steps:<br />
<br />
<!--T:169--><br />
{{Fancynote|1=<br />
See [[Funtoo Linux Kernels]] for a full list of kernels supported in Funtoo Linux. We recommend <code>debian-sources</code> for new users.}}<br />
<br />
<!--T:170--><br />
{{fancyimportant|1=<br />
<code>debian-sources</code> with <code>binary</code> USE flag requires at least 14GB free in <code>/var/tmp</code> and takes around 1 hour to build on a Intel Core i7 Processor.}}<br />
<br />
<!--T:171--><br />
Let's emerge our kernel:<br />
<br />
<!--T:172--><br />
<console><br />
(chroot) # ##i##emerge debian-sources<br />
</console><br />
<br />
<!--T:173--><br />
Once <code>emerge</code> completes, you'll have a brand new kernel and initramfs installed to <code>/boot</code>, plus kernel headers installed in <code>/usr/src/linux</code>, and you'll be ready to configure the boot loader to load these to boot your Funtoo Linux system.<br />
<br />
<!--T:174--><br />
{{warning|If you have a RAID in your machine, the kernel installation will pull in the <code>mdadm</code> tool as a dependency. It is important to edit the <code>/etc/mdadm.conf</code> file prior to rebooting the machine so the RAID is properly recognised and set up before the kernel attempts to mount it in the tree. Failing to do so can result in an unusable or even unbootable system! For specific details, consult the mdadm man page <code>man mdadm</code> or the [[Package:Mdadm|mdadm]] ebuild page.}}<br />
<br />
<!--T:175--><br />
{{fancynote|NVIDIA card users: the <code>binary</code> USE flag installs the Nouveau drivers which cannot be loaded at the same time as the proprietary drivers, and cannot be unloaded at runtime because of KMS. You need to blacklist it under <code>/etc/modprobe.d/</code>.}}<br />
<br />
<!--T:176--><br />
{{fancynote|For an overview of other kernel options for Funtoo Linux, see [[Funtoo Linux Kernels]]. There may be modules that the Debian kernel doesn't include, a situation where [http://www.funtoo.org/wiki/Funtoo_Linux_Kernels#Using_Debian-Sources_with_Genkernel genkernel] would be useful. Also be sure to see [[:Category:Hardware Compatibility|hardware compatibility]] information.}}<br />
<br />
=== Installing a Bootloader === <!--T:177--><br />
<br />
<!--T:178--><br />
These install instructions show you how to use GRUB to boot using BIOS (old-school) or UEFI (new-school). As of boot-update-1.7.2, now in Portage, the steps are very similar.<br />
<br />
<!--T:179--><br />
First, emerge <code>boot-update</code>. This will also cause <code>grub-2</code> and {{c|efibootmgr}} to be merged, since they are dependencies:<br />
<br />
<!--T:180--><br />
<console><br />
(chroot) # ##i##emerge boot-update<br />
</console><br />
<br />
<!--T:181--><br />
Then, edit <code>/etc/boot.conf</code> using {{c|nano}} and specify "<code>Funtoo Linux genkernel</code>" as the <code>default</code> setting at the top of the file, replacing <code>"Funtoo Linux"</code>. <br />
<br />
<!--T:182--><br />
<code>/etc/boot.conf</code> should now look like this:<br />
</translate><br />
{{file|name=/etc/boot.conf|body=<br />
boot {<br />
generate grub<br />
default "Funtoo Linux genkernel" <br />
timeout 3 <br />
}<br />
<br />
"Funtoo Linux" {<br />
kernel bzImage[-v]<br />
}<br />
<br />
"Funtoo Linux genkernel" {<br />
kernel kernel[-v]<br />
initrd initramfs[-v]<br />
params += real_root=auto <br />
} <br />
<br />
"Funtoo Linux better-initramfs" {<br />
kernel vmlinuz[-v]<br />
initrd /initramfs.cpio.gz<br />
}<br />
}}<br />
<translate><br />
<!--T:183--><br />
If you are booting a custom or non-default kernel, please read <code>man boot.conf</code> for information on the various options available to you.<br />
<br />
==== Old School (BIOS) MBR ==== <!--T:184--> <br />
<br />
<!--T:185--><br />
When using "old school" BIOS booting, run the following command to install GRUB to your MBR, and generate the {{c|/boot/grub/grub.cfg}} configuration file that GRUB will use for booting:<br />
<br />
<!--T:186--><br />
<console><br />
(chroot) # ##i##grub-install --target=i386-pc --no-floppy /dev/sda<br />
(chroot) # ##i##boot-update<br />
</console><br />
<br />
==== New School (UEFI) Boot Entry ==== <!--T:187--><br />
<br />
<!--T:188--><br />
If you're using "new school" UEFI booting, run of the following sets of commands, depending on whether you are installing a 64-bit or 32-bit system. This will add GRUB as a UEFI boot entry.<br />
<br />
<!--T:189--><br />
For x86-64bit systems:<br />
<br />
<!--T:190--><br />
<console><br />
(chroot) # ##i##grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id="Funtoo Linux [GRUB]" --recheck /dev/sda<br />
(chroot) # ##i##boot-update<br />
</console><br />
<br />
<!--T:191--><br />
For x86-32bit systems:<br />
<br />
<!--T:192--><br />
<console><br />
(chroot) # ##i##grub-install --target=i386-efi --efi-directory=/boot --bootloader-id="Funtoo Linux [GRUB]" --recheck /dev/sda<br />
(chroot) # ##i##boot-update<br />
</console><br />
<br />
==== First Boot, and in the future... ==== <!--T:193--> <br />
<br />
<!--T:194--><br />
OK -- you are ready to boot! <br />
<br />
<!--T:195--><br />
You only need to run <code>grub-install</code> when you first install Funtoo Linux, but you need to re-run <code>boot-update</code> every time you modify your <code>/etc/boot.conf</code> file or add new kernels to your system. This will regenerate {{c|/boot/grub/grub.cfg}} so that you will have new kernels available in your GRUB boot menu, the next time you reboot.<br />
<br />
=== Configuring your network === <!--T:196--> <br />
<br />
<!--T:197--><br />
It's important to ensure that you will be able to connect to your local-area network after you reboot into Funtoo Linux. There are three approaches you can use for configuring your network: NetworkManager, dhcpcd, and the [[Funtoo Linux Networking]] scripts. Here's how to choose which one to use based on the type of network you want to set up.<br />
<br />
==== Wi-Fi ==== <!--T:198--><br />
<br />
<!--T:232--><br />
For laptop/mobile systems where you will be using Wi-Fi, roaming, and connecting to various networks NetworkManager is strongly recommended. <br />
Since Wi-Fi cards require firmware to operate, it is also recommended that you emerge the linux-firmware ebuild:<br />
<br />
<!--T:233--><br />
{{console|body=(chroot) # ##i##emerge linux-firmware networkmanager<br />
(chroot) ###i## rc-update add NetworkManager default<br />
}}<br />
The above command will ensure that NetworkManager starts after you boot into Funtoo Linux. Once you've completed these installation steps and have booted into Funtoo Linux, you can use the {{c|addwifi}} command to connect to a Wi-Fi access point:<br />
{{console|body=# ##i##addwifi -S wpa -K 'wifipassword' mywifinetwork}}<br />
For more information about NetworkManager, see the [[Package:NetworkManager|NetworkManager package page]].<br />
<br />
<!--T:234--><br />
{{Note|wpa_supplicant is also a good choice for wireless network connections. See the {{package|net-wireless/wpa_supplicant}} package for steps involved in setting up wpa_supplicant.}}<br />
<br />
==== Desktop (Wired DHCP) ==== <!--T:200--> <br />
<br />
<!--T:201--><br />
For a home desktop or workstation with wired Ethernet that will use DHCP, the simplest and most effective option to enable network connectivity is to simply add {{c|dhcpcd}} to the default runlevel:<br />
<br />
<!--T:203--><br />
{{console|body=<br />
(chroot) # ##i##rc-update add dhcpcd default}}<br />
When you reboot, {{c|dhcpcd}} will run in the background and manage all network interfaces and use DHCP to acquire network addresses from a DHCP server.<br />
<br />
<!--T:204--><br />
If your upstream DHCP server is dnsmasq, it can be configured to assign addresses via mac address to make servers on DHCP feasible.<br />
<br />
==== Server (Static IP) ==== <!--T:205--><br />
<br />
<!--T:235--><br />
For servers, the [[Funtoo Linux Networking]] scripts are recommended. They are optimized for static configurations and things like virtual ethernet bridging for virtualization setups. See [[Funtoo Linux Networking]] for information on how to use Funtoo Linux's template-based network configuration system.<br />
<br />
==== Hostname ==== <!--T:207--><br />
By default Funtoo uses "localhost" as hostname. Although the system will work perfectly fine using this name, some ebuilds refuse to install when detecting localhost as hostname. It also may create confusion if several systems use the same hostname. Therefore, it is advised to change it to a more meaningful name. The hostname itself is arbitrary, meaning you can choose almost any combination of characters, as long as it makes sense to the system administrator. To change the hostname, edit<br />
<br />
<!--T:208--><br />
{{console|body=<br />
(chroot) # ##i##nano /etc/conf.d/hostname<br />
}}<br />
<br />
<!--T:209--><br />
Look for the line starting with hostname and change the entry between the quotes. Save the file, on the next boot Funtoo will use the new hostname.<br />
<br />
<!--T:210--><br />
{{warning|Do not use special characters in the hostname, as the shell may interpret these, leading to unpredictable results. Use the Latin alphabet: a-z, A-Z, 0-9}}<br />
{{tip|Use short hostnames (up to 8 or 10 characters) to prevent the terminal screen being filled with the hostname, leaving little space for the command itself. This become particularly poignant when coding long command strings in various programming languages like Bash, Python, SQL and Perl}}<br />
<br />
=== Finishing Steps === <!--T:211--><br />
==== Set your root password ==== <br />
It's imperative that you set your root password before rebooting so that you can log in.<br />
<console><br />
(chroot) # ##i##passwd<br />
</console><br />
<br />
===Restart your system === <!--T:212--> <br />
<br />
<!--T:213--><br />
Now is the time to leave chroot, to unmount Funtoo Linux partitions and files and to restart your computer. When you restart, the GRUB boot loader will start, load the Linux kernel and initramfs, and your system will begin booting.<br />
<br />
<!--T:214--><br />
Leave the chroot, change directory to /mnt, unmount your Funtoo partitions, and reboot.<br />
<console><br />
(chroot) # ##i##exit<br />
# ##i##cd /mnt<br />
# ##i##umount -lR funtoo<br />
# ##i##reboot<br />
</console><br />
<br />
<!--T:215--><br />
{{fancynote|System Rescue CD will gracefully unmount your new Funtoo filesystems as part of its normal shutdown sequence.}}<br />
<br />
<!--T:216--><br />
You should now see your system reboot, the GRUB boot loader appear for a few seconds, and then see the Linux kernel and initramfs loading. After this, you should see Funtoo Linux itself start to boot, and you should be greeted with a <code>login:</code> prompt. Funtoo Linux has been successfully installed!<br />
<br />
=== Profiles === <!--T:217--> <br />
<br />
<!--T:218--><br />
Once you have rebooted into Funtoo Linux, you can further customize your system to your needs by using [[Funtoo Profiles]]. A quick introduction to profiles is included below -- consult the [[Funtoo Profiles]] page for more detailed information. There are five basic profile types: arch, build, subarch, flavors and mix-ins:<br />
<br />
<!--T:220--><br />
{{TableStart}}<br />
{{2ColHead|Sub-Profile Type|Description}}<br />
{{2Col|{{c|arch}}|Typically {{c|x86-32bit}} or {{c|x86-64bit}}, this defines the processor type and support of your system. This is defined when your stage was built and should not be changed.}}<br />
{{2Col|{{c|build}}|Defines whether your system is a {{c|current}}, {{c|stable}} or {{c|experimental}} build. {{c|current}} systems will have newer packages unmasked than {{c|stable}} systems. This is defined when your stage is built and is typically not changed.}}<br />
{{2Col|{{c|subarch}}|Defines CPU optimizations for your system. The subarch is set at the time the stage3 is built, but can be changed later to better settings if necessary. Be sure to pick a setting that is compatible with your CPU.}}<br />
{{2Col|{{c|flavor}}|Defines the general type of system, such as {{c|server}} or {{c|desktop}}, and will set default USE flags appropriate for your needs.}}<br />
{{2Col|{{c|mix-ins}}|Defines various optional settings that you may be interested in enabling.}}<br />
{{TableEnd}}<br />
<br />
<!--T:221--><br />
One arch, build and flavor must be set for each Funtoo Linux system, while mix-ins are optional and you can enable more than one if desired. Often, flavors and mix-ins inherit settings from other sub-profiles. Use {{c|epro show}} to view your current profile settings, in addition to any inheritance information:</translate><br />
{{console|body=<br />
(chroot) # ##i## epro show<br />
<br />
=== ##g##Enabled Profiles##!g##: ===<br />
<br />
arch: ##c## x86-64bit<br />
build: ##c## current<br />
subarch: ##c## intel64-haswell<br />
flavor: ##c## desktop<br />
mix-ins: ##c## gnome<br />
<br />
<br />
=== ##g##All inherited flavors from desktop flavor##!g##: ===<br />
<br />
##c##workstation##!c## (from desktop flavor)<br />
##c##core##!c## (from workstation flavor)<br />
##c##minimal##!c## (from core flavor)<br />
<br />
=== ##g##All inherited mix-ins from desktop flavor##!g##: ===<br />
<br />
##c##X##!c## (from workstation flavor)<br />
##c##audio##!c## (from workstation flavor)<br />
##c##dvd##!c## (from workstation flavor)<br />
##c##media##!c## (from workstation flavor)<br />
##c##mediadevice-audio-consumer##!c## (from media mix-in)<br />
##c##mediadevice-base##!c## (from mediadevice-audio-consumer mix-in)<br />
##c##mediadevice-video-consumer##!c## (from media mix-in)<br />
##c##mediadevice-base##!c## (from mediadevice-video-consumer mix-in)<br />
##c##mediaformat-audio-common##!c## (from media mix-in)<br />
##c##mediaformat-gfx-common##!c## (from media mix-in)<br />
##c##mediaformat-video-common##!c## (from media mix-in)<br />
##c##console-extras##!c## (from workstation flavor)<br />
##c##print##!c## (from desktop flavor)<br />
}}<br />
<translate><br />
<!--T:223--><br />
Here are some basic examples of {{c|epro}} usage:<br />
{{TableStart}}<br />
{{2ColHead|Description|Command}}<br />
{{2Col|View available profiles. Enabled profiles will be highlighted in cyan. Directly enabled profiles will be in bold and have a {{c|*}} appended.|{{console|body=(chroot) # ##i##epro list}}}}<br />
{{2Col|Change the system flavor.|{{console|body=(chroot) # ##i##epro flavor desktop}}}}<br />
{{2Col|Add a mix-in.|{{console|body=(chroot) # ##i##epro mix-in +gnome}}}}<br />
{{TableEnd}}<br />
<br />
===Next Steps=== <!--T:228--> <br />
<br />
<!--T:229--><br />
If you are brand new to Funtoo Linux and Gentoo Linux, please check out [[Funtoo Linux First Steps]], which will help get you acquainted with your new system. We also have a category for our [[:Category:Official Documentation|official documentation]], which includes all docs that we officially maintain for installation and operation of Funtoo Linux.<br />
<br />
<!--T:230--><br />
We also have a number of pages dedicated to setting up your system. See [[:Category:First Steps|First Steps]] for a list of these pages.<br />
<br />
<!--T:231--><br />
If your system did not boot correctly, see [[Installation Troubleshooting]] for steps you can take to resolve the problem.<br />
[[Category:HOWTO]]<br />
[[Category:Install]]<br />
[[Category:Official Documentation]]<br />
</translate></div>Duncan.brittonhttps://www.funtoo.org/index.php?title=File:NetworkManagerIcon.PNG&diff=10697File:NetworkManagerIcon.PNG2015-06-30T18:07:40Z<p>Duncan.britton: Will be used in the install guide.</p>
<hr />
<div>Will be used in the install guide.</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Install/Chroot&diff=10696Install/Chroot2015-06-30T18:00:18Z<p>Duncan.britton: Edited /* Chroot into Funtoo */: moved all <console> tags over to {{console}}, changed the wording in a few places, and removed some extra spaces after some {{console}}s.</p>
<hr />
<div><noinclude><br />
{{InstallPart|the chroot process}}<br />
</noinclude><br />
=== Chroot into Funtoo ===<br />
To install Funtoo Linux, the {{c|chroot}} command is first used. The chroot command will "switch into" the new Funtoo Linux system, so the commands you execute after running "chroot" will run within your newly-extracted Funtoo Linux system.<br />
<br />
Before chrooting, there are a few things that need to be done to set up the chroot environment. You will need to mount {{f|/proc}}, {{f|/sys}} and {{f|/dev}} inside your new system. Use the following commands to do so:<br />
{{console|body=<br />
# ##i##cd /mnt/funtoo<br />
# ##i##mount -t proc none proc<br />
# ##i##mount --rbind /sys sys<br />
# ##i##mount --rbind /dev dev<br />
}}<br />
You'll also want to copy over {{f|resolv.conf}} in order to have proper resolution of Internet hostnames from inside the chroot:<br />
{{console|body=<br />
# ##i##cp /etc/resolv.conf /mnt/funtoo/etc/<br />
}}<br />
Now you can chroot into your new system. Use <code>env</code> before <code>chroot</code> to ensure that no environment settings from the installation media are pulled in to your new system:<br />
<br />
{{console|body=###i## env -i HOME=/root TERM=$TERM chroot . bash -l}}<br />
{{Note|For users of live CDs with 64-bit kernels installing 32-bit systems: Some software may use {{c|uname -r}} to check whether the system is 32 or 64-bit. You may want append linux32 to the chroot command as a workaround, but it's generally not needed.}}<br />
{{Important|If you receive the error "{{c|chroot: failed to run command `/bin/bash': Exec format error}}", it is most likely because you are running a 32-bit kernel and trying to execute 64-bit code. Make sure that you have selected the proper type of kernel when booting SystemRescueCD.}}<br />
<br />
It's also a good idea to change the default command prompt while inside the chroot. This will avoid confusion if you have to change terminals. Use this command:<br />
{{console|body=# ##i##export PS1="(chroot) $PS1"}}<br />
Test internet name resolution from within the chroot:<br />
{{console|body=###i## ping -c 5 google.com}}<br />
If you can't ping, make sure {{f|/etc/resolv.conf}} doesn't contain things like {{c|127.0.x.x}} addresses, if it does, change the {{c|127.0.x.x}} entry to {{c|8.8.8.8}} -- Google's public dns address. Make sure to replace this with your dns of choice once the system is installed.<br />
<br />
Congratulations! You are now chrooted inside a Funtoo Linux system. Now it's time to get Funtoo Linux properly configured so that Funtoo Linux will start successfully, without any manual assistance, when your system is restarted.</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Eix&diff=10693Package:Eix2015-06-30T16:29:51Z<p>Duncan.britton: Included in the portage category.</p>
<hr />
<div>{{Ebuild<br />
|Summary=A command to search and query ebuilds, portage including local settings, overlays, version changes, and more.<br />
|CatPkg=app-portage/eix<br />
|Maintainer=<br />
}}<br />
== Install ==<br />
To install eix, emerge it:<br />
{{console|body=<br />
###i## emerge eix<br />
}}<br />
=== Update ===<br />
To include your layman repositories for synchronization:<br />
{{console|body=###i## echo "*" >> /etc/eix-sync.conf }}<br />
Update eix by running:<br />
{{console|body=###i## eix-update}}<br />
== Use ==<br />
The basic usage of eix is simply using its name as a prefix to the package you are looking for: <br />
{{console|body=###i## eix foo}}<br />
This will give you a fairly verbose list of packages containing the term 'foo' in their name. It gives you information about which versions are available, whether they are stable, current or live, a description of the package and a list of the USE flags '''for all the packages combined''' - sometimes different versions of packages have different USE flags so you may need to check which a specific package contains with equery. <br />
=== More detailed example ===<br />
Suppose that you are interested in learning about the various available kernels in Portage. Eix can help with that. By running the following command, you will find the answer that you are looking for:<br />
{{console|body=<br />
###i## eix -# sys-kernel/<br />
}}<br />
To receive more information in the output, add the {{c|-c}} argument when you run eix:<br />
{{console|body=<br />
###i## eix -c sys-kernel/<br />
}}<br />
=== Showing what you have installed ===<br />
<br />
A handy feature of eix is the ability to quickly show you which packages you have installed on your system. <br />
{{console|body=###i## eix-installed all}}<br />
This will output all the packages you have explicitly installed along with the version number. There are other options to get more specific information with this command so check the man page for details. <br />
<br />
This can be handy for when you do backups of your system, the list could be sent to a file before you run rsync: <br />
{{console|body=###i## eix-installed all > ~/installed_list.txt}}<br />
=== Searching other overlays ===<br />
<br />
It is possible search in more than just the main portage tree and your local overlay. By using the <b>{{c|eix-remote}}</b> command you can configure eix to load, update and search multiple external overlays. <br />
<br />
To add the list of external overlays to eix: <br />
{{console|body=<br />
###i## eix-remote update <br />
###i## eix-sync}}<br />
Now you are ready to search for packages inside the main funtoo portage tree and in all the third party overlays by using the <b>{{c|-R}}</b> argument: <br />
{{console|body=###i## eix -R foo}}<br />
<br />
This is will give you a list of all the packages and versions, as well as telling you which overlay they belong to. Once you have found something you want to emerge you can add the overlay, with either <br />
{{console|body=###i## layman -a [overlay_name]}} <br />
or by using <b>{{c|eix-layman}}</b>, and then just emerge the package in the normal way. <br />
<br />
[[Category:Portage]]<br />
<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Eix&diff=10692Package:Eix2015-06-30T16:27:23Z<p>Duncan.britton: I missed a few <console> tags apparently...</p>
<hr />
<div>{{Ebuild<br />
|Summary=A command to search and query ebuilds, portage including local settings, overlays, version changes, and more.<br />
|CatPkg=app-portage/eix<br />
|Maintainer=<br />
}}<br />
== Install ==<br />
To install eix, emerge it:<br />
{{console|body=<br />
###i## emerge eix<br />
}}<br />
=== Update ===<br />
To include your layman repositories for synchronization:<br />
{{console|body=###i## echo "*" >> /etc/eix-sync.conf }}<br />
Update eix by running:<br />
{{console|body=###i## eix-update}}<br />
== Use ==<br />
The basic usage of eix is simply using its name as a prefix to the package you are looking for: <br />
{{console|body=###i## eix foo}}<br />
This will give you a fairly verbose list of packages containing the term 'foo' in their name. It gives you information about which versions are available, whether they are stable, current or live, a description of the package and a list of the USE flags '''for all the packages combined''' - sometimes different versions of packages have different USE flags so you may need to check which a specific package contains with equery. <br />
=== More detailed example ===<br />
Suppose that you are interested in learning about the various available kernels in Portage. Eix can help with that. By running the following command, you will find the answer that you are looking for:<br />
{{console|body=<br />
###i## eix -# sys-kernel/<br />
}}<br />
To receive more information in the output, add the {{c|-c}} argument when you run eix:<br />
{{console|body=<br />
###i## eix -c sys-kernel/<br />
}}<br />
=== Showing what you have installed ===<br />
<br />
A handy feature of eix is the ability to quickly show you which packages you have installed on your system. <br />
{{console|body=###i## eix-installed all}}<br />
This will output all the packages you have explicitly installed along with the version number. There are other options to get more specific information with this command so check the man page for details. <br />
<br />
This can be handy for when you do backups of your system, the list could be sent to a file before you run rsync: <br />
{{console|body=###i## eix-installed all > ~/installed_list.txt}}<br />
=== Searching other overlays ===<br />
<br />
It is possible search in more than just the main portage tree and your local overlay. By using the <b>{{c|eix-remote}}</b> command you can configure eix to load, update and search multiple external overlays. <br />
<br />
To add the list of external overlays to eix: <br />
{{console|body=<br />
###i## eix-remote update <br />
###i## eix-sync}}<br />
Now you are ready to search for packages inside the main funtoo portage tree and in all the third party overlays by using the <b>{{c|-R}}</b> argument: <br />
{{console|body=###i## eix -R foo}}<br />
<br />
This is will give you a list of all the packages and versions, as well as telling you which overlay they belong to. Once you have found something you want to emerge you can add the overlay, with either <br />
{{console|body=###i## layman -a [overlay_name]}} <br />
or by using <b>{{c|eix-layman}}</b>, and then just emerge the package in the normal way. <br />
<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Eix&diff=10691Package:Eix2015-06-30T16:23:17Z<p>Duncan.britton: Removed unnecessary space from the top of the page.</p>
<hr />
<div>{{Ebuild<br />
|Summary=A command to search and query ebuilds, portage including local settings, overlays, version changes, and more.<br />
|CatPkg=app-portage/eix<br />
|Maintainer=<br />
}}<br />
== Install ==<br />
To install eix, emerge it:<br />
{{console|body=<br />
###i## emerge eix<br />
}}<br />
=== Update ===<br />
To include your layman repositories for synchronization:<br />
{{console|body=###i## echo "*" >> /etc/eix-sync.conf }}<br />
Update eix by running:<br />
{{console|body=###i## eix-update}}<br />
== Use ==<br />
The basic usage of eix is simply using its name as a prefix to the package you are looking for: <br />
{{console|body=###i## eix foo}}<br />
This will give you a fairly verbose list of packages containing the term 'foo' in their name. It gives you information about which versions are available, whether they are stable, current or live, a description of the package and a list of the USE flags '''for all the packages combined''' - sometimes different versions of packages have different USE flags so you may need to check which a specific package contains with equery. <br />
=== More detailed example ===<br />
Suppose that you are interested in learning about the various available kernels in Portage. Eix can help with that. By running the following command, you will find the answer that you are looking for:<br />
{{console|body=<br />
###i## eix -# sys-kernel/<br />
}}<br />
To receive more information in the output, add the {{c|-c}} argument when you run eix:<br />
{{console|body=<br />
###i## eix -c sys-kernel/<br />
}}<br />
=== Showing what you have installed ===<br />
<br />
A handy feature of eix is the ability to quickly show you which packages you have installed on your system. <br />
<console>###i## eix-installed all </console><br />
This will output all the packages you have explicitly installed along with the version number. There are other options to get more specific information with this command so check the man page for details. <br />
<br />
This can be handy for when you do backups of your system, the list could be sent to a file before you run rsync: <br />
<console>###i## eix-installed all > ~/installed_list.txt </console><br />
<br />
=== Searching other overlays ===<br />
<br />
It is possible search in more than just the main portage tree and your local overlay. By using the <b><code>eix-remote</code></b> command you can configure eix to load, update and search multiple external overlays. <br />
<br />
To add the list of external overlays to eix: <br />
<console>###i## eix-remote update <br />
###i## eix-sync </console><br />
<br />
Now you are ready to search for packages inside the main funtoo portage tree and in all the third party overlays by using the <b><code>-R</code></b> option: <br />
<console>###i## eix -R foo </console><br />
<br />
This is will give you a list of all the packages and versions, as well as telling you which overlay they belong to. Once you have found something you want to emerge you can add the overlay, with either <console>###i## layman -a [overlay_name] </console> or by using <b><code>eix-layman</code></b>, and then just emerge the package in the normal way. <br />
{{PageNeedsUpdates}}<br />
<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Eix&diff=10690Package:Eix2015-06-30T16:22:37Z<p>Duncan.britton: Revised prior edits and updated the <console> tags to {{console}} templates.</p>
<hr />
<div>{{Ebuild<br />
|Summary=A command to search and query ebuilds, portage including local settings, overlays, version changes, and more.<br />
|CatPkg=app-portage/eix<br />
|Maintainer=<br />
}}<br />
<br />
== Install ==<br />
=== Emerge ===<br />
To install eix, emerge it:<br />
{{console|body=<br />
###i## emerge eix<br />
}}<br />
=== Update ===<br />
To include your layman repositories for synchronization:<br />
{{console|body=###i## echo "*" >> /etc/eix-sync.conf }}<br />
Update eix by running:<br />
{{console|body=###i## eix-update}}<br />
== Use ==<br />
The basic usage of eix is simply using its name as a prefix to the package you are looking for: <br />
{{console|body=###i## eix foo}}<br />
This will give you a fairly verbose list of packages containing the term 'foo' in their name. It gives you information about which versions are available, whether they are stable, current or live, a description of the package and a list of the USE flags '''for all the packages combined''' - sometimes different versions of packages have different USE flags so you may need to check which a specific package contains with equery. <br />
=== More detailed example ===<br />
Suppose that you are interested in learning about the various available kernels in Portage. Eix can help with that. By running the following command, you will find the answer that you are looking for:<br />
{{console|body=<br />
###i## eix -# sys-kernel/<br />
}}<br />
To receive more information in the output, add the {{c|-c}} argument when you run eix:<br />
{{console|body=<br />
###i## eix -c sys-kernel/<br />
}}<br />
=== Showing what you have installed ===<br />
<br />
A handy feature of eix is the ability to quickly show you which packages you have installed on your system. <br />
<console>###i## eix-installed all </console><br />
This will output all the packages you have explicitly installed along with the version number. There are other options to get more specific information with this command so check the man page for details. <br />
<br />
This can be handy for when you do backups of your system, the list could be sent to a file before you run rsync: <br />
<console>###i## eix-installed all > ~/installed_list.txt </console><br />
<br />
=== Searching other overlays ===<br />
<br />
It is possible search in more than just the main portage tree and your local overlay. By using the <b><code>eix-remote</code></b> command you can configure eix to load, update and search multiple external overlays. <br />
<br />
To add the list of external overlays to eix: <br />
<console>###i## eix-remote update <br />
###i## eix-sync </console><br />
<br />
Now you are ready to search for packages inside the main funtoo portage tree and in all the third party overlays by using the <b><code>-R</code></b> option: <br />
<console>###i## eix -R foo </console><br />
<br />
This is will give you a list of all the packages and versions, as well as telling you which overlay they belong to. Once you have found something you want to emerge you can add the overlay, with either <console>###i## layman -a [overlay_name] </console> or by using <b><code>eix-layman</code></b>, and then just emerge the package in the normal way. <br />
{{PageNeedsUpdates}}<br />
<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Initramfs&diff=10689Initramfs2015-06-30T16:13:31Z<p>Duncan.britton: Updated the <code> and <console> tags on the page to {{c}} and {{console}} templates. Replaced the old table of better initramfs arguments with a new one.</p>
<hr />
<div>== What is initramfs? ==<br />
[http://en.wikipedia.org/wiki/Initramfs Wikipedia] defines initramfs as:<br />
<blockquote><br />
initramfs, abbreviated from "initial ram file system", is the successor of initrd. It is a cpio archive of the initial file system that gets loaded into memory during the Linux startup process. The Linux kernel mounts it as root file system and starts the init process from it. This will complete certain tasks before the real root file system is loaded; thus, initramfs needs to contain all of the device drivers and tools needed to mount the real root filesystem.<br />
</blockquote><br />
<br />
== Do I need an initramfs? ==<br />
The reason to build a kernel with an initramfs is mostly for interoperability (e.g. live-cd's) and special features like an included busybox, ssh, etc. But mostly, and that's why we are doing this here now, to have a proper kernel up and running quick'n dirty in a reasonable time without fighting hours and days until a more or less exotic hardware is perfectly run by the kernel. After having a proper basic kernel running with the help of an initramfs, I really recommend you to go a step further and build a true kernel with all features included without an initramfs. However, relying only on a kernel to boot a system can be quite time consuming, so we have provided several initramfs options for Funtoo. If you have decided to use an initramfs, not just a kernel, check out the options below and choose the one that you like the most.<br />
<br />
== better-initramfs ==<br />
Piotr's better-initramfs is a popular approach among Funtoo'ers to building an initramfs. It is quick, nice, and shiny. The biggest plus is that, once built, it is kernel version independent. <br />
<br />
=== Installation from git ===<br />
To install better-initramfs on your system, change to the {{c|/opt}} directory (or any other directory that you deem suitable for building packages in) and clone the better-initramfs repository from bitbucket:<br />
{{console|body=<br />
###i## cd /opt<br />
###i## git clone https://bitbucket.org/piotrkarbowski/better-initramfs.git<br />
}}<br />
<br />
=== Building {{c|/initramfs.cpio.gz}} ===<br />
Now that you have the better-initramfs sources on your system, we can build the {{c|initramfs.cpio.gz}} image and move it to {{c|/boot}}.<br />
{{Note|Do not run {{c|make prepare}} or {{c|make image}} until you have configured your kernel. If you have not installed / configured a kernel yet, read: [[Building_a_Kernel_from_Source| Building a Kernel From Source]] and [[Funtoo_Linux_Kernels| Funtoo Linux Kernels]].}}<br />
{{console|body=<br />
###i## cd better-initramfs<br />
###i## bootstrap/bootstrap-all<br />
###i## make prepare<br />
###i## make image<br />
###i## cp output/initramfs.cpio.gz /boot<br />
}}<br />
<br />
=== Installation using portage ===<br />
If you don't want the version from git with the newest features '''and''' bugs, you can emerge {{c|better-initramfs-bin}}:<br />
{{console|body=<br />
###i## emerge better-initramfs-bin<br />
}}<br />
==== The {{c|gzip}} use flag ====<br />
The ebuild for {{c|better-initramfs-bin}} allows for the installation of the better-initramfs initramfs without gzip compression. Although gzip compression is enabled on the image by default, it can be disabled by emering {{c|better-initramfs-bin}} without the gzip USE flag. To disable the gzip use flag for {{c|better-initramfs-bin}}, do the following:<br />
{{console|body=<br />
###i## mkdir /etc/portage/package.use (if it doesn't exist on your system)<br />
###i## echo "sys-kernel/better-initramfs-bin -gzip" > /etc/portage/package.use/better-initramfs-bin<br />
}}<br />
Now, when better initramfs is emerged, the initramfs file in {{c|/boot}} will be called {{c|/boot/initramfs.cpio}} instead of {{c|initramfs.cpio.gz}}. To emerge better initramfs, run the following:<br />
{{console|body=<br />
###i## emerge better-initramfs-bin<br />
}}<br />
<br />
=== Configuring {{c|/etc/boot.conf}} ===<br />
Now that the {{c|initramfs.cpio.gz}} or {{c|initramfs.cpio}} file is in {{c|/boot}}, we can configure what we want the initramfs to do for us when the system boots. Below is a table of options that better-initramfs supports (from [https://bitbucket.org/piotrkarbowski/better-initramfs better-initramfs Bitbucket page]):<br />
==== Options ====<br />
<br />
{{TableStart}}<br />
<tr class="info"><th>Option</th><th>Description</th></tr><br />
<tr><td>rescueshell</td><td>Drop to rescueshell just before mount rootfs to /newroot.</td></tr><br />
<tr><td>sshd</td><td>Run sshd server. Lets you ssh into initramfs on error, to input password for encrypted rootfs, or to fix something remotly.</td></tr><br />
<tr><td>sshd_wait=x</td><td>Wait X seconds after setting up sshd, useful when you want to login (and thus pause boot process) before booting real system.</td></tr><br />
<tr><td>sshd_port=x</td><td>Setup sshd to listen on X port. Default: 22.</td></tr><br />
<tr><td>binit_net_if=<id></td><td>Specify on which interface the network should be configured. Optionally a vlan can be specified separated by a dot. Example: eth0 or eth0.55</td></tr><br />
<tr><td>binit_net_addr=<addr/cidr></td><td>Configure <addr> with <cidr> netmask on binit_net_if. Usualy you want something like '1.2.3.4/24'. If you will not add /CIDR, the IP will be configured with /32 thus you will be not able to connect to it unless you specify binit_net_gw.</td></tr><br />
<tr><td>binit_net_gw=<addr></td><td>Optional gateway config, if you want to connect via WAN.</td></tr><br />
<tr><td>rw</td><td>Mount rootfs in read-write. Default: read-only.</td></tr><br />
<tr><td>mdev</td><td>Don't check if kernel support devtmpfs, use mdev instead. (Useful for really old kernels).</td></tr><br />
<tr><td>softraid</td><td>Get up raid arrays</td></tr><br />
<tr><td>init=x</td><td>Run X after switching to newroot, Default: /sbin/init.</td></tr><br />
<tr><td>tuxonice</td><td>Try resuming with TuxOnIce. Depends on resume= variable which points to the device with image, usualy swap partition.</td></tr><br />
<tr><td>uswsusp</td><td>Try resuming with userspace software suspend. Depends on resume= variable which points to the device with the system snapshot, usually swap partition.</td></tr><br />
<tr><td>swsusp</td><td>Try resuming with swusps (in-kernel suspend). Depends on resume= variable which points to the device with system snapshot, usually swap partition.</td></tr><br />
<tr><td>resume=<device/path></td><td>Specify device from which you want to resume (with tuxonice or uswsusp).</td></tr><br />
<tr><td>lvm</td><td>Scan all disks for volume groups and activate them.</td></tr><br />
<tr><td>luks</td><td>Do cryptsetup luksOpen on enc_root variable.</td></tr><br />
<tr><td>enc_root=<device></td><td>For example /dev/sda2 if sda2 is your encrypted rootfs. This variable is ignored if luks isn't enabled. You can specify multiple devices with colon as separator, like enc_root=/dev/sda2:/dev/sdb2:/dev/vda1.</td></tr><br />
<tr><td>root=<device></td><td>For example /dev/mapper/enc_root if you have LUKS-encrypted rootfs, /dev/mapper/vg-rootfs or similar if lvm or just /dev/sdXX if you haven't rootfs over lvm or encrypted.</td></tr><br />
<tr><td>rootfstype=<filesystem type></td><td>Set type of filesystem on your rootfs if you do not want to use 'auto',</td></tr><br />
<tr><td>rootdelay=<integer></td><td>Set how many seconds initramfs should wait [for devices]. Useful for rootfs on USB device.</td></tr><br />
<tr><td>rootflags=x</td><td>Pass X flag(s) to mount while mounting rootfs, you can use it to specify which btrfs subvolume you want to mount.</td></tr><br />
<tr><td>luks_no_discards</td><td>Disable discards support on LUKS level, use if you don't want to allow lvm layer (if used) to send discards on reduce/resize or filesystem layer on file deletions to underlaying storage thru dmcrypt luks layer. Disabling discards on SSD-type storage may noticable degradate performance over time.</td></tr><br />
<tr><td>bcache</td><td>Bring up bcache devices. This will get ready for use /dev/bcache* which means one can have rootfs on bcache as well as anything else.</td></tr><br />
{{TableEnd}}<br />
==== Examples ====<br />
Below are examples of different use cases for better-initramfs and how your {{c|/etc/boot.conf}} should be configured for them. <br />
{{Note|Realize that your {{c|enc_root}}, {{c|root}}, and {{c|rootfstype}} variables may be different from the examples provided below.}}<br />
<br />
==== Regular ext4 root ====<br />
{{file|name=/etc/boot.conf|desc= |body=<br />
"Funtoo Linux" {<br />
kernel vmlinuz[-v]<br />
initrd /initramfs.cpio.gz<br />
params += root=/dev/sdaX rootfstype=ext4<br />
}<br />
}}<br />
<br />
==== Encrypted root with lvm ====<br />
{{file|name=/etc/boot.conf|desc= |body=<br />
"Funtoo Linux" {<br />
kernel vmlinuz[-v]<br />
initrd /initramfs.cpio.gz<br />
params += enc_root=/dev/sdaX lvm luks luks_trim root=/dev/mapper/funtoo--vg-root rootfstype=ext4<br />
}<br />
}}<br />
<br />
==== Encrypted root with lvm and RAID ====<br />
{{file|name=/etc/boot.conf|desc= |body=<br />
"Funtoo Linux" {<br />
kernel vmlinuz[-v]<br />
initrd /initramfs.cpio.gz<br />
params += enc_root=/dev/md0 lvm luks luks_trim softraid root=/dev/mapper/funtoo--vg-root rootfstype=ext4<br />
}<br />
}}<br />
<br />
== Dracut ==<br />
=== Installation ===<br />
To install Dracut, emerge it:<br />
{{console|body=<br />
###i## emerge dracut<br />
}}<br />
=== Build the initramfs ===<br />
To build the initrd with dracut, run:<br />
{{console|body=<br />
###i## dracut -f --fstab --xz /boot/initramfs-3.2.6-pf.img 3.2.6-pf<br />
}}<br />
Generally, this should be enough!<br />
If you experience booting problems like missing modules / drivers then just boot from your livecd and fix Dracut or consider changing to another initramfs. You can look into the man page to tweak the command a bit (e.g. {{c|--add-drivers "xz dm_crypt"}} etc...).<br />
<br />
=== Configuring {{c|/etc/boot.conf}} ===<br />
==== Examples ====<br />
<br />
==== Encrypted root with lvm ====<br />
{{file|name=/etc/boot.conf|desc= |body=<br />
boot {<br />
generate grub<br />
default "Funtoo Linux dracut"<br />
timeout 3<br />
}<br />
<br />
"Funtoo Linux dracut" {<br />
kernel vmlinuz[-v]<br />
initrd initramfs[-v].img<br />
params = quiet rootfstype=ext4<br />
params += luks enc_root=/dev/sda3<br />
params += lvm root=/dev/mapper/vg-root<br />
}<br />
}}<br />
[[Category:Kernel]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Uvesafb&diff=10688Uvesafb2015-06-30T13:26:31Z<p>Duncan.britton: Changed the wording of a few sections of the page.</p>
<hr />
<div>== ''How to'' : Framebuffer: Userspace VESA VGA graphics support ==<br />
Uvesafb is an improved framebuffer driver for Linux systems with some enhancements compared to vesa. Uvesafb can allow you to get a full-resolution console, even if you have installed a graphics driver that does not support full-resolution consoles, such as [[Package:AMD_Catalyst_Video_Drivers| ati-drivers]] or NVidia-drivers.<br />
<br />
== Kernel configuration ==<br />
Before we emerge the required packages for uvesafb functionality, we have to configure the kernel properly:<br />
{{Kernelop|title=|desc=<br />
Device Drivers ---><br />
<*> Connector - unified userspace <-> kernelspace linker ---><br />
<br />
Graphics support ---><br />
Frame buffer devices ---><br />
[*] Support for frame buffer devices ---><br />
[*] Enable firmware EDID<br />
<*> Userspace VESA VGA graphics support<br />
}}<br />
<br />
{{Note|Build the kernel {{c|make}} from the kernel sources directory ({{c|/usr/src/linux}}, but do not install the kernel and modules ({{c|make install modules_install}}). You can choose uvesafb as a module, unlike vesa.}}<br />
== Install required packages ==<br />
Emerge {{Package|dev-libs/klibc}}. Klibc has to be compiled against a kernel that includes uvesafb support. This only has to be done once:<br />
{{console|body=<br />
###i## emerge klibc<br />
}}<br />
After {{c|klibc}} has been installed, the userspace helper, {{Package|sys-apps/v86d}}, can be installed. Uvesafb will not work without {{c|v86d}}:<br />
{{console|body=<br />
###i## emerge v86d<br />
}}<br />
== Back to kernel configuration ==<br />
Reconfigure the kernel to include {{c|/usr/share/v86d/initramfs}} as an initramfs source file:<br />
{{Kernelop|title=|desc=<br />
General Setup---><br />
[*] Initial RAM filesystem and RAM disk (initramfs/initrd) support<br />
(/usr/share/v86d/initramfs) Initramfs source file(s)<br />
}}<br />
After building in {{c|/usr/share/v86d/initramfs}} as an initramfs file in the kernel, rebuild your kernel sources ({{c|make}}) and install the newly compiled kernel and its modules ({{c|make install modules_install}}). <br />
== Bootloader configuration ==<br />
If you compiled uvesafb into the kernel (not as a module), you can configure its behavior by editing the {{c|params +=}} line in {{c|/etc/boot.conf}}. Below, some of the more common arguments used with uvesafb are explained:<br />
* <code>video=uvesafb:<screen y-res>x<screen x-res>-<color depth></code>: Tells the kernel that you want to use the uvesafb driver for console output. Also specifies that you will be using uvesafb at a set screen resolution, and color depth. Set the first part to the size of your screen (in pixels) and the second part to the color depth of your screen (most monitors now have a depth of 32). For example, if I had a 1920x1080 screen and a color depth of 32, I would add the following: <code>video=uvesafb:1920x1080-32</code><br />
<br />
* {{c|mtrr:x}}: X represents the number 0 or 3. This option allows you to set up the memory type range registers for uvesafb. Setting x=0 disables mtrr and setting x=3 enables mtrr. x=3 is the default setting for this switch. {{c|mtrr:3}} is recommended.<br />
<br />
* {{c|ywrap}}: Add support for display panning. Recommended. <br />
<br />
{{Tip|For more information regarding these arguments, check out http://www.mjmwired.net/kernel/Documentation/fb/uvesafb.txt}}<br />
<br />
Now that you have a basic understanding of a few of the different arguments, you can configure your {{c|/etc/boot.conf}} to allow booting with the uvesafb framebuffer:<br />
<br />
{{file|name=/etc/boot.conf|desc= |body=<br />
boot {<br />
generate grub<br />
default "Funtoo Linux: uvesafb" <br />
timeout 3 <br />
}<br />
"Funtoo Linux: uvesafb" { <br />
kernel bzImage[-v]<br />
params += video=uvesafb:1920x1080-32,mtrr:3,ywrap<br />
}<br />
}}<br />
{{Note|Realize that the configuration in the above file will not work on every computer. You must change the resolution (and possibly other switches) to best suite your needs.}}<br />
<br />
After you have finished editing your {{c|/etc/boot.conf}}, run the following:<br />
{{console|body=<br />
###i## boot-update<br />
}}<br />
Finally, reboot your computer so that you can test out uvesafb:<br />
{{console|body=<br />
###i## reboot<br />
}}<br />
<br />
[[Category:HOWTO]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Uvesafb&diff=10687Uvesafb2015-06-30T13:18:19Z<p>Duncan.britton: Updated the <code> and <console> tags on the page to {{c}} and {{console}} templates. Changed the wording in a few places.</p>
<hr />
<div>== ''How to'' : Framebuffer: Userspace VESA VGA graphics support ==<br />
Uvesafb is an improved framebuffer driver for Linux systems with some enhancements compared to vesa. Uvesafb can allow you to get a full-resolution console, even if you have installed a graphics driver that does not support full-resolution consoles. Examples of drivers like these: [[Package:AMD_Catalyst_Video_Drivers| ati-drivers]] and NVidia-drivers.<br />
<br />
== Kernel configuration ==<br />
Before we emerge the required packages for uvesafb functionality, we have to configure the kernel properly.<br />
{{Kernelop|title=|desc=<br />
Device Drivers ---><br />
<*> Connector - unified userspace <-> kernelspace linker ---><br />
<br />
Graphics support ---><br />
Frame buffer devices ---><br />
[*] Support for frame buffer devices ---><br />
[*] Enable firmware EDID<br />
<*> Userspace VESA VGA graphics support<br />
}}<br />
<br />
{{Note|Build the kernel {{c|make}} from the kernel sources directory ({{c|/usr/src/linux}}. Do not install the kernel and modules ({{c|make install modules_install}}). You can choose uvesafb as a module, unlike vesa.}}<br />
<br />
== Install required packages ==<br />
<br />
Emerge {{Package|dev-libs/klibc}}. Klibc has to be compiled against a kernel that includes uvesafb support. This only has to be done once:<br />
{{console|body=<br />
###i## emerge klibc<br />
}}<br />
{{Package|sys-apps/v86d}} is the userspace helper that runs x86 code in emulated environment. Uvesafb will not work without v86d. Emerge {{c|v86d}}:<br />
{{console|body=<br />
###i## emerge v86d<br />
}}<br />
<br />
== Back to kernel configuration ==<br />
Reconfigure the kernel to include {{c|/usr/share/v86d/initramfs}} as an initramfs source file:<br />
{{Kernelop|title=|desc=<br />
General Setup---><br />
[*] Initial RAM filesystem and RAM disk (initramfs/initrd) support<br />
(/usr/share/v86d/initramfs) Initramfs source file(s)<br />
}}<br />
Rebuild the kernel: make and install it, install the modules<br />
<br />
== Bootloader configuration ==<br />
If you compiled uvesafb into the kernel (not as a module), you can configure its behavior by editing the {{c|params +=}} line in {{c|/etc/boot.conf}}. Below, some of the more common switches used with uvesafb are explained:<br />
* <code>video=uvesafb:<screen y-res>x<screen x-res>-<color depth></code>: Tells the kernel that you want to use the uvesafb driver for console output. Also specifies that you will be using uvesafb at a set x-screen resolution, y screen-resolution, and color depth. Set the first part to the size of your screen (in pixels). For example, if I had a 1920x1080 screen and wanted a color depth of 32, I would add the following: <code>video=uvesafb:1920x1080-32</code><br />
<br />
* {{c|mtrr:x}}: X represents the number 0 or 3. This option allows you to set up the memory type range registers for uvesafb. Setting x=0 disables mtrr and setting x=3 enables mtrr. x=3 is the default setting for this switch. mtrr:3 is recommended.<br />
<br />
* {{c|ywrap}}: Add support for display panning. Recommended. <br />
<br />
{{Tip|For more information regarding these switches, check out http://www.mjmwired.net/kernel/Documentation/fb/uvesafb.txt}}<br />
<br />
Now that you have a basic understanding of a few of the different switches, you can configure your {{c|/etc/boot.conf}} to allow booting with the uvesafb framebuffer:<br />
<br />
{{file|name=/etc/boot.conf|desc= |body=<br />
boot {<br />
generate grub<br />
default "Funtoo Linux: uvesafb" <br />
timeout 3 <br />
}<br />
"Funtoo Linux: uvesafb" { <br />
kernel bzImage[-v]<br />
params += video=uvesafb:1920x1080-32,mtrr:3,ywrap<br />
}<br />
}}<br />
{{Note|Realize that the configuration in the above file will not work on every computer. You must change the resolution (and possibly other switches) to best suite your needs.}}<br />
<br />
After you have finished editing your <tt>/etc/boot.conf</tt>, run the following:<br />
{{console|body=<br />
###i## boot-update<br />
}}<br />
Finally, reboot your computer so that you can test out uvesafb:<br />
{{console|body=<br />
###i## reboot<br />
}}<br />
<br />
[[Category:HOWTO]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Sed_by_Example,_Part_1&diff=10551Sed by Example, Part 12015-06-26T23:02:27Z<p>Duncan.britton: Fixed a broken link that I made earlier..</p>
<hr />
<div>{{Article<br />
|Author=Drobbins<br />
|Next in Series=Sed by Example, Part 2<br />
}}<br />
== Get to know the powerful UNIX editor ==<br />
<br />
=== Pick an editor ===<br />
In the UNIX world, we have a lot of options when it comes to editing files. Think of it -- vi, emacs, and jed come to mind, as well as many others. We all have our favorite editor (along with our favorite keybindings) that we have come to know and love. With our trusty editor, we are ready to tackle any number of UNIX-related administration or programming tasks with ease.<br />
<br />
While interactive editors are great, they do have limitations. Though their interactive nature can be a strength, it can also be a weakness. Consider a situation where you need to perform similar types of changes on a group of files. You could instinctively fire up your favorite editor and perform a bunch of mundane, repetitive, and time-consuming edits by hand. But there's a better way.<br />
<br />
=== Enter sed ===<br />
It would be nice if we could automate the process of making edits to files, so that we could "batch" edit files, or even write scripts with the ability to perform sophisticated changes to existing files. Fortunately for us, for these types of situations, there is a better way -- and the better way is called sed.<br />
<br />
sed is a lightweight stream editor that's included with nearly all UNIX flavors, including Linux. sed has a lot of nice features. First of all, it's very lightweight, typically many times smaller than your favorite scripting language. Secondly, because sed is a stream editor, it can perform edits to data it receives from stdin, such as from a pipeline. So, you don't need to have the data to be edited stored in a file on disk. Because data can just as easily be piped to sed, it's very easy to use sed as part of a long, complex pipeline in a powerful shell script. Try doing that with your favorite editor.<br />
<br />
=== GNU sed ===<br />
Fortunately for us Linux users, one of the nicest versions of sed out there happens to be GNU sed. Every Linux distribution has GNU sed, or at least should. GNU sed is popular not only because its sources are freely distributable, but because it happens to have a lot of handy, time-saving extensions to the POSIX sed standard. GNU sed also doesn't suffer from many of the limitations that earlier and proprietary versions of sed had, such as a limited line length -- GNU sed handles lines of any length with ease.<br />
<br />
=== The right sed ===<br />
In this series, we will be using GNU sed. Some (but very few) of the most advanced examples you'll find in my upcoming, follow-on articles in this series will not work with GNU sed 3.02 or 3.02a and will require a modern version. If you're using a non-GNU sed, your results may vary. Why not take some time to install GNU sed now (see [[#Resources|Resources]] for source code)? Then, not only will you be ready for the rest of the series, but you'll also be able to use arguably the best sed in existence!<br />
<br />
=== Sed examples ===<br />
Sed works by performing any number of user-specified editing operations ("commands") on the input data. Sed is line-based, so the commands are performed on each line in order. And, sed writes its results to standard output (stdout); it doesn't modify any input files.<br />
<br />
Let's look at some examples. The first several are going to be a bit weird because I'm using them to illustrate how sed works rather than to perform any useful task. However, if you're new to sed, it's very important that you understand them. Here's our first example:<br />
<br />
<console>$##i## sed -e 'd' /etc/services</console><br />
<br />
If you type this command, you'll get absolutely no output. Now, what happened? In this example, we called sed with one editing command, <span style="color:green">d</span>. Sed opened the '''/etc/services''' file, read a line into its pattern buffer, performed our editing command ("delete line"), and then printed the pattern buffer (which was empty). It then repeated these steps for each successive line. This produced no output, because the <span style="color:green">d</span> command zapped every single line in the pattern buffer!<br />
<br />
There are a couple of things to notice in this example. First, '''/etc/services''' was not modified at all. This is because, again, sed only reads from the file you specify on the command line, using it as input -- it doesn't try to modify the file. The second thing to notice is that sed is line-oriented. The <span style="color:green">d</span> command didn't simply tell sed to delete all incoming data in one fell swoop. Instead, sed read each line of /etc/services one by one into its internal buffer, called the pattern buffer. Once a line was read into the pattern buffer, it performed the <span style="color:green">d</span> command and printed the contents of the pattern buffer (nothing in this example). Later, I'll show you how to use address ranges to control which lines a command is applied to -- but in the absence of addresses, a command is applied to all lines.<br />
<br />
The third thing to notice is the use of single quotes to surround the d command. It's a good idea to get into the habit of using single quotes to surround your sed commands, so that shell expansion is disabled.<br />
<br />
=== Another sed example ===<br />
Here's an example of how to use sed to remove the first line of the '''/etc/services''' file from our output stream:<br />
<br />
<console>$##i## sed -e '1d' /etc/services | more</console><br />
<br />
As you can see, this command is very similar to our first <span style="color:green">d</span> command, except that it is preceded by a 1. If you guessed that the 1 refers to line number one, you're right. While in our first example, we used d by itself, this time we use the <span style="color:green">d</span> command preceded by an optional numerical address. By using addresses, you can tell sed to perform edits only on a particular line or lines.<br />
<br />
=== Address ranges ===<br />
Now, let's look at how to specify an address range. In this example, sed will delete lines 1-10 of the output:<br />
<br />
<console>$##i## sed -e '1,10d' /etc/services | more</console><br />
<br />
When we separate two addresses by a comma, sed will apply the following command to the range that starts with the first address, and ends with the second address. In this example, the <span style="color:green">d</span> command was applied to lines 1-10, inclusive. All other lines were ignored.<br />
<br />
=== Addresses with regular expressions ===<br />
Now, it's time for a more useful example. Let's say you wanted to view the contents of your '''/etc/services''' file, but you aren't interested in viewing any of the included comments. As you know, you can place comments in your '''/etc/services''' file by starting the line with the '#' character. To avoid comments, we'd like sed to delete lines that start with a '#'. Here's how to do it:<br />
<br />
<console>$##i## sed -e '/^#/d' /etc/services | more</console><br />
<br />
Try this example and see what happens. You'll notice that sed performs its desired task with flying colors. Now, let's figure out what happened.<br />
<br />
To understand the '/^#/d' command, we first need to dissect it. First, let's remove the 'd' -- we're using the same delete line command that we've used previously. The new addition is the '/^#/' part, which is a new kind of regular expression address. Regular expression addresses are always surrounded by slashes. They specify a pattern, and the command that immediately follows a regular expression address will only be applied to a line if it happens to match this particular pattern.<br />
<br />
So, '/^#/' is a regular expression. But what does it do? Obviously, this would be a good time for a regular expression refresher.<br />
<br />
=== Regular expression refresher ===<br />
We can use regular expressions to express patterns that we may find in the text. If you've ever used the '*' character on the shell command line, you've used something that's similar, but not identical to, regular expressions. Here are the special characters that you can use in regular expressions:<br />
{| border=1<br />
|-<br />
|'''Character'''<br />
|'''Description'''<br />
|-<br />
|^<br />
|Matches the beginning of the line<br />
|-<br />
|$<br />
|Matches the end of the line<br />
|-<br />
|.<br />
|Matches any single character<br />
|-<br />
|*<br />
|Will match zero or more occurrences of the previous character<br />
|-<br />
|[ ]<br />
|Matches all the characters inside the [ ]<br />
|}<br />
<br />
Probably the best way to get your feet wet with regular expressions is to see a few examples. All of these examples will be accepted by sed as valid addresses to appear on the left side of a command. Here are a few:<br />
{| border=1<br />
|-<br />
|'''Regular expression'''<br />
|'''Description'''<br />
|-<br />
|/./<br />
|Will match any line that contains at least one character<br />
|-<br />
|/../<br />
|Will match any line that contains at least two characters<br />
|-<br />
|/^#/<br />
|Will match any line that begins with a '#'<br />
|-<br />
|/^$/<br />
|Will match all blank lines<br />
|-<br />
|/}$/<br />
|Will match any lines that ends with '}' (no spaces)<br />
|-<br />
|/} *$/<br />
|Will match any line ending with '}' followed by zero or more spaces<br />
|-<br />
|/[abc]/<br />
|Will match any line that contains a lowercase 'a', 'b', or 'c'<br />
|-<br />
|/^[abc]/<br />
|Will match any line that begins with an 'a', 'b', or 'c'<br />
|}<br />
I encourage you to try several of these examples. Take some time to get familiar with regular expressions, and try a few regular expressions of your own creation. You can use a regexp this way:<br />
<br />
<console>$##i## sed -e '/regexp/d' /path/to/my/test/file | more</console><br />
<br />
This will cause sed to delete any matching lines. However, it may be easier to get familiar with regular expressions by telling sed to print regexp matches, and delete non-matches, rather than the other way around. This can be done with the following command:<br />
<br />
<console>$##i## sed -n -e '/regexp/p' /path/to/my/test/file | more</console><br />
<br />
Note the new '-n' option, which tells sed to not print the pattern space unless explicitly commanded to do so. You'll also notice that we've replaced the <span style="color:green">d</span> command with the <span style="color:green">p</span> command, which as you might guess, explicitly commands sed to print the pattern space. Voila, now only matches will be printed.<br />
<br />
=== More on addresses ===<br />
Up till now, we've taken a look at line addresses, line range addresses, and regexp addresses. But there are even more possibilities. We can specify two regular expressions separated by a comma, and sed will match all lines starting from the first line that matches the first regular expression, up to and including the line that matches the second regular expression. For example, the following command will print out a block of text that begins with a line containing "BEGIN", and ending with a line that contains "END":<br />
<br />
<console>$##i## sed -n -e '/BEGIN/,/END/p' /my/test/file | more</console><br />
<br />
If "BEGIN" isn't found, no data will be printed. And, if "BEGIN" is found, but no "END" is found on any line below it, all subsequent lines will be printed. This happens because of sed's stream-oriented nature -- it doesn't know whether or not an "END" will appear.<br />
<br />
=== C source example ===<br />
If you want to print out only the main() function in a C source file, you could type:<br />
<br />
<console>$##i## sed -n -e '/main[[:space:]]*(/,/^}/p' sourcefile.c | more</console><br />
<br />
This command has two regular expressions, <nowiki>'/main[[:space:]]*(/' and '/^}/'</nowiki>, and one command, <span style="color:green">p</span>. The first regular expression will match the string "main" followed by any number of spaces or tabs, followed by an open parenthesis. This should match the start of your average ANSI C main() declaration.<br />
<br />
<nowiki>In this particular regular expression, we encounter the '[[:space:]]' character class. This is simply a special keyword that tells sed to match either a TAB or a space. If you wanted, instead of typing '[[:space:]]', you could have typed '[', then a literal space, then Control-V, then a literal tab and a ']' -- The Control-V tells bash that you want to insert a "real" tab rather than perform command expansion. It's clearer, especially in scripts, to use the '[[:space:]]' command class.</nowiki><br />
<br />
OK, now on to the second regexp. '/^}/' will match a '}' character that appears at the beginning of a new line. If your code is formatted nicely, this will match the closing brace of your main() function. If it's not, it won't -- one of the tricky things about performing pattern matching.<br />
<br />
The <span style="color:green">p</span> command does what it always does, explicitly telling sed to print out the line, since we are in '-n' quiet mode. Try running the command on a C source file -- it should output the entire main() { } block, including the initial "main()" and the closing '}'.<br />
<br />
=== Next time ===<br />
Now that we've touched on the basics, we'll be picking up the pace for the next two articles. If you're in the mood for some meatier sed material, be patient -- it's coming! In the meantime, you might want to check out the following sed and regular expression resources.<br />
<br />
== Resources ==<br />
* Read Daniel's other sed articles: Sed by example, [[Sed by Example, Part 2|Part 2]] and [[Sed by Example, Part 3|Part 3]].<br />
* Check out Eric Pement's excellent [http://sed.sourceforge.net/sedfaq.html sed FAQ].<br />
* You can find the sources to sed at ftp://ftp.gnu.org/pub/gnu/sed.<br />
* Eric Pement also has a handy list of [http://sed.sourceforge.net/sed1line.txt sed one-liners] that any aspiring sed guru should definitely look at.<br />
* If you'd like a good old-fashioned book, [http://www.oreilly.com/catalog/sed2/ O'Reilly's sed & awk, 2nd Edition] would be wonderful choice.<br />
* See the regular expressions [http://docs.python.org/dev/howto/regex.html how-to document] from [http://python.org/ python.org].<br />
* Refer to an [http://www.uky.edu/ArtsSciences/Classics/regex.html overview of regular expressions] from the University of Kentucky.<br />
* A great place to practice regular expressions can be found [https://regex101.com/ here]<br />
<br />
__NOTOC__<br />
[[Category:Linux Core Concepts]]<br />
[[Category:Articles]]<br />
{{ArticleFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Sed_by_Example,_Part_1&diff=10549Sed by Example, Part 12015-06-26T18:48:28Z<p>Duncan.britton: Added an additional link to a resource</p>
<hr />
<div>{{Article<br />
|Author=Drobbins<br />
|Next in Series=Sed by Example, Part 2<br />
}}<br />
== Get to know the powerful UNIX editor ==<br />
<br />
=== Pick an editor ===<br />
In the UNIX world, we have a lot of options when it comes to editing files. Think of it -- vi, emacs, and jed come to mind, as well as many others. We all have our favorite editor (along with our favorite keybindings) that we have come to know and love. With our trusty editor, we are ready to tackle any number of UNIX-related administration or programming tasks with ease.<br />
<br />
While interactive editors are great, they do have limitations. Though their interactive nature can be a strength, it can also be a weakness. Consider a situation where you need to perform similar types of changes on a group of files. You could instinctively fire up your favorite editor and perform a bunch of mundane, repetitive, and time-consuming edits by hand. But there's a better way.<br />
<br />
=== Enter sed ===<br />
It would be nice if we could automate the process of making edits to files, so that we could "batch" edit files, or even write scripts with the ability to perform sophisticated changes to existing files. Fortunately for us, for these types of situations, there is a better way -- and the better way is called sed.<br />
<br />
sed is a lightweight stream editor that's included with nearly all UNIX flavors, including Linux. sed has a lot of nice features. First of all, it's very lightweight, typically many times smaller than your favorite scripting language. Secondly, because sed is a stream editor, it can perform edits to data it receives from stdin, such as from a pipeline. So, you don't need to have the data to be edited stored in a file on disk. Because data can just as easily be piped to sed, it's very easy to use sed as part of a long, complex pipeline in a powerful shell script. Try doing that with your favorite editor.<br />
<br />
=== GNU sed ===<br />
Fortunately for us Linux users, one of the nicest versions of sed out there happens to be GNU sed. Every Linux distribution has GNU sed, or at least should. GNU sed is popular not only because its sources are freely distributable, but because it happens to have a lot of handy, time-saving extensions to the POSIX sed standard. GNU sed also doesn't suffer from many of the limitations that earlier and proprietary versions of sed had, such as a limited line length -- GNU sed handles lines of any length with ease.<br />
<br />
=== The right sed ===<br />
In this series, we will be using GNU sed. Some (but very few) of the most advanced examples you'll find in my upcoming, follow-on articles in this series will not work with GNU sed 3.02 or 3.02a and will require a modern version. If you're using a non-GNU sed, your results may vary. Why not take some time to install GNU sed now (see [[#Resources|Resources]] for source code)? Then, not only will you be ready for the rest of the series, but you'll also be able to use arguably the best sed in existence!<br />
<br />
=== Sed examples ===<br />
Sed works by performing any number of user-specified editing operations ("commands") on the input data. Sed is line-based, so the commands are performed on each line in order. And, sed writes its results to standard output (stdout); it doesn't modify any input files.<br />
<br />
Let's look at some examples. The first several are going to be a bit weird because I'm using them to illustrate how sed works rather than to perform any useful task. However, if you're new to sed, it's very important that you understand them. Here's our first example:<br />
<br />
<console>$##i## sed -e 'd' /etc/services</console><br />
<br />
If you type this command, you'll get absolutely no output. Now, what happened? In this example, we called sed with one editing command, <span style="color:green">d</span>. Sed opened the '''/etc/services''' file, read a line into its pattern buffer, performed our editing command ("delete line"), and then printed the pattern buffer (which was empty). It then repeated these steps for each successive line. This produced no output, because the <span style="color:green">d</span> command zapped every single line in the pattern buffer!<br />
<br />
There are a couple of things to notice in this example. First, '''/etc/services''' was not modified at all. This is because, again, sed only reads from the file you specify on the command line, using it as input -- it doesn't try to modify the file. The second thing to notice is that sed is line-oriented. The <span style="color:green">d</span> command didn't simply tell sed to delete all incoming data in one fell swoop. Instead, sed read each line of /etc/services one by one into its internal buffer, called the pattern buffer. Once a line was read into the pattern buffer, it performed the <span style="color:green">d</span> command and printed the contents of the pattern buffer (nothing in this example). Later, I'll show you how to use address ranges to control which lines a command is applied to -- but in the absence of addresses, a command is applied to all lines.<br />
<br />
The third thing to notice is the use of single quotes to surround the d command. It's a good idea to get into the habit of using single quotes to surround your sed commands, so that shell expansion is disabled.<br />
<br />
=== Another sed example ===<br />
Here's an example of how to use sed to remove the first line of the '''/etc/services''' file from our output stream:<br />
<br />
<console>$##i## sed -e '1d' /etc/services | more</console><br />
<br />
As you can see, this command is very similar to our first <span style="color:green">d</span> command, except that it is preceded by a 1. If you guessed that the 1 refers to line number one, you're right. While in our first example, we used d by itself, this time we use the <span style="color:green">d</span> command preceded by an optional numerical address. By using addresses, you can tell sed to perform edits only on a particular line or lines.<br />
<br />
=== Address ranges ===<br />
Now, let's look at how to specify an address range. In this example, sed will delete lines 1-10 of the output:<br />
<br />
<console>$##i## sed -e '1,10d' /etc/services | more</console><br />
<br />
When we separate two addresses by a comma, sed will apply the following command to the range that starts with the first address, and ends with the second address. In this example, the <span style="color:green">d</span> command was applied to lines 1-10, inclusive. All other lines were ignored.<br />
<br />
=== Addresses with regular expressions ===<br />
Now, it's time for a more useful example. Let's say you wanted to view the contents of your '''/etc/services''' file, but you aren't interested in viewing any of the included comments. As you know, you can place comments in your '''/etc/services''' file by starting the line with the '#' character. To avoid comments, we'd like sed to delete lines that start with a '#'. Here's how to do it:<br />
<br />
<console>$##i## sed -e '/^#/d' /etc/services | more</console><br />
<br />
Try this example and see what happens. You'll notice that sed performs its desired task with flying colors. Now, let's figure out what happened.<br />
<br />
To understand the '/^#/d' command, we first need to dissect it. First, let's remove the 'd' -- we're using the same delete line command that we've used previously. The new addition is the '/^#/' part, which is a new kind of regular expression address. Regular expression addresses are always surrounded by slashes. They specify a pattern, and the command that immediately follows a regular expression address will only be applied to a line if it happens to match this particular pattern.<br />
<br />
So, '/^#/' is a regular expression. But what does it do? Obviously, this would be a good time for a regular expression refresher.<br />
<br />
=== Regular expression refresher ===<br />
We can use regular expressions to express patterns that we may find in the text. If you've ever used the '*' character on the shell command line, you've used something that's similar, but not identical to, regular expressions. Here are the special characters that you can use in regular expressions:<br />
{| border=1<br />
|-<br />
|'''Character'''<br />
|'''Description'''<br />
|-<br />
|^<br />
|Matches the beginning of the line<br />
|-<br />
|$<br />
|Matches the end of the line<br />
|-<br />
|.<br />
|Matches any single character<br />
|-<br />
|*<br />
|Will match zero or more occurrences of the previous character<br />
|-<br />
|[ ]<br />
|Matches all the characters inside the [ ]<br />
|}<br />
<br />
Probably the best way to get your feet wet with regular expressions is to see a few examples. All of these examples will be accepted by sed as valid addresses to appear on the left side of a command. Here are a few:<br />
{| border=1<br />
|-<br />
|'''Regular expression'''<br />
|'''Description'''<br />
|-<br />
|/./<br />
|Will match any line that contains at least one character<br />
|-<br />
|/../<br />
|Will match any line that contains at least two characters<br />
|-<br />
|/^#/<br />
|Will match any line that begins with a '#'<br />
|-<br />
|/^$/<br />
|Will match all blank lines<br />
|-<br />
|/}$/<br />
|Will match any lines that ends with '}' (no spaces)<br />
|-<br />
|/} *$/<br />
|Will match any line ending with '}' followed by zero or more spaces<br />
|-<br />
|/[abc]/<br />
|Will match any line that contains a lowercase 'a', 'b', or 'c'<br />
|-<br />
|/^[abc]/<br />
|Will match any line that begins with an 'a', 'b', or 'c'<br />
|}<br />
I encourage you to try several of these examples. Take some time to get familiar with regular expressions, and try a few regular expressions of your own creation. You can use a regexp this way:<br />
<br />
<console>$##i## sed -e '/regexp/d' /path/to/my/test/file | more</console><br />
<br />
This will cause sed to delete any matching lines. However, it may be easier to get familiar with regular expressions by telling sed to print regexp matches, and delete non-matches, rather than the other way around. This can be done with the following command:<br />
<br />
<console>$##i## sed -n -e '/regexp/p' /path/to/my/test/file | more</console><br />
<br />
Note the new '-n' option, which tells sed to not print the pattern space unless explicitly commanded to do so. You'll also notice that we've replaced the <span style="color:green">d</span> command with the <span style="color:green">p</span> command, which as you might guess, explicitly commands sed to print the pattern space. Voila, now only matches will be printed.<br />
<br />
=== More on addresses ===<br />
Up till now, we've taken a look at line addresses, line range addresses, and regexp addresses. But there are even more possibilities. We can specify two regular expressions separated by a comma, and sed will match all lines starting from the first line that matches the first regular expression, up to and including the line that matches the second regular expression. For example, the following command will print out a block of text that begins with a line containing "BEGIN", and ending with a line that contains "END":<br />
<br />
<console>$##i## sed -n -e '/BEGIN/,/END/p' /my/test/file | more</console><br />
<br />
If "BEGIN" isn't found, no data will be printed. And, if "BEGIN" is found, but no "END" is found on any line below it, all subsequent lines will be printed. This happens because of sed's stream-oriented nature -- it doesn't know whether or not an "END" will appear.<br />
<br />
=== C source example ===<br />
If you want to print out only the main() function in a C source file, you could type:<br />
<br />
<console>$##i## sed -n -e '/main[[:space:]]*(/,/^}/p' sourcefile.c | more</console><br />
<br />
This command has two regular expressions, <nowiki>'/main[[:space:]]*(/' and '/^}/'</nowiki>, and one command, <span style="color:green">p</span>. The first regular expression will match the string "main" followed by any number of spaces or tabs, followed by an open parenthesis. This should match the start of your average ANSI C main() declaration.<br />
<br />
<nowiki>In this particular regular expression, we encounter the '[[:space:]]' character class. This is simply a special keyword that tells sed to match either a TAB or a space. If you wanted, instead of typing '[[:space:]]', you could have typed '[', then a literal space, then Control-V, then a literal tab and a ']' -- The Control-V tells bash that you want to insert a "real" tab rather than perform command expansion. It's clearer, especially in scripts, to use the '[[:space:]]' command class.</nowiki><br />
<br />
OK, now on to the second regexp. '/^}/' will match a '}' character that appears at the beginning of a new line. If your code is formatted nicely, this will match the closing brace of your main() function. If it's not, it won't -- one of the tricky things about performing pattern matching.<br />
<br />
The <span style="color:green">p</span> command does what it always does, explicitly telling sed to print out the line, since we are in '-n' quiet mode. Try running the command on a C source file -- it should output the entire main() { } block, including the initial "main()" and the closing '}'.<br />
<br />
=== Next time ===<br />
Now that we've touched on the basics, we'll be picking up the pace for the next two articles. If you're in the mood for some meatier sed material, be patient -- it's coming! In the meantime, you might want to check out the following sed and regular expression resources.<br />
<br />
== Resources ==<br />
* Read Daniel's other sed articles: Sed by example, [[Sed by Example, Part 2|Part 2]] and [[Sed by Example, Part 3|Part 3]].<br />
* Check out Eric Pement's excellent [http://sed.sourceforge.net/sedfaq.html sed FAQ].<br />
* You can find the sources to sed at ftp://ftp.gnu.org/pub/gnu/sed.<br />
* Eric Pement also has a handy list of [http://sed.sourceforge.net/sed1line.txt sed one-liners] that any aspiring sed guru should definitely look at.<br />
* If you'd like a good old-fashioned book, [http://www.oreilly.com/catalog/sed2/ O'Reilly's sed & awk, 2nd Edition] would be wonderful choice.<br />
* See the regular expressions [http://docs.python.org/dev/howto/regex.html how-to document] from [http://python.org/ python.org].<br />
* Refer to an [http://www.uky.edu/ArtsSciences/Classics/regex.html overview of regular expressions] from the University of Kentucky.<br />
* A great place to practice regular expressions can be found [https://regex101.com/| here]<br />
<br />
__NOTOC__<br />
[[Category:Linux Core Concepts]]<br />
[[Category:Articles]]<br />
{{ArticleFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Xfce4-meta&diff=10531Package:Xfce4-meta2015-06-25T17:42:42Z<p>Duncan.britton: Added the name of the executables after the "XFCE configuration and XFCE applications" section and changed the color of the user "$" prompts</p>
<hr />
<div>{{Ebuild<br />
|Summary=Meta package for XFCE desktop<br />
|CatPkg=xfce-base/xfce4-meta<br />
|Maintainer=Oleg<br />
}}<br />
== About Xfce ==<br />
<blockquote><br />
Xfce is a lightweight desktop environment for UNIX-like operating systems. It aims to be fast and low on system resources, while still being visually appealing and user friendly.<br />
<br />
Xfce embodies the traditional UNIX philosophy of modularity and re-usability. It consists of a number of components that provide the full functionality one can expect of a modern desktop environment. They are packaged separately and you can pick among the available packages to create the optimal personal working environment.<br />
<br />
Another priority of Xfce is adhereance to standards, specifically those defined at [http://freedesktop.org/ freedesktop.org]. [[http://www.xfce.org/about/ About XFCE]]<br />
</blockquote><br />
== Installation ==<br />
<br />
Before emerging Xfce you need to:<br />
<br />
Check that you have enabled the USE flags necessary for a XFCE desktop environment. Set your profile to "xfce" via [[Funtoo_Linux_First_Steps#Changing_profile|mix-ins]], as follows:<br />
{{console|body=<br />
###i## epro mix-ins +xfce<br />
}}<br />
Then, verify that you have the [[Funtoo_Linux_First_Steps#X.Org|X.Org Server]] configured properly. If X.Org is installed on your system, you are now ready to install Xfce. Install the meta-package, which pulls in all of the components you need for a minimal Xfce installation:<br />
<br />
{{console|body=<br />
###i## emerge xfce4-meta<br />
}}<br />
== Running Xfce ==<br />
<br />
There are several different ways to start Xfce:<br />
<br />
* Editing the {{c|.xinitrc}} file in your user's home directory and using {{c|startx}} from a text console.<br />
* Using a display manager (e.g. SLiM, GDM, and KDM).<br />
* Configuring your shell profile to automatically start Xfce upon a successful login.<br />
=== .xinitrc ===<br />
<br />
The most common way to start the environment is to configure {{c|~/.xinitrc}} to launch an Xfce session. The proper way to launch Xfce from the terminal is by using {{c|startxfce4}} combined with {{c|ck-launch-session}}.<br />
<br />
{{console|body=<br />
$##bl## echo "exec startxfce4 --with-ck-launch" > ~/.xinitrc<br />
}}<br />
Note that {{c|--with-ck-launch}} (from ConsoleKit) is required by Xfce for important tasks such as shutting down, suspending, and automatically mounting removable storage media. Some applications will not work properly without it. Also, configuring the GTK+ theme and other forms of theming through {{Package|Xfce4-settings}} do not often work without the {{c|--with-ck-launch}} command line option. Because we are launching XFCE with a consolekit command line option, we need to add ConsoleKit to the {{c|default}} runlevel, executing the following command as root:<br />
<br />
{{console|body=<br />
###i## rc-update add consolekit default<br />
###i## rc<br />
}}<br />
Finally, to start the graphical environment, run {{c|startx}} from a login shell:<br />
<br />
{{console|body=<br />
$##bl## startx<br />
}}<br />
After running this command, you should be greeted by your shiny new XFCE desktop. For more information about configuring XFCE and some of the default applications that come with it, consider looking at [[Package:xfce4-meta#XFCE configuration and XFCE applications|XFCE configuration and XFCE applications]].<br />
== Display Manager ==<br />
<br />
A display manager is a program that manages sessions and acts as a login screen. Here's a short list of a few of the display managers available from the Funtoo repositories:<br />
* XDM ({{c|x11-apps/xdm}}): X.Org's standard display manager.<br />
* LightDM ({{c|x11-misc/lightdm}}): A lightweight, but highly configurable display manager.<br />
* SLiM ({{c|x11-misc/slim}}): Simple Login Manager -- a lightweight display manager. Not very configurable.<br />
<br />
<br />
Any of these would make a fine choice. After you've chosen which display manager to use, install it:<br />
<br />
{{console|body=###i## emerge <display manager of choice>}}<br />
All that's left to do now is to add the name of the display manager to {{c|/etc/conf.d/xdm}}, add the {{c|xdm}} service and the {{c|dbus}} service to the {{c|default}} runlevel, and start the services:<br />
<br />
{{file|name=/etc/conf.d/xdm|desc=|body=<br />
DISPLAYMANAGER="<display manager name>"<br />
}}<br />
<br />
{{console|body=<br />
###i## rc-update add xdm default<br />
###i## rc-update add dbus default<br />
###i## rc<br />
}}<br />
==Power Group==<br />
If you wish to be able to shutdown/reboot/suspend/hibernate using xfce4-logout-session then you will need to add yourself or the user to the power group by:<br />
<br />
{{console|body=<br />
###i## gpasswd -a <username> power<br />
}}<br />
If the group does not exist then execute the following and try again:<br />
<br />
{{console|body=<br />
###i## groupadd power}}<br />
== XFCE configuration and XFCE applications ==<br />
For more information on configuring XFCE and the default applications provided by XFCE, such as {{c|xfce4-terminal}}, consider following some of the below listed links:<br />
* [[Package:Xfce4-settings|GUI settings configuration for XFCE ({{c|xfce4-settings}})]]<br />
* [[Package:Xfce4-terminal|The default terminal emulator for XFCE ({{c|xfce4-terminal}})]]<br />
* [[XFCE Panel Plugins|A list of the various plugins available for {{c|xfce4-panel}}]]<br />
* [[Thunar Plugins|A list of the plugins available for the Thunar file manager ]]<br />
<br />
[[Category:Desktop]]<br />
[[Category:First Steps]]<br />
[[Category:Official Documentation]]<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Zope_HOWTO&diff=10530Zope HOWTO2015-06-25T17:32:53Z<p>Duncan.britton: Updated some of the syntax on the page.</p>
<hr />
<div>This page documents how to use Zope with Funtoo Experimental, which currently has good Zope support thanks to [[Progress Overlay Python]] integration.<br />
<br />
== About Zope ==<br />
<br />
Zope is an Open Source application server framework written in Python. It has an interesting history which you should familiarize yourself with before starting Zope development, as it contains several interesting twists and turns.<br />
<br />
=== Zope History ===<br />
<br />
{{Note|This HOWTO targets Zope 2.13, which includes Five. It is typically the version you should be using for new Zope projects.}}<br />
<br />
* There are two versions of Zope: Zope 2 and Zope 3. One might assume that Zope 3 is the version that people should use for new software development projects by default, but this is not the case. Most Zope-based projects continue to use Zope 2. Zope 3 was an attempt to redesign Zope 2 from scratch, and is completely different from Zope 2, but it was not adopted by the community.<br />
<br />
* There is also something called [http://codespeak.net/z3/five/ Five] (named because it is "2 + 3") that backports many of the new features of Zope 3 into the Zope 2 framework. Several projects will use Zope 2 plus Five in order to use some of the newer features in Zope. Five was merged into mainline Zope 2 in early 2010, and first appeared in Zope 2.8.<br />
<br />
* You can learn more about the history of Zope 2, 3 and Five in the [http://svn.zope.org/Zope/trunk/src/Products/Five/README.txt?view=markup Five README].<br />
<br />
* To make things even more interesting, work on [http://docs.zope.org/zope2/releases/4.0/ Zope 4] is underway, and it will be based on 2.13 rather than 3.x. It includes a number of [http://docs.zope.org/zope2/releases/4.0/CHANGES.html#restructuring incompatible changes] with prior versions.<br />
=== Zope Resources ===<br />
<br />
Now that you understand what version of Zope you should be targeting (2.13), we can point you towards the correct documentation :)<br />
<br />
; '''[http://docs.zope.org/zope2/zope2book/ The Zope 2 Book]'''<br />
: This book provides a general introduction to Zope concepts and ZMI. It is a good place to start, but doesn't provide a direct introduction to Zope development. It's recommended that you skim through this book to familiarize yourself with Zope. It generally does not assume much prior knowledge about Web development or Python.<br />
; '''[http://docs.zope.org/zope2/zdgbook/ Zope Developer's Guide]'''<br />
: This guide will give you a better introduction to Zope development. It assumes you already know Python. Skip chapters 1 and 2 and start in [http://docs.zope.org/zope2/zdgbook/ComponentsAndInterfaces.html chapter 3], which covers components and interfaces. [http://docs.zope.org/zope2/zdgbook/Products.html Chapter 5] covers the creation of your first product.<br />
; '''[http://codespeak.net/z3/five/manual.html The Five Manual]'''<br />
: We're not done yet. There is a bunch of stuff in Zope 2.13 that is not in the official documentation. Namely, the stuff in Five.<br />
; '''[http://docs.zope.org/ztkpackages.html ZTK Documentation]'''<br />
: ZTK <br />
; '''ZCA'''<br />
: [http://www.muthukadan.net/docs/zca.html A Comprehensive Guide to Zope Component Architecture] offers a good introduction to the programming concepts of ZCA. We also have a new page on [[Zope Component Architecture]] which will help you to understand the big picture of ZCA and why it is useful. ZCML ("Z-camel") is a part of ZCA and was introduced in Zope 3, so typically you will find ZCML documented within Zope 3 documentation and book.<br />
; '''Content Components'''<br />
: Views and Viewlets: [http://docs.zope.org/zope.viewlet/index.html This tutorial on viewlets] also contains some viewlet-related ZCML examples near the end. The "Content Component way" of developing in Zope seems to be a Zope 3 thing and tied to ZCML. Chapter 13+ of Stephan Richter's ''Zope 3 Developer's Handbook'' (book) seems to cover this quite well. You will probably also want to check out Philipp Weitershausen's ''Web Component Development with Zope 3'' (book).<br />
; '''[http://wiki.zope.org/zope2/Zope2Wiki Zope 2 Wiki]'''<br />
: Main wiki page for all things related to Zope 2.<br />
; '''[http://docs.zope.org docs.zope.org]'''<br />
: This is the main site for Zope documentation.<br />
<br />
== First Steps ==<br />
<br />
First, you will need to emerge {{Package|net-zope/zope}}:<br />
{{console|body=<br />
###i## emerge zope<br />
}}<br />
Zope is now installed.<br />
<br />
== Project Skeleton ==<br />
<br />
{{Note|Zope should be run by a regular user account, not as the root user.}}<br />
<br />
The first step in using Zope is to ensure that you are using a regular user account. As a regular user, create a new directory called {{c|zope_test}}:<br />
{{console|body=<br />
$##bl## cd<br />
$##bl## mkdir zope_test<br />
}}<br />
Now, enter the directory, and create an "instance", which is a set of files and directories that are used to contain a Zope project:<br />
{{console|body=<br />
$##bl## cd zope_test<br />
$##bl## /usr/lib/zope-2.13/bin/mkzopeinstance<br />
}}<br />
You will see the following output and will be prompted to answer a few questions:<br />
{{console|body=<br />
Please choose a directory in which you'd like to install<br />
Zope "instance home" files such as database files, configuration<br />
files, etc.<br />
<br />
Directory: instance<br />
Please choose a username and password for the initial user.<br />
These will be the credentials you use to initially manage<br />
your new Zope instance.<br />
<br />
Username: admin<br />
Password: ****<br />
Verify password: **** <br />
}}<br />
Now, we will start our Zope instance:<br />
{{console|body=<br />
$##bl## cd instance<br />
$##bl## bin/runzope<br />
}}<br />
Now that Zope is functional, you can go to the {{c|localhost:8080/manage}} URL in your web browser: you will be prompted to log in. Enter the username and password you specified. You are now logged in to the ZMI (Zope Management Interface.)<br />
<br />
You can stop your application by pressing Control-C. In the future, you can start and stop your Zope instance using the following commands:<br />
{{console|body=<br />
$##bl## zopectl start<br />
$##bl## zopectl stop<br />
}}<br />
{{Note|{{c|zopectl start}} will cause your instance to run in the background rather than consuming a shell console.}}<br />
<br />
== First Project ==<br />
<br />
We will create a single, very primitive Zope package, consisting of an Interface for a TODO class, and a TODO class.<br />
<br />
Create the following files and directories relative to your project root:<br />
<br />
* Create the directory {{c|lib/python/example}}.<br />
* Create the file {{c|lib/python/example/__init__.py}} by typing {{c|touch lib/python/example/__init__.py}}.<br />
* Create these files:<br />
<br />
=== {{c|example-configure.zcml}} ===<br />
<br />
This file registers the {{c|example}} directory you created in {{c|lib/python}} as a ''package'', so that it is seen by Zope. Edit {{c|/etc/package-includes/example-configure.zcml}}:<br />
{{file|name=/etc/package-includes/example-configure.zcml|body=<br />
<include package="example" /><br />
}}<br />
<br />
=== {{c|interfaces.py}} ===<br />
<br />
The following file defines the <tt>ITODO</tt> interface, and also uses some Zope Schema functions to define what kind of data we expect to store in objects that implement <tt>ITODO</tt>. Edit <code>/lib/python/example/interfaces.py</code> with your favorite text editor:<br />
<br />
<syntaxhighlight lang="python"><br />
from zope.interface import Interface<br />
from zope.schema import List, Text, TextLine, Int<br />
<br />
class ITODO(Interface):<br />
name = TextLine(title=u'Name', required=True)<br />
todo = List(title=u"TODO Items", required=True, value_type=TextLine(title=u'TODO'))<br />
daysleft = Int(title=u'Days left to complete', required=True)<br />
description = Text(title=u'Description', required=True)<br />
</syntaxhighlight><br />
<br />
=== {{c|TODO.py}} ===<br />
<br />
Now, we define {{c|TODO}} to be a ''persistent'' object, meaning it can be stored in the ZODB. We specify that it implements our previously-defined {{c|ITODO}} interface, and provide reasonable defaults for all values when we create a new TODO object. Edit {{c|/lib/python/example/TODO.py}} using your favorite text editor:<br />
{{file|name=/lib/python/example/TODO.py|lang=python|body=<br />
from persistent import Persistent<br />
from zope.interface import implements<br />
from example.interfaces import ITODO<br />
<br />
class TODO(Persistent):<br />
implements(ITODO)<br />
name = u''<br />
todo = []<br />
daysleft = 0<br />
description = u''<br />
}}<br />
<br />
=== {{c|configure.zcml}} ===<br />
<br />
Create the <tt>/lib/python/example/configure.zcml</tt> configuration file:<br />
<syntaxhighlight lang="xml"><br />
<configure xmlns="http://namespaces.zope.org/zope"<br />
xmlns:five="http://namespaces.zope.org/five"<br />
xmlns:browser="http://namespaces.zope.org/browser"><br />
</configure><br />
</syntaxhighlight><br />
<br />
== Debug Mode ==<br />
<br />
We can test our first project by entering debug mode:<br />
<console><br />
$##i## bin/zopectl debug<br />
Starting debugger (the name "app" is bound to the top-level Zope object)<br />
</console><br />
<br />
Now, let's try creating a new TODO object and writing it out to a ZODB database:<br />
<console><br />
>>> from ZODB import FileStorage, DB<br />
>>> storage = FileStorage.FileStorage('mydatabase.fs')<br />
>>> db = DB(storage)<br />
>>> connection = db.open()<br />
>>> import transaction<br />
>>> root = connection.root()<br />
>>> from example.TODO import TODO<br />
>>> a = TODO<br />
>>> a.name = u'My TODOs'<br />
>>> a.TODOS = [ u'Do Laundry', u'Wash Dishes' ]<br />
>>> a.daysleft = 1<br />
>>> a.description = u'Things I need to do today.'<br />
>>> root[u'today'] = a<br />
>>> transaction.commit()<br />
</console><br />
<br />
[[Category:HOWTO]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=XFCE_Panel_Plugins&diff=10514XFCE Panel Plugins2015-06-24T22:12:32Z<p>Duncan.britton: Added an extra space between the end of the numbered list and the table.</p>
<hr />
<div>As is apparent from the list below, there are quite a large number of different plugins available for the XFCE panel that can be found in the Funtoo GNU/Linux Portage tree. The basic procedure for adding a new panel plugin is as follows:<br />
Emerge the desired plugin by running the following command, as root:<br />
{{console|body=<br />
###i## emerge <name of plugin><br />
}}<br />
Then, add the plugin to the desired panel, using the following steps:<br />
# Open [[Package:Xfce4-settings|xfce4-settings-manager]] and select the "Panel" button<br />
# Go to the items tab under the panel configuration window<br />
# Click the "+" button on the right side of the window<br />
# Select the desired plugin to add to the panel from the list of plugins<br />
<br />
<br />
{{TableStart}}<br />
<tr class="info"><th>Name of plugin</th><th>Description of plugin</th></tr><br />
<tr><td>{{c|xfce4-battery-plugin}}</td><td>A battery monitor panel plugin for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-cellmodem-plugin}}</td><td>A panel plug-in with monitoring support for GPRS/UMTS(3G)/HSDPA(3.5G) modems</td></tr><br />
<tr><td>{{c|xfce4-clipman-plugin}}</td><td>A clipboard manager plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-cpufreq-plugin}}</td><td>A panel plugin for showing information about cpufreq settings</td></tr><br />
<tr><td>{{c|xfce4-cpugraph-plugin}}</td><td>A system load plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-datetime-plugin}}</td><td>A panel plug-in with date, time and embedded calender</td></tr><br />
<tr><td>{{c|xfce4-diskperf-plugin}}</td><td>A panel plug-in for disk usage and performance statistics</td></tr><br />
<tr><td>{{c|xfce4-embed-plugin}}</td><td>A plug-in for embedding arbitrary application windows into the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-equake-plugin}}</td><td>Panel plug-in that displays information about earthquakes at regular intervals</td></tr><br />
<tr><td>{{c|xfce4-eyes-plugin}}</td><td>A panel plug-in which adds classic eyes to your every step</td></tr><br />
<tr><td>{{c|xfce4-fsguard-plugin}}</td><td>A filesystem guard plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-genmon-plugin}}</td><td>Cyclically spawns the executable, captures its output and displays the result into the panel</td></tr><br />
<tr><td>{{c|xfce4-gvfs-mount}}</td><td>A panel plug-in to mount remote filesystems for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-indicator-plugin}}</td><td>A panel plugin that uses indicator-applet to show new messages</td></tr><br />
<tr><td>{{c|xfce4-kbdleds-plugin}}</td><td>A panel plug-in to show state of Caps, Num and Scroll Lock keys</td></tr><br />
<tr><td>{{c|xfce4-mailwatch-plugin}}</td><td>An mail notification panel plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-modemlights-plugin}}</td><td>A panel plug-in intended to simplify establishing a ppp connection</td></tr><br />
<tr><td>{{c|xfce4-mount-plugin}}</td><td>An mount plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-mpc-plugin}}</td><td>Music Player Daemon (mpd) panel plugin</td></tr><br />
<tr><td>{{c|xfce4-netload-plugin}}</td><td>A network load plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-notes-plugin}}</td><td>Xfce4 panel sticky notes plugin</td></tr><br />
<tr><td>{{c|xfce4-places-plugin}}</td><td>A panel plug-in to provide quick access to files, folders and removable media</td></tr><br />
<tr><td>{{c|xfce4-playercontrol-plugin}}</td><td>Audacious and MPD panel plugins</td></tr><br />
<tr><td>{{c|xfce4-pulseaudio-plugin}}</td><td>A panel plug-in for PulseAudio volume control</td></tr><br />
<tr><td>{{c|xfce4-quicklauncher-plugin}}</td><td>A quicklauncher plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-radio-plugin}}</td><td>V4L radio device control plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-sensors-plugin}}</td><td>A panel plug-in for different sensors using acpi, lm_sensors and hddtemp</td></tr><br />
<tr><td>{{c|xfce4-smartbookmark-plugin}}</td><td>Smart bookmark plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-systemload-plugin}}</td><td>System load plug-in for Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-time-out-plugin}}</td><td>A panel plug-in to take periodical breaks from the computer</td></tr><br />
<tr><td>{{c|xfce4-timer-plugin}}</td><td>A simple timer plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-verve-plugin}}</td><td>A comfortable command line plugin for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-wavelan-plugin}}</td><td>A panel plug-in to display wireless interface statistics</td></tr><br />
<tr><td>{{c|xfce4-weather-plugin}}</td><td>A weather plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-whiskermenu-plugin}}</td><td>Alternate application launcher for Xfce</td></tr><br />
<tr><td>{{c|xfce4-wmdock-plugin}}</td><td>a compatibility layer for running WindowMaker dockapps on Xfce4</td></tr><br />
<tr><td>{{c|xfce4-xkb-plugin}}</td><td>XKB layout switching panel plug-in for the Xfce desktop environment</td></tr><br />
{{TableEnd}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=XFCE_Panel_Plugins&diff=10513XFCE Panel Plugins2015-06-24T21:26:56Z<p>Duncan.britton: Added documentation as to how new items can be added to a panel.</p>
<hr />
<div>As is apparent from the list below, there are quite a large number of different plugins available for the XFCE panel that can be found in the Funtoo GNU/Linux Portage tree. The basic procedure for adding a new panel plugin is as follows:<br />
Emerge the desired plugin by running the following command, as root:<br />
{{console|body=<br />
###i## emerge <name of plugin><br />
}}<br />
Then, add the plugin to the desired panel, using the following steps:<br />
# Open [[Package:Xfce4-settings|xfce4-settings-manager]] and select the "Panel" button<br />
# Go to the items tab under the panel configuration window<br />
# Click the "+" button on the right side of the window<br />
# Select the desired plugin to add to the panel from the list of plugins<br />
<br />
{{TableStart}}<br />
<tr class="info"><th>Name of plugin</th><th>Description of plugin</th></tr><br />
<tr><td>{{c|xfce4-battery-plugin}}</td><td>A battery monitor panel plugin for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-cellmodem-plugin}}</td><td>A panel plug-in with monitoring support for GPRS/UMTS(3G)/HSDPA(3.5G) modems</td></tr><br />
<tr><td>{{c|xfce4-clipman-plugin}}</td><td>A clipboard manager plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-cpufreq-plugin}}</td><td>A panel plugin for showing information about cpufreq settings</td></tr><br />
<tr><td>{{c|xfce4-cpugraph-plugin}}</td><td>A system load plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-datetime-plugin}}</td><td>A panel plug-in with date, time and embedded calender</td></tr><br />
<tr><td>{{c|xfce4-diskperf-plugin}}</td><td>A panel plug-in for disk usage and performance statistics</td></tr><br />
<tr><td>{{c|xfce4-embed-plugin}}</td><td>A plug-in for embedding arbitrary application windows into the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-equake-plugin}}</td><td>Panel plug-in that displays information about earthquakes at regular intervals</td></tr><br />
<tr><td>{{c|xfce4-eyes-plugin}}</td><td>A panel plug-in which adds classic eyes to your every step</td></tr><br />
<tr><td>{{c|xfce4-fsguard-plugin}}</td><td>A filesystem guard plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-genmon-plugin}}</td><td>Cyclically spawns the executable, captures its output and displays the result into the panel</td></tr><br />
<tr><td>{{c|xfce4-gvfs-mount}}</td><td>A panel plug-in to mount remote filesystems for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-indicator-plugin}}</td><td>A panel plugin that uses indicator-applet to show new messages</td></tr><br />
<tr><td>{{c|xfce4-kbdleds-plugin}}</td><td>A panel plug-in to show state of Caps, Num and Scroll Lock keys</td></tr><br />
<tr><td>{{c|xfce4-mailwatch-plugin}}</td><td>An mail notification panel plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-modemlights-plugin}}</td><td>A panel plug-in intended to simplify establishing a ppp connection</td></tr><br />
<tr><td>{{c|xfce4-mount-plugin}}</td><td>An mount plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-mpc-plugin}}</td><td>Music Player Daemon (mpd) panel plugin</td></tr><br />
<tr><td>{{c|xfce4-netload-plugin}}</td><td>A network load plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-notes-plugin}}</td><td>Xfce4 panel sticky notes plugin</td></tr><br />
<tr><td>{{c|xfce4-places-plugin}}</td><td>A panel plug-in to provide quick access to files, folders and removable media</td></tr><br />
<tr><td>{{c|xfce4-playercontrol-plugin}}</td><td>Audacious and MPD panel plugins</td></tr><br />
<tr><td>{{c|xfce4-pulseaudio-plugin}}</td><td>A panel plug-in for PulseAudio volume control</td></tr><br />
<tr><td>{{c|xfce4-quicklauncher-plugin}}</td><td>A quicklauncher plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-radio-plugin}}</td><td>V4L radio device control plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-sensors-plugin}}</td><td>A panel plug-in for different sensors using acpi, lm_sensors and hddtemp</td></tr><br />
<tr><td>{{c|xfce4-smartbookmark-plugin}}</td><td>Smart bookmark plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-systemload-plugin}}</td><td>System load plug-in for Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-time-out-plugin}}</td><td>A panel plug-in to take periodical breaks from the computer</td></tr><br />
<tr><td>{{c|xfce4-timer-plugin}}</td><td>A simple timer plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-verve-plugin}}</td><td>A comfortable command line plugin for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-wavelan-plugin}}</td><td>A panel plug-in to display wireless interface statistics</td></tr><br />
<tr><td>{{c|xfce4-weather-plugin}}</td><td>A weather plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-whiskermenu-plugin}}</td><td>Alternate application launcher for Xfce</td></tr><br />
<tr><td>{{c|xfce4-wmdock-plugin}}</td><td>a compatibility layer for running WindowMaker dockapps on Xfce4</td></tr><br />
<tr><td>{{c|xfce4-xkb-plugin}}</td><td>XKB layout switching panel plug-in for the Xfce desktop environment</td></tr><br />
{{TableEnd}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Talk:Installation_(Tutorial)&diff=10512Talk:Installation (Tutorial)2015-06-24T20:30:15Z<p>Duncan.britton: /* Updating this page. */ new section</p>
<hr />
<div>--[[User:Danielv|Danielv]] ([[User talk:Danielv|talk]]) 10:53, June 24, 2015 (UTC)<br />
Please don't delete this, as it is very detailed. Thanks!<br />
<br />
== Updating this page. ==<br />
<br />
I removed the tag suggesting deletion, as I can tell that a lot of work was put into the page. It would be nice to see the page 'wikified' (use the instructions provided at [[Help:Funtoo_Editing_Guidelines|Editing Guidelines]]).</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Installation_(Tutorial)&diff=10511Installation (Tutorial)2015-06-24T20:27:48Z<p>Duncan.britton: Removed tag suggesting deletion.</p>
<hr />
<div>{{note|If you want to do a standard Funtoo Linux installation, I recommend you use the shorter, official [[Funtoo Linux Installation]] Instructions instead. -Daniel}}<br />
<br />
__TOC__<br />
<br />
== Introduction ==<br />
<br />
This HowTo aims to give the experienced GNU/Linux User a quick way to install Funtoo Linux in a nice and fast way. Also we will give you all the necessary steps for installing Funtoo GNU/Linux in this guide, but we won't go deeper into the details of them as need<br />
<br />
There are two ways of installing Funtoo GNU/Linux on your PC:<br />
<br />
# using an already installed GNU/Linux System or<br />
# using a LiveCD<br />
<br />
If you plan to use a LiveCD, we recommend you to use [http://www.sysresccd.org/ SystemRescueCd].<br />
<br />
All the commands in this guide are performed as "root", unless we indicate it otherwise.<br />
<br />
This HowTo will cover the following four setups:<br />
<br />
# a standard Installation (MBR, HDD not encrypted),<br />
# a standard secure Installation (MBR, HDD encrypted),<br />
# a modern Installation (GPT/GUID partition table, HDD not encrypted) and<br />
# a modern secure Installation (GPT/GUID partition table, HDD encrypted).<br />
<br />
These four approaches have the following Pros and Cons:<br />
<br />
<br />
{| border="1" cellpadding="4"<br />
|-<br />
! Setup !! Pro !! Contra<br />
|-<br />
| 1 <br />
|<br />
* Easy method mostly used by all distributions<br />
* Well documented everywhere<br />
* Time saving method<br />
* No special EFI-partition needed<br />
* Dualbootable with Microsoft® Windows™ <br />
|<br />
*Partition table limited 4 primary ones only<br />
* Needs special 4th partition for more than 4 partitions<br />
* HDD not encrypted, can easily be cloned<br />
|-<br />
| 2 <br />
|<br />
* Easy method mostly used by all distributions<br />
* Well documented everywhere<br />
* No special EFI-partition needed<br />
* HDD encrypted<br />
* Dualbootable with Microsoft® Windows™<br />
* Logical volume groups for GNU/Linux <br />
|<br />
*Partition table limited 4 primary ones only<br />
* Need special 4th partition for more than 4 partitions<br />
* Needs lot of time for preparing the HDD to be encrypted<br />
|-<br />
| 3 <br />
|<br />
* Easy method but nearly not used by other distributions<br />
* No special partiton needed for more than 4 partitions<br />
* Time saving method <br />
|<br />
* Need special EFI-partition for boot-manager<br />
* Special kernel attributes are needed<br />
* Not compatible with Microsoft® Windows™<br />
* Not supported on all platforms especially for the system volume<br />
* HDD not encrypted, can easily be cloned from other linux systems<br />
|-<br />
| 4 <br />
|<br />
* Easy method but nearly not used by other distributions<br />
* No special partition needed for more than 4 partitions<br />
* HDD encrypted<br />
* Logical volume groups <br />
|<br />
* Need special EFI-partition for boot-manager<br />
* Special kernel attributes are needed<br />
* Not compatible with Microsoft® Windows™<br />
* Not supported on all platforms especially for the system volume<br />
* Needs lot of time for preparing the HDD to be encrypted<br />
|}<br />
<br />
With the help of the the above table you should be able to select your future Hard Disk (HDD) partitioning scheme. In the further guide we will go through every single step for all four schemes.<br />
<br />
For booting your old/other GNU/Linux System we won't give you a special detailed howto guide, as you should know how to do so, as concerning the booting with [http://www.sysresccd.org SystemRescueCd], we will give you a short step-by-step guide on how to boot up the system.<br />
<br />
This guide will only be split into subparts for the installation process if concerning the four above mentioned steps, here the split points will be MBR vs. GPT/GUID-partitioning and encrypted vs. unencrypted HDD. So be aware of these parts if you want to use them.<br />
<br />
== Booting the Installation System ==<br />
<br />
=== Booting old/other GNU/Linux ===<br />
<br />
This step is really simple, as you know your old GNU/Linux System and you need simply start your Computer, select in the boot-loader your GNU/Linux System, let it start up, log in as always and start a root-terminal.<br />
<br />
=== Booting with SystemRescueCd ===<br />
<br />
First step is to download [http://www.sysresccd.org SystemRescueCd], an overview of the actual version can be found at [http://www.sysresccd.org/Download http://www.sysresccd.org/Download], just follow there the link to the Sourceforge Download, you will download then about 300 MB to your HDD. If finished burn this ISO-image with your favorite burning tool like ''burn-cd, bashburn, K3B, GNOMEbaker'' on a GNU/Linux Box or ''NERO Burning ROM, CDBurnerXP Pro, and many more'' on a Microsoft® Windows™ box.<br />
[[Image:fqi-001.png|center]]<br />
<br />
Next insert this CD into your CD-ROM-Drive and boot up the PC with it where you want to install Funtoo GNU/Linux. Make sure you boot from the CD when booting. The Booting process with [http://www.sysresccd.org SystemRescueCd] will follow the next steps:<br />
<br />
# Selecting your Kernel to boot [http://www.sysresccd.org/ SystemRescueCd] with:<br />
[[Image:fqi-002.png|center]]<br />
In that screen you will be greeted with all the power of [http://www.sysresccd.org/ SystemRescueCd], depending on your CPU we use the boot option 1) for a 32-bit CPU or a 64-bit CPU that should run in 32-bit mode and 6) for a 64-bit CPU in 64-bit mode. If this boot option fails, use the boot option A) or B), will will lead to the following screen:<br />
[[Image:fqi-003.png|center]]<br />
That menu will give you more boot options. If you select 1. here, it would be the same kernel option like in the previous screen 1) and 6). The next step is to select your keyboard layout for installation.<br />
# Selecting your Installation Keyboard Layout<br />
[[Image:fqi-004.png|center]]<br />
That step requires a bit of your atention, as it only gives you 20 seconds time to choose your keyboard layout, if you are OK with the US keymap, just press Enter to accept the default setting.<br />
# Being ready<br />
Seconds later [http://www.sysresccd.org/ SystemRescueCd] welcomes you wit a short message and is ready fo you to be used to perform your installation.<br />
[[Image:fqi-005.png|center]]<br />
<br />
= HDD Preparation =<br />
As mentioned earlier in this guide we cover four different installation variations, the could be displayed in an installation matrix as below:<br />
<br />
{| cellpadding="4"<br />
|-<br />
! !! '''MBR''' !! '''GPT'''<br />
|-<br />
| '''unencrypted''' || See [[#MBR|MBR]] || See [[#GPT/GUID partition table|GPT/GUID partition table]]<br />
|-<br />
| '''encrypted''' || See [[#MBR|MBR]] || See [[#GPT/GUID partition table|GPT/GUID partition table]]<br />
|}<br />
<br />
If you are going to plan to install Funtoo GNU/Linux on a machine where another O/S is already installed, you have to make some free space available on your HDD in order to do so. A resize of most existing filesystems can be done with [http://www.sysresccd.org/ SystemRescueCd] too. You just need to enter the graphical environment and use gparted. We will give you a short example on how to do so with a sample HDD that might hold windows, so you get a feeling what to do, but be aware that a resize can be a dangerous part, so please keep a backup of your data, as Funtoo Technologies wouldn't take any responsibility for a loss of data that could happen by the process of shrinking a partition.<br />
<br />
Starting the graphical environment in [http://www.sysresccd.org/ SystemRescueCd] is really simple, just execute the following command:<br />
<br />
<pre><br />
root@sysresccd /root % wizard<br />
</pre><br />
<br />
and it will start a dialog for the graphical environment setup, for most users the default options should be OK. Both the dialog and the graphical environment (Xfce) are shown in the next two images.<br />
<br />
[[Image:fqi-006.png|center]]<br />
[[Image:fqi-007.png|center]]<br />
<br />
=== Resize of HDD partitions ===<br />
<br />
The above screen shows us that there is the tool called GParted right on the frontpanel. That tool will be used to resize our HDD partitions. The following screen shows us an example of how the tool looks if you start it.<br />
[[Image:fqi-008.png|center]]<br />
By clicking on the partion you want to resize you make it active right-click on it and use the point resize and you will see the Resize/Move dialog, here you can edit the resize options for that partiton.<br />
[[Image:fqi-009.png|center]]<br />
When you finished setting the resize options, you will see that the grey-green hook in the menu got green, that means you have jobs added to the working list. If you have all actions done on the partition, click on the green hook and your resize action will run by giving you the following feedback window:<br />
[[Image:fqi-010.png|center]]<br />
when that has finished you will see the resized result and it should look like that:<br />
[[Image:fqi-011.png|center]]<br />
we are finished with resizing the dis partitions, exit the Tool and close Xfce by clicking the running exit man in the down right. We are back on the command line and are ready to partitions our disk. to our needs, for a unified way we will show it with an empty partition table, so if you have resized some partitions, they will be listed in the MBR menu, as if you want to use an GPT/GUID partition table we will start from a clean table anyway.<br />
<br />
=== Partitioning scheme ===<br />
<br />
{{fancywarning|If you are partitioning the hard drive of a SPARC machine, please see [[Funtoo Linux Installation on SPARC]]. Also, note that '''OpenBoot has no support for GPT volumes and you won't be able to boot on the system volume if that later has been partitioned with GPT.''' }}<br />
<br />
For partitioning we suggest the following schemes:<br />
* MBR unencrypted<br />
<br />
{| cellpadding="4"<br />
|-<br />
! Partition !! Size !! fdisk option !! Filesystem (FS)<br />
|-<br />
| /boot || 200 MB || 83 || ext2<br />
|-<br />
| swap || 2x RAM if 1024 MB or less, otherwise 2 GB || 82 || sw (default)<br />
|-<br />
| / || 20-50 GB || 83 || ext4<br />
|-<br />
| /usr/portage || ~10 GB || 83 || ext4<br />
|-<br />
| /home || As much as possible. || 83 || xfs<br />
|}<br />
<br />
* MBR encrypted<br />
<br />
{| cellpadding="4"<br />
|-<br />
! Partition !! Size !! fdisk option !! FS<br />
|-<br />
| /boot || 200 MB || 83 || ext2<br />
|-<br />
| cryptoroot || Rest of the Disc || 83 || none<br />
|}<br />
<br />
* GPT unencrypted<br />
<br />
{| cellpadding="4"<br />
|-<br />
! Partition !! Size !! gdisk option !! FS<br />
|-<br />
| /boot || 200 MB || 0700 || ext2<br />
|-<br />
| EFI-Boot || 512 kB || EF02 || none<br />
|-<br />
| swap || 2x RAM if 1024 MB or less, otherwise 2 GB || 8200 || swap (default)<br />
|-<br />
| / || 20 - 50 GB || 0700 || ext4<br />
|-<br />
| /usr/portage || ~10 GB || 0700 || ext4<br />
|-<br />
| /home || Rest of the Disc || 0700 || xfs<br />
|}<br />
<br />
* GPT encrypted<br />
<br />
{| cellpadding="4"<br />
|-<br />
! Partition !! Size !! gdisk option !! FS<br />
|-<br />
| /boot || 200 MB || 0700 || ext2<br />
|-<br />
| EFI-Boot || 512 kB || EF02 || none<br />
|-<br />
| cryptoroot || Rest of the Disc || 0700 || none<br />
|}<br />
<br />
=== MBR ===<br />
<br />
Now we will partition the HDD using the above scheme with a disk partitioning tool named "fdisk". So just invoke it with the following command:<br />
<br />
<pre><br />
# fdisk /dev/sda <br />
</pre><br />
<br />
it will greet you like this<br />
[[Image:fqi-012.png|center]]<br />
by pressing <tt>`m`</tt> you will get a help context menu that will give you the following options:<br />
<br />
<pre><br />
a toggle a bootable flag<br />
b edit bsd disklabel<br />
c toggle the dos compatibility flag<br />
d delete a partition<br />
l list known partition types<br />
m print this menu<br />
n add a new partion<br />
o create a new empty DOS partition table<br />
p print the partition table<br />
q quit without saving changes<br />
s create a new empty Sun disklabel <--- SPARC specific, see Funtoo installation notes for SPARC<br />
t change a partition's system id<br />
u change display/entry units<br />
v verify the partition table<br />
w write table to disk and exit<br />
x extra functionality (experts only)<br />
</pre><br />
<br />
The partitioning scheme is created with the following commands inside of fdisk:<br />
<br />
==== unencrypted ====<br />
<br />
<pre><br />
Command (m for help): n<br />
</pre><br />
<br />
it will ask you now if you want to add a primary or extended partition, we choose primary by pressing<br />
<br />
<pre><br />
Command action<br />
e extended<br />
p primary partition (1-4)<br />
p<br />
</pre><br />
<br />
and use for the next 2 steps the default options and add as the Last Sector for the first partition the following:<br />
<br />
<pre><br />
Partition number (1-4, default 1): (default)<br />
Using default value 1<br />
First sector: (Use default)<br />
Using default value<br />
Last sector, ...: +200M<br />
</pre><br />
<br />
your input should look like that right now:<br />
[[Image:fqi-013.png|center]]<br />
next we need to make the partition bootable and add then the rest of the partitions:<br />
<br />
<pre><br />
Command (m for help): a<br />
Partition number (1-4): 1<br />
<br />
Command (m for help): t<br />
Selected partition 1<br />
Hex code (type L to list codes): 83<br />
<br />
Command (m for help): n<br />
Command action <br />
e extended<br />
p primary partition (1-4)<br />
p<br />
Partition number (1-4, default 2): (default)<br />
Using default value 2<br />
First sector: (Use default)<br />
Using default value<br />
Last sector, ...: +2G<br />
<br />
Command (m for help): t<br />
Partition number (1-4): 2<br />
Hex code (type L to list codes): 82<br />
Changed system type of partition 2 to 82 (Linux swap / Solaris)<br />
<br />
Command (m for help): n<br />
Command action <br />
e extended<br />
p primary partition (1-4)<br />
p<br />
Partition number (1-4, default 3): (default)<br />
Using default value 3<br />
First sector: (Use default)<br />
Using default value<br />
Last sector, ...: +20G<br />
<br />
Command (m for help): t<br />
Partition number (1-4): 3<br />
Hex code (type L to list codes): 83<br />
<br />
Command (m for help): n<br />
Command action <br />
e extended<br />
p primary partition (1-4)<br />
e<br />
Selected partition 4<br />
First sector: (Use default)<br />
Using default value<br />
Last sector, ...: (Use default)<br />
Using default value<br />
<br />
Command (m for help): n<br />
First sector: (Use default)<br />
Using default value<br />
Last sector, ...: +10G<br />
<br />
Command (m for help): t<br />
Partition number (1-5): 5<br />
Hex code (type L to list codes): 83<br />
<br />
Command (m for help): n<br />
First sector: (Use default)<br />
Using default value<br />
Last sector, ...: (Use default)<br />
<br />
Command (m for help): t<br />
Partition number (1-6): 6<br />
Hex code (type L to list codes): 83<br />
<br />
Command (m for help): p<br />
</pre><br />
<br />
this will result in the following output<br />
[[Image:fqi-014.png|center]]<br />
now just write the partition table to your disk by using <tt>`w`</tt>, this will result in the following output:<br />
<br />
<pre><br />
Command (m for help): w<br />
The partition table has been altered!<br />
<br />
Calling ioctl() to re-read partition table.<br />
Syncing disks.<br />
</pre><br />
<br />
If that was your scheme, you are now so far to get to the partition formatting section.<br />
<br />
==== encrypted ====<br />
<br />
<pre><br />
Command (m for help): n<br />
</pre><br />
<br />
it will ask you now if you want to add a primary or extended partition, we choose primary by pressing<br />
<br />
<pre><br />
Command action<br />
e extended<br />
p primary partition (1-4)<br />
p<br />
</pre><br />
<br />
and use for the next 2 steps the default options and add as the Last Sector for the first partition the following:<br />
<br />
<pre><br />
Partition number (1-4, default 2): (default)<br />
Using default value 1<br />
First sector: (Use default)<br />
Using default value<br />
Last sector, ...: +200M<br />
</pre><br />
<br />
Next we need to make the partition bootable and add then the rest of the partition:<br />
<br />
<pre><br />
Command (m for help): a<br />
Partition number (1-4): 1<br />
<br />
Command (m for help): t<br />
Selected partition 1<br />
Hex code (type L to list codes): 83<br />
<br />
Command (m for help): n<br />
Command action <br />
e extended<br />
p primary partition (1-4)<br />
p<br />
Partition number (1-4, default 2): (default)<br />
Using default value 2<br />
First sector: (Use default)<br />
Using default value<br />
Last sector, ...: (use default)<br />
<br />
Command (m for help): p<br />
</pre><br />
<br />
this will result in the following output<br />
[[Image:fqi-015.png|center]]<br />
now just write the partition table to your disk by using <tt>w</tt>, this will result in the following output:<br />
<br />
<pre><br />
Command (m for help): w<br />
The partition table has been altered!<br />
<br />
Calling ioctl() to re-read partition table.<br />
Syncing disks.<br />
</pre><br />
<br />
next we need to prepare our cryto-container that will keep all the encrypted stuff in it. For that, go to the [[#Cryptocontainer|Cryptocontainer]] section.<br />
<br />
=== GPT/GUID partition table ===<br />
<br />
This setup is for most users more intuitive, since we don't need to care about extended partitions. We only need to setup an extra partition for our bootloader. So let us do it for unencrypted and encrypted partitions.<br />
<br />
For setting up the GPT partition table we use the tool "gdisk", that is the GPT equivalent of fdisk.<br />
<br />
Just start it with the following command:<br />
<br />
<pre><br />
gdisk /dev/sda <br />
</pre><br />
<br />
it will greet you with the following screen<br />
[[Image:fqi-016.png|center]]<br />
<br />
==== unencrypted ====<br />
<br />
Next we will create the partitions for our unencrypted setup:<br />
<br />
<pre><br />
Command (? for help): n<br />
Partition number (1-128, default 1): (Use default)<br />
First sector (34-..., default = 34) or ...: (Use default)<br />
Information: Moved requested sector from 34 to 2048 in<br />
order to align on 2048-sector boundaries.<br />
Use 'l' on the experts' menu to adjust alignment<br />
Last sector (2048-..., default = ...) or ...: +200M<br />
Current type is 'Linux/Windows data'<br />
Hex code or GUID (L to show codes, Enter = 0700): (ENTER)<br />
Changed type of partition to 'Linux/Windows data'<br />
<br />
Command (? for help): n<br />
Partion number (2-128, default 2): (Use default)<br />
First sector (...) or ...: (Use default)<br />
Last sector (...) or (...): +512K<br />
Current type is 'Linux/Windows data'<br />
Hex code or GUID (L to show codes, Enter = 0700): ef02<br />
Changed type of partition to 'BIOS boot partition'<br />
<br />
Command (? for help): n<br />
Partition number (3-128, default 3): (Use default)<br />
First sector (...) or ...: (Use default)<br />
Last sector (...) or (...): +2G<br />
Current type is 'Linux/Windows data'<br />
Hex code or GUID (L to show codes, Enter = 0700): 8200<br />
Changed type of partition to 'Linux swap'<br />
<br />
Command (? for help): n<br />
Partition number 4-128, default 4): (Use default)<br />
First sector (...) or ...: (Use default)<br />
Last sector (...) or (...): +20G<br />
Current type is 'Linux/Windows data'<br />
Hex code or GUID (L to show codes, Enter = 0700): (ENTER)<br />
Changed type of partition to 'Linux/Windows data'<br />
<br />
Command (? for help): n<br />
Partition number 5-128, default 5): (Use default)<br />
First sector (...) or ...: (Use default)<br />
Last sector (...) or (...): +10G<br />
Current type is 'Linux/Windows data'<br />
Hex code or GUID (L to show codes, Enter = 0700): (ENTER)<br />
Changed type of partition to 'Linux/Windows data'<br />
<br />
Command (? for help): n<br />
Partition number 6-128, default 6): (Use default)<br />
First sector (...) or ...: (Use default)<br />
Last sector (...) or (...): (Use default)<br />
Current type is 'Linux/Windows data'<br />
Hex code or GUID (L to show codes, Enter = 0700): (ENTER)<br />
Changed type of partition to 'Linux/Windows data'<br />
<br />
Command (? for help): p<br />
</pre><br />
<br />
will now show you a disk partitioning like that one:<br />
[[Image:fqi-017.png|center]]<br />
now write the table to your disk with <tt>w</tt>;<br />
<br />
<pre><br />
Command (? for help): w<br />
<br />
Final checks complete. About to write GPT data. THIS WILL OVERWRITE EXISTING PARTITIONS!!<br />
<br />
Do you want to proceed, possibly destroying your data? (Y/N): Y<br />
OK; writing new GUID partition table (GPT).<br />
The operation has completed successfully.<br />
</pre><br />
<br />
Now go the section about creating the filesystem on MBR.<br />
<br />
==== encrypted ====<br />
<br />
Next we will create the partitions for our encrypted setup:<br />
<br />
<pre><br />
Command (? for help): n<br />
Partition number (1-128, default 1): (Use default)<br />
First sector (34-..., default = 34) or ...: (Use default)<br />
Information: Moved requested sector from 34 to 2048 in<br />
order to align on 2048-sector boundaries.<br />
Use 'l' on the experts' menu to adjust alignment<br />
Last sector (2048-..., default = ...) or ...: +200M<br />
Current type is 'Linux/Windows data'<br />
Hex code or GUID (L to show codes, Enter = 0700): (ENTER)<br />
Changed type of partition to 'Linux/Windows data'<br />
<br />
Command (? for help): n<br />
Partion number (2-128, default 2): (Use default)<br />
First sector (...) or ...: (Use default)<br />
Last sector (...) or (...): +512K<br />
Current type is 'Linux/Windows data'<br />
Hex code or GUID (L to show codes, Enter = 0700): ef02<br />
Changed type of partition to 'BIOS boot partition'<br />
<br />
Command (? for help): n<br />
Partition number (3-128, default 3): (Use default)<br />
First sector (...) or ...: (Use default)<br />
Last sector (...) or (...): (Use default<br />
Current type is 'Linux/Windows data'<br />
Hex code or GUID (L to show codes, Enter = 0700): (ENTER)<br />
Changed type of partition to 'Linux/Windows data'<br />
<br />
Command (? for help): p<br />
</pre><br />
<br />
will now show you a disk partitioning like that one:<br />
[[Image:fqi-018.png|center]]<br />
now write the table to your disk with <tt>w</tt>;<br />
<br />
<pre><br />
Command (? for help): w<br />
<br />
Final checks complete. About to write GPT data. THIS WILL OVERWRITE EXISTING PARTITIONS!!<br />
<br />
Do you want to proceed, possibly destroying your data? (Y/N): Y<br />
OK; writing new GUID partition table (GPT).<br />
The operation has completed successfully.<br />
</pre><br />
<br />
Now go to the Cryptocontainer setup.<br />
<br />
=== Cryptocontainer ===<br />
<br />
Setting up the cryptocontainer for our encrypted system is in both cases nearly identically, but for the easier showing effect we will give both examples in a seperate subsection.<br />
<br />
==== MBR ====<br />
<br />
First we will prepare the HDD for being encrypted, if you use [http://www.sysresccd.org/ SystemRescueCd] in version 2.0.1 or higher just execute the following commands:<br />
<br />
{{fancynote|If you want to see progress of dd than you have to open another terminal and execute: <tt>kill -s USR1 `pidof dd`</tt>}}<br />
<br />
<pre><br />
# dd if=/dev/zero of=/dev/sda2 bs=100M<br />
# dd if=/dev/urandom of=/dev/sda2 bs=100M<br />
</pre><br />
<br />
This part is optional but for security reason we advise you to do so if you like to have a secure encrypted disk. This part takes a lot of time, let your Computer run and get out to sleep and work, as it might take a day or two depending on your HDD size. :)<br />
<br />
You should also be aware that you will get a hint about reaching the end of your HDD. That's intended and desired in this case so that the command can work without knowing your disk-size.<br />
<br />
If you ran the above commands you should see an output similar to the one shown in the screenshot:<br />
[[Image:fqi-019.png|center]]<br />
<br />
Next we need to encrypt our HDD, that will be done with the following commands:<br />
<br />
<pre><br />
# cryptsetup -c aes-xts-plain luksFormat /dev/sda2<br />
<br />
WARNING!<br />
========<br />
This will overwrite data on /dev/sda2 irrevocably.<br />
<br />
Are you sure (Type uppercase yes): YES<br />
Enter LUKS passphrase: (Your paranoid passphrase)<br />
Verify passphrase: (Your paranoid passphrase again)<br />
</pre><br />
Then we need to mount our HDD:<br />
<pre><br />
# cryptsetup luksOpen /dev/sda2 dmcrypt_root<br />
Enter passphrase for /dev/sda2: (your paranoid passphrase)<br />
</pre><br />
<br />
Next we will creat the logical volumes for our setup, so have a look at the subsection about logical volumes.<br />
<br />
==== GPT/GUID ====<br />
<br />
This section is nearly the same as above, so if you read the text in one you will reread the MBR section again only with the GPT enabled stuff.<br />
<br />
{{fancynote|If you want to see progress of dd than you have to open another terminal and execute: <tt>kill -s USR1 `pidof dd`</tt>}}<br />
<br />
First we will prepare the HDD for being encrypted, if you use [http://www.sysresccd.org/ SystemRescueCd] in version 2.0.1 or higher just execute the following commands:<br />
<br />
<pre><br />
# dd if=/dev/zero of=/dev/sda3 bs=100M<br />
# dd if=/dev/urandom of=/dev/sda3 bs=100M<br />
</pre><br />
<br />
This part is optional but for security reason we advise you to do so if you like to have a secure encrypted disk. This part takes a lot of time, let your Computer run and get out to sleep and work, as it might take a day or two depending on your HDD size. :)<br />
<br />
You should also be aware that you will get a hint about reaching the end of your HDD. That's intended and desired in this case so that the command can work without knowing your disk-size.<br />
<br />
If you ran the above commands you should see an output similiar to the one shown in the screenshot:<br />
[[Image:fqi-020.png|center]]<br />
<br />
Next we need to encrypt our HDD, that will be done with the following commands:<br />
<br />
<pre><br />
# cryptsetup -c aes-xts-plain luksFormat /dev/sda3<br />
<br />
WARNING!<br />
========<br />
This will overwrite data on /dev/sda3 irrevocably.<br />
<br />
Are you sure? (Type uppercase yes): YES<br />
Enter LUKS passphrase: (your paranoid passphrase)<br />
Verify passphrase: (your paranoid passphrase again)<br />
</pre><br />
Then we need to mount our HDD:<br />
<pre><br />
# cryptsetup luksOpen /dev/sda3 dmcrypt_root<br />
Enter passphrase for /dev/sda3: (your paranoid passphrase)<br />
</pre><br />
<br />
next we will creat the logical volumes for our setup, so have a look at the following subsection.<br />
<br />
==== logical volumes ====<br />
<br />
Feel free to adjust your sizes here, we will follow our given advices above for that. First we need to creat the the physical volume, then the volume group and at last the logical volumes. doing so is really easy, just do the following for if you want to follow our advices above:<br />
<br />
<pre><br />
# pvcreate /dev/mapper/dmcrypt_root<br />
Physical volume "/dev/mapper/dmcrypt_root" successfully created<br />
# vgcreate vg /dev/mapper/dmcrypt_root<br />
Volume group "vg" successfully created<br />
# lvcreate -L20G -nroot vg<br />
Logical volume "root" created<br />
# lvcreate -L2G -nswap vg<br />
Logical volume "swap" created<br />
# lvcreate -L10G -n portage vg<br />
Logical volume "portage" created<br />
# lvcreate -l 100%FREE -nhome vg<br />
Logical volume "home" created<br />
</pre><br />
<br />
=== filesystem creation ===<br />
<br />
Now that we have created our partitioning scheme, we can go on to create the filesystems needed for our partitions. Here differences only occur between the unencrypted setups. Encrypted volumes are handled the same way, no matter whether MBR and GPT, so there is no need to split them up in two seperate parts:<br />
<br />
==== MBR unencrypted ====<br />
<br />
For the unencrypted partions in the MBR setup just use the following regarding to our above given adives, you may feel free to change some parts of it if you like:<br />
<br />
<pre><br />
# mkfs.ext2 /dev/sda1<br />
# mkswap /dev/sda2<br />
# mkfs.ext4 /dev/sda3<br />
# mkfs.ext4 /dev/sda5<br />
# mkfs.xfs /dev/sda6<br />
<br />
</pre><br />
<br />
That was all for having your filesystem created. now go to the System Setup.<br />
<br />
==== GPT unencrypted ====<br />
<br />
Now let us create the filesystem for our GUID partition table. It is as easy as above, just see the difference in the jump of partition name:<br />
<br />
<pre><br />
# mkfs.ext2 /dev/sda1<br />
# mkswap /dev/sda3<br />
# mkfs.ext4 /dev/sda4<br />
# mkfs.ext4 /dev/sda5<br />
# mkfs.xfs /dev/sda6<br />
</pre><br />
<br />
Next step is to mount our partitons, for that go to the System Setup.<br />
<br />
==== MBR/GPT encrypted ====<br />
<br />
If you choose to encrypt your HDD, you will in both cases follow the next steps to setup your filesystems:<br />
<br />
<pre><br />
# mkfs.ext2 /dev/sda1<br />
# mkswap /dev/mapper/vg-swap<br />
# mkfs.ext4 /dev/mapper/vg-root<br />
# mkfs.ext4 /dev/mapper/vg-portage<br />
# mkfs.xfs /dev/mapper/vg-home<br />
</pre><br />
<br />
So far we prepared the disk and will now mount our partitions.<br />
<br />
== System Setup ==<br />
<br />
=== Mounting filesystem ===<br />
<br />
As we need to have a mountpoint for our system, we now create it with<br />
<pre><br />
# install -d /mnt/funtoo<br />
</pre><br />
<br />
{{fancynote|The in the following used <tt>install -d</tt> command just creats all the needed folders for later mountpoints for us. If you like you can control it by using <tt>ls /mnt/funtoo</tt> after the <tt>install -d</tt> part. Now you are ready to install your base system, read on in Downloading the System.}}<br />
<br />
==== MBR unencrypted ====<br />
<br />
Now mount your system partitions like that if you used our above advice:<br />
<br />
<pre><br />
# swapon /dev/sda2<br />
# mount /dev/sda3 /mnt/funtoo<br />
# install -d /mnt/funtoo/{boot,usr/portage,home}<br />
# mount /dev/sda1 /mnt/funtoo/boot<br />
# mount /dev/sda5 /mnt/funtoo/usr/portage<br />
# mount /dev/sda6 /mnt/funtoo/home<br />
</pre><br />
<br />
{{fancynote|The <tt>install -d</tt> command just creats all the needed folders for later mountpoints for us. If you like you can control it by using <tt>ls /mnt/funtoo</tt> after the <tt>install -d</tt> part. Now you are ready to install your base system, read on in Downloading the System.}}<br />
<br />
==== GPT unencrypted ====<br />
<br />
That part is really similiar to the unencrypted MBR, but see for yourself:<br />
<br />
<pre><br />
# swapon /dev/sda3<br />
# mount /dev/sda4 /mnt/funtoo<br />
# install -d /mnt/funtoo/{boot,usr/portage,home}<br />
# mount /dev/sda1 /mnt/funtoo/boot<br />
# mount /dev/sda5 /mnt/funtoo/usr/portage<br />
# mount /dev/sda6 /mnt/funtoo/home<br />
</pre><br />
<br />
==== MBR/GPT encrypted ====<br />
<br />
Now mount the system so we can setup the system in the next step.<br />
<br />
<pre><br />
# swapon /dev/mapper/vg-swap<br />
# mount /dev/mapper/vg-root /mnt/funtoo<br />
# install -d /mnt/funtoo/{boot,usr/portage,home}<br />
# mount /dev/sda1 /mnt/funtoo/boot<br />
# mount /dev/mapper/vg-portage /mnt/funtoo/usr/portage<br />
# mount /dev/mapper/vg-home /mnt/funtoo/home<br />
</pre><br />
<br />
=== Downloading the System ===<br />
<br />
The next step is to download the base system and portage tree and set up both. Here a list of packages we have:<br />
<br />
{| cellpadding="4"<br />
|-<br />
! Arch (32/64 bit) !! Processors !! Stable Release !! Current Release<br />
|-<br />
| 64-bit Install Images for PC-compatible processors<br />
|-<br />
| 64 || Generic Intel and Amd 64-bit Processors || [http://ftp.osuosl.org/pub/funtoo/funtoo-stable/x86-64bit/generic_64/ generic_64] || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-64bit/generic_64/ generic_64]<br />
|-<br />
| 64 || Intel Core2 Series and most Atom Processors || [http://ftp.osuosl.org/pub/funtoo/funtoo-stable/x86-64bit/core2_64/ core2_64] || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-64bit/core2_64/ core2_64]<br />
|-<br />
| 64 || Intel Core i3, i5, i7 || N/A || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-64bit/corei7/ corei7]<br />
|-<br />
| 64 || AMD Athlon 64 and Opteron Processors (K8 Family or higher) || [http://ftp.osuosl.org/pub/funtoo/funtoo-stable/x86-64bit/amd64-k8/ amd64-k8] || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-64bit/amd64-k8/ amd64-k8]<br />
|-<br />
| 32-bit Install Images for PC-compatible processors<br />
|-<br />
| 32 || Intel Core2 Series, i3, i5, i7 and Atom Processors || N/A || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-32bit/core2_32/ core2_32]<br />
|-<br />
| 32 || AMD Athlon64 and Opteron Processors (K8 Family or higher)| N/A || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-32bit/amd64-k8_32/ amd64-k8_32]<br />
|-<br />
| 32 || Generic x86 processors (intel80486+) || [http://ftp.osuosl.org/pub/funtoo/funtoo-stable/x86-32bit/i486/ i486] || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-32bit/i486/ i486]<br />
|-<br />
| 32 || Generic P6-class (Pentium Pro/Pentium II compatible) || [http://ftp.osuosl.org/pub/funtoo/funtoo-stable/x86-32bit/i686/ i686] || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-32bit/i686/ i686]<br />
|-<br />
| 32 || Athlon XP and Athlon 64-based CPU (32-bit mode) || N/A || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-32bit/athlon-xp/ athlon-xp]<br />
|-<br />
| 32 || Intel Pentium 4 Processors || N/A || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-32bit/pentium4/ pentium4]<br />
|-<br />
| OpenVZ Templates for PC-Compatible Systems<br />
|-<br />
| 32 || 32-bit OpenVZ Images || [http://ftp.osuosl.org/pub/funtoo/funtoo-stable/openvz/x86-32bit OpenVZ x86-32bit] || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/openvz/x86-32bit OpenVZ x86-64bit]<br />
|-<br />
| 64 || 64-bit OpenVZ Images || [http://ftp.osuosl.org/pub/funtoo/funtoo-stable/openvz/x86-64bit OpenVZ x86-64bit] || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/openvz/x86-64bit OpenVZ x86-64bit]<br />
|-<br />
| SPARC processor Images<br />
|-<br />
| 32/64 || Generic SPARC v9 processors (use this one if the ultrasparc I/II stages are inadequate for you) || N/A || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/sparc-64bit/sparc_v9/ sparc_v9]<br />
|-<br />
| 32/64 || UltraSPARC I & UltraSPARC II series (choose this one in doubt) || N/A || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/sparc-64bit/ultrasparc/ ultrasparc]<br />
|-<br />
| 32/64 || UltraSPARC III and UltraSPARC IV series || N/A || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/sparc-64bit/ultrasparc3/ ultrasparc3]<br />
|-<br />
| 32/64 || Niagara (UltraSPARC T1) || N/A || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/sparc-64bit/niagara/ niagara]<br />
|-<br />
| 32/64 || Niagara 2 (UltraSPARC T2/ UltraSPARC T2+) || N/A || [http://ftp.osuosl.org/pub/funtoo/funtoo-current/sparc-64bit/niagara2/ niagara2]<br />
|}<br />
<br />
If you found your desired image above, just change to <tt>/mnt/funtoo</tt> and download the stage3 and portage-tree images.<br />
<br />
<pre><br />
# cd /mnt/funtoo<br />
# elinks http://ftp.osuosl.org/pub/funtoo/funtoo-current/x86-64bit/generic_64/<br />
</pre><br />
<br />
[[Image:fqi-021.png|center]]<br />
this shows you the site presented and by going down with the arrow keys to stage3-latest.tar.xz until it is highlighted you can download it by pressing <tt>D</tt>. Then move up in the directory structure (<tt>..</tt>-link) and go to the snapshot directory or quit elinks after downloading finished and start it again with like that<br />
<br />
<pre><br />
# elinks http://ftp.osuosl.org/pub/funtoo/funtoo-current/snapshots/<br />
</pre><br />
<br />
here you will now download the portage tree (portage-latest.tar.xz). The Download dialog will look in both cases like that:(Note outdated image, 'stage3-current.tar.xz' is now 'stage3-latest.tar.xz')<br />
[[Image:fqi-022.png|center]]<br />
<br />
When both downloads have finished quit elinks by typing <tt>q</tt>. The downloaded files should be located in <tt>/mnt/funtoo</tt>. Now that this is done, let us move on to installing your base system.<br />
<br />
=== Installing the base system ===<br />
<br />
Now that we have the base system and the portage tree downloaded, we will install it. First install the stage3. it is really easy.<br />
<br />
<pre><br />
# tar xfvpJ stage3-latest.tar.xz<br />
</pre><br />
<br />
That will output many lines, and return a command-prompt line when finished.<br />
<br />
Next we need to extract the funtoo-portage-tree. For that we need to change to the future <tt>/usr</tt> dir, and extract there the portage.<br />
<br />
<pre><br />
# cd /mnt/funtoo/usr<br />
# tar xfvpJ ../portage-latest.tar.xz<br />
</pre><br />
<br />
This time there will be no output, but when the unpacking has finished, the result will be an empty command prompt. We still need to checkout the tree, but this can only be done from inside the chroot environment.<br />
<br />
At this state of the setup we have setup most of our system. If you choose to use the fast genkernel method later on, the hardest part is already done. If you choose to manually configure the kernel, you still have quite a bit work ahead of you.<br />
<br />
=== Chrooting ===<br />
<br />
Before we can finally chroot into your system, there are a couple of things that need to be done before, like mounting the proc and dev filesystem.<br />
<br />
<pre><br />
# mount -t proc none /mnt/funtoo/proc<br />
# mount --bind /dev /mnt/funtoo/dev<br />
</pre><br />
<br />
to have a working network inside of your chrooted system later you need to copy the <tt>resolv.conf</tt> file too:<br />
<br />
<pre><br />
# cp -L /etc/resolv.conf /mnt/funtoo/etc<br />
</pre><br />
<br />
Now we can chroot into your Funtoo system<br />
<br />
<pre><br />
# env -i HOME=/root TERM=$TERM SHELL=/bin/bash <br />
# chroot /mnt/funtoo /bin/bash<br />
</pre><br />
<br />
Now that we are inside your new system, you'll need to update your environment, use the following commands to do so:<br />
<br />
<pre><br />
# source /etc/profile<br />
# env-update<br />
</pre><br />
<br />
We also recommend you to change the default command prompt while you are inside the chroot, as it will avoid confusions if you have to change terminals for anything. To do so use the following command:<br />
<br />
<pre><br />
# export PS1="(chroot) $PS1"<br />
</pre><br />
<br />
Congratulations! You are now inside your new Funtoo Linux operating system.<br />
<br />
==== Updating the Portage tree ====<br />
<br />
As we have installed the Portage snapshot during the installation, we now need to "activate" the Portage tree by selecting the <tt>funtoo.org</tt> branch.<br />
<br />
By default, the master branch is enabled, which saves space when storing the tree inside a tarball, but that branch only contains a README with the same instructions as the ones given here.<br />
<br />
To activate the funtoo.org branch, do the following: <br />
<br />
<pre><br />
# cd /usr/portage/<br />
# git checkout funtoo.org<br />
<br />
Checking out files: 100% (85007/85007), done.<br />
Switched to branch "funtoo.org"<br />
</pre><br />
<br />
You'll now be able to see thousands of glorious ebuilds inside your Portage tree :) <br />
<br />
After activating the funtoo.org branch you need to sync your tree to the newest glorious funtoo ebuilds. Run:<br />
<br />
<pre><br />
# emerge --sync<br />
</pre><br />
<br />
This will now update the tree to the current state, which normally changes twice a day.<br />
<br />
==== Setting the default options ====<br />
<br />
Like any other Linux Distribution, Funtoo Linux has it's share of configuration files, that need to be edited by you. The following table gives you an overview of these files and for what they are there:<br />
<br />
{| cellpadding="4"<br />
|-<br />
! File !! Description<br />
|-<br />
| /etc/make.conf || Parameters used by <tt>gcc</tt> compiler<br />
|-<br />
| /etc/fstab || Device to mountpoint definitions<br />
|-<br />
| /etc/conf.d/hostname || Setting your hostname<br />
|-<br />
| /etc/rc.conf || OpenRC configuration file.<br />
|-<br />
| /etc/conf.d/keymaps || Keyboard configuration file.<br />
|-<br />
| /etc/conf.d/hwclock || System clock to use.<br />
|-<br />
| /etc/conf.d/consolefont || Fonts to be used in console display. This doesn't affect GUI terminal emulators.<br />
|-<br />
| /etc/env.d/99editor || Default editor.<br />
|-<br />
| /etc/localtime || Your timezone.<br />
|-<br />
| /etc/make.profile || Type of installation (desktop, server...).<br />
|-<br />
| /etc/conf.d/modules || Kernel modules to load<br />
|-<br />
| /etc/locale.gen || Localization.<br />
|-<br />
| /etc/env.d/02locales || Localization for old programs.<br />
|}<br />
<br />
If you are installing an english Funtoo, you are lucky, as you won't need to edit many of the files above, if not, don't be afraid, we will walk through the configuration of these files in the following together.<br />
<br />
First we will get a mighty editor with great syntax highlighting as it is not provided in our main system we will merge it, if you don't like to please replace in the following edit sections the part <tt>vim <path/filename></tt> with your <tt>editor <path/filename></tt> where editor is replaced by <tt>vi</tt> or <tt>nano -w</tt>.<br />
<br />
First let us get <tt>vim</tt> so we have the perfect highlighting from it for our personal help.<br />
<br />
<pre><br />
# emerge -avt vim<br />
</pre><br />
<br />
that will result in an output like that<br />
[[Image:fqi-023.png|center]]<br />
just accept the output with <tt>Enter</tt> and it will install vim for you, while you wait for vim to get emerged, here are the some basic usage instructions for ViM. ViM has a multimode interface, if you start it, it is in <tt>Command mode</tt>, the second mode is the <tt>Edit mode</tt> which you will enter from the <tt>Command mode</tt> by pressing <tt>i</tt>, to go back into the <tt>Command mode</tt> press <tt>ESC</tt>. After you have edited a config file, you want to save it, for that you have to be in <tt>Command mode</tt> and then simple press <tt>:w<ENTER></tt>, it will save the file, a closing is done with <tt>:q<ENTER></tt>, if you changed content in the file that shouldn't be saved use <tt>:q!</tt> and for saving and closing the file <tt>:wq</tt>, thats all, the visual mode is in that context not very useful, so we leave it out. Now that you know the basic usage of ViM and it has emerged we will now start configuring the config files.<br />
<br />
===== /etc/make.conf =====<br />
<br />
First open that file<br />
<br />
<pre><br />
# vim /etc/make.conf <br />
</pre><br />
<br />
This file contains something similar to the following. You may or may not have a CFLAGS variable set already depending on what stage 3 tarball you used: <br />
<br />
<pre><br />
ACCEPT_KEYWORDS="~amd64"<br />
SYNC="git://github.com/funtoo/portage-mini-2010.git"<br />
CHOST="x86_64-pc-linux-gnu"<br />
</pre><br />
<br />
{{fancynote|In ACCEPT_KEYWORDS, ~amd64 is used for current 64-bit builds; There is no tilde for the stable build. The default value is (~)x86 for 32 bit. The ACCEPT_KEYWORDS line should not be altered. Keep it as supplied in the default file. It is also important to not change the CHOST line.}}<br />
<br />
====== CFLAGS ======<br />
<br />
If you're only building packages for your host processor and not any others then the recommended CFLAGS setting is: <br />
<br />
<pre><br />
CFLAGS="-march=native -O2 -pipe"<br />
</pre><br />
<br />
Since [http://gcc.gnu.org/gcc-4.2/changes.html gcc-4.2], -mtune=native and -march=native will produce code optimized for the host processor. -mtune=native has no effect if GCC does not recognize the processor. More information can be found in the [http://gcc.gnu.org/onlinedocs/gcc/i386-and-x86_002d64-Options.html#i386-and-x86_002d64-Options GCC online docs]. <br />
<br />
{{fancynote|The value <tt>native</tt> selects the best architecture option for the host processor, so this should not be used if you intend to compile packages for a different CPU.}}<br />
<br />
====== CXXFLAGS ======<br />
<br />
Normally, this flag is set to the same values as CFLAGS: <br />
<br />
<pre><br />
CXXFLAGS="${CFLAGS}"<br />
</pre><br />
<br />
====== MAKEOPTS ======<br />
<br />
With <tt>MAKEOPTS</tt> you define how many parallel compilations should occur when you compile a package. A good choice is the number of CPUs (or CPU threads) in your system plus one (Note: this guideline isn't always perfect). If for example you have a dual core processor without hyperthreading, then you would set MAKEOPTS to 3: <br />
<br />
<pre><br />
MAKEOPTS="-j3" <br />
</pre><br />
<br />
If you're unsure of how many processors/threads you have, then use /proc/cpuinfo to help you. <br />
<br />
<pre><br />
# cat /proc/cpuinfo | grep "model name" | wc -l<br />
16<br />
</pre><br />
<br />
Set MAKEOPTS to this number plus one: <br />
<br />
<pre><br />
MAKEOPTS="-j17"<br />
</pre><br />
<br />
====== USE ======<br />
<br />
<tt>USE</tt> flags define what functionality is enabled when ebuilds are built. It is not recommended to add a lot of them during installation. You should wait until you have a working, bootable system to do so. The following USE flags are a recommended starting point for new systems: <br />
<br />
<pre><br />
USE="-gnome -gtk -kde -kdeenablefinal -ldap nls -qt3 -qt3support -qt4 userlocales"<br />
</pre><br />
<br />
The minus(-) sign tells gcc not to use the flag when compiling. <tt>USE</tt> flags <tt>gnome</tt>, <tt>gtk</tt>, <tt>kde</tt>, <tt>qt3</tt>, <tt>qt3support</tt>, and <tt>qt4</tt> will be set later if you install a desktop envrionment. <br />
<br />
A Funtoo guide to <tt>USE</tt> flags will be available in the future. For now, you can find out more information about USE flags in the [http://www.gentoo.org/doc/en/handbook/handbook-amd64.xml?part=2&chap=2 Gentoo Handbook]. <br />
<br />
====== GENTOO_MIRRORS ======<br />
<br />
This is the mirror from which emerge gets a lot of the source files. It is usually not necessary to set this flag. In the following ewxample, the Waterloo University is used (a fast and reliable Canadian mirror). Please set this variable to a mirror local to your country. <br />
<br />
<pre><br />
GENTOO_MIRRORS="ftp://mirror.csclub.uwaterloo.ca/gentoo-distfiles/ http://distfiles.gentoo.org"<br />
</pre><br />
<br />
====== LINGUAS ======<br />
<br />
<tt>LINGUAS</tt> tells Portage which local language to compile the system and applications in (those who use LINGUAS variable like OpenOffice). It is not usually necessary to set this if you use English. Otherwise, if you want another language, replace fr (French) for the code of your mother language, e.g. de for German. <br />
<br />
<pre><br />
LINGUAS="fr"<br />
</pre><br />
<br />
or for multiple language support you might also use:<br />
<br />
<pre><br />
LINGUAS="en de fr"<br />
</pre><br />
<br />
====== /etc/make.conf example ======<br />
<br />
An example of a <tt>/etc/make.conf</tt> file could look like that:<br />
<br />
<pre><br />
# These settings were set by the metro build script that automatically built this stage.<br />
# Please consult /etc/make.conf.example for a more detailed example.<br />
<br />
ACCEPT_KEYWORDS="x86"<br />
FEATURES="mini-manifest"<br />
SYNC="git://github.com/funtoo/portage-mini-2010.git"<br />
CHOST="i686-pc-linux-gnu"<br />
CFLAGS="-march=i686 -O2 -pipe"<br />
CXXFLAGS="${CFLAGS}"<br />
MAKEOPTS="-j2"<br />
USE="-gnome -gtk -kde -kdeenablefinal -ldap nls -qt3 -qt3support -qt4 userlocales"<br />
GENTOO_MIRRORS="ftp://mirror.csclub.uwaterloo.ca/gentoo-distfiles/ http://distfiles.gentoo.org"<br />
LINGUAS="fr"<br />
INPUT_DEVICES="evdev synaptics"<br />
VIDEO_CARDS="vesa radeon"<br />
PORT_LOGDIR="/var/log/portage"<br />
PORTAGE_ELOG_CLASSES="log warn error info"<br />
PORTAGE_ELOG_SYSTEM="echo:log,warn save:log,warn,error,info syslog:error"<br />
</pre><br />
<br />
===== /etc/fstab =====<br />
<br />
This file is used for the configuration of the mountpoints for the system. As we have two different setups described above, here are the two examples for these.<br />
<br />
<pre><br />
# vim /etc/fstab<br />
</pre><br />
<br />
====== unencrypted MBR ======<br />
<br />
<pre><br />
# The root filesystem should have a pass number of either 0 or 1.<br />
# All other filesystems should have a pass number of 0 or greater than 1.<br />
#<br />
# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.<br />
#<br />
# See the manpage fstab(5) for more information.<br />
#<br />
# <fs> <mountpoint> <type> <opts> <dump/pass><br />
<br />
/dev/sda1 /boot ext2 noauto,noatime 1 2<br />
/dev/sda2 none swap sw 0 0<br />
/dev/sda3 / ext4 noatime 0 1<br />
/dev/sda5 /usr/portage ext4 noatime 0 1<br />
/dev/sda6 /home xfs defaults,noatime 0 1<br />
#/dev/cdrom /mnt/cdrom auto noauto,ro 0 0<br />
none /dev/shm tmpfs nodev,nosuid,noexec 0 0<br />
</pre><br />
<br />
====== unencrypted GPT ======<br />
<br />
<pre><br />
# The root filesystem should have a pass number of either 0 or 1.<br />
# All other filesystems should have a pass number of 0 or greater than 1.<br />
#<br />
# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.<br />
#<br />
# See the manpage fstab(5) for more information.<br />
#<br />
# <fs> <mountpoint> <type> <opts> <dump/pass><br />
<br />
/dev/sda1 /boot ext2 noauto,noatime 1 2<br />
/dev/sda3 none swap sw 0 0<br />
/dev/sda4 / ext4 noatime 0 1<br />
/dev/sda5 /usr/portage ext4 noatime 0 1<br />
/dev/sda6 /home xfs defaults,noatime 0 1<br />
#/dev/cdrom /mnt/cdrom auto noauto,ro 0 0<br />
none /dev/shm tmpfs nodev,nosuid,noexec 0 0<br />
</pre><br />
<br />
====== encrypted ======<br />
<br />
That time the setup is the same for both MBR and GPT partition layout:<br />
<br />
<pre><br />
# The root filesystem should have a pass number of either 0 or 1.<br />
# All other filesystems should have a pass number of 0 or greater than 1.<br />
#<br />
# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.<br />
#<br />
# See the manpage fstab(5) for more information.<br />
#<br />
# <fs> <mountpoint> <type> <opts> <dump/pass><br />
<br />
/dev/sda1 /boot ext2 noauto,noatime 1 2<br />
/dev/mapper/vg-swap none swap sw 0 0<br />
/dev/mapper/vg-root / ext4 noatime 0 1<br />
/dev/mapper/vg-portage /usr/portage ext4 noatime 0 1<br />
/dev/mapper/vg-home /home xfs defaults,noatime 0 1<br />
#/dev/cdrom /mnt/cdrom auto noauto,ro 0 0<br />
none /dev/shm tmpfs nodev,nosuid,noexec 0 0<br />
</pre><br />
<br />
===== /etc/conf.d/hostname =====<br />
<br />
Here you will set up your hostname for the PC. So choose a name for your PC and set it up in that file:<br />
<br />
<pre><br />
# vim /etc/conf.d/hostname<br />
<br />
# Set to the hostname of this machine<br />
hostname="<your-hostname>"<br />
</pre><br />
<br />
===== /etc/rc.conf =====<br />
<br />
You may use this file as-is. However, it is a good idea to set <tt>rc_logger</tt> to yes. That will create a log file which is handy when problems are encountered with OpenRC scripts. Very helpful for fixing things. <br />
<br />
Another good option here is the <tt>rc_interactive</tt> flag, if you are playing around with a new graphical display manager or aren't that used with the upgrade procedure of the graphical environement. if <tt>rc_interactive</tt> is set to yes, you will be able to interactively manipulate the boot process, what means you can decide what you want to start or not, like the graphical environment for example.<br />
<br />
Other options have really good explainations inside of the <tt>/etc/rc.conf</tt> file.<br />
<br />
===== /etc/conf.d/keymaps =====<br />
<br />
You do not have to alter that file if you have a US English keyboard. Otherwise, edit file and set <tt>keymap</tt> to your keyboard model. For example, cf for French Canadian keyboard, fr for French Azerty and de for German Qwertz.<br />
<br />
===== /etc/conf.d/hwclock =====<br />
<br />
If you dual boot with Windows, you'll need to edit this file and change clock to local. Otherwise you should not normally need to edit this file. <br />
<br />
You should define your timezone in <tt>/etc/timezone</tt>:<br />
<br />
<pre><br />
# vim /etc/timezone<br />
Europe/Berlin<br />
</pre><br />
<br />
anoteher value might be<br />
<br />
<pre><br />
America/Denver<br />
</pre><br />
<br />
so you might get an idea how it should look like, if not have a look at <tt>/usr/share/zoneinfo</tt> it will give you the entry after the path like <tt>/usr/share/zoneinfo/<Content of /etc/timezone></tt> like for Germany you will find a path in there that looks like <tt>/usr/share/zoneinfo/Europe/Berlin</tt>.<br />
<br />
===== /etc/conf.d/consolefont =====<br />
<br />
There is nothing to edit in that file.<br />
<br />
===== /etc/env.d/99editor =====<br />
<br />
Create and edit that file to instruct your system about the default editor it should use. <br />
<br />
<pre><br />
vim /etc/env.d/99editor<br />
</pre><br />
<br />
Type in : <br />
<br />
<pre><br />
EDITOR="/usr/bin/vim"<br />
</pre><br />
<br />
Replace the above line with the editor of your choice, if you had been happy so far with ViM just paste it in as is, if not use <tt>nano</tt>, <tt>vi</tt> or what else you like.<br />
<br />
===== /etc/localtime =====<br />
<br />
If you came here from Gentoo, it was advised to copy the file from the zoneinfo dir to here. We advise you to create a symbolic link from the zoneinfo dir to <tt>/etc/localtime</tt>. As in the hwclock section above, we need your timezone parted in LAND/TOWN like for Germany Europe/Berlin. Now, create the symbolic link. More info about it can be found in the <tt>/usr/share/zoneinfo</tt> dir.<br />
<br />
<pre><br />
ln -sf /usr/share/zoneinfo/Europe/Berlin /etc/localtime<br />
</pre><br />
<br />
That command sets the timezone to Central European Time.<br />
<br />
===== /etc/make.profile =====<br />
<br />
Here you select which type of environment you want the gcc-compiler to take into account. That will dress up an environment with a list of pre-defined USE flags.<br />
<br />
To list all available profiles run:<br />
<br />
<pre><br />
eselect profile list<br />
</pre><br />
<br />
The output will look like that:<br />
<br />
<pre><br />
[1] default/linux/x86/2008.0 *<br />
[2] default/linux/x86/2008.0/desktop<br />
[3] default/linux/x86/2008.0/developer<br />
[4] default/linux/x86/2008.0/server<br />
</pre><br />
<br />
Profile defaults to 2008.0 (See the star). To create a profile for DE (Desktop Environment) run:<br />
<br />
<pre><br />
eselect profile set 2<br />
</pre><br />
<br />
{{fancywarning|Funtoo only supports the 2008.0 profile and the 2008.0 profile children. Use one of these profiles until 'funtoo-1.0' is ready.}}<br />
<br />
===== /etc/conf.d/modules =====<br />
<br />
With Funtoo, OpenRC loads modules from <tt>/etc/conf.d/modules</tt> using the line:<br />
<br />
<pre><br />
modules_2_6="list of modules"<br />
</pre><br />
<br />
With Funtoo, define module arguments as follows: <br />
<br />
<pre><br />
module_module-name_args_2_6="module arg=value"<br />
</pre><br />
<br />
===== Localization =====<br />
<br />
<tt>/etc/locale.gen</tt> and <tt>/etc/env.d/02locales</tt> are used to support your local language. The last one is required just in case there still are old programs installed.<br />
<br />
You do not need to amend anything if your locales are US English. The following are examples for German. You can look in /usr/share/i18n/SUPPORTED for the default list of supported combinations or look in /usr/share/i18n/locales to determine values to use. <br />
<br />
<pre><br />
# vim /etc/locale.gen <br />
</pre><br />
<br />
Put this value into the file for German support:<br />
<br />
<pre><br />
de_DE.UTF-8 UTF-8<br />
</pre><br />
<br />
for a multiple language support it might look like that:<br />
<br />
<pre><br />
de_DE.UTF-8 UTF-8<br />
fr_CA.UTF-8 UTF-8<br />
en_US.UTF-8 UTF-8<br />
</pre><br />
<br />
Edit <tt>/etc/env.d/02locales</tt> according to that layout:<br />
<br />
<pre><br />
# vim /etc/env.d/02locales<br />
</pre><br />
<br />
and put in these lines:<br />
<br />
<pre><br />
LANG="de_DE.UTF-8"<br />
LANGUAGE="de_DE.UTF-8"<br />
</pre><br />
<br />
Finally after we editet all the localization files generate the localized environment:<br />
<br />
<pre><br />
locale-gen && source /etc/profile <br />
</pre><br />
<br />
==== Kernel ====<br />
<br />
Now that you have the base system running, you need to install a kernel. If you decided to use a standard setup with an unencrypted GPT disc layout or the old unencrypted MBR disc layout, a fast solution would be to use the [[Funtoo Quick Install#genkernel|genkernel]] solution. If you used the standard setup with an encrypted GPT disc layout or the old encrypted MBR disc layout, you have to use the [[Funtoo Quick Install#manual kernel|manual kernel]] steps.<br />
<br />
===== choosing a kernel =====<br />
<br />
First, you need to choose a kernel version you would like to install on your system. The following table will give you an overview of which kernels are available and who should use them.<br />
<br />
{| border="0" cellpadding="4"<br />
|-<br />
! Kernel ebuild !! Description !! masked !! Prefered Users !! eselect kernel set<br />
|-<br />
! sys-kernel/* <br />
! <br />
!<br />
!<br />
! generates symlink<br />
|-<br />
| cell-sources<br />
| Full sources including the cell/ps3 patchset for the 2.6 kernel tree<br />
| <span style="color:red">[ Masked ]</span><br />
|<br />
| <span style="color:orange">unsure</span><br />
|-<br />
| ck-sources<br />
| Con Kolivas' high performance patchset + Gentoo patchset sources<br />
| <br />
|<br />
| <span style="color:orange">unsure</span><br />
|-<br />
| debian-sources<br />
| Debian Sources - with optional OpenVZ support<br />
| <br />
|<br />
| <span style="color:red">NO</span><br />
|-<br />
| gentoo-sources<br />
| Full sources including the Gentoo patchset for the 2.6 kernel tree<br />
| <br />
| <span style="color:green">default for most users</span><br />
| <span style="color:green">YES</span><br />
|-<br />
| git-sources<br />
| The very latest -git version of the Linux kernel<br />
| <br />
| for the versed user<br />
| <span style="color:green">YES</span><br />
|-<br />
| hardened-sources<br />
| Hardened kernel sources (kernel series 2.6)<br />
| <br />
| <span style="color:red">not supported atm</span><br />
| <span style="color:green">YES</span><br />
|-<br />
| mips-sources<br />
| Linux-Mips GIT sources for MIPS-based machines, dated 20110207<br />
| <span style="color:red">[ Masked ]</span><br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| mm-sources<br />
| Andrew Morton's kernel, mostly fixes for 2.6 vanilla, some vm stuff too<br />
| <br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| openvz-sources<br />
| Full sources including OpenVZ patchset for the 2.6.18 kernel tree<br />
| <br />
| For users that want to build a OpenVZ server<br />
| <span style="color:orange">unsure</span><br />
|-<br />
| pf-sources<br />
| Linux kernel fork with new features, including the -ck patchset (BFS), BFQ, TuxOnIce and LinuxIMQ<br />
| <br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| rhel5-openvz-binaries<br />
| RHEL5 kernel with OpenVZ patchset - initrd and bzImage<br />
| <br />
| <br />
| <span style="color:green">YES</span><br />
|-<br />
| rhel5-openvz-sources<br />
| Full Linux kernel sources - RHEL5 kernel with OpenVZ patchset<br />
| <br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| rhel6-openvz-binaries<br />
| RHEL6 kernel with OpenVZ patchset - initrd and bzImage<br />
| <br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| rhel6-openvz-sources<br />
| Full Linux kernel sources - RHEL5 kernel with OpenVZ patchset<br />
| <br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| sparc-sources<br />
| Full sources for the Gentoo Sparc Linux kernel<br />
| <span style="color:red">[ Masked ]</span><br />
| <br />
| <span style="color:green">YES</span><br />
|-<br />
| sysrescue-std-binaries<br />
| System Rescue CD Full sources for the Linux kernel, including gentoo and sysresccd patches - initrd and bzImage<br />
| <span style="color:red">[ Masked ]</span><br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| sysrescue-std-sources<br />
| System Rescue CD Full sources for the Linux kernel, including gentoo and sysresccd patches.<br />
| <br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| tuxonice-sources<br />
| TuxOnIce + Gentoo patchset sources<br />
| <br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| usermode-sources<br />
| Full sources for the User Mode Linux kernel<br />
| <span style="color:red">[ Masked ]</span><br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| vanilla-sources<br />
| Full sources for the Linux kernel<br />
| <br />
| <br />
| <span style="color:green">YES</span><br />
|-<br />
| vserver-sources<br />
| Full sources including Gentoo and Linux-VServer patchsets for the 2.6 kernel tree.<br />
| <br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| xbox-sources<br />
| Full sources for the Xbox Linux kernel<br />
| <span style="color:red">[ Masked ]</span><br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| xen-sources<br />
| Full sources for a dom0/domU Linux kernel to run under Xen<br />
| <br />
| <br />
| <span style="color:orange">unsure</span><br />
|-<br />
| zen-sources<br />
| The Zen Kernel Sources v2.6<br />
| <br />
| <br />
| <span style="color:orange">unsure</span><br />
|}<br />
<br />
For the next section, we will assume that you selected gentoo-sources for your kernel setup. If not, please replace gentoo-sources in the next section with your selection. If you are unsure, please follow our suggestion to use the gentoo-sources.<br />
<br />
===== genkernel =====<br />
<br />
That part would be fast done in general, we will now guide you through that process. First, we need to install the needed tools for it. So, let's do it!<br />
<br />
<pre><br />
# emerge -avt genkernel gentoo-sources<br />
Calculating dependencies... done!<br />
<br />
These are the packages that would be merged, in reverse order:<br />
<br />
[ebuild N ] sys-kernel/gentoo-sources-2.6.38-r4 USE="-build -deblob -symlink" 134 kB<br />
[ebuild N ] sys-kernel/genkernel-3.4.12.6-r2 USE="-bash-completion (-ibm) (-selinux)" 11,556 kB<br />
<br />
Total: 2 packages (2 new), Size of downloads: 11,690 kB<br />
<br />
Would you like to merge these packages? [Yes/No] <br />
</pre><br />
<br />
After answering the above question with "Yes", it will download and install the packages for you. Next, you need to set the symlink from /usr/src/linux to the /usr/src/linux-version directory. There are two ways to do so. If you have selected a version that is supported by eselect, it would be really simple for you, just do:<br />
<br />
<pre><br />
# eselect kernel list<br />
# eselect kernel set 1<br />
</pre><br />
<br />
The first command should list the kernel you have selected. If that isn't the case, the second command to set this kernel version isn't needed, else the second one sets the symlink automatically for you. As <tt>eselect kernel command</tt> will scan your <tt>/usr/src</tt> directory, it should list every kernel-sources listed above, if that isn't the case, please report the failing to the [http://groups.google.com/group/funtoo-dev funtoo-dev mailing list], [http://forums.funtoo.org Funtoo Forums] or contact us directly in IRC at [irc://irc.freenode.net/funtoo #funtoo]. As a workaround you could use the following steps to make your kernel-sources usable:<br />
<br />
<pre><br />
# cd /usr/src<br />
# rm linux<br />
# ls<br />
linux-sources<br />
# ln -s linux-sources linux<br />
</pre><br />
<br />
where linux-sources is the directory that the <tt>ls</tt> command above showed you.<br />
<br />
When you finished the selection of your kernel you will now bake your first kernel, using the genkernel or fast way. Execute for that the following command:<br />
<br />
<pre><br />
# genkernel --menuconfig all<br />
</pre><br />
<br />
if you have a special config predefined use<br />
<br />
<pre><br />
# genkernel --kernel-config=config-name --menuconfig all<br />
</pre><br />
<br />
else if you have choosen an encrypted setup, use the following command to include all the tools you need for bootup:<br />
<pre><br />
# genkernel --lvm --luks --menuconfig all<br />
</pre><br />
the above used options are doing the following:<br />
<br />
* --kernel-config: use the given name located in the kernel source tree (/usr/src/linux by default is taken unless overridden by --kerndir) <br />
* all: rebuild the kernel image and the initramfs ramdisk image (aside of kernel modules, the ramdisk image contains tools such as BusyBox and some generic startup scripts, depending on options you use on the command line several additional tools like lvm or raid volume management can be incorporated as well).<br />
* --lvm: Includes support for storage using via Logical Volume Management (LVM2) from static binaries, if available to the system. Relevant (static) LVM2 binaries are compiled if they are unavailable. Be sure to install the lvm2 package on your system with emerge lvm2 before enabling this flag.<br />
* --luks: Includes support for Linux Unified Key Setup or LUKS. This will allow you to use a device encrypted by LUKS which contains the root filesystem. On the bootloader, you then set that encrypted device as the value of crypt_root (and real_root shall be the unencrypted device LUKS creates).<br />
* --menuconfig: lets you set options for kernel compile manual<br />
<br />
The --menuoption will present you the following screen:<br />
[[Image:fqi-024.png|center]]<br />
<br />
====== default options for unencrypted/encrypted setup ======<br />
<br />
We advised you above to use a partitioning scheme based on the following file system types:<br />
<br />
* ext2<br />
* swap<br />
* ext4<br />
* xfs<br />
<br />
You now need to activate all of them so you can boot your system later, these options can be found at:<br />
<br />
{{kernelop|title=File systems|desc=<br />
<*> Second extended fs support<br />
<*> The Extended 4 (ext4) filesystem<br />
[*] Ext4 extended attributes (NEW)<br />
[ ] Ext4 POSIX Access Control Lists (NEW)<br />
[ ] Ext4 Security Labels (NEW)<br />
[ ] EXT4 debugging support (NEW)<br />
<*> XFS filesystem support<br />
[ ] XFS Quota support (NEW)<br />
[ ] XFS POSIX ACL support (NEW)<br />
[*] XFS Realtime subvolume support<br />
[ ] XFS Debugging support (EXPERIMENTAL) (NEW)}}<br />
<br />
If you furthermore decided to follow our advice and to use a GPT-Partitioning scheme, which will be your default, you will need to activate it in your kernel by using the following options:<br />
<br />
{{kernelop|title=File systems,Partition Types|desc=<br />
[*] Advanced Partition Selection (PARTITION_ADVANCED)<br />
[*] EFI GUID Partition Support (EFI_PARTITION)}}<br />
<br />
====== additional encrypted options ======<br />
<br />
It is very important to add the following parts in your kernel setup, when you used the above GPT or MBR encrypted setup. Under<br />
{{kernelop|title=General setup|desc=<br />
[*] Initial RAM filesystem and RAM disk (initramfs/initrd) support}}<br />
<br />
and {{kernelop|title=Device Drivers|desc=<br />
[*] Multiple devices driver support<br />
<*> Device Mapper Support<br />
<*> Crypt target support}}<br />
<br />
and finally {{kernelop|title=Cryptographic API|desc=<br />
<*> XTS support (EXPERIMENTAL)<br />
<br />
-*- AES cipher algorithms}}<br />
<br />
Finally exit the menuconfig for your kernel and get a coffee. You have done a good bit of work so far... :)<br />
<br />
===== manual kernel =====<br />
<br />
You can use genkernel to automatically compile your kernel, but this tends to create a bloated kernel, compatible with just about any computer, anyplace, any time.<br />
On the other hand, you can manually configure and compile your kernel, to give you complete control, for the smallest and fastest kernel(s) that you can build for your specific computer.<br />
However, manual kernel configuration is often called by many users, the hardest step in installing Funtoo. But it is also very worth learning how to do it.<br />
Be warned that it make take several reconfigurations, compiles and reboots, until you have a working system. Plus, for the encrypted hdd version, you will have to do a bit more work than above, but if you have gotten this far, you should be able to handle it.<br />
<br />
====== install and config ======<br />
<br />
First you will have to install the kernel image you selected above. In the following we again use the kernel we think might be the default choice of you, gentoo-sources, but you can feel free to replace it with any of the above ones. So now install your kernel-sources:<br />
<br />
<pre><br />
# emerge -avt gentoo-sources<br />
</pre><br />
<br />
After answering the above question with Yes, emerge will download and install the kernel-sources for you. Next you need to set the symlink from /usr/src/linux to the /usr/src/linux-version directory. There are two ways to do so, the default way would be to use the following command sequence:<br />
<br />
<pre><br />
# eselect kernel list<br />
# eselect kernel set 1<br />
</pre><br />
<br />
The first command will list the kernel or kernels for which you have used emerge to install the corresponding source code packages. The character * is used to indicate the currently selected default kernel package. In other words, the command <tt> eselect kernel list </tt> will scan and list directories in your <tt> /usr/src directory </tt>, each named after a different kernel source code. It will then show with a * the directory currently pointed to by the <tt> /usr/src/linux </tt> link.<br />
The second command is not needed, as long as the correct kernel source has been selected. Otherwise, use this command and the number of the corresponding kernel directory, to set your <tt> /usr/src/linux </tt> link.<br />
<br />
If the <tt> eselect kernel </tt> command does not work correctly, please report the failing to the [http://groups.google.com/group/funtoo-dev funtoo-dev mailing list], [http://forums.funtoo.org Funtoo Forums] or contact us directly in IRC at [irc://irc.freenode.net/funtoo #funtoo]. <br />
<br />
As a workaround or for educational purposes, you could use the following equivalent commands. For example, to make gentoo-sources available for compiling your kernel, enter:<br />
<br />
<pre><br />
# cd /usr/src<br />
# rm linux<br />
# ls<br />
gentoo-sources-3.5.4<br />
# ln -s gentoo-sources-3.5.4 linux<br />
</pre><br />
<br />
where gentoo-sources is the directory that the <tt>ls</tt> command above showed you.<br />
<br />
Now you are nearly ready to configure your kernel. First switch to a second terminal with <tt>Alt+F2</tt> and execute <tt>lspci</tt> and copy the output, most importantly the names of the VGA, Ethernet and Network devices currently in your system. Knowing these device names will be needed if you need help for default options at the [http://kmuto.jp/debian/hcl/ Debian GNU/Linux device driver check page]. Some options there aren't in your kernel or may have other names but it is a good source for getting default options help for devices.<br />
[[Image:fqi-025.png|center]]<br />
Now move back to your chrooted system (<tt>Alt+F1</tt>) and start the configure process with<br />
<br />
<pre><br />
# cd /usr/src/linux<br />
# make menuconfig<br />
</pre><br />
<br />
This will present you a screen similar to the following:<br />
[[Image:fqi-024.png|center]]<br />
start setting the options you know about or the ones the page above gave you. You need to at least set the following options:<br />
<br />
Here are some more sources you may like to read for configuring your kernel the old fashioned manual way:<br />
<br />
* [http://kernel-seeds.org/ http://kernel-seeds.org]<br />
* [http://swift.siphos.be/linux_sea/ch07.html http://swift.siphos.be/linux_sea/ch07.html]<br />
* [http://www.gentoo.org/doc/en/kernel-config.xml http://www.gentoo.org/doc/en/kernel-config.xml]<br />
<br />
====== default options for unencrypted/encrypted setup ======<br />
<br />
We advised above to use a partitioning scheme based on the following filesystemtypes:<br />
<br />
* ext2<br />
* swap<br />
* ext4<br />
* xfs<br />
<br />
You now need to activate all of them so you can boot your system later, these options can be fount at:<br />
<br />
{{kernelop|File Systems --->|<*>&nbsp;&nbsp;&nbsp;Second extended fs support<br><*>&nbsp;&nbsp;&nbsp;The Extended 4 (ext4) filesystem<br>[*]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Ext4 extended attributes (NEW)<br>[&nbsp;&nbsp;&nbsp;]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Ext4 POSIX Access Control Lists (NEW)<br>[&nbsp;&nbsp;&nbsp;]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Ext4 Security Labels (NEW)<br>[&nbsp;&nbsp;&nbsp;]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;EXT4 debugging support (NEW)<br><*>&nbsp;&nbsp;&nbsp;XFS filesystem support<br>[&nbsp;&nbsp;&nbsp;]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;XFS Quota support (NEW)<br>[&nbsp;&nbsp;&nbsp;]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;XFS POSIX ACL support (NEW)<br>[*]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;XFS Realtime subvolume support<br>[&nbsp;&nbsp;&nbsp;]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;XFS Debugging support (EXPERIMENTAL) (NEW)}}<br />
<br />
If you furthermore decided to follow our advice and use a GPT-Partitioning scheme, what will be our default, you need to activate it in your kernel by using the following options:<br />
<br />
{{kernelop|File Systems ---> (or Enable the block layer --->)<br>&nbsp;&nbsp;&nbsp;Partition Types --->|[*]&nbsp;&nbsp;&nbsp;Advanced Partition Selection (PARTITION_ADVANCED)<br>[*]&nbsp;&nbsp;&nbsp;EFI GUID Partition Support (EFI_PARTITION)}}<br />
<br />
====== additional encrypted options ======<br />
<br />
It is very important to add the following parts in your kernel setup, when you used the above GPT or MBR encrypted setup. Under<br />
{{kernelop|General setup --->|[*]&nbsp;&nbsp;&nbsp;Initial RAM filesystem and RAM disk (initramfs/initrd) support}}<br />
<br />
and under<br />
{{kernelop<br />
|Device Drivers ---><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[*] Multiple devices driver support<br />
|<*>&nbsp;&nbsp;&nbsp;Device Mapper Support<br><*>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Crypt target support}}<br />
<br />
and finaly under<br />
{{kernelop|-*-&nbsp;&nbsp;&nbsp;Cryptographic API --->|<*>&nbsp;&nbsp;&nbsp;XTS support (EXPERIMENTAL)<br><br>-*-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;AES cipher algorithms}}<br />
<br />
====== building the kernel the manual way ======<br />
<br />
Now that all the options are set exit <tt>menuconfig</tt> and answer the question about saving your config with <tt>YES</tt>. That already was the hardest part, now bake your kernel.<br />
<br />
<pre><br />
# make<br />
# make modules_install<br />
# cp arch/<architecture>/boot/bzImage /boot/bzImage-<versionnumber><br />
</pre><br />
<br />
This code-sequence will need to be explained, the first command <tt>make</tt> will bake your kernel, it will take some time, so feel free to get a coffee. :) if you don't have one available here is one from us |_|). <tt>make modules_install</tt> generates the modules for the kernel and builds them, the third command in the sequence needs to be adjusted by you, if you use a 32bit system replace <architecture> with x86 and for 64bit systems with x86_64, finally replace the <versionnumber>-string with a for you readable and unique versionnumber like <tt>2.6.38-rc7-mykernel-v1</tt> or something like that, then the command copies over your baked kernel to /boot and you are ready to get to the next step....<br />
<br />
==== Bootloader ====<br />
===== boot-update =====<br />
<br />
<tt>boot-update</tt> is the default boot-loader configuration tool in funtoo. You need to install it with<br />
<br />
<pre><br />
# emerge -avt boot-update<br />
</pre><br />
<br />
This will install boot-update and grub2 for you. Next you need to configure it. That is done in <tt>/etc/boot.conf</tt>:<br />
<br />
<pre><br />
# vim /etc/boot.conf<br />
</pre><br />
<br />
/etc/boot.conf will look somewhat like the following:<br />
<br />
<pre><br />
boot {<br />
generate grub<br />
default "Funtoo Linux 64-bit" <br />
timeout 10 <br />
}<br />
<br />
display {<br />
gfxmode 1440x900<br />
#background /boot/<br />
}<br />
<br />
color {<br />
normal cyan/black<br />
highlight black/cyan<br />
}<br />
<br />
default {<br />
scan /boot<br />
kernel bzImage[-v] kernel[-v] vmlinuz[-v]<br />
initrd initramfs[-v]<br />
<br />
# root=auto will cause the parameter <br />
# from your /etc/fstab. rootfstype=<br />
<br />
params video=vesafb root=auto rootfstype=auto<br />
<br />
# an alternate graphics mode can be set<br />
# default is inherited from display:<br />
<br />
# gfxmode 1024x768<br />
}<br />
<br />
"altboot" {<br />
params += init=/bin/bash<br />
}<br />
<br />
"Funtoo Linux 64-bit gpt" {<br />
kernel bzImage[-v]<br />
}<br />
<br />
"Funtoo Linux genkernel" {<br />
kernel kernel[-v]<br />
initrd initramfs[-v]<br />
params += real_root=auto<br />
}<br />
<br />
"Funtoo Linux 64-bit encrypted gpt/mbr manual kernel" {<br />
kernel bzImage[-v]<br />
initrd /initramfs.cpio.gz<br />
params += enc_root=/dev/sda3 lvm luks root=/dev/mapper/vg-root rootfstype=ext4 resume=swap:/dev/mapper/vg-swap quiet<br />
}<br />
</pre><br />
<br />
If you decided to do a manual kernel, with an encrypted HDD, you will need to read the next section after you made the changes to your config. If you decided to use genkernel or a manual kernel with unencrypted HDD, all is OK and it is now safe for you to go to the [[Funtoo Quick Install#setting up grub2|Grub2 setup]].<br />
<br />
====== encrypted disk with manual kernel ======<br />
<br />
As you decided to make an encrypted disk setup with a manual kernel, you need to instal slashbeast's [http://github.com/slashbeast/better-initramfs better-initrmafs]. It is very simple to do. First clone the git-repository. If you aren't confident with git, feel free to have a look at our [[Git Guide]].<br />
<br />
<pre><br />
# install -d /root/.git<br />
# cd /root/.git<br />
# git clone git://github.com/slashbeast/better-initramfs.git<br />
# cd better-initramfs<br />
# git checkout v0.3<br />
# less README.rst<br />
# echo "sys-apps/busybox static" >> /etc/portage/package.use/busybox && echo "sys-fs/cryptsetup static" >> /etc/portage/package.use/cryptsetup && echo "sys-fs/lvm2 static" >> /etc/portage/package.use/lvm2<br />
# emerge -avt busybox cryptsetup lvm2<br />
# make<br />
>>> New better-initramfs is not backward compatible, read ChangeLog file.<br />
<br />
>>> Preparing binary files...<br />
>>> Adding /bin/busybox...<br />
>>> Adding /sbin/cryptsetup...<br />
>>> Adding /sbin/lvm.static...<br />
>>> Building image...<br />
>>> initramfs.cpio.gz is ready.<br />
# cp initramfs.cpio.gz /boot<br />
</pre><br />
<br />
Now you are ready to setup grub2. Just go to the next section.<br />
<br />
======= Updating better-initramfs =======<br />
<br />
As the [http://github.com/slashbeast/better-initramfs better-initrmafs] project isn't controlled at the moment by an ebuild, you will need to take care of updating it by yourself, but it is very easy to do so:<br />
<br />
<pre><br />
# git checkout master<br />
# git pull<br />
# less ChangeLog<br />
# git checkout vx.x<br />
# make<br />
</pre><br />
where x.x is a version announced in the ChangeLog. At the moment the stable is 0.3.<br />
<br />
====== setting up grub2 ======<br />
<br />
This step is easy. It is done with two commands;<br />
<br />
<pre><br />
# grub-install --no-floppy /dev/sda<br />
# boot-update<br />
</pre><br />
<br />
A successful run of boot-update might will look like this:<br />
<br />
<pre><br />
boot-update 1.5.2 / Copyright 2009-2011 Funtoo Technologies<br />
<br />
[use option "-l" for license info, "-h" for help]<br />
<br />
* Generating config for grub...<br />
<br />
DEFAULT > Funtoo Linux 64-bit - bzImage-2.6.39-rc7-git-a2b9c1f<br />
Funtoo Linux 64-bit - bzImage-2.6.39-rc7-git-446cc63<br />
Funtoo Linux 64-bit - bzImage-2.6.39-rc7-git-df8d06a<br />
<br />
* WARN : multiple matches found for default "Funtoo Linux 64-bit" - most recent used.<br />
* Completed successfully with warnings.<br />
</pre><br />
<br />
===== Extlinux =====<br />
<br />
For Extlinux you will find a guide for setup at [[Extlinux]].<br />
<br />
== finalize Setup ==<br />
<br />
=== Necessary System Tools ===<br />
<br />
As some tools are providing the same functionality, it is up to you to choose which ones you like to use. The next sections are giving you an overview of tools you might like to use and install, but all are optional.<br />
<br />
==== System Logger ====<br />
<br />
Linux and Unix have an excellent history of logging capabilities, if you want you can log from only special stuff up to everything that happens on your system in logfiles, for that behavior is a system logger the reason.<br />
<br />
There are several in our repository from which you can choose:<br />
* sysklogd, which is a traditional set of system logging daemons,<br />
* syslog-ng, which is an advanced system logger and<br />
* metalog, which is a highly-configurable system logger,<br />
* rsyslog, seems to be a popular choice, default syslog of Fedora, RHEL, openSUSE, Debian and Ubuntu<br />
* there might be others available too, but at the moment we aren't aware of them.<br />
<br />
We advice you to install next to sysklogd or syslog-ng the logrotate tool, as those system loggers don't provide a rotation machanism for the log files.<br />
<br />
Just install the desired one like the example shows:<br />
<br />
<pre><br />
# emerge syslog-ng<br />
# rc-update add syslog-ng default<br />
</pre><br />
<br />
==== Optional: Cron Daemon ====<br />
<br />
Although this is optional it is in our opinion very handy and wise to install one. But you might ask yourself now "What the hell is a cron daemon?" A cron daemon just executes scheduled commands, so you see it can be very handy if you need to execute commands regularly.<br />
<br />
In our tree there are three possible cron daemons; dcron, fcron and vixie-cron. We would like to advise you to use fcron, but it depends on what you like. also vixie-cron might be easier, as you don't need to execute <tt>crontab /etc/crontab</tt>, fcron might be more powerful.<br />
<br />
<pre><br />
# emerge fcron<br />
# rc-update add fcron default<br />
# crontab /etc/crontab<br />
</pre><br />
<br />
==== Optional: File Indexing ====<br />
<br />
If you like to index your files for a fast search, you need to install mlocate so you can use the locate command to quickly search for them:<br />
<br />
<pre><br />
# emerge mlocate<br />
# updatedb<br />
</pre><br />
<br />
==== File System Tools ======<br />
<br />
As we used some special filesystems above you need to at least install xfsprogs, but there might be some others too, the following table gives you an overview:<br />
{| border="0" cellpadding="4"<br />
|-<br />
! File System !! Tool !! install command !! needed<br />
|-<br />
| XFS<br />
| xfsprogs<br />
| emerge xfsprogs<br />
| X<br />
|-<br />
| JFS<br />
| jfsprogs<br />
| emerge jfsprogs<br />
| <br />
|-<br />
| reiserfs<br />
| reiserfsprogs<br />
| emerge reiserfsprogs<br />
| <br />
|-<br />
| btrfs<br />
| btrfs-progs<br />
| emerge btrfs-progs<br />
| <br />
|-<br />
|}<br />
<br />
=== Networkconfig ===<br />
<br />
==== The Easy (Dynamic) Way ====<br />
<br />
When configuring your network, one option is to skip traditional network configuration and simply rely on DHCP. This is by far the simplest method of configuring your network. If you are on a wired network, no other steps are typically required beyond enabling a DHCP client, and Funtoo Linux includes dhcpcd 5.x by default. To enable DHCP at system startup, you would add dhcpcd to your default runlevel as follows:<br />
<br />
<pre><br />
# rc-update add dhcpcd default<br />
</pre><br />
<br />
{{note|If your going to use a third party package such as Network Manager or Wicd to manage your network then do not add dhcpcd to any runlevel. These packages handle DHCP for you.}}<br />
<br />
==== The Modular Way ====<br />
<br />
DHCP isn't always an option, and for these situations, Funtoo Linux offers its own modular, template-based network configuration system. This system offers a lot of flexibility for configuring network interfaces, essentially serving as a "network interface construction kit." This system can be used by itself, or even combined with dhcpcd -- if you limit dhcpcd to only manage certain network interfaces. <br />
<br />
Here are the key components of the template-based network configuration system: <br />
<ol style="list-style-type: decimal;"><br />
<li><p><tt>/etc/init.d/netif.lo</tt> -- An init script that configures the localhost interface.</p></li><br />
<li><p><tt>/etc/netif.d</tt> -- This is a directory that contains various network configuration templates. Each of these templates is focused on configuring a particular type of network interface, such as a general static IP-based interface, a bridge interface, a bond interface, etc.</p></li><br />
<li><p><tt>/etc/init.d/netif.tmpl</tt> -- This is the master init script for the template-based network configuration system. New interfaces are added to your system by creating symbolic links to this file in /etc/init.d.</p></li></ol><br />
<br />
So, if you wanted to use this system to configure eth0 with a static IP address, you would create a netif.eth0 symlink to netif.tmpl as follows: <br />
<pre><br />
# cd /etc/init.d<br />
# ln -s netif.tmpl netif.eth0<br />
</pre><br />
<br />
Then, you would create an /etc/conf.d/netif.eth0 configuration file that would specify which template to use from the /etc/netif.d directory: <br />
<pre><br />
template="interface"<br />
ipaddr="10.0.1.200/24"<br />
gateway="10.0.1.1"<br />
nameservers="10.0.1.1 10.0.1.2"<br />
domain="funtoo.org"<br />
</pre><br />
<br />
To complete our static IP network configuration we would need to: <br />
<pre><br />
# rc-update add netif.eth0 default<br />
</pre><br />
<br />
When configuring your own static network interface, one of ipaddr or ipaddrs is required and should specify the IP address(es) to configure for this interface, in "a.b.c.d/netmask" format. Optional parameters include gateway, which defines a default gateway for your entire network, and if set should specify the gateway's IP address. In addition, domain and nameservers (space-separated if more than one) can be used to specify DNS information for this interface. <br />
<br />
===== Configuration Variables =====<br />
<br />
====== Interface Variables ======<br />
<br />
The following variables are supported by the interface and bridge templates: <br />
<br />
* ipaddr or ipaddrs: specify IPv4 or IPv6 address(es) for the interface. IP addresses should be specified in "IP/netmask" format, such as "10.0.0.1/24". Multiple IP addresses can be specified like this:<br />
<pre><br />
ipaddrs="10.0.0.1/24 10.0.0.2/24"<br />
</pre><br />
<br />
Note that in some cases, you may choose to not specify ipaddr or ipaddrs for a bridge template. That is allowed. If you don't want to specify an IP address for a regular interface, you can choose to use the interface template without an IP address specified in the config, or use the interface-noip template instead, for the sake of clarity. <br />
<br />
Also note that if you specify multiple IP addresses, ifconfig will only show the first IP address. To view all IP addresses associated with the interface, use the ip addr show command. <br />
<br />
===== General Variables =====<br />
<br />
The following variables are enabled by default for all network scripts, and if specified will trigger a corresponding configuration action: <br />
nameservers: Set DNS nameservers using OpenResolv. Specify multiple nameservers like this: "1.2.3.4 1.2.3.5 1.2.3.6" <br />
* domain: Set DNS domain using OpenResolv. <br />
* gateway: Define a default IP gateway. <br />
* route: Specify a semi-colon delimited list of routes to apply when this interface is brought up. Will be appended to ip route add. <br />
* mtu: Set Maximum Transmit Unit for the interface <br />
* slaves: Set slave interfaces of this interface (for bridges, etc.) All slaves will automatically be depended upon, and will also automatically have their mtu set to that of the current interface, if an mtu is specified for the current interface. This setting is required for the bond template and optional for the bridge template.<br />
<br />
==== VLAN Variables ====<br />
<br />
VLAN support is enabled by default for all network configuration scripts. If a network script has a name in the format netif.ethX.Y, then it is assumed to be a VLAN interface referencing trunk ethX and VLAN ID Y. If you desire a custom name for your VLAN interface, you can name your interface whatever you'd like and specify the following variables in your interface config [file: file:] <br />
* trunk: VLAN trunk interface, e.g. "eth0" <br />
* vlan: VLAN id, e.g. "32" <br />
<br />
==== OpenResolv and resolv.conf ====<br />
<br />
For the network configuration above, OpenResolv will be used to set DNS information when the netif.eth0 is brought up. The OpenResolv framework will add entries to /etc/resolv.conf, and will also handle removing these entries when the interface is brought down. This way, /etc/resolv.conf should always contain current information and should not need to be manually edited by the system administrator. dhcpcd will use OpenResolv for updating system DNS information as well. <br />
<br />
==== Network-Dependent Services ====<br />
<br />
One important difference between Gentoo Linux and Funtoo Linux is that, in Funtoo Linux, network-dependent services only strictly depend on netif.lo. This means that if another network service requires an interface to be up, such as samba requiring eth0, then the system administrator must specify this relationship by adding the following line to /etc/conf.d/samba: <br />
<pre><br />
rc_need="netif.eth0"<br />
</pre><br />
<br />
This will have the effect of ensuring that netif.eth0 is started prior to samba and that samba is stopped prior to stopping netif.eth0. <br />
<br />
Many network services, especially those that listen on all network intefaces, don't need an rc_need line in order to function properly. Avoiding the use of rc_need when required will optimize boot times and allow more network services to remain available when network interfaces are brought up and down by the system administrator. <br />
<br />
<br />
==== Multiple Network Configurations ====<br />
<br />
For information on how to have multiple, independent network configurations, please see Stacked Runlevels. <br />
<br />
===== Alternate Configs =====<br />
<br />
If you need to run the same service with different configuration parameters depending upon runlevel, then you'll be happy to know that you can specify runlevel-specific conf.d files by appending a . <runlevel> suffix. In this particular example, we could imagine a situation where we had two child runlevels named home and work: <br />
<pre><br />
/etc/conf.d/netif.eth0.home<br />
/etc/conf.d/netif.eth0.work<br />
</pre><br />
Note that this feature works for all init scripts, not just network configuration scripts. <br />
<br />
===== Interface Renaming =====<br />
<br />
Funtoo network scripts now support interface renaming, so you can create an interface called lan if you would like. To so this, simply specify the MAC address of the interface you would like to rename using the macaddr variable: <br />
macaddr="00:15:17:19:b6:a3"<br />
If this MAC address is part of the netif.lan configuration file, then when this interface starts, whatever interface currently has the MAC address of 00:15:17:19:b6:a3 (i.e. eth5) will be renamed to lan prior to the interface being brought up, and will show up in ifconfig and ip commands as being an interface named lan. <br />
<br />
===== Basic VLAN Configuration =====<br />
<br />
The standard interface template supports VLANs. To use VLAN support, first configure the trunk interface using the interface-noip template. Assuming eth1 is trunked, you would create the file /etc/conf.d/netif.eth1 with the following contents: <br />
<pre><br />
template="interface-noip"<br />
</pre><br />
<br />
Then, create a network interface symlink for the trunk and add it to your default runlevel: <br />
<pre><br />
# cd /etc/init.d<br />
# ln -s netif.tmpl netif.eth1<br />
# rc-update add netif.eth1 default<br />
</pre><br />
<br />
Now, assuming you wanted to configure a VLAN of 32, you would create a config file named /etc/conf.d/netif.eth1.32 that looks something like this: <br />
<pre><br />
template="interface"<br />
ipaddr="1.2.3.4/24"<br />
gateway="1.2.3.1"# etc...<br />
</pre><br />
<br />
Then, create a VLAN network interface symlink and add it to your default runlevel: <br />
<pre><br />
# cd /etc/init.d<br />
# ln -s netif.tmpl netif.eth1.32# rc-update add netif.eth1.32 default<br />
</pre><br />
<br />
The Funtoo network configuration scripts will automatically recognize the filename netif.eth1.32 as being VLAN 32 of trunk interface netif.eth1. <br />
<br />
When the VLAN interface is brought up, it will be named eth1.32. <br />
<br />
===== Custom VLAN Names =====<br />
<br />
However, sometimes you may want to turn off automatic file-based VLAN naming and give your VLAN interface a custom name, such as mgmt. To do this, you would set up the trunk interface in the exact same way as described above, but instead of creating a netif.eth1.32 interface, you would create a netif.mgmt interface, and specify vlan and trunk in the /etc/conf.d/netif.mgmt config file, as follows: <br />
<pre><br />
template="interface"<br />
vlan="32"<br />
trunk="eth1"<br />
ipaddr="1.2.3.4/24"<br />
gateway="1.2.3.1"<br />
# etc...<br />
</pre><br />
<br />
When you specify trunk and vlan in the interface config file, filename-based auto-detecting of VLAN ID and trunk is disabled. Both trunk and vlan must be specified -- you can't specify just one. <br />
<br />
Then you would simply create a VLAN network interface symlink for netif.mgmt: <br />
<pre><br />
# cd /etc/init.d<br />
# ln -s netif.tmpl netif.mgmt<br />
# rc-update add netif.mgmt default<br />
</pre><br />
<br />
When the VLAN interface is brought up, it will be named mgmt. <br />
<br />
==== More Complex Network Configuration ====<br />
<br />
If the standard templates don't work for your needs, simply create a new template -- I recommend starting from the interface template for most things: <br />
<pre><br />
# cd /etc/netif.d<br />
# cp interface custom<br />
</pre><br />
<br />
You can now call whatever commands you need to /etc/netif.d/custom. The following shell functions can be defined in a network script: <br />
<br />
==== netif_create ====<br />
<br />
In netif_create, you should call any commands to create the interface if it does not yet exist. <br />
<br />
==== netif_depend ====<br />
<br />
In netif_depend, you can define dependencies, using the functions need and use. <br />
<br />
==== netif_pre_up ====<br />
<br />
In netif_pre_up, you can define network configuration actions to perform prior to bringing the interface up. You can also ensure certain variables are specified by calling require var1 [var2...] here. <br />
<br />
==== netif_post_up ====<br />
<br />
In netif_post_up, you can define network configuration actions to perform after bringing the interface up. <br />
<br />
==== netif_pre_down ====<br />
<br />
In netif_pre_down, you can define network configuration actions to perform prior to bringing the interface down. <br />
<br />
==== netif_post_down ====<br />
<br />
In netif_post_down, you can define network configuration actions to perform after bringing the interface down. <br />
<br />
==== netif_destroy ====<br />
<br />
In netif_destroy, you can call any commands necessary to destroy/delete the interface if it is dynamic in nature (tun/tap, etc.) <br />
<br />
==== How It Works ====<br />
<br />
You do not specify a function for actually bringing up the interface, because the template-based system does this for you. The template-based system also performs all normal actions for required for bringing an interface down, so only need to specify atypical actions that must be performed - such as removing child interfaces or destroying a bridge using brctl. <br />
<br />
When you create your own network configuration template, the following capabilities are available for use automatically, as long as the appropriate variables are set in the /etc/conf.d/netif.<ifname> file,, without requiring any explicit steps on your part: <br />
* DNS configuration using domain and nameservers config settings. OpenResolv is used automatically. <br />
* VLAN configuration using auto-naming (netif.ethX.Y) or via custom naming with trunk and vlan config settings. <br />
* Default gateway and route configuration using the gateway and route settings. <br />
* MTU configuration using the mtu setting. <br />
* Auto-depend (and auto-MTU configuration) of slave interfaces specified using slaves setting. <br />
* Renaming of existing network interface (specify MAC address using macaddr setting). <br />
<br />
To take advantage of this functionality, simply enable the appropriate variables. <br />
<br />
All other necessary network configuration and dependency behavior should be defined using the netif_-prefix functions described above. <br />
<br />
==== Wireless Configuration ====<br />
<br />
Wireless network configuration requires additional steps to the ones outlined above. <br />
<br />
For wireless networks, you will need to enable wireless extensions in your kernel, the appropriate wireless modules, and emerge wireless-tools: <br />
<pre><br />
# emerge wireless-tools<br />
</pre><br />
<br />
I also recommend you emerge wpa_supplicant. wpa_supplicant implements modern WPA/WPA2 wireless link-layer encryption, which is necessary for connecting to most modern password-protected wireless networks: <br />
<br />
<pre><br />
# emerge wpa_supplicant<br />
</pre><br />
<br />
After emerging, add to your default runlevel as follows: <br />
<pre><br />
# rc-update add wpa_supplicant default<br />
</pre><br />
<br />
==== 802.11 Passphrases ====<br />
<br />
The only remaining step is to use the wpa_passphrase utility to store hashed keys (passwords) that wpa_supplicant can use to connect to your favorite wireless networks. This is done as follows: <br />
<pre><br />
# wpa_passphrase jims-netgear >> /etc/wpa_supplicant/wpa_supplicant.conf<br />
<enter your passphrase><br />
</pre><br />
<br />
Now, when wpa_supplicant encounters an SSID of jims-netgear, it will use the password you entered to authenticate with this access point. <br />
<br />
At this point, ensure that dhcpcd has been enabled in your current runlevel and type rc to start everything up. wpa_supplicant should be able to automatically associate with SSIDs in its config file, at which point dhcpcd will take over and acquire an IP address from a DHCP server. This should all happen seamlessly. Use the iwconfig command to see if you have successfully associated with an access point. <br />
<br />
<br />
<br />
==== Wireless Firmware ====<br />
<br />
Many wireless adapters will now have everything they need to work. However, if you have an Intel wireless adapter, then you may need to install the proper microcode for your device in addition to ensuring that the proper Intel Wireless kernel drivers are available. For my Intel Corporation PRO/Wireless AGN [Shiloh] Network Connection, I need to do the following: <br />
<pre><br />
# emerge net-wireless/iwl5000-ucode<br />
</pre><br />
<br />
udev (running by default) and the Linux kernel firmware loader support (CONFIG_FW_LOADER) will automatically load the microcode when needed. <br />
<br />
Note that Gentoo and Funtoo provide different versions of the Intel microcode because the version you need will depend on the kernel you are using. For my RHEL5-based kernel, I had emerge an older version of the microcode to match what my kernel wireless driver was expecting by typing: <br />
# emerge =net-wireless/iwl5000-ucode-5.4.0.11<br />
<br />
This installed this file iwlwifi-5000-1.ucode which was required by my RHEL5-based kernel. Just typing emerge net-wireless-iwl5000-ucode installed iwlwifi-500-2.ucode, which my kernel could not use. Before I had the right version of the microcode, I saw an error like this when I viewed the kernel messages by typing dmesg: <br />
iwl5000: iwlwifi-5000-1.ucode firmware file req failed: Reason -2<br />
<br />
This error message generally means "I can't find this file iwlwifi-5000-1.ucode that I'm looking for in /lib/firmware." With the proper firmware in place, then the wireless driver will be happy and wpa-supplicant can then bring the wireless interface up.<br />
<br />
=== Set your root password ===<br />
<br />
It's imperative that you set your root password before rebooting: <br />
<pre><br />
# passwd<br />
</pre><br />
<br />
=== Create a user account ===<br />
<br />
Logging in as root is a bad idea on a Linux system. Before rebooting, create a user account for everyday use. Adjust the groups in the example below to match your needs. Some of them may not exist yet on your system. Replace '<user_name>' with the name your going to use for your everyday user. The '-m' option instructs useradd to create a home directory for your user. See the useradd manpage for more info. <br />
<pre><br />
useradd -m -G audio,cdrom,cdrw,floppy,usb,users,video,wheel -s /bin/bash <user_name><br />
</pre><br />
<br />
Don't forget to set a password for your new user: <br />
<pre><br />
passwd <user_name><br />
</pre><br />
<br />
=== Verify boot time services ===<br />
<br />
You should verify that all of your needed services have been added to the appropriate runlevel. <br />
<pre><br />
eselect rc list | less<br />
</pre><br />
<br />
Scroll though the list and check. Example of things you might need to add: <br />
* lvm if you use logical volumes <br />
* Your system logger if you installed one <br />
* hibernate-cleanup if you use tuxonice <br />
* iptables <br />
* dbus <br />
<br />
Add anything you need with the following command: <br />
<pre><br />
eselect rc add <script> <runlevel><br />
</pre><br />
<br />
=== First boot ===<br />
<br />
Now is the time to leave chroot, to unmount Funtoo Linux partitions and files and to restart your PC. If you installed GRUB, you will get an option to launch Funtoo Linux. Otherwise you will get to your already installed Linux and you will have to update your GRUB menu. <br />
<br />
Leave the chroot, change directory to /, and unmount your funtoo partitions. Adjust the unmount command to match your setup <br />
<pre><br />
exit<br />
cd /<br />
umount /mnt/funtoo/home /mnt/funtoo/boot /mnt/funtoo/dev /mnt/funtoo/proc /mnt/funtoo/usr/portage /mnt/funtoo<br />
</pre><br />
<br />
{{fancynote|In case of LVM2 also: <tt>swapoff /dev/mapper/vg-swap</tt>, <tt>vgchange -a n</tt> , if not You will see: Device dmcrypt_root is busy. In case of luks: <tt>cryptsetup luksClose dmcrypt_root</tt> to close the container.}}<br />
<br />
<br />
Restart <br />
<pre><br />
shutdown -r now<br />
</pre><br />
<br />
== What's next ==<br />
* [[Funtoo Linux First Steps]]<br />
<br />
[[Category:HOWTO]]<br />
[[Category:Install]]<br />
[[Category:Tutorial]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Clang&diff=10510Clang2015-06-24T20:01:12Z<p>Duncan.britton: Began updating the page...</p>
<hr />
<div>== Introduction ==<br />
LLVM can be used as an alternative to GNU's compiler, GCC. The main benefit of using LLVM compilers instead of GCC is their lower memory usage, faster compile time and better diagnostics. There are some Benchmarks on the [http://clang.llvm.org/features.html#performance Clang] and [http://www.phoronix.com/scan.php?page=article&item=llvm3_gcc_open64 Phoronix] homepages.<br />
<br />
It may happen that some programs do not compile (like glibc) because they depend on GCC-specific language extensions [http://gcc.gnu.org/onlinedocs/gcc/C-Extensions.html] (this is why the whole BSD code can be compiled with LLVM but some GNU code cannot) or segfault after successful compilation with LLVM (like xorg-server) but after following this guide, the system will still be able to compile packages with gcc. So if something goes wrong, it can be switched back to gcc for the particular package by uncommenting lines in /etc/make.conf and the bug should be reported.<br />
<br />
LLVM's C/C++ frontends clang and clang++ version 3.0 are stable enough to be self-hosting [http://blog.llvm.org/2010/02/clang-successfully-self-hosts.html] and compile Boost [http://blog.llvm.org/2010/05/clang-builds-boost.html], Qt [http://labs.qt.nokia.com/2010/10/29/compiling-qt-with-clang/], LibreOffice [http://wiki.documentfoundation.org/Development/Building_LibreOffice_with_Clang], FreeBSD [http://wiki.freebsd.org/BuildingFreeBSDWithClang], some parts of the Linux kernel [http://lwn.net/Articles/411654/] and more.<br />
<br />
Further, using LLVM 3.0 and up, there is a third way to compile with LLVM: the dragonegg package creates a gcc-plugin, that uses LLVM's optimizers but parses the code and creates binaries with gcc, which means that everything that compiles and works with gcc should work with dragonegg also. This plugin can be enabled by using a single CFLAG. Since LLVM 3.0 the old llvm-gcc package is deprecated and replaced by dragonegg, so it will disappear from portage with llvm version 2.9.<br />
<br />
==LLVM Frontends==<br />
To be able to compile some sourcecode of a specific language, LLVM needs an appropriate frontend. There are clang, llvm-gcc and dragonegg in portage.<br />
<br />
The goal of the Clang project is to create a new C, C++, Objective C and Objective C++ front-end for the LLVM compiler.<br />
<br />
llvm-gcc is a modified version of gcc that compiles C/ObjC programs into native objects, LLVM bitcode or LLVM assembly language, depending upon the options. As written in the previous section, dragonegg replaced llvm-gcc in version 3.0.<br />
<br />
So after installing llvm, clang and dragonegg, you will be able to choose between gcc and llvm whenever you like or use them both at the same time.<br />
<br />
== Install LLVM and its Frontends ==<br />
Simply emerge the packages on ~arch systems. On arch systems you have to unmask some packages first. dragonegg requires gcc's ''lto'' USE-flag to be set and works with gcc 4.5 and gcc 4.6.<br />
{{console|body=<br />
###i## emerge llvm clang dragonegg<br />
}}<br />
Note, that for clang++ the C++ headers search path is hardcoded to the active gcc profile.<br />
If you change the active gcc profile, or update gcc to a new version, you will have to remerge clang to update the search path.<br />
<br />
To use dragonegg, run gcc as usual, with an extra command line argument {{c|-fplugin=/usr/lib/llvm/dragonegg.so}}<br />
If you change the active gcc profile, or update gcc to a new version, you will have to remerge dragonegg to update the plugin.<br />
<br />
After the installation, check which CPUs are supported by using the command<br />
{{console|body=<br />
###i## llvm-as < /dev/null | llc -mcpu=help<br />
}}<br />
and then add the following lines to {{c|/etc/portage/make.conf}} (uncommenting the lines you need) to enable compilation via LLVM, adapting the march-option according to the previous command:<br />
{{file|name=/etc/portage/make.conf|lang=bash|body=<br />
# LLVM<br />
#CC="/usr/bin/clang"<br />
#CXX="/usr/bin/clang++"<br />
<br />
# llvm-gcc for C++ code and fortran<br />
# llvm-gcc is deprecated and only used with LLVM 2.9<br />
#CC="/usr/bin/llvm-gcc"<br />
#CXX="/usr/bin/llvm-g++"<br />
#CPP="/usr/bin/llvm-cpp"<br />
#F77="/usr/bin/llvm-gfortran"<br />
<br />
# Flags for clang: Insert your arch here instead of k8 and have a look at the manpage of clang for flag descriptions.<br />
# Some gcc flags like -pipe and -pthread also work, though they might be ignored by clang.<br />
#CFLAGS="-march=k8 -O2"<br />
<br />
# Flags for dragonegg; just use all the gcc flags you like and append -fplugin=/path/to/dragonegg.so<br />
#CFLAGS="-march=k8 -O2 -fplugin=/usr/lib64/llvm/dragonegg.so"<br />
}}<br />
<br />
{{Note|Have a look at clang's manpages for additional information. If you get errors that your compiler cannot produce code, you should check your flags, e.g. don't use {{c|-O4 -flto -S}} or stuff like that; the examples above will work.}}<br />
<br />
== Using clang with portage ==<br />
<br />
Although the Funtoo portage tree is not designed to be used with any compiler other than GCC, clang can be enforced on most of the packages through the {{c|CC}} and {{c|CXX}} variables. Please note, however, that many of Gentoo packages still don't build with clang and a few don't work correctly after being built. That's why we suggest using {{c|/etc/portage/env}} file to enable the use of clang per-package. In order to do such, first create a new environment override to use in {{c|/etc/portage/env/clang}}:<br />
{{file|name=/etc/portage/env/clang|lang=bash|body=<br />
CC=clang<br />
CXX=clang++<br />
}}<br />
Then you can enable use of clang for packages:<br />
{{file|name=/etc/portage/package.env|lang=bash|body=<br />
app-foo/bar clang<br />
app-bar/baz clang<br />
}}<br />
<br />
If you want to use clang by default, you can. and need to specify some core packages. Here is small list of core packages that are currently failing on clang, but that are most likely not outdated:<br />
<br />
<pre><br />
CC=gcc<br />
CXX=g++<br />
</pre><br />
<br />
in addition, it is recommended to add compiler flags there (<tt>/etc/portage/env/gcc</tt>:<br />
<br />
<pre><br />
CFLAGS="-O2 -march=native -mtune=native -pipe"<br />
CXXFLAGS="-O2 -march=native -mtune=native -pipe"<br />
LDFLAGS="-Wl,--as-needed"<br />
#You can disable gold link here<br />
#EXTRA_ECONF="--enable-gold=default"<br />
</pre><br />
<br />
And in <code>/etc/portage/package.env</code>:<br />
<br />
<pre><br />
#---------------CORE PACKAGES TO BUILD WITH GCC:<br />
sys-apps/which gcc<br />
sys-fs/reiserfsprogs gcc<br />
sys-libs/ncurses gcc<br />
sys-libs/zlib gcc<br />
sys-apps/busybox gcc<br />
sys-fs/e2fsprogs gcc<br />
sys-devel/binutils gcc<br />
sys-libs/glibc gcc<br />
sys-devel/dragonegg gcc<br />
dev-libs/openssl gcc<br />
sys-boot/grub gcc<br />
#---------------USER PACKAGES TO BUILD WITH GCC:<br />
sys-apps/pacman gcc<br />
www-client/firefox gcc<br />
x11-libs/cairo gcc<br />
media-libs/mesa gcc<br />
</pre><br />
<br />
If you have {{Package|app-portage/flaggie}} installed, you can modify <code>/etc/portage/package.env</code> by running the following:<br />
<console><br />
###i## flaggie app-foo/bar app-bar/baz +clang<br />
</console><br />
<br />
== Enabling link-time optimizations ==<br />
<br />
The ''link-time optimization'' feature defers optimizing the resulting executables to linking phase. This can result in better optimization of packages but is unsupported in Gentoo, and many packages simply fail to build.<br />
<br />
When using LTO, clang compiles units into LLVM byte-code rather than machine code. In order to support linking such object files, the [[gold]] linker must be installed and set as the default linker, as it does support plugins.<br />
<br />
Similarly, ''ar'' needs plugin support as well. Sadly, binutils ar doesn't support passing '--plugin'' option before the actual command. Thus, we need to create a wrapper for it in <code>/usr/local/bin/clang-ar</code>:<br />
<br />
<pre><br />
#!/bin/sh<br />
firstarg=${1}<br />
shift<br />
<br />
exec /usr/bin/ar "${firstarg}" --plugin /usr/lib/llvm/LLVMgold.so "${@}"<br />
</pre><br />
<br />
If that's done, you can create a new environment override profile for LTO-enabled clang in <code>/etc/portage/env/clang-lt</code>:<br />
<br />
<pre><br />
CC='clang'<br />
CXX='clang++'<br />
CFLAGS="${CFLAGS} -O4"<br />
CXXFLAGS="${CXXFLAGS} -O4"<br />
LDFLAGS="${LDFLAGS} -O4 -Wl,-plugin,/usr/lib/llvm/LLVMgold.so"<br />
AR='/usr/local/bin/clang-ar'<br />
RANLIB=':'<br />
NM='nm --plugin /usr/lib64/llvm/LLVMgold.so'<br />
</pre><br />
<br />
Note that the link-time optimizations were indirectly enabled here via ''-O4''. If you don't want to enable other optimizations enforced by ''-O3'', please use ''-flto'' instead. You need to also pass optimization flags when linking because that's where clang needs them.<br />
<br />
You may also need to adjust the libdir path to plugin. Newer (live) versions of clang add `-plugin` when linking automatically, so `-Wl,-plugin`… is no longer necessary.<br />
<br />
== Using clang with distcc ==<br />
<br />
In order to use clang on distcc client, additional symlinks have to be created in <code>/usr/lib*/distcc/bin</code>:<br />
<console><br />
###i## ln -s /usr/bin/distcc /usr/lib/distcc/bin/clang<br />
###i## ln -s /usr/bin/distcc /usr/lib/distcc/bin/clang++<br />
</console><br />
<br />
{{GLW|src=http://wiki.gentoo.org/wiki/Clang}}<br />
<br />
[[Category:HOWTO]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:CCache&diff=10509Package:CCache2015-06-24T17:53:02Z<p>Duncan.britton: Updated the <code> and <console> tags on the page to {{c}} and {{console}} templates. Changed the wording in a few places.</p>
<hr />
<div>{{Ebuild<br />
|Summary=CCACHE is an application that caches compilation results and reuses it in future compilations in order to achieve faster compile times.<br />
|CatPkg=dev-util/ccache<br />
|Maintainer=<br />
|Repository=Gentoo Portage Tree<br />
}}<br />
{{Note|'''CCACHE can cause build failures'''. If it does, please try to compile the application without CCACHE enabled. Bug reports reported with CCACHE enabled will be closed.}}<br />
<br />
== Installing CCACHE ==<br />
To emerge {{Package|dev-util/ccache}}, run the following:<br />
{{console|body=<br />
###i## emerge ccache<br />
}}<br />
Once it finishes emerging, enable it in portage. This is very easy. Just open up {{c|/etc/portage/make.conf}} with your favorite text editor and add the following:<br />
{{file|name=/etc/portage/make.conf|lang=bash|desc=|body=<br />
FEATURES="ccache"<br />
}}<br />
<br />
That's it. If you want to check how much space the cache is taking up on your disk and other info about the cache, run the following command:<br />
{{console|body=<br />
###i## CCACHE_DIR="/var/tmp/ccache" ccache -s<br />
}}<br />
<br />
You must pass the {{c|CCACHE_DIR}} option since ccache normally defaults to the user's home directory, and portage uses {{c|/var/tmp/ccache}}.<br />
<br />
== Tweaking CCACHE ==<br />
=== Disabling the CACHE limit ===<br />
If you want to let the cache have the flexibility to grow to whatever size it needs to (unlimited size cache), just do the following:<br />
{{console|body=<br />
###i## CCACHE_DIR="/var/tmp/ccache" ccache -M 0<br />
}}<br />
== Tricks ==<br />
=== Using CCACHE to compile your kernel faster ===<br />
In order to use {{c|CCACHE}} to compule your kernel more quickly, you need to change a few variables. You probably only want to change these variables temporarily, but you could change them permanently if you want to. Since we just want to do this temporarily, make a new file called {{c|build.sh}} and put the following inside of it:<br />
{{file|name=build.sh|lang=bash|body=<br />
#!/bin/bash<br />
<br />
export CCACHE_DIR="/var/tmp/ccache"<br />
export PATH="/usr/lib/ccache/bin:${PATH}"<br />
<br />
cd /usr/src/linux<br />
time make bzImage modules<br />
}}<br />
<br />
Give the file execute permission:<br />
{{console|body=<br />
$##bl## chmod u+x build.sh<br />
}}<br />
This will temporarily export the variables neccessary, then go into the {{c|/usr/src/linux}} folder (whatever you declared with 'eselect kernel') and then compile the kernel.<br />
<br />
[[Category:HOWTO]]<br />
[[Category:Ebuilds]]<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Boot_livecd_ISO_from_HDD&diff=10508Boot livecd ISO from HDD2015-06-24T17:46:32Z<p>Duncan.britton: Removed spaces</p>
<hr />
<div>With [[Grub| GRUB2]], you can easily boot a livecd image from your hard drive.<br />
<br />
== General guide ==<br />
{{Note|This is general example. It may not work with all livecds.}}<br />
1. Copy the iso image to root folder for simplicity:<br />
{{console|body=<br />
###i## cp /home/user/downloads/systemrescuecd.iso /src.iso<br />
}}<br />
2. Reboot and when grub2 loads press 'c' for console. Run the following commands (tab autocompletion is your friend):<br />
{{console|body=<br />
loopback loop (hd0,2)/src.iso<br />
linux (loop)/boot/vmlinuz<br />
initrd (loop)/boot/initrd.lz<br />
boot<br />
}}<br />
<br />
[[Category:HOWTO]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Boot_livecd_ISO_from_HDD&diff=10507Boot livecd ISO from HDD2015-06-24T17:46:16Z<p>Duncan.britton: Removed ugly white box around {{note}}, updated from <console> to {{console}}</p>
<hr />
<div>With [[Grub| GRUB2]], you can easily boot a livecd image from your hard drive.<br />
<br />
== General guide ==<br />
{{Note|This is general example. It may not work with all livecds.}}<br />
<br />
1. Copy the iso image to root folder for simplicity:<br />
{{console|body=<br />
###i## cp /home/user/downloads/systemrescuecd.iso /src.iso<br />
}}<br />
<br />
2. Reboot and when grub2 loads press 'c' for console. Run the following commands (tab autocompletion is your friend):<br />
{{console|body=<br />
loopback loop (hd0,2)/src.iso<br />
linux (loop)/boot/vmlinuz<br />
initrd (loop)/boot/initrd.lz<br />
boot<br />
}}<br />
<br />
[[Category:HOWTO]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Bluetooth_made_easy&diff=10506Bluetooth made easy2015-06-24T17:09:53Z<p>Duncan.britton: Added kernelop's, file's and {{c}}'s - - formatted the page to 'conform' more to wiki standards.</p>
<hr />
<div>== Kernel Support ==<br />
You must have bluetooth support in your kernel if you are going to use bluetooth. Enable the following in your kernel config:<br />
{{kernelop|title=Networking Support|desc=<br />
Bluetooth subsystem support →<br />
<m> RFCOMM protocol support<br />
<*> RFCOMM tty support<br />
<m> BNEP protocol support<br />
<*> Multicast filter support<br />
<*> Protocol filter support<br />
<m> HIDP protocol support<br />
}}<br />
I find no difference in choosing built-in modules vs. loading modules with the exception that someday you may wish to use out-of-tree drivers directly from wireless.kernel.org. Just adding all the modules guarantees you can do anything bluetooth in the future, not worth worrying about saving a tiny bit of space.<br />
<br />
Also be sure and select your bluetooth device driver:<br />
{{kernelop|title=Networking Support|desc=<br />
Bluetooth subsystem support →<br />
Bluetooth device drivers →<br />
<m> HCI USB driver<br />
}}<br />
Make sure you choose at least the HCI USB driver. Others may be applicable to your setup too, for example, if you have a Broadcom BCM203x device you'll want the driver for that which loads the appropriate firmware.<br />
== Userspace Programs ==<br />
There was a big change in the transition from bluez4 to bluez5, namely support for HandsFree Profile/Headset Profile (HFP/HSP) was dropped. Pulseaudio was supposed to begin supporting those profiles but there was a _____long wait. However, the wait is over and you can now once again use headsets for Skype, Sip, etc.<br />
If you plan to use headsets you'll want to add use changes to pulseaudio, as the default usage profile in the Funtoo tree does not support headsets. headset-native and headset-ofono are needed. One example would be<br />
{{console|body=<br />
###i## echo ">=media-sound/pulseaudio-5.99 headset-native headset-ofono" >> /etc/portage/package.use<br />
}}<br />
A2DP and other protocols work fine in bluez-5 without help from pulseaudio, so if you don't intend to use headsets the above doesn't apply.<br />
<br />
Add “bluetooth” to your USE flags in /etc/portage/make.conf<br />
<br />
And then: {{c|emerge -aND @world}}<br />
<br />
If you need firmware for your bluetooth receiver be sure and get that too. {{c|Sys-kernel/linux-firmware}} is always a safe bet to have on hand.<br />
<br />
Unless you prefer controlling your devices at the command line you'll need either Blueman or Gnome-bluetooth, handy GUI applets, just click on the device you want to control.<br />
<br />
You'll want to add bluetooth to your startup:<br />
{{console|body=<br />
###i## rc-update add bluetooth default<br />
}}<br />
<br />
== Usage ==<br />
While it's rumored that some high-profile Funtoo users refuse to even run an X server, for the rest of us a handy GUI can be nice. However, be aware that all operations can be done from the command line as well.<br />
<br />
Pair up your devices, you're ready to go! With either Blueman or Gnome-bluetooth it's intuitive, they'll steer you in the right direction. There's a ton of info on the web if for some reason you wish to use the command line rather than a GUI.<br />
<br />
== Custom Tips ==<br />
{{fancynote|Some of the following requires installation of net-wireless/rfkill, a handy thing to have anyway}}<br />
Bluez-5.x starts with your bluetooth device (receiver) powered off. For those that would like their bluetooth active on machine start, the following code passing around the web added to /etc/udev/rules.d/10-local.rules is purported to work:<br />
{{console|body=<br />
###i## /etc/udev/rules.d/10-local.rules<br />
###i## Set bluetooth power up<br />
###i## ACTION=="add", KERNEL=="hci0", RUN+="/usr/bin/hciconfig hci0 up"<br />
}}<br />
Those generic Debian-based instructions do not work for me at all with Bluez5.x in Funtoo. It starts with {{c|rfkill bluetooth}} soft blocked and hci down. If you want it that way, you're good to go. If you want bluetooth enabled on start what does work for me is this:<br />
{{console|body=<br />
###i## /etc/local.d/*.start<br />
###i## rfkill unblock bluetooth<br />
###i## You may need a sleep command here, I just put it further down the list after other things<br />
###i## /usr/bin/hciconfig hci0 up<br />
}}<br />
Your bluetooth device will be physically powered down (no electricity even) when {{c|rfkill}} blocks it. Most desktop environments, Gnome, KDE, etc. have some way to assign a hotkey to a command. However, these commands are limited to the unprivileged user. Since {{c|rfkill}} must be run by root I use the following method.<br />
<br />
First, we need toggle action, so one hotkey can turn bluetooth either off or on. The following code accomplishes that.<br />
I have a {{c|/home/<username>/bin}} directory with many “helper” programs. In there, create a file owned by root, with chmod 744 permissions called bluetooth.<br />
{{console|body=<br />
$##bl## cd ~<br />
$##bl## mkdir bin<br />
$##bl## cd bin<br />
$##bl## touch bluetooth<br />
$##bl## sudo chown root: bluetooth<br />
$##bl## sudo chmod 744 bluetooth<br />
}}<br />
Paste the following code into the file with your favorite editor, taking care to change the device name as noted.<br />
{{file|name=~/bin/bluetooth|lang=bash|desc=|body=<br />
#/home/<username>/bin/bluetooth<br />
#keyboard shortcut set to <your choice>, toggles bluetooth on & off<br />
#this file must be added to sudoers ;)<br />
<br />
# we need to find which rfkill applies to bluetooth, there can be one for wifi, one for bluetooth, I have a 3rd , don't even know what it is<br />
<br />
for file in /sys/class/rfkill/*<br />
do<br />
if [ "$(cat ${file}/name)" = "hp-bluetooth" ]; then ### you'll have to snoop around in there, rename to what your device is called<br />
BT_STATE=$(cat ${file}/state)<br />
fi<br />
done<br />
if [[ ${BT_STATE} -eq 1 ]]; then<br />
rfkill block bluetooth<br />
BLUETOOTH_STRING=" Bluetooth powered off"<br />
DISPLAY_COLOR="red"<br />
else<br />
rfkill unblock bluetooth<br />
BLUETOOTH_STRING=" Bluetooth powered on"<br />
DISPLAY_COLOR="blue"<br />
fi<br />
# Clean up any running aosd_cat processes<br />
killall aosd_cat &> /dev/null<br />
# Display the desired text<br />
echo "$BLUETOOTH_STRING" | aosd_cat -n "Georgia Italic 120" -u 1000 -o 200 -R $DISPLAY_COLOR -S black -f 0 -e 4 -p 3 -x 300<br />
}}<br />
As you can see, I also have a display that prints huge colored letters across my screen telling bluetooth status for a few seconds as I enable/disable it. To have the display you must install {{c|x11-libs/libaosd}} with USE={{c|pango}}, it's disabled by default. That's it, the code in the bluetooth program shows how to use this handy library, you can tweak font size, etc. to your liking.<br />
<br />
This one-liner will list out the available {{c|rfkill}} named devices on your computer:<br />
{{console|body=<br />
###i## for file in /sys/class/rfkill/* ; do echo "$(cat ${file}/name)"; done<br />
}}<br />
You may have to snoop around a bit in {{c|/sys}} to find what you're looking for. The name of your device may be something as simple as {{c|hci0}}. I actually use {{c|/sys/devices/platform/hp-wmi/rfkill/*}} on my system, but this generic method should work for you. A static directory usually doesn't work, it's often different on every startup, hence the search code.<br />
<br />
Since this program is owned by root, and in fact, {{c|rfkill}} itself must be run as root, simply put the following line in your sudoers file using the {{c|visudo}} command:<br />
{{file|name=/etc/sudoers|desc=Edit only with {{c|visudo}}|body=<br />
...<br />
<your username> ALL = NOPASSWD: /home/<username>/bin/bluetooth<br />
...<br />
}}<br />
Now just add the following command to your hotkey assignment, and you can toggle bluetooth on & off to your heart's content:<br />
{{console|body=<br />
$##bl## sudo /home/<username>/bin/bluetooth<br />
}}<br />
<br />
== Yet Another Trick ==<br />
Suppose that I have two computers at my desk, one is rarely used and somewhat underpowered. I sometimes use it, though, to talk on voip, leaving my main machine free to compile, restart, whatever.<br />
<br />
The problem: I wish to use the same headsets on both computers. In practice, this is a bit of a hassle, because you must pair the headsets with only one machine, so as I switch back and forth, I have to change the pairing. Not the end of the world, but we can end that hassle.<br />
<br />
{{fancynote|Some newer headsets can be paired to as many as 3 different receivers, great...if you have them}}<br />
The first task is to acquire the {{c|bdaddr}} program. It's on the Backtrack Linux distros, so you can probably find it out there in cyberspace somewhere, but it gets confusing on a search because bluez uses the {{c|bdaddr}} abbreviation a lot, creating a lot of noise in your search.<br />
I just put it in {{c|/usr/bin}}.<br />
<br />
To accomplish this, one machine must be the “Master Record” and the other machine pretends to be that machine with pairing. Not as complicated as it sounds.<br />
<br />
Now pair all of your devices on the “Master Record” machine. The secret link codes are stored at (shhhh!) {{c|/var/lib/bluetooth}} in a directory named with your receivers bluetooth address, let's say {{c|AA:AA:AA:AA:AA:AA}}. After this is done you are ready to start on the Pretender machine. It will fool bluez into thinking that it's bluetooth address is {{c|AA:AA:AA:AA:AA:AA}}, even though it has a different address. Copy the {{c|AA:AA:AA:AA:AA:AA}} directory from {{c|/var/lib/bluetooth}} on the “Master Record” machine to {{c|/var/lib/bluetooth}} on the “Pretender”. The Pretender will now have two directories in /var/lib/bluetooth, {{c|AA:AA:AA:AA:AA:AA}} and it's own receiver's address directory. (Unless you have more than 1 receiver, but let's keep it simple).<br />
<br />
Then simply modify the code in {{c|/home/<username>/bin/bluetooth}}, only the “turn on” section is shown below, because that's all we are changing:<br />
{{file|name=~/bin/bluetooth|lang=bash|body=<br />
... <br />
else<br />
rfkill unblock bluetooth<br />
### add these 4 lines<br />
sleep 2<br />
/usr/bin/bdaddr -i hci0 AA:AA:AA:AA:AA:AA 2&>1>/dev/null #of course, you must change this to "Master Record's" receiver address<br />
/usr/sbin/hciconfig hci0 reset<br />
/etc/init.d/bluetooth restart<br />
### end of addition<br />
BLUETOOTH_STRING=" Bluetooth powered on"<br />
DISPLAY_COLOR="blue"<br />
...<br />
}}<br />
And that's it! Now both machines will use the same headsets and you won't constantly have to re-pair. When the Pretender bluetooth is toggled on it has the other machines bluetooth address for it's receiver. Note that I always start my bluetooth powered off, so it always starts in pretend mode, if you start with yours powered on it won't spoof the other address until you toggle it off & then on unless you add the above code to your /etc/local.d/*.start file as well.<br />
<br />
The only caveat is I'm not sure what would ever happen if I had both bluetooth receivers on at the same time and turned on a headset. But far short of a nuclear meltdown I'm sure, I suspect one machine would grab the headset before the other? Anyhow, with hotkey controlled bluetooth it's never been an issue.<br />
<br />
[[Category:Hardware]]<br />
[[Category:HOWTO]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Benchmarking&diff=10505Benchmarking2015-06-24T12:26:59Z<p>Duncan.britton: Removed some extra spaces at the bottom of the new console templates.</p>
<hr />
<div>== Power usage ==<br />
{{c|sys-power/powertop}} can estimate the computer's current power usage in watts. You have to be on battery power for watt usage to show up.<br />
{{console|body=<br />
###i## powertop<br />
Power usage (ACPI estimate): 15.7W (0.5 hours)<br />
}}<br />
== CPU ==<br />
=== Compiler performance ===<br />
{{console|body=<br />
###i## time emerge -1 coreutils<br />
real 2m17.574s<br />
user 1m46.572s<br />
sys 0m53.450s<br />
}}<br />
== RAM ==<br />
=== ramspeed ===<br />
{{console|body=<br />
###i## emerge -av ramspeed<br />
$##bl## ramspeed -b2 -m4 && ramspeed -b1 -m4<br />
INTEGER & READING 2048 Kb block: 5027.82 MB/s<br />
INTEGER & READING 4096 Kb block: 4999.53 MB/s<br />
...<br />
INTEGER & WRITING 2048 Kb block: 2003.86 MB/s<br />
INTEGER & WRITING 4096 Kb block: 1951.05 MB/s<br />
}}<br />
== Hard drive ==<br />
=== hdparm ===<br />
{{console|body=<br />
###i## hdparm -tT /dev/sda<br />
/dev/sda:<br />
Timing cached reads: 2318 MB in 2.00 seconds = 1159.52 MB/sec<br />
Timing buffered disk reads: 648 MB in 3.00 seconds = 215.92 MB/sec<br />
}}<br />
=== dd ===<br />
{{console|body=<br />
$##bl## dd bs=1M count=512 if=/dev/zero of=temp conv=fdatasync<br />
###i## echo 3 > /proc/sys/vm/drop_caches<br />
$##bl## dd bs=1M count=512 if=temp of=/dev/null<br />
536870912 bytes (537 MB) copied, 3.13319 s, 171 MB/s<br />
..<br />
536870912 bytes (537 MB) copied, 2.17444 s, 247 MB/s<br />
$##bl## rm temp<br />
}}<br />
== GPU ==<br />
=== Warsow ===<br />
==== Install ====<br />
{{console|body=<br />
###i## emerge -av warsow<br />
$##bl## mkdir -p ~/.warsow-1.0/basewsw/demos<br />
$##bl## cd ~/.warsow-1.0/basewsw/demos<br />
$##bl## wget http://www.phoronix-test-suite.com/benchmark-files/pts-warsow-10-1.zip<br />
$##bl## unzip pts-warsow-10-1.zip<br />
}}<br />
==== Benchmark ====<br />
{{console|body=<br />
$##bl## warsow +exec profiles/high+.cfg +timedemo 1 +cg_showFPS 1 +cl_maxfps 999 +demo pts-demo10 +next "quit" +r_mode -1<br />
899 frames, 76.4 seconds: 11.8 fps<br />
}}<br />
=== Nexuiz ===<br />
{{console|body=<br />
###i## emerge -av nexuiz<br />
$##bl## nexuiz-glx -benchmark demos/demo1 -nosound 2>&1 {{!}} egrep -e '[0-9]+ frames'<br />
1910 frames 42.0330749 seconds 45.4404063 fps, one-second fps min/avg/max: 35 46 63 (90 seconds)<br />
}}<br />
=== Xonotic ===<br />
{{console|body=<br />
###i## emerge -av xonotic<br />
$##bl## xonotic-glx -benchmark demos/the-big-keybench 2>&1 {{!}} egrep -e '[0-9]+ frames'<br />
12568 frames 556.0637400 seconds 22.6017255 fps, one-second fps min/avg/max: 19 23 27 (207 seconds)<br />
}}<br />
=== Glxgears ===<br />
Note: glxgears is a very basic OpenGL support test, it is not a real benchmark tool!<br />
{{console|body=<br />
###i## emerge -av mesa-progs<br />
$##bl## vblank_mode=0 glxgears<br />
1583 frames in 5.0 seconds = 316.485 FPS<br />
}}<br />
<br />
[[Category:HOWTO]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Benchmarking&diff=10504Benchmarking2015-06-24T12:26:19Z<p>Duncan.britton: Updated the <code> and <console> tags on the page to {{c}} and {{console}} templates.</p>
<hr />
<div>== Power usage ==<br />
{{c|sys-power/powertop}} can estimate the computer's current power usage in watts. You have to be on battery power for watt usage to show up.<br />
{{console|body=<br />
###i## powertop<br />
Power usage (ACPI estimate): 15.7W (0.5 hours)<br />
}}<br />
<br />
== CPU ==<br />
=== Compiler performance ===<br />
{{console|body=<br />
###i## time emerge -1 coreutils<br />
real 2m17.574s<br />
user 1m46.572s<br />
sys 0m53.450s<br />
}}<br />
<br />
== RAM ==<br />
=== ramspeed ===<br />
{{console|body=<br />
###i## emerge -av ramspeed<br />
$##bl## ramspeed -b2 -m4 && ramspeed -b1 -m4<br />
INTEGER & READING 2048 Kb block: 5027.82 MB/s<br />
INTEGER & READING 4096 Kb block: 4999.53 MB/s<br />
...<br />
INTEGER & WRITING 2048 Kb block: 2003.86 MB/s<br />
INTEGER & WRITING 4096 Kb block: 1951.05 MB/s<br />
}}<br />
<br />
== Hard drive ==<br />
=== hdparm ===<br />
{{console|body=<br />
###i## hdparm -tT /dev/sda<br />
/dev/sda:<br />
Timing cached reads: 2318 MB in 2.00 seconds = 1159.52 MB/sec<br />
Timing buffered disk reads: 648 MB in 3.00 seconds = 215.92 MB/sec<br />
}}<br />
<br />
=== dd ===<br />
{{console|body=<br />
$##bl## dd bs=1M count=512 if=/dev/zero of=temp conv=fdatasync<br />
###i## echo 3 > /proc/sys/vm/drop_caches<br />
$##bl## dd bs=1M count=512 if=temp of=/dev/null<br />
536870912 bytes (537 MB) copied, 3.13319 s, 171 MB/s<br />
..<br />
536870912 bytes (537 MB) copied, 2.17444 s, 247 MB/s<br />
$##bl## rm temp<br />
}}<br />
<br />
== GPU ==<br />
=== Warsow ===<br />
==== Install ====<br />
{{console|body=<br />
###i## emerge -av warsow<br />
$##bl## mkdir -p ~/.warsow-1.0/basewsw/demos<br />
$##bl## cd ~/.warsow-1.0/basewsw/demos<br />
$##bl## wget http://www.phoronix-test-suite.com/benchmark-files/pts-warsow-10-1.zip<br />
$##bl## unzip pts-warsow-10-1.zip<br />
}}<br />
==== Benchmark ====<br />
{{console|body=<br />
$##bl## warsow +exec profiles/high+.cfg +timedemo 1 +cg_showFPS 1 +cl_maxfps 999 +demo pts-demo10 +next "quit" +r_mode -1<br />
899 frames, 76.4 seconds: 11.8 fps<br />
}}<br />
<br />
=== Nexuiz ===<br />
{{console|body=<br />
###i## emerge -av nexuiz<br />
$##bl## nexuiz-glx -benchmark demos/demo1 -nosound 2>&1 {{!}} egrep -e '[0-9]+ frames'<br />
1910 frames 42.0330749 seconds 45.4404063 fps, one-second fps min/avg/max: 35 46 63 (90 seconds)<br />
}}<br />
<br />
=== Xonotic ===<br />
{{console|body=<br />
###i## emerge -av xonotic<br />
$##bl## xonotic-glx -benchmark demos/the-big-keybench 2>&1 {{!}} egrep -e '[0-9]+ frames'<br />
12568 frames 556.0637400 seconds 22.6017255 fps, one-second fps min/avg/max: 19 23 27 (207 seconds)<br />
}}<br />
<br />
=== Glxgears ===<br />
Note: glxgears is a very basic OpenGL support test, it is not a real benchmark tool!<br />
{{console|body=<br />
###i## emerge -av mesa-progs<br />
$##bl## vblank_mode=0 glxgears<br />
1583 frames in 5.0 seconds = 316.485 FPS<br />
}}<br />
<br />
[[Category:HOWTO]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Xfce4-meta&diff=10503Package:Xfce4-meta2015-06-24T12:14:54Z<p>Duncan.britton: Removed a link to a deleted page.</p>
<hr />
<div>{{Ebuild<br />
|Summary=Meta package for XFCE desktop<br />
|CatPkg=xfce-base/xfce4-meta<br />
|Maintainer=Oleg<br />
}}<br />
== About Xfce ==<br />
<blockquote><br />
Xfce is a lightweight desktop environment for UNIX-like operating systems. It aims to be fast and low on system resources, while still being visually appealing and user friendly.<br />
<br />
Xfce embodies the traditional UNIX philosophy of modularity and re-usability. It consists of a number of components that provide the full functionality one can expect of a modern desktop environment. They are packaged separately and you can pick among the available packages to create the optimal personal working environment.<br />
<br />
Another priority of Xfce is adhereance to standards, specifically those defined at [http://freedesktop.org/ freedesktop.org]. [[http://www.xfce.org/about/ About XFCE]]<br />
</blockquote><br />
== Installation ==<br />
<br />
Before emerging Xfce you need to:<br />
<br />
Check that you have enabled the USE flags necessary for a XFCE desktop environment. Set your profile to "xfce" via [[Funtoo_Linux_First_Steps#Changing_profile|mix-ins]], as follows:<br />
{{console|body=<br />
###i## epro mix-ins +xfce<br />
}}<br />
Then, verify that you have the [[Funtoo_Linux_First_Steps#X.Org|X.Org Server]] configured properly. If X.Org is installed on your system, you are now ready to install Xfce. Install the meta-package, which pulls in all of the components you need for a minimal Xfce installation:<br />
<br />
{{console|body=<br />
###i## emerge xfce4-meta<br />
}}<br />
== Running Xfce ==<br />
<br />
There are several different ways to start Xfce:<br />
<br />
* Editing the {{c|.xinitrc}} file in your user's home directory and using {{c|startx}} from a text console.<br />
* Using a display manager (e.g. SLiM, GDM, and KDM).<br />
* Configuring your shell profile to automatically start Xfce upon a successful login.<br />
=== .xinitrc ===<br />
<br />
The most common way to start the environment is to configure {{c|~/.xinitrc}} to launch an Xfce session. The proper way to launch Xfce from the terminal is by using {{c|startxfce4}} combined with {{c|ck-launch-session}}.<br />
<br />
{{console|body=<br />
$##i## echo "exec startxfce4 --with-ck-launch" > ~/.xinitrc<br />
}}<br />
Note that {{c|--with-ck-launch}} (from ConsoleKit) is required by Xfce for important tasks such as shutting down, suspending, and automatically mounting removable storage media. Some applications will not work properly without it. Also, configuring the GTK+ theme and other forms of theming through {{Package|Xfce4-settings}} do not often work without the {{c|--with-ck-launch}} command line option. Because we are launching XFCE with a consolekit command line option, we need to add ConsoleKit to the {{c|default}} runlevel, executing the following command as root:<br />
<br />
{{console|body=<br />
###i## rc-update add consolekit default<br />
###i## rc<br />
}}<br />
Finally, to start the graphical environment, run {{c|startx}} from a login shell:<br />
<br />
{{console|body=<br />
$##i## startx<br />
}}<br />
After running this command, you should be greeted by your shiny new XFCE desktop. For more information about configuring XFCE and some of the default applications that come with it, consider looking at [[Package:xfce4-meta#XFCE configuration and XFCE applications|XFCE configuration and XFCE applications]].<br />
== Display Manager ==<br />
<br />
A display manager is a program that manages sessions and acts as a login screen. Here's a short list of a few of the display managers available from the Funtoo repositories:<br />
* XDM ({{c|x11-apps/xdm}}): X.Org's standard display manager.<br />
* LightDM ({{c|x11-misc/lightdm}}): A lightweight, but highly configurable display manager.<br />
* SLiM ({{c|x11-misc/slim}}): Simple Login Manager -- a lightweight display manager. Not very configurable.<br />
<br />
<br />
Any of these would make a fine choice. After you've chosen which display manager to use, install it:<br />
<br />
{{console|body=###i## emerge <display manager of choice>}}<br />
All that's left to do now is to add the name of the display manager to {{c|/etc/conf.d/xdm}}, add the {{c|xdm}} service and the {{c|dbus}} service to the {{c|default}} runlevel, and start the services:<br />
<br />
{{file|name=/etc/conf.d/xdm|desc=|body=<br />
DISPLAYMANAGER="<display manager name>"<br />
}}<br />
<br />
{{console|body=<br />
###i## rc-update add xdm default<br />
###i## rc-update add dbus default<br />
###i## rc<br />
}}<br />
==Power Group==<br />
If you wish to be able to shutdown/reboot/suspend/hibernate using xfce4-logout-session then you will need to add yourself or the user to the power group by:<br />
<br />
{{console|body=<br />
###i## gpasswd -a <username> power<br />
}}<br />
If the group does not exist then execute the following and try again:<br />
<br />
{{console|body=<br />
###i## groupadd power}}<br />
== XFCE configuration and XFCE applications ==<br />
For more information on configuring XFCE and the default applications provided by XFCE, such as {{c|xfce4-terminal}}, consider following some of the below listed links:<br />
* [[Package:Xfce4-settings|GUI settings configuration for XFCE]]<br />
* [[Package:Xfce4-terminal|The default terminal emulator for XFCE]]<br />
* [[XFCE Panel Plugins|A list of the various plugins available for {{c|xfce4-panel}}]]<br />
* [[Thunar Plugins|A list of the plugins available for the Thunar file manager]]<br />
<br />
[[Category:Desktop]]<br />
[[Category:First Steps]]<br />
[[Category:Official Documentation]]<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Xfce4-settings&diff=10501Package:Xfce4-settings2015-06-23T22:47:53Z<p>Duncan.britton: Fixed a {{c}} issue</p>
<hr />
<div>{{Ebuild<br />
|Summary=The configuration system for XFCE<br />
|CatPkg=xfce-base/xfce4-settings<br />
|Homepage=http://docs.xfce.org/xfce/xfce4-settings/start<br />
}}<br />
{{c|xfce4-settings}} provides two main utilities used to configure key components of the XFCE desktop environment:<br />
* {{c|xfce4-settings-editor}}: Provides a {{c|dconf-editor}}-like interface used to configure components of XFCE ranging from Thunar to the XFCE notification daemon.<br />
* {{c|xfce4-settings-manager}}: Allows users to configure the same components as can be configured in the {{c|xfce4-settings-editor}} but provides a more easy to understand interface for configuration.<br />
<br />
== Installation ==<br />
If you have already installed the XFCE desktop environment using the {{c|xfce4-meta}} package, {{c|xfce4-settings}} should be installed. Also, if you have installed an XFCE program such as thunar in another desktop environment or window manager such as Openbox or KDE, {{c|xfce4-settings}} is probably installed on your system too. If, for some reason, the program is not installed in either of those cases and you wish to emerge it, run the command:<br />
{{console|body=<br />
###i## emerge xfce4-settings<br />
}}<br />
<br />
After the emerge has finished, you can check that the package was successfully installed by running the command {{c|xfce4-settings-manager}} or by launching the program from your dock. If the package did install, you should be greeted with a window titled "Settings" that is divided into several sections with names like "Personal" and "Hardware." If the program does not launch after repeated attempts, consider filing a bug report at [http://bugs.funtoo.org Funtoo Bugs].<br />
<br />
== Usage ==<br />
To run {{c|xfce4-settings-manager}} in XFCE, navigate to the applications menu in your panel, go to "Settings" and then select "Settings Manager." Alternately, you can open your terminal emulator and type "xfce4-settings-manager" and press enter to launch the program. In other desktop environments, launch the program as you would any other.<br />
<br />
=== Appearance ({{c|xfce4-appearance-settings}}) ===<br />
==== Style ====<br />
After clicking on the "Appearance" subsection in the section "Personal," you will find yourself in a tab titled "Style." This tab allows you to select the GTK+ theme that you would like to use from a list of themes that are currently installed in either {{c|/usr/share/themes}} or {{c|~/.themes}}. The three colored boxes to the left of the theme name show the theme's colors. To select a GTK+ theme as default, simply click on it and your theme will change immediately. <br />
{{note|If the theme does not change when clicked, double check to see that you are launching XFCE with the {{c|--with-ck-launch parameter}}. Theming using {{c|xfce4-settings-manager}} does not seem to work without it.}}<br />
<br />
==== Icons ====<br />
To select the default icon theme for XFCE, click on the tab with the text "Icons." This tab, not surprisingly, allows you to edit your icon theme. To change your icon theme, click on the one that you like and the theme will change immediately. If it does not, read the above note.<br />
{{tip|To install new icon themes, extract an icon theme to either {{c|/usr/share/icons}} (for every user on the system) or to {{c|~/.icons}} (for just you).}}<br />
<br />
==== Fonts ====<br />
To change the default font, the DPI value of the current font, or to enable font anti-aliasing, click on the "Fonts" tab. The default font can be changed quite easily by selecting the box under "Default Font." Selecting this box will bring up a list of all the different font families that are currently installed on your system, along with the available styles for each font family. To change your font, choose the appropriate font family, style, and size and the click the button labeled "OK" at the bottom right of the window. Your font should change immediately. If it does not, the above note may help to solve the problem. A nice default font is "Ubuntu Regular 10," provided by the {{c|ubuntu-font-family}} package which can easily be installed using the following command:<br />
{{console|body=<br />
###i## emerge ubuntu-font-family<br />
}}<br />
If you are unhappy with the scaling of the fonts in XFCE, perhaps because you are using a hiDPI display, consider increasing the value next to "Custom DPI setting." Finally, to make many fonts appear more crisp and well-defined, increase the value in "Hinting" to "Medium" or "Full."<br />
<br />
==== Settings ====<br />
If you do not like having images in menus or buttons or you would like to change the way that toolbars are displayed, navigate to the "Settings" tab. To modify how toolbars appear in GTK+ applications, modify the "Toolbar Style" dropdown to your pleasing. Here is what the different toolbar styles look like:<br />
<br />
{{TableStart}}<br />
<tr class="info"><th>Style</th><th>Preview</th></tr><br />
<tr><td>Icons</td><td>[[File:xfce4-settings_toolbar_icons.png]]</td></tr><br />
<tr><td>Text</td><td>[[File:xfce4-settings_toolbar_text.png]]</td></tr><br />
<tr><td>Text under icons</td><td>[[File:xfce4-settings_toolbar_text_under_icons.png]]</td></tr><br />
{{TableEnd}}<br />
To add or remove images on GTK+ buttons, check or uncheck the checkbox adjacent to "Show images on buttons." To remove those ''pesky'' little icons in menus, uncheck "Show images in menus."<br />
<br />
=== Desktop ({{c|xfdesktop-settings}}) ===<br />
The desktop section of {{c|xfce4-settings}} is, not surprisingly, focused on the customization of the XFCE desktop. It includes options to customize the wallpaper, desktop icons, and desktop menus.<br />
<br />
==== Background ====<br />
The first tab of the desktop section is titled "Background." This tab provides configuration options for the wallpaper of your XFCE desktop. To change the wallpaper for the current desktop, take note of the directory in which you have stored the image that you want to set as your wallpaper {{c|~/Pictures/Wallpapers/}}, for example. Then, click the box next to "Folder" in the bottom of the Background tab. When you click this box, you will get a menu displaying some directories where your photos could be located. If the picture you wish to use is not in any of the listed directories, select "Other..." and a dialog called "select a file will open." Now, navigate to the parent directory of the directory in which your wallpapers are stored ({{c|~/Pictures}} in my case) and click on the icon for that directory (should be called {{c|Wallpapers}} for me). After selecting that directory, click "Open" in the bottom right of the "Select a file" dialog. Now you should be able to choose the wallpaper that you wanted from the "Wallpaper for my desktop" box in the Background tab. To change to that wallpaper, simply click on the image of the desired wallpaper and your background should change immediately. <br />
<br />
==== Menus ====<br />
The "Menus" tab controls the appearance of menus that appear on your desktop when you right and middle click. <br />
<br />
==== Icons ====<br />
Clicking on the tab labeled "Icons" allows you to customize the appearance of desktop icons. If you do not like having icons on your desktop and have struggled to find a way to remove the "Home," "Filesystem," and "Trash" icons from your desktop, you're in luck! Go to the bottom of the configuration dialog and uncheck all of the boxes in the "Default Icons" box. One by one, those pesky little icons will fade away into the nothingness that they deserve. Conversely, if you love desktop icons, you can always add more by right clicking on your desktop and selecting the appropriate "Create *" option in the menu that appears.<br />
<br />
To remove the large tooltips that appear when you hover over an icon on your desktop, uncheck the box "Show icon tooltips" in {{c|xfce4-settings}}. You can also shrink the size of the tooltip icon, and hence the tooltip itself, by decreasing the value in the box next to "Size:"<br />
<br />
{{warning|The rest of this page is still 'under construction.'}}<br />
=== Panel ({{c|xfce4-panel --preferences}}) ===<br />
The panel section provides an interface to easily configure {{c|xfce4-panel}}. <br />
==== Display ====<br />
The display subsection provides for configuration of panel position, size, location, and autohiding. To select the panel to configure, select the dropdown menu at the top of the page and select the appropriate panel. New panels can be added by clicking the plus button and existing panels can be removed by clicking the button marked with "X". To move a panel to a different part of the screen, uncheck the "Lock panel" checkbox and drag the menu by the handles that appear on the left and right ends of the panel to the desired new location of the panel, and the re-check the "Lock panel" checkbox. To make a panel hide all of the time, select the "Automatically hide the panel" menu and select "Always." Selecting this option hides the panel unless a mouse hovers over the place it is hidden. To make a panel hide only when a window covers it, select the "Intelligently" option. The rest of the settings in this tab seem self-explanatory.<br />
<br />
==== Appearance ====<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Xfce4-settings&diff=10500Package:Xfce4-settings2015-06-23T22:47:25Z<p>Duncan.britton: Began working on the Panel section</p>
<hr />
<div>{{Ebuild<br />
|Summary=The configuration system for XFCE<br />
|CatPkg=xfce-base/xfce4-settings<br />
|Homepage=http://docs.xfce.org/xfce/xfce4-settings/start<br />
}}<br />
{{c|xfce4-settings}} provides two main utilities used to configure key components of the XFCE desktop environment:<br />
* {{c|xfce4-settings-editor}}: Provides a {{c|dconf-editor}}-like interface used to configure components of XFCE ranging from Thunar to the XFCE notification daemon.<br />
* {{c|xfce4-settings-manager}}: Allows users to configure the same components as can be configured in the {{c|xfce4-settings-editor}} but provides a more easy to understand interface for configuration.<br />
<br />
== Installation ==<br />
If you have already installed the XFCE desktop environment using the {{c|xfce4-meta}} package, {{c|xfce4-settings}} should be installed. Also, if you have installed an XFCE program such as thunar in another desktop environment or window manager such as Openbox or KDE, {{c|xfce4-settings}} is probably installed on your system too. If, for some reason, the program is not installed in either of those cases and you wish to emerge it, run the command:<br />
{{console|body=<br />
###i## emerge xfce4-settings<br />
}}<br />
<br />
After the emerge has finished, you can check that the package was successfully installed by running the command {{c|xfce4-settings-manager}} or by launching the program from your dock. If the package did install, you should be greeted with a window titled "Settings" that is divided into several sections with names like "Personal" and "Hardware." If the program does not launch after repeated attempts, consider filing a bug report at [http://bugs.funtoo.org Funtoo Bugs].<br />
<br />
== Usage ==<br />
To run {{c|xfce4-settings-manager}} in XFCE, navigate to the applications menu in your panel, go to "Settings" and then select "Settings Manager." Alternately, you can open your terminal emulator and type "xfce4-settings-manager" and press enter to launch the program. In other desktop environments, launch the program as you would any other.<br />
<br />
=== Appearance ({{c|xfce4-appearance-settings}}) ===<br />
==== Style ====<br />
After clicking on the "Appearance" subsection in the section "Personal," you will find yourself in a tab titled "Style." This tab allows you to select the GTK+ theme that you would like to use from a list of themes that are currently installed in either {{c|/usr/share/themes}} or {{c|~/.themes}}. The three colored boxes to the left of the theme name show the theme's colors. To select a GTK+ theme as default, simply click on it and your theme will change immediately. <br />
{{note|If the theme does not change when clicked, double check to see that you are launching XFCE with the {{c|--with-ck-launch parameter}}. Theming using {{c|xfce4-settings-manager}} does not seem to work without it.}}<br />
<br />
==== Icons ====<br />
To select the default icon theme for XFCE, click on the tab with the text "Icons." This tab, not surprisingly, allows you to edit your icon theme. To change your icon theme, click on the one that you like and the theme will change immediately. If it does not, read the above note.<br />
{{tip|To install new icon themes, extract an icon theme to either {{c|/usr/share/icons}} (for every user on the system) or to {{c|~/.icons}} (for just you).}}<br />
<br />
==== Fonts ====<br />
To change the default font, the DPI value of the current font, or to enable font anti-aliasing, click on the "Fonts" tab. The default font can be changed quite easily by selecting the box under "Default Font." Selecting this box will bring up a list of all the different font families that are currently installed on your system, along with the available styles for each font family. To change your font, choose the appropriate font family, style, and size and the click the button labeled "OK" at the bottom right of the window. Your font should change immediately. If it does not, the above note may help to solve the problem. A nice default font is "Ubuntu Regular 10," provided by the {{c|ubuntu-font-family}} package which can easily be installed using the following command:<br />
{{console|body=<br />
###i## emerge ubuntu-font-family<br />
}}<br />
If you are unhappy with the scaling of the fonts in XFCE, perhaps because you are using a hiDPI display, consider increasing the value next to "Custom DPI setting." Finally, to make many fonts appear more crisp and well-defined, increase the value in "Hinting" to "Medium" or "Full."<br />
<br />
==== Settings ====<br />
If you do not like having images in menus or buttons or you would like to change the way that toolbars are displayed, navigate to the "Settings" tab. To modify how toolbars appear in GTK+ applications, modify the "Toolbar Style" dropdown to your pleasing. Here is what the different toolbar styles look like:<br />
<br />
{{TableStart}}<br />
<tr class="info"><th>Style</th><th>Preview</th></tr><br />
<tr><td>Icons</td><td>[[File:xfce4-settings_toolbar_icons.png]]</td></tr><br />
<tr><td>Text</td><td>[[File:xfce4-settings_toolbar_text.png]]</td></tr><br />
<tr><td>Text under icons</td><td>[[File:xfce4-settings_toolbar_text_under_icons.png]]</td></tr><br />
{{TableEnd}}<br />
To add or remove images on GTK+ buttons, check or uncheck the checkbox adjacent to "Show images on buttons." To remove those ''pesky'' little icons in menus, uncheck "Show images in menus."<br />
<br />
=== Desktop ({{c|xfdesktop-settings}}) ===<br />
The desktop section of {{c|xfce4-settings}} is, not surprisingly, focused on the customization of the XFCE desktop. It includes options to customize the wallpaper, desktop icons, and desktop menus.<br />
<br />
==== Background ====<br />
The first tab of the desktop section is titled "Background." This tab provides configuration options for the wallpaper of your XFCE desktop. To change the wallpaper for the current desktop, take note of the directory in which you have stored the image that you want to set as your wallpaper {{c|~/Pictures/Wallpapers/}}, for example. Then, click the box next to "Folder" in the bottom of the Background tab. When you click this box, you will get a menu displaying some directories where your photos could be located. If the picture you wish to use is not in any of the listed directories, select "Other..." and a dialog called "select a file will open." Now, navigate to the parent directory of the directory in which your wallpapers are stored ({{c|~/Pictures}} in my case) and click on the icon for that directory (should be called {{c|Wallpapers}} for me). After selecting that directory, click "Open" in the bottom right of the "Select a file" dialog. Now you should be able to choose the wallpaper that you wanted from the "Wallpaper for my desktop" box in the Background tab. To change to that wallpaper, simply click on the image of the desired wallpaper and your background should change immediately. <br />
<br />
==== Menus ====<br />
The "Menus" tab controls the appearance of menus that appear on your desktop when you right and middle click. <br />
<br />
==== Icons ====<br />
Clicking on the tab labeled "Icons" allows you to customize the appearance of desktop icons. If you do not like having icons on your desktop and have struggled to find a way to remove the "Home," "Filesystem," and "Trash" icons from your desktop, you're in luck! Go to the bottom of the configuration dialog and uncheck all of the boxes in the "Default Icons" box. One by one, those pesky little icons will fade away into the nothingness that they deserve. Conversely, if you love desktop icons, you can always add more by right clicking on your desktop and selecting the appropriate "Create *" option in the menu that appears.<br />
<br />
To remove the large tooltips that appear when you hover over an icon on your desktop, uncheck the box "Show icon tooltips" in {{c|xfce4-settings}}. You can also shrink the size of the tooltip icon, and hence the tooltip itself, by decreasing the value in the box next to "Size:"<br />
<br />
{{warning|The rest of this page is still 'under construction.'}}<br />
=== Panel ({{c|xfce4-panel --preferences}) ===<br />
The panel section provides an interface to easily configure {{c|xfce4-panel}}. <br />
==== Display ====<br />
The display subsection provides for configuration of panel position, size, location, and autohiding. To select the panel to configure, select the dropdown menu at the top of the page and select the appropriate panel. New panels can be added by clicking the plus button and existing panels can be removed by clicking the button marked with "X". To move a panel to a different part of the screen, uncheck the "Lock panel" checkbox and drag the menu by the handles that appear on the left and right ends of the panel to the desired new location of the panel, and the re-check the "Lock panel" checkbox. To make a panel hide all of the time, select the "Automatically hide the panel" menu and select "Always." Selecting this option hides the panel unless a mouse hovers over the place it is hidden. To make a panel hide only when a window covers it, select the "Intelligently" option. The rest of the settings in this tab seem self-explanatory.<br />
<br />
==== Appearance ====<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Xfce4-meta&diff=10498Package:Xfce4-meta2015-06-23T22:10:06Z<p>Duncan.britton: __FORCETOC__ didn't seem to work...removing it.</p>
<hr />
<div>{{Ebuild<br />
|Summary=Meta package for XFCE desktop<br />
|CatPkg=xfce-base/xfce4-meta<br />
|Maintainer=Oleg<br />
}}<br />
== About Xfce ==<br />
<blockquote><br />
Xfce is a lightweight desktop environment for UNIX-like operating systems. It aims to be fast and low on system resources, while still being visually appealing and user friendly.<br />
<br />
Xfce embodies the traditional UNIX philosophy of modularity and re-usability. It consists of a number of components that provide the full functionality one can expect of a modern desktop environment. They are packaged separately and you can pick among the available packages to create the optimal personal working environment.<br />
<br />
Another priority of Xfce is adhereance to standards, specifically those defined at [http://freedesktop.org/ freedesktop.org]. [[http://www.xfce.org/about/ About XFCE]]<br />
</blockquote><br />
== Installation ==<br />
<br />
Before emerging Xfce you need to:<br />
<br />
Check that you have enabled the USE flags necessary for a XFCE desktop environment. Set your profile to "xfce" via [[Funtoo_Linux_First_Steps#Changing_profile|mix-ins]], as follows:<br />
{{console|body=<br />
###i## epro mix-ins +xfce<br />
}}<br />
Then, verify that you have the [[Funtoo_Linux_First_Steps#X.Org|X.Org Server]] configured properly. If X.Org is installed on your system, you are now ready to install Xfce. Install the meta-package, which pulls in all of the components you need for a minimal Xfce installation:<br />
<br />
{{console|body=<br />
###i## emerge xfce4-meta<br />
}}<br />
== Running Xfce ==<br />
<br />
There are several different ways to start Xfce:<br />
<br />
* Editing the {{c|.xinitrc}} file in your user's home directory and using {{c|startx}} from a text console.<br />
* Using a display manager (e.g. SLiM, GDM, and KDM).<br />
* Configuring your shell profile to automatically start Xfce upon a successful login.<br />
=== .xinitrc ===<br />
<br />
The most common way to start the environment is to configure {{c|~/.xinitrc}} to launch an Xfce session. The proper way to launch Xfce from the terminal is by using {{c|startxfce4}} combined with {{c|ck-launch-session}}.<br />
<br />
{{console|body=<br />
$##i## echo "exec startxfce4 --with-ck-launch" > ~/.xinitrc<br />
}}<br />
Note that {{c|--with-ck-launch}} (from ConsoleKit) is required by Xfce for important tasks such as shutting down, suspending, and automatically mounting removable storage media. Some applications will not work properly without it. Also, configuring the GTK+ theme and other forms of theming through {{Package|Xfce4-settings}} do not often work without the {{c|--with-ck-launch}} command line option. Because we are launching XFCE with a consolekit command line option, we need to add ConsoleKit to the {{c|default}} runlevel, executing the following command as root:<br />
<br />
{{console|body=<br />
###i## rc-update add consolekit default<br />
###i## rc<br />
}}<br />
Finally, to start the graphical environment, run {{c|startx}} from a login shell:<br />
<br />
{{console|body=<br />
$##i## startx<br />
}}<br />
After running this command, you should be greeted by your shiny new XFCE desktop. For more information about configuring XFCE and some of the default applications that come with it, consider looking at [[Package:xfce4-meta#XFCE configuration and XFCE applications|XFCE configuration and XFCE applications]].<br />
== Display Manager ==<br />
<br />
A display manager is a program that manages sessions and acts as a login screen. Here's a short list of a few of the display managers available from the Funtoo repositories:<br />
* XDM ({{c|x11-apps/xdm}}): X.Org's standard display manager.<br />
* LightDM ({{c|x11-misc/lightdm}}): A lightweight, but highly configurable display manager.<br />
* SLiM ({{c|x11-misc/slim}}): Simple Login Manager -- a lightweight display manager. Not very configurable.<br />
<br />
<br />
Any of these would make a fine choice. After you've chosen which display manager to use, install it:<br />
<br />
{{console|body=###i## emerge <display manager of choice>}}<br />
All that's left to do now is to add the name of the display manager to {{c|/etc/conf.d/xdm}}, add the {{c|xdm}} service and the {{c|dbus}} service to the {{c|default}} runlevel, and start the services:<br />
<br />
{{file|name=/etc/conf.d/xdm|desc=|body=<br />
DISPLAYMANAGER="<display manager name>"<br />
}}<br />
<br />
{{console|body=<br />
###i## rc-update add xdm default<br />
###i## rc-update add dbus default<br />
###i## rc<br />
}}<br />
==Power Group==<br />
If you wish to be able to shutdown/reboot/suspend/hibernate using xfce4-logout-session then you will need to add yourself or the user to the power group by:<br />
<br />
{{console|body=<br />
###i## gpasswd -a <username> power<br />
}}<br />
If the group does not exist then execute the following and try again:<br />
<br />
{{console|body=<br />
###i## groupadd power}}<br />
== XFCE configuration and XFCE applications ==<br />
For more information on configuring XFCE and the default applications provided by XFCE, such as {{c|xfce4-terminal}}, consider following some of the below listed links:<br />
* [[Package:Xfce4-settings|GUI settings configuration for XFCE]]<br />
* [[Package:Xfce4-terminal|The default terminal emulator for XFCE]]<br />
* [[Package:Whiskermenu|An alternate menu for the XFCE panel]]<br />
* [[XFCE Panel Plugins|A list of the various plugins available for {{c|xfce4-panel}}]]<br />
* [[Thunar Plugins|A list of the plugins available for the Thunar file manager]]<br />
<br />
[[Category:Desktop]]<br />
[[Category:First Steps]]<br />
[[Category:Official Documentation]]<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Xfce4-meta&diff=10497Package:Xfce4-meta2015-06-23T22:08:20Z<p>Duncan.britton: testing the __FORCETOC__</p>
<hr />
<div>{{Ebuild<br />
|Summary=Meta package for XFCE desktop<br />
|CatPkg=xfce-base/xfce4-meta<br />
|Maintainer=Oleg<br />
}}<br />
== About Xfce ==<br />
<blockquote><br />
Xfce is a lightweight desktop environment for UNIX-like operating systems. It aims to be fast and low on system resources, while still being visually appealing and user friendly.<br />
<br />
Xfce embodies the traditional UNIX philosophy of modularity and re-usability. It consists of a number of components that provide the full functionality one can expect of a modern desktop environment. They are packaged separately and you can pick among the available packages to create the optimal personal working environment.<br />
<br />
Another priority of Xfce is adhereance to standards, specifically those defined at [http://freedesktop.org/ freedesktop.org]. [[http://www.xfce.org/about/ About XFCE]]<br />
</blockquote><br />
__FORCETOC__<br />
== Installation ==<br />
<br />
Before emerging Xfce you need to:<br />
<br />
Check that you have enabled the USE flags necessary for a XFCE desktop environment. Set your profile to "xfce" via [[Funtoo_Linux_First_Steps#Changing_profile|mix-ins]], as follows:<br />
{{console|body=<br />
###i## epro mix-ins +xfce<br />
}}<br />
Then, verify that you have the [[Funtoo_Linux_First_Steps#X.Org|X.Org Server]] configured properly. If X.Org is installed on your system, you are now ready to install Xfce. Install the meta-package, which pulls in all of the components you need for a minimal Xfce installation:<br />
<br />
{{console|body=<br />
###i## emerge xfce4-meta<br />
}}<br />
== Running Xfce ==<br />
<br />
There are several different ways to start Xfce:<br />
<br />
* Editing the {{c|.xinitrc}} file in your user's home directory and using {{c|startx}} from a text console.<br />
* Using a display manager (e.g. SLiM, GDM, and KDM).<br />
* Configuring your shell profile to automatically start Xfce upon a successful login.<br />
=== .xinitrc ===<br />
<br />
The most common way to start the environment is to configure {{c|~/.xinitrc}} to launch an Xfce session. The proper way to launch Xfce from the terminal is by using {{c|startxfce4}} combined with {{c|ck-launch-session}}.<br />
<br />
{{console|body=<br />
$##i## echo "exec startxfce4 --with-ck-launch" > ~/.xinitrc<br />
}}<br />
Note that {{c|--with-ck-launch}} (from ConsoleKit) is required by Xfce for important tasks such as shutting down, suspending, and automatically mounting removable storage media. Some applications will not work properly without it. Also, configuring the GTK+ theme and other forms of theming through {{Package|Xfce4-settings}} do not often work without the {{c|--with-ck-launch}} command line option. Because we are launching XFCE with a consolekit command line option, we need to add ConsoleKit to the {{c|default}} runlevel, executing the following command as root:<br />
<br />
{{console|body=<br />
###i## rc-update add consolekit default<br />
###i## rc<br />
}}<br />
Finally, to start the graphical environment, run {{c|startx}} from a login shell:<br />
<br />
{{console|body=<br />
$##i## startx<br />
}}<br />
After running this command, you should be greeted by your shiny new XFCE desktop. For more information about configuring XFCE and some of the default applications that come with it, consider looking at [[Package:xfce4-meta#XFCE configuration and XFCE applications|XFCE configuration and XFCE applications]].<br />
== Display Manager ==<br />
<br />
A display manager is a program that manages sessions and acts as a login screen. Here's a short list of a few of the display managers available from the Funtoo repositories:<br />
* XDM ({{c|x11-apps/xdm}}): X.Org's standard display manager.<br />
* LightDM ({{c|x11-misc/lightdm}}): A lightweight, but highly configurable display manager.<br />
* SLiM ({{c|x11-misc/slim}}): Simple Login Manager -- a lightweight display manager. Not very configurable.<br />
<br />
<br />
Any of these would make a fine choice. After you've chosen which display manager to use, install it:<br />
<br />
{{console|body=###i## emerge <display manager of choice>}}<br />
All that's left to do now is to add the name of the display manager to {{c|/etc/conf.d/xdm}}, add the {{c|xdm}} service and the {{c|dbus}} service to the {{c|default}} runlevel, and start the services:<br />
<br />
{{file|name=/etc/conf.d/xdm|desc=|body=<br />
DISPLAYMANAGER="<display manager name>"<br />
}}<br />
<br />
{{console|body=<br />
###i## rc-update add xdm default<br />
###i## rc-update add dbus default<br />
###i## rc<br />
}}<br />
==Power Group==<br />
If you wish to be able to shutdown/reboot/suspend/hibernate using xfce4-logout-session then you will need to add yourself or the user to the power group by:<br />
<br />
{{console|body=<br />
###i## gpasswd -a <username> power<br />
}}<br />
If the group does not exist then execute the following and try again:<br />
<br />
{{console|body=<br />
###i## groupadd power}}<br />
== XFCE configuration and XFCE applications ==<br />
For more information on configuring XFCE and the default applications provided by XFCE, such as {{c|xfce4-terminal}}, consider following some of the below listed links:<br />
* [[Package:Xfce4-settings|GUI settings configuration for XFCE]]<br />
* [[Package:Xfce4-terminal|The default terminal emulator for XFCE]]<br />
* [[Package:Whiskermenu|An alternate menu for the XFCE panel]]<br />
* [[XFCE Panel Plugins|A list of the various plugins available for {{c|xfce4-panel}}]]<br />
* [[Thunar Plugins|A list of the plugins available for the Thunar file manager]]<br />
<br />
[[Category:Desktop]]<br />
[[Category:First Steps]]<br />
[[Category:Official Documentation]]<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Talk:Install&diff=10428Talk:Install2015-06-22T22:31:23Z<p>Duncan.britton: Added a DISQUS to this page.</p>
<hr />
<div>{{DISQUS}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Pianobar&diff=10426Package:Pianobar2015-06-21T22:12:49Z<p>Duncan.britton: Changed the color of the header on the two tables.</p>
<hr />
<div>{{Ebuild<br />
|Summary=Pianobar is a console client for the personalized web radio Pandora.<br />
|CatPkg=media-sound/pianobar<br />
|Homepage=https://github.com/PromyLOPh/pianobar<br />
}}<br />
<blockquote><br />
Pianobar is a console client for the personalized web radio Pandora.<br />
It features the following abilities:<br />
<br />
* Play and manage (create, add more music, delete, rename, etc.) your stations<br />
* Rate played songs and let Pandora explain why they have been selected<br />
* Show upcoming songs and song history<br />
* Configure keybindings<br />
* Last.fm scrobbling support (with the help of an external application)<br />
* Proxy support for listeners outside of the USA [[https://github.com/PromyLOPh/pianobar Homepage]]<br />
</blockquote><br />
<br />
== Install ==<br />
To install Pianobar, emerge it:<br />
{{console|body=<br />
###i## emerge pianobar<br />
}}<br />
== Keyboard shortcuts ==<br />
Pianobar has many shortcuts that allow you to increase or decrease the volume, change station, favorite a song, and many others. The table below includes some of the more commonly used shortcuts.<br />
{{TableStart}}<br />
<tr class="info"><br />
<th>Shortcut</th><br />
<th>Description</th><br />
</tr><tr><br />
<td>+</td><br />
<td>Love the song you are currently listening to. This is equivalent to the "thumbs up" button on Pandora.'</td><br />
</tr><tr><br />
<td>-</td><br />
<td>Give a "thumbs down" to the current song.</td><br />
</tr><tr><br />
<td>p</td><br />
<td>Pause or resume the music.</td><br />
</tr><tr><br />
<td>s</td><br />
<td>Change the station.</td><br />
</tr><tr><br />
<td>)</td><br />
<td>Increase the volume of pianobar.</td><br />
</tr><tr><br />
<td>(</td><br />
<td>Decrease the volume of pianobar.</td><br />
</tr><tr><br />
</tr><br />
{{TableEnd}}<br />
<br />
{{note|All of Pianobar's shortcuts can be listed by typing {{c|?}} when running pianobar.}}<br />
<br />
== Pianobar configuration ==<br />
=== Easy login ===<br />
After you have emerged Pianobar, you can run it with <code>pianobar</code>. If you dislike typing your username and password every time that you run pianobar, create the file <code>~/.config/pianobar/config</code> and add the following lines to it:<br />
{{file|name= ~/.config/pianobar/config|desc= |body=<br />
password = YOURPASSWORD<br />
user = user@email.com<br />
}}<br />
<br />
=== Easy login (with encryption) ===<br />
If leaving a plaintext password for your Pandora account somewhere on your filesystem makes you nervous, you can use gpg to decrypt a file that contains your password. Change your configuration to reflect the one below if you would like to encrypt your password:<br />
{{file|name=~/.config/pianobar/config|desc= |body=<br />
password_command = gpg --decrypt ~/.passwords/pianobar<br />
user = user@email.com<br />
}}<br />
<br />
=== Keybindings ===<br />
To configure keybindings, check out {{c|man pianobar}}. All keybindings can be added to {{c|~/.config/pianobar/config}}. All the keybindings in the man page will begin with the line {{c|act_}}.<br />
<br />
=== Other configuration options ===<br />
{{TableStart}}<br />
<tr class="info"><br />
<th>Option</th><br />
<th>Description</th><br />
</tr><tr><br />
<td>audio_quality</td><br />
<td>The quality of the audio. Can be set to: high, medium, or low.</td><br />
</tr><tr><br />
<td>autostart_station</td><br />
<td>Select a station ID that you would like to play when Pianobar starts.</td><br />
</tr><tr><br />
<td>proxy</td><br />
<td>Use an http proxy to connect to Pandora.</td><br />
</tr><tr><br />
</tr><br />
{{TableEnd}}<br />
<br />
== Troubleshooting ==<br />
=== {{c|ao_alsa WARNING}} message ===<br />
The {{c|ao_alsa WARNING: Unable to open surround playback. Trying default device}} message is often associated with the use of Pulseaudio. To resolve this warning message, edit {{c|/etc/libao.conf}} (you may have to create the file if it does not exist on your system):<br />
{{file|name=/etc/libao.conf|desc=|body=<br />
default_driver=pulse<br />
}}<br />
After a restart of Pianobar, the warning messages should not be displayed anymore.<br />
<br />
=== Not compiled with threads support ===<br />
If you recieve the following warning message ({{c|[aac @ 0x7faccc003cd0] Warning: not compiled with thread support, using thread emulation}}) while running Pianobar, add threads support to {{c|ffmpeg}}, then rebuild it:<br />
{{console|body=<br />
###i## echo "media-video/ffmpeg threads" > /etc/portage/package.use/ffmpeg<br />
###i## emerge ffmpeg<br />
}}<br />
{{note|As of [https://bugs.funtoo.org/browse/FL-1437 FL-1437], threads support should be enabled on ffmpeg by default.}}<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Pianobar&diff=10425Package:Pianobar2015-06-21T22:11:30Z<p>Duncan.britton: Removed two bothersome extra spaces.</p>
<hr />
<div>{{Ebuild<br />
|Summary=Pianobar is a console client for the personalized web radio Pandora.<br />
|CatPkg=media-sound/pianobar<br />
|Homepage=https://github.com/PromyLOPh/pianobar<br />
}}<br />
<blockquote><br />
Pianobar is a console client for the personalized web radio Pandora.<br />
It features the following abilities:<br />
<br />
* Play and manage (create, add more music, delete, rename, etc.) your stations<br />
* Rate played songs and let Pandora explain why they have been selected<br />
* Show upcoming songs and song history<br />
* Configure keybindings<br />
* Last.fm scrobbling support (with the help of an external application)<br />
* Proxy support for listeners outside of the USA [[https://github.com/PromyLOPh/pianobar Homepage]]<br />
</blockquote><br />
<br />
== Install ==<br />
To install Pianobar, emerge it:<br />
{{console|body=<br />
###i## emerge pianobar<br />
}}<br />
== Keyboard shortcuts ==<br />
Pianobar has many shortcuts that allow you to increase or decrease the volume, change station, favorite a song, and many others. The table below includes some of the more commonly used shortcuts.<br />
{{TableStart}}<br />
<tr class="active"><br />
<th>Shortcut</th><br />
<th>Description</th><br />
</tr><tr><br />
<td>+</td><br />
<td>Love the song you are currently listening to. This is equivalent to the "thumbs up" button on Pandora.'</td><br />
</tr><tr><br />
<td>-</td><br />
<td>Give a "thumbs down" to the current song.</td><br />
</tr><tr><br />
<td>p</td><br />
<td>Pause or resume the music.</td><br />
</tr><tr><br />
<td>s</td><br />
<td>Change the station.</td><br />
</tr><tr><br />
<td>)</td><br />
<td>Increase the volume of pianobar.</td><br />
</tr><tr><br />
<td>(</td><br />
<td>Decrease the volume of pianobar.</td><br />
</tr><tr><br />
</tr><br />
{{TableEnd}}<br />
<br />
{{note|All of Pianobar's shortcuts can be listed by typing {{c|?}} when running pianobar.}}<br />
<br />
== Pianobar configuration ==<br />
=== Easy login ===<br />
After you have emerged Pianobar, you can run it with <code>pianobar</code>. If you dislike typing your username and password every time that you run pianobar, create the file <code>~/.config/pianobar/config</code> and add the following lines to it:<br />
{{file|name= ~/.config/pianobar/config|desc= |body=<br />
password = YOURPASSWORD<br />
user = user@email.com<br />
}}<br />
<br />
=== Easy login (with encryption) ===<br />
If leaving a plaintext password for your Pandora account somewhere on your filesystem makes you nervous, you can use gpg to decrypt a file that contains your password. Change your configuration to reflect the one below if you would like to encrypt your password:<br />
{{file|name=~/.config/pianobar/config|desc= |body=<br />
password_command = gpg --decrypt ~/.passwords/pianobar<br />
user = user@email.com<br />
}}<br />
<br />
=== Keybindings ===<br />
To configure keybindings, check out {{c|man pianobar}}. All keybindings can be added to {{c|~/.config/pianobar/config}}. All the keybindings in the man page will begin with the line {{c|act_}}.<br />
<br />
=== Other configuration options ===<br />
{{TableStart}}<br />
<tr class="active"><br />
<th>Option</th><br />
<th>Description</th><br />
</tr><tr><br />
<td>audio_quality</td><br />
<td>The quality of the audio. Can be set to: high, medium, or low.</td><br />
</tr><tr><br />
<td>autostart_station</td><br />
<td>Select a station ID that you would like to play when Pianobar starts.</td><br />
</tr><tr><br />
<td>proxy</td><br />
<td>Use an http proxy to connect to Pandora.</td><br />
</tr><tr><br />
</tr><br />
{{TableEnd}}<br />
<br />
== Troubleshooting ==<br />
=== {{c|ao_alsa WARNING}} message ===<br />
The {{c|ao_alsa WARNING: Unable to open surround playback. Trying default device}} message is often associated with the use of Pulseaudio. To resolve this warning message, edit {{c|/etc/libao.conf}} (you may have to create the file if it does not exist on your system):<br />
{{file|name=/etc/libao.conf|desc=|body=<br />
default_driver=pulse<br />
}}<br />
After a restart of Pianobar, the warning messages should not be displayed anymore.<br />
<br />
=== Not compiled with threads support ===<br />
If you recieve the following warning message ({{c|[aac @ 0x7faccc003cd0] Warning: not compiled with thread support, using thread emulation}}) while running Pianobar, add threads support to {{c|ffmpeg}}, then rebuild it:<br />
{{console|body=<br />
###i## echo "media-video/ffmpeg threads" > /etc/portage/package.use/ffmpeg<br />
###i## emerge ffmpeg<br />
}}<br />
{{note|As of [https://bugs.funtoo.org/browse/FL-1437 FL-1437], threads support should be enabled on ffmpeg by default.}}<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Pianobar&diff=10424Package:Pianobar2015-06-21T22:10:48Z<p>Duncan.britton: Added fix for problem with pulseaudio and libao.conf. Removed old <code> and <terminal> tags and added a blockquote at the top of the page.</p>
<hr />
<div>{{Ebuild<br />
|Summary=Pianobar is a console client for the personalized web radio Pandora.<br />
|CatPkg=media-sound/pianobar<br />
|Homepage=https://github.com/PromyLOPh/pianobar<br />
}}<br />
<blockquote><br />
Pianobar is a console client for the personalized web radio Pandora.<br />
It features the following abilities:<br />
<br />
* Play and manage (create, add more music, delete, rename, etc.) your stations<br />
* Rate played songs and let Pandora explain why they have been selected<br />
* Show upcoming songs and song history<br />
* Configure keybindings<br />
* Last.fm scrobbling support (with the help of an external application)<br />
* Proxy support for listeners outside of the USA [[https://github.com/PromyLOPh/pianobar Homepage]]<br />
</blockquote><br />
<br />
<br />
== Install ==<br />
To install Pianobar, emerge it:<br />
{{console|body=<br />
###i## emerge pianobar<br />
}}<br />
<br />
== Keyboard shortcuts ==<br />
Pianobar has many shortcuts that allow you to increase or decrease the volume, change station, favorite a song, and many others. The table below includes some of the more commonly used shortcuts.<br />
{{TableStart}}<br />
<tr class="active"><br />
<th>Shortcut</th><br />
<th>Description</th><br />
</tr><tr><br />
<td>+</td><br />
<td>Love the song you are currently listening to. This is equivalent to the "thumbs up" button on Pandora.'</td><br />
</tr><tr><br />
<td>-</td><br />
<td>Give a "thumbs down" to the current song.</td><br />
</tr><tr><br />
<td>p</td><br />
<td>Pause or resume the music.</td><br />
</tr><tr><br />
<td>s</td><br />
<td>Change the station.</td><br />
</tr><tr><br />
<td>)</td><br />
<td>Increase the volume of pianobar.</td><br />
</tr><tr><br />
<td>(</td><br />
<td>Decrease the volume of pianobar.</td><br />
</tr><tr><br />
</tr><br />
{{TableEnd}}<br />
<br />
{{note|All of Pianobar's shortcuts can be listed by typing {{c|?}} when running pianobar.}}<br />
<br />
== Pianobar configuration ==<br />
=== Easy login ===<br />
After you have emerged Pianobar, you can run it with <code>pianobar</code>. If you dislike typing your username and password every time that you run pianobar, create the file <code>~/.config/pianobar/config</code> and add the following lines to it:<br />
{{file|name= ~/.config/pianobar/config|desc= |body=<br />
password = YOURPASSWORD<br />
user = user@email.com<br />
}}<br />
<br />
=== Easy login (with encryption) ===<br />
If leaving a plaintext password for your Pandora account somewhere on your filesystem makes you nervous, you can use gpg to decrypt a file that contains your password. Change your configuration to reflect the one below if you would like to encrypt your password:<br />
{{file|name=~/.config/pianobar/config|desc= |body=<br />
password_command = gpg --decrypt ~/.passwords/pianobar<br />
user = user@email.com<br />
}}<br />
<br />
=== Keybindings ===<br />
To configure keybindings, check out {{c|man pianobar}}. All keybindings can be added to {{c|~/.config/pianobar/config}}. All the keybindings in the man page will begin with the line {{c|act_}}.<br />
<br />
=== Other configuration options ===<br />
{{TableStart}}<br />
<tr class="active"><br />
<th>Option</th><br />
<th>Description</th><br />
</tr><tr><br />
<td>audio_quality</td><br />
<td>The quality of the audio. Can be set to: high, medium, or low.</td><br />
</tr><tr><br />
<td>autostart_station</td><br />
<td>Select a station ID that you would like to play when Pianobar starts.</td><br />
</tr><tr><br />
<td>proxy</td><br />
<td>Use an http proxy to connect to Pandora.</td><br />
</tr><tr><br />
</tr><br />
{{TableEnd}}<br />
<br />
== Troubleshooting ==<br />
=== {{c|ao_alsa WARNING}} message ===<br />
The {{c|ao_alsa WARNING: Unable to open surround playback. Trying default device}} message is often associated with the use of Pulseaudio. To resolve this warning message, edit {{c|/etc/libao.conf}} (you may have to create the file if it does not exist on your system):<br />
{{file|name=/etc/libao.conf|desc=|body=<br />
default_driver=pulse<br />
}}<br />
After a restart of Pianobar, the warning messages should not be displayed anymore.<br />
<br />
=== Not compiled with threads support ===<br />
If you recieve the following warning message ({{c|[aac @ 0x7faccc003cd0] Warning: not compiled with thread support, using thread emulation}}) while running Pianobar, add threads support to {{c|ffmpeg}}, then rebuild it:<br />
{{console|body=<br />
###i## echo "media-video/ffmpeg threads" > /etc/portage/package.use/ffmpeg<br />
###i## emerge ffmpeg<br />
}}<br />
{{note|As of [https://bugs.funtoo.org/browse/FL-1437 FL-1437], threads support should be enabled on ffmpeg by default.}}<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Ntp&diff=10411Package:Ntp2015-06-21T16:06:07Z<p>Duncan.britton: Removed irritating white spaces between different sections.</p>
<hr />
<div>{{Ebuild<br />
|Summary=Network Time Protocol suite/programs<br />
|CatPkg=net-misc/ntp<br />
|Homepage=http://www.ntp.org/<br />
}}<br />
=== Installation ===<br />
To install the NTP client and server, run the following command:<br />
{{console|body=<br />
###i## emerge net-misc/ntp<br />
}}<br />
=== Configuration ===<br />
==== Client ====<br />
The ntp-client command immediately synchronizes your clock, and has separate ntp sync settings from the daemon:<br />
<br />
{{file|name=/etc/conf.d/ntp-client|lang=|desc=setting ntp-client upstream servers|body=<br />
NTPCLIENT_OPTS="-s -b -u \<br />
0.pool.ntp.org 1.pool.ntp.org \<br />
2.pool.ntp.org 3.pool.ntp.org"<br />
}}<br />
==== Server ====<br />
The ntpd server is also an ntp-client of upstream servers. Ntpd continuously, and gradually synchronizes the local clock.<br />
<br />
{{file|name=/etc/ntp.conf|lang=|desc=setting ntpd upstream servers|body=<br />
# Pools for Gentoo users<br />
server 0.pool.ntp.org<br />
server 1.pool.ntp.org<br />
server 2.pool.ntp.org<br />
server 3.pool.ntp.org<br />
}}<br />
=== Runtime ===<br />
If you are interested only in synchronizing your local clock against servers, then only add {{c|ntp-client}} to your list of services to start at boot:<br />
{{console|body=<br />
###i## rc-updated add ntp-client<br />
}}<br />
After adding the {{c|ntp-client}} service to the {{c|default}} runlevel, the service can be started by executing the {{c|rc}} command as root:<br />
{{console|body=<br />
###i## rc<br />
##g##* ##!g##Setting the clock via the NTP client 'ntpdate' ... ##bl##[##!bl## ##g##OK##!g## ##bl##]##!bl##<br />
}}<br />
{{note|Executing the above command normally takes several seconds}}<br />
<br />
If you are instead interested in running an NTP server, add {{c|ntpd}} to your list of services to execute at boot:<br />
{{console|body=<br />
###i## rc-update add ntpd<br />
}}<br />
{{note|{{c|ntpd}} serves as both a client and a server}}<br />
==== Hardware Clock ====<br />
To write your NTP sync time to the hardware at shutdown, and read hw clock at start.<br />
<br />
{{console|body=<br />
###i## echo 'clock_hctosys="YES"' >> /etc/conf.d/hwclock<br />
###i## echo 'clock_systohc="YES"' >> /etc/conf.d/hwclock<br />
###i## rc-service hwclock restart<br />
###i## rc-update add hwclock boot<br />
}}<br />
=== External Resources ===<br />
http://keetweej.vanheusden.com/query_ntp.php<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Ntp&diff=10410Package:Ntp2015-06-21T16:05:19Z<p>Duncan.britton: Added descriptions of what the different commands on the page mean.</p>
<hr />
<div>{{Ebuild<br />
|Summary=Network Time Protocol suite/programs<br />
|CatPkg=net-misc/ntp<br />
|Homepage=http://www.ntp.org/<br />
}}<br />
=== Installation ===<br />
To install the NTP client and server, run the following command:<br />
{{console|body=<br />
###i## emerge net-misc/ntp<br />
}}<br />
<br />
=== Configuration ===<br />
==== Client ====<br />
The ntp-client command immediately synchronizes your clock, and has separate ntp sync settings from the daemon:<br />
<br />
{{file|name=/etc/conf.d/ntp-client|lang=|desc=setting ntp-client upstream servers|body=<br />
NTPCLIENT_OPTS="-s -b -u \<br />
0.pool.ntp.org 1.pool.ntp.org \<br />
2.pool.ntp.org 3.pool.ntp.org"<br />
}}<br />
<br />
==== Server ====<br />
The ntpd server is also an ntp-client of upstream servers. Ntpd continuously, and gradually synchronizes the local clock.<br />
<br />
{{file|name=/etc/ntp.conf|lang=|desc=setting ntpd upstream servers|body=<br />
# Pools for Gentoo users<br />
server 0.pool.ntp.org<br />
server 1.pool.ntp.org<br />
server 2.pool.ntp.org<br />
server 3.pool.ntp.org<br />
}}<br />
<br />
=== Runtime ===<br />
If you are interested only in synchronizing your local clock against servers, then only add {{c|ntp-client}} to your list of services to start at boot:<br />
{{console|body=<br />
###i## rc-updated add ntp-client<br />
}}<br />
After adding the {{c|ntp-client}} service to the {{c|default}} runlevel, the service can be started by executing the {{c|rc}} command as root:<br />
{{console|body=<br />
###i## rc<br />
##g##* ##!g##Setting the clock via the NTP client 'ntpdate' ... ##bl##[##!bl## ##g##OK##!g## ##bl##]##!bl##<br />
}}<br />
{{note|Executing the above command normally takes several seconds}}<br />
<br />
If you are instead interested in running an NTP server, add {{c|ntpd}} to your list of services to execute at boot:<br />
{{console|body=<br />
###i## rc-update add ntpd<br />
}}<br />
{{note|{{c|ntpd}} serves as both a client and a server}}<br />
<br />
==== Hardware Clock ====<br />
To write your NTP sync time to the hardware at shutdown, and read hw clock at start.<br />
<br />
{{console|body=<br />
###i## echo 'clock_hctosys="YES"' >> /etc/conf.d/hwclock<br />
###i## echo 'clock_systohc="YES"' >> /etc/conf.d/hwclock<br />
###i## rc-service hwclock restart<br />
###i## rc-update add hwclock boot<br />
}}<br />
<br />
=== External Resources ===<br />
http://keetweej.vanheusden.com/query_ntp.php<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Uvesafb&diff=10408Uvesafb2015-06-21T13:41:42Z<p>Duncan.britton: Removed ugly white boxes inside the tip and note templates on the page.</p>
<hr />
<div>== ''How to'' : Framebuffer: Userspace VESA VGA graphics support ==<br />
Uvesafb is an improved framebuffer driver for Linux systems with some enhancements compared to vesa. Uvesafb can allow you to get a full-resolution console, even if you have installed a graphics driver that does not support full-resolution consoles. Examples of drivers like these: [[Package:AMD_Catalyst_Video_Drivers| ati-drivers]] and NVidia-drivers.<br />
<br />
== Kernel configuration ==<br />
Before we emerge the required packages for uvesafb functionality, we have to configure the kernel properly.<br />
{{Kernelop|title= |desc=<br />
Device Drivers ---><br />
<*> Connector - unified userspace <-> kernelspace linker ---><br />
<br />
Graphics support ---><br />
Frame buffer devices ---><br />
[*] Support for frame buffer devices ---><br />
[*] Enable firmware EDID<br />
<*> Userspace VESA VGA graphics support<br />
}}<br />
<br />
{{Note|Build the kernel (<tt>make</tt>), do not install the kernel and modules (<tt> make install modules_install</tt>). You can choose uvesafb as a module, unlike vesa.}}<br />
<br />
== Install required packages ==<br />
<br />
Emerge {{Package|dev-libs/klibc}}. Klibc has to be compiled against a kernel that includes uvesafb support. This only has to be done once:<br />
<console><br />
###i## emerge klibc<br />
</console><br />
{{Package|sys-apps/v86d}} is the userspace helper that runs x86 code in emulated environment. Uvesafb will not work without v86d. Emerge <code>v86d</code>:<br />
<console><br />
###i## emerge v86d<br />
</console><br />
<br />
== Back to kernel configuration ==<br />
Reconfigure the kernel to include <tt>/usr/share/v86d/initramfs</tt> as an initramfs source file:<br />
{{Kernelop<br />
|title=<br />
|desc=<br />
General Setup---><br />
[*] Initial RAM filesystem and RAM disk (initramfs/initrd) support<br />
(/usr/share/v86d/initramfs) Initramfs source file(s)<br />
}}<br />
Rebuild the kernel: make and install it, install the modules<br />
<br />
== Bootloader configuration ==<br />
If you compiled uvesafb into the kernel (not as a module), you can configure its behavior by editing the '<tt>params += </tt>' line in <tt>/etc/boot.conf</tt>. Below, some of the more common switches used with uvesafb are explained.<br />
* <tt>video=uvesafb:<screen y-res>x<screen x-res>-<color depth></tt>: Tells the kernel that you want to use the uvesafb driver for console output. Also specifies that you will be using uvesafb at a set x-screen resolution, y screen-resolution, and color depth. Set the first part to the size of your screen (in pixels). For example, if I had a 1920x1080 screen and wanted a color depth of 32, I would add the following: <tt>video=uvesafb:1920x1080-32</tt><br />
<br />
* <tt>mtrr:x</tt>: X represents the number 0 or 3. This option allows you to set up the memory type range registers for uvesafb. Setting x=0 disables mtrr and setting x=3 enables mtrr. x=3 is the default setting for this switch. mtrr:3 is recommended.<br />
<br />
* <tt>ywrap</tt>: Add support for display panning. Recommended. <br />
<br />
{{Tip|For more information regarding these switches, check out http://www.mjmwired.net/kernel/Documentation/fb/uvesafb.txt}}<br />
<br />
Now that you have a basic understanding of a few of the different switches, configure your <tt>/etc/boot.conf</tt>:<br />
<br />
{{file|name=/etc/boot.conf|desc= |body=<br />
boot {<br />
generate grub<br />
default "Funtoo Linux: uvesafb" <br />
timeout 3 <br />
}<br />
"Funtoo Linux: uvesafb" { <br />
kernel bzImage[-v]<br />
params += video=uvesafb:1920x1080-32,mtrr:3,ywrap<br />
}<br />
}}<br />
{{Note|Realize that the configuration in the above file will not work on every computer. You must change the resolution (and possibly other switches) to best suite your needs.}}<br />
<br />
After you have finished editing your <tt>/etc/boot.conf</tt>, run the following:<br />
<console><br />
###i## boot-update<br />
</console> <br />
finally, reboot your computer so that you can test out uvesafb:<br />
<console><br />
###i## reboot<br />
</console><br />
<br />
[[Category:HOWTO]]</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Xfce4-meta&diff=10407Package:Xfce4-meta2015-06-21T13:00:18Z<p>Duncan.britton: Removed the table of plugins at the bottom of the page, as that information is now contained by the XFCE Panel Plugins page and the Thunar Plugins page.</p>
<hr />
<div>{{Ebuild<br />
|Summary=Meta package for XFCE desktop<br />
|CatPkg=xfce-base/xfce4-meta<br />
|Maintainer=Oleg<br />
}}<br />
== About Xfce ==<br />
<blockquote><br />
Xfce is a lightweight desktop environment for UNIX-like operating systems. It aims to be fast and low on system resources, while still being visually appealing and user friendly.<br />
<br />
Xfce embodies the traditional UNIX philosophy of modularity and re-usability. It consists of a number of components that provide the full functionality one can expect of a modern desktop environment. They are packaged separately and you can pick among the available packages to create the optimal personal working environment.<br />
<br />
Another priority of Xfce is adhereance to standards, specifically those defined at [http://freedesktop.org/ freedesktop.org]. [[http://www.xfce.org/about/ About XFCE]]<br />
</blockquote><br />
== Installation ==<br />
<br />
Before emerging Xfce you need to:<br />
<br />
Check that you have enabled the USE flags necessary for a XFCE desktop environment. Set your profile to "xfce" via [[Funtoo_Linux_First_Steps#Changing_profile|mix-ins]], as follows:<br />
{{console|body=<br />
###i## epro mix-ins +xfce<br />
}}<br />
Then, verify that you have the [[Funtoo_Linux_First_Steps#X.Org|X.Org Server]] configured properly. If X.Org is installed on your system, you are now ready to install Xfce. Install the meta-package, which pulls in all of the components you need for a minimal Xfce installation:<br />
<br />
{{console|body=<br />
###i## emerge xfce4-meta<br />
}}<br />
== Running Xfce ==<br />
<br />
There are several different ways to start Xfce:<br />
<br />
* Editing the {{c|.xinitrc}} file in your user's home directory and using {{c|startx}} from a text console.<br />
* Using a display manager (e.g. SLiM, GDM, and KDM).<br />
* Configuring your shell profile to automatically start Xfce upon a successful login.<br />
=== .xinitrc ===<br />
<br />
The most common way to start the environment is to configure {{c|~/.xinitrc}} to launch an Xfce session. The proper way to launch Xfce from the terminal is by using {{c|startxfce4}} combined with {{c|ck-launch-session}}.<br />
<br />
{{console|body=<br />
$##i## echo "exec startxfce4 --with-ck-launch" > ~/.xinitrc<br />
}}<br />
Note that {{c|--with-ck-launch}} (from ConsoleKit) is required by Xfce for important tasks such as shutting down, suspending, and automatically mounting removable storage media. Some applications will not work properly without it. Also, configuring the GTK+ theme and other forms of theming through {{Package|Xfce4-settings}} do not often work without the {{c|--with-ck-launch}} command line option. Because we are launching XFCE with a consolekit command line option, we need to add ConsoleKit to the {{c|default}} runlevel, executing the following command as root:<br />
<br />
{{console|body=<br />
###i## rc-update add consolekit default<br />
###i## rc<br />
}}<br />
Finally, to start the graphical environment, run {{c|startx}} from a login shell:<br />
<br />
{{console|body=<br />
$##i## startx<br />
}}<br />
After running this command, you should be greeted by your shiny new XFCE desktop. For more information about configuring XFCE and some of the default applications that come with it, consider looking at [[Package:xfce4-meta#XFCE configuration and XFCE applications|XFCE configuration and XFCE applications]].<br />
== Display Manager ==<br />
<br />
A display manager is a program that manages sessions and acts as a login screen. Here's a short list of a few of the display managers available from the Funtoo repositories:<br />
* XDM ({{c|x11-apps/xdm}}): X.Org's standard display manager.<br />
* LightDM ({{c|x11-misc/lightdm}}): A lightweight, but highly configurable display manager.<br />
* SLiM ({{c|x11-misc/slim}}): Simple Login Manager -- a lightweight display manager. Not very configurable.<br />
<br />
<br />
Any of these would make a fine choice. After you've chosen which display manager to use, install it:<br />
<br />
{{console|body=###i## emerge <display manager of choice>}}<br />
All that's left to do now is to add the name of the display manager to {{c|/etc/conf.d/xdm}}, add the {{c|xdm}} service and the {{c|dbus}} service to the {{c|default}} runlevel, and start the services:<br />
<br />
{{file|name=/etc/conf.d/xdm|desc=|body=<br />
DISPLAYMANAGER="<display manager name>"<br />
}}<br />
<br />
{{console|body=<br />
###i## rc-update add xdm default<br />
###i## rc-update add dbus default<br />
###i## rc<br />
}}<br />
==Power Group==<br />
If you wish to be able to shutdown/reboot/suspend/hibernate using xfce4-logout-session then you will need to add yourself or the user to the power group by:<br />
<br />
{{console|body=<br />
###i## gpasswd -a <username> power<br />
}}<br />
If the group does not exist then execute the following and try again:<br />
<br />
{{console|body=<br />
###i## groupadd power}}<br />
== XFCE configuration and XFCE applications ==<br />
For more information on configuring XFCE and the default applications provided by XFCE, such as {{c|xfce4-terminal}}, consider following some of the below listed links:<br />
* [[Package:Xfce4-settings|GUI settings configuration for XFCE]]<br />
* [[Package:Xfce4-terminal|The default terminal emulator for XFCE]]<br />
* [[Package:Whiskermenu|An alternate menu for the XFCE panel]]<br />
* [[XFCE Panel Plugins|A list of the various plugins available for {{c|xfce4-panel}}]]<br />
* [[Thunar Plugins|A list of the plugins available for the Thunar file manager]]<br />
<br />
[[Category:Desktop]]<br />
[[Category:First Steps]]<br />
[[Category:Official Documentation]]<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Thunar_Plugins&diff=10403Thunar Plugins2015-06-20T18:30:51Z<p>Duncan.britton: Changed wording in introduction to page...it now sounds better.</p>
<hr />
<div>The functionality of Thunar, XFCE's file manager, can be extended by the installation of plugins. Below is a list of the plugins provided for Thunar that are contained in the Funtoo portage tree.<br />
<br />
{{TableStart}}<br />
<tr class="info"><th>Name of plugin</th><th>Description of plugin</th></tr><br />
<tr><td>{{c|thunar-archive-plugin}}</td><td>Archive plug-in for the Thunar filemanager</td></tr><br />
<tr><td>{{c|thunar-media-tags-plugin}}</td><td>Adds special features for media files to the Thunar File Manager</td></tr><br />
<tr><td>{{c|thunar-shares-plugin}}</td><td>Thunar plugin to share files using Samba</td></tr><br />
<tr><td>{{c|thunar-vcs-plugin}}</td><td>Adds Subversion and GIT actions to the context menu of thunar</td></tr><br />
{{TableEnd}}<br />
To install and use any of the above plugins, simply:<br />
{{console|body=<br />
###i## emerge <thunar plugin><br />
}}<br />
and restart Thunar.</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Thunar_Plugins&diff=10402Thunar Plugins2015-06-20T18:24:53Z<p>Duncan.britton: Added a description of the page and how to install the plugins documented by the page.</p>
<hr />
<div>Thunar, XFCE's file manager's functionality can be extended by the installation of plugins. Plugins for Thunar allow for the opening and creation of archives and other helpful functions that do not come built-in to Thunar to be achieved with ease. Below is a list of the plugins provided for Thunar by the Funtoo portage tree.<br />
<br />
{{TableStart}}<br />
<tr class="info"><th>Name of plugin</th><th>Description of plugin</th></tr><br />
<tr><td>{{c|thunar-archive-plugin}}</td><td>Archive plug-in for the Thunar filemanager</td></tr><br />
<tr><td>{{c|thunar-media-tags-plugin}}</td><td>Adds special features for media files to the Thunar File Manager</td></tr><br />
<tr><td>{{c|thunar-shares-plugin}}</td><td>Thunar plugin to share files using Samba</td></tr><br />
<tr><td>{{c|thunar-vcs-plugin}}</td><td>Adds Subversion and GIT actions to the context menu of thunar</td></tr><br />
{{TableEnd}}<br />
<br />
To install and use any of the above plugins, simply:<br />
{{console|body=<br />
###i## emerge <thunar plugin><br />
}}<br />
and restart Thunar.</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Thunar_Plugins&diff=10401Thunar Plugins2015-06-20T18:13:09Z<p>Duncan.britton: Fixed the first row in the table.</p>
<hr />
<div>{{TableStart}}<br />
<tr class="info"><th>Name of plugin</th><th>Description of plugin</th></tr><br />
<tr><td>{{c|thunar-archive-plugin}}</td><td>Archive plug-in for the Thunar filemanager</td></tr><br />
<tr><td>{{c|thunar-media-tags-plugin}}</td><td>Adds special features for media files to the Thunar File Manager</td></tr><br />
<tr><td>{{c|thunar-shares-plugin}}</td><td>Thunar plugin to share files using Samba</td></tr><br />
<tr><td>{{c|thunar-vcs-plugin}}</td><td>Adds Subversion and GIT actions to the context menu of thunar</td></tr><br />
{{TableEnd}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=XFCE_Panel_Plugins&diff=10400XFCE Panel Plugins2015-06-20T18:12:54Z<p>Duncan.britton: *Improved* the name of the second column in the table of plugins.</p>
<hr />
<div><br />
{{TableStart}}<br />
<tr class="info"><th>Name of plugin</th><th>Description of plugin</th></tr><br />
<tr><td>{{c|xfce4-battery-plugin}}</td><td>A battery monitor panel plugin for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-cellmodem-plugin}}</td><td>A panel plug-in with monitoring support for GPRS/UMTS(3G)/HSDPA(3.5G) modems</td></tr><br />
<tr><td>{{c|xfce4-clipman-plugin}}</td><td>A clipboard manager plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-cpufreq-plugin}}</td><td>A panel plugin for showing information about cpufreq settings</td></tr><br />
<tr><td>{{c|xfce4-cpugraph-plugin}}</td><td>A system load plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-datetime-plugin}}</td><td>A panel plug-in with date, time and embedded calender</td></tr><br />
<tr><td>{{c|xfce4-diskperf-plugin}}</td><td>A panel plug-in for disk usage and performance statistics</td></tr><br />
<tr><td>{{c|xfce4-embed-plugin}}</td><td>A plug-in for embedding arbitrary application windows into the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-equake-plugin}}</td><td>Panel plug-in that displays information about earthquakes at regular intervals</td></tr><br />
<tr><td>{{c|xfce4-eyes-plugin}}</td><td>A panel plug-in which adds classic eyes to your every step</td></tr><br />
<tr><td>{{c|xfce4-fsguard-plugin}}</td><td>A filesystem guard plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-genmon-plugin}}</td><td>Cyclically spawns the executable, captures its output and displays the result into the panel</td></tr><br />
<tr><td>{{c|xfce4-gvfs-mount}}</td><td>A panel plug-in to mount remote filesystems for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-indicator-plugin}}</td><td>A panel plugin that uses indicator-applet to show new messages</td></tr><br />
<tr><td>{{c|xfce4-kbdleds-plugin}}</td><td>A panel plug-in to show state of Caps, Num and Scroll Lock keys</td></tr><br />
<tr><td>{{c|xfce4-mailwatch-plugin}}</td><td>An mail notification panel plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-modemlights-plugin}}</td><td>A panel plug-in intended to simplify establishing a ppp connection</td></tr><br />
<tr><td>{{c|xfce4-mount-plugin}}</td><td>An mount plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-mpc-plugin}}</td><td>Music Player Daemon (mpd) panel plugin</td></tr><br />
<tr><td>{{c|xfce4-netload-plugin}}</td><td>A network load plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-notes-plugin}}</td><td>Xfce4 panel sticky notes plugin</td></tr><br />
<tr><td>{{c|xfce4-places-plugin}}</td><td>A panel plug-in to provide quick access to files, folders and removable media</td></tr><br />
<tr><td>{{c|xfce4-playercontrol-plugin}}</td><td>Audacious and MPD panel plugins</td></tr><br />
<tr><td>{{c|xfce4-pulseaudio-plugin}}</td><td>A panel plug-in for PulseAudio volume control</td></tr><br />
<tr><td>{{c|xfce4-quicklauncher-plugin}}</td><td>A quicklauncher plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-radio-plugin}}</td><td>V4L radio device control plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-sensors-plugin}}</td><td>A panel plug-in for different sensors using acpi, lm_sensors and hddtemp</td></tr><br />
<tr><td>{{c|xfce4-smartbookmark-plugin}}</td><td>Smart bookmark plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-systemload-plugin}}</td><td>System load plug-in for Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-time-out-plugin}}</td><td>A panel plug-in to take periodical breaks from the computer</td></tr><br />
<tr><td>{{c|xfce4-timer-plugin}}</td><td>A simple timer plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-verve-plugin}}</td><td>A comfortable command line plugin for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-wavelan-plugin}}</td><td>A panel plug-in to display wireless interface statistics</td></tr><br />
<tr><td>{{c|xfce4-weather-plugin}}</td><td>A weather plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-whiskermenu-plugin}}</td><td>Alternate application launcher for Xfce</td></tr><br />
<tr><td>{{c|xfce4-wmdock-plugin}}</td><td>a compatibility layer for running WindowMaker dockapps on Xfce4</td></tr><br />
<tr><td>{{c|xfce4-xkb-plugin}}</td><td>XKB layout switching panel plug-in for the Xfce desktop environment</td></tr><br />
{{TableEnd}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Thunar_Plugins&diff=10399Thunar Plugins2015-06-20T18:11:01Z<p>Duncan.britton: </p>
<hr />
<div>{{TableStart}}<br />
<tr class="info><th>Plugin name</th><th>Plugin description</th></tr><br />
<tr><td>{{c|thunar-archive-plugin}}</td><td>Archive plug-in for the Thunar filemanager</td></tr><br />
<tr><td>{{c|thunar-media-tags-plugin}}</td><td>Adds special features for media files to the Thunar File Manager</td></tr><br />
<tr><td>{{c|thunar-shares-plugin}}</td><td>Thunar plugin to share files using Samba</td></tr><br />
<tr><td>{{c|thunar-vcs-plugin}}</td><td>Adds Subversion and GIT actions to the context menu of thunar</td></tr><br />
{{TableEnd}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Thunar_Plugins&diff=10398Thunar Plugins2015-06-20T18:10:07Z<p>Duncan.britton: Added a table that contains a list of all of the thunar panel plugins in the Funtoo portage tree.</p>
<hr />
<div>{{TableStart}}<br />
<tr class="info><td>Plugin name</td><td>Plugin description</td></tr><br />
<tr><td>{{c|thunar-archive-plugin}}</td><td>Archive plug-in for the Thunar filemanager</td></tr><br />
<tr><td>{{c|thunar-media-tags-plugin}}</td><td>Adds special features for media files to the Thunar File Manager</td></tr><br />
<tr><td>{{c|thunar-shares-plugin}}</td><td>Thunar plugin to share files using Samba</td></tr><br />
<tr><td>{{c|thunar-vcs-plugin}}</td><td>Adds Subversion and GIT actions to the context menu of thunar</td></tr><br />
{{TableEnd}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=XFCE_Panel_Plugins&diff=10397XFCE Panel Plugins2015-06-20T17:30:21Z<p>Duncan.britton: Added a table that contains a list of all of the XFCE panel plugins in the Funtoo portage tree.</p>
<hr />
<div><br />
{{TableStart}}<br />
<tr class="info"><th>Name of plugin</th><th>Functionality provided</th></tr><br />
<tr><td>{{c|xfce4-battery-plugin}}</td><td>A battery monitor panel plugin for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-cellmodem-plugin}}</td><td>A panel plug-in with monitoring support for GPRS/UMTS(3G)/HSDPA(3.5G) modems</td></tr><br />
<tr><td>{{c|xfce4-clipman-plugin}}</td><td>A clipboard manager plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-cpufreq-plugin}}</td><td>A panel plugin for showing information about cpufreq settings</td></tr><br />
<tr><td>{{c|xfce4-cpugraph-plugin}}</td><td>A system load plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-datetime-plugin}}</td><td>A panel plug-in with date, time and embedded calender</td></tr><br />
<tr><td>{{c|xfce4-diskperf-plugin}}</td><td>A panel plug-in for disk usage and performance statistics</td></tr><br />
<tr><td>{{c|xfce4-embed-plugin}}</td><td>A plug-in for embedding arbitrary application windows into the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-equake-plugin}}</td><td>Panel plug-in that displays information about earthquakes at regular intervals</td></tr><br />
<tr><td>{{c|xfce4-eyes-plugin}}</td><td>A panel plug-in which adds classic eyes to your every step</td></tr><br />
<tr><td>{{c|xfce4-fsguard-plugin}}</td><td>A filesystem guard plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-genmon-plugin}}</td><td>Cyclically spawns the executable, captures its output and displays the result into the panel</td></tr><br />
<tr><td>{{c|xfce4-gvfs-mount}}</td><td>A panel plug-in to mount remote filesystems for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-indicator-plugin}}</td><td>A panel plugin that uses indicator-applet to show new messages</td></tr><br />
<tr><td>{{c|xfce4-kbdleds-plugin}}</td><td>A panel plug-in to show state of Caps, Num and Scroll Lock keys</td></tr><br />
<tr><td>{{c|xfce4-mailwatch-plugin}}</td><td>An mail notification panel plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-modemlights-plugin}}</td><td>A panel plug-in intended to simplify establishing a ppp connection</td></tr><br />
<tr><td>{{c|xfce4-mount-plugin}}</td><td>An mount plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-mpc-plugin}}</td><td>Music Player Daemon (mpd) panel plugin</td></tr><br />
<tr><td>{{c|xfce4-netload-plugin}}</td><td>A network load plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-notes-plugin}}</td><td>Xfce4 panel sticky notes plugin</td></tr><br />
<tr><td>{{c|xfce4-places-plugin}}</td><td>A panel plug-in to provide quick access to files, folders and removable media</td></tr><br />
<tr><td>{{c|xfce4-playercontrol-plugin}}</td><td>Audacious and MPD panel plugins</td></tr><br />
<tr><td>{{c|xfce4-pulseaudio-plugin}}</td><td>A panel plug-in for PulseAudio volume control</td></tr><br />
<tr><td>{{c|xfce4-quicklauncher-plugin}}</td><td>A quicklauncher plug-in for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-radio-plugin}}</td><td>V4L radio device control plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-sensors-plugin}}</td><td>A panel plug-in for different sensors using acpi, lm_sensors and hddtemp</td></tr><br />
<tr><td>{{c|xfce4-smartbookmark-plugin}}</td><td>Smart bookmark plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-systemload-plugin}}</td><td>System load plug-in for Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-time-out-plugin}}</td><td>A panel plug-in to take periodical breaks from the computer</td></tr><br />
<tr><td>{{c|xfce4-timer-plugin}}</td><td>A simple timer plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-verve-plugin}}</td><td>A comfortable command line plugin for the Xfce panel</td></tr><br />
<tr><td>{{c|xfce4-wavelan-plugin}}</td><td>A panel plug-in to display wireless interface statistics</td></tr><br />
<tr><td>{{c|xfce4-weather-plugin}}</td><td>A weather plug-in for the Xfce desktop environment</td></tr><br />
<tr><td>{{c|xfce4-whiskermenu-plugin}}</td><td>Alternate application launcher for Xfce</td></tr><br />
<tr><td>{{c|xfce4-wmdock-plugin}}</td><td>a compatibility layer for running WindowMaker dockapps on Xfce4</td></tr><br />
<tr><td>{{c|xfce4-xkb-plugin}}</td><td>XKB layout switching panel plug-in for the Xfce desktop environment</td></tr><br />
{{TableEnd}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Package:Xfce4-meta&diff=10395Package:Xfce4-meta2015-06-20T16:18:04Z<p>Duncan.britton: Added more links to the XFCE configuration and XFCE applications category.</p>
<hr />
<div>{{Ebuild<br />
|Summary=Meta package for XFCE desktop<br />
|CatPkg=xfce-base/xfce4-meta<br />
|Maintainer=Oleg<br />
}}<br />
== About Xfce ==<br />
<blockquote><br />
Xfce is a lightweight desktop environment for UNIX-like operating systems. It aims to be fast and low on system resources, while still being visually appealing and user friendly.<br />
<br />
Xfce embodies the traditional UNIX philosophy of modularity and re-usability. It consists of a number of components that provide the full functionality one can expect of a modern desktop environment. They are packaged separately and you can pick among the available packages to create the optimal personal working environment.<br />
<br />
Another priority of Xfce is adhereance to standards, specifically those defined at [http://freedesktop.org/ freedesktop.org]. [[http://www.xfce.org/about/ About XFCE]]<br />
</blockquote><br />
== Installation ==<br />
<br />
Before emerging Xfce you need to:<br />
<br />
Check that you have enabled the USE flags necessary for a XFCE desktop environment. Set your profile to "xfce" via [[Funtoo_Linux_First_Steps#Changing_profile|mix-ins]], as follows:<br />
{{console|body=<br />
###i## epro mix-ins +xfce<br />
}}<br />
Then, verify that you have the [[Funtoo_Linux_First_Steps#X.Org|X.Org Server]] configured properly. If X.Org is installed on your system, you are now ready to install Xfce. Install the meta-package, which pulls in all of the components you need for a minimal Xfce installation:<br />
<br />
{{console|body=<br />
###i## emerge xfce4-meta<br />
}}<br />
== Running Xfce ==<br />
<br />
There are several different ways to start Xfce:<br />
<br />
* Editing the {{c|.xinitrc}} file in your user's home directory and using {{c|startx}} from a text console.<br />
* Using a display manager (e.g. SLiM, GDM, and KDM).<br />
* Configuring your shell profile to automatically start Xfce upon a successful login.<br />
=== .xinitrc ===<br />
<br />
The most common way to start the environment is to configure {{c|~/.xinitrc}} to launch an Xfce session. The proper way to launch Xfce from the terminal is by using {{c|startxfce4}} combined with {{c|ck-launch-session}}.<br />
<br />
{{console|body=<br />
$##i## echo "exec startxfce4 --with-ck-launch" > ~/.xinitrc<br />
}}<br />
Note that {{c|--with-ck-launch}} (from ConsoleKit) is required by Xfce for important tasks such as shutting down, suspending, and automatically mounting removable storage media. Some applications will not work properly without it. Also, configuring the GTK+ theme and other forms of theming through {{Package|Xfce4-settings}} do not often work without the {{c|--with-ck-launch}} command line option. Because we are launching XFCE with a consolekit command line option, we need to add ConsoleKit to the {{c|default}} runlevel, executing the following command as root:<br />
<br />
{{console|body=<br />
###i## rc-update add consolekit default<br />
###i## rc<br />
}}<br />
Finally, to start the graphical environment, run {{c|startx}} from a login shell:<br />
<br />
{{console|body=<br />
$##i## startx<br />
}}<br />
After running this command, you should be greeted by your shiny new XFCE desktop. For more information about configuring XFCE and some of the default applications that come with it, consider looking at [[Package:xfce4-meta#XFCE configuration and XFCE applications|XFCE configuration and XFCE applications]].<br />
== Display Manager ==<br />
<br />
A display manager is a program that manages sessions and acts as a login screen. Here's a short list of a few of the display managers available from the Funtoo repositories:<br />
* XDM ({{c|x11-apps/xdm}}): X.Org's standard display manager.<br />
* LightDM ({{c|x11-misc/lightdm}}): A lightweight, but highly configurable display manager.<br />
* SLiM ({{c|x11-misc/slim}}): Simple Login Manager -- a lightweight display manager. Not very configurable.<br />
<br />
<br />
Any of these would make a fine choice. After you've chosen which display manager to use, install it:<br />
<br />
{{console|body=###i## emerge <display manager of choice>}}<br />
All that's left to do now is to add the name of the display manager to {{c|/etc/conf.d/xdm}}, add the {{c|xdm}} service and the {{c|dbus}} service to the {{c|default}} runlevel, and start the services:<br />
<br />
{{file|name=/etc/conf.d/xdm|desc=|body=<br />
DISPLAYMANAGER="<display manager name>"<br />
}}<br />
<br />
{{console|body=<br />
###i## rc-update add xdm default<br />
###i## /etc/init.d/xdm start<br />
###i## rc-update add dbus default<br />
###i## /etc/init.d/dbus start}}<br />
==Power Group==<br />
If you wish to be able to shutdown/reboot/suspend/hibernate using xfce4-logout-session then you will need to add yourself or the user to the power group by:<br />
<br />
{{console|body=<br />
###i## gpasswd -a <username> power<br />
}}<br />
If the group does not exist then execute the following and try again:<br />
<br />
{{console|body=<br />
###i## groupadd power}}<br />
== XFCE configuration and XFCE applications ==<br />
For more information on configuring XFCE and the default applications provided by XFCE, such as {{c|xfce4-terminal}}, consider following some of the below listed links:<br />
* [[Package:Xfce4-settings|GUI settings configuration for XFCE]]<br />
* [[Package:Xfce4-terminal|The default terminal emulator for XFCE]]<br />
* [[Package:Whiskermenu|An alternate menu for the XFCE panel]]<br />
* [[XFCE Panel Plugins|A list of the various plugins available for {{c|xfce4-panel}}]]<br />
* [[Thunar Plugins|A list of the plugins available for the Thunar file manager]]<br />
<br />
== Plugins for Thunar and XFCE ==<br />
There are a lot of plugins available for Thunar and XFCE. Here is a table that contains the name of the plugin and a description of what it does. To install one of the plugins, run<br />
{{console|body=###i## emerge [name of plugin]}}<br />
<br />
{{TableStart}}<br />
<tr class="info"><th>Name</th><th>Description</th></tr><br />
<tr><td>xfce-extra/tumbler</td><td>A thumbnail service for the filemanager of Xfce desktop environment. Installed by default in Funtoo</td></tr><br />
<tr><td>xfce-extra/thunar-volman</td><td>Daemon that enforces volume-related policies. Installed by default Funtoo</td></tr><br />
<tr><td>xfce-extra/thunar-vcs-plugin </td><td>Adds Subversion and GIT actions to the context menu of thunar </td></tr><br />
<tr><td>xfce-extra/thunar-shares-plugin</td><td>Thunar plugin to share files using Samba </td></tr><br />
<tr><td>xfce-extra/thunar-archive-plugin</td><td>Archive plug-in for the Thunar filemanager</td></tr><br />
<tr><td>xfce-extra/xfce4-volumed</td><td>Daemon to control volume up/down and mute keys</td></tr><br />
<tr><td>xfce-extra/xfce4-volumed-pulse</td><td>Daemon to control volume keys for pulseaudio</td></tr><br />
<tr><td>xfce-extra/xfce4-screenshooter</td><td>Xfce4 screenshooter application and panel plugin</td></tr><br />
<tr><td>xfce-extra/xfce4-notifyd</td><td>Notification daemon for the Xfce desktop environment</td></tr><br />
<tr><td>xfce-extra/xfce4-mixer</td><td>A volume control application (and panel plug-in) for the Xfce desktop environment. Installed by default in Funtoo</td></tr><br />
<tr><td>xfce-extra/xfce4-mount-plugin</td><td>A mount plug-in for the Xfce panel</td></tr><br />
<tr><td>xfce-extra/xfce4-clipman-plugin</td><td>A clipboard manager plug-in for the Xfce panel</td></tr><br />
<tr><td>xfce-extra/xfce4-battery-plugin</td><td>A battery monitor panel plugin for the Xfce desktop environment</td></tr><br />
<tr><td>media-gfx/ristretto</td><td>A image viewer by Xfce project. Installed by default in Funtoo</td></tr><br />
{{TableEnd}}<br />
<br />
[[Category:Desktop]]<br />
[[Category:First Steps]]<br />
[[Category:Official Documentation]]<br />
{{EbuildFooter}}</div>Duncan.brittonhttps://www.funtoo.org/index.php?title=Thunar_Plugins&diff=10394Thunar Plugins2015-06-20T16:16:25Z<p>Duncan.britton: Created the page -- not its contents.</p>
<hr />
<div>A page to detail the various plugins available for the Thunar file manager.<br />
{{PageNeedsUpdates}}</div>Duncan.britton