ºìÁªLinuxÃÅ»§
Linux°ïÖú

Archlinux+xfce4°²×°Íê³ÉºóÅäÖÃ

·¢²¼Ê±¼ä:2009-11-06 19:52:54À´Ô´:ºìÁª×÷Õß:gxylcqx
[i=s] ±¾Ìû×îºóÓÉ gxylcqx ÓÚ 2009-11-6 20:27 ±à¼­ [/i]

´ÓUbuntuתµ½ArchlinuxÏÂÓÐÒ»¶Îʱ¼äÁË£¬É¹É¹ÎÒµÄÅäÖñʼǣ¬Ö»ÎªArchlinuxÅóÓÑÉÙ×ßÍä·£¬ÎÄÖÐ×ÊÁϺܶàÀ´×Ôwiki.archlinux.org´ó¼Ò¿Ï¿´EÎĿ϶¨²»ÊÇÎÊÌâµÄÀ²£¬ÓеÄÊÇÎÒ×Ô¼ºÕûÀíµÄ£¬ÓеÄÊÇÍøÂç²éÕÒµ½µÄ£¬ÒѾ­¼Ç²»ÇåÀ´Ô´ÁË£¬µ«ÎÒ¾¡ÎÒ¼ÇÒäÁ¦Ð´Ã÷³ö´¦£¬¸ÐлËùÓÐÔ­×÷Õß,ÎÄÖеĴíµÄµØ·½»¶Ó­´ó¼ÒÖ¸½Ì°¡
°²×°²¿·ÖÎҾͲ»Ð´ÁË£¬ÂÛ̳ÀïÓÐÒѾ­ÅóÓÑ·¢¹ýÁË
ºÃÁË£¬¿´¿´ÎÒʹÓÃArchlinuxÓöµ½µÄÎÊÌâ¼°½â¾ö·½·¨¡£

µÚÒ»²½£¬ÖÐÎÄÊäÈë²»ÄÜÉٵģ¬

ÈÃfcitxËæXÒ»ÆðÆô¶¯£¬Õâ¸öûÎÊÌ⣬´ó¼Ò¿Ï¿´ËæÈí¼þ£¨»ò´úÂ룩ÊÖ²áµÄ»°×ÔÈ»²»ÊÇÎÊÌâ
ÔÚ~/.xinitrc¼ÓÈëÈçÏ´úÂ루ÎÒÓõÄÊÇstartxÆô¶¯×ÀÃæµÄ£¬Èç¹ûÓÃxÏÔʾ¹ÜÀíÆ÷Ö®ÀàÆô¶¯×ÀÃæµÄ»°£¬Çë×¢Òâ±à¼­ÖÁÕýÈ·µÄÎļþ£¬Èç.profile »ò.xsession£©:
export XMODIFIERS =¡±@=im=fcitx¡±
export XIM=fcitx
export XIM_PROGRAM=fcitx
exec fcitx &


Éù¿¨
$sudo alsaconf µÈ×Ô¶¯ÅäÖþÍÐÐÁË£¬
ΪʹÆÕͨÓû§Ê¹ÓÃÉù¿¨É豸 £¬½«Óû§Ìí¼Ó½øaudio×é¾ÍÐÐÁË
#gpasswd -a ̞ audio
Ò²¿ÉÖ±½ÓÐÞ¸Ä/etc/groupÎļþ£¬ÕÒµ½audio¿ªÍ·µÄÄÇÐУ¬·ÖºÅ¸ô¿ªµÄµÚËÄÁУ¬Ò²Ó¦¸ÃÐÐÄ©£¬¼ÓÈëÄãµÄÓû§Ãû¡£´ó¼Ò·ÅÐÄ£¬ÐÞ¸ÄÕâ¸öÎļþËÀ²»ÁË£¬±ðÒÔΪÊÇϵͳÎļþ¸ç¾Í²»¸Ò¶¯Ëü


XtermÂÒÂë½â¾ö
Sudo vim /usr/share/X11/app-defaults/XTerm
´ó¸Å102ÐлòÕ߸½½ü¸ÄΪÈçÏ£ºÊµ¼ÊÉÏÊÇÔö´óXtermµÄĬÈÏ×ÖÌå´óС
Ô­ *VT100.utf8Fonts.font: -misc-fixed-medium-r-semicondensed--16-120-75-75-c-60-iso10646-1
¸Ä *VT100.utf8Fonts.font: -misc-fixed-medium-r-normal--18-120-100-100-c-90-iso10646-1
Èç¹ûÓйËÂÇ£¬¿ÉÒÔ½«¸ÃÐÐ×¢ÊÍ£¬ÖØÐÂдһÐÐÊÔÊÔ£¬²âÊÔÖе¹ÊýµÚ3¸öÊý×Ö²ÅÊÇÆð×÷ÓõÄÊý×Ö£¬´Ó60¸Äµ½90,ÂíÉϺÃÓÃÁË
ÐÞ¸ÄÑÕÉ«Ò²ÔÚÕâÀï¸Ä£¬È磺ºÚµ×ÂÌ×Ö
XTerm*background: black
XTerm*foreground: green
XTerm*scrollbar: no


javaÒÔ¼°ÆäËü»ù±¾JavaµÄÈí¼þÂÒÂë½â¾ö
À´Ô´(×ÖÌåÎÒÓõıðµÄ,ÊÇÖÐÎľ͵Ã):
http://wiki.archlinux.org/index.php/Arch_Linux_%E4%B8%AD%E6%96%87%E5%8C%96_%28%E7%AE%80%E4%BD%93%E4%B8%AD%E6%96%87%29#JAVA.E7.95.8C.E9.9D.A2.E4.B9.B1.E7.A0.81

/opt/java/jre/lib/fonts

Öн¨Á¢fallbackĿ¼£¬È»ºóÁ´½Ó»ò¿½±´Èô¸ÉÖÐÎÄ×ÖÌåµ½¸ÃĿ¼¾ÍÄÜʹjava³ÌÐòÕýÈ·ÏÔʾÖÐÎÄ¡£
Sudo ln -s /usr/share/fonts/truetype/simsun.ttc /opt/java/jre/lib/fonts/fallback #ÄǸö·¾¶ÇëдÕýÈ·£¬Òª²»¡£¡£¡£¡£
#ÒÔÏÂÁ½¸öÃüÁîҪʹÓÃrootȨÏÞ
mkfontdir
mkfontscale Ò»¶¨ÒªÔÚ×ÖÌ帴ÖƹýÀ´»òÊÇÁ´½ÓºÃÖ®ºóÔÙÖ´ÐУ¬·ñÔòÊÇ×öÎÞÓù¦

LANG=zh_CN.utf8 ÕâÔÚ~/.xinitrcÎļþÀïÉèÖÃ,=ÓëLANGÖ®¼ä²»ÄÜÓпոñ,·ñÔòÎÞÓÃ
µÄ£¬Èç¹ûʹÓÃvim±à¼­²¢¿ªÆôÁËÓï·¨½âÎösyntaxµÄ»°£¬ÉèÖÃÕýÈ·Ó¦¸Ã»áÏÔʾΪÇàÉ«
ÔÚ°²×°Archlinuxʱ£¬ÎÒÉèÖÃ/etc/rc.confÀïµÄLOCALE="en_US.utf8"¶øÔÚ.xinitrcÀï±ß²ÅÉèÖóÉÖÐÎıàÂëµÄ»°£¬¿ÉÒÔ·ÀÖ¹ÔÚ console£¨atl+ctrl+F1(-F6)£©Àï²»³öÏÖÂÒÂë
ÕâÑù·½±ã×Ô¼ºÊ¹Óá£ÎÒ°ÑÎÒµÄ.xinitrc·Å³öÀ´°É£¬´ó¼Ò²Î¿¼Ê¹Óã¬ÒªÊ¹ÓÃzh_CN.utf8Ó¦µ±±£Ö¤ÏµÍ³ÓÐÕâ¸ö±àÂ룬¹ØÓÚLOCALE£¬´ó¼Ò×Ô¼ºÉÏÍø²é°É,UbuntuÖÐÎÄÂÛ̳ÎÒ¼û¹ýÒ»¸öÌû×Ó£¬Ð´µÃºÜ³¤ºÜÏêϸ¡£¡£
LOCALE=zh_CN.utf8
LANG=zh_CN.utf8
LC_CTYPE="zh_CN.utf8"
LC_NUMERIC="zh_CN.utf8"
LC_TIME="zh_CN.utf8"
LC_COLLATE="zh_CN.utf8"
LC_MONETARY="zh_CN.utf8"
LC_MESSAGES="zh_CN.utf8"
LC_NAME="zh_CN.utf8"
LC_ADDRESS="zh_CN.utf8"
LC_TELEPHONE="zh_CN.utf8"
LC_MEASUREMENT="zh_CN.utf8"
LC_ALL="zh_CN.utf8"
export XMODIFIERS="@im=fcitx"
export XIM="fcitx"
export XIM_PROGRAM="fcitx"
exec fcitx &
exec startxfce4



Xfce4ÖØÆô»òÕ߹ػúʱ³öÏÖ £¨Õâ¸öÎҼǵúÃÏñÊÇÀ´×ÔarchlinuxµÄÂÛ̳£©
org.freedesktop.hal.powermanagement reboot no <-(action,result)
ÀàËÆÇé¿ö½â¾ö·½·¨(ÍøÉÏÓÐÈË˵һ°ã¼ûÓÚÓÃstartxÆô¶¯xfce4µÄÓû§,δ֪Õæ¼Ù)
cp /etc/PolicyKit/PolicyKit.conf /etc/PolicyKit/PolicyKit.conf.bak
sudo vim /etc/PolicyKit/PolicyKit.conf
½«Àï±ßÄÚÈÝÇå¿Õ,ÔÙÌí¼ÓÈçÏÂÐÅÏ¢¼´¿É½â¾ö(ÒѲâÊÔ,Ôݲ»·¢ÏÖÈκÎÎÊÌâ,ÍøÉÏÓÐЩÈË˵²»ÄÜ·¢ÏÖUÅÌÖ®À༴²å¼´ÓÃÉ豸,ÎÒÕâÀïûÊÂ,»¹ÓУ¬²Ù×÷Ç°ÇëÄãÏȲ鿴ÏÂÓû§ÃûÊÇ·ñÔÚpower×éÖÐÒ²ÓпÉÄÜÊÇȨÏÞÎÊÌâÒýÆðµÄŶ)

















¼Çס£º¹Ø»ú»òÆäËüµçÔ´²Ù×÷ʱ³öÏÖʲôÐÅÏ¢¾ÍÔÚactionÀïÌîʲôÐÅÏ¢,resultµÈÓÚYes¾ÍÐÐÁË
·½·¨2(δ²âÊÔ,²»ÖªµÀÊÇ·ñ¿ÉÐÐ)
ÔÚ~/.xinitrcÎļþÖн«
exec startxfce4 »»³É
exec ck-launch-session startxfce4


ÖÐÎÄ×ÖÌå·¢Ðé
Xfce4 ÀïÉèÖÃ
²Ëµ¥--ÉèÖÃ--Íâ¹Û--×ÖÌå,ϱßÓиö×Ô¶¨ÒåDPIµÄ,ÎÒÓõÄÊÇ96,ÍøÉÏ˵һ°ãÊÇ6»ò12µÄ±¶Êý,
ΪʲôÎҾͲ»Ì«Çå³þÁË
µ÷Õû¼´Ê±¼ûЧµÄ,¿´Çé¿ö°É
Æäʵ¸Õ¸Õ×öµÄ¾ÍÊÇÐÞ¸Ä~/.config/xfce4/Xft.xrdbÕâ¸öÎļþ£¬ÔÚÀïÃæÐÞ¸ÄÕâ¾ä
Xft.dpi: 78
µ«ÊÇÈç¹ûÖ±½ÓÐÞ¸ÄÕâ¸öÎļþ,ÎÒµÄXFCE4ÔÚstartxºóÊǺÚÆÁ,µ«²»ËÀ»ú
ÔÚÍâ¹ÛÀïÉèÖþÍûÊÂ,Èç¹û´ó¼Ò¼ûµ½ÕâÖÖÇé¿ö,µ½~/.config/xfce4/Xft.xrdbÀï±ß°Ñ
Xft.dpi:78ÕâÐÐɾµô,ÔÙÆô¶¯XÊÔÊÔ
Èç¹û»¹·¢Ð飬½¨Òé´ó¼Ò¸ü¸Ä×ÖÌå°É Ò²ÊÇÉϱßÄǸö×ÖÌåÉèÖýçÃ棬ÐÞ¸ÄÏÂ×ÖÌå°É
Ò²ÊǼ´Ê±ÉúЧµÄ¡£Èç¹û²»ÐУ¬ÓôÖÌå¿´¿´¡£

ÐÝÃß
Èç¹ûÄã²»ÄÜÐÝÃß,ÇëÏȼì²éµ±Ç°Óû§ÊÇ·ñÔÚϵͳµÄpower×éÖÐ,
Èç¹û²»ÔÚ,Ö±½Ó¼Ó..
sudo vim /etc/group
ÔÚpowerÐÐ×îºó¼ÓÈëÈ¥,ÎÒµÄÎļþÖкÃÏñ±ßroot¶¼²»ÔÚÀï±ß,ËùÒÔ¼ÓÁËroot,Username
»òÕßÄã¿ÉÓÃÃüÁî¼Ó
#gpasswd -a Username power
ÕâÑù¾ÍÄÜÔö¼ÓUsernameÓû§µ½power×éÀï±ßÁË
ÄÜÐÝÃßÁË,µ«Æô¶¯Ê±Ö±½ÓÕý³£Æô¶¯ÁË,¸ù±¾²»Äָܻ´,Õâ¸öÎÊÌâÈçϽâ¾ö,ÉÏ´ÎÔÚUbuntuÏÂÔö¼Óswap·ÖÇøʱΪ½â¾öÕâ¸öÎÊÌâ,°´ÍøÉÏ·½·¨Öؽ¨ÁËintrdÎļþ,µ«ÊÇ·¢ÏÖarchlinux¸ü¼òµ¥
ÐÞ¸Ämenu.lstÎļþ,ÕâÊÇÔÚarchlinuxÖÐÎÄ
(http://wiki.archlinux.org/index.php/Pm-utils_%E7%94%B5%E6%BA%90%E7%AE%A1%E7%90%86_%28%E7%AE%80%E4%BD%93%E4%B8%AD%E6%96%87%29)ÉÏ¿´µ½µÄ
#sudo vim /boot/grub/menu.lst
ÔÚkernelÐеÄÄǸöroot= ÏîºÍroÖ®¼ä¼ÓÉÏÄãµÄSwapÇøλÖþÍÐÐÁË,ÒÔÏÂÊÇÎÒµÄ
kernel /boot/vmlinuz26 root=/dev/sda5 resume=/dev/sda3 ro

Æô¶¯ºó¿ªÆôС¼üÅÌ
°²×°numlockx
#pacman -S numlockx
ÓÃxtartxÆô¶¯XµÄ»°ÔÚ~/.initrc ¼ÓÈë
/usr/bin/numlockx on
/etc/rc.local¼ÓÈëÒÔÏ´úÂë ,ÔÚÖն˾ÍÄÜÓÃС¼üÅÌ
for tty in /dev/tty[1-6]
do setleds -D +num < $tty
done


Æô¶¯X³ÌÐò³¬¿¨ÎÊÌâ,ÕâÊDZàÂëÎÊÌâ,ÕâЩ³ÌÐòºìÁªÉÏûʲôÈËÓÃÁË°É£¬½çÃæÄÑ¿´£¬µ«ÊÇÈÔ±»Ò»Ð©Å£ÈË·îΪ¾­µä¡£ÎÒÒ²²»³££¬Ö»ÊÇÓиöXtermż¶ûÓÃÏ£¬»¹ÓмÆËãÆ÷xcalc
sudo vim /usr/share/X11/locale/zh_CN.UTF-8/XLC_LOCALE
ÉÏÊöÎļþ¿Éɾ³ý,²»¹ýÓпÉÄÜÔì³É±ðµÄСÎÊÌâ,ÎÒÕâÀï¾ÍÊÇÓÃXµÄ³ÌÐòʱ»á³öÏÖ¾¯¸æ¶ªÊ§×Ö·û¼¯,¶øÇÒxtermÏÔʾÖÐÎÄ»áÕæÕýµØ³öÏÖÂÒÂë
²»É¾³ýµÄ¾ÍÕâÑù×ö,Ïȱ¸·ÝÎļþ,
½«Àï±ßÄǸöGBKµÄÄǶÎɾµô(ÔÚÎÒÕâÊÇf3ÄÇÒ»Óï¾ä¿é)


Ìí¼Ó×ÖÌ壬
ÕâÒ»²½ºÃÏñ¼¸¸ö·¢ÐаæÖ®¼ä¶¼Í¨ÓÃ

×ÖÌ帴ÖƵ½/usr/share/fontsºóÖ´ÐÐÈçÏÂÖ¸Áî
#fc-cache -vf ;²»¹ýÎÒ·¢¾õÎÒ¸´ÖƽøÈ¥ºó,²»ÓÃÖ´ÐÐÕâ¸öÃüÁîÓеijÌÐòÒѾ­ÄÜ·¢ÏÖÐÂ×ÖÌå(Èçfirefox,ÔÚËüµÄÊ×Ñ¡Ïî--ÄÚÈÝ--×ÖÌåÀï¿É¿´µ½),ÄѵÀÊÇÎҵĻþõ? WikiÉÏ˵µÄ,»¹ÊÇÖ´ÐÐһϰÉ,È˼Ò˵µÄ×ÜÓеÀÀíµÄ

EvinceÔĶÁPDFʱÖÐÎIJ»ÏÔʾ(Èç¹ûÊÇÔÚµ±Ç°ÏµÍ³Éú³ÉµÄPDFÔòÏÔʾÕý³£)
pacman -S poppler-data


gvimÏ»®Ïß¿´²»Çå
http://forum.ubuntu.org.cn/viewtopic.php?f=8&t=199539&start=0
ÄË×ÖÌåÐоàСËùÖÂ,ÔÚ~/.gvimrc¼ÓÈëÈçÏÂÐÐ
set linespace=6»òÆäËüÖµ¼´¿É

ÒÔrootÉí·ÝÆô¶¯¹ýfirefoxºó£¬ÔÙʹÓÃÆÕͨÓû§Æô¶¯ËüÌáʾ¡°ÊéÇ©ÎÞ·¨Õý³£Ê¹Óá±×ÖÑù,ÕâÊÇÓÉÓÚfirefoxÖв¿·ÖÅäÖÃÎļþȨÏ޸ıäËùÖÂ
cd ~/.mozilloa/firefox Ó¦¸Ã»áÓÐÁ½¸öĿ¼ºÍÒ»¸öÎļþprofiles.ini ´ò¿ªÕâ¸öÎļþ £¬
¿´ËüµÄPath·¾¶Ö¸ÏòÄĸöĿ¼£¬È»ºóµ½¸ÃĿ¼ÏÂɾ³ý
cookies.sqlite-journal
places.sqlite-journalÕâÁ½¸öÎļþ¼´¿É£¬»òÕ߸ıäÆäȨÏÞÒ²ÐÐ


Apache2²»½âÊÍphp£¨²Î¿¼http://wiki.archlinux.org/index.php/LAMP£©
ÏÈ°²×°php,ºÍphp-apache£¨²»ÓüӰ汾ºÅ£©£¬Õâʱϵͳ²Å»áÓÐlibphp5.soÕâ¸öÄ£¿é
ÔÙ°²×°apache2£¨ÏµÍ³µÄ°üºÃÏñϸ·ÖµÃºÜÀ÷º¦£¬Èç¹û²»ÓÃÔ´Âë°²×°Çë°´×Ô¼ºÐèÇóÌí¼ÓÄ£¿é£©
È»ºóÔÚhttpd.conf£¨ÔÚapache2°²×°Ä¿Â¼confÏ£©£¬Ìí¼ÓÈçÏ´úÂë
LoadModule php5_module modules/libphp5.so #½âÊÍphpµÄÄ£¿é
Include /etc/httpd/conf/extra/php5_module.conf #Õâ¸öÎļþÎÒÒ²²»ÊǺÜÇå³þ¸ÉɶµÄ£¬²»¹ý¿Ï¶¨ÊÇÅäÖÃphpµÄÀ²£¬ºÙºÙ£¬ËüµÄÄÚÈÝÊǼ¸¸öAddHandler
»¹µÃÅäÏÂphpµÄÅäÖÃÎļþphp.ini£¬Ä¬ÈÏÔÚ/etc/php/php.ini
ÕÒµ½ÓÐÒ»ÐÐÊÇopen_basedir¿ªÍ·µÄ¶«Î÷£¬Ìí¼ÓÄãµÄÍøվĿ¼µ½ÐÐÄ©£¬ÓëÔ­ÏȵÄÓ㺺Ÿô¿ª
£¨OÁË£¬²î²»¶àÁË£¬ÎÒµ½ÕâÀï¾ÍÄÜÕý³£´ò¿ªphpÍøÒ³ÁË£¬²»¹ý¿´±ðÈ˵ÄÒªÇó»¹µÃÔÚhttpd.confÀï±ßÓï¾ä¿éÀï±ß¼Ó
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
£¬ÎÒ·´ÕýÊDz»ÓüÓÒ²ÄܽâÊÍÁË£¬mime.typesÅäÖÃÎļþÀïҲûÓÐÓйØphpµÄÐУ¬ÄܽâÊÍËùÒԾͲ»¼ÓÁË)



½áÊø--------

ÓÐʲôÎÊÌâ»òÊDz»¶ÔµÄµØ·½ÆÚÍû´ó¼ÒÌá³ö°¡¡£×£´ó¼ÒLinux·Óä¿ì
ÎÄÕÂÆÀÂÛ

¹²ÓÐ 4 ÌõÆÀÂÛ

  1. kingwl88 ÓÚ 2010-11-13 21:13:07·¢±í:

    ѧϰ£¬Ö§³Ö

  2. shejijia ÓÚ 2010-11-12 20:32:46·¢±í:

    Ö§³Ö£¬Ð»Ð»·ÖÏí

  3. Ringfar ÓÚ 2009-11-07 00:07:07·¢±í:

    Ö§³Ö

  4. Bebun ÓÚ 2009-11-06 20:17:48·¢±í:

    ѧϰÏÂ