There are generally two ways to install software in
Description:
FreeBSD:
(i), using Pk_add-r Package To install the software, package installed a compiled binary package, package the path of the default download package is in/var/db/pkg
(ii), using ports to compile the installation, ports is the download source to the local, To perform a compilation installation, the ports package path is in/usr/ports
The above two installation methods need to download the software package from the network, the default is to download the package from the official source, the speed is slow, You can modify the configuration file to specify a domestic mirror source to quickly install the software
1, modify pcakage source to 163 mirror source
setenv packagesite http://mirrors.163.com/FreeBSD/releases/i386/8.1-RELEASE/packages/Latest/
Pkg_add-r Package #package为要安装的软件名
2, install ports source
portsnap Fetch- s portsnap.cn.freebsd.org #安装ports
ee/etc/portsnap.conf #编辑文件
servername=portsnap.cn.freebsd.org #更改服务器为国内镜像
Press ESC to enter and press A to save
Portsnap Fetch extract #下载ports快照
Portsnap update #更新
ee/etc/make.conf #编辑文件, add the following code
master_site_backup?=http://mirrors.163.com/freebsd/distfiles/${dist_subdir}/
Master_site_override?=${master_site_backup}
cd /usr/ports
Make search name=nginx #查找ports中是否有nginx这个软件
cd /usr/ports/www/nginx #进入软件包目录
Make install clean #安装
Make deinstall clean #卸载
make deinstall reinstall clean #升级
Source system Operation Dimension osyunwei.com