Notes: November 2003 Archives

第一台電腦
無線網路->慣用網路->新增, SSID 任意取一個名字, 如 test
網路驗證: 已開啟
資料加密: 停用
進階: 只給電腦到電腦的網路

第二台電腦
重複上面的動作, SSID 取一樣即可

USB keyboard support

user-pic
Vote 0 Votes

Input core support --->
[*] Input core support
[*] Keyboard support
USB support --->
[*] Support for USB
[*] USB HIDBP Keyboard (basic) support
勾選 OHCI Num Lock 燈號才會正常, 否則一直亮
[*] OHCI (Compaq, iMacs, OPTi, SiS, ALi, ...) support

$_SERVER["HTTP_ACCEPT_LANGUAGE"]

xdm

user-pic
Vote 0 Votes

server 端
修改 /etc/X11/xdm/xdm-config
改成 #DisplayManager.requestPort: 0
啟動 xdm

client 端
X -query host
X -broadcast

client 端一開機就連
3:2345:respawn:/usr/bin/X11/X -broadcast

perl,sed replace, append sample

user-pic
Vote 0 Votes

在 ccc 後面加上一行 xxx

# cat test
aaa
bbb
ccc
ddd

# perl -pi -e "s/ccc/ccc\nxxx/" test

# cat test
aaa
bbb
ccc
xxx
ddd

把 xxx 換成 yyy
# perl -pi -e "s/xxx/yyy/" test

# cat test
aaa
bbb
ccc
yyy
ddd

把檔案中含有 xxx 字串的下一行加上一行 new line
# cat test
aaa 111
bbb 222
ccc 333
555 xxx 444
ddd kkkkkkkkkkkkk
xxx 666
mmmmmmmmmmmmm
lllllllllllllllllxxx
eeeeeee

# sed -e '/xxx/a\
new line' test > test.tmp

# mv test.tmp test

# cat test
aaa 111
bbb 222
ccc 333
555 xxx 444
new line
ddd kkkkkkkkkkkkk
xxx 666
new line
mmmmmmmmmmmmm
lllllllllllllllllxxx
new line
eeeeeee

postfix clean mail queue

user-pic
Vote 0 Votes

postsuper -d ALL

apache + ssl + php (更新版)

user-pic
Vote 0 Votes

準備
apache_1.3.29.tar.gz from http://httpd.apache.org/
openssl-0.9.7c.tar.gz from http://www.openssl.org/
php-4.3.3.tar.gz from http://www.php.net/
mod_ssl-2.8.16-1.3.29.tar.gz from http://www.modssl.org/

解壓全部
cd openssl-0.9.7c
./config -fPIC
make
make install

cd ../mod_ssl-2.8.16-1.3.29
./configure --with-apache=../apache_1.3.29 --with-ssl=../openssl-0.9.7c --prefix=/usr/local/apache

cd ../apache_1.3.29
./configure --prefix=/usr/local/apache --sysconfdir=/usr/local/apache/conf --enable-module=so \
--enable-shared=ssl --enable-module=ssl --enable-module=rewrite --enable-shared=rewrite
make
make certificate

STEP 0: Decide the signature algorithm used for certificate
The generated X.509 CA certificate can contain either
RSA or DSA based ingredients. Select the one you want to use.
Signature Algorithm ((R)SA or (D)SA) [R]:D (選 DSA)

WARNING! You're generating a DSA based certificate/key pair.
This implies that RSA based ciphers won't be available later,
which for your web server currently still means that mostly all
popular web browsers cannot connect to it. At least not until
you also generate an additional RSA based certificate/key pair
and configure them in parallel.
______________________________________________________________________

STEP 1: Generating DSA private key (1024 bit) [server.key]
Generating DSA private key via SnakeOil CA DSA parameters
109338882 semi-random bytes loaded
Generating DSA key, 1024 bits
______________________________________________________________________

STEP 2: Generating X.509 certificate signing request [server.csr]
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.

Postfix 的 MX relay

user-pic
Vote 0 Votes

master.cf 裡面要有這一行
relay unix - - n - - smtp

in FreeBSD , 修改 /usr/local/sbin/thttpd_wrapper
加 -T big5

About this Archive

This page is an archive of entries in the Notes category from November 2003.

Notes: October 2003 is the previous archive.

Notes: December 2003 is the next archive.

Find recent content on the main index or look in the archives to find all content.

Monthly Archives