2008年6月26日 星期四

FreeBSD, Linux Serial Console

Serial Console 在沒有 VGA 的環境下很好用
FreeBSD 的 Serial Console 設定
在 /boot/loader.conf 加上 'console="comconsole"
編輯 /etc/ttys 的 ttyd0 那行
ttyd0 "/usr/libexec/getty std.9600" vt100 on secure
很簡單吧, Kernel 不要忘記加上 COM Port 的支援 (device sio0)
ref. FreeBSD Handbook: 21.6 Setting Up the Serial Console

Linux 的 Serial Console 設定
有 Boot Loader, Kernel 參數, inittab 三個地方要設
以 GRUB 為例, 在 menu.lst 前加入
serial --unit=0 --speed=9600
terminal serial
在 kernel 那一行的最後加上 console=tty0 console=ttyS0,9600
在 /etc/inittab 最後加上 s0:2345:respawn:/sbin/agetty ttyS0 115200 linux
ref. Using GRUB via a serial line, Linux Serial Console

支援 Serial 的 Terminal 軟體, X 下有不少, for Windows 最基本的就是 Windows 附的超級終端機,
商業軟體 SecureCRT, PowerTerm 都不錯,
也是有 Open Source 如 RealTerm, 但功能較差.

查看rpm內容及install/uninstall 的script

包的内容: rpm -qpl MySQL-server-4.0.24-0.i386.rpm
执行的操作: rpm -qp --scripts MySQL-server-4.0.24-0.i386.rpm

VirtualBox Bridge Mode

先裝好 tunctl 及 bridge-utils 套件
tunctl -t tap0 -u virtualbox
brctl addbr br0
ifconfig eth0 0.0.0.0 promisc
brctl addif br0 eth0
ifconfig br0 192.168.0.1 (把原來設在 eth0 的 IP 設到 br0)
brctl addif br0 tap0
ifconfig tap0 up
chmod 0666 /dev/net/tun
在 VirtualBox 網路設定為 Host Interface, Interface Name 為 tap0
就跟 VMware 的 Bridge Mode 一樣.

2008年6月24日 星期二

手動安裝gcin

/etc/sysconfig/i18n:

LANG="en_US.UTF-8"
SYSFONT="latarcyrheb-sun16"
LC_CTYPE="zh_TW.UTF-8"
LC_MESSAGES="en_US.UTF-8"
GTK_IM_MODULE=gcin
QT_IM_MODULE=gcin
XIM_PROGRAM=gcin

/etc/X11/xinit/xinput.d/gcin.conf

XIM=gcin
XIM_PROGRAM=gcin
XIM_ARGS="-x gcin"
GTK_IM_MODULE=gcin
QT_IM_MODULE=gcin


要注意!!確定gtk跟qt的im module有確定copy到指定的地方, 並且個別測試gtk以及qt的application
gtk application有可能因為支援XIM模式, 所以可以使用