xorg.confによる解像度の変更
9/Feb/2011
それがいつかはさだかではないが、最近のディストリにはxorg.confがない。
/usr/share/X11/xorg.conf.dの下あたりにかくされるように変更された様子。
ここらへんのいぢりかたは知らないのでw
古典的に/etc/X11/xorg.confを新規生成することにする
最初は800 x 600 ぐらいのトホホな解像度からすたーと
んで、以下 手順の備忘録
、ubuntu10.04(LTS) 32bit版 on 手作りpen4 machine PCの場合ですよ
0) sshdすら動いていない場合があるので、念のためsshdを機動しておくと幸せになれるかもしれない(net越しのレスキューが可能かもよ)
1) #service gdm stop
2) 適当にpttyをあける(ctl + alt +F2 とかね)
3) #xorg -configure を叩く
すっと /root/xorg.conf.new
ってのができる
4) #vi /root/xorg.conf.newにて編集
hirasawa@ubunt1004-32-2:~$ cat /etc/X11/xorg.conf | grep -v "^ *#" | grep -v "^$" Section "ServerLayout" Identifier "X.org Configured" Screen 0 "Screen0" 0 0 InputDevice "Mouse0" "CorePointer" InputDevice "Keyboard0" "CoreKeyboard" EndSection Section "Files" ModulePath "/usr/lib/xorg/modules" FontPath "/usr/share/fonts/X11/misc" FontPath "/usr/share/fonts/X11/cyrillic" FontPath "/usr/share/fonts/X11/100dpi/:unscaled" FontPath "/usr/share/fonts/X11/75dpi/:unscaled" FontPath "/usr/share/fonts/X11/Type1" FontPath "/usr/share/fonts/X11/100dpi" FontPath "/usr/share/fonts/X11/75dpi" FontPath "/var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType" FontPath "built-ins" EndSection Section "Module" Load "dri2" Load "record" Load "extmod" Load "dri" Load "glx" Load "dbe" EndSection Section "InputDevice" Identifier "Keyboard0" Driver "kbd" EndSection Section "InputDevice" Identifier "Mouse0" Driver "mouse" Option "Protocol" "auto" Option "Device" "/dev/input/mice" Option "ZAxisMapping" "4 5 6 7" EndSection Section "Monitor" Identifier "Monitor0" VendorName "Monitor Vendor" ModelName "Monitor Model" HorizSync 20 - 83 << モニターのマニュアルでしらべろ VertREfresh 50 - 76 EndSection Section "Device" Identifier "Card0" Driver "mga" <<ここら辺のチェック VendorName "Matrox Graphics, Inc." BoardName "MGA G400/G450" BusID "PCI:1:0:0" EndSection Section "Screen" Identifier "Screen0" Device "Card0" Monitor "Monitor0" DefaultDepth 24 << 追加 SubSection "Display" Viewport 0 0 Depth 24 Modes "1600x1200" "1024x768" << 追加 EndSubSection EndSection hirasawa@ubunt1004-32-2:~$
4)#cp /root/xorg.conf.new /etc/X11/xorg.conf
5) #service gdm start (つうよりは #rebootの方が手っ取り早いですな)
これでうまくいくはずだよ。
最後に
5) #xrandr コマンドで確認
2011/02/28 こっちの方がいいかな?
http://mo.kerosoft.com/0167
https://wiki.ubuntulinux.jp/UbuntuTips/Hardware/HowToChangeMonitorResolution
[hirasawa@fedora14-17 ~]$ cvt 1600 1200 # 1600x1200 59.87 Hz (CVT 1.92M3) hsync: 74.54 kHz; pclk: 161.00 MHz Modeline "1600x1200_60.00" 161.00 1600 1712 1880 2160 1200 1203 1207 1245 -hsync +vsync [hirasawa@fedora14-17 ~]$ [hirasawa@fedora14-17 ~]$ vi ./.xprofile [hirasawa@fedora14-17 ~]$ cat ./.xprofile #!/bin/sh xrandr --newmode "1600x1200_60.00" 161.00 1600 1712 1880 2160 1200 1203 1207 1245 -hsync +vsync xrandr --addmode VGA-1 "1600x1200_60.00" xrandr --output VGA-1 --mode 1600x1200_60.00 [hirasawa@fedora14-17 ~]$ xrandr Screen 0: minimum 320 x 200, current 1600 x 1200, maximum 4096 x 4096 VGA-1 connected 1600x1200+0+0 (normal left inverted right x axis y axis) 0mm x 0mm 1024x768 60.0 800x600 60.3 56.2 848x480 60.0 640x480 59.9 1600x1200_60.00 59.9* DVI-D-1 disconnected (normal left inverted right x axis y axis) [hirasawa@fedora14-17 ~]$