2009年4月23日 星期四

無法在ACER M461(ICH9) 安裝CO 5.3 的解決方式

INTEL ICH9 的SATA chipset 在CO 5.3 中還是無法認得, 所以使用光碟安裝時會找不到device 來安裝.

解決方式: 目前使用網路安裝可以順利將CO 5.3 給裝起來

使用 FTP安裝
ftp site: ftp.twaren.net
path: Linux/CentOS/5.3/os/x86_64

2009年4月20日 星期一

CentOS 5.1 更新不知的套件後出現的錯誤

sudo: symbol lookup error: sudo: undefined symbol: audit_log_user_command

解決方式: 更新 audit 函式庫
yum update audit-libs

2009年1月20日 星期二

32 bit RAM over 4GB

以前總是認為在32位元的作業系統下記憶體最多只能到4GB, 不料前幾日在安裝CO5.2 時卻發現儘然可以支援超過4GB 的RAM.

透過PAE (Physical Address Extensions) 的方法就可以在32位元的作業系統上使用4G以上的RAM 了.

http://www.cyberciti.biz/tips/redhat-enterprise-linux-4gb-plus-ram-support.html

2008年10月28日 星期二

quote and unquote 應用


#!/bin/python
#coding: utf-8
# -*- coding: utf-8 -*-
import urllib

str = "測試utf8 編解碼"
str_en = urllib.quote(str).encode('utf-8')
print str_en
print urllib.unquote(str_en)
codeing 指定本文編碼

其他應用
from urllib import quote, unquote

input = u"http://test.net/~admin"
input = input.encode('utf8')
print quote(input) # http%3A//test.net/%7Eadmin
print quote(input, '') # http%3A%2F%2Ftest.net%2F%7Eadmin
print quote(input, '~/') # http%3A//test.net/~admin

2008年10月22日 星期三

取得使用者最後登入日期及密碼最後更改日期

last 使用者名稱 | head -n 1

chage -l 使用者名稱