Hunter的大杂烩 技术学习笔记

2012-11-21

ESMTP记录

Filed under: 技术话题 — hunter @ 7:20 pm

http://www.rosoo.net/a/201106/14594.html

3.2.  ESMTP

ESMTP最显著的地方是添加了用户认证功能。如果用户想使用ESMTP提供的新命令,则在初次与服务器交互时,发送的命令应该是EHLO而不是HELO。先来看一个例子。

C:telnet smtp.126.com 25   /* 以telnet方式连接126邮件服务器 */

S:220 126.com Anti-spam GT for Coremail System (126com[071018]) /* 220为响应数字,其后的为欢迎信息,会应服务器不同而不同*/

C:EHLO smtp.126.com /* 除了HELO所具有的功能外,EHLO主要用来查询服务器支持的扩充功能 */

S:250-mail

S:250-AUTH LOGIN PLAIN

S:250-AUTH=LOGIN PLAIN

(more…)

exchange2010取消smtp验证

Filed under: 技术话题 — hunter @ 7:18 pm

内网exchange经常被用来发送报警邮件,esmtp协议过于复杂,小型组织内,可以简单取消exchage的邮箱认证来实现:

1. 进入exchange管理控制台

(more…)

2012-11-15

rpm 几个命令

Filed under: 技术话题 — hunter @ 7:50 pm

rpm -qpi 查看未安装的rpm信息 ,如 rpm -qpi kernel-default-2.6.32.59-0.7.1.x86_64.rpm
Name        : kernel-default               Relocations: (not relocatable)
Version     : 2.6.32.59                         Vendor: SUSE LINUX Products GmbH, Nuernberg, Germany
Release     : 0.7.1                         Build Date: Sun Jul 15 02:02:35 2012
Install Date: (not installed)               Build Host: acamar
Group       : System/Kernel                 Source RPM: kernel-default-2.6.32.59-0.7.1.nosrc.rpm
Size        : 71488024                         License: GPL v2 only
Signature   : RSA/8, Sun Jul 15 02:06:03 2012, Key ID e3a5c360307e3d54
Packager    : http://bugs.opensuse.org
URL         : http://www.kernel.org/
Summary     : The Standard Kernel
Description :
The standard kernel for both uniprocessor and multiprocessor systems.

Source Timestamp: 2012-07-13 15:50:56 +0200
GIT Revision: a8f988783941e968c09cfb4df071a0959dd8ddf4
GIT Branch: SLE11-SP1
Distribution: SUSE Linux Enterprise 11

(more…)

2012-11-13

sql-bench-insert-test ssd vs harddisk

Filed under: 技术话题 — hunter @ 5:42 pm

harddisk

Generating random keys
Creating tables
Inserting 10000 rows in order
Inserting 10000 rows in reverse order
Inserting 10000 rows in random order
Time for insert (30000): 1111 wallclock secs ( 1.51 usr  0.46 sys +  0.00 cusr  0.00 csys =  1.97 CPU)
Testing update of keys with functions
Time for update_of_key (5000):  110 wallclock secs ( 0.17 usr  0.06 sys +  0.00 cusr  0.00 csys =  0.23 CPU)
Time for update_of_key_big (480): 41 wallclock secs ( 0.03 usr  0.01 sys +  0.00 cusr  0.00 csys =  0.04 CPU)

Testing update with key
Time for update_with_key (30000):  773 wallclock secs ( 1.18 usr  0.41 sys +  0.00 cusr  0.00 csys =  1.59 CPU)
Time for update_with_key_prefix (10000):  240 wallclock secs ( 0.79 usr  0.16 sys +  0.00 cusr  0.00 csys =  0.95 CPU)
(more…)

测试Mysql 使用 SSD硬盘

Filed under: 技术话题 — hunter @ 5:36 pm

最近SSD硬盘价格大幅下跌,128G只需要500 (http://item.51buy.com/item-265823.html),已经达到心理价位了。

SSD硬盘的优势是随机读写速度高于传统硬盘(传统硬盘的优势是顺序读写),最大的缺点是写次数有限制,所以在配置mysql时,需要把binlog与datadir分离:

其中/data目录是传统硬盘,放binlog

/data2是SSD硬盘

[mysqld]
datadir=/data2/mysql
basedir=/usr/local/mysql
log-bin=/data/applog/mysql/mysql-bin

log-slow-queries=/data/applog/mysql/slow.log

innodb_data_home_dir = /data2/mysql
innodb_data_file_path = ibdata1:200M;ibdata2:100M:autoextend
innodb_log_group_home_dir= /data/applog/mysql/
(more…)

« Newer PostsOlder Posts »

Powered by WordPress