2,070 瀏覽數

RHEL 6 – X Window 設定檔

突然同事問我 RHEL6 的 X11 的設定檔放那裏?阿!!不就是在 /etc/X11/xorg.conf 嗎?? 結果仔細看真的沒這一個檔,我們需要手動產生,執行 #Xorg -configure 就可以產生 xorg.conf 了!!!

[root@localhost ~]$ Xorg -configure

X.Org X Server 1.17.2
Release Date: 2015-06-16
X Protocol Version 11, Revision 0
Build Operating System:  2.6.32-573.18.1.el6.x86_64 
Current Operating System: Linux localhost.localdomain 3.10.0-514.6.1.el7.x86_64 #1 SMP Wed Jan 18 13:06:36 UTC 2017 x86_64
Kernel command line: BOOT_IMAGE=/vmlinuz-3.10.0-514.6.1.el7.x86_64 root=/dev/mapper/centos-root ro crashkernel=auto rd.lvm.lv=centos/root rd.lvm.lv=centos/swap rhgb quiet LANG=en_US.UTF-8
Build Date: 06 November 2016  12:43:39AM
Build ID: xorg-x11-server 1.17.2-22.el7 
Current version of pixman: 0.34.0
	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.0.log", Time: Sat Apr 22 00:01:03 2017
List of video drivers:
	ati
	intel
	nouveau
	qxl
	radeon
	v4l
	vmware
	vesa
	fbdev
	modesetting
	dummy
(++) Using config file: "/root/xorg.conf.new"
(==) Using config directory: "/etc/X11/xorg.conf.d"
(==) Using system config directory "/usr/share/X11/xorg.conf.d"


Xorg detected your mouse at device /dev/input/mice.
Please check your config if the mouse is still not
operational, as by default Xorg tries to autodetect
the protocol.

Your xorg.conf file is /root/xorg.conf.new

To test the server, run 'X -config /root/xorg.conf.new'

(EE) Server terminated with error (2). Closing log file.

Xorg 會顯示目前他有支援的 VGA 驅動模組.並且自行偵測你的系統可以使用哪一種模組,新產生的設定檔 xorg.conf.new 會儲存在家目錄,我們需要把該檔案從家目錄 xorg.conf.new 複製到 /etc/X11 ,如果偵測錯誤,可依據下面支援列表中自行編輯成目前系統的 VGA 的驅動模組.

常見的 Xorg 驅動程式名稱.

  • qxl (QEMU QXL video accelerator)
  • ati
  • intel
  • sisusb
  • mga
  • r128
  • radeon (Driver for ATI/AMD Radeon)
  • modesetting (Kernel Mode Setting)
  • trident
  • spiceqxl
  • cirrus
  • savage
  • sis
  • nouveau (Nvidia 的顯示卡)
  • siliconmotion
  • mach64
  • tdfx
  • vmware
  • openchrome
  • s3
  • neomagic
  • vesa (VESA-compatible)
  • fbdev (Linux framebuffer X)
  • v4l (old Xv ddx driver for video4linux devices)

最常指定使用的 xorg driver 驅動程式為 vesa,而且只要是 VESA-compatible video cards 都可以使用.或是 fbdev (Linux framebuffer X 驅動程式).

修改後就可以啟動 X-window

[root@localhost ~]$ cp xorg.conf.new /etc/X11/xorg.conf
[root@localhost ~]$ vi /etc/X11/xorg.conf
Section "Device"
        Identifier  "Card0"
        Driver      "fbdev"
        BusID       "PCI:0:15:0"
EndSection
[root@localhost ~]$ startx

如果可以進入 X-Windows ,這個 VGA 的驅動模組就確定可以在你的系統上來使用.

發表迴響