freebsd7.0 安装记录

##最小化安装FreeBSD7.0
##用sysinstall安装perl5.8.8、bash、ports和设置网络
##通过ssh登录
##添加用户web、svn、mysql
[root@fb7 /home/ximi]# su
[root@fb7 /home/ximi]# cd /usr/src/
[root@fb7 /usr/src]# ls
[root@fb7 /usr/src]# mkdir /usr/server
[root@fb7 /usr/src]# ln -s /usr/server/ /server
##安装mysql
[root@fb7 /usr/src]# fetch http://dev.mysql.com/get/Downloads/MySQL-5.0/mysql-5.0.51a.tar.gz/from/http://mirror.mysql-partners-jp.biz/
【freebsd7.0 安装记录】[root@fb7 /usr/src]# tar zxvf fetch.out
[root@fb7 /usr/src]# cd mysql-5.0.51a/
[root@fb7 /usr/src/mysql-5.0.51a]# ./configure --prefix=/server/mysql
[root@fb7 /usr/src/mysql-5.0.51a]# make
[root@fb7 /usr/src/mysql-5.0.51a]# make install
[root@fb7 /usr/src/mysql-5.0.51a]# cd /server/mysql/
#编辑/etc/my.cnf加入2行
basedir = /usr/local/mysql5
datadir = /home/mysql/data
[root@fb7 /server/mysql]# bin/mysql_install_db --user=mysql
[root@fb7 /server/mysql]# bin/mysqld_safe &
[root@fb7 /server/mysql]# bin/mysqladmin -u root passWord 'new password'
[root@fb7 /server/mysql]# cp share/mysql/mysql.server /usr/local/etc/rc.d/mysql.sh
##安装apache
[root@fb7 /usr/src]# ls /server
[root@fb7 /usr/src]# tar zxvf httpd-2.2.8.tar.gz
[root@fb7 /usr/src]# cd httpd-2.2.8
[root@fb7 /usr/src/httpd-2.2.8]# ./configure --prefix=/server/http --enable-so --enable-rewrite --enable-dav
[root@fb7 /usr/src/httpd-2.2.8]# make
[root@fb7 /usr/src/httpd-2.2.8]# make install
[root@fb7 /usr/src/httpd-2.2.8]# cp /server/http/bin/apachectl /usr/local/etc/rc.d/http.sh
##安装gd
[root@fb7 /usr/src]# pkg_add -r gd
##安装libxml2
[root@fb7 /usr/src]# pkg_add -r libxml2
##安装t1lib
[root@fb7 /home/ximi/src]# pkg_add -r t1lib
##安装ImageMagick
#安装对tiff
[root@fb7 /usr/src]# pkg_add -r tiff
[root@fb7 /usr/src]# fetch http://www.imagemagick.com.cn/download/ImageMagick-6.2.7-6.tar.gz
[root@fb7 /usr/src]# tar zxvf ImageMagick-6.2.7-6.tar.gz
[root@fb7 /usr/src]# cd ImageMagick-6.2.7
[root@fb7 /usr/src/ImageMagick-6.2.7]# ./configure --prefix=/server/ImageMagick
[root@fb7 /usr/src/ImageMagick-6.2.7]# make
[root@fb7 /usr/src/ImageMagick-6.2.7]# make install
##安装memcached
#安装必须libevent
[root@fb7 /usr/src]# pkg_add -r libevent
[root@fb7 /usr/src]# fetch http://www.danga.com/memcached/dist/memcached-1.2.5.tar.gz
[root@fb7 /usr/src]# tar zxvf memcached-1.2.5.tar.gz
[root@fb7 /usr/src]# cd memcached-1.2.5
[root@fb7 /usr/src/memcached-1.2.5]# ./configure --prefix=/server/memcached
[root@fb7 /usr/src/memcached-1.2.5]# make
[root@fb7 /usr/src/memcached-1.2.5]# make install
##安装subversion
#安装必须berkeley db
[root@fb7 /usr/src]# pkg_add -r db42
#安装必须apr-db42
[root@fb7 /usr/src]# pkg_add -r apr-db42
[root@fb7 /usr/src]# fetch http://subversion.tigris.org/downloads/subversion-1.4.6.tar.gz
[root@fb7 /usr/src]# tar zxvf subversion-1.4.6.tar.gz
[root@fb7 /usr/src]# cd subversion-1.4.6
[root@fb7 /usr/src/subversion-1.4.6]# ./configure --prefix=/server/svn --with-apxs=/server/http/bin/apxs
[root@fb7 /usr/src/subversion-1.4.6]# make
[root@fb7 /usr/src/subversion-1.4.6]# make install
##安装pdflib php扩展pdf必须
[root@fb7 /usr/src]# fetch http://www.pdflib.com/binarIEs/PDFlib/702/PDFlib-Lite-7.0.2p8.tar.gz
[root@fb7 /usr/src]# tar zxvf PDFlib-Lite-7.0.2p8.tar.gz
[root@fb7 /usr/src]# fetch http://www.pdflib.com/binaries/PDFlib/702/PDFlib-7.0.2-FreeBSD6.tar.gz
[root@fb7 /usr/src]# tar zxvf PDFlib-7.0.2-FreeBSD6.tar.gz
[root@fb7 /usr/src]# cp -r PDFlib-7.0.2-FreeBSD6/bind/c PDFlib-Lite-7.0.2p8/bind/
##安装autoconf 2.13创建php configure必须
[root@fb7 /usr/src/]# pkg_add -r autoconf213

推荐阅读