2010年11月6日 星期六

LDAP

(早期的筆記)
Type:  System V - launched service
Packages:  openldap { -client,  -servers}
Daemons:  slapd, slurpd
Script: ldap
Ports:  389 (ldap)
Config:  /etc/openldap/*
/var/lib/ldap/*

2010年11月3日 星期三

NIS

(早期的筆記)

Type:  System V - launched service

Packages:  ypserv, ypbind, yp-tools

Daemons:  ypserv, ypbind, rpc.yppasswdd

Script:  ypserv, ypbind,  yppasswdd

Ports:  111 (portmap) (rpc)

Config:  /etc/yp.conf,  /var/yp/*
/etc/nsswitch.conf
/etc/sysconfig/network

2010年10月19日 星期二

Samba Server

(早期的筆記)

Type:  System  V - Launched Service

Packages:  samba { -common,  -client}

Daemons:  nmbd,  smbd

Script:  smb

Ports:  137, 138, 139

Config:  /etc/samba/smb.conf

2010年8月5日 星期四

Sendmail Server

(早期的筆記)

Type:  System  V - Launched  Daemon

Packages:  sendmail [ -cf,  -doc}

Daemons:  sendmail

Script:  sendmail

Ports:  25(smtp)

Config:  /etc/sendmail.cf,  /etc/aliases,  /etc/mail/*,  /usr/share/sendmail-cf/

2010年7月6日 星期二

webalizer網頁流量統計設定

webalizer是一個不錯的網頁流量統計程式, Red Hat Linux系統好像預設都有附, 也有支援Windows
官網: http://www.webalizer.org/

以下為之前架網站時所裝的webalizer
webalizer首頁(年瀏覽率)
從Apache log檔抓資料來進行統計
以月為單位將每日的log檔轉換成柱狀圖的統計, 方便分析
月瀏覽率
日瀏覽率

還能將瀏覽者IP解析

設定檔: webalizer.conf
指令 webalizer /var/log/httpd/access_log
解析IP webalizer -c webalizer.conf -N 10 -D dns_cache.db /var/log/httpd/access_log
再加入排程就能自動更新

2010年7月5日 星期一

使用Apache的目錄驗證 (加密目錄)

在設定檔 httpd.conf 中

以 DocumentRoot 目錄為例
<Directory "/var/www/html">
AllowOverride None 改為 AllowOverride All
</Directory>

另外於目錄中建立 .htaccess 檔
AuthUserFile .htpasswd   用戶帳號密碼文件名(建議放置不同位置)
AuthName "加密的目錄"  畫面提示文字
AuthType Basic                 驗證方式
require valid-user             密碼驗證方式

建立 .htpasswd 檔
htpasswd -c -m /var/www/.htpasswd(密碼文件名) user(登入名稱)
-c: 建立檔案
-m: 使用md5加密

2010年7月4日 星期日

Apache Server

(早期的筆記)
Type:  System  V - Launched Service
Packages:  apache  { -devel,  -manual }
Daemons:  httpd
Script:  httpd
Ports:  80(http),  443(https)
Config:  /etc/httpd/*,   /var/www/*

2010年5月21日 星期五

DNS client設定

(早期的筆記)
/etc/resolv.conf
/etc/hosts
/etc/hostname
/etc/sysconfig/network-scripts/ifcfg-eth0 網卡設定加入Name Server
設定完 restart  network

2010年5月20日 星期四

DNS Server (bind)

(早期的筆記)

Type: System V - Launched Daemon

Packages: bind, bind-utils

Daemons: named

Script: named

Ports: 53  tcp、udp

Configs: /etc/named.conf,   /var/named/*

2010年5月19日 星期三

System V - Launched Daemons

(早期的筆記)

/etc/init.d/"_____"  start, stop, restart, status...

service "_____" start, stop, restart, status...

chkconfig  "_____"  --list

chkconfig  "_____"  on

chkconfig  "_____"  off

2010年1月13日 星期三

MySQL匯入時的錯誤 #1064

MySQL更新到5.5以後匯入資料庫時會出現如下錯誤

#1064 : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'TYPE=MyISAM' at line 1

原因出在於 TYPE=MyISAM

將 TYPE=MyISAM 全部替換成 ENGINE=MyISAM 就好了

2010年1月4日 星期一