最近宿舍使用树莓派心得一二

使用vpn连接校网:

1.绑定静态ip地址

http://service.chinasinew.com/

2.安装vpn,下源码包

http://www.cc98.org/dispbbs.asp?boardID=212&ID=2323871&page=1

3.配置帐号密码,或用以下脚本

http://pan.baidu.com/s/1qWr2w7y

 

 

编译树莓派内核:

参考文章:

http://blog.csdn.net/jinzheng_2010/article/details/8676213

注意:

下载内核代码时git clone一直会断开,那就去网页下zip,

下完将其放入linux后用jar xvf解压,否则编译会出现错误。

备份树莓派镜像2014-12:

http://pan.baidu.com/s/1pJ9LtKf

备份我的源码3.12.25:(可编译)配合前面的镜像中的config才行

http://pan.baidu.com/s/1jG89Atg

备份config.gz,3.12.25版

http://pan.baidu.com/s/11yvt8

备份RpiTools,我使用的是64位的交叉编译工具

http://pan.baidu.com/s/1kTzKfAZ

PATH=$PATH:~/build_pi/RpiTools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin

 

 

配置Exim4发送邮件:

apt-get install exim4

自动配置:

dpkg-reconfigure exim4-config

使用smarthost发信

(1)将配置文档拆分成小文件么? 否

(2)选择“用smarthost发信;无本地邮件”

(3)系统邮件名称,raspberrypi

(4)要监听的入站 SMTP 连接的 IP 地址:127.0.0.1 (这样,就只有本机可以利用exim4)

(5)其它可接受的邮件目的地址:(empty)

(6)为这些主机进行邮件转发:(empty)

(7)负责处理从本机寄出的邮件的机器(smarthost):真正用来外发邮件的smtp地址(我这里用smtp.qq.com)

(8)保持最小DNS 查询量吗(按需拔号 Dial-on-Demand)? 否

(9)或者直接修改文件/etc/exim4/update-exim4.conf.conf内容如下:

# /etc/exim4/update-exim4.conf.conf
#
# Edit this file and /etc/mailname by hand and execute update-exim4.conf
# yourself or use 'dpkg-reconfigure exim4-config'
#
# Please note that this is _not_ a dpkg-conffile and that automatic changes
# to this file might happen. The code handling this will honor your local
# changes, so this is usually fine, but will break local schemes that mess
# around with multiple versions of the file.
#
# update-exim4.conf uses this file to determine variable values to generate
# exim configuration macros for the configuration file.
#
# Most settings found in here do have corresponding questions in the
# Debconf configuration, but not all of them.
#
# This is a Debian specific file

dc_eximconfig_configtype='smarthost'
dc_other_hostnames='raspberrypi'
dc_local_interfaces='127.0.0.1'
dc_readhost=''
dc_relay_domains=''
dc_minimaldns='false'
dc_relay_nets=''
dc_smarthost='smtp.qq.com'
CFILEMODE='644'
dc_use_split_config='false'
dc_hide_mailname='false'
dc_mailname_in_oh='true'
dc_localdelivery='mail_spool'

其余设置(重要!)

(1)/etc/exim4/passwd.client,smtp的帐号密码设置

# password file used when the local exim is authenticating to a remote
# host as a client.
#
# see exim4_passwd_client(5) for more documentation
#
# Example:
### target.mail.server.example:login:password
smtp.qq.com:QQ号:QQ密码

(2)/etc/email-addresses,系统邮箱地址(如不填写,则会报错:用户名必须与发件用户相同)

# This is /etc/email-addresses. It is part of the exim package
#
# This file contains email addresses to use for outgoing mail. Any local
# part not in here will be qualified by the system domain as normal.
#
# It should contain lines of the form:
#
#user: someone@isp.com
#otheruser: someoneelse@anotherisp.com
root: qq@qq.com 

(3)log文件cat /var/log/exim4/mainlog,调试时使用

(4)清空邮件,cat /var/mail/mail

exim -bpru | awk {'print $3'} | xargs exim -Mrm

 

树莓派的时区和网络对时!

1.安装ntp,输入 

sudo apt-get install ntpdate

2.修改时区,输入

tzselect 

3.按照自己的时区修改

4.确认选择

TZ='Asia/Shanghai'; export TZ

5.配置网络对时,输入 

sudo ntpdate cn.pool.ntp.org

 

 

 

 Sun Feb  1 17:54:48 CST 2015

 

 CST:China Standard Time 中国标准时间(北京时间) UTC 8:00

posted @ 2015-01-31 20:28  Ю詺菛╀時代  阅读(802)  评论(0编辑  收藏  举报