Tip: 看不到本站引用 Flickr 的图片? 下载 Firefox Access Flickr 插件 | AD: 订阅 DBA notes -- ![]()
2008-07-24 Thu
Shared by Fenng
希望有更多朋友看到 :)
作者:Fenng 发布在 dbanotes.net.
| 转载文章是对互联网的伤害
本月 26 日,也就是明天,QClub:当SOA遭遇现实 将如期在支付宝举行。
除了报名参加的杭州本地的众多技术精英,阿里集团各家子公司也都有人参加,淘宝、阿里软件、阿里妈妈都会有资深架构师到现场来。相信这回是一场精彩的思维碰撞,期待。
特邀嘉宾:支付宝首席架构师 程立(花名:鲁肃)
程立,支付宝(中国)网络技术有限公司。2004年开始参与淘宝网与支付宝系统的建设,2005年起进入支付宝,一直从事于互联网电子支付系统的研发工作。现任支付宝首席架构师,专注于电子支付系统的分布式服务架构与开放架构。
一说起 SOA 可能很多人会觉得比较"空",这也是我们举办会议的目的之一,"来点实在的技术信息" 是这次活动的一个宗旨。
会议地点
文三路、万塘路交汇处,华星时代广场 5 楼。大厅届时会有人指路
友情提示
为便于交流,请尽量携带名片 :)
--EOF--
相关文章|Related Articles
- Google 在中国的支付通道 - Sep 5, 2006
- 支付宝 Wordpress 捐赠插件 - Dec 5, 2006
- WordPress.com 的数据量 - Sep 11, 2007
- Fotolog.com 的技术信息拾零 - Sep 12, 2007
评论数量(0)|Add Comments
本文网址:http://www.dbanotes.net/arch/alipay_qclub.html
最近作者还说了什么? Follow Twitter / Fenng
DBA notes 理念: 用最简约的技术取得最大的收益!
作者:Fenng 发布在 dbanotes.net.
| 转载文章是对互联网的伤害
本月 26 日,也就是明天,QClub:当SOA遭遇现实 将如期在支付宝举行。
除了报名参加的杭州本地的众多技术精英,阿里集团各家子公司也都有人参加,淘宝、阿里软件、阿里妈妈都会有资深架构师到现场来。相信这回是一场精彩的思维碰撞,期待。
特邀嘉宾:支付宝首席架构师 程立(花名:鲁肃)
程立,支付宝(中国)网络技术有限公司。2004年开始参与淘宝网与支付宝系统的建设,2005年起进入支付宝,一直从事于互联网电子支付系统的研发工作。现任支付宝首席架构师,专注于电子支付系统的分布式服务架构与开放架构。
一说起 SOA 可能很多人会觉得比较"空",这也是我们举办会议的目的之一,"来点实在的技术信息" 是这次活动的一个宗旨。
会议地点
文三路、万塘路交汇处,华星时代广场 5 楼。大厅届时会有人指路
友情提示
为便于交流,请尽量携带名片 :)
--EOF--
相关文章|Related Articles
- Google 在中国的支付通道 - Sep 5, 2006
- 支付宝 Wordpress 捐赠插件 - Dec 5, 2006
- WordPress.com 的数据量 - Sep 11, 2007
- Fotolog.com 的技术信息拾零 - Sep 12, 2007
评论数量(0)|Add Comments
本文网址:http://www.dbanotes.net/arch/alipay_qclub.html
最近作者还说了什么? Follow Twitter / Fenng
DBA notes 理念: 用最简约的技术取得最大的收益!
作者:Fenng 发布在 dbanotes.net.
| 转载文章是对互联网的伤害
本月 26 日,也就是明天,QClub:当SOA遭遇现实 将如期在支付宝举行。
除了报名参加的杭州本地的众多技术精英,阿里集团各家子公司也都有人参加,淘宝、阿里软件、阿里妈妈都会有资深架构师到现场来。相信这回是一场精彩的思维碰撞,期待。
特邀嘉宾:支付宝首席架构师 程立(花名:鲁肃)
程立,支付宝(中国)网络技术有限公司。2004年开始参与淘宝网与支付宝系统的建设,2005年起进入支付宝,一直从事于互联网电子支付系统的研发工作。现任支付宝首席架构师,专注于电子支付系统的分布式服务架构与开放架构。
一说起 SOA 可能很多人会觉得比较"空",这也是我们举办会议的目的之一,"来点实在的技术信息" 是这次活动的一个宗旨。
会议地点
文三路、万塘路交汇处,华星时代广场 5 楼。大厅届时会有人指路
友情提示
为便于交流,请尽量携带名片 :)
--EOF--
相关文章|Related Articles
- Google 在中国的支付通道 - Sep 5, 2006
- 支付宝 Wordpress 捐赠插件 - Dec 5, 2006
- WordPress.com 的数据量 - Sep 11, 2007
- Fotolog.com 的技术信息拾零 - Sep 12, 2007
评论数量(0)|Add Comments
本文网址:http://www.dbanotes.net/arch/alipay_qclub.html
最近作者还说了什么? Follow Twitter / Fenng
DBA notes 理念: 用最简约的技术取得最大的收益!
其实青海有很多条线路可以筹划,包括入藏或者入甘肃,但是考虑到时间和目前本人半残的状态,还是计划了一条相对舒适的行程。
2008-7-25 晚上出发,北京飞西宁
从2008-7-26开始算正式的行程。
D1 塔尔寺(宿西宁),第一天算是休息调整的一天,毕竟进入海拔较高的地方需要适应一下。
D2 西宁 — 青海湖 — 都兰(宿都兰)
D3 科肖图景区(位于都兰县城西南40公里,海拔3600 - 4200米)(宿都兰)
D4 都兰 — 共和(宿共和)
倒淌河、日月山
D5 共和 — 玛多(宿玛多)
D6 鄂陵湖、扎陵湖(宿玛多)
D7 玛多 — 青海湖(宿青海湖,第二天看日出)
D8 青海湖 — 门源(百里油菜花海)– 西宁
D9 回京
以上行程按照实际情况应该还是会有调整的。出发前先畅想一下,希望能够看到下面这样的油菜花海。

Are you an Oracle-related blogger? Are you attending Oracle OpenWorld this year? If you answered yes to both questions, then you are invited to attend the yearly blogger meetup at the ThirstyBear Restaurant and Brewery, Tuesday September 23rd at 7:00 PM.
Mark Rittman has been the person organizing the blogger meetup events for the past few years. Mark passed the torch to me and I gladly volunteered to organize this year’s special event.
Like in 2007, OTN is sponsoring our get-together by establishing a tab at the bar, so there will complementary drinks and appetizers for a while (Thanks Justin, Vikki and Lillian).
If you would like to attend, make sure you RSVP on the event’s page on OracleCommunity.net.
See you…
---
Related Articles at Eddie Awad's Blog:
- Oracle OpenWorld Presentation Downloads
- Oracle OpenWorld 2007
- So Far at Oracle OpenWorld
- OK, I Will be There Too
- A Complimentary Oracle OpenWorld Session
As there were many requests for Debian binary packages in our announcement of MySQL releases with custom patchsets, we decided to play with it and built .deb, which you can find there:
http://www.mysqlperformanceblog.com/mysql/debian/
Also we have generic RPMs for x86-64 architecture:
http://www.mysqlperformanceblog.com/mysql/RPM/. They are based on .spec file provided in MySQL source tree and should be compatible with SuSe, CentOS and RedHat.
Your comments are welcome!
Entry posted by Vadim | 3 comments
Shared by shunz
睿智各有不同,但脑残基本一致!
A:这鸡蛋真难吃。
B:隔壁家那鸭蛋更难吃,你咋不说呢?
A:这鸡蛋真难吃。
B:请拿出建设性的意见来,有本事你下个好吃的蛋来。
A:这鸡蛋真难吃。
B:下蛋的是一只勤劳勇敢善良正直的鸡。
A:这鸡蛋真难吃。
B:比前年的蛋已经进步很多了。
A:这鸡蛋真难吃。
B:你就是吃这鸡蛋长大的,你有什么权力说这蛋不好吃?
A:这鸡蛋真难吃。
B:你这么说是什么居心什么目的?
拍脑门的功夫只想起这几种文法,以后如果想起了更多的再补充。
今天读了脑残文几篇,想了想,脑残文之所以让我反感,关键一点是文法太简单。大量的脑残文只是几种常见文法的简单变形和组合,一堆逻辑荒漠叠在一起,能不乏味吗。![]()
![]()
Below is the full text of the email AOL EVP Kevin Conroy sent out to staff on July 14, outlining the reorganization of his product groups and announcing the “sunsetting” of XDrive, AOL Pictures, MyMobile and Bluestring.
At the start of this year I committed to providing frequent updates on the state of our business and our plans going forward. Additionally I have said that we will continue to evaluate our product portfolio and discontinue projects when necessary in order to focus our resources in the right areas. In that spirit, I want to give you an update on the essentials project, an exercise we undertook to help our organization focus on the things that will most effectively contribute to the financial health of our company.
There was a time at AOL when the strengths of our aggregate portfolio of products more than compensated for the weakness of an underperforming product. The realities of the industry and market shifts in online advertising no longer make that possible. Simply put, every product makes a direct impact on our bottom line. With two quarters behind us, it is fair to say that results across the AOL products team have been mixed. And while I expect 2008 to finish stronger than it started, the current situation is that some of our products are doing very well while some continue to struggle. Being responsible to our company and its financial goals means taking a very hard and honest look at each of our products and making the tough business decisions necessary to ensure the long term viability of AOL.
The changes described below are in no way a reflection of the hard work and creativity of the people who built and maintain them.
- Personal Media: Bluestring, Xdrive and AOL Pictures will be sunset. These consumer storage products haven???t gained sufficient traction in the marketplace or the monetization levels necessary to offset the high cost of their operation. We have found that building media management applications within the context of a social experience is a more rapid and effective way to grow the business. For example, today the Bebo audience is uploading over three million photos per day. To effectively grow the XDrive online storage business we would need to focus on subscription revenues vs. monetizing through advertising revenue, and this business model is not in strategic alignment with our company???s goals. We are exploring plans to migrate our users assets to ensure the best possible transition experience.
- MyAOL will complete its HP deployments by the end of October and will transform the MyAOL platform from proprietary to industry open standards. The team will provide ongoing platform maintenance support for our 70 plus HP partner sites.
- Mobile: We have decided to halt further investment in AIMWorld and will sunset MyMobile next year in order to focus on our core revenue producing products (ie, mail, messaging, portal and mapping). Along with these core products we will focus on developing for key devices like the iPhone and the Blackberry. We will also leverage open services through OpenMobile to engage third party mobile developers in order to create new applications and experiences, which will expand distribution without additional internal development costs.
- Video Portal: The AOL Video Portal has seen significant success in growing organic search traffic to about 15 million SEO referrals per month. That said, there is an opportunity to align resources throughout the company and grow advertising revenue by merging the video portal with AOL Programming Video Experiences to deliver a higher value product inside of the AOL Programming channels. The work to merge the two products is currently ongoing and will be completed in early Q4.
We are also aggressively seeking revenue growth opportunities and have identified the following areas as opportunities:
- Toolbar: Accelerate the distribution and monetization of toolbars to drive revenue derived from search and recirculation.
- Desktop: Develop and launch desktop software promotion push to drive increased ROI through the acquisition of new free software users.
- Mail: Increase effective monetization of mail while pursuing distribution opportunities to grow audience and engagement. Drive growth though new ad inventory (Quigo, etc.), ad packaging and sales strategy development, affinity and cobranding partnerships and open services.
- Truveo: Monetize the over 50 million UVs Truveo receives monthly through our O&O site and APIs through a phased approach including banner advertising on the site and monetization of the APIs.
The plans we are putting into place strengthen our position in the industry and improve the finacial health of our business. The evaluation of our product is based on ongoing monthly reviews of each product???s progress compared to our 2008 goals and the market outlook. It is fact based, not arbitrary. It goes without saying that we are all working in a dynamic and challenging industry, but I firmly believe that we can succeed by focusing on reveue opportunities and managing our costs. I hope that you will continue to stay focused and deliver your best work as we strive to continue the transformation of our company.
Crunch Network: MobileCrunch Mobile Gadgets and Applications, Delivered Daily.
Here are my slides for the memcached presentation I gave at OSCON this year. I experimented with a new slide template, which turned out for the worst, since the contrast of the type on the screen was very poor, making it difficult for attendees to read. I apologize for this. In addition, I was completely distracted during my entire talk by loud music coming from the room next door. Nevertheless, the majority of my audience was still around even after I ran 5-10 minutes over schedule, eating into their free beer time, so I suppose that says something and that they were learning.
Thanks to all who attended!
Give Your Site a Boost With Memcache
Today’s high-traffic websites must implement performance-boosting measures that reduce data processing and reduce load on the database, while increasing the speed of content delivery. One such method is the use of a cache to temporarily store whole pages, database recordsets, large objects, and sessions. While many caching mechanisms exist, memcached provides one of the fastest and easiest-to-use caching servers. This talk will cover memcached and the memcache extension for PHP from setting up a memcached server to using it to provide a variety of caching solutions, including the use of memcached as a session data store.
Voice over Internet Protocol (VoIP) has emerged as a popular technology for modern voice communications. Many organizations have replaced their analog or proprietary digital telephone systems with VoIP-based solutions. This allows the consolidation of telephone services into an existing IP infrastructure. In addition, using IP to host voice services lets the organization leverage existing expertise–while retaining all of the network’s management advantages. Though not without its disadvantages, VoIP provides a compelling option to those looking for a telephone solution.
This article will present a simple VoIP solution using Asterisk, an open source private branch exchange (PBX) product. It will show you how to install Asterisk, configure it using its LDAP backend, and connect to it using the Ekiga software VoIP client and a Cisco 7900 Series VoIP telephone to make calls.
Prerequisites
- Important note about Asterisk:
- Asterisk 1.6 Beta 10 has not yet been released. This version will fix a bug in Asterisk’s realtime LDAP code that causes the server to crash. In the meantime, one may compile the upcoming realtime LDAP module and install it for use with Fedora’s packages. In order to do this, follow the following instructions after installing the Fedora Asterisk packages:
- Execute “yum install openldap-devel”
- Download the Asterisk 1.6 Beta 9 source from http://www.asterisk.org/ and extract it.
- Enter the resulting asterisk-1.6.0-beta9 directory.
- Apply the patch available at http://www.flyn.org/patches/asterisk-1.6.0-beta9-crashfix/asterisk-1.6.0-beta9-crashfix.patch.gz by downloading it and executing “gunzip -c PATH-TO-PATCH.gz | patch -p1″ from within the asterisk-1.6.0-beta9 directory.
- Execute “./configure –prefix=/usr –sysconf=/etc”
- Execute “make res”
- Execute “cp res/res_config_ldap.so /usr/lib/asterisk/modules/”
There are a few prerequisites to discuss before covering the configuration of Asterisk. First, my instructions assume that you have already installed Fedora 9. Second, you must have an existing LDAP server. The LDAP schema I use in this article is compatible with Fedora Directory Server. I recommend using the FreeIPA system to manage FDS. Fedora 9 provides packages for both FDS (fedora-ds-base) and FreeIPA (ipa-server). Finally, the machine hosting Asterisk must allow incoming UDP connections to ports 5060 (Session Initiation Protocol) and 69 (TFTP) to pass through its firewall.
- Note:
- In general, the LDAP database is optional. All configurations may be stored in flat files on the Asterisk server’s disk. However, I have chosen to store my Asterisk users and extensions in an LDAP database. This is beneficial for organizations that wish to consolidate user information in LDAP. In addition, Asterisk’s realtime LDAP backend is new to 1.6. I hope to help fill the gap in existing documentation with this article.
Install the Asterisk components by executing the command yum install asterisk asterisk-ldap asterisk-alsa asterisk-voicemail asterisk-voicemail-plain. In order to configure a Cisco 7900 Series VoIP telephone, you will also need to execute yum install tftp-server, have an existing DHCP server (the one on an inexpensive wireless router will work fine) and a copy of Cisco’s Session Initiation Protocol (SIP) software for the phone.
- Note:
- Depending on how you buy a Cisco telephone, you may need to purchase the rights to Cisco’s SIP software. Cisco telephones are typically sold with support for the proprietary SCCP protocol. In order to use the telephone with SIP, one must load a SIP flash image onto the telephone. This image may not have been included in the original telephone purchase. One way to obtain a license for the software is to purchase a Cisco SmartNet support package. Support for a 7900 Series telephone costs less than $10 and should be available from the vendor that sold you the telephone. I will cover installing the SIP software later in the article.
The Fedora project does not yet package Asterisk’s audio files because their copyright holder has not yet assigned a license to them (see Red Hat Bugzilla bug #428832). These audio files are required to implement features like an echo test and voicemail. Fortunately, it is quite simple to install them. Visit the Asterisk website and download the latest Asterisk 1.6 series release. Inside the Asterisk archive is another, sounds/asterisk-core-sounds-en-gsm-1.4.11.tar.gz. Extract this archive file into /usr/share/asterisk/sounds.
Configuring the Asterisk PBX
The Asterisk PBX has many features and is very flexible. In this section, I will focus on configuring four things: the SIP module, the extensions module, the external configuration engine, and the realtime LDAP backend. Once Asterisk is configured, I will demonstrate how to add SIP users and extensions to your LDAP database.
Asterisk provides a module to support the SIP protocol. SIP is used to set up and tear down a VoIP phone call. Though individual SIP users will be stored in an LDAP database, some global parameters will exist in the following configuration file. Save this configuration as /etc/asterisk/sip.conf:
[general] videosupport=yes allow=all bindaddr=0.0.0.0 realm=example.com
- videosupport
- Enable support for video streaming.
- allow
- List of CODEC’s to allow.
- bindaddr
- IP address of the device to bind to. 0.0.0.0 ensures that Asterisk will listen on all available network devices.
- realm
- The authentication realm.
We will now move on to define extensions. In many cases, an extension is simply a telephone number that will be associated with a SIP user. Individual extensions, like SIP users, will be stored in an
LDAP database. However, as with the SIP configuration, global parameters will be configured in a file,
/etc/asterisk/extensions.conf. The following example supports the LDAP entries I will use in this article:
[users] switch => Realtime/@ [demo] switch => Realtime/@ [default] include => users include => demo
This example defines three contexts: default, users, and demo. The line switch => Realtime/@ states that the extensions in a context will be defined using one of Asterisk’s realtime back-ends (in our case, LDAP). Each individual extension will be assigned to one of these contexts. As a collection of available extensions, contexts determine what happens when a user dials a phone number.
Asterisk’s external configuration engines are activated in /etc/asterisk/extconfig.conf. The following example configures Asterisk to pull SIP and extension information using its real-time LDAP back-end:
[settings] sipusers => ldap,"dc=example,dc=com",sip sippeers => ldap,"dc=example,dc=com",sip extensions => ldap,"dc=example,dc=com",extensions
This example causes Asterisk to activate its real-time LDAP back-end look for SIP users, SIP peers, and extensions in the LDAP database. In addition, the base DN used for queries is specified.
- Note:
- All of the examples in this article will use dc=example,dc=com as the LDAP database’s base DN. This should be replaced with your organization’s base DN.
The final configuration file we will write configures Asterisk’s real-time LDAP back-end and should be saved as /etc/asterisk/res_ldap.conf.
[_general] url=ldaps://ldap.example.com:636 protocol=3 basedn="dc=example,dc=com" user=cn=Directory Manager pass=LDAP-PASSWORD [config] additionalFilter=(objectClass=AstConfig) filename = AstConfigFilename category = AstConfigCategory variable_name = AstConfigVariableName variable_value = AstConfigVariableValue cat_metric = AstConfigCategoryMetric commented = AstConfigCommented [extensions] context = AstContext exten = AstExtension priority = AstPriority app = AstApplication appdata = AstApplicationData additionalFilter=(objectClass=AsteriskExtension) [sip] name = cn amaflags = AstAccountAMAFlags callgroup = AstAccountCallGroup callerid = AstAccountCallerID canreinvite = AstAccountCanReinvite context = AstAccountContext dtmfmode = AstAccountDTMFMode fromuser = AstAccountFromUser fromdomain = AstAccountFromDomain fullcontact = AstAccountFullContact host = AstAccountHost ipaddr = AstAccountIPAddress insecure = AstAccountInsecure mailbox = AstAccountMailbox md5secret = AstAccountRealmedPassword nat = AstAccountNAT deny = AstAccountDeny permit = AstAccountPermit pickupgroup = AstAccountPickupGroup port = AstAccountPort qualify = AstAccountQualify restrictcid = AstAccountRestrictCID rtptimeout = AstAccountRTPTimeout rtpholdtimeout = AstAccountRTPHoldTimeout type = AstAccountType disallow = AstAccountDisallowedCodec allow = AstAccountAllowedCodec MusicOnHold = AstAccountMusicOnHold regseconds = AstAccountExpirationTimestamp regcontext = AstAccountRegistrationContext regexten = AstAccountRegistrationExten CanCallForward = AstAccountCanCallForward defaultuser = AstAccountDefaultUser regserver = AstAccountRegistrationServer additionalFilter = (objectClass=AsteriskSIPUser)
The config, extensions, and sip sections of this file map Asterisk configuration options to LDAP attributes and do not need to be customized. The _general section contains the following options:
- url
- The URL pointing to the organization’s LDAP server. The example above uses LDAP over SSL on port 636.
- protocol
- The LDAP version to use.
- basedn
- The base DN used for queries.
- user
- The name of the LDAP administrator. Directory Manager is the name used by the Fedora Directory Server.
- pass
- The LDAP directory manager’s password.
Configuring LDAP
With the exception of actual users and extensions, our simple Asterisk installation is fully configured. We will now finish our installation by adding users and extensions to our LDAP database. First, we need to install an Asterisk schema for LDAP at /etc/dirsrv/slapd-DOMAIN/schema/99asterisk.ldif. After the schema has been installed, restart FDS using service dirsrv restart.
dn: cn=schema
#
attributeTypes: (
NAME 'AstContext'
DESC 'Asterisk Context'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstExtension'
DESC 'Asterisk Extension'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstPriority'
DESC 'Asterisk Priority'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstApplication'
DESC 'Asterisk Application'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstApplicationData'
DESC 'Asterisk Application Data'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountAMAFlags'
DESC 'Asterisk Account AMA Flags'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountCallerID'
DESC 'Asterisk Account CallerID'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountContext'
DESC 'Asterisk Account Context'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountMailbox'
DESC 'Asterisk Account Mailbox'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstMD5secret'
DESC 'Asterisk Account MD5 Secret'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountDeny'
DESC 'Asterisk Account Deny'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountPermit'
DESC 'Asterisk Account Permit'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountQualify'
DESC 'Asterisk Account Qualify'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountType'
DESC 'Asterisk Account Type'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountDisallowedCodec'
DESC 'Asterisk Account Disallowed Codec'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountExpirationTimestamp'
DESC 'Asterisk Account Allowed Codec'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountRegistrationContext'
DESC 'Asterisk Account AMA Flags'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountRegistrationExten'
DESC 'Asterisk Account AMA Flags'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountNoTransfer'
DESC 'Asterisk Account AMA Flags'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountCallGroup'
DESC 'Asterisk Account Call Group'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountCanReinvite'
DESC 'Asterisk Account Can Reinvite'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountDTMFMode'
DESC 'Asterisk Account DTMF Flags'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountFromUser'
DESC 'Asterisk Account From User'
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountFromDomain'
DESC 'Asterisk Account From Domain'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountFullContact'
DESC 'Asterisk Account Full Contact'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountHost'
DESC 'Asterisk Account Host'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountInsecure'
DESC 'Asterisk Account Insecure'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountNAT'
DESC 'Asterisk Account NAT'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountPickupGroup'
DESC 'Asterisk Account PickupGroup'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountPort'
DESC 'Asterisk Account Port'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountRestrictCID'
DESC 'Asterisk Restrict CallerID'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountRTPTimeout'
DESC 'Asterisk RTP Timeout'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountRTPHoldTimeout'
DESC 'Asterisk RTP Hold Timeout'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountRealmedPassword'
DESC 'Asterisk RTP Hold Timeout'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountAllowedCodec'
DESC 'Asterisk Account Allowed Codec'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountMusicOnHold'
DESC 'Asterisk Account Allowed Codec'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountCanCallForward'
DESC 'Asterisk Can CAll Forward'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountSecret'
DESC 'Asterisk Can CAll Forward'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountName'
DESC 'Asterisk Account Username'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstConfigFilename'
DESC 'Asterisk LDAP Configuration Filename'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstConfigCategory'
DESC 'Asterisk LDAP Configuration Category'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstConfigCategoryMetric'
DESC 'Asterisk LDAP Configuration Category Metric'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstConfigVariableName'
DESC 'Asterisk LDAP Configuration Variable Name'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstConfigVariableValue'
DESC 'Asterisk LDAP Configuration Variable Value'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstConfigCommented'
DESC 'Asterisk LDAP Configuration Commented'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountIPAddress'
DESC 'Asterisk Account IP Address'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountDefaultUser'
DESC 'Asterisk Account Default User'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstAccountRegistrationServer'
DESC 'Asterisk Account Registration Server'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
objectClasses: (
NAME 'AsteriskExtension'
DESC 'PBX Extension Information for Asterisk'
SUP top
AUXILIARY
MUST cn
MAY ( AstContext $ AstExtension $ AstPriority $ AstApplication
$ AstApplicationData )
)
#
objectClasses: (
NAME 'AsteriskIAXUser'
DESC 'IAX2 User information for Asterisk'
SUP AsteriskExtension
AUXILIARY
MUST cn
MAY ( AstAccountAMAFlags $ AstAccountCallerID $ AstAccountContext
$ AstAccountFullContact $ AstAccountHost $ AstAccountMailbox $ AstMD5secret
$ AstAccountDeny $ AstAccountPermit $ AstAccountPort $ AstAccountQualify
$ AstAccountType $ AstAccountDisallowedCodec $ AstAccountExpirationTimestamp
$ AstAccountRegistrationContext$ AstAccountRegistrationExten
$ AstAccountNoTransfer $ AstAccountName )
)
#
objectClasses: (
NAME 'AsteriskSIPUser'
DESC 'SIP User information for Asterisk'
SUP AsteriskExtension
AUXILIARY
MUST cn
MAY ( AstAccountAMAFlags $ AstAccountCallGroup $ AstAccountCallerID
$ AstAccountCanReinvite $ AstAccountContext $ AstAccountDefaultUser
$ AstAccountDTMFMode $ AstAccountFromUser $ AstAccountFromDomain
$ AstAccountFullContact $ AstAccountHost $ AstAccountInsecure
$ AstAccountIPAddress $ AstAccountMailbox $ AstAccountRealmedPassword
$ AstAccountNAT $ AstAccountDeny $ AstAccountPermit $ AstAccountPickupGroup
$ AstAccountPort $ AstAccountQualify $ AstAccountRestrictCID
$ AstAccountRTPTimeout $ AstAccountRTPHoldTimeout $ AstAccountType
$ AstAccountDisallowedCodec $ AstAccountAllowedCodec $ AstAccountMusicOnHold
$ AstAccountExpirationTimestamp $ AstAccountRegistrationContext
$ AstAccountRegistrationExten $ AstAccountRegistrationServer
$ AstAccountCanCallForward $ AstAccountSecret $ AstAccountName )
)
#
objectClasses: (
NAME 'AsteriskConfig'
DESC 'Asterisk configuration Information'
SUP top
AUXILIARY
MUST cn
MAY ( AstConfigFilename $ AstConfigCategory $ AstConfigCategoryMetric
$ AstConfigVariableName $ AstConfigVariableValue $ AstConfigCommented )
)
We may now create two SIP users, one for our Ekiga installation and the other for our Cisco telephone. If you write the following LDIF into a file, you may load it into the LDAP database using ldapadd -x -D "cn=Directory Manager" -W -f PATH-TO-LDIF.
dn: ou=sippeers,dc=example,dc=com
ou: sippeers
objectClass: top
objectClass: organizationalUnit
dn: cn=user1,ou=sippeers,dc=example,dc=com
objectClass: top
objectClass: AsteriskSIPUser
cn: user1
AstAccountCallerID: 2001
AstAccountHost: dynamic
AstAccountRealmedPassword: {MD5}a94775781e5bb7d3e4ec047c56f0acc5
AstAccountContext: default
AstAccountType: friend
dn: cn=user2,ou=sippeers,dc=example,dc=com
objectClass: top
objectClass: AsteriskSIPUser
cn: user2
AstAccountCallerID: 2002
AstAccountHost: dynamic
AstAccountRealmedPassword: {MD5}3c7806fa6e6c3416d57f2de223cdea5d
AstAccountContext: default
AstAccountType: friend
The example above defines a minimal SIP user. The attributes used are:
- cn
- The SIP user’s account name.
- AstAccountCallerID
- The user’s caller ID information.
- AstAccountHost
- The user’s host. The dynamic keyword allows a user’s telephone to dynamically register its IP address by logging into Asterisk.
- AstAccountRealmedPassword
- The account’s password. The hash of a user’s password may be generated by executing
echo -n "SIPUSER:example.com:PASSWORD" | md5sum - AstAccountContext
- The context this user will exist in. This determines which extension context applies to this user. Extension contexts were defined in
extensions.conf. - AstAccountType
- Defines the type of client. Asterisk sends calls to peers (i.e., a SIP provider). The user type may place calls only. Friends are both peers and users.
Once a user is defined, one may test Asterisk. Start the Asterisk service by executing service asterisk start as root. Execute an Asterisk shell using the command asterisk -rv. At Asterisk’s prompt, execute sip show peer user1 load. Asterisk should print all of the information for user1.
Once you have defined a user, you may start writing your dial plan. First, we will associate a phone number with each user. Use ldapadd to add the following to your LDAP database:
dn: ou=extensions,dc=example,dc=com ou: extensions objectClass: top objectClass: organizationalUnit dn: cn=2001-1,ou=extensions,dc=example,dc=com cn: 2001-1 objectClass: top objectClass: AsteriskExtension AstContext: users AstExtension: 2001 AstPriority: 1 AstApplication: Dial AstApplicationData: SIP/user1,20 dn: cn=2002-1,ou=extensions,dc=example,dc=com cn: 2002-1 objectClass: top objectClass: AsteriskExtension AstContext: users AstExtension: 2002 AstPriority: 1 AstApplication: Dial AstApplicationData: SIP/user2,20
- AstContext
- The context in which this extension exists.
- AstExtension
- The extension ID (e.g., what you dial to reach this extension).
- AstPriority
- Each extension can execute several commands when it receives a call. The priority determines the order in which commands are executed.
- AstApplication
- The command to execute when the extension receives a call. The command Dial connects to another Asterisk user.
- AstApplicationData
- Arguments, separated with commas (without spaces), and passed to a command. The
Dialhas two arguments. The first is the user that the call will be connected to. The second is the number of seconds to wait before quitting.
In order to facilitate testing our installation, we will define the following additional extension. This extension executes three commands to implement an echo test that may be reached by dialing ‘600.’
dn: cn=600-1,ou=extensions,dc=example,dc=com cn: 600-1 objectClass: top objectClass: AsteriskExtension AstContext: demo AstExtension: 600 AstPriority: 1 AstApplication: Playback AstApplicationData: demo-echotest dn: cn=600-2,ou=extensions,dc=example,dc=com cn: 600-2 objectClass: top objectClass: AsteriskExtension AstContext: demo AstExtension: 600 AstPriority: 2 AstApplication: Echo dn: cn=600-3,ou=extensions,dc=example,dc=com cn: 600-3 objectClass: top objectClass: AsteriskExtension AstContext: demo AstExtension: 600 AstPriority: 3 AstApplication: Playback AstApplicationData: demo-echodone
After schema edits, FDS must be restarted using service dirsrv restart.
The basic Asterisk configuration is now complete. Restart the Asterisk service using service asterisk restart.
Configuring the Ekiga VoIP client
Ekiga is a software VoIP application that supports SIP. Its configuration is straightforward. The first time Ekiga is executed by a user, it provides a wizard that allows one to configure the user’s full name,
ekiga.net account (this is not required for the purpose of this article), connection type, audio devices, and video devices. Once the software is configured, setup a SIP account by clicking on Edit→Accounts and selecting add. Figure 1 displays an account configured for our SIP user identified as user1.
After an account is set up, it must be activated. Figure 2 shows that the account I just configured is displayed in Ekiga’s list. Click the checkbox to activate the account.
Figure 3 shows Ekiga’s main interface window. Here, you can see how many accounts have been registered. In order to test your configuration, make a SIP connection to extension 600 and perform an echo test.
Configuring a Cisco VoIP telephone
As mentioned before, using a Cisco phone to connect to Asterisk using SIP requires Cisco’s SIP software. When a Cisco 7900 Series telephone boots, it will try to configure itself using TFTP. We will place some firmware and configuration files on our server so that the phone will boot properly for our installation.
In order to enable TFTP on the Asterisk server, edit /etc/xinetd.d/tftp and set disable to no. The TFTP daemon is configured on Fedora to serve files out of /var/lib/tftpboot. After you have modified its configuration, restart xinetd with the command service xinetd restart. Cisco’s SIP software package provides the files P0S3-08-2-00.sb2, P0S3-08-2-00.sbn and P0S3-08-2-00.loads. Copy these files to /var/lib/tftpboot.
- Note:
- The filenames used by your Cisco firmware may be slightly different. Cisco’s naming convention is P0S3-xxx-y-zz, where x is the major version, y is the minor version, and z is the subversion. P0S3 indicates SIP firmware, P003 indicates SCCP firmware, and P0M3 indicates MGCP firmware.
When booting SIP firmware, the telephone will look for three configuration files: OS79XX.TXT, SIPDefault.cnf, and SIPMAC-ADDRESS.cnf. These files should also
be placed in /var/lib/tftpboot.
OS79XX.TXT contains one line: the firmware version to load. Mine contains P0S3-08-2-00.
SIPDefault.cnf contains configurations common to all SIP telephones. The following example lists the image version and the address of our Asterisk server, and instructs the telephones to register with Asterisk:
image_version: P0S3-08-2-00 ; proxy1_address: 192.168.0.10 ; proxy_register: "1" ;
Per-telephone configurations are stored in a file named after the telephone’s MAC address. The telephone’s MAC address may be found in its configuration menu. This configuration will correspond with the SIP information found in LDAP and should be saved as SIPMAC-ADDRESS.cnf:
line1_name : user2 line1_authname : user2 line1_password : PLAINTEXT-PASSWORD
The first step in preparing the telephone is to clear any existing configuration. This may be done by pressing **# settings 3 to access an unlocked Network
Configuration menu. Here, find the Erase Configuration menu item and select it. Restart the phone and return to the Network Configuration menu. Ensure DHCP Enabled is set. Reboot the phone.
The phone will pull its network configuration from DHCP and should now respond to pings. Return to the Network Configuration menu and deactivate DHCP. Select the TFTP Server 1 option and set it to your Asterisk / TFTP server. Do not disable DHCP or manually set a TFTP server if your DHCP server provides your TFTP server’s IP address. Reboot the telephone and it should load the SIP software and configuration. As the phone boots, you may see it request files using TFTP by watching the Asterisk server’s /var/log/messages log.
Once the telephone boots, test its configuration by dialing 600. This will execute an echo test. After the echo test, you may make a Cisco telephone to Ekiga call by dialing 2001.
Configuring voicemail
In this section, we will cover configuring Asterisk to provide a voicemail system. The configuration process is similar to that of SIP users and extensions, so this should also serve to reinforce the techniques covered in those sections. We will configure the voicemail module, the external
configuration engine, and the real-time LDAP back-end. After the configuration files are setup, we will add information to the LDAP database.
/etc/asterisk/voicemail.conf is similar to sip.conf and
extensions.conf. This file configures the voicemail module. As with SIP users and extensions, we will configure global parameters in a file, leaving extension-specific parameters to be configured in LDAP:
[general] searchcontexts=yes
Add the following line to /etc/asterisk/extconfig.conf in order to activate the real-time LDAP back-end for voicemail:
voicemail => ldap,"dc=example,dc=com",voicemail
Map Asterisk voicemail configuration options to LDAP attributes by adding the following to /etc/asterisk/res_ldap.conf:
[voicemail] context = AstVMContext mailbox = AstVMMailbox password = AstVMPassword fullname = AstVMFullname email = AstVMEmail pager = AstVMPager tz = AstVMTz attach = AstVMAttach saycid = AstVMSaycid dialout = AstVMDialout callback = AstVMCallback review = AstVMReview operator = AstVMOperator envelope = AstVMEnvelope sayduration = AstVMSayduration saydurationm = AstVMSaydurationm sendvoicemail = AstVMSendvoicemail delete = AstVMDelete nextaftercmd = AstVMNextastercmd forcename = AstVMForcename forcegreetings = AstVMForcegreetings hidefromdir = AstVMHidefromdir stamp = AstVMStamp additionalFilter = (objectClass=AsteriskVoicemail)
Now we will move to updating our LDAP database. First, we must add to the LDAP schema that we installed earlier. The following will add support for the attributes required to provide basic voicemail:
attributeTypes: (
NAME 'AstVMMailbox'
DESC 'Asterisk Voicemail Mailbox'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstVMPassword'
DESC 'Asterisk Voicemail Password'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstVMFullname'
DESC 'Asterisk Voicemail Fullname'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
attributeTypes: (
NAME 'AstVMEmail'
DESC 'Asterisk Voicemail Email'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
)
#
objectClasses: (
NAME 'AsteriskVoicemail'
DESC 'Voicemail information for Asterisk'
SUP top
MUST cn
MAY ( AstContext $ AstVMMailbox $ AstVMPassword $ AstVMFullname
$ AstVMEmail )
)
Add the following LDIF to the LDAP database using ldapadd in order to add voicemail support for the extensions 2001 and 2002:
dn: ou=voicemail,dc=example,dc=com ou: voicemail objectClass: top objectClass: organizationalUnit dn: cn=2001,ou=voicemail,dc=example,dc=com cn: 2001 objectClass: top objectClass: AsteriskVoicemail AstContext: users AstVMMailbox: 2001 AstVMPassword: 1234 AstVMFullname: User 1 AstVMEmail: user1@example.org dn: cn=2002,ou=voicemail,dc=example,dc=com cn: 2002 objectClass: top objectClass: AsteriskVoicemail AstContext: users AstVMMailbox: 2002 AstVMPassword: 1234 AstVMFullname: User 2 AstVMEmail: user2@example.org dn: cn=2000-1,ou=extensions,dc=example,dc=com cn: 2000-1 objectClass: top objectClass: AsteriskExtension AstContext: users AstExtension: 2000 AstPriority: 1 AstApplication: Voicemailmain dn: cn=2001-2,ou=extensions,dc=example,dc=com cn: 2001-2 objectClass: top objectClass: AsteriskExtension AstContext: users AstExtension: 2001 AstPriority: 2 AstApplication: Voicemail AstApplicationData: 2001,u dn: cn=2002-2,ou=extensions,dc=example,dc=com cn: 2002-2 objectClass: top objectClass: AsteriskExtension AstContext: users AstExtension: 2002 AstPriority: 2 AstApplication: Voicemail AstApplicationData: 2002,u
The second entry defines a mailbox for extension 2001. It uses the following options:
- AstContext
- The context in which this mailbox exists.
- AstVMMailbox
- The extension that this mailbox corresponds to.
- AstVMPassword
- The password used to access the mailbox.
- AstVMFullname
- The full name of the mailbox owner.
- AstVMEmail
- The mailbox owner’s email address.
Entity four defines an extension, 2000, that will provide access to the voicemail system when dialed.
Entity five adds a command to extension 2001 that executes the Voicemail and provides access to the voicemail system. This command will execute if the Dial command defined earlier is not answered within 20 seconds.
To test the voicemail system, use Ekiga to dial 2002. If you don’t answer the call on the other end, then you should be directed to Asterisk’s voicemail system. To listen to new voicemail, dial 2000.
Conclusion
This article demonstrated how to install Asterisk on a Fedora system and configure SIP users, extensions, and voicemail. We installed all user data into an LDAP database in order to keep it consolidated.
Asterisk has far too many features to cover in one article. The VoIP Wiki has a section dedicated to Asterisk and is a great place to learn more. The VoIP Wiki covers topics such as hooking Asterisk up to the standard public-switched telephone network using direct inward dialing and automatically emailing voicemail messages to users. You can even find information on how to route calls to a user based on his Jabber presence. Clearly, Asterisk is capable of a wide range of applications. And, perhaps best of all, it’s entirely open source!
I could stay awake just 2 hear u breathing.
Watch u smile while u’re sleeping.
While u’re far away dreaming.
I could spend my life in this sweet surrender.
I could stay last in this moment forever.
Every moment spent with u is a moment i treasure.I don’t wanna close my eyes.
I don’t wanna fall asleep.
‘Cause i’d miss u, baby.
And i don’t wanna miss a thing.
’cause even when i dream of u.
The sweetest dream will never do.
I’d still miss u, baby.Lying close 2 u feeling Ur heart beating.
And i’m wondering what u’re dreaming.
Wondering if it’s me u’re seeking.
Then i kiss Ur eyes thank god we’re together.
And i just wanna stay with u.
In this moment forever, forever ever.I don’t wanna miss one smile.
I don’t wanna miss one kiss.
Well, i just wanna be with u.
Right here with u, just like this.
I just wanna hold u close.
Feel Ur heart so close 2 mine.
And just stay here in this moment.
For all the rest of time.Don’t wanna close my eyes.
Don’t wanna fall asleep, yeah
Don’t wanna miss a thing.
从某种意义上说,我们现在做的系统是在刚开始看来是苦不堪言的:一个总页面数量不超过两位数的web项目需要跟超过10个外部系统进行集成,集成的协议包括WebService In/Out(安全与非安全的)、FTP、Email、XML/XSD/XSL等等。然而5个月后第一个版本准备发布的时候,我们发现居然解决了大部分的集成问题(我们对此有准备并且,有最好的组员!)。在与第三方集成的过程中,与WebService、XSD等标准协议的集成相对比较容易,而与那些封闭协议则苦不堪言,耗费大量时间并且整个过程毫无乐趣可言。
例如,需要将PDF通过FTP发布到一个第三方网站。由于PDF不具备自描述特性,传输PDF的同时还需要传一个文本文件来描述这个PDF文件,例如作者是谁,出版时间等等。为了阐述这个文本文件的写法, 第三方系统提供了少则十多页,多则数个DOC文档、PPT演示等让我们学习如何使用这些API。研究和学习使用这种“土制”API充满了挫折感:再丰富的文档也不能涵盖开发的各个方面,通过自身系统的领域模型产生出这样的一个个文本文件的过程并不有趣——想象一下手写webservice文件的过程,更何况这些土制API完全没有规则可言,几乎类似于汇编。这些不是最严重的,更严重的是,对于开发者而言,这些知识——如果他们是知识的话——毫无价值。无论是这些API的维护方还是使用方,一旦转到其他的项目,这些耗费精力学习和掌握的东西立刻价值为零。
相对而言,采用WebService方式的要好的多。一个好的WebService接口明确定义了输入和输出类型。在简单的了解各个属性的业务含义后,开发阶段只需要跟WebService的WSDL交互,开发和测试都很容易。在支持开放标准的IDE帮助下,土制标准带来的无谓时间和精力损耗降到最低,利用开放标准带来的系统之间的耦合也随之降低。其他的,如XSD,也同样具备描述系统接口契约的能力,使用方也能够充分使用工具支持,来完成业务功能。
以前无数次听说开放标准会使系统造价更经济。现在看起来确实如此。观察我前一个项目,一个Outlook插件,运行在Outlook进程中的WPF Rich Client程序。微软乱糟糟的技术在Outlook中得到了集大成。由于对通信内部状态的未知,我们不得不写了很多的Hack方法来绕过各种限制,得到的恶果是严重的性能问题我们不得不推迟上线。痛定思痛,在下一个项目中坚决采用了Web技术,而通过iCalendar协议与Outlook交互。这种方式下,系统之间通过开放标准来隔离彼此的变化,两边的编程模型清晰而简单,没有无谓的猜测。
当然,很多时候我们不得不使用土制协议,如我们,使用的协议是使用了20多年的,要修改绝非一朝一夕的事情。对协议进行直接使用是很愚蠢的,采用接口隔离是一般的做法;另外,为QA提供一个对应的假的实现对于开发阶段的测试也会相当有帮助。
一些想法:
- 把应用往小而专的考虑比大的好。如果不能,说明分析不够。
- 一旦两个系统之间发生了两个以上的同类型交互,一定要警惕——如果他们不能合并到一起通过一个统一的API来交互,那么一定是你的分析出了问题。
- REST很好,但在古板的企业系统中,WebService、XSD带来的强类型的好处,甚至比Rest更好。
- 如果在你的系统中使用了非标准的协议,例如,我们的项目中使用了Buffalo, 那么请确保这个协议的使用范围被限制在某一个层次之内。Buffalo只是用在Service层与Web层之间的传输,在API的封装下几乎可以被忽略。良好的Service、Web分层结构使得Buffalo不那么重要,虽然实现上他确实很重要。
- 说服你的客户采用标准协议。如果不能,继续说服,直到说服为止。否则,惨的不仅仅是你自己,还包含客户。与非标准技术斗争很麻烦却一点挑战性也没有,对于程序员职业生涯而言更是毫无价值;而且在浪费客户的钱。
- 一旦项目被要求做微软系列产品的插件,在没有决定之前,尝试说服客户不要这么做;如果不能,那么做的越少越好;如果还不能(比如被要求在Outlook meeting面板画个新窗口之类),趁早想退路。
作者:d.c.b.a, 订阅AnySQL, Oracle数据库恢复及服务, Sybase恢复, 磁盘及RAID恢复
前几年在上海时, 一直想有一个招商银行信用卡的, 想使用招行的唯一原因是它的网上功能做得很好, 可是前后去办了两次, 周边的兄弟都一个一个办下来了, 就我一直没有办下来. 不知道是那个地方出问题了, 也许是我的RPWT. 所以一直没有机会体验信用卡消费是什么样的感觉. 早想租个独立的DreamHost空间, 也因为没有信用卡不好支付而搁置.
到杭州来后, 据说在现在这个公司, 办信用卡是没有办不下来的, 天天和很行有业务往来, 因此是公司的人员, 都能办下来的. 在办之前我还是怀疑, 是不是我真的有很不良的信用记录, 会被拒绝, 还特意告诉银行的人, 以前有两次没有办下来的经历. 银行的人也只能劝我试试吧.
办下来的当天, 就去吃饭刷卡了, 请了公司同事吃饭的, 第二天也去刷卡的, 请的淘宝的Ningoo吃牛排的. 随后周末去华联世纪买东西时, 也习惯于刷信用卡了. 用它花钱, 还真没有花钱的感觉, 没有拿出现金那么心痛. 因此第一个月就消费了2000元.
年费是不用交了, 已消费了8次了. 信用卡一定程度上是促进了消费, 就是不经意间让人去没有计划地花钱, 信用额度还真是不易给得过高. 现在人品没有问题了, 有信用卡了.
相关文章 | Related Artiles
我要留言(当前5)
发表日:2008/7/23
作者:长野雅广(Masahiro Nagano)
原文链接:http://gihyo.jp/dev/feature/01/memcached/0004
前几次的文章在这里:
- 第1次:http://tech.idv2.com/2008/07/10/memcached-001/
- 第2次:http://tech.idv2.com/2008/07/11/memcached-002/
- 第3次:http://tech.idv2.com/2008/07/16/memcached-003/
我是Mixi的长野。 第2次、 第3次 由前坂介绍了memcached的内部情况。本次不再介绍memcached的内部结构, 开始介绍memcached的分布式。
memcached的分布式
正如第1次中介绍的那样, memcached虽然称为“分布式”缓存服务器,但服务器端并没有“分布式”功能。 服务器端仅包括 第2次、 第3次 前坂介绍的内存存储功能,其实现非常简单。 至于memcached的分布式,则是完全由客户端程序库实现的。 这种分布式是memcached的最大特点。
memcached的分布式是什么意思?
这里多次使用了“分布式”这个词,但并未做详细解释。 现在开始简单地介绍一下其原理,各个客户端的实现基本相同。
下面假设memcached服务器有node1~node3三台, 应用程序要保存键名为“tokyo”“kanagawa”“chiba”“saitama”“gunma” 的数据。

图1 分布式简介:准备
首先向memcached中添加“tokyo”。将“tokyo”传给客户端程序库后, 客户端实现的算法就会根据“键”来决定保存数据的memcached服务器。 服务器选定后,即命令它保存“tokyo”及其值。

图2 分布式简介:添加时
同样,“kanagawa”“chiba”“saitama”“gunma”都是先选择服务器再保存。
接下来获取保存的数据。获取时也要将要获取的键“tokyo”传递给函数库。 函数库通过与数据保存时相同的算法,根据“键”选择服务器。 使用的算法相同,就能选中与保存时相同的服务器,然后发送get命令。 只要数据没有因为某些原因被删除,就能获得保存的值。

图3 分布式简介:获取时
这样,将不同的键保存到不同的服务器上,就实现了memcached的分布式。 memcached服务器增多后,键就会分散,即使一台memcached服务器发生故障 无法连接,也不会影响其他的缓存,系统依然能继续运行。
接下来介绍第1次 中提到的Perl客户端函数库Cache::Memcached实现的分布式方法。
Cache::Memcached的分布式方法
Perl的memcached客户端函数库Cache::Memcached是 memcached的作者Brad Fitzpatrick的作品,可以说是原装的函数库了。
该函数库实现了分布式功能,是memcached标准的分布式方法。
根据余数计算分散
Cache::Memcached的分布式方法简单来说,就是“根据服务器台数的余数进行分散”。 求得键的整数哈希值,再除以服务器台数,根据其余数来选择服务器。
下面将Cache::Memcached简化成以下的Perl脚本来进行说明。
use strict;
use warnings;
use String::CRC32;
my @nodes = ('node1','node2','node3');
my @keys = ('tokyo', 'kanagawa', 'chiba', 'saitama', 'gunma');
foreach my $key (@keys) {
my $crc = crc32($key); # CRC値
my $mod = $crc % ( $#nodes + 1 );
my $server = $nodes[ $mod ]; # 根据余数选择服务器
printf "%s => %s\n", $key, $server;
}
Cache::Memcached在求哈希值时使用了CRC。
首先求得字符串的CRC值,根据该值除以服务器节点数目得到的余数决定服务器。 上面的代码执行后输入以下结果:
tokyo => node2 kanagawa => node3 chiba => node2 saitama => node1 gunma => node1
根据该结果,“tokyo”分散到node2,“kanagawa”分散到node3等。 多说一句,当选择的服务器无法连接时,Cache::Memcached会将连接次数 添加到键之后,再次计算哈希值并尝试连接。这个动作称为rehash。 不希望rehash时可以在生成Cache::Memcached对象时指定“rehash => 0”选项。
根据余数计算分散的缺点
余数计算的方法简单,数据的分散性也相当优秀,但也有其缺点。 那就是当添加或移除服务器时,缓存重组的代价相当巨大。 添加服务器后,余数就会产生巨变,这样就无法获取与保存时相同的服务器, 从而影响缓存的命中率。用Perl写段代码来验证其代价。
use strict;
use warnings;
use String::CRC32;
my @nodes = @ARGV;
my @keys = ('a'..'z');
my %nodes;
foreach my $key ( @keys ) {
my $hash = crc32($key);
my $mod = $hash % ( $#nodes + 1 );
my $server = $nodes[ $mod ];
push @{ $nodes{ $server } }, $key;
}
foreach my $node ( sort keys %nodes ) {
printf "%s: %s\n", $node, join ",", @{ $nodes{$node} };
}
这段Perl脚本演示了将“a”到“z”的键保存到memcached并访问的情况。 将其保存为mod.pl并执行。
首先,当服务器只有三台时:
$ mod.pl node1 node2 nod3 node1: a,c,d,e,h,j,n,u,w,x node2: g,i,k,l,p,r,s,y node3: b,f,m,o,q,t,v,z
结果如上,node1保存a、c、d、e……,node2保存g、i、k……, 每台服务器都保存了8个到10个数据。
接下来增加一台memcached服务器。
$ mod.pl node1 node2 node3 node4 node1: d,f,m,o,t,v node2: b,i,k,p,r,y node3: e,g,l,n,u,w node4: a,c,h,j,q,s,x,z
添加了node4。可见,只有d、i、k、p、r、y命中了。像这样,添加节点后 键分散到的服务器会发生巨大变化。26个键中只有六个在访问原来的服务器, 其他的全都移到了其他服务器。命中率降低到23%。在Web应用程序中使用memcached时, 在添加memcached服务器的瞬间缓存效率会大幅度下降,负载会集中到数据库服务器上, 有可能会发生无法提供正常服务的情况。
mixi的Web应用程序运用中也有这个问题,导致无法添加memcached服务器。 但由于使用了新的分布式方法,现在可以轻而易举地添加memcached服务器了。 这种分布式方法称为 Consistent Hashing。
Consistent Hashing
关于Consistent Hashing的思想,mixi株式会社的开发blog等许多地方都介绍过, 这里只简单地说明一下。
Consistent Hashing的简单说明
Consistent Hashing如下所示:首先求出memcached服务器(节点)的哈希值, 并将其配置到0~232的圆(continuum)上。 然后用同样的方法求出存储数据的键的哈希值,并映射到圆上。 然后从数据映射到的位置开始顺时针查找,将数据保存到找到的第一个服务器上。 如果超过232仍然找不到服务器,就会保存到第一台memcached服务器上。

图4 Consistent Hashing:基本原理
从上图的状态中添加一台memcached服务器。余数分布式算法由于保存键的服务器会发生巨大变化 而影响缓存的命中率,但Consistent Hashing中,只有在continuum上增加服务器的地点逆时针方向的 第一台服务器上的键会受到影响。

图5 Consistent Hashing:添加服务器
因此,Consistent Hashing最大限度地抑制了键的重新分布。 而且,有的Consistent Hashing的实现方法还采用了虚拟节点的思想。 使用一般的hash函数的话,服务器的映射地点的分布非常不均匀。 因此,使用虚拟节点的思想,为每个物理节点(服务器) 在continuum上分配100~200个点。这样就能抑制分布不均匀, 最大限度地减小服务器增减时的缓存重新分布。
通过下文中介绍的使用Consistent Hashing算法的memcached客户端函数库进行测试的结果是, 由服务器台数(n)和增加的服务器台数(m)计算增加服务器后的命中率计算公式如下:
(1 - n/(n+m)) * 100
支持Consistent Hashing的函数库
本连载中多次介绍的Cache::Memcached虽然不支持Consistent Hashing, 但已有几个客户端函数库支持了这种新的分布式算法。 第一个支持Consistent Hashing和虚拟节点的memcached客户端函数库是 名为libketama的PHP库,由last.fm开发。
至于Perl客户端,连载的第1次 中介绍过的Cache::Memcached::Fast和Cache::Memcached::libmemcached支持 Consistent Hashing。
两者的接口都与Cache::Memcached几乎相同,如果正在使用Cache::Memcached, 那么就可以方便地替换过来。Cache::Memcached::Fast重新实现了libketama, 使用Consistent Hashing创建对象时可以指定ketama_points选项。
my $memcached = Cache::Memcached::Fast->new({
servers => ["192.168.0.1:11211","192.168.0.2:11211"],
ketama_points => 150
});
另外,Cache::Memcached::libmemcached 是一个使用了Brain Aker开发的C函数库libmemcached的Perl模块。 libmemcached本身支持几种分布式算法,也支持Consistent Hashing, 其Perl绑定也支持Consistent Hashing。
总结
本次介绍了memcached的分布式算法,主要有memcached的分布式是由客户端函数库实现, 以及高效率地分散数据的Consistent Hashing算法。下次将介绍mixi在memcached应用方面的一些经验, 和相关的兼容应用程序。
7月的天空似乎充满了幸福的味道。那边在不丹,经历了20年爱情长跑的梁朝伟和刘嘉玲终成眷属;这边在台湾,“代工之王”,鸿海董事长郭台铭与舞蹈老师曾馨莹也举行了文定之喜。
这位台湾科技首富的订婚仪式在台北君悦饭店低调举行,包括马英九在内的众多名流参加了郭台铭的订婚仪式。让人更为惊喜的是,在筵席上,郭台铭宣布将捐出个人九成的财产用于公益事业。
据台湾《联合报》报道,福布斯杂志上月曾估算郭台铭财富高达1800亿元(新台币),若按照此数字计算,如果郭台铭捐出九成财富,金额将超过1600亿元(合50亿美元)。
郭台铭是台湾科技首富,个人持有的鸿海股票高达71万余股,以鸿海22日收盘价150.5元计算,一股价值15万5000元,换算市值即超过千亿元。他光是持有的鸿海股票即可盖两座台北101大楼,或是购买15至20架“梦幻客机”波音787。 若加上其它个人持股,以及透过投资公司持有的财富,福布斯杂志最新估计,郭台铭财产总值达60亿美元,约合1800亿元台币,是台湾排名第三的富豪,仅次于国泰蔡宏图家族、王永庆。
郭台铭长年从事公益事业,早在以双亲名字成立永龄基金会前,便默默捐款行善多年,所有经费来自个人,受惠的艺文团体、社福单位、弱势儿童家庭数以千计。多年来,郭台铭慷慨捐资1700多万元,先后为家乡修建了"万芳桥"、"牛土路"、"富晋桥"、"葛万小学"、"富康新优果品示范园区",为家乡的经济社会发展做出贡献。
从1974年生产电视机塑料旋钮的小厂起家,经过三十多年的发展,郭台铭领导下的富士康已经成为全球IT、消费电子产品制造领域毋庸置疑的霸主。从上世纪90年代以来,富士康先后进入了连接器、电脑机壳和零部件、电脑整机、网络设备、手机、数码相机等众多领域,连年保持30%以上的增长率,并从2004年开始连续多年稳居全球最大EMS企业的宝座。

上周我们已经给大家介绍了我们对于web表单调查研究结果的第一部分。调研的主要目的是提供给凭直接来判断有效性的设计师和开发人员一些理论依据。我们也介绍了一些如何让web表单成为完美的友好用户界面的指导方针。
我们把更多关键表单单独开来(例如校验表单)从而关注注册表单。然后我们分别完成每个被选择网站的注册表单并且分析这些表单的设计方法。以下我们介绍这个研究的第二部分——关于100个流行网站web表单的调研结果。
请注意这个文章不是关于校验表单——那是另外一个讨论的话题,我们把它独立开来看待成一个即将要讨论的文章。我们要感谢Wufoo为我们提供构架来引导我们的调查。
3、表单的功能性
在研究的第一部分里,我们已经仔细考虑过注册链接和注册表单的布局和视觉表现形式。但是如果表单不能正常工作的话设计的多漂亮都没有用,表单完成率依然很低。让我们现在来考虑一下注册表单功能性的典型问题以及设计时的方式方法。
3.1.Hover,active,focus - 使用中的效果?
显然地,为了提高表单的完成率,设计师试图避免各种各样的分散因素,并且提供一个清晰明确并且简单的web表单。这就是为什么任何视觉效果需要非常适当地使用的本质原因。

- 84%的web表单没有任何种类的hover、active或者focus的效果。
- 16%使用非常细微的鼠标上移的效果。
3.2. 帮助,支持,工具技巧:静态还是动态的?
有时候,输入区域的标签不够明确,但是用户却需要足够理解才能提供这些信息。用户名适用哪些字符格式?密码的字符数限制是多少?提供的Email地址会不会自动变成登录名使用?
用户通过建议和技巧的帮助最小化地减少输入框重新考虑的次数。而且,没有比虽然输入的内容看上去完全正确,但是输入框却不接受的情况更恼怒的了。为了避免这个问题,设计师(通常)使用不引人注目但清晰的建议提示。

调查报告中57%的web表单只有 “静态”的帮助提示,这些帮助提示只是之前假定好的一些和用户有关的提示信息;这些提示被明显地放在输入框的旁边。10%的操作提示通常是在一些帮助图标被点击之后或者用户输入信息时才会出现的。
3.3.帮助,支持,操作提示:应该放在什么位置?
当在为用户提供帮助时,一定要确定帮助是简单地提示,并且可以方便地被找到和理解。这是确保用户通过帮助提示不犯错误地完成表单的决定性因素。为了达到这个目标,你需要知道用户希望这些帮助在什么地方出现。所以,这些帮助和提示通常被放在表单的什么位置呢?

如果帮助提示出现的话,它们会出现在…
- 在输入区域下面(57%)
- 在输入区域的右侧(26%)
- 在输入区域的上方(13%)
- 在输入区域的左侧(4%)
我们注意到提示信息直接放在输入框下方是一个强烈的趋势。通常这类帮助提示会有稍微不同的色彩,大部分情况比主要内容要浅一些。
3.4.输入确认:静态的还是Ajax动态?
去年一整年,很多网站为了和用户进行互动,看上去似乎确实充满了Ajax的应用,但Ajax在流行网站服务中仍然还没有设法达到临界点。令人惊讶的是,我们不能认清Ajax的趋势。用户在输入完所有信息点击提交按钮的“经典”确认技术依然比Javascript的实时确认要来的流行。
根据我们的研究:
- 30%的表单只在表单顶部显示一条错误信息。(没有提示哪个输入框有问题)
- 29%的表单会在输入框旁边提示相应的操作帮助(顶部没有提供错误信息)
- 25%的表单同时使用错误信息和输入框提示。
- 22%的表单利用Ajax的实时确认来进行提示。
- 14%利用Javascript的错误提醒。
- 1%的表单是用系统信息提醒,并且给出“后退”链接。
3.5.错误信息的设计
正如你所看到的,我们已经识别出6种不同类型的错误提示。显而易见,14%的表单仍旧使用Javascript错误窗口来传达问题(例如,YouSendIt, Mail.ru, Newsvine, Clipmarks, Yandex,看下面的截图),然而只有22%使用Ajax确认(通常用来确认用户名的有效性)。当然也显然的是没有一个网站是没有任何确认的。

Newsvine使用Javascript错误窗口来传达问题。
通常设计师试图报告错误的使用方法。a、在点击提交按钮之后显示错误信息;b、在视觉上高光“不正确”的输入框。第一种错误情况通常会作为一条信息在页面的顶部(表单之前)显示出来。第二种情况通常是把错误的输入框的边框色彩和输入的标签进行高光(大部分情况是红色的字体以及红色的背景色)。
有时候设计师合并两种技术并且利用输入区域高光错误信息的方法。例如,看一下Ning结合两种技术的注册表单(请看下面的截图)

通常,红色被用于标示错误;但是在这种情况下就没有必要了。当表单完成时,Tickspot, Mixx.com和 Furl使用黄色来表示遇到的问题。

不过,如果有任意一种色彩来表示注册成功的话,它应该就是绿色,97%的网站表示成功的视觉就是用绿色的。

3.6有必要确认Email吗?
只有18%的网站需要确认Email(例如,Odeo, Ning)。老实说,我们实在没有任何理由让用户重复输入email地址,毕竟用户能够看到他们输的是什么,因为email地址的区域不像是密码区域那样是以星状显示的,对吧?

3.7有必要去确认密码吗?
当用户看不到自己所输的内容(他们看到的是以星号代替的)时让他们确认输入感觉上是有理由的。但是很多网站为了缩短完成注册表单的时间而去掉二次确认的步骤。

72%的情况是有必要确认密码的,但是许多例如Facebook,Friendster,LinkedIn, Stumbleupon, Pownce 和 Twitter的网站都不要求确认密码。
3.8. 需要使用校验码吗?
如果校验码去掉的话用户肯定很开心,但是实际上校验码却是必要的,因为网站需要防止垃圾注册软件创建很多垃圾帐户,不然他们需要不停地在数据库中过滤掉这些账户。
根据我们的调查,
- 52%的网站没有使用校验码。
- 有39%的网站是不能在不刷新页面的情况下实时刷新校验码的,这个实在是在可用性上非常的糟糕的一件事。
但是我们还是不能看清注册表单是否需要校验码的趋势。任何情况下,如果你使用校验码,请确定它是易可读的,或者在不可读的情况用户可以实时刷新校验码的。一些网站没有提供实时刷新校验码的功能,除了Digg,AOL, Slashdot, Google等。Fm倒是能够让校验码变成可以听的,当它很难被识别的时候。
3.9.需要使用取消按钮吗?
当我们在思考设计表单时一些认为会碰到的问题时,我们期望注册表单没有取消按钮,因为毕竟所有选项都已经填写好了,对于用户来讲就没有太大的意义去退出这个表单。然而我们在一定程度上错了。
只有8%的情况使用了取消按钮,这些情况中的一些取消按钮正好出现在“条款和协议”的下面(例如,Zoho Writer)。所以如果用户不同意服务条款,他们会退出这个流程。另一方面,一些服务在注册之前给出了一个支付方案(例如,Crazyegg)。在这种情况下用户选择错了支付方案时他们需要利用取消按钮返回并重新选择另外更好的支付方案。

除此以外:我们还是不明白为什么Dzone要把取消按钮放在注册表单的左侧。
如果使用取消按钮的话,有4%的情况是放在提交按钮的右侧。在这些网站中观察发现,取消和提交按钮没有非常强烈的视觉区别,而且还被挨在一起。从可用性观点上去看,把主要动作和次要动作用视觉区分开来并且用明确的空隙去区别它们是更有意义的。
3.10. 提交按钮的对齐方式
考虑到表单的样式,把提交按钮左对齐、右对齐或者放在中间是有实际意义的。有56%的设计师把提交按钮左对齐,第二位是26%的把按钮居中对齐。

右对齐的提交按钮依然比较流行(17%),但是一般都是起到需要进行下一步操作时的指示作用。在这些情况中提交按钮经常是以“继续”或者“下一步”为标题的。理由是:通常桌面软件中的“下一步”按钮就是放在右侧的。
3.11. 感谢信息
几年前,大多数服务在成功注册之后会提供一个简单,基础的感谢信息(通常还带有一个登录的链接),现在大多数站点都试图去激发用户立刻探索一下他们的服务。
- 45%的网站要求用户在完成注册之后提供更多的信息,在他们的网站上找到自己的朋友,或者邀请用户的朋友来使用他们的网站。
- 33%的表单会用友好并具有吸引力的语气指出 “接下来要去地方”(网站功能的探索)。
- 4%的网站提供了一个基础的“谢谢你”的消息。
- 2%是直接跳转到首页。
更多的发现
- 99%的案例中都是用到标签索引(除了Habrahabr)
- 24%的表单使用谈话式的语气,试图通过标示的对话达到用户所需。在这种环境中通常使用类似“你叫什么?”,“你的Email请告诉我一下?”或者“我想要……”等非









