Chinaunix首页 | 论坛 | 博客
  • 博客访问: 506850
  • 博文数量: 106
  • 博客积分: 1707
  • 博客等级: 上尉
  • 技术积分: 1109
  • 用 户 组: 普通用户
  • 注册时间: 2009-11-16 11:24
个人简介

从事互联网开发、运营、设计、运维等工作。偏爱底层开发,服务器运维

文章分类

全部博文(106)

文章存档

2016年(3)

2015年(6)

2014年(5)

2013年(11)

2012年(8)

2011年(8)

2010年(34)

2009年(31)

分类: 系统运维

2012-11-30 14:52:22

一、Ports Tree更新

1、配置更新服务器地址

shell>vi /etc/portsnap.conf

SERVERNAME=portsnap.cn.FreeBSD.org

2、首次获取Ports

shell>portsnap fetch extract

3、更新Ports

shell>portsnap fetch update

 

二、以root用户SSH(不建议)

1、修改配置文件

shell>vi /etc/ssh/sshd_config

#PermitRootLogin no修改为PermitRootLogin yes

#PasswordAuthentication no修改为PasswordAuthentication yes

#PermitEmptyPasswords no修改为PermitEmptyPasswords no

2、配置生效

shell>/etc/rc.d/sshd reload

三、加速make下载

1、增加配置文件

shell>vi /etc/make.conf

MASTER_SITE_BACKUP?=\
    {DIST_SUBDIR}/\
    ftp://ftp.cn.freebsd.org/pub/FreeBSD/ports/distfiles/${DICT_SUBDIR}/\
    ftp://freebsd.csie.nctu.edu.tw/pub/FreeBSD/ports/distfiles/${DICT_SUBDIR}/\
    ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/${DICT_SUBDIR}

MASTER_SITE_OVERRIDE?=${MASTER_SITE_BACKUP}

2、安装wget

shell>cd /usr/ports/ftp/wget/

shell>make install clean

3、修改配置文件

shell>vi /etc/make.conf

FETCH_CMD=wget
FETCH_BEFORE_ARGS=-c -t 1
FETCH_AFTER_ARGS=
DISABLE_SIZE=yes

MASTER_SITE_BACKUP?=\
    {DIST_SUBDIR}/\
    ftp://ftp.cn.freebsd.org/pub/FreeBSD/ports/distfiles/${DICT_SUBDIR}/\
    ftp://freebsd.csie.nctu.edu.tw/pub/FreeBSD/ports/distfiles/${DICT_SUBDIR}/\
    ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/${DICT_SUBDIR}

MASTER_SITE_OVERRIDE?=${MASTER_SITE_BACKUP}

阅读(1659) | 评论(0) | 转发(1) |
给主人留下些什么吧!~~