Difference between revisions of "X configuration"

From FreekiWiki
Jump to navigation Jump to search
m (XF86Config moved to X configuration: XF86 no longer used. We need a more general page.)
(a beginning. need to put in dpkg-reconfigure and the other ways to configure X)
Line 1: Line 1:
 
{{cleanup}}
 
{{cleanup}}
 +
The X-windows system configuration information is kept in text files in /etc/X11.  In older freekboxen, this file is called /etc/X11/XF86Config-4, and in newer systems is /etc/X11/xorg.conf, but it is essentially the same file.
  
 +
This file includes information on the keyboard, mouse, monitor, and video card, as well as some special options for resolution, fancy graphics display, and multi-headed systems.  The file is broken up into sections such as <code>"InputDevice"</code> for mice and keyboards, <code>"Monitor"</code> for monitors, and just plain <code>"Device"</code> for video cards themselves.  The <code>"Screen"</code> section has meta information about combining all the pieces together correctly.
  
==Overview of contents==
 
  
The /etc/X11/XF86Config-4 file holds configuration information for the XF86 windowing system.  This includes information on the keyboard, mouse, monitor, and video card, as well as some special options for resolution, fancy graphics display, and multi-headed systems.  The file is broken up into sections such as <code>"InputDevice"</code> for mice and keyboards, <code>"Monitor"</code> for monitors, and just plain <code>"Device"</code> for video cards themselves.  The <code>"Screen"</code> section has meta information about combining all the pieces together correctly.
+
==How to edit the file==
  
We are going to have to deal with this file most often because [[magix]] somehow fails to create it correctly.  In these situations, we need to make small tweaks to fix things.
+
Occasionally, the normal methods of configuring X fail and we need to edit the file directly.
 
 
==How to edit the file==
 
  
 
Using [[nano]] or another command line editor as [[root]], you open up the file:
 
Using [[nano]] or another command line editor as [[root]], you open up the file:
  
  nano -w /etc/X11/XF86Config-4
+
  nano -w /etc/X11/XF86Config-4
 +
or
 +
nano -w /etc/X11/xorg.conf
  
 
Then you'll need to look for what you have to change.  One common change is the video [[driver]], for instance from <code>"nvidia"</code> to <code>"nv"</code> (closed source to open source drivers for nVidia cards).  Look through the file until you find the <code>"Device"</code> section, and change the value of the <code>Driver</code> line to match the correct driver.  Another common change is the default color depth, which is under the <code>"Screen"</code> section, on a line labeled <code>DefaultDepth</code>.
 
Then you'll need to look for what you have to change.  One common change is the video [[driver]], for instance from <code>"nvidia"</code> to <code>"nv"</code> (closed source to open source drivers for nVidia cards).  Look through the file until you find the <code>"Device"</code> section, and change the value of the <code>Driver</code> line to match the correct driver.  Another common change is the default color depth, which is under the <code>"Screen"</code> section, on a line labeled <code>DefaultDepth</code>.
Line 18: Line 19:
 
Make your changes and save the file, then quit out of the editor.  As root, you'll want to try to start X again, which you accomplish by:
 
Make your changes and save the file, then quit out of the editor.  As root, you'll want to try to start X again, which you accomplish by:
  
  /etc/init.d/kdm restart
+
  /etc/init.d/kdm restart (for the FreekBox 3)
 +
or
 +
/etc/init.d/gdm restart  (for Ubuntu boxes)
  
 
If this doesn't work again, check the log file:
 
If this doesn't work again, check the log file:
  
 
  less /var/log/XFree86.0.log
 
  less /var/log/XFree86.0.log
 +
or
 +
less /var/log/Xorg.0.log
  
 
and try again.
 
and try again.
  
 +
<!--
 
You can ask X to attempt to configure itself, with this command
 
You can ask X to attempt to configure itself, with this command
 
  X -configure
 
  X -configure
Line 31: Line 37:
 
  X --xf86config XF86Config-4
 
  X --xf86config XF86Config-4
 
This will produce a grey screen with a working mouse if it works.
 
This will produce a grey screen with a working mouse if it works.
 
  
 
For more information, type:
 
For more information, type:
Line 38: Line 43:
  
 
at the command line.
 
at the command line.
 
+
-->
  
 
[[Category: Build]]
 
[[Category: Build]]
 
[[Category:Tech support]]
 
[[Category:Tech support]]

Revision as of 14:02, 19 July 2008

This page or section appears to be out of date or otherwise inaccurate.
Please edit as seems necessary, removing the {{cleanup}} tag when you are through.

The X-windows system configuration information is kept in text files in /etc/X11. In older freekboxen, this file is called /etc/X11/XF86Config-4, and in newer systems is /etc/X11/xorg.conf, but it is essentially the same file.

This file includes information on the keyboard, mouse, monitor, and video card, as well as some special options for resolution, fancy graphics display, and multi-headed systems. The file is broken up into sections such as "InputDevice" for mice and keyboards, "Monitor" for monitors, and just plain "Device" for video cards themselves. The "Screen" section has meta information about combining all the pieces together correctly.


How to edit the file

Occasionally, the normal methods of configuring X fail and we need to edit the file directly.

Using nano or another command line editor as root, you open up the file:

nano -w /etc/X11/XF86Config-4  

or

nano -w /etc/X11/xorg.conf

Then you'll need to look for what you have to change. One common change is the video driver, for instance from "nvidia" to "nv" (closed source to open source drivers for nVidia cards). Look through the file until you find the "Device" section, and change the value of the Driver line to match the correct driver. Another common change is the default color depth, which is under the "Screen" section, on a line labeled DefaultDepth.

Make your changes and save the file, then quit out of the editor. As root, you'll want to try to start X again, which you accomplish by:

/etc/init.d/kdm restart  (for the FreekBox 3)

or

/etc/init.d/gdm restart  (for Ubuntu boxes)

If this doesn't work again, check the log file:

less /var/log/XFree86.0.log

or

less /var/log/Xorg.0.log

and try again.