https://wiki.archlinux.org/api.php?action=feedcontributions&user=Ek&feedformat=atomArchWiki - User contributions [en]2024-03-29T09:54:33ZUser contributionsMediaWiki 1.41.0https://wiki.archlinux.org/index.php?title=FFmpeg&diff=236852FFmpeg2012-11-26T16:10:34Z<p>Ek: Small addition for android users.</p>
<hr />
<div>[[Category:Audio/Video]]<br />
{{Article summary start}}<br />
{{Article summary text|This article attempts to walk users through the installation, usage and configuration of FFmpeg.}}<br />
{{Article summary end}}<br />
<br />
[http://www.ffmpeg.org/ FFmpeg] is command-line driven collection of tools which enables the decoding, encoding, conversion and playback of [http://ffmpeg.org/general.html#Supported-File-Formats-and-Codecs most audio and video streams].<br />
<br />
== Package installation ==<br />
{{Pkg|FFmpeg}} is part of the [[Official_repositories#.5Bextra.5D|official Arch Linux [extra] repository]].<br />
<br />
{{bc|# pacman -S ffmpeg}}<br />
<br />
== Encoding examples ==<br />
<br />
=== Screen cast to .webm ===<br />
<br />
Using '''x11grab''' to video grab your display and using '''ALSA''' for sound. First we create lossless raw file `test.mkv`.<br />
<br />
$ ffmpeg -f x11grab -r 30 -i :0.0 -f alsa -i hw:0,0 -acodec flac -vcodec ffvhuff test.mkv<br />
<br />
Then we process this `test.mkv` file into a smaller `test.webm` end product. Complex switches like `c:a` & `c:v` convert the stream into what's needed for [http://en.wikipedia.org/wiki/WebM WebM].<br />
<br />
$ ffmpeg -y -i test.mkv -c:a libvorbis -q:a 7 -c:v libvpx -b:v 2000k test.webm<br />
<br />
See https://github.com/kaihendry/recordmydesktop2.0/blob/master/r2d2.sh for a more fleshed out example.<br />
<br />
=== VOB to any container ===<br />
Concatenate the desired [[Wikipedia:VOB|VOB]] files into a single VOB file: <br />
$ cat VTS_01_1.VOB VTS_01_2.VOB VTS_01_3.VOB VTS_01_4.VOB > Transformers.3.Dark.of.the.Moon.VOB<br />
Or concatenate and then pipe the output VOB to FFmpeg: <br />
$ cat VTS_01_1.VOB VTS_01_2.VOB VTS_01_3.VOB VTS_01_4.VOB > Transformers.3.Dark.of.the.Moon.VOB | ffmpeg -i ...<br />
<br />
=== x264 Lossless ===<br />
The ''ultrafast'' preset will provide the fastest encoding and is useful for quick capturing (such as screencasting):<br />
{{bc|ffmpeg -i input -vcodec libx264 -preset ultrafast -qp 0 -acodec copy output.mkv}}<br />
On the opposite end of the preset spectrum is ''veryslow'' and will encode slower than ''ultrafast'' but provide a smaller output file size:<br />
{{bc|ffmpeg -i input -vcodec libx264 -preset veryslow -qp 0 -acodec copy output.mkv}}<br />
Both examples will provide the same quality output.<br />
<br />
=== Single-pass MPEG-2 (near lossless) ===<br />
Allow FFmpeg to automatically set DVD standardized parameters. Encode to DVD [[Wikipedia:MPEG-2|MPEG-2]] at a frame rate of 30 frames/second:<br />
<br />
ffmpeg -i 13.Assassins.VOB -target ntsc-dvd -sameq 13.Assassins.mpg<br />
<br />
Encode to DVD MPEG-2 at a frame rate of 24 frames/second:<br />
<br />
ffmpeg -i 13.Assassins.VOB -target film-dvd -sameq 13.Assassins.mpg<br />
<br />
=== x264: Constant Rate Factor ===<br />
Used when you want a specific quality output. General usage is to use the highest {{ic|-crf}} value that still provides an acceptable quality. A sane range is 18-28 and 23 is default. 18 is considered to be visually lossless. Use the slowest {{ic|-preset}} you have patience for. See the [https://ffmpeg.org/trac/ffmpeg/wiki/x264EncodingGuide x264 Encoding Guide] for more information.<br />
{{bc|1=ffmpeg -i input -vcodec libx264 -preset slow -crf 22 -acodec libmp3lame -aq 4 output.mkv}}<br />
{{ic|-tune}} option can be used to [http://forum.doom9.org/showthread.php?t=149394 match the type and content of the of media being encoded].<br />
<br />
=== Two-pass x264 (very high-quality) ===<br />
Audio deactivated as only video statistics are recorded during the first of multiple pass runs: <br />
{{bc|1=ffmpeg -i Transformers.3.Dark.of.the.Moon.VOB -an -vcodec libx264 -pass 1 -preset veryslow -threads 0 -b 3000k -x264opts frameref=15:fast_pskip=0 -f rawvideo -y /dev/null}}<br />
Container format is automatically detected and muxed into from the output file extenstion ({{ic|.mkv}}):<br />
{{bc|1=ffmpeg -i Transformers.3.Dark.of.the.Moon.VOB -acodec libvo-aacenc -ab 256k -ar 96000 -vcodec libx264 -pass 2 -preset veryslow -threads 0 -b 3000k -x264opts frameref=15:fast_pskip=0 Transformers.3.Dark.of.the.Moon.mkv}}<br />
<br />
=== Two-pass MPEG-4 (very high-quality) ===<br />
Audio deactivated as only video statistics are logged during the first of multiple pass runs: <br />
{{bc|ffmpeg -i Transformers.3.Dark.of.the.Moon.VOB -an -vcodec mpeg4 -pass 1 -mbd 2 -trellis 2 -flags +cbp+mv0 -pre_dia_size 4 -dia_size 4 -precmp 4 -cmp 4 -subcmp 4 -preme 2 -qns 2 -b 3000k -f rawvideo -y /dev/null}}<br />
<br />
Container format is automatically detected and muxed into from the output file extenstion ({{ic|.avi}}):<br />
{{bc|ffmpeg -i Transformers.3.Dark.of.the.Moon.VOB -acodec copy -vcodec mpeg4 -vtag DX50 -pass 2 -mbd 2 -trellis 2 -flags +cbp+mv0 -pre_dia_size 4 -dia_size 4 -precmp 4 -cmp 4 -subcmp 4 -preme 2 -qns 2 -b 3000k Transformers.3.Dark.of.the.Moon.avi}}<br />
* Introducing {{ic|threads}}={{ic|n}}>{{ic|1}} for {{ic|-vcodec mpeg4}} may skew the effects of [[Wikipedia:Motion_estimation|motion estimation]] and lead to [http://ffmpeg.org/faq.html#Why-do-I-see-a-slight-quality-degradation-with-multithreaded-MPEG_002a-encoding_003f reduced video quality] and compression efficiency.<br />
* The two-pass MPEG-4 example above also supports output to the [[Wikipedia:MPEG-4_Part_14|MP4]] container (replace {{ic|.avi}} with {{ic|.mp4}}).<br />
<br />
==== Determining bitrates with fixed output file sizes ====<br />
* (Desired File Size in MB - Audio File Size in MB) '''x''' 8192 kb/MB '''/''' Length of Media in Seconds (s) '''=''' [[Wikipedia:Bitrate|Bitrate]] in kb/s<br />
:* (3900 MB - 275 MB) = 3625 MB '''x''' 8192 kb/MB '''/''' 8830 s = 3363 kb/s required to achieve an approximate total output file size of 3900 MB<br />
<br />
=== Softsubs to hardsubs ===<br />
If have a softsubbed video (eg. ASS/SSA subs in a mkv container like most anime) you can 'burn' these subs into a new file to be played on a device which does not support subs or is to weak to display complex subs.<br />
<br />
* Install {{ic|mkvtoolnix-cli}} to pull out *.ass files from *.mkv files.<br />
<br />
* Recompile {{ic|ffmpeg}} with {{ic|--enable-libass}} if it is not already enabled in your ffmpeg build. See [[ABS]] for easy recompiling.<br />
<br />
* Pull out subs from your file. This command assumes that track #2 is the ASS/SSA track. Use {{ic|mkvinfo}} if it is not.<br />
{{bc|mkvextract tracks YourFile.mkv 2:YourFile.ass}}<br />
<br />
* Recode file with ffmpeg. See sections above for suitable options. It is very important to disable sub-recording {{ic|-sn}} and enable sub-rendering {{ic|<nowiki>-vf ass=YourFile.ass</nowiki>}}<br />
<br />
Output is set as *.mp4 since the default Android 4.2 player dislikes *.mkv. (But VLC on Android works with mkv). Example:<br />
{{bc|<nowiki>ffmpeg -i YourFile.mkv -sn -vcodec libx264 -crf 18 -preset slow -vf ass=YourFile.ass -acodec copy Output.mp4</nowiki>}}<br />
<br />
== Preset files ==<br />
=== Creating presets ===<br />
<br />
Populate {{ic|~/.ffmpeg}} with the default [http://ffmpeg.org/ffmpeg-doc.html#SEC13 preset files]: <br />
<br />
$ cp -iR /usr/share/ffmpeg ~/.ffmpeg<br />
<br />
Create new and/or modify the default preset files:<br />
<br />
{{hc|~/.ffmpeg/libavcodec-vhq.ffpreset|<nowiki><br />
vtag=DX50<br />
mbd=2<br />
trellis=2<br />
flags=+cbp+mv0<br />
pre_dia_size=4<br />
dia_size=4<br />
precmp=4<br />
cmp=4<br />
subcmp=4<br />
preme=2<br />
qns=2</nowiki>}}<br />
<br />
=== Using preset files ===<br />
<br />
Enable the {{ic|-vpre}} option after declaring the desired {{ic|-vcodec}}<br />
<br />
==== {{ic|libavcodec-vhq.ffpreset}} ====<br />
<br />
* {{ic|libavcodec}} '''=''' Name of the vcodec/acodec<br />
* {{ic|vhq}} '''=''' Name of specific preset to be called out<br />
* {{ic|ffpreset}} '''=''' FFmpeg preset filetype suffix <br />
<br />
===== Two-pass MPEG-4 (very high quality) =====<br />
<br />
First pass of a multipass (bitrate) ratecontrol transcode:<br />
{{bc|ffmpeg -i 13.Assassins.2010.mpg -an -vcodec mpeg4 -pass 1 -vpre vhq -f rawvideo -y /dev/null}}<br />
Ratecontrol based on the video statistics logged from the first pass: <br />
{{bc|ffmpeg -i 13.Assassins.2010.mpg -acodec libvorbis -aq 8 -ar 48000 -vcodec mpeg4 -pass 2 -vpre vhq -b 3000k 13.Assassins.2010.mp4}}<br />
<br />
* '''libvorbis quality settings (VBR)'''<br />
:* -aq 4 '''=''' 128 kb/s<br />
:* -aq 5 '''=''' 160 kb/s<br />
:* -aq 6 '''=''' 192 kb/s<br />
:* -aq 7 '''=''' 224 kb/s<br />
:* -aq 8 '''=''' 256 kb/s<br />
<br />
*[http://www.geocities.jp/aoyoume/aotuv/ aoTuV] is generally preferred over [http://vorbis.com/ libvorbis] provided by [http://www.xiph.org/ Xiph.Org] and is provided by [https://aur.archlinux.org/packages.php?ID=6155 libvorbis-aotuv] in the [[AUR]].<br />
<br />
== Volume gain ==<br />
<br />
Change the audio volume in multiples of 256 where '''256 = 100%''' (normal) volume. Additional values such as 400 are also valid options. <br />
-vol 256 = 100%<br />
-vol 512 = 200%<br />
-vol 768 = 300%<br />
-vol 1024 = 400%<br />
-vol 2048 = 800%<br />
<br />
To double the volume '''(512 = 200%)''' of an [[Wikipedia:Mp3|MP3]] file:<br />
ffmpeg -i example.mp3 -vol 512 loud-example.mp3<br />
<br />
To quadruple the volume '''(1024 = 400%)''' of an [[Wikipedia:Ogg|Ogg]] file:<br />
ffmpeg -i example.ogg -vol 1024 loud-example.ogg<br />
<br />
Note that gain metadata is only written to the output file. Unlike mp3gain or ogggain, the source sound file is untouched.<br />
<br />
== Extracting audio ==<br />
<br />
{{bc|$ ffmpeg -i The.Kings.Speech.mpg<br><br />
Input #0, avi, from 'The.Kings.Speech.2010.mpg':<br> Duration: 01:58:28.96, start: 0.000000, bitrate: 3000 kb/s<br> Stream #0.0: Video: mpeg4, yuv420p, 720x480 [PAR 1:1 DAR 16:9], 29.97 tbr, 29.97 tbn, 29.97 tbc<br> Stream #0.1: Audio: ac3, 48000 Hz, stereo, s16, 384 kb/s<br> Stream #0.2: Audio: ac3, 48000 Hz, 5.1, s16, 448 kb/s<br> Stream #0.3: Audio: dts, 48000 Hz, 5.1 768 kb/s}}<br />
<br />
Extract the first ({{ic|-map 0:1}}) [[Wikipedia:Dolby_Digital|AC-3]] encoded audio stream exactly as it was multiplexed into the file: <br />
{{bc|ffmpeg -i The.Kings.Speech.mpg -map 0:1 -acodec copy -vn The.Kings.Speech.ac3}}<br />
Convert the third ({{ic|-map 0:3}}) [[Wikipedia:DTS_(sound_system)|DTS]] audio stream to an [[Wikipedia:Advanced_Audio_Coding|AAC]] file with a bitrate of 192 kb/s and a [[Wikipedia:Sampling_rate|sampling rate]] of 96000 Hz:<br />
{{bc|ffmpeg -i The.Kings.Speech.mpg -map 0:3 -acodec libvo-aacenc -ab 192k -ar 96000 -vn The.Kings.Speech.aac}}<br />
{{ic|-vn}} disables the processing of the video stream.<br />
<br />
Extract audio stream with certain time interval: <br />
{{bc|ffmpeg -ss 00:01:25 -t 00:00:05 -i The.Kings.Speech.mpg -map 0:1 -acodec copy -vn The.Kings.Speech.ac3}}<br />
{{ic|-ss}} specifies the start point, and {{ic|-t}} specifies the duration.<br />
<br />
=== Stripping audio ===<br />
<br />
# Copy the first video stream ({{ic|-map 0:0}}) along with the second AC-3 audio stream ({{ic|-map 0:2}}).<br />
# Convert the AC-3 audio stream to two-channel MP3 with a bitrate of 128 kb/s and a sampling rate of 48000 Hz.<br />
{{bc|ffmpeg -i The.Kings.Speech.mpg -map 0:0 -map 0:2 -vcodec copy -acodec libmp3lame -ab 128k -ar 48000 -ac 2 The.Kings.Speech.mkv}}<br />
{{bc|$ ffmpeg -i The.Kings.Speech.mkv<br><br />
Input #0, avi, from 'The.Kings.Speech.2010.mpg':<br> Duration: 01:58:28.96, start: 0.000000, bitrate: 3000 kb/s<br> Stream #0.0: Video: mpeg4, yuv420p, 720x480 [PAR 1:1 DAR 16:9], 29.97 tbr, 29.97 tbn, 29.97 tbc<br> Stream #0.1: Audio: mp3, 48000 Hz, stereo, s16, 128 kb/s}}<br />
{{Note|Removing undesired audio streams allows for additional bits to be allocated towards improving video quality.}}<br />
<br />
== Adding subtitles ==<br />
<br />
FFmpeg does not currently support muxing [[Wikipedia:Category:Subtitle_file_formats|subtitle files]] into existing streams. See [[Mencoder#Adding_SubRip_subtitles_to_a_file|MEncoder]] for subtitle muxing support.<br />
<br />
== Recording webcam ==<br />
<br />
FFmpeg supports grabbing input from Video4Linux2 devices. The following command will record a video from the webcam, assuming that the webcam is correctly recognized under {{Ic|/dev/video0}}:<br />
<br />
$ ffmpeg -f v4l2 -s 640x480 -i /dev/video0 out.mpg<br />
<br />
The above produces a silent video. It is also possible to include audio sources from a microphone. The following command will include a stream from the default [[Advanced Linux Sound Architecture|ALSA]] recording device into the video:<br />
<br />
$ ffmpeg -f alsa -i default -f v4l2 -s 640x480 -i /dev/video0 out.mpg<br />
<br />
To use [[PulseAudio]] with an ALSA backend:<br />
<br />
$ ffmpeg -f alsa -i pulse -f v4l2 -s 640x480 -i /dev/video0 out.mpg<br />
<br />
For a higher quality capture, try encoding the output using higher quality codecs:<br />
<br />
$ ffmpeg -f alsa -i default -f v4l2 -s 640x480 -i /dev/video0 -acodec flac -vcodec libx264 out.mkv<br />
<br />
== Package removal ==<br />
<br />
[[pacman]] will not [[Pacman#Removing_packages|remove]] configuration files outside of the defaults that were created during package installation. This includes user-created preset files.<br />
<br />
== Additional resources ==<br />
* [http://mewiki.project357.com/wiki/X264_Settings x264 Settings] - MeWiki Documentation<br />
* [http://ffmpeg.org/ffmpeg-doc.html FFmpeg Documentation] - Official Documentation<br />
* [http://www.mplayerhq.hu/DOCS/HTML/en/menc-feat-x264.html Encoding with the x264 Codec] - MEncoder Documentation<br />
* [http://avidemux.org/admWiki/doku.php?id=tutorial:h.264 H.264 eEcoding Guide] - Avidemux Wiki<br />
* [http://howto-pages.org/ffmpeg/ Using FFmpeg] - Linux How To Pages</div>Ekhttps://wiki.archlinux.org/index.php?title=FFmpeg&diff=236847FFmpeg2012-11-26T15:17:49Z<p>Ek: Provided additional encoding example. How to hardsub a softsubbed video using mkvextract and libass.</p>
<hr />
<div>[[Category:Audio/Video]]<br />
{{Article summary start}}<br />
{{Article summary text|This article attempts to walk users through the installation, usage and configuration of FFmpeg.}}<br />
{{Article summary end}}<br />
<br />
[http://www.ffmpeg.org/ FFmpeg] is command-line driven collection of tools which enables the decoding, encoding, conversion and playback of [http://ffmpeg.org/general.html#Supported-File-Formats-and-Codecs most audio and video streams].<br />
<br />
== Package installation ==<br />
{{Pkg|FFmpeg}} is part of the [[Official_repositories#.5Bextra.5D|official Arch Linux [extra] repository]].<br />
<br />
{{bc|# pacman -S ffmpeg}}<br />
<br />
== Encoding examples ==<br />
<br />
=== Screen cast to .webm ===<br />
<br />
Using '''x11grab''' to video grab your display and using '''ALSA''' for sound. First we create lossless raw file `test.mkv`.<br />
<br />
$ ffmpeg -f x11grab -r 30 -i :0.0 -f alsa -i hw:0,0 -acodec flac -vcodec ffvhuff test.mkv<br />
<br />
Then we process this `test.mkv` file into a smaller `test.webm` end product. Complex switches like `c:a` & `c:v` convert the stream into what's needed for [http://en.wikipedia.org/wiki/WebM WebM].<br />
<br />
$ ffmpeg -y -i test.mkv -c:a libvorbis -q:a 7 -c:v libvpx -b:v 2000k test.webm<br />
<br />
See https://github.com/kaihendry/recordmydesktop2.0/blob/master/r2d2.sh for a more fleshed out example.<br />
<br />
=== VOB to any container ===<br />
Concatenate the desired [[Wikipedia:VOB|VOB]] files into a single VOB file: <br />
$ cat VTS_01_1.VOB VTS_01_2.VOB VTS_01_3.VOB VTS_01_4.VOB > Transformers.3.Dark.of.the.Moon.VOB<br />
Or concatenate and then pipe the output VOB to FFmpeg: <br />
$ cat VTS_01_1.VOB VTS_01_2.VOB VTS_01_3.VOB VTS_01_4.VOB > Transformers.3.Dark.of.the.Moon.VOB | ffmpeg -i ...<br />
<br />
=== x264 Lossless ===<br />
The ''ultrafast'' preset will provide the fastest encoding and is useful for quick capturing (such as screencasting):<br />
{{bc|ffmpeg -i input -vcodec libx264 -preset ultrafast -qp 0 -acodec copy output.mkv}}<br />
On the opposite end of the preset spectrum is ''veryslow'' and will encode slower than ''ultrafast'' but provide a smaller output file size:<br />
{{bc|ffmpeg -i input -vcodec libx264 -preset veryslow -qp 0 -acodec copy output.mkv}}<br />
Both examples will provide the same quality output.<br />
<br />
=== Single-pass MPEG-2 (near lossless) ===<br />
Allow FFmpeg to automatically set DVD standardized parameters. Encode to DVD [[Wikipedia:MPEG-2|MPEG-2]] at a frame rate of 30 frames/second:<br />
<br />
ffmpeg -i 13.Assassins.VOB -target ntsc-dvd -sameq 13.Assassins.mpg<br />
<br />
Encode to DVD MPEG-2 at a frame rate of 24 frames/second:<br />
<br />
ffmpeg -i 13.Assassins.VOB -target film-dvd -sameq 13.Assassins.mpg<br />
<br />
=== x264: Constant Rate Factor ===<br />
Used when you want a specific quality output. General usage is to use the highest {{ic|-crf}} value that still provides an acceptable quality. A sane range is 18-28 and 23 is default. 18 is considered to be visually lossless. Use the slowest {{ic|-preset}} you have patience for. See the [https://ffmpeg.org/trac/ffmpeg/wiki/x264EncodingGuide x264 Encoding Guide] for more information.<br />
{{bc|1=ffmpeg -i input -vcodec libx264 -preset slow -crf 22 -acodec libmp3lame -aq 4 output.mkv}}<br />
{{ic|-tune}} option can be used to [http://forum.doom9.org/showthread.php?t=149394 match the type and content of the of media being encoded].<br />
<br />
=== Two-pass x264 (very high-quality) ===<br />
Audio deactivated as only video statistics are recorded during the first of multiple pass runs: <br />
{{bc|1=ffmpeg -i Transformers.3.Dark.of.the.Moon.VOB -an -vcodec libx264 -pass 1 -preset veryslow -threads 0 -b 3000k -x264opts frameref=15:fast_pskip=0 -f rawvideo -y /dev/null}}<br />
Container format is automatically detected and muxed into from the output file extenstion ({{ic|.mkv}}):<br />
{{bc|1=ffmpeg -i Transformers.3.Dark.of.the.Moon.VOB -acodec libvo-aacenc -ab 256k -ar 96000 -vcodec libx264 -pass 2 -preset veryslow -threads 0 -b 3000k -x264opts frameref=15:fast_pskip=0 Transformers.3.Dark.of.the.Moon.mkv}}<br />
<br />
=== Two-pass MPEG-4 (very high-quality) ===<br />
Audio deactivated as only video statistics are logged during the first of multiple pass runs: <br />
{{bc|ffmpeg -i Transformers.3.Dark.of.the.Moon.VOB -an -vcodec mpeg4 -pass 1 -mbd 2 -trellis 2 -flags +cbp+mv0 -pre_dia_size 4 -dia_size 4 -precmp 4 -cmp 4 -subcmp 4 -preme 2 -qns 2 -b 3000k -f rawvideo -y /dev/null}}<br />
<br />
Container format is automatically detected and muxed into from the output file extenstion ({{ic|.avi}}):<br />
{{bc|ffmpeg -i Transformers.3.Dark.of.the.Moon.VOB -acodec copy -vcodec mpeg4 -vtag DX50 -pass 2 -mbd 2 -trellis 2 -flags +cbp+mv0 -pre_dia_size 4 -dia_size 4 -precmp 4 -cmp 4 -subcmp 4 -preme 2 -qns 2 -b 3000k Transformers.3.Dark.of.the.Moon.avi}}<br />
* Introducing {{ic|threads}}={{ic|n}}>{{ic|1}} for {{ic|-vcodec mpeg4}} may skew the effects of [[Wikipedia:Motion_estimation|motion estimation]] and lead to [http://ffmpeg.org/faq.html#Why-do-I-see-a-slight-quality-degradation-with-multithreaded-MPEG_002a-encoding_003f reduced video quality] and compression efficiency.<br />
* The two-pass MPEG-4 example above also supports output to the [[Wikipedia:MPEG-4_Part_14|MP4]] container (replace {{ic|.avi}} with {{ic|.mp4}}).<br />
<br />
==== Determining bitrates with fixed output file sizes ====<br />
* (Desired File Size in MB - Audio File Size in MB) '''x''' 8192 kb/MB '''/''' Length of Media in Seconds (s) '''=''' [[Wikipedia:Bitrate|Bitrate]] in kb/s<br />
:* (3900 MB - 275 MB) = 3625 MB '''x''' 8192 kb/MB '''/''' 8830 s = 3363 kb/s required to achieve an approximate total output file size of 3900 MB<br />
<br />
=== Softsubs to hardsubs ===<br />
If have a softsubbed video (eg. ASS/SSA subs in a mkv container like most anime) you can 'burn' these subs into a new file to be played on a device which does not support subs or is to weak to display complex subs.<br />
<br />
* Install {{ic|mkvtoolnix-cli}} to pull out *.ass files from *.mkv files.<br />
<br />
* Recompile {{ic|ffmpeg}} with {{ic|--enable-libass}} if it is not already enabled in your ffmpeg build. See [[ABS]] for easy recompiling.<br />
<br />
* Pull out subs from your file. This command assumes that track #2 is the ASS/SSA track. Use {{ic|mkvinfo}} if it is not.<br />
{{bc|mkvextract tracks YourFile.mkv 2:YourFile.ass}}<br />
<br />
* Recode file with ffmpeg. See sections above for suitable options. It is very important to disable sub-recording {{ic|-sn}} and enable sub-rendering {{ic|<nowiki>-vf ass=YourFile.ass</nowiki>}}<br />
<br />
Example:<br />
{{bc|<nowiki>ffmpeg -i YourFile.mkv -sn -vcodec libx264 -crf 18 -preset slow -vf ass=YourFile.ass -acodec copy Output.mkv</nowiki>}}<br />
<br />
== Preset files ==<br />
=== Creating presets ===<br />
<br />
Populate {{ic|~/.ffmpeg}} with the default [http://ffmpeg.org/ffmpeg-doc.html#SEC13 preset files]: <br />
<br />
$ cp -iR /usr/share/ffmpeg ~/.ffmpeg<br />
<br />
Create new and/or modify the default preset files:<br />
<br />
{{hc|~/.ffmpeg/libavcodec-vhq.ffpreset|<nowiki><br />
vtag=DX50<br />
mbd=2<br />
trellis=2<br />
flags=+cbp+mv0<br />
pre_dia_size=4<br />
dia_size=4<br />
precmp=4<br />
cmp=4<br />
subcmp=4<br />
preme=2<br />
qns=2</nowiki>}}<br />
<br />
=== Using preset files ===<br />
<br />
Enable the {{ic|-vpre}} option after declaring the desired {{ic|-vcodec}}<br />
<br />
==== {{ic|libavcodec-vhq.ffpreset}} ====<br />
<br />
* {{ic|libavcodec}} '''=''' Name of the vcodec/acodec<br />
* {{ic|vhq}} '''=''' Name of specific preset to be called out<br />
* {{ic|ffpreset}} '''=''' FFmpeg preset filetype suffix <br />
<br />
===== Two-pass MPEG-4 (very high quality) =====<br />
<br />
First pass of a multipass (bitrate) ratecontrol transcode:<br />
{{bc|ffmpeg -i 13.Assassins.2010.mpg -an -vcodec mpeg4 -pass 1 -vpre vhq -f rawvideo -y /dev/null}}<br />
Ratecontrol based on the video statistics logged from the first pass: <br />
{{bc|ffmpeg -i 13.Assassins.2010.mpg -acodec libvorbis -aq 8 -ar 48000 -vcodec mpeg4 -pass 2 -vpre vhq -b 3000k 13.Assassins.2010.mp4}}<br />
<br />
* '''libvorbis quality settings (VBR)'''<br />
:* -aq 4 '''=''' 128 kb/s<br />
:* -aq 5 '''=''' 160 kb/s<br />
:* -aq 6 '''=''' 192 kb/s<br />
:* -aq 7 '''=''' 224 kb/s<br />
:* -aq 8 '''=''' 256 kb/s<br />
<br />
*[http://www.geocities.jp/aoyoume/aotuv/ aoTuV] is generally preferred over [http://vorbis.com/ libvorbis] provided by [http://www.xiph.org/ Xiph.Org] and is provided by [https://aur.archlinux.org/packages.php?ID=6155 libvorbis-aotuv] in the [[AUR]].<br />
<br />
== Volume gain ==<br />
<br />
Change the audio volume in multiples of 256 where '''256 = 100%''' (normal) volume. Additional values such as 400 are also valid options. <br />
-vol 256 = 100%<br />
-vol 512 = 200%<br />
-vol 768 = 300%<br />
-vol 1024 = 400%<br />
-vol 2048 = 800%<br />
<br />
To double the volume '''(512 = 200%)''' of an [[Wikipedia:Mp3|MP3]] file:<br />
ffmpeg -i example.mp3 -vol 512 loud-example.mp3<br />
<br />
To quadruple the volume '''(1024 = 400%)''' of an [[Wikipedia:Ogg|Ogg]] file:<br />
ffmpeg -i example.ogg -vol 1024 loud-example.ogg<br />
<br />
Note that gain metadata is only written to the output file. Unlike mp3gain or ogggain, the source sound file is untouched.<br />
<br />
== Extracting audio ==<br />
<br />
{{bc|$ ffmpeg -i The.Kings.Speech.mpg<br><br />
Input #0, avi, from 'The.Kings.Speech.2010.mpg':<br> Duration: 01:58:28.96, start: 0.000000, bitrate: 3000 kb/s<br> Stream #0.0: Video: mpeg4, yuv420p, 720x480 [PAR 1:1 DAR 16:9], 29.97 tbr, 29.97 tbn, 29.97 tbc<br> Stream #0.1: Audio: ac3, 48000 Hz, stereo, s16, 384 kb/s<br> Stream #0.2: Audio: ac3, 48000 Hz, 5.1, s16, 448 kb/s<br> Stream #0.3: Audio: dts, 48000 Hz, 5.1 768 kb/s}}<br />
<br />
Extract the first ({{ic|-map 0:1}}) [[Wikipedia:Dolby_Digital|AC-3]] encoded audio stream exactly as it was multiplexed into the file: <br />
{{bc|ffmpeg -i The.Kings.Speech.mpg -map 0:1 -acodec copy -vn The.Kings.Speech.ac3}}<br />
Convert the third ({{ic|-map 0:3}}) [[Wikipedia:DTS_(sound_system)|DTS]] audio stream to an [[Wikipedia:Advanced_Audio_Coding|AAC]] file with a bitrate of 192 kb/s and a [[Wikipedia:Sampling_rate|sampling rate]] of 96000 Hz:<br />
{{bc|ffmpeg -i The.Kings.Speech.mpg -map 0:3 -acodec libvo-aacenc -ab 192k -ar 96000 -vn The.Kings.Speech.aac}}<br />
{{ic|-vn}} disables the processing of the video stream.<br />
<br />
Extract audio stream with certain time interval: <br />
{{bc|ffmpeg -ss 00:01:25 -t 00:00:05 -i The.Kings.Speech.mpg -map 0:1 -acodec copy -vn The.Kings.Speech.ac3}}<br />
{{ic|-ss}} specifies the start point, and {{ic|-t}} specifies the duration.<br />
<br />
=== Stripping audio ===<br />
<br />
# Copy the first video stream ({{ic|-map 0:0}}) along with the second AC-3 audio stream ({{ic|-map 0:2}}).<br />
# Convert the AC-3 audio stream to two-channel MP3 with a bitrate of 128 kb/s and a sampling rate of 48000 Hz.<br />
{{bc|ffmpeg -i The.Kings.Speech.mpg -map 0:0 -map 0:2 -vcodec copy -acodec libmp3lame -ab 128k -ar 48000 -ac 2 The.Kings.Speech.mkv}}<br />
{{bc|$ ffmpeg -i The.Kings.Speech.mkv<br><br />
Input #0, avi, from 'The.Kings.Speech.2010.mpg':<br> Duration: 01:58:28.96, start: 0.000000, bitrate: 3000 kb/s<br> Stream #0.0: Video: mpeg4, yuv420p, 720x480 [PAR 1:1 DAR 16:9], 29.97 tbr, 29.97 tbn, 29.97 tbc<br> Stream #0.1: Audio: mp3, 48000 Hz, stereo, s16, 128 kb/s}}<br />
{{Note|Removing undesired audio streams allows for additional bits to be allocated towards improving video quality.}}<br />
<br />
== Adding subtitles ==<br />
<br />
FFmpeg does not currently support muxing [[Wikipedia:Category:Subtitle_file_formats|subtitle files]] into existing streams. See [[Mencoder#Adding_SubRip_subtitles_to_a_file|MEncoder]] for subtitle muxing support.<br />
<br />
== Recording webcam ==<br />
<br />
FFmpeg supports grabbing input from Video4Linux2 devices. The following command will record a video from the webcam, assuming that the webcam is correctly recognized under {{Ic|/dev/video0}}:<br />
<br />
$ ffmpeg -f v4l2 -s 640x480 -i /dev/video0 out.mpg<br />
<br />
The above produces a silent video. It is also possible to include audio sources from a microphone. The following command will include a stream from the default [[Advanced Linux Sound Architecture|ALSA]] recording device into the video:<br />
<br />
$ ffmpeg -f alsa -i default -f v4l2 -s 640x480 -i /dev/video0 out.mpg<br />
<br />
To use [[PulseAudio]] with an ALSA backend:<br />
<br />
$ ffmpeg -f alsa -i pulse -f v4l2 -s 640x480 -i /dev/video0 out.mpg<br />
<br />
For a higher quality capture, try encoding the output using higher quality codecs:<br />
<br />
$ ffmpeg -f alsa -i default -f v4l2 -s 640x480 -i /dev/video0 -acodec flac -vcodec libx264 out.mkv<br />
<br />
== Package removal ==<br />
<br />
[[pacman]] will not [[Pacman#Removing_packages|remove]] configuration files outside of the defaults that were created during package installation. This includes user-created preset files.<br />
<br />
== Additional resources ==<br />
* [http://mewiki.project357.com/wiki/X264_Settings x264 Settings] - MeWiki Documentation<br />
* [http://ffmpeg.org/ffmpeg-doc.html FFmpeg Documentation] - Official Documentation<br />
* [http://www.mplayerhq.hu/DOCS/HTML/en/menc-feat-x264.html Encoding with the x264 Codec] - MEncoder Documentation<br />
* [http://avidemux.org/admWiki/doku.php?id=tutorial:h.264 H.264 eEcoding Guide] - Avidemux Wiki<br />
* [http://howto-pages.org/ffmpeg/ Using FFmpeg] - Linux How To Pages</div>Ekhttps://wiki.archlinux.org/index.php?title=Chromium&diff=235109Chromium2012-11-12T18:01:33Z<p>Ek: Added possible workaround for the combination of certain versions Chrome & PA-Alsa-Bridge & Pepper-Flash not playing sound or playing distorted sound.</p>
<hr />
<div>[[es:Chromium]]<br />
[[fr:chromium]]<br />
[[it:Chromium]]<br />
[[zh-CN:Chromium]]<br />
[[Category:Web Browser]]<br />
{{Article summary start}}<br />
{{Article summary text|General information, installation and troubleshooting for Chromium.}}<br />
{{Article summary heading|Related}}<br />
{{Article summary wiki|Chromium Tips and Tweaks}}<br />
{{Article summary wiki|Browser Plugins}}<br />
{{Article summary wiki|Firefox}}<br />
{{Article summary wiki|Opera}}<br />
{{Article summary end}}<br />
[[Wikipedia:Chromium (web browser)|Chromium]] is an open source graphical web browser from Google, based on the [[Wikipedia:WebKit|WebKit]] rendering engine.<br />
<br />
== Installation ==<br />
Chromium can be [[Pacman|installed]] with the package {{Pkg|chromium}}, available in the [[official repositories]].<br />
<br />
In the [[AUR]] you can also find:<br />
* {{AUR|chromium-dev}} - a development version of the Chromium browser.<br />
* {{AUR|chromium-update}} - an update. script for Chromium nighly builds, pre-compiled on the Chromium buildbot server.<br />
* {{AUR|chromium-browser-bin}} - a binary version of the latest Chromium build.<br />
* {{AUR|iron-bin}} - a binary version of Chromium without Google's 'tracking features'<br />
<br />
{{Note|Compiling {{AUR|chromium-dev}} takes at least as long as compiling the Linux kernel.}}<br />
<br />
Various versions of the modified Google Chrome browser can be found in the [[AUR]]:<br />
* {{AUR|google-chrome}}<br />
* {{AUR|google-chrome-beta}}<br />
* {{AUR|google-chrome-dev}}<br />
<br />
See these [https://code.google.com/p/chromium/wiki/ChromiumBrowserVsGoogleChrome two] [http://news.softpedia.com/news/Google-Chrome-vs-Chromium-Understanding-Stable-Beta-Dev-Releases-and-Version-No-140060.shtml articles] for an explanation of the differences between Stable/Beta/Dev, as well as Chromium vs. Chrome and the version numbers.<br />
<br />
== Configuration ==<br />
<br />
=== File associations ===<br />
<br />
Unlike [[Firefox]], Chromium does not maintain its own database of mimetype-to-application associations. Instead, it relies on [[Xdg-open|xdg-open]] to open files and other mime types, for example, [[Wikipedia:Magnet URI scheme|magnet links]].<br />
<br />
There are exceptions to this rule though. In the case of ''mailto'' URIs, Chromium calls out to {{ic|xdg-email}} which is similar to {{ic|xdg-open}}. Other protocol handlers may have equivalent scripts so check {{ic|/usr/bin/xdg*}}. <br />
<br />
The behaviour of {{ic|xdg-*}} tools is managed automatically in environments such as [[GNOME]], [[KDE]], [[Xfce]] or [[LXDE]], but does not work in others. Usually this behaviour can be fixed by tricking them into thinking that they are operating in one of the supported desktop environments. Depending on your environment one may work and another will not so trying each is recommended. You can set the desktop environment with the following variable:<br />
export DE=INSERT_DE_HERE<br />
<br />
where the recognised desktop environments are: '''gnome''', '''kde''', '''xfce''' and '''lxde'''. For the variable to be always set, put it somewhere like {{ic|~/.xinitrc}} or {{ic|~/.bashrc}}.<br />
<br />
An alternative is to edit the {{ic|xdg-open}} or {{ic|xdg-email}} scripts and '''hard-code''' a useful DE. At the bottom of the file you will see something like this:<br />
{{hc|/usr/bin/xdg-open|<nowiki><br />
detectDE<br />
<br />
if [ x"$DE" = x"" ]; then<br />
DE=generic<br />
fi<br />
<br />
DEBUG 2 "Selected DE $DE"<br />
<br />
# if BROWSER variable is not set, check some well known browsers instead<br />
if [ x"$BROWSER" = x"" ]; then<br />
BROWSER=links2:elinks:links:lynx:w3m<br />
if [ -n "$DISPLAY" ]; then<br />
BROWSER=x-www-browser:firefox:seamonkey:mozilla:epiphany:konqueror:chromium-browser:google-chrome:$BROWSER<br />
fi<br />
fi<br />
<br />
case "$DE" in<br />
kde)<br />
open_kde "$url"<br />
;;<br />
<br />
gnome*)<br />
open_gnome "$url"<br />
;;<br />
<br />
mate)<br />
open_mate "$url"<br />
;;<br />
<br />
xfce)<br />
open_xfce "$url"<br />
;;<br />
<br />
lxde)<br />
open_lxde "$url"<br />
;;<br />
<br />
generic)<br />
open_generic "$url"<br />
;;<br />
<br />
*)<br />
exit_failure_operation_impossible "no method available for opening '$url'"<br />
;;<br />
esac</nowiki><br />
}}<br />
<br />
change the third line: {{ic|DE&#61;generic}} to one of the supported desktop environments (e.g. {{ic|DE&#61;gnome}}). <br />
<br />
{{Note|These changes are lost when any of the utilities are upgraded.}}<br />
<br />
An approach which is less useful is to place the required application in the default browser list:<br />
<br />
BROWSER=links2:links:lynx:w3m<br />
if [ -n "$DISPLAY" ]; then<br />
BROWSER=firefox:mozilla:epiphany:konqueror:chromium-browser:google-chrome:$BROWSER<br />
fi<br />
<br />
{{ic|xdg-open}} and {{ic|xdg-email}} fall back to this list of browsers and will use the first that they find to attempt to open the URI. You could add the name of the application to the beginning of the list. However there is no guarantee that the application will be called correctly to meet your needs, e.g. your mail client will open but it will not correctly receive the ''mailto'' address. Also it will only work for one application.<br />
<br />
A fourth option is to make a softlink from your preferred application to one of the names on the browser list. This approach has the same problems as the previous work around. For more discussion on these ideas see [https://bbs.archlinux.org/viewtopic.php?id=81282&p=1 this forum thread].<br />
<br />
=== Font Rendering ===<br />
Chromium is now supposed to use the settings in {{ic|~/.fonts.conf}}, though you may have to edit it manually (see [[Font_Configuration#Basic_settings|Font Configuration]]). If the fonts are still rendered badly, you can use Xft settings [[X resources|as suggested here]]. Create {{ic|~/.Xresources}} if it does not exist and add in:<br />
{{hc|~/.Xresources|<br />
...<br />
! Xft settings ---------------------------------------------------------------<br />
Xft.dpi: 96<br />
Xft.antialias: true<br />
Xft.rgba: rgb<br />
Xft.hinting: true<br />
Xft.hintstyle: hintslight<br />
...<br />
}}<br />
<br />
Then update the X Resources database using:<br />
<br />
{{bc|xrdb -merge ~/.Xresources}}<br />
<br />
{{Note|These settings will affect any application that uses X Resources for font settings; one example is [[Rxvt-unicode|rxvt-unicode]].}}<br />
<br />
==== Non-Latin characters ====<br />
Install needed fonts to correctly display Chinese, Japanese, Korean characters. For examples of recommended fonts for various languages see [[Fonts#Font_packages|Font Packages]].<br />
<br />
=== Default browser ===<br />
The simplest way to make Chromium the default browser is to set variable {{Ic|<nowiki>$BROWSER=chromium</nowiki>}} in {{ic|~/.profile}}<br />
if [ -n "$DISPLAY" ]; then<br />
BROWSER=chromium<br />
fi<br />
<br />
To test if this was applied successfully, try to open an URL with {{ic|xdg-open}} as follows:<br />
$ xdg-open http://google.com/<br />
If everything went well, either a new tab inside Chromium, or a new window would open and display the Google homepage, depending on your settings.<br />
<br />
Another option, when using {{AUR|mimeo}}, is to associate "http://" links with Chromium:<br />
{{hc|~/.config/mimeo.conf|<nowiki><br />
/usr/bin/chromium<br />
^http://<br />
</nowiki>}}<br />
<br />
If all of that still does not get it working, you can try adding the following to the {{ic|[Added Associations]}} list in {{ic|~/.local/share/applications/mimeapps.list}}:<br />
x-scheme-handler/http=chromium.desktop<br />
<br />
For more info, see [[Xdg-open]].<br />
<br />
=== Flash Player ===<br />
The Adobe Flash plugin can be [[Pacman|installed]] with the package {{Pkg|flashplugin}}, available in the official repositories. <br />
<br />
While the classic Flash plugin will not be updated for Linux, Chromium can use the Flash plugin from Google Chrome (that uses the new Pepper API). This plugin is available in the [[AUR]] with the {{AUR|chromium-pepper-flash}} or {{AUR|chromium-pepper-flash-stable}} packages. <br />
<br />
{{Note|Make sure to enable the Flash plugin with location {{ic|/usr/lib/PepperFlash/libpepflashplayer.so}} in {{ic|chrome://plugins}} and disable the plugin with location {{ic|/usr/lib/mozilla/plugins/libflashplayer.so}}.}}<br />
<br />
If Pepper Flash doesn't show up in the plugins list (as is the case for Iron) then disable libflashplayer.so and start with the following command.<br />
iron --ppapi-flash-path=/usr/lib/PepperFlash/libpepflashplayer.so --ppapi-flash-version=11.5.31.101<br />
<br />
=== Open PDF files inside Chromium ===<br />
<br />
There are multiple ways of enabling PDF support in Chromium that are detailed below. <br />
<br />
==== Using Google Chrome's libpdf ====<br />
<br />
'''libpdf''' is Google's own implementation of a PDF renderer. While compatible, it is currently only part of Chrome releases, not Chromium ones.<br />
<br />
The easiest way to add it to the latter is using one of the packages provided in the [[AUR]]:<br />
* {{AUR|chromium-stable-libpdf}} for the stable version of the browser.<br />
* {{AUR|chromium-libpdf}} for a development version that installs to {{ic|/usr/lib/chromium}} (such as {{AUR|chromium-dev}}).<br />
* {{AUR|chromium-browser-libpdf}} for a development version that installs to {{ic|/opt/chromium-browser}} (such as {{AUR|chromium-browser-bin}}).<br />
<br />
To do it manually, download a Google Chrome release that corresponds to the version of Chromium you use:<br />
<br />
$ wget https://dl-ssl.google.com/linux/direct/google-chrome-stable_current_i386.deb<br />
$ wget https://dl-ssl.google.com/linux/direct/google-chrome-unstable_current_i386.deb<br />
<br />
$ wget https://dl-ssl.google.com/linux/direct/google-chrome-stable_current_amd64.deb<br />
$ wget https://dl-ssl.google.com/linux/direct/google-chrome-unstable_current_amd64.deb<br />
<br />
Extract the deb file with<br />
$ ar vx <deb-file><br />
<br />
Extract LZMA archive with<br />
$ tar -xJf <lzma-file><br />
<br />
Move {{ic|libpdf.so}} from {{ic|opt/google/chrome/}} to the appropriate directory as stated above. A change of its file permissions and ownership may be necessary (the permission of {{ic|libpdf.so}} should be 755).<br />
<br />
To verify that the installation went correctly: start Chromium, open ''about:plugins'' and check if "Chrome PDF Viewer" is available (it may need to be enabled).<br />
<br />
{{Note|As a new version of Chromium will not update {{ic|libpdf.so}}, it may become incompatible. Thus and with respect to possible security fixes it is advisable to update both at the same time.}}<br />
<br />
==== Using mozplugger ====<br />
{{Box||See the main article: [[Browser Plugins#MozPlugger]]|#E5E5FF|#FCFCFC}}<br />
<br />
For information about the installation see [[Browser Plugins#PDF viewer]].<br />
<br />
==== Using the KParts plugin ====<br />
{{Box||See the main article: [[Browser Plugins#kpartsplugin]]|#E5E5FF|#FCFCFC}}<br />
<br />
=== Certificates ===<br />
<br />
Chromium uses [[Nss|NSS]] for the certificate management. Certificates can be managed (including added) by going to ''Settings'', clicking the ''Show advanced settings..'' link and then ''Manage Certificates''.<br />
<br />
== Tips and Tricks ==<br />
{{Box||See the main article: [[Chromium Tips and Tweaks]]|#E5E5FF|#FCFCFC}}<br />
<br />
== Troubleshooting ==<br />
<br />
=== Proxy Settings ===<br />
There have been many situations in which proxy settings do not work properly, especially if set through the KDE interface. A good method as of now is to use Chromium's command-line options, like {{ic|--proxy-pac-url}} and {{ic|--proxy-server}}, to set your proxy.<br />
<br />
=== Default profile ===<br />
If you cannot get your default profile when you try to run Chromium and get a similar error instead:<br />
{{bc|<br />
$ chromium<br />
[2630:2630:485325611:FATAL:chrome/browser/browser_main.cc(755)] Check failed: profile. <br />
Cannot get default profile. Trace/breakpoint trap<br />
}}<br />
<br />
you have to set the correct owner of the directory {{ic|~/.config/chromium}} as following:<br />
$ sudo chown -R yourusername:yourusergroup /home/yourusername/.config/chromium<br />
<br />
=== WebGL ===<br />
<br />
Sometimes, Chromium will disable WebGL with certain graphics card configurations. This can generally be remedied by typing {{ic|about:flags}} into the URL bar and enabling the WebGL flag. You may also enable WebGL by passing the command line flag {{ic|--enable-webgl}} to Chromium in the terminal.<br />
<br />
There is also the possibility that your graphics card has been blacklisted by Chromium. To override this, pass the flag {{ic|--ignore-gpu-blacklist}} when starting Chromium, alternatively, go to {{ic|about:flags}} and enable ''Override software rendering list''.<br />
<br />
=== Pulseaudio & PA-Alsa-Bridge & Pepper-Flash ===<br />
<br />
Given a certain version of Chrome (23.x seem to exhibit this problem) and Pepper-Flash (11.x) while using the PA-Alsa-Bridge, sound may not play, become distorted, start skipping or outright keep crashing the PA-Alsa-Bridge continously. See [http://code.google.com/p/chromium/issues/detail?id=128870] for the bugreport.<br />
<br />
A possible workaround is to use {{ic|pasuspender}} to suspend Pulseaudio and force Chrome to use Alsa directly.<br />
<br />
First, create an {{ic|~/.asoundrc}} file to default Alsa to your real hardware instead of Pulseaudio. See [[Alsa]] and [http://alsa.opensrc.org/FAQ026] for more information. Exemplary {{ic|~/.asoundrc}}:<br />
<br />
{{hc|~/.asoundrc|<br />
pcm. !default {<br />
type hw<br />
card 0<br />
device 0<br />
}<br />
}}<br />
<br />
Then use {{ic|pasuspender}} to suspend Pulseaudio and force Chrome to use Alsa which now uses your real hardware.<br />
<br />
{{bc|<br />
pasuspender -- google-chrome<br />
}}<br />
<br />
== See Also ==<br />
* [http://www.chromium.org/Home Chromium Homepage]<br />
* [http://googlechromereleases.blogspot.com Google Chrome Release Notes]<br />
* [https://chrome.google.com/webstore/category/home Chrome Web Store]<br />
* [[Wikipedia: Chromium_(web_browser)#Differences_from_Google_Chrome|Differences between Chromium and Google Chrome]]<br />
* [http://peter.sh/experiments/chromium-command-line-switches/ List of Chromium command-line switches]</div>Ekhttps://wiki.archlinux.org/index.php?title=Dm-crypt&diff=189813Dm-crypt2012-03-17T19:45:26Z<p>Ek: Loop devices need to asked for with losetup -f, since Kernel 3.x creates them on demand.</p>
<hr />
<div>[[Category:Security (English)]]<br />
[[Category:File systems (English)]]<br />
{{i18n|System Encryption with LUKS for dm-crypt}}<br />
{{Article summary start}}<br />
{{Article summary text|This tutorial will show you how to set up system encryption with LUKS for dm-crypt.}}<br />
{{Article summary end}}<br />
<br />
== Introduction ==<br />
=== Why Use Encryption? ===<br />
<br />
In the simplest terms encryption is a method for establishing privacy. <br />
<br />
There are presently two approaches to partition level encryption '''data encryption''' and '''system encryption'''.<br />
<br />
'''Data encryption''', defined as encrypting a users data, provides for many benefits including: <br />
<br />
::*Preventing unauthorized physical access to private data.<br />
::*Some confidence in data disposal when discarding obsolete systems.<br />
<br />
However data encryption alone has some significant drawbacks. In modern computing systems, there are many background processes that may store information about encrypted data or parts of the encrypted data itself in non-encrypted areas of the hard drive, thus reducing the effectiveness of any data encryption system in place.<br />
<br />
'''System encryption''', defined as the encryption of the operating system and user data, helps to address some of the inadequacies of data encryption. The benefits of system encryption over data encryption alone include:<br />
<br />
::*Preventing unauthorized physical access to operating system files<br />
::*Preventing unauthorized physical access to private data that may cached by the system.<br />
<br />
In the context of overall system security, system encryption should be viewed as an adjunct to the existing security mechanisms of the operating system that focuses on physical attempts to breach system security which includes:<br />
<br />
::*Attempts to bypass the operating system by inserting a boot CD/USB<br />
::*Copying, modifying, or removing the hard disk drives when the computer is off<br />
<br />
Despite the use of system encryption, there are still points of physical insecurity. These issues revolve around the {{ic|/boot}} partition which must remain unencrypted in order for the machine to properly boot. However, system encryption is presently the best way to minimize the loss of data privacy by physical attempts at invasion.<br />
<br />
{{Warning|Any encryption method employed is only as good as its associated key management. Partition level encryption does not protect you from all forms of security compromise. There are ways to break into computers while they are powered on that are unaffected by disk level encryption. Read the [[System Encryption with LUKS for dm-crypt#Caveats | caveats]] section below!}}<br />
<br />
=== What Methods are Available for System Encryption? ===<br />
<br />
There are multiple current methods that can be employed for system encryption, including:<br />
<br />
;loop-AES ([http://loop-aes.sourceforge.net/ loop-AES]):loop-AES is a descendant of cryptoloop and is a secure and fast solution to system encryption.<br />
:However loop-AES is considered less user-friendly than other options as it requires non-standard kernel support.<br />
<br />
;standard device-mapper encryption ([http://www.saout.de/misc/dm-crypt/ dm-crypt]):This is the standard device mapper which can be used for those who like to have control over all aspects partition management.<br />
<br />
;LUKS for dm-crypt ([http://code.google.com/p/cryptsetup/ LUKS]):LUKS stores all of the needed setup information for dm-crypt on the disk itself and abstracts partition and key management in an attempt to improve ease of use.<br />
<br />
:Briefly some key features that LUKS provides include:<br />
<br />
::*Support for either passphrase or keyfiles as encryption keys<br />
::*Per partition key creation and revocation<br />
::*Multiple passphrases or keyfiles for a particular partition<br />
<br />
=== Caveats ===<br />
<br />
For any type of encryption the security of your privacy is dependent on two things:<br />
<br />
::*The complexity/availability of your key (see [[Wikipedia:Kerckhoffs's principle]])<br />
::*The usage of a proven encryption algorithm<br />
<br />
====Key Complexity and Availability====<br />
<br />
The user-provided key used for encryption, whether a passphrase or a keyfile, must be complex enough that is it not easy to guess. Having a strong encryption algorithm does nothing to provide privacy if the key used for encryption is too simple. The tenets of strong keys are based on length and randomness. There are many sources available with instructions on how to create strong encryption keys. <br />
<br />
Part of key complexity is key availability. For example a complex key written on a sticky note pasted to the computer's keyboard would not provide much in the way privacy. Therefore in addition to creating a strong key, maintaining it in a secure location is necessary as well.<br />
<br />
====Encryption Algorithm====<br />
<br />
There are many peer-reviewed encryption algorithms in existence. The encryption algorithms and block ciphers used in any of the mentioned methods for applying encryption in this wiki page are considered strong algorithms that have been subjected to cryptographic review by the cryptography community.<br />
<br />
====discard/TRIM support for solid state disks====<br />
<br />
Solid state disk users should be aware that by default, Linux's full-disk encryption mechanisms will ''not'' forward TRIM commands from the filesystem to the underlying disk. The device-mapper maintainers have made it clear that TRIM support will never be enabled by default on dm-crypt devices because of the potential security implications; if TRIM support were enabled, an attacker may be able to tell which blocks have been used, how many blocks have been used, and other information that is exposed directly to the device when a TRIM is issued.<br />
<br />
It may be possible to determine the filesystem utilized by your encrypted device through the data that is leaked by TRIM. Furthermore, any information that may be derived by a profile of block usage may be exposed by enabling TRIM support on an encrypted device.<br />
<br />
As of {{Pkg|linux}} version 3.1, support for dm-crypt TRIM pass-through can be toggled upon device creation or mount with dmsetup. Support for this option also exists in {{Pkg|cryptsetup}} version 1.4.0 and up. To add support during boot, you will need to add "{{ic|:allow-discards}}" to the {{ic|cryptdevice}} option. The option should look like this:<br />
cryptdevice=/dev/mapper/root:root:allow-discards<br />
<br />
For more information, including specific commands and details on dm-crypt TRIM pass-through, see these mailing list threads:<br />
* http://article.gmane.org/gmane.linux.kernel.device-mapper.devel/14134<br />
* http://article.gmane.org/gmane.linux.kernel.device-mapper.dm-crypt/5166<br />
<br />
==== System Encryption ====<br />
<br />
System encryption provides security against unauthorized physical access to a machine that is powered off. It does not effect any security advantages for a system that is powered on with its partitions mounted in an unencrypted state. For a powered on user-accessible system the normal precautions to prevent viruses, trojans, worms, or other attempts to access private data should be exercised. Furthermore, system encryption has been shown to be penetrable in cases where a system has been recently shut down. This is due to the fact that cessation of power does not immediately degrade data that was stored in RAM prior to shutdown. Therefore someone with physical access to your computer within a few moments of shutdown could cool the RAM modules and use them extract your encryption key - thus obtaining access to your data.<br />
<br />
{{Note|System Encryption assumes encryption of all mounted partitions: this includes all partitions except for {{ic|/boot}} - meaning that the root file system, swap partition, and all other partitions must be encrypted. If the swap, {{ic|/tmp}}, or root filesystems are unencrypted, only Data Encryption level of security has been accomplished.}}<br />
<br />
==== Data Encryption ====<br />
<br />
There are two common forms of data encryption:<br />
<br />
::*Encryption of data partitions on the same physical disk as the system.<br />
::*Encryption of data partitions on separate physical disks from the system.<br />
<br />
=====Encryption of data partitions on the same physical disk as the system=====<br />
<br />
The most common form of data encryption is encrypting the {{ic|/home}} partition.<br />
<br />
In cases where the encrypted data are located on the same physical disk as the system accessing the drive the privacy of data has already been decreased by orders of magnitude when compared to system encryption. The reason for this is that the host operating systems employ background methods to assist the user in the access and management of their data. The problem lies in where these processes store this data which is most commonly in the unencrypted system partition. <br />
<br />
For example, {{Pkg|mlocate}} will scan all currently mounted file systems regularly and write the list of filenames to {{ic|/var/lib/mlocate/mlocate.db}}, which is located in the non-encrypted root or {{ic|/var}} partition. Thus an attacker will have a list of all filenames for that computer, even the ones on the encrypted {{ic|/home}} partition, readily available to assist them in accessing the encrypted data present on the disk.<br />
<br />
Some have compared this to reducing the level of security from partition-based encryption to filesystem level encryption like [[System_Encryption_with_eCryptfs|System Encryption with eCryptfs]].<br />
<br />
=====Encryption of data partitions on separate physical disks from the system=====<br />
<br />
Popular forms of data encryption on physically separate partitions include the encryption of removable media such as:<br />
<br />
::*USB Flash Drives<br />
::*External Hard Disk Drives or Separate Internal Hard Disk Drives<br />
::*CD/DVD/Blu-Ray Optical Media<br />
::*Magnetic Storage Media<br />
<br />
The most important part of this form of data encryption is to remember that the encryption protects the privacy of the data that is located within the encrypted media only when it is not mounted. Data encryption does not protect the privacy of data once it is made accessible to a system. For example, attaching an encrypted USB flash drive, and subsequently decrypting a file for use temporarily on a non-secured system could result in remnants of that file existing on the host system in an unencrypted form.<br />
<br />
== Initial Setup ==<br />
=== Overview and Preparation ===<br />
<br />
The Arch installer comes with all the tools required for system encryption. Setup of encrypted partitions can be accomplished either manually prior to executing the arch installer or using the menu interface from the arch installer itself. The installation of an encrypted system is largely the same as installing an unencrypted system, so you can follow the [[Official Arch Linux Install Guide]] or the [[Beginners' Guide]] after the encrypted partitions are set up.<br />
<br />
Routine creation of an encrypted system follows these general steps:<br />
<br />
::* Secure erasure of the hard disk drive(s)<br />
::* Partitioning and setup of encryption ([[LVM]] optional)<br />
::* Routine package selection and installation<br />
::* System Configuration<br />
<br />
{{Warning | Encrypting a partition will erase everything currently on that partition. Please make appropriate data backups prior to starting.}}<br />
<br />
=== Secure Erasure of the Hard Disk Drive ===<br />
<br />
Secure erasure of the hard disk drive involves overwriting the entire drive with random data.<br />
<br />
{{Note|Overwriting a hard disk drive ''multiple'' times with random data serves no purpose. Data existing prior to overwriting cannot be recovered after it has been overwritten. [http://www.springerlink.com/content/408263ql11460147/ Overwriting Hard Drive Data: The Great Wiping Controversy]}}<br />
<br />
====Why perform secure of erasure of a drive?====<br />
<br />
There are two types of hard disk drives, new and used, both kinds should be securely overwritten. The reasoning is slightly different for each but the goal is to help ensure the privacy of data located within the encrypted partitions.<br />
<br />
::'''New Hard Disk Drives'''<br />
<br />
::In hard drives that have been directly purchased from a manufacturer there is no preexisting private data to protect. The problem is that there is no consistency in what is presently on the drive. Ideally the drive should be completely filled with random bits. However some drives have been overwritten completely with zeros. Therefore once the drive is used to write encrypted data, it is relatively simple to identify where the encrypted data ends and the zeroed data begins compared to a drive that was written with random data before usage as an encrypted drive. Since an encrypted partition is supposed to be indistinguishable from random data, the lack of random data on a zeroed drive makes an encrypted drive an easier target for cryptanalysis.<br />
<br />
::'''Used Hard Disk Drives'''<br />
<br />
::Repartitioning or reformatting a used hard drive removes the file system structure for identifying where the original data was located while leaving the actual data intact on the drive itself. It is relatively straightforward using data tools like [http://foremost.sourceforge.net/ Foremost] to access the remnant data. Therefore hard drives should be securely overwritten with random data prior to encryption to prevent unintentional data recovery.<br />
<br />
====Overwriting a hard disk drive with random data====<br />
<br />
There are two sources of random data commonly used for securely overwriting hard disk partitions.<br />
<br />
::*{{ic|/dev/urandom}}<br />
::*badblocks<br />
<br />
=====Using urandom=====<br />
<br />
#dd if=/dev/urandom of=/dev/<drive> bs=1M<br />
<br />
Where {{ic|/dev/<drive>}} is the drive to be encrypted.<br />
<br />
{{Note| Using {{ic|/dev/urandom}} will take a long time to completely overwrite a drive with "random" data. In the strictest sense, {{ic|/dev/urandom}} is less random than {{ic|/dev/random}}; however, {{ic|/dev/random}} uses the kernel entropy pool and will halt overwriting until more input entropy once this pool has been exhausted. This makes the use of {{ic|/dev/random}} for overwriting hard disks impractical.}}<br />
<br />
{{Note| Users may also find that {{ic|/dev/urandom}} takes an excessively long time on large drives of several hundred gigabytes or more (more than twenty-four hours). [[Frandom]] offers a faster alternative.}}<br />
<br />
{{Note|You can retrieve progress of the dd command with this command: {{ic|kill -USR1 $(pidof dd)}}}}<br />
<br />
=====Using badblocks=====<br />
<br />
#badblocks -c 10240 -wsvt random /dev/<drive><br />
<br />
Where {{ic|/dev/<drive>}} is the drive to be encrypted.<br />
<br />
{{Note|The {{ic|badblocks}} command overwrites the drive at a much faster rate by generating data that is not truly random.}}<br />
<br />
See also [[badblocks]].<br />
<br />
{{Tip|In deciding which method to use for secure erasure of a hard disk drive, remember that this will not need to be performed more than once for as long as the drive is used as an encrypted drive.}}<br />
<br />
=== Partitioning ===<br />
<br />
After the drive has been securely overwritten, it is time to create partitions and begin setting up an encrypted system.<br />
<br />
There are multiple ways to create disk partitions:<br />
<br />
::*Standard partitions<br />
::*[[LVM]]<br />
::*[[RAID]]<br />
<br />
LUKS is compatible with systems that require LVM and/or RAID as well as with with standard primary, extended, and logical partitions.<br />
<br />
====Standard Partitions====<br />
<br />
These are the partitions that most people are familiar with. They come in three flavors: primary partitions, extended partitions, and logical partitions.<br />
<br />
;Primary Partitions: These are the normal partitions recognized by the system BIOS. There can be up to four of these stored in the MBR.<br />
<br />
;Extended Partitions: These are primary partitions that also define another partition within themselves. Extended partitions were created to work around the original limit of four primary partitions.<br />
<br />
;Logical Partitions: These are the partitions that are defined within extended partitions.<br />
<br />
====LVM: Logical Volume Manager====<br />
<br />
The LVM allows for creation of volume groups for systems that require complex combinations of multiple hard disk drives and partitions that are not possible with standard partitions. LVM is covered in detail in the [[LVM|Arch Linux LVM Wiki Article]] which is recommended reading prior to continuing with the instructions on setting up LUKS with LVM located below.<br />
<br />
====How does LVM fit into the overall system?====<br />
<br />
There is a growing preference towards logical volume management of LUKS encrypted physical media (LVM on LUKS). It is possible there may exist usage scenarios where encrypting logical volumes rather than physical disks is required (LUKS on LVM). However, the deployment of LVM on LUKS is considered much more generalizable. One reason for this is that using LUKS as the lowest level of infrastructure most closely approximates the deployment of physical disks with built-in hardware encryption. In this case, logical volume management would be layered on top of the hardware encryption &ndash; usage of LUKS would be superfluous.<br />
<br />
==== Creating Disk Partitions ====<br />
<br />
Disk partitions are created using:<br />
<br />
# cfdisk<br />
<br />
This will display a graphical interface for creating disk partitions.<br />
<br />
There are two required partitions for any encrypted system:<br />
<br />
::A root file system<br />
<br />
:::*{{ic|'''/'''}}<br />
:::*Will be encrypted and store all system and user files ({{ic|/usr}}, {{ic|/bin}}, {{ic|/var}}, {{ic|/home}}, etc.)<br />
<br />
::An initial boot partition<br />
<br />
:::*{{ic|'''/boot'''}}<br />
:::*Will ''not'' be encrypted; the bootloader needs to access the {{ic|/boot}} directory where it will load the initramfs/encryption modules needed to load the rest of the system which ''is'' encrypted (see [[Mkinitcpio]] for details). For this reason, {{ic|/boot}} needs to reside on its own, unencrypted partition.<br />
<br />
{{Note| A swap partition is optional; it can be encrypted with dm-crypt/LUKS. See [[#Encrypting_the_Swap_partition|Encrypting the Swap Partition]] for details.}}<br />
<br />
=====Single Disk Systems=====<br />
<br />
Depending on the system demands, there may be additional partitions desired. These partitions can be individually created at this level by defining separate primary or extended/logical partitions. However, if LVM is to be used, the space unoccupied by {{ic|/boot}} and swap should be defined as single large partition which will be divided up later at the LVM level.<br />
<br />
=====Multiple Disk Systems=====<br />
<br />
In systems that will have multiple hard disk drives, the same options exist as a single disk system. After the creation of the {{ic|/boot}} and swap partitions, the remaining free space on physical disks can divided up into their respective partitions at this level, or large partitions can define all free space per physical disk with intent to partition them within the LVM.<br />
<br />
== Configuring LUKS ==<br />
<br />
Creating LUKS partitions with a passphrase is supported by the {{ic|/arch/setup}} program. <br />
<br />
This section of the Wiki will cover how to manually utilize LUKS from the command line to encrypt a system. <br />
<br />
The steps for accomplishing this through the graphical installer are very similar and can be located in the dialogue for manual configuration of the hard drive.<br />
<br />
=== Mapping Physical Partitions to LUKS ===<br />
<br />
Once the desired partitions are created it is time to format them as LUKS partitions and then mount them through the device mapper.<br />
<br />
When creating LUKS partitions they must be associated with a key. <br />
<br />
A key is either a: <br />
<br />
::*Passphrase<br />
::*Keyfile <br />
<br />
It is possible to define up to 8 different keys per LUKS partition.<br />
<br />
==== Using LUKS to Format Partitions with a Passphrase ====<br />
<br />
Cryptsetup is used to interface with LUKS for formatting, mounting and unmounting encrypted partitions.<br />
<br />
A full list of options {{ic|cryptsetup}} accepts can be found in the [[http://www.linuxcommand.org/man_pages/cryptsetup8.html Cryptsetup Manpage]]<br />
<br />
The options used here are:<br />
<br />
::*{{ic|-c}} defines the cipher type<br />
::*{{ic|-y}} prompts for password confirmation on password creation<br />
::*{{ic|-s}} defines the key size<br />
<br />
::luksFormat addresses the LUKS extensions built into cryptsetup.<br />
<br />
In the following examples for creating LUKS partitions, we will use the AES cipher in XTS mode; at present this is most generally used preferred cipher.<br />
Other ciphers can be used with cryptsetup, and details about them can be found here: [[Wikipedia:Block_cipher]]<br />
<br />
'''Formatting LUKS Partitions'''<br />
<br />
First of all make sure the device mapper kernel module is loaded by executing the following: {{ic|# modprobe dm_mod}}<br />
<br />
In order to format a desired partition as an encrypted LUKS partition execute:<br />
{{hc|# cryptsetup -c <cipher> -y -s <key size> luksFormat /dev/<partition name>|<br />
Enter passphrase: <password><br />
Verify passphrase: <password>}}<br />
<br />
This should be repeated for all partitions except for {{ic|/boot}} and possibly swap.<br />
<br />
The example below will create an encrypted root partition using the AES cipher in XTS mode (generally referred to as ''XTS-AES'').<br />
{{bc|cryptsetup -c aes-xts-plain -y -s 512 luksFormat /dev/sda2}}<br />
<br />
{{Note|If hibernation usage is planned, swap must be encrypted in this fashion; otherwise, if hibernation is not a planned feature for the system, encrypting the swap file will be performed in a alternative manner.}}<br />
<br />
{{Warning|Irrespective of the chosen partitioning method, the {{ic|/boot}} partition must remain separate and unencrypted in order to load the kernel and boot the system.}}<br />
<br />
'''Unlocking/Mapping LUKS Partitions with the Device Mapper'''<br />
<br />
Once the LUKS partitions have been created it is time to unlock them.<br />
<br />
The unlocking process will map the partitions to a new device name using the device mapper. This alerts the kernel that {{ic|/dev/<partition name>}} is actually an encrypted device and should be addressed through LUKS using the {{ic|/dev/mapper/<name>}} so as not to overwrite the encrypted data. <br />
<br />
In order to open an encrypted LUKS partition execute:<br />
{{hc|# cryptsetup luksOpen /dev/<partition name> <device-mapper name>|<br />
Enter any LUKS passphrase: <password><br />
key slot 0 unlocked.<br />
Command successful.}}<br />
<br />
Usually the device mapped name is descriptive of the function of the partition that is mapped, example:<br />
<br />
::*cryptsetup luksOpen /dev/sda2 '''swap'''<br />
::::Once opened, the swap partition device address would be '''{{ic|/dev/mapper/swap}}''' instead of {{ic|/dev/sda2}}.<br />
<br />
::*cryptsetup luksOpen /dev/sda3 '''root'''<br />
::::Once opened, the root partition device address would be '''{{ic|/dev/mapper/root}}''' instead of {{ic|/dev/sda3}}.<br />
<br />
{{Note|Since {{ic|/boot}} is not encrypted, it does not need a device mapped name and will be addressed as {{ic|/dev/sda1}}.}}<br />
<br />
{{Warning|In order to write encrypted data into the partition it must be accessed through the device mapped name.}}<br />
<br />
==== Using LUKS to Format Partitions with a Keyfile ====<br />
<br />
'''What is a Keyfile?'''<br />
<br />
A keyfile is any file in which the data contained within it is used as the passphrase to unlock an encrypted volume.<br />
Therefore if these files are lost or changed, decrypting the volume will no longer be possible.<br />
<br />
{{Tip|Define a passphrase in addition to the keyfile for backup access to encrypted volumes in the event the defined keyfile is lost or changed.}}<br />
<br />
'''Why use a Keyfile?'''<br />
<br />
There are many kinds of keyfile. Each type of keyfile used has benefits and disadvantages summarized below:<br />
<br />
:'''keyfile.passphrase:'''<br />
::this is my passphrase I would have typed during boot but I have placed it in a file instead<br />
<br />
This is a keyfile containing a simple passphrase. The benefit of this type of keyfile is that if the file is lost the data it contained is known and hopefully easily remembered by the owner of the encrypted volume. However the disadvantage is that this does not add any security over entering a passphrase during the initial system start.<br />
<br />
:'''keyfile.randomtext:'''<br />
::fjqweifj830149-57 819y4my1- 38t1934yt8-91m 34co3;t8y;9p3y-<br />
<br />
This is a keyfile containing a block of random characters. The benefit of this type of keyfile is that it is much more resistant to dictionary attacks than a simple passphrase. An additional strength of keyfiles can be utilized in this situation which is the length of data used. Since this is not a string meant to be memorized by a person for entry, it is trivial to create files containing thousands of random characters as the key. The disadvantage is that if this file is lost or changed, it will most likely not be possible to access the encrypted volume without a backup passphrase.<br />
<br />
:'''keyfile.binary:'''<br />
::where any binary file, images, text, video could be chosen as the keyfile<br />
<br />
This is a binary file that has been defined as a keyfile. When identifying files as candidates for a keyfile, it is recommended to choose files that are relatively static such as photos, music, video clips. The benefit of these files is that they serve a dual function which can make them harder to identify as keyfiles. Instead of having a text file with a large amount of random text, the keyfile would look like a regular image file or music clip to the casual observer. The disadvantage is that if this file is lost or changed, it will most likely not be possible to access the encrypted volume without a backup passphrase. Additionally, there is a theoretical loss of randomness when compared to a randomly generated text file. This is due to the fact that images, videos and music have some intrinsic relationship between neighboring bits of data that does not exist for a text file. However this is controversial and has never been exploited publicly.<br />
<br />
'''Creating a Keyfile with Random Characters'''<br />
<br />
Here {{ic|dd}} is used to generate a keyfile of 2048 bits of random characters.<br />
<br />
# dd if=/dev/urandom of=mykeyfile bs=512 count=4<br />
<br />
The usage of {{ic|dd}} is similar to initially wiping the volume with random data prior to encryption. While [[badblocks]] may also be used, most key files are on the order of a few kilobytes and there is no noticeable speed difference between dd or badblocks.<br />
<br />
'''Creating a new LUKS encrypted partition with a Keyfile'''<br />
<br />
When creating a new LUKS encrypted partition, a keyfile may be associated with the partition on its creation using:<br />
<br />
# cryptsetup -c <desired cipher> -s <key size> luksFormat /dev/<volume to encrypt> '''/path/to/mykeyfile'''<br />
<br />
This is accomplished by appending the bold area to the standard cryptsetup command which defines where the keyfile is located.<br />
<br />
==== Adding Additional Passphrases or Keyfiles to a LUKS Encrypted Partition ====<br />
<br />
LUKS supports the association of up to 8 keys with any single encrypted volume.<br />
Keys can be either keyfiles or passphrases.<br />
<br />
Once an encrytped partition has been created, the initial key is associated at slot 0.<br />
Additional keys will occupy slots 1&ndash;7.<br />
<br />
The addition of new keys to an encrypted partition is accomplished using cryptsetup with the {{ic|luksAddKey}} extension.<br />
<br />
# cryptsetup luksAddKey /dev/<encrypted volume> '''/path/to/mykeyfile'''<br />
<br />
Where {{ic|/dev/<encrypted volume>}} is the volume that is to have the new key associated with it.<br />
<br />
If the bolded area is present, cryptsetup will look for the keyfile defined at that location to associate with the encrypted volume specified.<br />
<br />
=== Storing the Key File ===<br />
<br />
==== External Storage on a USB Drive ====<br />
<br />
===== Preparation for permanent device names =====<br />
For reading the file from an USB stick it is important to access it through a permanent device name.<br />
The numbering of the normal device names e.g. {{ic|/dev/sdb1}} is somewhat arbitrary and depends on how many storage devices are attached and in what order, etc.<br />
So in order to assure that the {{ic|encrypt}} HOOK in the initcpio finds your keyfile, you must use a permanent device name. <br />
<br />
===== Quick method =====<br />
A quick method (as opposed to setting up a [[udev]] rule) for doing so involves referencing your removable device by its label (or UUID). To find your label or UUID, plug in your USB drive and run the following:<br />
<br />
{{hc|# ls -l /dev/disk/by-label/|<br />
lrwxrwxrwx 1 root root 10 12. Feb 10:11 Keys -> ../../sdb1}}<br />
<br />
or<br />
<br />
{{hc|# ls -l /dev/disk/by-uuid/|<br />
lrwxrwxrwx 1 root root 10 12. Feb 10:11 4803-8A7B -> ../../sdb1}}<br />
<br />
In this case, I labeled the vfat partition on my USB drive as "Keys" so my device is always symlinked in {{ic|/dev/disk/by-label/Keys}}, or if I had wanted to use the UUID I would find {{ic|/dev/disk/by-uuid/4803-8A7B}}. This allows me to have a consistent naming of my USB devices regardless of the order they are plugged into the system. These device names can be used in the "cryptkey" kernel option or any where else. Filesystem UUIDs are stored in the filesystem itself, meaning that the UUID will be the same if you plug it into any other computer, and that a dd backup of it will always have the same UUID since dd does a bitwise copy.<br />
<br />
{{Note|If you plan to store the keyfile between [[#Storing_the_key_between_MBR_and_1st_partition|MBR and the 1st partition]] you '''cannot use this method''', since it only allows access to the partitions ({{ic|sdb1}}, {{ic|sdb2}}, ...) but not to the USB device ({{ic|sdb}}) itself.<br />
Create a udev rule instead as described in the following section.}}<br />
<br />
==== Using udev ====<br />
Optionally you may choose to set up your flash drive with a [[udev]] rule. There is some documentation in the Arch wiki about that already; if you want more in-depth, structural info, read [http://reactivated.net/writing_udev_rules.html this guide]. Here is quickly how it goes.<br />
<br />
Get the serial number from your USB flash drive:<br />
lsusb -v | grep -A 5 Vendor<br />
<br />
Create a udev rule for it by adding the following to a file in {{ic|/etc/udev/rules.d/}}, such as {{ic|8-usbstick.rules}}:<br />
KERNEL=="sd*", ATTRS{serial}=="$SERIAL", SYMLINK+="$SYMLINK%n"<br />
<br />
Replace {{ic|$SYMLINK}} and {{ic|$SERIAL}} with their respective values. {{ic|%n}} will expand to the partition (just like sda is subdivided into sda1, sda2, ...). You do not need to go with the 'serial' attribute. If you have a custom rule of your own, you can put it in as well (e.g. using the vendor name).<br />
<br />
Rescan your sysfs:<br />
udevadm trigger<br />
Now check the contents of {{ic|/dev}}:<br />
ls /dev<br />
It should show your device with your desired name.<br />
<br />
==== Generating the keyfile ====<br />
Optionally you can mount a tmpfs for storing the temporary keyfile.<br />
# mkdir ./mytmpfs<br />
# mount tmpfs ./mytmpfs -t tmpfs -o size=32m<br />
# cd ./mytmpfs<br />
The advantage is that it resides in RAM and not on a physical disk, so after unmounting your keyfile is securly gone.<br />
So copy your keyfile to some place you consider as secure before unmounting.<br />
If you are planning to store the keyfile as a plain file on your USB device, you can also simply execute the following command in the corresponding directory, e.g. {{ic|/media/sdb1}}<br />
<br />
The keyfile can be of arbitrary content and size. We will generate a random temporary keyfile of 2048 bytes:<br />
# dd if=/dev/urandom of=secretkey bs=512 count=4<br />
<br />
If you stored your temporary keyfile on a physical storage device, remember to not just (re)move the keyfile later on, but use something like<br />
cp secretkey /destination/path<br />
shred --remove --zero secretkey<br />
to securely overwrite it. (However due to journaling filesystems this is also not 100% secure.)<br />
<br />
Add the temporary keyfile with cryptsetup:<br />
# cryptsetup luksAddKey /dev/sda2 secretkey<br />
Enter any LUKS passphrase:<br />
key slot 0 unlocked.<br />
Command successful.<br />
<br />
==== Storing the keyfile ====<br />
To store the key file, you have two options. The first is less risky than the other, but perhaps a bit more secure (if you consider security by obscurity as more secure).<br />
In any case you have to do some further configuration, if not already done above.<br />
<br />
==== Configuration of initcpio ====<br />
You have to add two extra modules in your {{ic|/etc/mkinitcpio.conf}}, one for the drive's file system and one for the codepage. Further if you created a udev rule, you should tell {{ic|mkinitcpio}} about it:<br />
MODULES="ata_generic ata_piix nls_cp437 vfat"<br />
FILES="/etc/udev/rules.d/8-usbstick.rules"<br />
In this example it is assumed that you use a FAT formatted USB drive. Replace those module names if you use another file system on your USB stick (e.g. ext2) or another codepage. Users running the stock Arch kernel should stick to the codepage mentioned here.<br />
<br />
Additionally, insert the {{ic|usb}} hook somewhere before the {{ic|encrypt}} hook.<br />
HOOKS="... '''usb''' encrypt ... filesystems ..."<br />
<br />
If you have a non-US keyboard, it might prove useful to load your keyboard layout before you are prompted to enter the password to unlock the root partition at boot. For this, you will need the {{ic|keymap}} hook before {{ic|encrypt}}.<br />
<br />
Generate a new image (maybe you should backup a copy of your old kernel26.img first):<br />
mkinitcpio -g /boot/kernel26.img<br />
<br />
==== Storing the key as a plain (visible) file ====<br />
Be sure to choose a plain name for your key &ndash; a bit of 'security through obscurity' is always nice ;-). Avoid using dotfiles (hidden files) &ndash; the {{ic|encrypt}} hook will fail to find the keyfile during the boot process.<br />
<br />
You have to add a kernel parameter in your {{ic|/boot/grub/menu.lst}} ([[GRUB]]). It should look something like this:<br />
kernel /vmlinuz26 root=/dev/hda3 ro vga=791 cryptkey=/dev/usbstick:vfat:/secretkey<br />
This assumes {{ic|/dev/usbstick}} is the FAT partition of your choice. Replace it with {{ic|/dev/disk/by-...}} or whatever your device is.<br />
<br />
That is all, reboot and have fun!<br />
<br />
==== Storing the key between MBR and 1st partition ====<br />
We will write the key directly between the Master Boot Record (MBR) and the first partition.<br />
<br />
{{Warning|You should only follow this step if you know what you are doing -- '''it can cause data loss and damage your partitions or MBR on the stick!'''}}<br />
<br />
If you have a bootloader installed on your drive you have to adjust the values. E.g. [[GRUB]] needs the first 16 sectors (actually, it depends on the type of the file system, so do not rely on this too much), so you would have to replace {{ic|seek<nowiki>=</nowiki>4}} with {{ic|seek<nowiki>=</nowiki>16}}; otherwise you would overwrite parts of your GRUB installation. When in doubt, take a look at the first 64 sectors of your drive and decide on your own where to place your key. <br />
<br />
''Optional''<br />
If you do not know if you have enough free space before the first partition, you can do<br />
dd if=/dev/usbstick of=64sectors bs=512 count=64 # gives you copy of your first 64 sectors<br />
hexcurse 64sectors # determine free space<br />
xxd 64sectors | less # alternative hex viewer<br />
<br />
Write your key to the disk:<br />
dd if=secretkey of=/dev/usbstick bs=512 seek=4<br />
<br />
If everything went fine you can now overwrite and delete your temporary secretkey as noted above.<br />
You should not simply use {{ic|rm}} as the keyfile would only be unlinked from your filesystem and be left physically intact.<br />
<br />
Now you have to add a kernel parameter in your {{ic|/boot/grub/menu.lst}} file (GRUB); it should look something like this:<br />
kernel /vmlinuz26 root=/dev/hda3 ro vga=791 cryptkey=/dev/usbstick:2048:2048<br />
Format for the {{ic|cryptkey}} option:<br />
cryptkey=BLOCKDEVICE:OFFSET:SIZE<br />
{{ic|OFFSET}} and {{ic|SIZE}} match in this example, but this is just coincidence - they can differ (and often will). An other possible example could be<br />
kernel /vmlinuz26 root=/dev/hda3 ro vga=791 cryptkey=/dev/usbstick:8192:2048<br />
That is all, reboot and have fun! And look if your partitions still work after that ;-).<br />
<br />
=== Encrypting the Swap partition ===<br />
<br />
==== Without suspend-to-disk support ====<br />
<br />
In systems where suspend to disk is not a desired feature, it is possible to create a swap file that will have a random passphrase with each boot.<br />
<br />
This is accomplished by using dm-crypt directly without LUKS extensions.<br />
<br />
Append a similar line to /etc/crypttab to set up a randomly encrypted swap partition:<br />
<br />
<device-mapper name> <swap physical partition> SWAP "-c aes-xts-plain -h whirlpool -s 512"<br />
<br />
Where:<br />
<br />
:*{{ic|<device-mapper name>}} represents the name you want to use as label in /etc/fstab<br />
:*{{ic|<swap physical partition>}} should be the ID of the actual partition. <br> {{Warning|You should use IDs here because if there are multiple hard drives installed in the system, their naming order (sda, sdb,...) can occasionally be scrambled upon boot and thus the swap would be created over a valuable file system, destroying its content. {{ic|<nowiki>ls -l /dev/disk/*/* | grep sdl7</nowiki>}} should help you to find the desired partition.}}<br />
:*{{ic|SWAP}} identifies the partition as a swap partition<br />
:*{{ic|-c}} defines a cipher<br />
:*{{ic|-h}} defines a hash algorithm<br />
:*{{ic|-s}} defines the key size<br />
<br />
Example line (where {{ic|/dev/sdl7}} is the physical partition and {{ic|<nowiki>LABEL=swap</nowiki>}} the desired label):<br />
<br />
swap /dev/disk/by-id/scsi-SATA_Hitachi_HDS7220_JK1130YAGX0R1T-part7 SWAP "-c aes-xts-plain -h whirlpool -s 512"<br />
<br />
:Maps {{ic|/dev/sdl7}} to {{ic|/dev/mapper/swap}} as a swap partition which we can now add in /etc/fstab like a normal swap.<br />
<br />
If the partition chosen for swap was previously a LUKS partition, crypttab will not overwrite the partition to create a swap partition. This is a safety measure to prevent data loss from accidental mis-identification of the swap partition in crypttab. In order to use such a partition the LUKS header must be removed. This can be accomplished with:<br />
<br />
# dd if=/dev/zero of=/dev/sdl7 bs=1M<br />
<br />
==== With suspend-to-disk support ====<br />
{{Warning|Do not use this setup with a key file. Please read about the issue reported [[Talk:System_Encryption_with_LUKS_for_dm-crypt#Suspend_to_disk_instructions_are_insecure|here]]}}<br />
<br />
To be able to resume after suspending the computer to disk (hibernate), it is required to keep the swap filesystem intact. Therefore, it is required to have a pre-existent LUKS swap partition, which can be stored on the disk or input manually at startup. Because the resume takes place before {{ic|/etc/crypttab}} can be used, it is required to create a hook in {{ic|/etc/mkinitcpio.conf}} to open the swap LUKS device before resuming. The following setup has the disadvantage of having to insert a key manually for the swap partition.<br />
<br />
If you want to use a partition which is currently used by the system, you have to disable it first:<br />
# swapoff /dev/<device><br />
To create the swap partition, follow steps similar to those described in [[#Mapping_partitions | mapping partitions]] above.<br><br />
* Format the partition you want to use as swap with the {{ic|cryptsetup}} command. For performance reasons, you might want to use different ciphers with different key sizes.<br />
<br />
# cryptsetup -c aes-xts-plain -s 512 -h sha512 -v luksFormat /dev/<device><br />
<br />
Check the result with:<br />
<br />
# cryptsetup luksDump /dev/<device><br />
<br />
* Open the partition in {{ic|/dev/mapper}}:<br />
<br />
# cryptsetup luksOpen /dev/<device> swapDevice<br />
<br />
* Create a swap filesystem inside the mapped partition:<br />
<br />
# mkswap /dev/mapper/swapDevice<br />
<br />
Now you should have a LUKS swap partition which asks for the passphrase before mounting. Make sure you remove any line in {{ic|/etc/crypttab}} which uses this device. Now you have to create a hook to open the swap at boot time.<br />
<br />
* Create a hook file containing the open command:<br />
<br />
{{hc|/lib/initcpio/hooks/openswap|<nowiki><br />
# vim: set ft=sh:<br />
run_hook ()<br />
{<br />
cryptsetup luksOpen /dev/<device> swapDevice<br />
}<br />
</nowiki>}}<br />
<br />
* Then create and edit the hook setup file:<br />
{{hc|/lib/initcpio/install/openswap|<nowiki><br />
# vim: set ft=sh:<br />
build ()<br />
{<br />
MODULES=""<br />
BINARIES=""<br />
FILES=""<br />
SCRIPT="openswap"<br />
}<br />
help ()<br />
{<br />
cat<<HELPEOF<br />
This opens the swap encrypted partition /dev/<device> in /dev/mapper/swapDevice<br />
HELPEOF<br />
}<br />
</nowiki>}}<br />
<br />
* Add the hook {{ic|openswap}} in the {{ic|HOOKS}} array in {{ic|/etc/mkinitcpio.conf}}, before {{ic|filesystem}}, but '''after''' {{ic|encrypt}} which is mandatory as well. Do not forget to add the {{ic|resume}} hook between {{ic|openswap}} and {{ic|filesystem}} as well.<br />
<br />
* Regenerate the boot image:<br />
<br />
# mkinitcpio -p linux<br />
<br />
* Add the mapped partition to {{ic|/etc/fstab}} by adding the following line:<br />
/dev/mapper/swapDevice swap swap defaults 0 0<br />
<br />
* Set up your system to resume from {{ic|/dev/mapper/swapDevice}}. For example, if you use [[GRUB]] with kernel hibernation support, add {{ic|resume<nowiki>=</nowiki>/dev/mapper/swapDevice}} to the kernel line in {{ic|/boot/grub/menu.lst}}. A line with encrypted root and swap partitions can look like this:<br />
<br />
kernel /vmlinuz26 cryptdevice=/dev/sda2:rootDevice root=/dev/mapper/rootDevice resume=/dev/mapper/swapDevice ro<br />
<br />
At boot time, the {{ic|openswap}} hook will open the swap partition so the kernel resume may use it. If you use special hooks for resuming from hibernation, make sure they are placed '''after''' {{ic|openswap}} in the {{ic|HOOKS}} array. Please note that because of initrd opening swap, there is no entry for swapDevice in {{ic|/etc/crypttab}} needed in this case.<br />
<br />
=== Using a swap file for suspend-to-disk support ===<br />
* Choose a mapped partition (e.g. {{ic|/dev/mapper/rootDevice}}) whose mounted filesystem (e.g. {{ic|/}}) contains enough free space to hold the entire contents of your system's RAM. For example, if your system has 4 GiB RAM, then you need at least that much free space on the mounted filesystem of your chosen mapped partition for the swap file.<br />
<br />
* [[HOW_TO:_Create_swap_file#Swap_file_creation | Create the swap file]] (e.g. {{ic|/swapfile}}) inside the mounted filesystem of your chosen mapped partition. Be sure to activate it with {{ic|swapon}} and also add it to your {{ic|/etc/fstab}} file afterward.<br />
<br />
* Set up your system to resume from your chosen mapped partition. For example, if you use [[GRUB]] with kernel hibernation support, add {{ic|resume<nowiki>=</nowiki>}}''your chosen mapped partition'' and {{ic|resume_offset<nowiki>=</nowiki>}}''see calculation command below'' to the kernel line in {{ic|/boot/grub/menu.lst}}. A line with encrypted root partition can look like this:<br />
<br />
kernel /vmlinuz26 cryptdevice=/dev/sda2:rootDevice root=/dev/mapper/rootDevice resume=/dev/mapper/rootDevice resume_offset=123456789 ro<br />
<br />
You can calculate the {{ic|resume_offset}} of your swap file like this:<br />
<br />
# filefrag -v /swapfile | awk '{if($1==0){print $3}}'<br />
<br />
* Add the {{ic|resume}} hook to your {{ic|etc/mkinitcpio.conf}} file and [[Mkinitcpio#Image_creation_and_activation|rebuild the image]] afterward:<br />
<br />
HOOKS="... encrypt '''resume''' ... filesystems ..."<br />
<br />
== Installing the system ==<br />
Now that {{ic|/dev/mapper/root}} and {{ic|/dev/mapper/home}} are in place, we can enter the regular Arch setup script to install the system into the encrypted volumes.<br />
# /arch/setup<br />
{{Note | Most of the installation can be carried out normally. However, there are a few areas where it is important to make certain selections. These are marked below.}}<br />
<br />
=== Prepare hard drive ===<br />
Skip the Partitioning and Auto-Prepare steps and go straight to manual configuration.<br />
Instead of choosing the hardware devices ({{ic|/dev/sdaX}}) directly, you have to select the mapper devices created above.<br />
Choose {{ic|/dev/mapper/root}} for your root and {{ic|/dev/mapper/home}} as {{ic|/home}} partition respectively and format them with any filesystem you like.<br />
The same is valid for a swap partition which is set up like the {{ic|/home}} partition. Make sure you mount {{ic|/dev/sda1}} as the {{ic|/boot}} partition, or else the installer will not properly set up the bootloader.<br />
<br />
=== Select and Install packages ===<br />
Select and install the packages as usual: the base package contains all required programs.<br />
<br />
=== Configure System ===<br />
{{Note|The {{ic|encrypt}} hook is only needed if your root partition is a ''LUKS'' partition (or a LUKS partition that needs to be mounted ''before'' root). The {{ic|encrypt}} hook is not needed if any other partition (swap, for example) is encrypted. System initialization scripts ({{ic|/etc/rc.sysinit}} and {{ic|/etc/crypttab}} among others) take care of those.<br />
<br />
Afterwards you can check the files presented to you by the installer, the most important one being {{ic|/etc/mkinitcpio.conf}}. For detailed information about mkinitcpio and its configuration refer to [[Mkinitcpio]]. You have to make sure that your {{ic|HOOKS}} array in {{ic|/etc/mkinitcpio.conf}} looks something like this:<br />
HOOKS="... encrypt ... filesystems ..."<br />
It is important that the {{ic|encrypt}} hook comes ''before'' the {{ic|filesystems}} hook. If you store your key on an external USB device (e.g. a USB stick), you need to add the USB hook too:<br />
HOOKS="... usb encrypt ... filesystems ..."<br />
For safety, add {{ic|usb}} before {{ic|encrypt}} because the hooks are run in the order they appear.<br />
If you need support for foreign keymaps for your encryption password, you have to specify the hook {{ic|keymap}} as well. I suggest putting this in {{ic|/etc/mkinitcpio.conf}} immediately before {{ic|encrypt}}.<br />
<br />
If you have a USB keyboard, you will need the {{ic|usbinput}} hook in {{ic|/etc/mkinitcpio.conf}}. Without it, no USB keyboard will work in early userspace.<br />
<br />
If your root partition is a ''LUKS'' partition, add the used filesystem to the {{ic|MODULES}} section.<br />
MODULES="... ext3 ext4 xfs ..."<br />
<br />
=== Install Bootloader ===<br />
'''[[GRUB]]:''' You have to make some small changes to the entries generated by the installer by replacing {{ic|/dev/mapper/root}} with {{ic|/dev/sda3}}. The important point to remember here is to use the same {{ic|cryptdevice}} name you assigned when you initially unlocked your device. In this example, the device name is {{ic|cryptroot}}; customize yours accordingly:<br />
<br />
# (0) Arch Linux<br />
title Arch Linux<br />
root (hd0,0)<br />
kernel /vmlinuz-linux cryptdevice=/dev/sda3:cryptroot root=/dev/mapper/cryptroot ro<br />
initrd /initramfs-linux.img<br />
<br />
For kernels older than 2.6.37, the syntax is:<br />
# (0) Arch Linux<br />
title Arch Linux<br />
root (hd0,0)<br />
kernel /vmlinuz26 root=/dev/sda3 ro<br />
initrd /kernel26.img<br />
<br />
'''LILO:''' Edit the Arch Linux section in {{ic|/etc/lilo.conf}} and include a line for the {{ic|append}} option, over the initrd, with the {{ic|root<nowiki>=</nowiki>/dev/sda3}} parameter. The {{ic|append}} section makes the same kernel line as in GRUB. Also, you can omit the {{ic|root}} option above the {{ic|image}} option. The section looks like this:<br />
# Arch Linux lilo section<br />
image = /vmlinuz26<br />
# root = /dev/sda3<br />
label = Arch<br />
initrd = /kernel26.img<br />
append = "root=/dev/sda3"<br />
read-only<br />
<br />
{{Note|If you want to use a USB flash drive with a keyfile, you have to append the {{ic|cryptkey}} option. See the corresponding section below.}}<br />
<br />
=== Exit Install ===<br />
Now that the install is finished the only thing left to do is add entries to the {{ic|/etc/crypttab}} file so you do not have to enter the passphrase for all encrypted partitions. This works only for non-root partitions e.g. /home, swap, etc.<br />
# vi /mnt/etc/crypttab<br />
Add the following line for the {{ic|/home}} partition<br />
home /dev/sda5 "myotherpassword"<br />
<br />
You can also use a keyfile instead of a passphrase. If not already done, create a keyfile and add the key to the corresponding LUKS partition as described [[#Keyfile|above]].<br />
Then add the following information to the {{ic|/etc/crypttab}} file for automounting:<br />
home /dev/sda5 /path/of/your/keyfile<br />
<br />
After rebooting you should now be presented with the text<br />
A password is required to access the root filesystem:<br />
followed by a prompt for a LUKS password. Type it in and everything should boot.<br />
Once you've logged in, have a look at your mounted partitions by typing {{ic|mount}}. You should have {{ic|/dev/mapper/root}} mounted at {{ic|/}} and, if you set up a separate encrypted home partition, {{ic|/dev/mapper/home}} mounted at {{ic|/home}}. If you set up encrypted swap, {{ic|swapon -s}} should have {{ic|/dev/mapper/swap}} listed as your swap partition.<br />
<br />
{{Note|Eventually the text prompting for the password is mixed up with other boot messages. So the boot process may seem frozen at first glance, but it is not, simply enter your password and press return.}}<br />
<br />
== Remote unlocking of the root (or other) partition ==<br />
If you want to be able to reboot a fully LUKS-encrypted system remotely, or start it with a Wake-on-LAN service, you will need a way to enter a passphrase for the root partition/volume at startup. This can be achieved by running the {{ic|net}} hook along with an [[SSH]] server in initrd. Install the {{AUR|dropbear_initrd_encrypt}} package from the [[Arch User Repository|AUR]] and follow the post-installation instructions. Replace the {{ic|encrypt}} hook with {{ic|dropbear encryptssh}} in {{ic|/etc/mkinitcpio.conf}}. Put the {{ic|net}} hook early in the HOOKS array if your DHCP server takes a long time to lease IP addresses.<br />
<br />
If you would simply like a nice solution to mount other encrypted partitions (such as {{ic|/home}})remotely, you may want to look at [https://bbs.archlinux.org/viewtopic.php?pid=880484 this forum thread].<br />
<br />
{{Note|Acutally trim will not work with this script because it is not yet updated to the latest encrypt hook, so it is not able to parse {{ic|-–allow-discards}} from {{ic|/boot/grub/menu.lst}}. (Version: dropbear_initrd_encrypt 0.8-16). You won't notice any error when using online discard, but you see an error when you try to use {{ic|fstrim}}.For a temporary solution just add {{ic|-–allow-discards}} to every cryptsetup line of {{ic|/lib/initcpio/install/dropbear}}(1 line) and {{ic|/lib/initcpio/hooks/encryptssh}}(3 lines)}}<br />
<br />
== Backup the cryptheader ==<br />
If the header of your encrypted partition gets destroyed, you will not be able to decrypt your data. Therefore, having a backup of the headers and storing them on another disk might be a good idea.<br />
<br />
'''Attention:''' Many people recommend NOT backing up the cryptheader, but even so it's a single point of failure!<br />
In short, the problem is that LUKS is not aware of the duplicated cryptheader, which contains the master key which is used to encrypt all files on your partition. Of course this master key is encrypted with your passphrases or keyfiles.<br />
But if one of those gets compromised and you want to revoke it you have to do this on all copies of the cryptheader!<br />
I.e. if someone has got your cryptheader and one of your keys he can decrypt the master key and access all your data.<br />
Of course the same is true for all backups you create of your partions.<br />
So you decide if you are one of those paranoids brave enough to go without a backup for the sake of security or not.<br />
See also [http://www.saout.de/tikiwiki/tiki-slideshow.php?page=LUKSFaq&slide=1|LUKSFaq]{{Linkrot|2011|09|05}} for further details on this.<br />
<br />
{{Note|You can also back up the header into a tmpfs/ramfs and encrypt it with gpg or whatever before writing it to a physical disk. Of course you can wrap your encrypted backup into another encryption layer and so on until you feel safe enough :-)}}<br />
<br />
=== Backup ===<br />
==== Manually ====<br />
First you have to find out the payload offset of the crypted partition (replace sdaX with the corresponding partition)<br />
cryptsetup luksDump /dev/sdaX | grep "Payload offset"<br />
Payload offset: 4040<br />
Now that you know the value, you can backup the header with a simple dd command<br />
dd if=/dev/sdaX of=./backup.img bs=512 count=4040<br />
<br />
==== Using cryptsetup ====<br />
You can also use the luksHeaderBackup command instead:<br />
cryptsetup luksHeaderBackup /dev/sdaX --header-backup-file ./backup.img<br />
<br />
=== Restore ===<br />
Be careful before restore: make sure that you chose the right partition (again replace sdaX with the corresponding partition).<br />
Restoring the wrong header or restoring to an unencrypted partition will cause data loss.<br />
==== Manually ====<br />
Again, you will need to the same values as when backing up:<br />
dd if=./backup.img of=/dev/sdX bs=512 count=4040<br />
==== Using cryptsetup ====<br />
Or you can use the luksHeaderRestore command:<br />
cryptsetup luksHeaderRestore /dev/sdaX --header-backup-file ./backup.img<br />
<br />
'''Note:''' All the keyslot areas are overwritten; only active keyslots from the backup file are available after issuing this command.<br />
<br />
== Encrypting a loopback filesystem ==<br />
''[This paragraph has been merged from another page; its consistency with the other paragraphs should be improved]''<br />
<br />
=== Preparation and mapping ===<br />
First, start start by creating an encrypted container!<br />
<br />
dd if=/dev/urandom of=/bigsecret bs=1M count=10<br />
<br />
This will create the file {{ic|bigsecret}} with a size of 10 megabytes.<br />
<br />
losetup /dev/loop0 /bigsecret<br />
<br />
This will create the device node {{ic|/dev/loop0}}, so that we can mount/use our container.<br />
<br />
{{Note|If it gives you the error {{ic|/dev/loop0: No such file or directory}}, you need to first load the kernel module with {{ic|modprobe loop}}. These days (Kernel 3.2) loop devices are created on demand. Ask for a new loop device with {{ic|losetup -f}}.}}<br />
<br />
cryptsetup luksFormat /dev/loop0<br />
<br />
This will ask you for a password for your new container file.<br />
<br />
{{Note|If you get an error like {{ic|Command failed: Failed to setup dm-crypt key mapping. Check kernel for support for the aes-cbc-essiv:sha256 cipher spec and verify that /dev/loop0 contains at least 133 sectors|}}, then run {{ic|modprobe dm-mod}}.}}<br />
<br />
cryptsetup luksOpen /dev/loop0 secret<br />
<br />
The encrypted container is now available through the device file {{ic|/dev/mapper/secret}}.<br />
Now we are able to create a partition in the container:<br />
<br />
mkfs.ext2 /dev/mapper/secret<br />
<br />
and mount it...<br />
<br />
mkdir /mnt/secret<br />
mount -t ext2 /dev/mapper/secret /mnt/secret<br />
<br />
We can now use the container as if it was a normal partition!<br />
To unmount the container:<br />
<br />
umount /mnt/secret<br />
cryptsetup luksClose secret<br />
losetup -d /dev/loop0 # free the loopdevice.<br />
<br />
so, if you want to mount the container again, you just apply the following commands:<br />
<br />
losetup /dev/loop0 /bigsecret<br />
cryptsetup luksOpen /dev/loop0 secret<br />
mount -t ext2 /dev/mapper/secret /mnt/secret<br />
<br />
=== Encrypt using a key-file ===<br />
Let us first generate a 2048 byte random keyfile:<br />
<br />
dd if=/dev/urandom of=keyfile bs=1k count=2<br />
<br />
We can now format our container using this key<br />
<br />
cryptsetup luksFormat /dev/loop0 keyfile<br />
<br />
or our partition : <br />
<br />
cryptsetup luksFormat /dev/hda2 keyfile<br />
<br />
Once formatted, we can now open the LUKS device using the key:<br />
<br />
cryptsetup -d keyfile luksOpen /dev/loop0 container<br />
<br />
You can now like before format the device {{ic|/dev/mapper/container}} with your favorite filesystem and then mount it just as easily.<br />
<br />
The keyfile is now the only key to your file. I personally advise encrypting your keyfile using your private GPG key and storing an off-site secured copy of the file.<br />
<br />
=== Resizing the loopback filesystem ===<br />
First we should unmount the encrypted container:<br />
umount /mnt/secret<br />
cryptsetup luksClose secret<br />
losetup -d /dev/loop0 # free the loopdevice.<br />
<br />
After this we need to expand our container file with the size of the data we want to add:<br />
<br />
dd if=/dev/urandom bs=1M count=1024 | cat - >> /bigsecret<br />
<br />
Be careful to really use TWO {{ic|>}}, or you will override your current container!<br />
<br />
You could use {{ic|/dev/zero}} instead of {{ic|/dev/urandom}} to significantly speed up the process, but with {{ic|/dev/zero}} your encrypted filesystems will ''not be as secure''. (A better option to create random data quicker than {{ic|/dev/urandom}} is {{ic|frandom}} [http://aur.archlinux.org/packages.php?ID=9869], available from the [[AUR]]).<br />
<br />
Now we have to map the container to the loop device:<br />
losetup /dev/loop0 /bigsecret<br />
cryptsetup luksOpen /dev/loop0 secret<br />
After this we will resize the encrypted part of the container to the maximum size of the container file:<br />
cryptsetup resize secret<br />
Finally, we can resize the filesystem. Here is an example for ext2/3/4:<br />
e2fsck -f /dev/mapper/secret # Just doing a filesystem check, because it's a bad idea to resize a broken fs<br />
resize2fs /dev/mapper/secret<br />
You can now mount your container again:<br />
mount /dev/mapper/secret /mnt/secret<br />
<br />
== Encrypting a LVM setup ==<br />
It's really easy to use encryption with [[LVM]]. If you do not know how to set up LVM, then read [[Installing_with_Software_RAID_or_LVM]].<br />
<br />
The easiest and best method is to set up LVM on top of the encrypted partition instead of the other way around. This link here is easy to follow and explains everything: [http://www.pindarsign.de/webblog/?p=767 Arch Linux: LVM on top of an encrypted partition]<br />
<br />
The most important thing in setting LVM on '''top''' of encryption is that you need to have the {{ic|encrypt}} hook '''before''' the {{ic|lvm2}} hook (and those two before the {{ic|filesystems}} hook, but that's repeating) ''because they are processed in order''.<br />
<br />
To use encryption on top of LVM, you have to first set up your LVM volumes and then use them as the base for the encrypted partitions. That means, in short, that you have to set up LVM first. Then follow this guide, but replace all occurrences of {{ic|/dev/sdXy}} in the guide with its LVM counterpart. (E.g.: {{ic|/dev/sda5}} -> {{ic|/dev/<volume group name>/home}}).<br />
<br />
Do not forget to add the {{ic|encrypt}} hook in {{ic|/etc/mkinitcpio.conf}} '''before''' the {{ic|lvm2}} hook, if you chose to set up encrypted partitions on '''top''' of LVM. Also remember to change {{ic|USELVM}} in {{ic|/etc/rc.conf}} to {{ic|"yes"}}.<br />
<br />
=== LVM with Arch Linux Installer (>2009.08) ===<br />
<br />
Since Arch Linux images 2009.08, LVM and dm_crypt is supported by the installer out of the box.<br />
This makes it very easy to configure your system for [[LVM]] on dm-crypt or vice versa.<br />
Actually the configuration is done exactly as without LVM: see the [[#Arch Linux Installer (>2009.08)|corresponding]] section above. It differs only in two aspects.<br />
<br />
==== The partition and filesystem choice ====<br />
Create a small, unencrypted boot partition and use the remaining space for a single partition which can later be split up into multiple logic volumes by [[LVM]].<br />
<br />
For a LVM-on-dm-crypt system set up the filesystems and mounting points for example like this:<br />
/dev/sda1 raw->ext2;yes;/boot;no_opts;no_label;no_params<br />
/dev/sda2 raw->dm_crypt;yes;no_mountpoint;no_opts;sda2crypt;-c_aes-xts-plain_-y_-s_512<br />
/dev/mapper/sda2crypt dm_crypt->lvm-vg;yes;no_mountpoint;no_opts;no_label;no_params<br />
/dev/mapper/sda2crypt+ lvm-pv->lvm-vg;yes;no_mountpoint;no_opts;cryptpool;no_params<br />
/dev/mapper/cryptpool lvm-vg(cryptpool)->lvm-lv;yes;no_mountpoint;no_opts;cryptroot;10000M|lvm-lv;yes;no_mountpoint;no_opts;crypthome;20000M<br />
/dev/mapper/cryptpool-cryptroot lvm-lv(cryptroot)->ext3;yes;/;no_opts;cryptroot;no_params<br />
/dev/mapper/cryptpool-crypthome lvm-lv(crypthome)->ext3;yes;/home;no_opts;cryptroot;no_params<br />
<br />
==== The configuration stage ====<br />
<br />
* In {{ic|/etc/rc.conf}} set {{ic|USELVM}} to {{ic|"yes"}}<br />
* In {{ic|/etc/mkinitcpio.conf}} add the {{ic|encrypt}} hook '''before''' the {{ic|lvm2}} hook in the {{ic|HOOKS}} array, if you set up LVM on top of the encrypted partition.<br />
<br />
That is it for the LVM & dm_crypt specific part. The rest is done as usual.<br />
<br />
=== Applying this to a non-root partition ===<br />
You might get tempted to apply all this fancy stuff to a non-root partition. Arch does not support this out of the box, however, you can easily change the cryptdev and cryptname values in {{ic|/lib/initcpio/hooks/encrypt}} (the first one to your {{ic|/dev/sd*}} partition, the second to the name you want to attribute). That should be enough.<br />
<br />
The big advantage is you can have everything automated, while setting up {{ic|/etc/crypttab}} with an external key file (i.e. the keyfile is not on any internal hard drive partition) can be a pain - you need to make sure the USB/FireWire/... device gets mounted before the encrypted partition, which means you have to change the order of {{ic|/etc/fstab}} (at least).<br />
<br />
Of course, if the {{Pkg|cryptsetup}} package gets upgraded, you will have to change this script again. However, this solution is to be preferred over hacking {{ic|/etc/rc.sysinit}} or similar files. Unlike {{ic|/etc/crypttab}}, only one partition is supported, but with some further hacking one should be able to have multiple partitions unlocked.<br />
<br />
If you want to do this on a software RAID partition, there is one more thing you need to do. Just setting the {{ic|/dev/mdX}} device in {{ic|/lib/initcpio/hooks/encrypt}} is not enough; the {{ic|encrypt}} hook will fail to find the key for some reason, and not prompt for a passphrase either. It looks like the RAID devices are not brought up until after the {{ic|encrypt}} hook is run. You can solve this by putting the RAID array in {{ic|/boot/grub/menu.lst}}, like <br />
kernel /boot/vmlinuz26 md=1,/dev/hda5,/dev/hdb5<br />
<br />
If you set up your root partition as a RAID, you will notice the similarities with that setup ;-). [[GRUB]] can handle multiple array definitions just fine:<br />
kernel /boot/vmlinuz26 root=/dev/md0 ro md=0,/dev/sda1,/dev/sdb1 md=1,/dev/sda5,/dev/sdb5,/dev/sdc5<br />
<br />
=== LVM and dm-crypt manually (short version) ===<br />
<br />
==== Notes ====<br />
If you are smart enough for this, you will be smart enough to ignore/replace LVM-specific things if you do not want to use LVM.<br />
<br />
{{Note|This brief uses reiserfs for some of the partitions, so change this accordingly if you want to use a more "normal" file system, like ext4.}}<br />
<br />
==== Partitioning scheme ====<br />
{{ic|/dev/sda1}} -> {{ic|/boot}}<br />
{{ic|/dev/sda2}} -> LVM<br />
<br />
==== The commands ====<br />
cryptsetup -d /dev/random -c aes-xts-plain -s 512 create lvm /dev/sda2<br />
dd if=/dev/urandom of=/dev/mapper/lvm<br />
cryptsetup remove lvm<br />
lvm pvcreate /dev/sda2<br />
lvm vgcreate lvm /dev/sda2<br />
lvm lvcreate -L 10G -n root lvm<br />
lvm lvcreate -L 500M -n swap lvm<br />
lvm lvcreate -L 500M -n tmp lvm<br />
lvm lvcreate -l 100%FREE -n home lvm<br />
cryptsetup luksFormat -c aes-xts-plain -s 512 /dev/lvm/root<br />
cryptsetup luksOpen /dev/lvm/root root<br />
mkreiserfs /dev/mapper/root<br />
mount /dev/mapper/root /mnt<br />
dd if=/dev/zero of=/dev/sda1 bs=1M<br />
mkreiserfs /dev/sda1<br />
mkdir /mnt/boot<br />
mount /dev/sda1 /mnt/boot<br />
mkdir -p -m 700 /mnt/etc/luks-keys<br />
dd if=/dev/random of=/mnt/etc/luks-keys/home bs=1 count=256<br />
<br />
==== Install Arch Linux ====<br />
Run {{ic|/arch/setup}}<br />
<br />
==== Configuration ====<br />
<br />
===== /etc/rc.conf =====<br />
Change {{ic|USELVM<nowiki>=</nowiki>"no"}} to {{ic|USELVM<nowiki>=</nowiki>"yes"}}.<br />
<br />
===== /etc/mkinitcpio.conf =====<br />
Put {{ic|lvm2}} and {{ic|encrypt}} (in that order) before {{ic|filesystems}} in the {{ic|HOOKS}} array. Again, note that you are setting encryption on '''top''' of LVM.)<br />
<br />
===== /boot/grub/menu.lst =====<br />
Change {{ic|root<nowiki>=</nowiki>/dev/hda3}} to {{ic|root<nowiki>=</nowiki>/dev/lvm/root}}.<br />
<br />
For kernel >= 2.6.30, you should change {{ic|root<nowiki>=</nowiki>/dev/hda3}} to the following:<br />
cryptdevice=/dev/lvm/root:root root=/dev/mapper/root<br />
<br />
===== /etc/fstab =====<br />
/dev/mapper/root / reiserfs defaults 0 1<br />
/dev/sda1 /boot reiserfs defaults 0 2<br />
/dev/mapper/tmp /tmp tmpfs defaults 0 0<br />
/dev/mapper/swap none swap sw 0 0<br />
<br />
===== /etc/crypttab =====<br />
swap /dev/lvm/swap SWAP -c aes-xts-plain -h whirlpool -s 512<br />
tmp /dev/lvm/tmp /dev/urandom -c aes-xts-plain -s 512<br />
<br />
==== After rebooting ====<br />
<br />
===== The commands =====<br />
cryptsetup luksFormat -c aes-xts-plain -s 512 /dev/lvm/home /etc/luks-keys/home<br />
cryptsetup luksOpen -d /etc/luks-keys/home /dev/lvm/home home<br />
mkreiserfs /dev/mapper/home<br />
mount /dev/mapper/home /home<br />
<br />
===== /etc/crypttab =====<br />
home /dev/lvm/home /etc/luks-keys/home<br />
<br />
===== /etc/fstab =====<br />
/dev/mapper/home /home reiserfs defaults 0 0<br />
<br />
=== / on LVM on LUKS ===<br />
Make sure your kernel command line looks like this:<br />
root=/dev/mapper/<volume-group>-<logical-volume> cryptdevice=/dev/<luks-part>:<volume-group><br />
For example:<br />
root=/dev/mapper/vg-arch cryptdevice=/dev/sda4:vg<br />
<br />
Or like this:<br />
cryptdevice=/dev/<volume-group>/<logical-volume>:root root=/dev/mapper/root<br />
<br />
==Securing the unencrypted boot partition==<br />
Referring to an article from the ct-magazine (Issue 3/12, page 146, 01.16.2012 http://www.heise.de/ct/inhalt/2012/03/6/) the following script checks all files under /boot for changes of sha1 hash, inode and occupied blocks on the hard drive. It also checks the MBR.<br />
<br />
The script with installation instructions is available here: ftp://ftp.heise.de/pub/ct/listings/1203-146.zip (Autor: Juergen Schmidt, ju at heisec.de; License: GPLv2)<br />
<br />
There is also an AUR package: https://aur.archlinux.org/packages.php?ID=56934<br />
<br />
After installation do<br />
echo "/usr/local/bin/chkboot.sh &" >> /etc/rc.local<br />
<br />
And as chkboot_user.sh need to be excuted after login, add it to the autostarts.<br />
<br />
== Resources ==<br />
* [http://yannickloth.be/blog/2010/08/01/installing-archlinux-with-software-raid1-encrypted-filesystem-and-lvm2/ Install Archlinux on top of raid, LVM2 and encrypted partitions]<br />
* [http://www.freeotfe.org/ FreeOTFE] - Supports unlocking LUKS encrypted volumes in Microsoft Windows.</div>Ekhttps://wiki.archlinux.org/index.php?title=Improving_performance&diff=148280Improving performance2011-07-04T21:37:08Z<p>Ek: Update on compcache. Its now known as zram and in mainline. No need for aur package.</p>
<hr />
<div>[[Category: Other desktop user's resources (English)]]<br />
{{i18n|Maximizing Performance}}<br />
This article is a retrospective analysis and basic rundown about gaining performance in Arch Linux.<br />
<br />
==The basics==<br />
<br />
===Know your system===<br />
The best way to tune a system is to target the bottlenecks, that is the subsystems that limit the overall speed. They usually can be identified by knowing the specifications of the system, but there are some basic indications:<br />
* If the computer becomes slow when big applications, like openoffice and firefox, are running at the same time, then there is a good chance the amount of RAM is insufficient. To verify available RAM, use this command, and check for the line beginning with -/+buffers:<br />
$ free -m<br />
* If boot time is really slow, and if applications take a lot of time to load the first time they are launched, but run fine afterwards, then the hard drive is probably too slow. The speed of a hard drive can be measured using the hdparm command:<br />
$ hdparm -t /dev/harddrive<br />
This is only the pure read speed of the hard drive, and is not a valid benchmark, but a value superior to 40MB/s (assuming drive tested while idle) can be considered decent on an average system.<br />
* If the CPU load is consistently high even when RAM is available, then lowering CPU usage should be a priority. CPU load can be monitored in many ways, like using the top command:<br />
$ top<br />
* If the only applications lagging are the ones using direct rendering, meaning they use the graphic card, like video players and games, then improving the graphic performance should help. First step would be to verify if direct rendering simply isn't enabled. This is indicated by the glxinfo command:<br />
$ glxinfo | grep direct<br />
<br />
===The first thing to do===<br />
The simplest and most efficient way of improving overall performance is to run lightweight environments and applications.<br />
* Use a [[Window Manager|window manager]] instead of a [[Desktop Environment]]. Choices include [[dwm]], [[Openbox]] and [[JWM]].<br />
* Choose a minimal Desktop Environment over [[GNOME]] and [[KDE]]. Choices include [[LXDE]] and [[Xfce]].<br />
* Using lightweight applications. See [[Lightweight Software]] and the Light and Fast Applications Awards threads in the forum: [http://bbs.archlinux.org/viewtopic.php?id=41168 2007], [http://bbs.archlinux.org/viewtopic.php?id=67951 2008], [http://bbs.archlinux.org/viewtopic.php?id=78490 2009],[http://bbs.archlinux.org/viewtopic.php?id=88515 2010], and [http://bbs.archlinux.org/viewtopic.php?id=111878 2011].<br />
* Remove unnecessary daemons and background what daemons you can in {{Filename|/etc/rc.conf}}.<br />
<br />
===Compromise===<br />
Almost all tuning brings drawbacks. Lighter applications usually come with less features and some tweaks may make a system unstable, or simply require time to implement and maintain. This page tries to highlight those drawbacks, but the final judgment rests on the user.<br />
<br />
===Benchmarking===<br />
The effects of optimization are often difficult to judge. They can however be measured by [[benchmarking]] tools<br />
<br />
==Storage devices==<br />
===Choosing and tuning your filesystem===<br />
Choosing the best filesystem for a specific system is very important because each has its own strengths. The [[Beginner's Guide#Filesystem Types|beginner's guide]] provides a short summary of the most popular ones. You can also find relevant articles [[:Category:File systems (English)|here]].<br />
<br />
====Summary====<br />
*XFS: Excellent performance with large files. Low speed with small files. A good choice for /home.<br />
*Reiserfs: Excellent performance with small files. A good choice for /var.<br />
*Ext3: Average performance, reliable.<br />
*Ext4: Great overall performance, reliable, has performance issues with sqlite and some other databases.<br />
*JFS: Good overall performance, very low CPU usage, extremely fast resume after power failure.<br />
*Btrfs: Great overall performance (better than ext4), reliable (once it becomes stable). Lots of features. Still in heavy development and considered as unstable. Do not use this filesystem yet unless you know what you are doing and are prepared for potential data loss.<br />
<br />
====Mount options====<br />
Mount options offer an easy way to improve speed without reformatting. They can be set using the mount command:<br />
$ mount -o option1,option2 /dev/partition /mnt/partition<br />
To set them permanently, you can modify /etc/fstab to make the relevant line look like this:<br />
/dev/partition /mnt/partition partitiontype option1,option2 0 0<br />
A couple of mount options improving performance on almost all file-systems is {{Codeline|noatime,nodiratime}}. The former is a superset of the latter (which applies to directories only -- {{Codeline|noatime}} applies to both files and directories). In rare cases, for example if you use mutt, it can cause minor problems. You can instead use the {{Codeline|relatime}} option (NB relatime is the default in >2.6.30)<br />
<br />
====Ext3====<br />
See [[Ext3 Filesystem Tips]].<br />
<br />
====Ext4====<br />
See the [[Ext4#Improving performance | Ext4 wiki page]].<br />
<br />
====JFS====<br />
See [[JFS Filesystem#Optimizations| JFS Filesystem]].<br />
<br />
====XFS====<br />
For optimal speed, create an XFS file-system with:<br />
$ mkfs.xfs -l internal,lazy-count=1,size=128m -d agcount=2 /dev/thetargetpartition<br />
An XFS specific mount option that may increase performance is {{Codeline|<nowiki>logbufs=8</nowiki>}}. <br />
<br />
#/etc/fstab<br />
LABEL=XFSHOME /home xfs noatime,logbufs=8 0 1<br />
<br />
==== Reiserfs ====<br />
<br />
The {{Codeline|<nowiki>data=writeback</nowiki>}} mount option improves speed, but may corrupt data during power loss. The {{Codeline|notail}} mount option increases the space used by the filesystem by about 5%, but also improves overall speed. You can also reduce disk load by putting the journal and data on separate drives. This is be done when creating the filesystem: <br />
<br />
$ mkreiserfs –j /dev/hda1 /dev/hdb1<br />
<br />
Replace /dev/hda1 with the partition reserved for the journal, and /dev/hdb1 with the partition for data. You can learn more about reiserfs with this [http://www.funtoo.org/en/articles/linux/ffg/2/ article].<br />
<br />
====BTRFS====<br />
Btrfs is a new filesystem offering online defragmentation, optimized mode for SSDs, writable snapshots, changing size of partition without data loss and many other features. Btrfs is still in active development, and is available in the kernel (marked experimental). See more info on the [http://btrfs.wiki.kernel.org/index.php/Main_Page Btrfs homepage].<br />
<br />
===== mkinitcpio.conf for btrfs =====<br />
<br />
For non-root btrfs filesystems the btrfs module and dependencies are loaded when required. For a root btrfs filesystem you should ensure the initial ramdisk has the correct modules. There is a dependency of the btrfs module on the libcrc32c module. You can add crc32c to the modules line of /etc/mkinitcpio.conf like so:<br />
<br />
MODULES="crc32c libcrc32c zlib_deflate btrfs"<br />
<br />
This avoids pitfalls like "unknown symbol" errors when loading the btrfs modules.<br />
See also [http://aur.archlinux.org/packages.php?ID=33376 mkinitcpio-btrfs].<br />
<br />
===Compressing /usr===<br />
A way to speed up reading from the hard drive is to compress the data, because there is less data to be read. It must however be decompressed, which means a greater CPU load. Some filesystems support transparent compression, most notably btrfs and reiserfs4, but their compression ratio is limited by the 4k block size. A good alternative is to compress /usr in a squashfs file, with a 64k(128k) block size, as instructed in this [http://forums.gentoo.org/viewtopic-t-646289.html Gentoo forums thread]. What this tutorial does is basically to compress the /usr folder into a compressed squashfs file-system, then mounts it with aufs. A lot of space is saved, usually two thirds of the original size of /usr, and applications load faster. However, each time an application is installed or reinstalled, it is written uncompressed, so /usr must be re-compressed periodically. Squashfs is already in the kernel, and aufs2 is in the extra repository, so no kernel compilation is needed if using the stock kernel.<br />
Since the linked guide is for Gentoo the next commands outline the steps especially for Arch. Basically we have got install two packages to get it working:<br />
# pacman -S aufs2 squashfs-tools<br />
This command installs the aufs-modules and some userspace-tools for the squash-filesystem.<br />
Now we need some extra directories where we can store the archive of /usr as read-only and another folder where we can store the data changed after the last compression as writeable:<br />
# mkdir -p /squashed/usr/{ro,rw}<br />
Now that we got a rough setup you should perform a complete system-upgrade since every change of content in /usr after the compression will be excluded from this speedup. If you use prelink you should also perform a complete prelink before creating the archive. Now it is time to invoke the command to compress /usr:<br />
# mksquashfs /usr /squashed/usr/usr.sfs -b 65536<br />
These parameters/options are the ones suggested by the Gentoo link but there might be some room for improvement using some of the options described [http://www.tldp.org/HOWTO/SquashFS-HOWTO/mksqoverview.html#mksqusing here].<br />
Now to get the archive mounted together with the writeable folder it is necessary to edit fstab:<br />
# nano /etc/fstab<br />
Add the following lines:<br />
/squashed/usr/usr.sfs /squashed/usr/ro squashfs loop,ro 0 0 <br />
usr /usr aufs udba=reval,br:/squashed/usr/rw:/squashed/usr/ro 0 0<br />
Now you should be done and able to reboot. The original Author suggests to delete all the old content of /usr, but this might cause some problems if anything goes wrong during some later re-compression. It is more safe to leave the old files in place just to be on the safe side.<br />
<br />
A [http://bbs.archlinux.org/viewtopic.php?pid=714052 bash script] has been created that will automate the process of re-compressing (read updating) the archive since the tutorial is meant for Gentoo and some options don't correlate to what they should be in Arch.<br />
<br />
===Tuning for an SSD===<br />
[[SSD#Tips_for_Maximizing_SSD_Performance]]<br />
<br />
==CPU==<br />
The only way to directly improve CPU speed is overclocking. As it is a complicated and risky task, it is not recommended for anyone except experts. The best way to overclock is through the BIOS. When purchasing your system, keep in mind that most Intel motherboards are notorious for disabling the capacity to overclock.<br />
<br />
A way to modify performance ([http://lkml.org/lkml/2009/9/6/136 ref]) is to use Con Kolivas' desktop-centric kernel patchset, which, among other things, replaces the Completely Fair Scheduler (CFS) with the Brain Fuck Scheduler (BFS).<br />
<br />
Kernel PKGBUILDs that include the BFS patch can be installed from the [[AUR]] or [[Unofficial_User_Repositories]]. See the respective pages for [http://aur.archlinux.org/packages.php?ID=32877 kernel26-ck], [http://aur.archlinux.org/packages.php?ID=36384 kernel26-bfs] or [http://aur.archlinux.org/packages.php?ID=40191 kernel26-pf] for more information on their additional patches.<br />
<br />
{{Note|BFS/CK are designed for desktop/laptop use and not servers. They provide low latency and work well for 16 CPUs or less. Also, Con Kolivas suggests setting HZ to 1000. For more information, see the [http://ck.kolivas.org/patches/bfs/bfs-faq.txt BFS FAQ] and [http://www.kernel.org/pub/linux/kernel/people/ck/patches/2.6/2.6.37/2.6.37-ck1/patches/ ck patches].}}<br />
===[[Verynice]]===<br />
[http://thermal.cnde.iastate.edu/~sdh4/verynice/ Verynice] is a daemon, available on [http://aur.archlinux.org/packages.php?ID=6403 AUR], for dynamically adjusting the nice levels of executables. The nice level represent the priority of the executable when allocating CPU resources. Simply define executables for which responsiveness is important, like X or multimedia applications, as ''goodexe'' in {{filename|/etc/verynice.conf}}. Similarly, CPU-hungry executables running in the background, like make, can be defined as ''badexe''. This prioritisation greatly improves system responsiveness under heavy load.<br />
<br />
===[[Ulatencyd]]===<br />
Ulatency is a daemon that controls how the Linux kernel will spend it's resources on the running processes. It uses dynamic cgroups to give the kernel hints and limitations on processes.<br />
<br />
==Network==<br />
See relevant section in [[General Recommendations#Networking|General Recomendations]].<br />
<br />
==Graphics==<br />
<br />
===Xorg.conf configuration===<br />
Graphic performance heavily depends on the settings in {{Filename|/etc/X11/xorg.conf}}. There are tutorials for [[Nvidia]], [[ATI]] and [[Intel]] cards. Improper settings may stop Xorg from working, so caution is advised.<br />
<br />
===Driconf===<br />
Driconf is a small utility that allows you to change the direct rendering settings for open source drivers. Enabling HyperZ can drastically improve performance.<br />
<br />
===GPU Overclocking===<br />
Overclocking a graphics card is typically more expedient than with a CPU, since there are readily accessible software packages which allow for on-the-fly GPU clock adjustments. For ATI users, get [http://aur.archlinux.org/packages.php?ID=2128 rovclock], and Nvidia users should get nvclock in the extra repository. Intel chipsets users can install [http://www.gmabooster.com/ GMABooster] from [http://aur.archlinux.org/packages.php?ID=28197 AUR]<br />
<br />
The changes can be made permanent by running the appropriate command after X boots, for example by adding it to {{Filename|~/.xinitrc}}. A safer approach would be to only apply the overclocked settings when needed.<br />
<br />
==RAM and swap==<br />
<br />
=== Swappiness ===<br />
<br />
The swappiness represent how much the kernel prefers swap to RAM. Setting it to a very low value, meaning the kernel will almost always use RAM, is known to improve responsiveness on many systems. To do that, simply add those line to {{Filename|/etc/sysctl.conf}}:<br />
<br />
vm.swappiness=20<br />
vm.vfs_cache_pressure=50<br />
<br />
To test and more on why this may work, take a look at this [http://rudd-o.com/en/linux-and-free-software/tales-from-responsivenessland-why-linux-feels-slow-and-how-to-fix-that article].<br />
<br />
===Compcache===<br />
[http://code.google.com/p/compcache/ Compcache], also known as the zram kernel module, creates a swap device in RAM and compresses it. That means that part of the RAM can hold much more information, but uses more CPU. Still, is it much quicker than a hard drive swap. If a system often falls back to swap, this could improve responsiveness. Zram is in mainline staging (therefore its not stable yet, use with caution).<br />
<br />
modprobe zram<br />
<br />
It is also possible (and recommended) to tell compcache to fall back on the hard drive swap when full. To do this, define a backing swap device in the configuration file. This swap device must not be in use when zram is started, so remove it from your /etc/fstab!<br />
<br />
This is also a good way to reduce disk read/write cycles due to swap on SSDs.<br />
<br />
===Mounting /tmp to RAM===<br />
This will make your system a tiny bit faster, but will take up some of your RAM. It also reduces disk read/write cycles, and is therefore a good choice if using an SSD or if you have RAM to spare. Simply add this line to {{Filename|/etc/fstab}} and reboot:<br />
tmpfs /tmp tmpfs defaults,noatime,nodev,nosuid,mode=1777 0 0<br />
<br />
===Using the graphic card's RAM===<br />
In the unlikely case that you have very little RAM and a surplus of video RAM, you can use the latter as swap. See [[Swap on video ram]].<br />
<br />
=== Preloading ===<br />
Preloading is the action of putting and keeping target files into the RAM. The practical use is that preloaded applications always start very quickly, because reading from the RAM is always quicker than from the hard drive. However, part of your RAM will be dedicated to this task, but no more than if you kept the application open. Therefore, preloading is best used with heavy, often-used applications, like firefox and openoffice.<br />
==== Go-preload ====<br />
[http://aur.archlinux.org/packages.php?ID=34207 Go-preload] is a small daemon created in the [http://forums.gentoo.org/viewtopic-t-789818-view-next.html?sid=5457cff93039fc7d4a3e445ef90f9821 gentoo forum]. To use it, first run this command in a terminal for each program you want to preload at boot:<br />
# gopreload-prepare program<br />
Then, as instructed, press enter when the program is fully loaded. This will add a list of files needed by the program in {{Filename|/usr/share/gopreload/enabled}}. To load all lists at boot, simply add gopreload to your DAEMONS array in {{Filename|/etc/rc.conf}}. To disable the loading of a program, remove the appropriate list in {{Filename|/usr/share/gopreload/enabled}}, or move it to {{Filename|/usr/share/gopreload/disabled}}.<br />
====Preload====<br />
A more automated, albeit less KISS, approach is used by [[Preload]]. All you have to do is add it to your DAEMONS array in {{Filename|/etc/rc.conf}}. It will monitor the most used files on your system, and with time build its own list of files to preload at boot.<br />
====Readahead====<br />
[[Readahead]] is a tool that can cache files before needed and help you accelerating program loading.<br />
<br />
==Boot time==<br />
You can find tutorials with good tips in the article [[Improve Boot Performance]].<br />
<br />
===Suspend to ram===<br />
The best way to reduce boot time is not booting at all. Consider [[Suspend to RAM|suspending your system to ram]] instead.<br />
<br />
===Kernel boot options===<br />
Some boot options can decrease kernel boot time. The {{Codeline|fastboot}} option usually can take off one second or so. Also, if you see a message saying "Waiting 8s for device XXX" at boot, adding {{Codeline|<nowiki>rootdelay=1</nowiki>}} can reduce the waiting time, but be careful, as it may break the booting process. Those options are set in {{Filename|/boot/grub/menu.lst}} or {{Filename|/etc/lilo.conf}}, depending on which bootloader you use.<br />
<br />
===Custom kernel===<br />
Compiling a custom kernel will reduce boot time and memory usage, but can be long, complicated and even painful. It usually is not worth the effort, but can be very interesting and a great learning experience. If you really know what you are doing, start [[Kernel Compilation|here]].<br />
<br />
==Application-specific tips==<br />
===Firefox===<br />
The [[Firefox]] article offers good tips; most notably [[Firefox Tips and Tweaks#Improve rendering by disabling pango |disabling pango]], [[Firefox Tips and Tweaks#Defragment the profile's SQLite databases|cleaning the sqlite database]], and using [[Firefox#Firefox customized for speed|firefox-pgo]]. See also: [[Speed-up Firefox using tmpfs]], and [[Firefox Tips and Tweaks#Turning off anti-phishing|Turning off anti-phishing]].<br />
<br />
===Gcc/Makepkg===<br />
See [[Ccache]].<br />
<br />
===Mkinitcpio===<br />
User josh_ from the forum has made impressive changes to the mkinitcpio script, making it two or three times faster. While waiting for these changes to be implemented, you can get them [http://bbs.archlinux.org/viewtopic.php?id=79898 here].<br />
<br />
===LibreOffice===<br />
See [[LibreOffice#Speed up LibreOffice|Speed up LibreOffice]].<br />
<br />
===Pacman===<br />
See [[Improve Pacman Performance]].<br />
<br />
===SSH===<br />
See [[SSH#Speed up SSH|Speed up SSH]].</div>Ekhttps://wiki.archlinux.org/index.php?title=Xfce&diff=148149Xfce2011-07-03T22:50:53Z<p>Ek: Corrected 3-headings to 5-headings to keep constitent with other headings.</p>
<hr />
<div>[[Category:Desktop environments (English)]]<br />
{{i18n|Xfce}}<br />
[[pl:XFCE]]<br />
[[de:Xfce]]<br />
<br />
{{Article summary start}}<br />
{{Article summary text|Xfce is a lightweight desktop environment for Unix-like operating systems. It aims to be fast and lightweight, while still being visually appealing and user friendly. This article covers its installation, configuration, and troubleshooting.}}<br />
{{Article summary text|Xfce uses the [[GTK+]] toolkit.}}<br />
{{Article summary heading|Overview}}<br />
{{Article summary text|{{Graphical user interface overview}}}}<br />
{{Article summary end}}<br />
<br />
From [http://www.xfce.org/about/ Xfce - About]:<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 />
== What is Xfce? ==<br />
Xfce is a Desktop Environment, like GNOME or KDE. It contains a suite of apps like a root window app, window manager, file manager, panel, etc. Xfce is written using the GTK2 toolkit, and contains its own development environment (libraries, daemons, etc), similar to other big DEs.<br />
<br />
==Features==<br />
{{expansion}}<br />
*Lighter on resources than the other major DEs (KDE, GNOME).<br />
*Most settings are exposed via a GUI, Xfce doesn't try to hide stuff from the user.<br />
*Xfwm has an optional built-in compositor which allows for true transparency and all the benefits of GPU acceleration (minimizes tearing, etc.).<br />
*It works great with multiple monitors.<br />
*Xfce4 is stable, mature software.<br />
<br />
==Installation==<br />
Xfce is somewhat modular. That means there is no need for you to run every part, you can pick and choose some of them. Because of this, Xfce has some separate Arch packages.<br />
<br />
=====Installing Xfce=====<br />
To install the base Xfce system, run:<br />
<br />
# pacman -S xfce4<br />
<br />
Pacman will ask you to select the packages to install, you probably want to get them all by simply pressing enter.<br />
<br />
{{Note |Or you can install only a few needed '''core packages''':<br />
<br />
# pacman -S xfwm4 xfce4-panel xfdesktop thunar xfce4-session xfce4-settings xfce4-appfinder xfce-utils xfconf<br />
<br />
}}<br />
<br />
If you want extras, like panel plugins, run this:<br />
<br />
# pacman -S xfce4-goodies<br />
<br />
Like before, pacman will ask you which packages you want to install.<br />
<br />
If you wish to admire 'Tips and Tricks' on login, install the fortune-mod package:<br />
<br />
# pacman -S fortune-mod<br />
<br />
In order to get the xfce4-mixer to work with alsa, you need to install gstreamer0.10-base-plugins. (See below for help with OSS.)<br />
<br />
# pacman -S gstreamer0.10-base-plugins<br />
<br />
=====Installing and configuring the Daemons=====<br />
Install [[D-Bus]]:<br />
# pacman -S dbus<br />
<br />
{{Daemon|dbus}}<br />
<br />
Install [[Gamin]] (the successor of [[FAM]]). It is configured to automatically run in the background by default, do not add it to rc.conf.<br />
<br />
# pacman -S gamin<br />
<br />
== Running Xfce ==<br />
<br />
=====Automatically at boot time=====<br />
See [[Display Manager]] to install and configure a Display Manager. Be sure to configure it properly for [[PolicyKit]].<br />
<br />
=====Manually=====<br />
<br />
You can execute:<br />
$ startxfce4<br />
from the console, or configure [[xinitrc]] and use xinit or startx.<br />
<br />
If you have not created a ~/.xinitrc yet, do so with:<br />
<br />
$ cp /etc/skel/.xinitrc ~/.xinitrc<br />
<br />
and add the following line:<br />
<br />
exec ck-launch-session dbus-launch --exit-with-session startxfce4<br />
<br />
Example:<br />
#!/bin/sh<br />
#<br />
# ~/.xinitrc<br />
#<br />
# Executed by startx (run your window manager from here)<br />
<br />
# exec gnome-session<br />
# exec startkde<br />
# exec startxfce4<br />
# ...or the Window Manager of your choice<br />
exec ck-launch-session dbus-launch --exit-with-session startxfce4<br />
<br />
{{{Note|<code>dbus-launch</code> starts a dbus-daemon instance to provide communication with PolicyKit. <code>ck-launch-session</code> starts a clean consolekit session needed by Xfce for power management, automounting, shutting down/rebooting etc. ConsoleKit/PolicyKit capable display managers such as gdm do this for you automatically. Notice dbus-launch must be placed after ck-launch-session, or there will be problems when mounting disks.}}}<br />
<br />
=====Shutting down, rebooting, and automounting from within Xfce=====<br />
* Make sure that '''dbus''' is enabled in the DAEMONS array in /etc/rc.conf.<br />
* Make sure you are a member of the ''power'' group for shutting down and rebooting.<br />
* Make sure you are a member of the ''storage'' group for automounting.<br />
* Make sure that you are using <code>exec ck-launch-session dbus-launch --exit-with-session startxfce4</code> in ~/.xinitrc '''or''' a ConsoleKit/PolicyKit capable display manager, such as [[GDM]] or [[Slim|SLiM]]. (see above)<br />
<br />
== Tips ==<br />
=== Panel ===<br />
==== How to customize xfce panel background ====<br />
Edit ~/.gtkrc-2.0. <br />
Note that you must place the image in the same directory as the configuration, which is ~/. You can not specify the path to the image, or it won't work.<br />
style "panel-background" {<br />
bg_pixmap[NORMAL] = "foo.bar"<br />
bg_pixmap[PRELIGHT] = "foo.bar"<br />
bg_pixmap[ACTIVE] = "foo.bar"<br />
bg_pixmap[SELECTED] = "foo.bar"<br />
bg_pixmap[INSENSITIVE] = "foo.bar"<br />
}<br />
widget_class "*Panel*" style "panel-background"<br />
<br />
==== Replacements for the default 'menu' panel applet ====<br />
The "Ubuntu System Panel" (Gnome) panel applet has similar features to those found in its KDE v4.2 equivalent. It can be added to an Xfce panel via the 'XfApplet' panel applet, which allows Gnome applets to be used in Xfce.<br />
<br />
It is available in [http://aur.archlinux.org/packages.php?ID=10259 the AUR]<br />
<br />
==== How to remove menu entries from the System menu ==== <br />
===== Method 1 =====<br />
With the built-in menu editor, you cannot remove menu entries from the System menu. Here’s how to hide them:<br />
# Open Terminal (Xfce menu > System > Terminal) and go to the /usr/share/applications folder: <pre>$ cd /usr/share/applications</pre><br />
# This folder should be full of .desktop files. To see a list type: <pre>$ ls</pre><br />
# Add ''NoDisplay=true'' to the .desktop file. For example, if you want to hide Firefox, type in the terminal:<pre>$ sudo echo "NoDisplay=true" >> firefox.desktop</pre> This command appends the text ''NoDisplay=true'' to the end of the .desktop file and saves the file<br />
<br />
===== Method 2 =====<br />
Another method is to copy the entire contents of the global applications directory over to your local applications directory, and then proceed to modify and/or disable unwanted .desktop entries. This will survive application updates that overwrite changes under /usr/share/applications/.<br />
# In a terminal, copy everything from /usr/share/applications to ~/.local/share/applications/: <pre>$ cp /usr/share/applications/* ~/.local/share/applications/</pre><br />
# For any entry you wish to hide from the menu, add the NoDisplay=true option: <pre>$ echo "NoDisplay=true" >> ~/.local/share/applications/foo.desktop</pre><br />
<br />
You can also edit the application's category by editing the .desktop file with a text editor and modifying the Categories= line.<br />
<br />
==== But what do you do with menu entries which do not show up in /usr/share/applications (e.g., apps installed via wine)? ==== <br />
I've found some shortcuts that show in the category “Other” in this directory:<br />
~/.local/share/applications/wine/.<br />
<br />
=== Desktop ===<br />
==== Why doesn't my desktop refresh? ====<br />
Xfce 4.6 uses [[FAM]] (File Alteration Monitor) or [[gamin]] (FAM's successor) to get notification when a file or directory changes.<br />
If you decide to use FAM, don't forget to add 'fam' to the list of DAEMONS in /etc/rc.conf.<br />
This step is not necessary for gamin.<br />
<br />
NOTE: After recent updates, FAM may have issues opening some mounts, such as sshfs. Use gamin if this is the case.<br />
<br />
==== Use a transparent background for desktop icon titles ====<br />
To change the default white background of desktop icon titles to something more suitable, edit the .gtkrc-2.0 file in your home directory (or create the file if needed) and add the following:<br />
style "xfdesktop-icon-view" {<br />
XfdesktopIconView::label-alpha = 10<br />
base[NORMAL] = "#000000"<br />
base[SELECTED] = "#71B9FF"<br />
base[ACTIVE] = "#71FFAD"<br />
fg[NORMAL] = "#ffffff"<br />
fg[SELECTED] = "#71B9FF"<br />
fg[ACTIVE] = "#71FFAD" }<br />
widget_class "*XfdesktopIconView*" style "xfdesktop-icon-view"<br />
<br />
==== Hide selected partitions on the desktop ====<br />
If you wish to prevent certain partitions or drives appearing on the desktop, you can create a udev rule, for example {{filename|/etc/udev/rules.d/10-local.rules}}:<br />
<br />
KERNEL=="sda1", ENV{UDISKS_PRESENTATION_HIDE}="1"<br />
KERNEL=="sda2", ENV{UDISKS_PRESENTATION_HIDE}="1"<br />
<br />
Would show all partitions with the exception of sda1 and sda2 on your desktop.<br />
<br />
==== Switch to old desktop right click menu without Thunar things ====<br />
xfconf-query -c xfce4-desktop -v --create -p /desktop-icons/style -t int -s 0<br />
<br />
=== XFWM4 ===<br />
==== How to enable the compositor in Xfce 4.6 ====<br />
Xfce 4.6 comes with a builtin compositor adding the option for fancy window effects, shadows and transparency and so on. It can be enabled in the Window Manager Tweaks and works on the fly. No additional settings are needed in your /etc/xorg.conf. To enable and adjust settings, go to:<br />
<br />
Menu --> Settings --> Window Manager Tweaks<br />
<br />
==== Disable window roll-up ====<br />
xfconf-query -c xfwm4 -p /general/mousewheel_rollup -s false<br />
<br />
=== Commands for the settings manager ===<br />
<br />
There is no official documentation for the commands executed. One must look at .desktop files ''/usr/share/applications/'' folder. For the people who like to know exactly what is happening, here is a handy list to save the effort:<br />
<br />
xfce-setting-show backdrop<br />
xfce-setting-show display<br />
xfce-setting-show keyboard<br />
xfce4-menueditor<br />
xfce-setting-show sound<br />
xfce-setting-show mouse<br />
xfce-setting-show session<br />
xfce-setting-show<br />
xfce-setting-show splash<br />
xfce-setting-show ui<br />
xfce-setting-show xfwm4<br />
xfce-setting-show wmtweaks<br />
xfce-setting-show workspaces<br />
xfce-setting-show printing_system<br />
xfce4-appfinder<br />
xfce4-autostart-editor<br />
xfce4-panel -c<br />
<br />
To review all the available setting manager commands run the following in a terminal:<br />
<br />
$ grep xfce-setting-show /usr/share/applications/xfce*settings*<br />
<br />
=== Session ===<br />
==== Customizing Startup Applications ====<br />
<br />
This includes getting necessary environment variables into the GUI runtime.<br />
<br />
* Copy the file /etc/xdg/xfce4/xinitrc to ~/.config/xfce4/<br />
* Edit this file. For example, you can add something like this somehwere in the middle:<br />
source $HOME/.bashrc<br />
# start rxvt-unicode server<br />
urxvtd -q -o -f<br />
<br />
==== Switch between users ====<br />
<br />
It is possible to switch between X sessions thanks to [http://goodies.xfce.org/projects/panel-plugins/xfswitch-plugin xfswitch-plugin ]. It adds an icon to the Xfce panel, and requires gdm to work at the moment.<br />
<br />
xfswitch-plugin is available through [http://aur.archlinux.org/packages.php?ID=40677 AUR ]<br />
<br />
==== Modify XML settings files directly ====<br />
It may be useful, especially when upgrading, to manually edit .xml files in the ~/.config/xfce4/xfconf/ folder. For application keyboard shortcuts for example, the file is ~/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml. It's faster to copy and paste the XML keys that you want rather than using the GUI.<br />
<br />
<br />
=== How to add themes to XFCE === <br />
<br />
1. Go to [http://xfce-look.org xfce-look.org] and click "Themes" in the left navbar. Look around for a theme you want and click "Download".<br />
<br />
2. Go to the directory where you downloaded the tarball/file and extract it using Squeeze/Xarchiver/CLI.<br />
<br />
3. Move the extracted folder to /usr/share/themes (for all users) or ~/.themes (for just you). Inside /usr/share/themes/abc, there is a folder that you create called xfwm4 that will contain whatever files that is included with that theme.<br />
<br />
4. GTK theme is available here:<br />
Menu --> Settings --> Appearance<br />
You select your xfwm theme in:<br />
Menu --> Settings --> Window Manager<br />
<br />
=== Cursors ===<br />
<br />
By default, X uses a plain black cursor. If you have alternative X cursor themes installed, Xfce can find them with:<br />
Menu --> Settings --> Mouse --> Theme<br />
<br />
To install new cursor themes, install {{Package Official|xcursor-themes}} or another {{Package Official|xcursor}} package, or see [[X11 Cursors]].<br />
<br />
=== Fonts ===<br />
<br />
If you find the standard fonts rather thick and or slightly out of focus open Settings>Appearence click on the Fonts tab and under Hinting: change to Full<br />
<br />
You could also try using a custom DPI setting.<br />
<br />
=== Sound ===<br />
<br />
===== Pulseaudio =====<br />
<br />
Sync-update the complete gstreamer group since xfce4 uses gstreamer as sound backend. The xfce mixer applet will be able to control volume (after setting device and master control).<br />
<br />
pacman -Syu gstreamer0.10-plugins<br />
<br />
===== How do I get xfce4-mixer and OSS4 to work together? =====<br />
<br />
Xfce 4.6 uses gstreamer as the backend to control volume, so first you have to make gstreamer cooperate with xfce4-mixer.<br />
<br />
pacman -S xfce4-mixer gstreamer0.10-base-plugins<br />
<br />
(Optional) Second, try to install gstreamer0.10-good-plugins, gstreamer0.10-bad-plugins<br />
<br />
pacman -S gstreamer0.10-good-plugins gstreamer0.10-bad-plugins<br />
<br />
login and logout, or just remove the mixer plugin and add it again. If it doesn't work at all, then you have to compile gstreamer0.10-good-plugins yourself. and can <br />
<br />
Download the PKGBUILD and other files needed from ABS or [http://projects.archlinux.org/svntogit/packages.git/tree/gstreamer0.10-good/repos here], edit the PKGBUILD, add --enable-oss. <br />
<br />
./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var \<br />
'''--enable-oss \'''<br />
--disable-static --enable-experimental \<br />
--disable-schemas-install \<br />
--disable-hal \<br />
--with-package-name="GStreamer Good Plugins (Archlinux)" \<br />
--with-package-origin="http://www.archlinux.org/"<br />
<br />
and then run makepkg -i. <br />
<br />
makepkg -i<br />
<br />
Still not working? Try tis package in AUR [http://aur.archlinux.org/packages.php?ID=17024 gstreamer0.10-good-plugins-ossv4], modify the pkgver to the newest in the PKGBUILD, and it should work.<br />
<br />
Other LINKS: [http://www.4front-tech.com/forum/ OSS forum]<br />
<br />
===== Change volume with keyboard volume buttons =====<br />
<br />
Go to <br />
Settings --> Keyboard<br />
Click the "Application Shortcuts" tab and add click the "Add" button. Add the following by entering the command, then pressing the corresponding button at the next window:<br />
<br />
===== ALSA =====<br />
For the raise volume button:<br />
amixer set Master 5%+<br />
For the lower volume button:<br />
amixer set Master 5%-<br />
For the mute button:<br />
amixer set Master toggle<br />
<br />
You can also run these commands to set the above commands to the standard XF86Audio keys:<br />
xfconf-query -c xfce4-keyboard-shortcuts -p /commands/custom/XF86AudioRaiseVolume -n -t string -s "amixer set Master 5%+"<br />
xfconf-query -c xfce4-keyboard-shortcuts -p /commands/custom/XF86AudioLowerVolume -n -t string -s "amixer set Master 5%-"<br />
xfconf-query -c xfce4-keyboard-shortcuts -p /commands/custom/XF86AudioMute -n -t string -s "amixer set Master toggle"<br />
<br />
If {{codeline|amixer set Master toggle}} does not work, try the PCM channel ({{codeline|amixer set PCM toggle}}) instead.<br />
<br />
The channel must have a "mute" option for the toggle command to work. To check whether or not your Master channel supports toggling mute, run {{codeline|alsamixer}} in a terminal and look for the double M's (MM) under the Master channel. If they are not present, then it does not support the mute option. If, for example, you had to change the toggle button to use the PCM channel, make sure to also set the PCM channel as the Mixer Track under Xfce Mixer properties.<br />
<br />
===== OSS =====<br />
Use one of these scripts:<br />
[http://www.opensound.com/wiki/index.php/Tips_And_Tricks#Using_multimedia_keys_with_OSS<br />
]<br />
<br />
If using ossvol (recommended), add:<br />
ossvol -i 1<br />
for the volume up button<br />
ossvol -d 1<br />
for the volume down button<br />
ossvol -t<br />
for the mute/unmute button<br />
<br />
=== Screenshots ===<br />
<br />
==== Using print-screen key ====<br />
<br />
A simple way is to use a command-line screenshot utility:<br />
<br />
# pacman -S scrot<br />
<br />
Then<br />
<br />
XFCE Menu --> Settings --> Keyboard >>> Application Shortcuts.<br />
<br />
Add the "scrot" command to use the "PrintScreen" key.<br />
<br />
All screenshots will be placed in your home folder with unique names like<br />
<br />
"2009-02-19-063052_1280x1024_scrot.png".<br />
<br />
====Screenshooter====<br />
<br />
There is also an a screenshot plugin for the Xfce panel, which can be used instead of scrot, that is available in extra:<br />
<br />
# pacman -S xfce4-screenshooter<br />
<br />
You can add a keyboard binding for it using the command<br />
<br />
xfce4-screenshooter -f<br />
<br />
instead of "scrot". You'll get a dialog window after pressing "Print" where you can copy the image to the clipboard or save it.<br />
<br />
=== Change mount options ===<br />
<br />
A common problem when automounting USB sticks formatted with fat filesystem is the inability to properly show characters as umlauts, ñ, ß, etc. This may be solved changing the default iocharset to utf8, which is easily done adding a line to '''/etc/xdg/xfce4/mount.rc''':<br />
<br />
[vfat]<br />
uid=<auto><br />
shortname=winnt<br />
'''utf8=true'''<br />
# FreeBSD specific option<br />
longnames=true<br />
<br />
Note that when using utf-8, the system will distinct between upper- and lowercases, potentially corrupting your files. Be careful.<br />
<br />
It is also recommendable to mount vfat devices with the '''flush''' option, so that when copying to usb sticks data flushes more often, thus making thunar's progress bar to stays up until things are on the disk.<br />
<br />
[vfat]<br />
flush=true<br />
<br />
====Removable Devices====<br />
<br />
If you want an icon appearing on your desktop and in thunar when you plug in external devices, make sure gvfs is installed:<br />
<br />
# pacman -S --needed gvfs<br />
<br />
You could also need to install gvfs-afc (read [https://bbs.archlinux.org/viewtopic.php?pid=889018 this discussion]):<br />
<br />
# pacman -S gvfs-afc<br />
<br />
It is also a good idea to install thunar-volman (included in the <tt>xfce4-goodies</tt> group):<br />
<br />
# pacman -S thunar-volman<br />
<br />
====Terminal tango color theme====<br />
Open with your favorite editor<br />
<br />
~/.config/Terminal/terminalrc<br />
<br />
And add(replace) this lines:<br />
<br />
ColorForeground=White<br />
ColorBackground=#323232323232<br />
ColorPalette1=#2e2e34343636<br />
ColorPalette2=#cccc00000000<br />
ColorPalette3=#4e4e9a9a0606<br />
ColorPalette4=#c4c4a0a00000<br />
ColorPalette5=#34346565a4a4<br />
ColorPalette6=#757550507b7b<br />
ColorPalette7=#060698989a9a<br />
ColorPalette8=#d3d3d7d7cfcf<br />
ColorPalette9=#555557575353<br />
ColorPalette10=#efef29292929<br />
ColorPalette11=#8a8ae2e23434<br />
ColorPalette12=#fcfce9e94f4f<br />
ColorPalette13=#72729f9fcfcf<br />
ColorPalette14=#adad7f7fa8a8<br />
ColorPalette15=#3434e2e2e2e2<br />
ColorPalette16=#eeeeeeeeecec<br />
<br />
== Troubleshooting ==<br />
=== Keyboard shortcuts aren't working ===<br />
Under Xfce 4.6 there is a problem where the user's [http://bugzilla.xfce.org/show_bug.cgi?id=5639 keyboard shortcuts will intermittently not work]. This is usually the case when the settings helper is either not running or has been started improperly due to a conflict. This bug has been fixed in Xfce 4.8, which replaced 4.6 in the main repositories.<br />
<br />
A workaround is to disable ''xfce4-settings-helper-autostart'' from autostarting in a user's session. The settings helper daemon will start upon loading an Xfce session, anyways. The following two steps seem to have resolved this issue.<br />
<br />
Remove or rename the global autostart .desktop file:<br />
mv /etc/xdg/autostart/xfce4-settings-helper-autostart.desktop /etc/xdg/autostart/xfce4-settings-helper-autostart.desktop.disabled<br />
<br />
Remove or rename the local autostart .desktop file:<br />
mv ~/.config/autostart/xfce4-settings-helper-autostart.desktop ~/.config/autostart/xfce4-settings-helper-autostart.desktop.disabled<br />
<br />
After logging out and logging back in, your shortcut keys should be working fine now.<br />
=== Thunar does not display any thumbnail ===<br />
<br />
Thunar relies on '''Tumbler''' to generate thumbnails. You can install Tumbler by issuing<br />
<br />
pacman -S tumbler<br />
<br />
More details in [[Thunar#Thunar_Thumbnailers|Thunar's page]].<br />
<br />
=== Restore default settings ===<br />
If for any reason you need to revert back to the default settings, try renaming ~/.config/xfce4-session/ and ~/.config/xfce4/<br />
<br />
$ mv ~/.config/xfce4-session/ ~/.config/xfce4-session-bak<br />
$ mv ~/.config/xfce4/ ~/.config/xfce4-bak<br />
<br />
Logout and login for changes to take effect.<br />
<br />
== Related Articles ==<br />
* [[Thunar]]<br />
* [[Build order for XFCE]]<br />
* [[Improve GTK Application Looks]]<br />
* [[Autostart applications#Graphical]]<br />
<br />
== External Resources ==<br />
* http://docs.xfce.org/ - The complete documentation.<br />
* [http://www.xfce-look.org/ Xfce-Look] - Themes, wallpapers, and more.<br />
* [http://xfce.wikia.com/wiki/Frequently_Asked_Questions Xfce Wikia] - How to edit the auto generated menu with the menu editor<br />
* [http://wiki.xfce.org Xfce Wiki]</div>Ekhttps://wiki.archlinux.org/index.php?title=Xfce&diff=148148Xfce2011-07-03T22:49:16Z<p>Ek: Pulseaudio configuration for xfce4</p>
<hr />
<div>[[Category:Desktop environments (English)]]<br />
{{i18n|Xfce}}<br />
[[pl:XFCE]]<br />
[[de:Xfce]]<br />
<br />
{{Article summary start}}<br />
{{Article summary text|Xfce is a lightweight desktop environment for Unix-like operating systems. It aims to be fast and lightweight, while still being visually appealing and user friendly. This article covers its installation, configuration, and troubleshooting.}}<br />
{{Article summary text|Xfce uses the [[GTK+]] toolkit.}}<br />
{{Article summary heading|Overview}}<br />
{{Article summary text|{{Graphical user interface overview}}}}<br />
{{Article summary end}}<br />
<br />
From [http://www.xfce.org/about/ Xfce - About]:<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 />
== What is Xfce? ==<br />
Xfce is a Desktop Environment, like GNOME or KDE. It contains a suite of apps like a root window app, window manager, file manager, panel, etc. Xfce is written using the GTK2 toolkit, and contains its own development environment (libraries, daemons, etc), similar to other big DEs.<br />
<br />
==Features==<br />
{{expansion}}<br />
*Lighter on resources than the other major DEs (KDE, GNOME).<br />
*Most settings are exposed via a GUI, Xfce doesn't try to hide stuff from the user.<br />
*Xfwm has an optional built-in compositor which allows for true transparency and all the benefits of GPU acceleration (minimizes tearing, etc.).<br />
*It works great with multiple monitors.<br />
*Xfce4 is stable, mature software.<br />
<br />
==Installation==<br />
Xfce is somewhat modular. That means there is no need for you to run every part, you can pick and choose some of them. Because of this, Xfce has some separate Arch packages.<br />
<br />
=====Installing Xfce=====<br />
To install the base Xfce system, run:<br />
<br />
# pacman -S xfce4<br />
<br />
Pacman will ask you to select the packages to install, you probably want to get them all by simply pressing enter.<br />
<br />
{{Note |Or you can install only a few needed '''core packages''':<br />
<br />
# pacman -S xfwm4 xfce4-panel xfdesktop thunar xfce4-session xfce4-settings xfce4-appfinder xfce-utils xfconf<br />
<br />
}}<br />
<br />
If you want extras, like panel plugins, run this:<br />
<br />
# pacman -S xfce4-goodies<br />
<br />
Like before, pacman will ask you which packages you want to install.<br />
<br />
If you wish to admire 'Tips and Tricks' on login, install the fortune-mod package:<br />
<br />
# pacman -S fortune-mod<br />
<br />
In order to get the xfce4-mixer to work with alsa, you need to install gstreamer0.10-base-plugins. (See below for help with OSS.)<br />
<br />
# pacman -S gstreamer0.10-base-plugins<br />
<br />
=====Installing and configuring the Daemons=====<br />
Install [[D-Bus]]:<br />
# pacman -S dbus<br />
<br />
{{Daemon|dbus}}<br />
<br />
Install [[Gamin]] (the successor of [[FAM]]). It is configured to automatically run in the background by default, do not add it to rc.conf.<br />
<br />
# pacman -S gamin<br />
<br />
== Running Xfce ==<br />
<br />
=====Automatically at boot time=====<br />
See [[Display Manager]] to install and configure a Display Manager. Be sure to configure it properly for [[PolicyKit]].<br />
<br />
=====Manually=====<br />
<br />
You can execute:<br />
$ startxfce4<br />
from the console, or configure [[xinitrc]] and use xinit or startx.<br />
<br />
If you have not created a ~/.xinitrc yet, do so with:<br />
<br />
$ cp /etc/skel/.xinitrc ~/.xinitrc<br />
<br />
and add the following line:<br />
<br />
exec ck-launch-session dbus-launch --exit-with-session startxfce4<br />
<br />
Example:<br />
#!/bin/sh<br />
#<br />
# ~/.xinitrc<br />
#<br />
# Executed by startx (run your window manager from here)<br />
<br />
# exec gnome-session<br />
# exec startkde<br />
# exec startxfce4<br />
# ...or the Window Manager of your choice<br />
exec ck-launch-session dbus-launch --exit-with-session startxfce4<br />
<br />
{{{Note|<code>dbus-launch</code> starts a dbus-daemon instance to provide communication with PolicyKit. <code>ck-launch-session</code> starts a clean consolekit session needed by Xfce for power management, automounting, shutting down/rebooting etc. ConsoleKit/PolicyKit capable display managers such as gdm do this for you automatically. Notice dbus-launch must be placed after ck-launch-session, or there will be problems when mounting disks.}}}<br />
<br />
=====Shutting down, rebooting, and automounting from within Xfce=====<br />
* Make sure that '''dbus''' is enabled in the DAEMONS array in /etc/rc.conf.<br />
* Make sure you are a member of the ''power'' group for shutting down and rebooting.<br />
* Make sure you are a member of the ''storage'' group for automounting.<br />
* Make sure that you are using <code>exec ck-launch-session dbus-launch --exit-with-session startxfce4</code> in ~/.xinitrc '''or''' a ConsoleKit/PolicyKit capable display manager, such as [[GDM]] or [[Slim|SLiM]]. (see above)<br />
<br />
== Tips ==<br />
=== Panel ===<br />
==== How to customize xfce panel background ====<br />
Edit ~/.gtkrc-2.0. <br />
Note that you must place the image in the same directory as the configuration, which is ~/. You can not specify the path to the image, or it won't work.<br />
style "panel-background" {<br />
bg_pixmap[NORMAL] = "foo.bar"<br />
bg_pixmap[PRELIGHT] = "foo.bar"<br />
bg_pixmap[ACTIVE] = "foo.bar"<br />
bg_pixmap[SELECTED] = "foo.bar"<br />
bg_pixmap[INSENSITIVE] = "foo.bar"<br />
}<br />
widget_class "*Panel*" style "panel-background"<br />
<br />
==== Replacements for the default 'menu' panel applet ====<br />
The "Ubuntu System Panel" (Gnome) panel applet has similar features to those found in its KDE v4.2 equivalent. It can be added to an Xfce panel via the 'XfApplet' panel applet, which allows Gnome applets to be used in Xfce.<br />
<br />
It is available in [http://aur.archlinux.org/packages.php?ID=10259 the AUR]<br />
<br />
==== How to remove menu entries from the System menu ==== <br />
===== Method 1 =====<br />
With the built-in menu editor, you cannot remove menu entries from the System menu. Here’s how to hide them:<br />
# Open Terminal (Xfce menu > System > Terminal) and go to the /usr/share/applications folder: <pre>$ cd /usr/share/applications</pre><br />
# This folder should be full of .desktop files. To see a list type: <pre>$ ls</pre><br />
# Add ''NoDisplay=true'' to the .desktop file. For example, if you want to hide Firefox, type in the terminal:<pre>$ sudo echo "NoDisplay=true" >> firefox.desktop</pre> This command appends the text ''NoDisplay=true'' to the end of the .desktop file and saves the file<br />
<br />
===== Method 2 =====<br />
Another method is to copy the entire contents of the global applications directory over to your local applications directory, and then proceed to modify and/or disable unwanted .desktop entries. This will survive application updates that overwrite changes under /usr/share/applications/.<br />
# In a terminal, copy everything from /usr/share/applications to ~/.local/share/applications/: <pre>$ cp /usr/share/applications/* ~/.local/share/applications/</pre><br />
# For any entry you wish to hide from the menu, add the NoDisplay=true option: <pre>$ echo "NoDisplay=true" >> ~/.local/share/applications/foo.desktop</pre><br />
<br />
You can also edit the application's category by editing the .desktop file with a text editor and modifying the Categories= line.<br />
<br />
==== But what do you do with menu entries which do not show up in /usr/share/applications (e.g., apps installed via wine)? ==== <br />
I've found some shortcuts that show in the category “Other” in this directory:<br />
~/.local/share/applications/wine/.<br />
<br />
=== Desktop ===<br />
==== Why doesn't my desktop refresh? ====<br />
Xfce 4.6 uses [[FAM]] (File Alteration Monitor) or [[gamin]] (FAM's successor) to get notification when a file or directory changes.<br />
If you decide to use FAM, don't forget to add 'fam' to the list of DAEMONS in /etc/rc.conf.<br />
This step is not necessary for gamin.<br />
<br />
NOTE: After recent updates, FAM may have issues opening some mounts, such as sshfs. Use gamin if this is the case.<br />
<br />
==== Use a transparent background for desktop icon titles ====<br />
To change the default white background of desktop icon titles to something more suitable, edit the .gtkrc-2.0 file in your home directory (or create the file if needed) and add the following:<br />
style "xfdesktop-icon-view" {<br />
XfdesktopIconView::label-alpha = 10<br />
base[NORMAL] = "#000000"<br />
base[SELECTED] = "#71B9FF"<br />
base[ACTIVE] = "#71FFAD"<br />
fg[NORMAL] = "#ffffff"<br />
fg[SELECTED] = "#71B9FF"<br />
fg[ACTIVE] = "#71FFAD" }<br />
widget_class "*XfdesktopIconView*" style "xfdesktop-icon-view"<br />
<br />
==== Hide selected partitions on the desktop ====<br />
If you wish to prevent certain partitions or drives appearing on the desktop, you can create a udev rule, for example {{filename|/etc/udev/rules.d/10-local.rules}}:<br />
<br />
KERNEL=="sda1", ENV{UDISKS_PRESENTATION_HIDE}="1"<br />
KERNEL=="sda2", ENV{UDISKS_PRESENTATION_HIDE}="1"<br />
<br />
Would show all partitions with the exception of sda1 and sda2 on your desktop.<br />
<br />
==== Switch to old desktop right click menu without Thunar things ====<br />
xfconf-query -c xfce4-desktop -v --create -p /desktop-icons/style -t int -s 0<br />
<br />
=== XFWM4 ===<br />
==== How to enable the compositor in Xfce 4.6 ====<br />
Xfce 4.6 comes with a builtin compositor adding the option for fancy window effects, shadows and transparency and so on. It can be enabled in the Window Manager Tweaks and works on the fly. No additional settings are needed in your /etc/xorg.conf. To enable and adjust settings, go to:<br />
<br />
Menu --> Settings --> Window Manager Tweaks<br />
<br />
==== Disable window roll-up ====<br />
xfconf-query -c xfwm4 -p /general/mousewheel_rollup -s false<br />
<br />
=== Commands for the settings manager ===<br />
<br />
There is no official documentation for the commands executed. One must look at .desktop files ''/usr/share/applications/'' folder. For the people who like to know exactly what is happening, here is a handy list to save the effort:<br />
<br />
xfce-setting-show backdrop<br />
xfce-setting-show display<br />
xfce-setting-show keyboard<br />
xfce4-menueditor<br />
xfce-setting-show sound<br />
xfce-setting-show mouse<br />
xfce-setting-show session<br />
xfce-setting-show<br />
xfce-setting-show splash<br />
xfce-setting-show ui<br />
xfce-setting-show xfwm4<br />
xfce-setting-show wmtweaks<br />
xfce-setting-show workspaces<br />
xfce-setting-show printing_system<br />
xfce4-appfinder<br />
xfce4-autostart-editor<br />
xfce4-panel -c<br />
<br />
To review all the available setting manager commands run the following in a terminal:<br />
<br />
$ grep xfce-setting-show /usr/share/applications/xfce*settings*<br />
<br />
=== Session ===<br />
==== Customizing Startup Applications ====<br />
<br />
This includes getting necessary environment variables into the GUI runtime.<br />
<br />
* Copy the file /etc/xdg/xfce4/xinitrc to ~/.config/xfce4/<br />
* Edit this file. For example, you can add something like this somehwere in the middle:<br />
source $HOME/.bashrc<br />
# start rxvt-unicode server<br />
urxvtd -q -o -f<br />
<br />
==== Switch between users ====<br />
<br />
It is possible to switch between X sessions thanks to [http://goodies.xfce.org/projects/panel-plugins/xfswitch-plugin xfswitch-plugin ]. It adds an icon to the Xfce panel, and requires gdm to work at the moment.<br />
<br />
xfswitch-plugin is available through [http://aur.archlinux.org/packages.php?ID=40677 AUR ]<br />
<br />
==== Modify XML settings files directly ====<br />
It may be useful, especially when upgrading, to manually edit .xml files in the ~/.config/xfce4/xfconf/ folder. For application keyboard shortcuts for example, the file is ~/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml. It's faster to copy and paste the XML keys that you want rather than using the GUI.<br />
<br />
<br />
=== How to add themes to XFCE === <br />
<br />
1. Go to [http://xfce-look.org xfce-look.org] and click "Themes" in the left navbar. Look around for a theme you want and click "Download".<br />
<br />
2. Go to the directory where you downloaded the tarball/file and extract it using Squeeze/Xarchiver/CLI.<br />
<br />
3. Move the extracted folder to /usr/share/themes (for all users) or ~/.themes (for just you). Inside /usr/share/themes/abc, there is a folder that you create called xfwm4 that will contain whatever files that is included with that theme.<br />
<br />
4. GTK theme is available here:<br />
Menu --> Settings --> Appearance<br />
You select your xfwm theme in:<br />
Menu --> Settings --> Window Manager<br />
<br />
=== Cursors ===<br />
<br />
By default, X uses a plain black cursor. If you have alternative X cursor themes installed, Xfce can find them with:<br />
Menu --> Settings --> Mouse --> Theme<br />
<br />
To install new cursor themes, install {{Package Official|xcursor-themes}} or another {{Package Official|xcursor}} package, or see [[X11 Cursors]].<br />
<br />
=== Fonts ===<br />
<br />
If you find the standard fonts rather thick and or slightly out of focus open Settings>Appearence click on the Fonts tab and under Hinting: change to Full<br />
<br />
You could also try using a custom DPI setting.<br />
<br />
=== Sound ===<br />
<br />
=== Pulseaudio ===<br />
<br />
Sync-update the complete gstreamer group since xfce4 uses gstreamer as sound backend. The xfce mixer applet will be able to control volume (after setting device and master control).<br />
<br />
pacman -Syu gstreamer0.10-plugins<br />
<br />
==== How do I get xfce4-mixer and OSS4 to work together? ====<br />
<br />
Xfce 4.6 uses gstreamer as the backend to control volume, so first you have to make gstreamer cooperate with xfce4-mixer.<br />
<br />
pacman -S xfce4-mixer gstreamer0.10-base-plugins<br />
<br />
(Optional) Second, try to install gstreamer0.10-good-plugins, gstreamer0.10-bad-plugins<br />
<br />
pacman -S gstreamer0.10-good-plugins gstreamer0.10-bad-plugins<br />
<br />
login and logout, or just remove the mixer plugin and add it again. If it doesn't work at all, then you have to compile gstreamer0.10-good-plugins yourself. and can <br />
<br />
Download the PKGBUILD and other files needed from ABS or [http://projects.archlinux.org/svntogit/packages.git/tree/gstreamer0.10-good/repos here], edit the PKGBUILD, add --enable-oss. <br />
<br />
./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var \<br />
'''--enable-oss \'''<br />
--disable-static --enable-experimental \<br />
--disable-schemas-install \<br />
--disable-hal \<br />
--with-package-name="GStreamer Good Plugins (Archlinux)" \<br />
--with-package-origin="http://www.archlinux.org/"<br />
<br />
and then run makepkg -i. <br />
<br />
makepkg -i<br />
<br />
Still not working? Try tis package in AUR [http://aur.archlinux.org/packages.php?ID=17024 gstreamer0.10-good-plugins-ossv4], modify the pkgver to the newest in the PKGBUILD, and it should work.<br />
<br />
Other LINKS: [http://www.4front-tech.com/forum/ OSS forum]<br />
<br />
==== Change volume with keyboard volume buttons ====<br />
<br />
Go to <br />
Settings --> Keyboard<br />
Click the "Application Shortcuts" tab and add click the "Add" button. Add the following by entering the command, then pressing the corresponding button at the next window:<br />
<br />
===== ALSA =====<br />
For the raise volume button:<br />
amixer set Master 5%+<br />
For the lower volume button:<br />
amixer set Master 5%-<br />
For the mute button:<br />
amixer set Master toggle<br />
<br />
You can also run these commands to set the above commands to the standard XF86Audio keys:<br />
xfconf-query -c xfce4-keyboard-shortcuts -p /commands/custom/XF86AudioRaiseVolume -n -t string -s "amixer set Master 5%+"<br />
xfconf-query -c xfce4-keyboard-shortcuts -p /commands/custom/XF86AudioLowerVolume -n -t string -s "amixer set Master 5%-"<br />
xfconf-query -c xfce4-keyboard-shortcuts -p /commands/custom/XF86AudioMute -n -t string -s "amixer set Master toggle"<br />
<br />
If {{codeline|amixer set Master toggle}} does not work, try the PCM channel ({{codeline|amixer set PCM toggle}}) instead.<br />
<br />
The channel must have a "mute" option for the toggle command to work. To check whether or not your Master channel supports toggling mute, run {{codeline|alsamixer}} in a terminal and look for the double M's (MM) under the Master channel. If they are not present, then it does not support the mute option. If, for example, you had to change the toggle button to use the PCM channel, make sure to also set the PCM channel as the Mixer Track under Xfce Mixer properties.<br />
<br />
===== OSS =====<br />
Use one of these scripts:<br />
[http://www.opensound.com/wiki/index.php/Tips_And_Tricks#Using_multimedia_keys_with_OSS<br />
]<br />
<br />
If using ossvol (recommended), add:<br />
ossvol -i 1<br />
for the volume up button<br />
ossvol -d 1<br />
for the volume down button<br />
ossvol -t<br />
for the mute/unmute button<br />
<br />
=== Screenshots ===<br />
<br />
==== Using print-screen key ====<br />
<br />
A simple way is to use a command-line screenshot utility:<br />
<br />
# pacman -S scrot<br />
<br />
Then<br />
<br />
XFCE Menu --> Settings --> Keyboard >>> Application Shortcuts.<br />
<br />
Add the "scrot" command to use the "PrintScreen" key.<br />
<br />
All screenshots will be placed in your home folder with unique names like<br />
<br />
"2009-02-19-063052_1280x1024_scrot.png".<br />
<br />
====Screenshooter====<br />
<br />
There is also an a screenshot plugin for the Xfce panel, which can be used instead of scrot, that is available in extra:<br />
<br />
# pacman -S xfce4-screenshooter<br />
<br />
You can add a keyboard binding for it using the command<br />
<br />
xfce4-screenshooter -f<br />
<br />
instead of "scrot". You'll get a dialog window after pressing "Print" where you can copy the image to the clipboard or save it.<br />
<br />
=== Change mount options ===<br />
<br />
A common problem when automounting USB sticks formatted with fat filesystem is the inability to properly show characters as umlauts, ñ, ß, etc. This may be solved changing the default iocharset to utf8, which is easily done adding a line to '''/etc/xdg/xfce4/mount.rc''':<br />
<br />
[vfat]<br />
uid=<auto><br />
shortname=winnt<br />
'''utf8=true'''<br />
# FreeBSD specific option<br />
longnames=true<br />
<br />
Note that when using utf-8, the system will distinct between upper- and lowercases, potentially corrupting your files. Be careful.<br />
<br />
It is also recommendable to mount vfat devices with the '''flush''' option, so that when copying to usb sticks data flushes more often, thus making thunar's progress bar to stays up until things are on the disk.<br />
<br />
[vfat]<br />
flush=true<br />
<br />
====Removable Devices====<br />
<br />
If you want an icon appearing on your desktop and in thunar when you plug in external devices, make sure gvfs is installed:<br />
<br />
# pacman -S --needed gvfs<br />
<br />
You could also need to install gvfs-afc (read [https://bbs.archlinux.org/viewtopic.php?pid=889018 this discussion]):<br />
<br />
# pacman -S gvfs-afc<br />
<br />
It is also a good idea to install thunar-volman (included in the <tt>xfce4-goodies</tt> group):<br />
<br />
# pacman -S thunar-volman<br />
<br />
====Terminal tango color theme====<br />
Open with your favorite editor<br />
<br />
~/.config/Terminal/terminalrc<br />
<br />
And add(replace) this lines:<br />
<br />
ColorForeground=White<br />
ColorBackground=#323232323232<br />
ColorPalette1=#2e2e34343636<br />
ColorPalette2=#cccc00000000<br />
ColorPalette3=#4e4e9a9a0606<br />
ColorPalette4=#c4c4a0a00000<br />
ColorPalette5=#34346565a4a4<br />
ColorPalette6=#757550507b7b<br />
ColorPalette7=#060698989a9a<br />
ColorPalette8=#d3d3d7d7cfcf<br />
ColorPalette9=#555557575353<br />
ColorPalette10=#efef29292929<br />
ColorPalette11=#8a8ae2e23434<br />
ColorPalette12=#fcfce9e94f4f<br />
ColorPalette13=#72729f9fcfcf<br />
ColorPalette14=#adad7f7fa8a8<br />
ColorPalette15=#3434e2e2e2e2<br />
ColorPalette16=#eeeeeeeeecec<br />
<br />
== Troubleshooting ==<br />
=== Keyboard shortcuts aren't working ===<br />
Under Xfce 4.6 there is a problem where the user's [http://bugzilla.xfce.org/show_bug.cgi?id=5639 keyboard shortcuts will intermittently not work]. This is usually the case when the settings helper is either not running or has been started improperly due to a conflict. This bug has been fixed in Xfce 4.8, which replaced 4.6 in the main repositories.<br />
<br />
A workaround is to disable ''xfce4-settings-helper-autostart'' from autostarting in a user's session. The settings helper daemon will start upon loading an Xfce session, anyways. The following two steps seem to have resolved this issue.<br />
<br />
Remove or rename the global autostart .desktop file:<br />
mv /etc/xdg/autostart/xfce4-settings-helper-autostart.desktop /etc/xdg/autostart/xfce4-settings-helper-autostart.desktop.disabled<br />
<br />
Remove or rename the local autostart .desktop file:<br />
mv ~/.config/autostart/xfce4-settings-helper-autostart.desktop ~/.config/autostart/xfce4-settings-helper-autostart.desktop.disabled<br />
<br />
After logging out and logging back in, your shortcut keys should be working fine now.<br />
=== Thunar does not display any thumbnail ===<br />
<br />
Thunar relies on '''Tumbler''' to generate thumbnails. You can install Tumbler by issuing<br />
<br />
pacman -S tumbler<br />
<br />
More details in [[Thunar#Thunar_Thumbnailers|Thunar's page]].<br />
<br />
=== Restore default settings ===<br />
If for any reason you need to revert back to the default settings, try renaming ~/.config/xfce4-session/ and ~/.config/xfce4/<br />
<br />
$ mv ~/.config/xfce4-session/ ~/.config/xfce4-session-bak<br />
$ mv ~/.config/xfce4/ ~/.config/xfce4-bak<br />
<br />
Logout and login for changes to take effect.<br />
<br />
== Related Articles ==<br />
* [[Thunar]]<br />
* [[Build order for XFCE]]<br />
* [[Improve GTK Application Looks]]<br />
* [[Autostart applications#Graphical]]<br />
<br />
== External Resources ==<br />
* http://docs.xfce.org/ - The complete documentation.<br />
* [http://www.xfce-look.org/ Xfce-Look] - Themes, wallpapers, and more.<br />
* [http://xfce.wikia.com/wiki/Frequently_Asked_Questions Xfce Wikia] - How to edit the auto generated menu with the menu editor<br />
* [http://wiki.xfce.org Xfce Wiki]</div>Ekhttps://wiki.archlinux.org/index.php?title=User:Ek&diff=146516User:Ek2011-06-17T15:05:43Z<p>Ek: </p>
<hr />
<div>- Thinkpad Edge 13<br />
<br />
- Acer Aspire 1410<br />
<br />
- Desktop with an AMD HD 4850 using xorg-video-ati.<br />
<br />
Trying to keep wiki pages about said things more or less up-to-date.<br />
<br />
TODO: 2.6.39 doenst require rtl8192ce package from aur on thinkpad egde 13 amd any longer.</div>Ekhttps://wiki.archlinux.org/index.php?title=Lenovo_ThinkPad_Edge_13&diff=142758Lenovo ThinkPad Edge 132011-05-25T10:21:35Z<p>Ek: Newer models dont require hacks. Thinkpad fan-control.</p>
<hr />
<div>[[Category:Lenovo (English)]]<br />
{{Note|This article will be updated from time to time and is currently (as of 2010/09/5) processed by [[User:ProfWho]]}}<br />
{{Article summary start}}<br />
{{Article summary text|How to setup archlinux on Lenovo ThinkPad Edge 13}}<br />
{{Article summary heading|Required hardware}}<br />
{{Article summary text|Thinkpad Edge 13 (Lenovo) - This guide has been written aside the ThinkPad Edge AMD version with ATI-graphics.}}<br />
{{Article summary heading|Related}}<br />
{{Article summary wiki|http://wiki.archlinux.org/index.php/Lenovo_Thinkpad_T61 }}<br />
{{Article summary end}}<br />
<br />
This article was written to assist you with getting archlinux run on the Lenovo ThinkPad Edge 13. It is meant to be help you with some tricky points aside to the [[Beginners' Guide]]: A guide through the whole process of installing and configuring Arch Linux; written for new or inexperienced users.<br />
<br />
== Prerequisits ==<br />
<br />
First and important to do is an BIOS-Update (As of 2010/08/20 to Version 1.19.)<br />
<br />
This was done, by using grub4dos, one can get [http://grub4dos.sourceforge.net/wiki/ here]. Because a simple dd didn't create a bootable USB-Stick for me.<br />
<br />
=== BIOS-Update: ===<br />
<br />
Download [http://download.gna.org/grub4dos/ grub4dos].<br />
<br />
Unpack it on another *nix-box and run:<br />
<br />
sudo ./bootlace.com /dev/sdX<br />
<br />
with /dev/sdX being your USB-Stick (as the Thinkpad Edge 13 has no CDROM-Drive) in the directory, where you unpacked your files.<br />
<br />
Afterwards copy grldr and menu.lst to the device:<br />
<br />
cp grldr /media/USBSTICK<br />
cp menu.lst /media/USBSTICK<br />
<br />
Download the BIOS update from the BIOS section on [http://www-307.ibm.com/pc/support/site.wss/MIGR-74581.html this support site]. Pick the one that matches your current BIOS Id. Copy the iso-file to the / directory of the USB-Stick!<br />
<br />
Finally you have to add the following code to the menu.lst on your pendrive to make the USB-Stick boot the PC DOS program made by lenovo:<br />
<br />
title Thinkpad-Edge-BIOS-UPDATE<br />
find --set-root /6yuj06uc.iso<br />
map /6yuj06uc.iso (0xff) || map --mem /6yuj06uc.iso (0xff)<br />
map --hook<br />
chainloader (0xff)<br />
boot<br />
<br />
Inserting such a prepared USB-Stick into your Thinkpad Edge, and things should be self-explanatory after that.<br />
<br />
=== Creating an installation medium ===<br />
<br />
To create a bootable USB-Stick with the archlinux*.iso you downloaded, simply:<br />
<br />
dd bs=8M if=archlinux*.iso of=/dev/sdX<br />
<br />
which will/should behave like a regular bootable CD-Rom in addition to a capable BIOS and the <u>correct bootsequence</u>! In doubt or in case of problems see [[Install_from_a_USB_flash_drive|Install from a USB flash drive]] for more detailed instructions.<br />
<br />
== Installation ==<br />
<br />
After that it is recommended to follow the usual installation procedure described in the [[Beginners' Guide]] up to the part 2, as the installation of the wireless lan card needs some further work. <br />
<br />
=== WLAN driver installation ===<br />
<br />
The WLAN-driver doesn't come with the current repos and was uploaded to the [[AUR]]: The package can be found [http://aur.archlinux.org/packages.php?ID=34281 here].<br />
<br />
As you probably are a archlinux newbie, the AUR - or Archlinux User Repository is a <i>community</i> repository, which lives quite dynamical and changes shapes quite fast, where friendly members upload there compilation and installation package prepared code.<br />
<br />
To get it running:<br />
<br />
* Unpack your downloaded package<br />
<br />
* As a 'normal' user run<br />
<br />
makepkg -s<br />
<br />
in the unpacked directory and <br />
<br />
* then install it:<br />
<br />
sudo pacman -U PACKAGENAME <br />
<br />
Maybe a<br />
<br />
depmod -a<br />
<br />
might be necessary, however the module should be loaded after that.<br />
<br />
===== Installation via yaourt =====<br />
<br />
If you already have [[yaourt]] installed then instead of manually downloading, unpacking and compiling the package, you can simply do:<br />
<br />
yaourt -S rtl8192se<br />
<br />
or<br />
<br />
yaourt -S dkms-rtl8192se<br />
<br />
The dkms-rtl8192se package is different from rtl8192se in that you will not need to manually recompile the driver after a major kernel upgrade. Apparently minor releases do not require recompilation of the driver.<br />
<br />
=== Audio ===<br />
<br />
To get jack sensing to work add:<br />
<br />
options snd-hda-intel model="olpc-xo-1_5"<br />
<br />
to /etc/modprobe.d/modprobe.conf.<br />
<br />
=== Video ===<br />
<br />
If you have the AMD-AMD model you can use the free ati drivers. <br />
<br />
pacman -S xorg-server xf86-video-ati<br />
<br />
These drivers give enough horsepower for compiz and video playback.<br />
<br />
=== Touchpad ===<br />
<br />
A synaptics touchpad with two-finger scrolling.<br />
<br />
pacman -S xf86-input-synaptics<br />
<br />
=== Frequency scaling ===<br />
<br />
The Turion work well with powernow-k8. Please refer to the wiki for more information on cpufrequtils.<br />
Dont forget to add powernow-k8 to your modules array.<br />
<br />
=== Fan control ===<br />
<br />
Add the follwing line to your /etc/modprobe.d/modprobe.conf<br />
<br />
options thinkpad_acpi fan_control=1<br />
<br />
Then you can manually set your fanspeed with:<br />
<br />
echo level 7 > /proc/acpi/ibm/fan<br />
cat /proc/acpi/ibm/fan # for more commands.<br />
# Other files will report their status and commands when read too.<br />
<br />
=== Webcam ===<br />
<br />
Works out of the box. Test with<br />
<br />
mplayer tv:// -tv driver=v4l2<br />
<br />
If you use skype and the video is way to dark, skype forgot to enable automatic exposure control. Install v4l2 control and set it yourself. You need to to do it everytime you use skype.<br />
<br />
pacman -S v4l2-utils<br />
v4l2-utils -c exposure_auto_priority 1<br />
<br />
Your video should gradually begin to brighten up. More options:<br />
<br />
v4l2-utils -l<br />
<br />
=== Suspend ===<br />
<br />
First, you might need to add the following to your kernel commandline if suspend does not work. Newer models don't require the following hacks, so make sure that neither suspend nor wifi works.<br />
<br />
kernel root= ... acpi_osi=linux noapic<br />
<br />
Second, your wifi card will delay resume by roughly 2 minutes. That means that your laptop is not frozen but still resuming. Wifi wont want to work, too. This can be worked around by removing the wifi modules before suspend. You can do this automatically if you use pm-utils. Please refer for more information to the pm-utils wiki article. Below follows my /etc/pm/sleep.d/100wifiworkaround.sh script for automation<br />
<br />
#!/bin/bash<br />
#<br />
case $1 in<br />
hibernate)<br />
ifconfig wlan0 down<br />
rmmod rtl8192ce<br />
rmmod r8169<br />
;;<br />
thaw)<br />
modprobe rtl8192ce # Pulls r8169 in<br />
;;<br />
sleep)<br />
ifconfig wlan0 down<br />
rmmod rtl8192ce<br />
rmmod r8169<br />
;;<br />
resume)<br />
modprobe rtl8192ce<br />
;;<br />
*)<br />
echo "I dont do that. Read me first please."<br />
;;<br />
esac</div>Ekhttps://wiki.archlinux.org/index.php?title=User:Ek&diff=140409User:Ek2011-05-08T13:02:49Z<p>Ek: My User page.</p>
<hr />
<div>- Thinkpad Edge 13<br />
<br />
- Acer Aspire 1410<br />
<br />
- Desktop with an AMD HD 4850 using xorg-video-ati.<br />
<br />
Trying to keep wiki pages about said things more or less up-to-date.</div>Ekhttps://wiki.archlinux.org/index.php?title=Talk:Lenovo_ThinkPad_Edge_13&diff=140189Talk:Lenovo ThinkPad Edge 132011-05-06T20:20:13Z<p>Ek: </p>
<hr />
<div><u>2DO:</u><br />
<br />
* ATI problems<br />
* powernow-k8<br />
* saving more energy<br />
<br />
Thanks to pnutzh4x0r, for the work he wrote down somehwere at notebookreview.com! <br />
<br />
[[User:ProfWho|ProfWho]] 09:54, 23 August 2010 (EDT)<br />
<br />
It worked, thanks!<br />
--[[User:Tbaumann|Tbaumann]] 17:47, 15 March 2011 (EDT)<br />
<br />
Is it really necessary to have walk through for rtl8192 installation? It is just installing a package from AUR. Linking to the wiki page about AUR is IMHO more appropriate, since it contains more information how to deal with packages from AUR.<br />
--[[User:Ek|Ek]] 16:20, 6 May 2011 (EDT)</div>Ekhttps://wiki.archlinux.org/index.php?title=Lenovo_ThinkPad_Edge_13&diff=140188Lenovo ThinkPad Edge 132011-05-06T20:14:27Z<p>Ek: Article clean-up. A general summary of experiences and work arounds. More to come.</p>
<hr />
<div>[[Category:Lenovo (English)]]<br />
{{Note|This article will be updated from time to time and is currently (as of 2010/09/5) processed by [[User:ProfWho]]}}<br />
{{Article summary start}}<br />
{{Article summary text|How to setup archlinux on Lenovo ThinkPad Edge 13}}<br />
{{Article summary heading|Required hardware}}<br />
{{Article summary text|Thinkpad Edge 13 (Lenovo) - This guide has been written aside the ThinkPad Edge AMD version with ATI-graphics.}}<br />
{{Article summary heading|Related}}<br />
{{Article summary wiki|http://wiki.archlinux.org/index.php/Lenovo_Thinkpad_T61 }}<br />
{{Article summary end}}<br />
<br />
This article was written to assist you with getting archlinux run on the Lenovo ThinkPad Edge 13. It is meant to be help you with some tricky points aside to the [[Beginners' Guide]]: A guide through the whole process of installing and configuring Arch Linux; written for new or inexperienced users.<br />
<br />
== Prerequisits ==<br />
<br />
First and important to do is an BIOS-Update (As of 2010/08/20 to Version 1.19.)<br />
<br />
This was done, by using grub4dos, one can get [http://grub4dos.sourceforge.net/wiki/ here]. Because a simple dd didn't create a bootable USB-Stick for me.<br />
<br />
=== BIOS-Update: ===<br />
<br />
Download [http://download.gna.org/grub4dos/ grub4dos].<br />
<br />
Unpack it on another *nix-box and run:<br />
<br />
sudo ./bootlace.com /dev/sdX<br />
<br />
with /dev/sdX being your USB-Stick (as the Thinkpad Edge 13 has no CDROM-Drive) in the directory, where you unpacked your files.<br />
<br />
Afterwards copy grldr and menu.lst to the device:<br />
<br />
cp grldr /media/USBSTICK<br />
cp menu.lst /media/USBSTICK<br />
<br />
Download the BIOS update from the BIOS section on [http://www-307.ibm.com/pc/support/site.wss/MIGR-74581.html this support site]. Pick the one that matches your current BIOS Id. Copy the iso-file to the / directory of the USB-Stick!<br />
<br />
Finally you have to add the following code to the menu.lst on your pendrive to make the USB-Stick boot the PC DOS program made by lenovo:<br />
<br />
title Thinkpad-Edge-BIOS-UPDATE<br />
find --set-root /6yuj06uc.iso<br />
map /6yuj06uc.iso (0xff) || map --mem /6yuj06uc.iso (0xff)<br />
map --hook<br />
chainloader (0xff)<br />
boot<br />
<br />
Inserting such a prepared USB-Stick into your Thinkpad Edge, and things should be self-explanatory after that.<br />
<br />
=== Creating an installation medium ===<br />
<br />
To create a bootable USB-Stick with the archlinux*.iso you downloaded, simply:<br />
<br />
dd bs=8M if=archlinux*.iso of=/dev/sdX<br />
<br />
which will/should behave like a regular bootable CD-Rom in addition to a capable BIOS and the <u>correct bootsequence</u>! In doubt or in case of problems see [[Install_from_a_USB_flash_drive|Install from a USB flash drive]] for more detailed instructions.<br />
<br />
== Installation ==<br />
<br />
After that it is recommended to follow the usual installation procedure described in the [[Beginners' Guide]] up to the part 2, as the installation of the wireless lan card needs some further work. <br />
<br />
=== WLAN driver installation ===<br />
<br />
The WLAN-driver doesn't come with the current repos and was uploaded to the [[AUR]]: The package can be found [http://aur.archlinux.org/packages.php?ID=34281 here].<br />
<br />
As you probably are a archlinux newbie, the AUR - or Archlinux User Repository is a <i>community</i> repository, which lives quite dynamical and changes shapes quite fast, where friendly members upload there compilation and installation package prepared code.<br />
<br />
To get it running:<br />
<br />
* Unpack your downloaded package<br />
<br />
* As a 'normal' user run<br />
<br />
makepkg -s<br />
<br />
in the unpacked directory and <br />
<br />
* then install it:<br />
<br />
sudo pacman -U PACKAGENAME <br />
<br />
Maybe a<br />
<br />
depmod -a<br />
<br />
might be necessary, however the module should be loaded after that.<br />
<br />
===== Installation via yaourt =====<br />
<br />
If you already have [[yaourt]] installed then instead of manually downloading, unpacking and compiling the package, you can simply do:<br />
<br />
yaourt -S rtl8192se<br />
<br />
or<br />
<br />
yaourt -S dkms-rtl8192se<br />
<br />
The dkms-rtl8192se package is different from rtl8192se in that you will not need to manually recompile the driver after a major kernel upgrade. Apparently minor releases do not require recompilation of the driver.<br />
<br />
=== Audio ===<br />
<br />
To get jack sensing to work add:<br />
<br />
options snd-hda-intel model="olpc-xo-1_5"<br />
<br />
to /etc/modprobe.d/modprobe.conf.<br />
<br />
=== Video ===<br />
<br />
If you have the AMD-AMD model you can use the free ati drivers. <br />
<br />
pacman -S xorg-server xf86-video-ati<br />
<br />
These drivers give enough horsepower for compiz and video playback.<br />
<br />
=== Touchpad ===<br />
<br />
A synaptics touchpad with two-finger scrolling.<br />
<br />
pacman -S xf86-input-synaptics<br />
<br />
=== Frequency scaling ===<br />
<br />
The Turion work well with powernow-k8. Please refer to the wiki for more information on cpufrequtils.<br />
Dont forget to add powernow-k8 to your modules array.<br />
<br />
=== Webcam ===<br />
<br />
Works out of the box. Test with<br />
<br />
mplayer tv:// -tv driver=v4l2<br />
<br />
If you use skype and the video is way to dark, skype forgot to enable automatic exposure control. Install v4l2 control and set it yourself. You need to to do it everytime you use skype.<br />
<br />
pacman -S v4l2-utils<br />
v4l2-utils -c exposure_auto_priority 1<br />
<br />
Your video should gradually begin to brighten up. More options:<br />
<br />
v4l2-utils -l<br />
<br />
=== Suspend ===<br />
<br />
First, you might need to add the following to your kernel commandline if suspend does not work.<br />
<br />
kernel root= ... acpi_osi=linux noapic<br />
<br />
Second, your wifi card will delay resume by roughly 2 minutes. That means that your laptop is not frozen but still resuming. Wifi wont want to work, too. This can be worked around by removing the wifi modules before suspend. You can do this automatically if you use pm-utils. Please refer for more information to the pm-utils wiki article. Below follows my /etc/pm/sleep.d/100wifiworkaround.sh script for automation<br />
<br />
#!/bin/bash<br />
#<br />
case $1 in<br />
hibernate)<br />
ifconfig wlan0 down<br />
rmmod rtl8192ce<br />
rmmod r8169<br />
;;<br />
thaw)<br />
modprobe rtl8192ce # Pulls r8169 in<br />
;;<br />
sleep)<br />
ifconfig wlan0 down<br />
rmmod rtl8192ce<br />
rmmod r8169<br />
;;<br />
resume)<br />
modprobe rtl8192ce<br />
;;<br />
*)<br />
echo "I dont do that. Read me first please."<br />
;;<br />
esac</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=140185Acer Aspire 14102011-05-06T19:52:07Z<p>Ek: Some experience with buggy kernels.</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
This laptop is almost perfect for Linux. It has Intel chipset on motherboard (includes OpenGL 2.0-compatible video) and well-known Atheros network devices (on some models). Even special keyboard and suspend work fine. <br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Driver/Status<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Install xf86-video-intel<br />
|-<br />
| Wireless<br />
| ['''8804'''] Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br><br />
or Atheros AR9285 Wireless Network Adapter<br />
| Install iwlwifi-5000-ucode<br><br />
Out-of-box (kernel module ath9k)<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
or Atheros Communications Device 1063<br />
| Works out-of-box<br />
|-<br />
| Audio<br />
| Built-in speakers<br><br />
Headphone Jack<br><br />
Integrated Microphone<br><br />
Microphone Jack<br />
| Works<br><br />
Works<br><br />
Untested<br><br />
Untested<br><br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader:<br />
MultiMediaCard™<br><br />
Secure Digital<br><br />
Memory Stick®<br><br />
Memory Stick PRO™<br><br />
xD-Picture Card™<br />
|<br />
Untested<br><br />
Works<br><br />
Untested<br><br />
Works<br><br />
Works<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works out-of-box<br />
|-<br />
| Touchpad<br />
| <br />
| Install xf86-input-evdev, xf86-input-synaptics<br />
|-<br />
| HDMI Out<br />
| <br />
| Works OOTB<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
<br />
If you are receiving errors booting or during the install, try setting the SATA mode to "IDE" in the BIOS. This is not necessary for all users.<br />
<br />
=== During the Installation ===<br />
Be sure to install the necessary wireless driver (see above), "wireless_tools", and optionally "netcfg" if you would like wireless to work post-install. <br />
<br />
Note for beginners: connect to wifi-router directly by ethernet cable, or completely switch-off authentication. After that install Arch from network mirrors, reload and install network-manager with your preferred Desktop Environment.<br />
<br />
=== Post-Install ===<br />
<br />
==== Kernel Issues ====<br />
<br />
Kernel 2.6.36 and 2.6.37 often freeze the system. Make sure to upgrade to newest kernel. This also fixes issues with the touchpad.<br />
<br />
==== Setup the Touchpad ====<br />
<br />
Make sure to install xf86-input-synaptics. Don't forget to enable the touchpad with <Fn>-F7. The following threads might also be interesting: [http://bbs.archlinux.org/viewtopic.php?id=77400] [http://bbs.archlinux.org/viewtopic.php?id=77190]<br />
<br />
Kernel 2.6.36 has an annoying bug makeing the touchpad finicky. A temporary workaround [https://bbs.archlinux.org/viewtopic.php?pid=871240] is:<br />
<br />
xinput --set-prop "SynPS/2 Synaptics TouchPad" "Synaptics Two-Finger Pressure" 280<br />
<br />
Please note that since kernel 2.6.38 the touchpad works well and no such fix is necessary.<br />
<br />
==== Fan Issues ====<br />
<br />
If the noise is running too often or making too much noise, try installing the latest version of [http://aur.archlinux.org/packages.php?ID=23686 acerhdf].<br />
<br />
==== Panel aspect ratio ====<br />
<br />
Default mode for this laptop is 1366x768 (widescreen). Different resolutions may look ugly because of whole-screen-stretching. To overcome this do the command from regular user:<br />
<br />
xrandr --output LVDS1 --set "scaling mode" "Full aspect"<br />
<br />
==Extra resources==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official US site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]<br />
* [https://help.ubuntu.com/community/Aspire1810TZ/Karmic Ubuntu wiki]<br />
* [http://forum.notebookreview.com/showthread.php?t=424213 Thread post containing specs of different models]<br />
* [http://forum.notebookreview.com/showthread.php?t=419117 Thread of tips, tricks, & tweaks]<br />
* [http://ubuntuforums.org/showthread.php?p=8409272 Power saving tips and tricks from Ubuntu forum]</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=140182Acer Aspire 14102011-05-06T19:49:41Z<p>Ek: Setup the Touchpad updates to reflect changes since kernel 2.6.38</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
This laptop is almost perfect for Linux. It has Intel chipset on motherboard (includes OpenGL 2.0-compatible video) and well-known Atheros network devices (on some models). Even special keyboard and suspend work fine. <br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Driver/Status<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Install xf86-video-intel<br />
|-<br />
| Wireless<br />
| ['''8804'''] Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br><br />
or Atheros AR9285 Wireless Network Adapter<br />
| Install iwlwifi-5000-ucode<br><br />
Out-of-box (kernel module ath9k)<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
or Atheros Communications Device 1063<br />
| Works out-of-box<br />
|-<br />
| Audio<br />
| Built-in speakers<br><br />
Headphone Jack<br><br />
Integrated Microphone<br><br />
Microphone Jack<br />
| Works<br><br />
Works<br><br />
Untested<br><br />
Untested<br><br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader:<br />
MultiMediaCard™<br><br />
Secure Digital<br><br />
Memory Stick®<br><br />
Memory Stick PRO™<br><br />
xD-Picture Card™<br />
|<br />
Untested<br><br />
Works<br><br />
Untested<br><br />
Works<br><br />
Works<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works out-of-box<br />
|-<br />
| Touchpad<br />
| <br />
| Install xf86-input-evdev, xf86-input-synaptics<br />
|-<br />
| HDMI Out<br />
| <br />
| Works OOTB<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
<br />
If you are receiving errors booting or during the install, try setting the SATA mode to "IDE" in the BIOS. This is not necessary for all users.<br />
<br />
=== During the Installation ===<br />
Be sure to install the necessary wireless driver (see above), "wireless_tools", and optionally "netcfg" if you would like wireless to work post-install. <br />
<br />
Note for beginners: connect to wifi-router directly by ethernet cable, or completely switch-off authentication. After that install Arch from network mirrors, reload and install network-manager with your preferred Desktop Environment.<br />
<br />
=== Post-Install ===<br />
<br />
==== Setup the Touchpad ====<br />
<br />
Make sure to install xf86-input-synaptics. Don't forget to enable the touchpad with <Fn>-F7. The following threads might also be interesting: [http://bbs.archlinux.org/viewtopic.php?id=77400] [http://bbs.archlinux.org/viewtopic.php?id=77190]<br />
<br />
Kernel 2.6.36 has an annoying bug makeing the touchpad finicky. A temporary workaround [https://bbs.archlinux.org/viewtopic.php?pid=871240] is:<br />
<br />
xinput --set-prop "SynPS/2 Synaptics TouchPad" "Synaptics Two-Finger Pressure" 280<br />
<br />
Please note that since kernel 2.6.38 the touchpad works well and no such fix is necessary.<br />
<br />
==== Fan Issues ====<br />
<br />
If the noise is running too often or making too much noise, try installing the latest version of [http://aur.archlinux.org/packages.php?ID=23686 acerhdf].<br />
<br />
==== Panel aspect ratio ====<br />
<br />
Default mode for this laptop is 1366x768 (widescreen). Different resolutions may look ugly because of whole-screen-stretching. To overcome this do the command from regular user:<br />
<br />
xrandr --output LVDS1 --set "scaling mode" "Full aspect"<br />
<br />
==Extra resources==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official US site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]<br />
* [https://help.ubuntu.com/community/Aspire1810TZ/Karmic Ubuntu wiki]<br />
* [http://forum.notebookreview.com/showthread.php?t=424213 Thread post containing specs of different models]<br />
* [http://forum.notebookreview.com/showthread.php?t=419117 Thread of tips, tricks, & tweaks]<br />
* [http://ubuntuforums.org/showthread.php?p=8409272 Power saving tips and tricks from Ubuntu forum]</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=126694Acer Aspire 14102011-01-02T22:58:51Z<p>Ek: /* Setup the Touchpad */</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
This laptop is almost perfect for Linux. It has Intel chipset on motherboard (includes OpenGL 2.0-compatible video) and well-known Atheros network devices (on some models). Even special keyboard and suspend work fine. <br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Driver/Status<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Install xf86-video-intel<br />
|-<br />
| Wireless<br />
| ['''8804'''] Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br><br />
or Atheros AR9285 Wireless Network Adapter<br />
| Install iwlwifi-5000-ucode<br><br />
Out-of-box (kernel module ath9k)<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
or Atheros Communications Device 1063<br />
| Works out-of-box<br />
|-<br />
| Audio<br />
| Built-in speakers<br><br />
Headphone Jack<br><br />
Integrated Microphone<br><br />
Microphone Jack<br />
| Works<br><br />
Works<br><br />
Untested<br><br />
Untested<br><br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader:<br />
MultiMediaCard™<br><br />
Secure Digital<br><br />
Memory Stick®<br><br />
Memory Stick PRO™<br><br />
xD-Picture Card™<br />
|<br />
Untested<br><br />
Works<br><br />
Untested<br><br />
Works<br><br />
Untested<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works out-of-box<br />
|-<br />
| Touchpad<br />
| <br />
| Install xf86-input-evdev, xf86-input-synaptics<br />
|-<br />
| HDMI Out<br />
| <br />
| Works OOTB<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
<br />
If you are receiving errors booting or during the install, try setting the SATA mode to "IDE" in the BIOS. This is not necessary for all users.<br />
<br />
=== During the Installation ===<br />
Be sure to install the necessary wireless driver (see above), "wireless_tools", and optionally "netcfg" if you would like wireless to work post-install. <br />
<br />
Note for beginners: connect to wifi-router directly by ethernet cable, or completely switch-off authentication. After that install Arch from network mirrors, reload and install network-manager with your preferred Desktop Environment.<br />
<br />
=== Post-Install ===<br />
<br />
==== Setup the Touchpad ====<br />
<br />
Make sure to install xf86-input-synaptics. If you use HAL for Xorg hotplugging it will be autoloaded. Don't forget to enable the touchpad with <Fn>-F7. The following threads might also be interesting: [http://bbs.archlinux.org/viewtopic.php?id=77400] [http://bbs.archlinux.org/viewtopic.php?id=77190]<br />
<br />
Kernel 2.6.36 has an annoying bug makeing the touchpad finicky. A temporary workaround[https://bbs.archlinux.org/viewtopic.php?pid=871240] is:<br />
<br />
xinput --set-prop "SynPS/2 Synaptics TouchPad" "Synaptics Two-Finger Pressure" 280<br />
<br />
==== Fan Issues ====<br />
<br />
If the noise is running too often or making too much noise, try installing the latest version of [http://aur.archlinux.org/packages.php?ID=23686 acerhdf].<br />
<br />
==== Panel aspect ratio ====<br />
<br />
Default mode for this laptop is 1366x768 (widescreen). Different resolutions may look ugly because of whole-screen-stretching. To overcome this do the command from regular user:<br />
<br />
xrandr --output LVDS1 --set "scaling mode" "Full aspect"<br />
<br />
==Extra resources==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official US site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]<br />
* [https://help.ubuntu.com/community/Aspire1810TZ/Karmic Ubuntu wiki]<br />
* [http://forum.notebookreview.com/showthread.php?t=424213 Thread post containing specs of different models]<br />
* [http://forum.notebookreview.com/showthread.php?t=419117 Thread of tips, tricks, & tweaks]<br />
* [http://ubuntuforums.org/showthread.php?p=8409272 Power saving tips and tricks from Ubuntu forum]</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=112526Acer Aspire 14102010-07-22T23:42:30Z<p>Ek: Tested, work for me.</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Driver/Status<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Install xf86-video-intel<br />
|-<br />
| Wireless<br />
| ['''8804'''] Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br><br />
['''233g16n''']<br />
| Install iwlwifi-5000-ucode<br><br />
Install iwlwifi-1000-ucode<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
| Works out-of-box<br />
|-<br />
| Audio<br />
| Built-in speakers<br><br />
Headphone Jack<br><br />
Integrated Microphone<br><br />
Microphone Jack<br />
| Works<br><br />
Works<br><br />
Untested<br><br />
Untested<br><br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader:<br />
MultiMediaCard™<br><br />
Secure Digital<br><br />
Memory Stick®<br><br />
Memory Stick PRO™<br><br />
xD-Picture Card™<br />
|<br />
Untested<br><br />
Works<br><br />
Untested<br><br />
Works<br><br />
Untested<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works out-of-box<br />
|-<br />
| Touchpad<br />
| <br />
| Install xf86-input-evdev, xf86-input-synaptics<br />
|-<br />
| HDMI Out<br />
| <br />
| Works OOTB<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
<br />
If you are receiving errors booting or during the install, try setting the SATA mode to "IDE" in the BIOS. This is not necessary for all users.<br />
<br />
=== During the Installation ===<br />
Be sure to install the necessary wireless driver (see above), "wireless_tools", and optionally "netcfg" if you would like wireless to work post-install.<br />
<br />
=== Post-Install ===<br />
<br />
==== Setup the Touchpad ====<br />
<br />
Make sure to install xf86-input-synaptics. If you use HAL for Xorg hotplugging it will be autoloaded. Don't forget to enable the touchpad with <Fn>-F7. The following threads might also be interesting: [http://bbs.archlinux.org/viewtopic.php?id=77400] [http://bbs.archlinux.org/viewtopic.php?id=77190]<br />
<br />
==== Fan Issues ====<br />
<br />
If the noise is running too often or making too much noise, try installing the latest version of [http://aur.archlinux.org/packages.php?ID=23686 acerhdf].<br />
<br />
==Extra resources==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official US site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]<br />
* [https://help.ubuntu.com/community/Aspire1810TZ/Karmic Ubuntu wiki]<br />
* [http://forum.notebookreview.com/showthread.php?t=424213 Thread post containing specs of different models]<br />
* [http://forum.notebookreview.com/showthread.php?t=419117 Thread of tips, tricks, & tweaks]<br />
* [http://ubuntuforums.org/showthread.php?p=8409272 Power saving tips and tricks from Ubuntu forum]</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=112524Acer Aspire 14102010-07-22T23:41:31Z<p>Ek: No (see below) section, since Mic work OOTB.</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Driver/Status<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Install xf86-video-intel<br />
|-<br />
| Wireless<br />
| ['''8804'''] Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br><br />
['''233g16n''']<br />
| Install iwlwifi-5000-ucode<br><br />
Install iwlwifi-1000-ucode<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
| Works out-of-box<br />
|-<br />
| Audio<br />
| Built-in speakers<br><br />
Headphone Jack<br><br />
Integrated Microphone<br><br />
Microphone Jack<br />
| Untested<br><br />
Works<br><br />
Untested<br><br />
Untested<br><br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader:<br />
MultiMediaCard™<br><br />
Secure Digital<br><br />
Memory Stick®<br><br />
Memory Stick PRO™<br><br />
xD-Picture Card™<br />
|<br />
Untested<br><br />
Works<br><br />
Untested<br><br />
Works<br><br />
Untested<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works out-of-box<br />
|-<br />
| Touchpad<br />
| <br />
| Install xf86-input-evdev, xf86-input-synaptics<br />
|-<br />
| HDMI Out<br />
| <br />
| Works OOTB<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
<br />
If you are receiving errors booting or during the install, try setting the SATA mode to "IDE" in the BIOS. This is not necessary for all users.<br />
<br />
=== During the Installation ===<br />
Be sure to install the necessary wireless driver (see above), "wireless_tools", and optionally "netcfg" if you would like wireless to work post-install.<br />
<br />
=== Post-Install ===<br />
<br />
==== Setup the Touchpad ====<br />
<br />
Make sure to install xf86-input-synaptics. If you use HAL for Xorg hotplugging it will be autoloaded. Don't forget to enable the touchpad with <Fn>-F7. The following threads might also be interesting: [http://bbs.archlinux.org/viewtopic.php?id=77400] [http://bbs.archlinux.org/viewtopic.php?id=77190]<br />
<br />
==== Fan Issues ====<br />
<br />
If the noise is running too often or making too much noise, try installing the latest version of [http://aur.archlinux.org/packages.php?ID=23686 acerhdf].<br />
<br />
==Extra resources==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official US site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]<br />
* [https://help.ubuntu.com/community/Aspire1810TZ/Karmic Ubuntu wiki]<br />
* [http://forum.notebookreview.com/showthread.php?t=424213 Thread post containing specs of different models]<br />
* [http://forum.notebookreview.com/showthread.php?t=419117 Thread of tips, tricks, & tweaks]<br />
* [http://ubuntuforums.org/showthread.php?p=8409272 Power saving tips and tricks from Ubuntu forum]</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=97390Acer Aspire 14102010-02-19T10:53:29Z<p>Ek: /* Setup the touchpad */</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Status<br />
|-<br />
| HDD<br />
| TOSHIBA MK2555GS 250GB<br />
| Works<br />
|-<br />
| Screen<br />
| Acer® CineCrystal 11.6" WXGA (1366 x 768) high-brightness (200-nit) TFT display with 16:9 aspect ratio and LED backlight <br />
| Works<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Works<br />
|-<br />
| Wireless<br />
| Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br />
| Works (install driver)<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
| Works out of box with 2009.08 install<br />
|-<br />
| Audio<br />
| Headphones/speaker/line-out with SPDIF support and microphone ports <br />
Integrated microphone <br />
| Untested<br />
Manual setup required, see below<br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader supports optional MultiMediaCard™, Secure Digital card, Memory Stick®, Memory Stick PRO™ or xD-Picture Card™<br />
| Works (SD/MS Pro tested)<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works<br />
|-<br />
| Touchpad<br />
| <br />
| Works (modify Xorg.conf)<br />
|-<br />
| HDMI Out<br />
| <br />
| Untested<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
Before you install Arch, ensure that the SATA mode is set to "IDE" in the BIOS. This will resolve the hard drive error messages.<br />
<br />
----<br />
This wasn't necessary for my Aspire 1410.<br />
<br />
=== Package Installation ===<br />
Be sure to install "iwlwifi-5000-ucode" and "wireless_tools" (I also installed "netcfg") if you would like wireless to work post-install.<br />
<br />
=== Setup the Internal Microphone ===<br />
Download the latest alsa driver from [http://www.alsa-project.org/main/index.php/Download Alsa Project Download Page].<br />
Untar the file<br />
tar -xjvf alsa-driver-1.0.22.1.tar.bz2<br />
Change directories<br />
cd alsa-driver-1.0.22<br />
Configure<br />
sh configure --prefix=/usr --with-cards=hda-intel<br />
Compile<br />
make<br />
Install<br />
sudo make install<br />
<br />
Reboot/reload your modules, run alsaconf and your mic should be good to go!<br />
<br />
=== Setup the touchpad ===<br />
Make sure to install xf86-input-synaptics. If you use HAL for Xorg hotplugging it will be autoloaded. Don't forget to enable the touchpad with <Fn>-F7. The following threads might also be interesting: [http://bbs.archlinux.org/viewtopic.php?id=77400] [http://bbs.archlinux.org/viewtopic.php?id=77190]<br />
<br />
== Additional Links ==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official Site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=97389Acer Aspire 14102010-02-19T10:53:05Z<p>Ek: /* Setup the touchpad */</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Status<br />
|-<br />
| HDD<br />
| TOSHIBA MK2555GS 250GB<br />
| Works<br />
|-<br />
| Screen<br />
| Acer® CineCrystal 11.6" WXGA (1366 x 768) high-brightness (200-nit) TFT display with 16:9 aspect ratio and LED backlight <br />
| Works<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Works<br />
|-<br />
| Wireless<br />
| Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br />
| Works (install driver)<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
| Works out of box with 2009.08 install<br />
|-<br />
| Audio<br />
| Headphones/speaker/line-out with SPDIF support and microphone ports <br />
Integrated microphone <br />
| Untested<br />
Manual setup required, see below<br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader supports optional MultiMediaCard™, Secure Digital card, Memory Stick®, Memory Stick PRO™ or xD-Picture Card™<br />
| Works (SD/MS Pro tested)<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works<br />
|-<br />
| Touchpad<br />
| <br />
| Works (modify Xorg.conf)<br />
|-<br />
| HDMI Out<br />
| <br />
| Untested<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
Before you install Arch, ensure that the SATA mode is set to "IDE" in the BIOS. This will resolve the hard drive error messages.<br />
<br />
----<br />
This wasn't necessary for my Aspire 1410.<br />
<br />
=== Package Installation ===<br />
Be sure to install "iwlwifi-5000-ucode" and "wireless_tools" (I also installed "netcfg") if you would like wireless to work post-install.<br />
<br />
=== Setup the Internal Microphone ===<br />
Download the latest alsa driver from [http://www.alsa-project.org/main/index.php/Download Alsa Project Download Page].<br />
Untar the file<br />
tar -xjvf alsa-driver-1.0.22.1.tar.bz2<br />
Change directories<br />
cd alsa-driver-1.0.22<br />
Configure<br />
sh configure --prefix=/usr --with-cards=hda-intel<br />
Compile<br />
make<br />
Install<br />
sudo make install<br />
<br />
Reboot/reload your modules, run alsaconf and your mic should be good to go!<br />
<br />
=== Setup the touchpad ===<br />
Make sure to install xf86-input-synaptics. If you use HAL for Xorg hotplugging it will be autoloaded. Don't forget to enable the touchpad with <Fn>-F7. The follwing threads might also be interesting: [http://bbs.archlinux.org/viewtopic.php?id=77400] [http://bbs.archlinux.org/viewtopic.php?id=77190]<br />
<br />
== Additional Links ==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official Site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=97388Acer Aspire 14102010-02-19T10:52:22Z<p>Ek: /* Installing Arch */</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Status<br />
|-<br />
| HDD<br />
| TOSHIBA MK2555GS 250GB<br />
| Works<br />
|-<br />
| Screen<br />
| Acer® CineCrystal 11.6" WXGA (1366 x 768) high-brightness (200-nit) TFT display with 16:9 aspect ratio and LED backlight <br />
| Works<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Works<br />
|-<br />
| Wireless<br />
| Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br />
| Works (install driver)<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
| Works out of box with 2009.08 install<br />
|-<br />
| Audio<br />
| Headphones/speaker/line-out with SPDIF support and microphone ports <br />
Integrated microphone <br />
| Untested<br />
Manual setup required, see below<br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader supports optional MultiMediaCard™, Secure Digital card, Memory Stick®, Memory Stick PRO™ or xD-Picture Card™<br />
| Works (SD/MS Pro tested)<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works<br />
|-<br />
| Touchpad<br />
| <br />
| Works (modify Xorg.conf)<br />
|-<br />
| HDMI Out<br />
| <br />
| Untested<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
Before you install Arch, ensure that the SATA mode is set to "IDE" in the BIOS. This will resolve the hard drive error messages.<br />
<br />
----<br />
This wasn't necessary for my Aspire 1410.<br />
<br />
=== Package Installation ===<br />
Be sure to install "iwlwifi-5000-ucode" and "wireless_tools" (I also installed "netcfg") if you would like wireless to work post-install.<br />
<br />
=== Setup the Internal Microphone ===<br />
Download the latest alsa driver from [http://www.alsa-project.org/main/index.php/Download Alsa Project Download Page].<br />
Untar the file<br />
tar -xjvf alsa-driver-1.0.22.1.tar.bz2<br />
Change directories<br />
cd alsa-driver-1.0.22<br />
Configure<br />
sh configure --prefix=/usr --with-cards=hda-intel<br />
Compile<br />
make<br />
Install<br />
sudo make install<br />
<br />
Reboot/reload your modules, run alsaconf and your mic should be good to go!<br />
<br />
== Setup the touchpad ==<br />
Make sure to install xf86-input-synaptics. If you use HAL for Xorg hotplugging it will be autoloaded. Don't forget to enable the touchpad with <Fn>-F7. The follwing threads might also be interesting: [http://bbs.archlinux.org/viewtopic.php?id=77400] [http://bbs.archlinux.org/viewtopic.php?id=77190]<br />
<br />
== Additional Links ==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official Site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=97387Acer Aspire 14102010-02-19T10:49:18Z<p>Ek: /* Pre-Install */</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Status<br />
|-<br />
| HDD<br />
| TOSHIBA MK2555GS 250GB<br />
| Works<br />
|-<br />
| Screen<br />
| Acer® CineCrystal 11.6" WXGA (1366 x 768) high-brightness (200-nit) TFT display with 16:9 aspect ratio and LED backlight <br />
| Works<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Works<br />
|-<br />
| Wireless<br />
| Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br />
| Works (install driver)<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
| Works out of box with 2009.08 install<br />
|-<br />
| Audio<br />
| Headphones/speaker/line-out with SPDIF support and microphone ports <br />
Integrated microphone <br />
| Untested<br />
Manual setup required, see below<br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader supports optional MultiMediaCard™, Secure Digital card, Memory Stick®, Memory Stick PRO™ or xD-Picture Card™<br />
| Works (SD/MS Pro tested)<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works<br />
|-<br />
| Touchpad<br />
| <br />
| Works (modify Xorg.conf)<br />
|-<br />
| HDMI Out<br />
| <br />
| Untested<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
Before you install Arch, ensure that the SATA mode is set to "IDE" in the BIOS. This will resolve the hard drive error messages.<br />
<br />
----<br />
This wasn't necessary for my Aspire 1410.<br />
<br />
=== Package Installation ===<br />
Be sure to install "iwlwifi-5000-ucode" and "wireless_tools" (I also installed "netcfg") if you would like wireless to work post-install.<br />
<br />
=== Setup the Internal Microphone ===<br />
Download the latest alsa driver from [http://www.alsa-project.org/main/index.php/Download Alsa Project Download Page].<br />
Untar the file<br />
tar -xjvf alsa-driver-1.0.22.1.tar.bz2<br />
Change directories<br />
cd alsa-driver-1.0.22<br />
Configure<br />
sh configure --prefix=/usr --with-cards=hda-intel<br />
Compile<br />
make<br />
Install<br />
sudo make install<br />
<br />
Reboot/reload your modules, run alsaconf and your mic should be good to go!<br />
<br />
== Additional Links ==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official Site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=97386Acer Aspire 14102010-02-19T10:49:06Z<p>Ek: /* Pre-Install */</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Status<br />
|-<br />
| HDD<br />
| TOSHIBA MK2555GS 250GB<br />
| Works<br />
|-<br />
| Screen<br />
| Acer® CineCrystal 11.6" WXGA (1366 x 768) high-brightness (200-nit) TFT display with 16:9 aspect ratio and LED backlight <br />
| Works<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Works<br />
|-<br />
| Wireless<br />
| Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br />
| Works (install driver)<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
| Works out of box with 2009.08 install<br />
|-<br />
| Audio<br />
| Headphones/speaker/line-out with SPDIF support and microphone ports <br />
Integrated microphone <br />
| Untested<br />
Manual setup required, see below<br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader supports optional MultiMediaCard™, Secure Digital card, Memory Stick®, Memory Stick PRO™ or xD-Picture Card™<br />
| Works (SD/MS Pro tested)<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works<br />
|-<br />
| Touchpad<br />
| <br />
| Works (modify Xorg.conf)<br />
|-<br />
| HDMI Out<br />
| <br />
| Untested<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
Before you install Arch, ensure that the SATA mode is set to "IDE" in the BIOS. This will resolve the hard drive error messages.<br />
<br />
----<br />
This wasn't necessary for my Aspire 1410. [[ek]]<br />
<br />
=== Package Installation ===<br />
Be sure to install "iwlwifi-5000-ucode" and "wireless_tools" (I also installed "netcfg") if you would like wireless to work post-install.<br />
<br />
=== Setup the Internal Microphone ===<br />
Download the latest alsa driver from [http://www.alsa-project.org/main/index.php/Download Alsa Project Download Page].<br />
Untar the file<br />
tar -xjvf alsa-driver-1.0.22.1.tar.bz2<br />
Change directories<br />
cd alsa-driver-1.0.22<br />
Configure<br />
sh configure --prefix=/usr --with-cards=hda-intel<br />
Compile<br />
make<br />
Install<br />
sudo make install<br />
<br />
Reboot/reload your modules, run alsaconf and your mic should be good to go!<br />
<br />
== Additional Links ==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official Site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]</div>Ekhttps://wiki.archlinux.org/index.php?title=Acer_Aspire_1410&diff=97385Acer Aspire 14102010-02-19T10:48:50Z<p>Ek: /* Pre-Install */</p>
<hr />
<div>[[Category:Acer (English)]]<br />
{{Stub}}<br />
This page will eventually hold information to install Arch Linux on the Acer Aspire 1410. Here is the (albeit empty) forum post for discussion: http://bbs.archlinux.org/viewtopic.php?pid=626296<br />
<br />
== Summary ==<br />
<br />
=== Specifications ===<br />
<br />
{| border="1"<br />
|-<br />
! Hardware<br />
! Details<br />
! Status<br />
|-<br />
| HDD<br />
| TOSHIBA MK2555GS 250GB<br />
| Works<br />
|-<br />
| Screen<br />
| Acer® CineCrystal 11.6" WXGA (1366 x 768) high-brightness (200-nit) TFT display with 16:9 aspect ratio and LED backlight <br />
| Works<br />
|-<br />
| Graphics<br />
| Integrated Intel® Graphics Media Accelerator 4500MHD<br />
| Works<br />
|-<br />
| Wireless<br />
| Intel WiFi Link 5100 802.11a/b/g/Draft-N Wireless<br />
| Works (install driver)<br />
|-<br />
| Ethernet<br />
| Attansic Technology Gigabit Ethernet<br />
| Works out of box with 2009.08 install<br />
|-<br />
| Audio<br />
| Headphones/speaker/line-out with SPDIF support and microphone ports <br />
Integrated microphone <br />
| Untested<br />
Manual setup required, see below<br />
|-<br />
| Card Reader<br />
| 5-in-1 card reader supports optional MultiMediaCard™, Secure Digital card, Memory Stick®, Memory Stick PRO™ or xD-Picture Card™<br />
| Works (SD/MS Pro tested)<br />
|-<br />
| Webcam<br />
| Chicony Electronics Co. Ltd<br />
| Works<br />
|-<br />
| Touchpad<br />
| <br />
| Works (modify Xorg.conf)<br />
|-<br />
| HDMI Out<br />
| <br />
| Untested<br />
|}<br />
<br />
== Installing Arch ==<br />
<br />
=== Pre-Install ===<br />
Before you install Arch, ensure that the SATA mode is set to "IDE" in the BIOS. This will resolve the hard drive error messages.<br />
<br />
----<br />
This wasn't necessary for my Aspire 1410. -- ek<br />
<br />
=== Package Installation ===<br />
Be sure to install "iwlwifi-5000-ucode" and "wireless_tools" (I also installed "netcfg") if you would like wireless to work post-install.<br />
<br />
=== Setup the Internal Microphone ===<br />
Download the latest alsa driver from [http://www.alsa-project.org/main/index.php/Download Alsa Project Download Page].<br />
Untar the file<br />
tar -xjvf alsa-driver-1.0.22.1.tar.bz2<br />
Change directories<br />
cd alsa-driver-1.0.22<br />
Configure<br />
sh configure --prefix=/usr --with-cards=hda-intel<br />
Compile<br />
make<br />
Install<br />
sudo make install<br />
<br />
Reboot/reload your modules, run alsaconf and your mic should be good to go!<br />
<br />
== Additional Links ==<br />
* [http://us.acer.com/acer/productv.do?LanguageISOCtxParam=en&kcond61e.c2att101=63750&sp=page16e&ctx2.c2att1=25&link=ln438e&CountryISOCtxParam=US&ctx1g.c2att92=447&ctx1.att21k=1&CRC=1346651341 Official Site]<br />
* [http://www.linlap.com/wiki/acer+aspire+1410 Linux Laptop]</div>Ek