<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-37910476</id><updated>2012-02-13T14:34:51.173+08:00</updated><category term='apache'/><category term='dell'/><category term='Company'/><category term='linux VPS'/><category term='mail'/><category term='mysql'/><category term='opensuse'/><category term='books'/><category term='security'/><category term='工作'/><category term='Server'/><category term='virtual'/><category term='linux Admin'/><category term='监控'/><category term='使用技巧'/><title type='text'>Linux的企业级应用</title><subtitle type='html'>致力于Linux在企业中的应用, LAMP, Mail, Cluster等架构,(ENterprise Linux Apache MySQL Php)</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>97</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-37910476.post-3991871430195115947</id><published>2012-02-13T14:32:00.001+08:00</published><updated>2012-02-13T14:34:51.180+08:00</updated><title type='text'>My New home</title><content type='html'>&lt;a href="http://www.linuxdict.com"&gt;http://www.linuxdict.com&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;新站&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.linuxdict.com"&gt;http://www.linuxdict.com&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-3991871430195115947?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/3991871430195115947/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=3991871430195115947' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3991871430195115947'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3991871430195115947'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2012/02/my-new-home.html' title='My New home'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-399256115885649670</id><published>2009-12-13T11:14:00.000+08:00</published><updated>2009-12-13T11:17:13.834+08:00</updated><title type='text'>How To Relay Email On A Postfix Server</title><content type='html'>Introduction&lt;br /&gt;For two small businesses I set up a debian lenny installation on their "home" dsl connection. The problem is that they have dynamic ip addresses and most mailservers will not accept incoming mail from a server on a dynamic ip address. The solution is rather simple. Set up postfix in a way that it will relay the outgoing email through the actual ISP. In this short howto I'll show you how to do that.&lt;br /&gt;&lt;br /&gt;1. Prerequisites&lt;br /&gt;I assume that you already have set up a working postfix server and that you have an email account at your ISP which you can access. So you will need to have a login for your IPS's email account.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;2. Edit the postfix config&lt;br /&gt;First you need to edit your postfix config...&lt;br /&gt;&lt;br /&gt;nano /etc/postfix/main.cf&lt;br /&gt;&lt;br /&gt;... and add the following code at the end of your config:&lt;br /&gt;&lt;br /&gt;smtp_sasl_auth_enable = yes&lt;br /&gt;smtp_sasl_security_options = noanonymous&lt;br /&gt;smtp_sasl_password_maps = hash:/etc/postfix/saslpasswd&lt;br /&gt;smtp_always_send_ehlo = yes&lt;br /&gt;relayhost = smtp.yourisp.com&lt;br /&gt;Of course replace smtp.yourisp.com with the actual smtp server of your ISP. Also SASL must be working. If you followed the perfect howtos for setting up a server as provided by Falko then you don't have to worry about it. Then save and close the file.&lt;br /&gt;&lt;br /&gt;If your ISP requires you to use a special port for sending email, then use a line like this instead:&lt;br /&gt;&lt;br /&gt;relayhost = [smtp.yourisp.com]:PORT&lt;br /&gt;In one of the cases that I have used this, I had to enter this:&lt;br /&gt;&lt;br /&gt;relayhost = [smtpauth.bluewin.ch]:587&lt;br /&gt; &lt;br /&gt;&lt;br /&gt;3. Edit /etc/postfix/saslpasswd&lt;br /&gt;After having extended the postfix config you'll still need to add the credentials to the /etc/postfix/saslpasswd file, so that you can authorize yourself at your ISP.&lt;br /&gt;&lt;br /&gt;nano /etc/postfix/saslpasswd&lt;br /&gt;&lt;br /&gt;and then add this:&lt;br /&gt;&lt;br /&gt;smtp.yourisp.com     yourlogin:yourpassword&lt;br /&gt;Of course replace yourlogin / yourpassword with the actual username and password provided by your ISP. You don't need to add the port there.&lt;br /&gt;&lt;br /&gt; &lt;br /&gt;&lt;br /&gt;4. Hash /etc/postfix/saslpasswd&lt;br /&gt;Before postfix can use that file, it needs to be hashed by postmap:&lt;br /&gt;&lt;br /&gt;postmap /etc/postfix/saslpasswd&lt;br /&gt;&lt;br /&gt;5. Restart postfix&lt;br /&gt;&lt;br /&gt;Finally you need to restart postfix to use the new config:&lt;br /&gt;&lt;br /&gt;/etc/init.d/postfix restart&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-399256115885649670?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/399256115885649670/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=399256115885649670' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/399256115885649670'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/399256115885649670'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/12/how-to-relay-email-on-postfix-server.html' title='How To Relay Email On A Postfix Server'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7192480593907658240</id><published>2009-04-14T11:52:00.002+08:00</published><updated>2009-04-14T14:12:06.477+08:00</updated><title type='text'>telnet 25/110测试mail服务器</title><content type='html'>&lt;span style="font-style:italic;"&gt;telnet test.com 25&lt;/span&gt;&lt;br /&gt;R: 220 SU-SCORE.ARPA Simple Mail Transfer Service Ready&lt;br /&gt;S: HELO MIT-MC.ARPA&lt;br /&gt;R: 250 SU-SCORE.ARPA&lt;br /&gt;S: VRFY Crispin&lt;br /&gt;R: 250 Mark Crispin&lt;br /&gt;S: SEND FROM:&lt;br /&gt;R: 250 OK&lt;br /&gt;S: RCPT TO:&lt;br /&gt;R: 250 OK&lt;br /&gt;&lt;br /&gt;S: DATA&lt;br /&gt;R: 354 Start mail input; end with .&lt;br /&gt;S: Blah blah blah...&lt;br /&gt;S: ...etc. etc. etc.&lt;br /&gt;S: .&lt;br /&gt;R: 250 OK&lt;br /&gt;S: QUIT&lt;br /&gt;R: 221 SU-SCORE.ARPA Service closing transmission channel&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style:italic;"&gt;&lt;br /&gt;telnet test.com 110&lt;/span&gt;&lt;br /&gt;POP3 Commands:&lt;br /&gt;&lt;br /&gt;USER name valid in the AUTHORIZATION state&lt;br /&gt;PASS string&lt;br /&gt;QUIT&lt;br /&gt;&lt;br /&gt;STAT valid in the TRANSACTION state&lt;br /&gt;LIST [msg]&lt;br /&gt;RETR msg&lt;br /&gt;DELE msg&lt;br /&gt;NOOP&lt;br /&gt;RSET&lt;br /&gt;QUIT&lt;br /&gt;&lt;br /&gt;Optional POP3 Commands:&lt;br /&gt;&lt;br /&gt;APOP name digest valid in the AUTHORIZATION state&lt;br /&gt;&lt;br /&gt;TOP msg n valid in the TRANSACTION state&lt;br /&gt;UIDL [msg]&lt;br /&gt;&lt;br /&gt;POP3 Replies:&lt;br /&gt;+OK&lt;br /&gt;-ERR&lt;br /&gt;&lt;br /&gt;More Details&lt;br /&gt;http://www.ietf.org/rfc/rfc1939.txt&lt;br /&gt;http://www.ietf.org/rfc/rfc0821.txt&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7192480593907658240?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7192480593907658240/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7192480593907658240' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7192480593907658240'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7192480593907658240'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/04/telnet-25110mail.html' title='telnet 25/110测试mail服务器'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8188995863173524793</id><published>2009-04-10T10:06:00.002+08:00</published><updated>2009-04-10T10:12:04.707+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='监控'/><title type='text'>zabbix系统监控首选</title><content type='html'>最近研究了一下zabbix，它在监控上确实做得很不错&lt;br /&gt;&lt;br /&gt;可以监控一下内容。&lt;br /&gt;system.localtime&lt;br /&gt;system.run 远程执行系统命令&lt;br /&gt;web.page.get[localhost,,80]&lt;br /&gt;Date:&lt;br /&gt;Server:&lt;br /&gt;Last-Modified:&lt;br /&gt;ETag:&lt;br /&gt;Accept-Ranges:&lt;br /&gt;Content-Length:&lt;br /&gt;Vary:&lt;br /&gt;Connection:&lt;br /&gt;Content-Type:&lt;br /&gt;web.page.perf[localhost,,80]&lt;br /&gt;web.page.regexp[localhost,,80,OK]&lt;br /&gt;vfs.file.exists[/etc/passwd]&lt;br /&gt;vfs.file.time[/etc/passwd,modify]&lt;br /&gt;vfs.file.size[/etc/passwd]&lt;br /&gt;vfs.file.regexp[/etc/passwd,root]&lt;br /&gt;vfs.file.regmatch[/etc/passwd,root] 搜索文件中内容&lt;br /&gt;vfs.file.cksum[/etc/passwd]&lt;br /&gt;vfs.file.md5sum[/etc/passwd]&lt;br /&gt;net.tcp.dns[127.0.0.1,localhost]&lt;br /&gt;net.tcp.port[,80]&lt;br /&gt;system.hostname&lt;br /&gt;system.uname&lt;br /&gt;system.users.num&lt;br /&gt;log[logfile]&lt;br /&gt;eventlog[system]&lt;br /&gt;kernel.maxfiles&lt;br /&gt;kernel.maxproc&lt;br /&gt;&lt;br /&gt;文件系统监控&lt;br /&gt;vfs.fs.size[/,free]&lt;br /&gt;vfs.fs.inode[/,free]&lt;br /&gt;vfs.dev.read[sda,operations]&lt;br /&gt;vfs.dev.write[sda,sectors]&lt;br /&gt;net.tcp.listen[80]&lt;br /&gt;&lt;br /&gt;网络流量监控&lt;br /&gt;net.if.in[lo,bytes]&lt;br /&gt;net.if.out[lo,bytes]&lt;br /&gt;net.if.total[lo,bytes]&lt;br /&gt;net.if.collisions[lo]&lt;br /&gt;&lt;br /&gt;CPU/内存使用监控&lt;br /&gt;vm.memory.size[total]&lt;br /&gt;proc.num[inetd,,,]&lt;br /&gt;proc.mem[inetd,,]&lt;br /&gt;system.cpu.switches&lt;br /&gt;system.cpu.intr&lt;br /&gt;system.cpu.util[all,user,avg1]&lt;br /&gt;system.cpu.load[all,avg1]&lt;br /&gt;system.cpu.num[online]&lt;br /&gt;system.swap.size[all,free]&lt;br /&gt;system.swap.in[all]&lt;br /&gt;system.swap.out[all]&lt;br /&gt;system.uptime&lt;br /&gt;system.boottime&lt;br /&gt;&lt;br /&gt;服务监控&lt;br /&gt;net.tcp.service[ssh,127.0.0.1,22]&lt;br /&gt;net.tcp.service.perf[ssh,127.0.0.1,22]&lt;br /&gt;&lt;br /&gt;推荐Linux系统管理员使用&lt;br /&gt;&lt;br /&gt;网址：http://www.zabbix.com/&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8188995863173524793?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8188995863173524793/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8188995863173524793' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8188995863173524793'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8188995863173524793'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/04/zabbix.html' title='zabbix系统监控首选'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8705205255468552091</id><published>2009-04-07T16:41:00.002+08:00</published><updated>2009-04-07T16:45:06.766+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux Admin'/><title type='text'>自动部署之Puppet</title><content type='html'>Puppet在自动部署上是一个很不错的选择，可以定义不同的节点。&lt;br /&gt;并且在不同节点上进行各种操作，包括软件安装，配置文件修改，服务管理等&lt;br /&gt;&lt;br /&gt;具体参考：&lt;br /&gt;http://www.howtoforge.com/installing_puppet_on_ubuntu&lt;br /&gt;&lt;br /&gt;更多应用：&lt;br /&gt;http://reductivelabs.com/trac/puppet&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8705205255468552091?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8705205255468552091/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8705205255468552091' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8705205255468552091'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8705205255468552091'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/04/puppet.html' title='自动部署之Puppet'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8946892563110999622</id><published>2009-03-24T11:04:00.003+08:00</published><updated>2009-03-24T11:12:42.998+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='virtual'/><title type='text'>VirtualBox的主机访问客户机</title><content type='html'>以前用Vmware从宿主访问客户机没有问题，可是VirtualBox就有问题。&lt;br /&gt;因为Vmware它自己创建一套内网，所以用Host Interface是可以内外访问都没问题&lt;br /&gt;&lt;br /&gt;现在一直用Virtualbox＋OpenVZ,Virtualbox主要是运行XP，很少用来运行CentOS或者Fedora等&lt;br /&gt;OpenVZ基本上够测试Centos用了，也没怎么叨咕。今天因为要从宿主访问客户机。&lt;br /&gt;&lt;br /&gt;网上查到一个方案，就是创建一个虚拟网络，模拟Vmware的方法。&lt;br /&gt;&lt;br /&gt;http://wandering.blog.51cto.com/467932/103994&lt;br /&gt;&lt;br /&gt;成功访问。以后可以“告别”Vmware了。记得前一阵子用Vmware Server是免费的了。&lt;br /&gt;反正以前在Windows下用都是要收费的。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8946892563110999622?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8946892563110999622/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8946892563110999622' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8946892563110999622'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8946892563110999622'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/03/virtualbox.html' title='VirtualBox的主机访问客户机'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-2925887563098434392</id><published>2009-02-27T16:08:00.000+08:00</published><updated>2009-03-12T16:10:44.306+08:00</updated><title type='text'>MySQL生产中Tips</title><content type='html'>1、my.cnf的检查工具&lt;br /&gt;&lt;a href="http://jeremy.zawodny.com/mysql/mytop/"&gt;mytop&lt;/a&gt; &lt;a href="http://hackmysql.com/mysqlreport"&gt;mysqlreport&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;2、允许mysql query caches&lt;br /&gt;&lt;br /&gt;3、Optimize tables 的效果比服务器调整更好一点，如果不能确定优化对象，启动slow query log&lt;br /&gt;&lt;br /&gt;4、my.cnf参数调优&lt;br /&gt;key_buffer = 20%-50% Physical Ram&lt;br /&gt;du -sh */*.MYI 检查index的大小，可以作为决定key_buffer大小的依据&lt;br /&gt;&lt;br /&gt;5、调整服务器参数&lt;br /&gt;set global key_buffer_size=128*1024*1024 (即128M)&lt;br /&gt;可直接生效&lt;br /&gt;修改my.cnf&lt;br /&gt;下次启动后生效&lt;br /&gt;&lt;br /&gt;5、&lt;a href="http://www.linux-mag.com/id/924"&gt;更多&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-2925887563098434392?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/2925887563098434392/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=2925887563098434392' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2925887563098434392'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2925887563098434392'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/02/mysqltips.html' title='MySQL生产中Tips'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-1346202725202567205</id><published>2009-02-26T16:10:00.000+08:00</published><updated>2009-03-12T16:11:26.579+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mysql'/><title type='text'>MySQL Replication Tips</title><content type='html'>MySQL的Replication已经很成熟了。下面总结一下生产中的一些小技巧&lt;br /&gt;&lt;br /&gt;1、从Master上来过滤一些数据库，即忽略test,scratch数据库，不进行Rep&lt;br /&gt;binlog-ignore-db=test,scratch&lt;br /&gt;或者&lt;br /&gt;binlog-ignore-db=test&lt;br /&gt;binlog-ignore-db=scratch&lt;br /&gt;&lt;br /&gt;2、如果只想同步某一或几个数据库，可以只制定需要Repl的数据库名&lt;br /&gt;binlog-do-db=catalog&lt;br /&gt;binlog-do-db=users&lt;br /&gt;binlog-do-db=sessions&lt;br /&gt;&lt;br /&gt;3、如果某些SQL语句导致Repl出现问题，可以使用如下方法：&lt;br /&gt;SET GLOBAL SQL_SLAVE_SKIP_COUNTER = 1;&lt;br /&gt;SLAVE START SQL_THREAD;&lt;br /&gt;&lt;br /&gt;4、从Slaves上过滤数据库，只同步某一些数据库（users）。&lt;br /&gt;replicate-do-db=users&lt;br /&gt;阻止temporary数据库同步的设置方法：&lt;br /&gt;replicate-ignore-db=temporary&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-1346202725202567205?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/1346202725202567205/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=1346202725202567205' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1346202725202567205'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1346202725202567205'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/02/mysql-replication-tips.html' title='MySQL Replication Tips'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-302234619295880876</id><published>2009-02-25T16:13:00.000+08:00</published><updated>2009-03-12T16:14:38.667+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='security'/><title type='text'>TripWire-系统完整性检查工具</title><content type='html'>今晚看iptables的书的时候，看到TripWire，以前也看过。但是没怎么注意&lt;br /&gt;正好做了一下实验&lt;br /&gt;http://sourceforge.net/projects/tripwire/&lt;br /&gt;下载安装&lt;br /&gt;wget http://nchc.dl.sourceforge.net/sourceforge/tripwire/tripwire-2.4.1.2-src.tar.bz2&lt;br /&gt;tar xvf tripwire-2.4.1.2-src.tar.bz2&lt;br /&gt;cd tripwire-2.4.1.2-src&lt;br /&gt;./configure –prefix=/srv/tripwire &amp;&amp; make &amp;&amp; make install&lt;br /&gt;&lt;br /&gt;初始化数据库&lt;br /&gt;/srv/tripwire/sbin/tripwire -m i&lt;br /&gt;检测某个软件的完整性&lt;br /&gt;/srv/tripwire/sbin/tripwire -m c&lt;br /&gt;e.g. sudo /srv/tripwire/sbin/tripwire -m c /bin/echo&lt;br /&gt;Integrity checking objects specified on command line…&lt;br /&gt;……..&lt;br /&gt;Total objects scanned: 1&lt;br /&gt;Total violations found: 0&lt;br /&gt;……..&lt;br /&gt;&lt;br /&gt;具体用法：&lt;br /&gt;Database Initialization: tripwire [-m i|--init] [options]&lt;br /&gt;Integrity Checking: tripwire [-m c|--check] [object1 [object2...]]&lt;br /&gt;Database Update: tripwire [-m u|--update]&lt;br /&gt;Policy Update: tripwire [-m p|--update-policy] policyfile.txt&lt;br /&gt;Test: tripwire [-m t|--test] –email address&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-302234619295880876?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/302234619295880876/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=302234619295880876' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/302234619295880876'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/302234619295880876'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/02/tripwire.html' title='TripWire-系统完整性检查工具'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-5218957458141215827</id><published>2009-02-25T16:12:00.000+08:00</published><updated>2009-03-12T16:13:19.486+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='books'/><title type='text'>《大道至简》小感</title><content type='html'>看了3天，当时在公司内部论坛看到的。虽然自己不是编程人员。呵呵&lt;br /&gt;&lt;br /&gt;感觉讲了很多道的东西，看不是很懂，但是也有不少收获。&lt;br /&gt;他讲了好几个故事，也看了相关典故。我从一个系统的侧面感触一些东西。&lt;br /&gt;&lt;br /&gt;作者虽然是在讲编程的道，但是很多东西也是解决问题的过程。&lt;br /&gt;编程何尝不是解决问题的过程的，从学的不好的编程到项目到软件工程&lt;br /&gt;从小到达，一种系统的管理和解决问题的思考。&lt;br /&gt;&lt;br /&gt;值得有志成为项目经理的程序员一读，不管从以后的开发上还是管理上感觉都&lt;br /&gt;会有不少的收获。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-5218957458141215827?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/5218957458141215827/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=5218957458141215827' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5218957458141215827'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5218957458141215827'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/02/blog-post.html' title='《大道至简》小感'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-816326671751599127</id><published>2009-02-22T11:19:00.000+08:00</published><updated>2009-03-12T16:20:18.005+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux VPS'/><title type='text'>OpenVZ on F8</title><content type='html'>我的系统是fedora8&lt;br /&gt;&lt;br /&gt;关于openvz的安装：&lt;br /&gt;&lt;br /&gt;1.第一步我们为了要安装openvz呢，我们需要把openvz的数据库添加到yum中：&lt;br /&gt;&lt;br /&gt;cd /etc/yum.repos.d&lt;br /&gt;&lt;br /&gt;wget http://download.openvz.org/openvz.repo&lt;br /&gt;&lt;br /&gt;rpm –import http://download.openvz.org/RPM-GPG-Key-OpenVZ&lt;br /&gt;&lt;br /&gt;2.在安装时要选择适合你的数据库：&lt;br /&gt;&lt;br /&gt;yum search ovzkernel&lt;br /&gt;&lt;br /&gt;然后安装它yum install ovzkernel……&lt;br /&gt;&lt;br /&gt;3.为了在系统开启时选择正确的内核我们修改一下启动是的名称：&lt;br /&gt;&lt;br /&gt;vi /etc/grub/grub.conf&lt;br /&gt;&lt;br /&gt;修改这个文件哦&lt;br /&gt;&lt;br /&gt;default=0&lt;br /&gt;&lt;br /&gt;timeout=5&lt;br /&gt;&lt;br /&gt;splashimage=(hd0,0)/boot/grub/splash.xpm.gz&lt;br /&gt;&lt;br /&gt;hiddenmenu&lt;br /&gt;&lt;br /&gt;title Fedora OpenVZ (2.6.18-92.1.18.el5.028stab060.2)&lt;br /&gt;&lt;br /&gt;root (hd0,0)&lt;br /&gt;&lt;br /&gt;kernel /boot/vmlinuz-2.6.18-92.1.18.el5.028stab060.2 ro root=LABEL=/ rhgb quiet acpi=force apm=power-off&lt;br /&gt;&lt;br /&gt;initrd /boot/initrd-2.6.18-92.1.18.el5.028stab060.2.img&lt;br /&gt;&lt;br /&gt;4.安装一些openvz的工具：&lt;br /&gt;&lt;br /&gt;yum install vzctl vzquota&lt;br /&gt;&lt;br /&gt;5.打开sysctl.conf文件设置一些参数：&lt;br /&gt;&lt;br /&gt;vi /etc/sysctl.conf&lt;br /&gt;&lt;br /&gt;net.ipv4.ip_forward = 1 (这个东东我们老大说没有设置是不会上网的哦)&lt;br /&gt;net.ipv4.conf.default.proxy_arp = 0&lt;br /&gt;net.ipv4.conf.all.rp_filter = 1&lt;br /&gt;kernel.sysrq = 1&lt;br /&gt;net.ipv4.conf.default.send_redirects = 1&lt;br /&gt;net.ipv4.conf.all.send_redirects = 0&lt;br /&gt;net.ipv4.icmp_echo_ignore_broadcasts=1&lt;br /&gt;net.ipv4.conf.default.forwarding=1&lt;br /&gt;&lt;br /&gt;6.接着运行sysctl -p 在修改/etc/vz/vz.conf文件使neigthbour_devs=all&lt;br /&gt;&lt;br /&gt;7.需要把selinux给禁用了，&lt;br /&gt;&lt;br /&gt;vi /etc/sysconfig/selinux&lt;br /&gt;&lt;br /&gt;selinux=disabled&lt;br /&gt;&lt;br /&gt;selinuxtype=targeted&lt;br /&gt;&lt;br /&gt;8.接着重启系统一下 reboot&lt;br /&gt;&lt;br /&gt;9.重启之后再看看你的内核把 uname -r&lt;br /&gt;&lt;br /&gt;10.openvz已经安装好了，接下来的事情就是要安装（template）模板了&lt;br /&gt;&lt;br /&gt;http://wiki.openvz.org/Download/template/precreated&lt;br /&gt;&lt;br /&gt;满地都是。下载到/vz/template/cache下边&lt;br /&gt;&lt;br /&gt;11.创建一个cente os5 系统&lt;br /&gt;&lt;br /&gt;12. 创建一个操作系统的template&lt;br /&gt;&lt;br /&gt;vzctl create 101 –ostemplate fedora-9-i386-minimal –config vps.basic&lt;br /&gt;&lt;br /&gt;呵呵就是把那个.tar.gz去了使用前边的名字。&lt;br /&gt;&lt;br /&gt;13.设置101开启&lt;br /&gt;&lt;br /&gt;vzctl set 101 –onboot yes –save&lt;br /&gt;&lt;br /&gt;14.设置101的名字和ip地址&lt;br /&gt;&lt;br /&gt;vzctl set 101 –hostname test.example.com –save&lt;br /&gt;&lt;br /&gt;vzctl set 101 –ipadd 192.168.0.101 –save&lt;br /&gt;&lt;br /&gt;设置成你的局域网的ip地址哦&lt;br /&gt;&lt;br /&gt;15.设置101 的sock号以及他的dns server&lt;br /&gt;&lt;br /&gt;vzctl set 101 –numothersock 120 –save&lt;br /&gt;&lt;br /&gt;vzctl set 101 –nameserver 213.133.98.98 –nameserver 213.133.99.99 –nameserver 213.133.100.100 –nameserver 145.253.2.75 –save&lt;br /&gt;&lt;br /&gt;16.开启101&lt;br /&gt;&lt;br /&gt;vzctl start 101&lt;br /&gt;&lt;br /&gt;17.设置101的密码&lt;br /&gt;&lt;br /&gt;vzctl exec 101 passwd&lt;br /&gt;&lt;br /&gt;18.进入101&lt;br /&gt;&lt;br /&gt;vzctl enter 101&lt;br /&gt;&lt;br /&gt;19.退出101&lt;br /&gt;&lt;br /&gt;exit&lt;br /&gt;&lt;br /&gt;20.停止101&lt;br /&gt;&lt;br /&gt;vzctl stop 101&lt;br /&gt;&lt;br /&gt;21.重启101&lt;br /&gt;&lt;br /&gt;vzctl restart 101&lt;br /&gt;&lt;br /&gt;22.把101删除了&lt;br /&gt;&lt;br /&gt;vzctl destroy 101&lt;br /&gt;&lt;br /&gt;23.查看openvz各个系统的状态&lt;br /&gt;&lt;br /&gt;vzlist -a&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-816326671751599127?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/816326671751599127/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=816326671751599127' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/816326671751599127'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/816326671751599127'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/02/openvz-on-f8.html' title='OpenVZ on F8'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-2655000192578824022</id><published>2009-02-17T17:17:00.000+08:00</published><updated>2009-03-12T16:18:36.138+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='virtual'/><title type='text'>Linux-Vserver安装笔记</title><content type='html'>http://linux-vserver.org/ 官方网站&lt;br /&gt;具体不同系统的安装方法：&lt;br /&gt;http://linux-vserver.org/Documentation&lt;br /&gt;&lt;br /&gt;这里我在CentOS 5.1上安装&lt;br /&gt;http://linux-vserver.org/Installation_on_CentOS&lt;br /&gt;&lt;br /&gt;过程：&lt;br /&gt;1、vi /etc/yum.repos.d/dhozac-vserver.repo&lt;br /&gt;内容&lt;br /&gt;&lt;br /&gt;[dhozac-vserver]&lt;br /&gt;name=Linux-VServer related packages for CentOS $releasever - $basearch&lt;br /&gt;baseurl=http://rpm.hozac.com/dhozac/centos/$releasever/vserver/$basearch&lt;br /&gt;gpgkey=http://rpm.hozac.com/conf/keys/RPM-DHOZAC-GPG-KEY&lt;br /&gt;2、yum update yum 更新yum&lt;br /&gt;3、yum install kernel 重启系统&lt;br /&gt;4、安装Vserver工具&lt;br /&gt;yum install util-vserver{,-core,-lib,-sysv,-build}&lt;br /&gt;5、/etc/init.d/vprocunhide start&lt;br /&gt;6、安装GuestOS（斜体字是可变内容）&lt;br /&gt;当然了，如果你知道快的源，可以自己更改一下源&lt;br /&gt;/usr/lib/util-vserver/distributions/centos5/yum.repos.d/CentOS-Base.repo&lt;br /&gt;命令创建虚拟主机&lt;br /&gt;vserver enlampv1 build -m yum –context 42\&lt;br /&gt;–hostname enlampv1.enlamp.cn \&lt;br /&gt;–interface eth0:192.168.1.11/24 — -d centos5&lt;br /&gt;7、安装yum&lt;br /&gt;vyum enlampv1 — install yum&lt;br /&gt;vserver enlampv1 pkgmgmt internalize&lt;br /&gt;8、启动虚拟机&lt;br /&gt;vserver enlampv1 start&lt;br /&gt;vserver enlampv1 enter 进入系统&lt;br /&gt;没有vi，呵呵，echo修改各个文件了。像/etc/reslove.conf等文件。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-2655000192578824022?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/2655000192578824022/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=2655000192578824022' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2655000192578824022'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2655000192578824022'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/02/linux-vserver.html' title='Linux-Vserver安装笔记'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-1127693395075721124</id><published>2009-02-16T23:20:00.000+08:00</published><updated>2009-03-12T16:21:26.949+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux VPS'/><title type='text'>Proxmox-虚拟技术的选择</title><content type='html'>用过Vmware,Openvz. 个人是偏向Openvz的。&lt;br /&gt;今天看到一个更好的Proxmox，感觉它结合了Openvz的优点，&lt;br /&gt;并且还有了Openvz不具备的东西，就是你可以自己安装Guest OS了。&lt;br /&gt;怎么感觉有点像广告啊，闲话不多说了。开工&lt;br /&gt;&lt;br /&gt;系统需求: 64bit，如果要支持自己安装GuestOS，那么CPU需要支持Inter VT/AMD V技术&lt;br /&gt;我的测试机器是CPU: AMD Athlon(tm) 64 X2 Dual Core Processor 5200+ RAM: 1G&lt;br /&gt;&lt;br /&gt;千万注意：Proxmox是需要一个干净的系统的，如果不干净它会把你的系统删&lt;br /&gt;光光的，所以一定要是测试机器，切记！！！&lt;br /&gt;&lt;br /&gt;下载地址 http://pve.proxmox.com/wiki/Downloads&lt;br /&gt;我这里用的是Proxmox VE 1.1&lt;br /&gt;刻录成盘－&gt;安装到测试机器 整个过程也就是30分钟吧（当然了下载不算了）。&lt;br /&gt;&lt;br /&gt;奇怪的事：&lt;br /&gt;[Mon Feb 16 15:59:42 2009] [error] [client 192.168.90.183] File does not exist: /var/www/pve/qemu/VncViewer.class, referer: https://10.0.0.165/qemu/vnc-direct.htm?cid=0&amp;veid=101&lt;br /&gt;竟然没有VncViewer.class，找个来用吧，vnc-java里面就有，我这里传上来了。&lt;br /&gt;wget http://www.enlamp.cn/soft/VncViewer.class&lt;br /&gt;&lt;br /&gt;现在就可以用了，记得你的Proxmox的IP地址吧。&lt;br /&gt;我的是 https://10.0.0.165&lt;br /&gt;帐号是root 密码是安装过程中设置的&lt;br /&gt;&lt;br /&gt;登录成功了，创建虚拟机，然后剩下的你应该都知道了吧。管理起来很简单的&lt;br /&gt;截了几张图，Win那个不知道算不算侵权。Hoho&lt;br /&gt;“小二，上图片！”&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-1127693395075721124?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/1127693395075721124/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=1127693395075721124' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1127693395075721124'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1127693395075721124'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/02/proxmox.html' title='Proxmox-虚拟技术的选择'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-6098962743904208319</id><published>2009-02-16T14:21:00.000+08:00</published><updated>2009-03-12T16:22:19.743+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='apache'/><title type='text'>Apache之userdir</title><content type='html'>Apache有个userdir的模块&lt;br /&gt;http://httpd.apache.org/docs/2.2/howto/public_html.html&lt;br /&gt;&lt;br /&gt;以前没用过，想用一下，可是就是很403，日志也是简单的&lt;br /&gt;Permission denied: access to /~username denied&lt;br /&gt;&lt;br /&gt;后来在另一台用yum安装的服务器上找到答案。&lt;br /&gt;# The path to the end user account ‘public_html’ directory must be&lt;br /&gt;# accessible to the webserver userid. This usually means that ~userid&lt;br /&gt;# must have permissions of 711, ~userid/public_html must have permissions&lt;br /&gt;# of 755, and documents contained therein must be world-readable.&lt;br /&gt;# Otherwise, the client will only receive a “403 Forbidden” message.&lt;br /&gt;&lt;br /&gt;具体操作过程就是　&lt;br /&gt;#chmod -R 711 /home/*&lt;br /&gt;#cd /home/username/&lt;br /&gt;#chmod 755 -R public_html&lt;br /&gt;&lt;br /&gt;一切正常了。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-6098962743904208319?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/6098962743904208319/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=6098962743904208319' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6098962743904208319'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6098962743904208319'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/02/apacheuserdir.html' title='Apache之userdir'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-1370385934679708905</id><published>2009-02-15T13:22:00.000+08:00</published><updated>2009-03-12T16:23:06.204+08:00</updated><title type='text'>Linux技巧</title><content type='html'>Q：如何禁用 gnome 的 最近的文档&lt;br /&gt;A：&lt;br /&gt;$rm .recently-used.xbel&lt;br /&gt;$mkdir .recently-used.xbel&lt;br /&gt;&lt;br /&gt;Q:安装gd-2.0.35出错&lt;br /&gt;gd-2.0.35]# make&lt;br /&gt;cd . &amp;&amp; /bin/sh /root/gd-2.0.35/config/missing –run aclocal-1.9 -I config&lt;br /&gt;aclocal:configure.ac:64: warning: macro `AM_ICONV’ not found in library&lt;br /&gt;cd . &amp;&amp; /bin/sh /root/gd-2.0.35/config/missing –run automake-1.9 –foreign&lt;br /&gt;cd . &amp;&amp; /bin/sh /root/gd-2.0.35/config/missing –run autoconf&lt;br /&gt;configure.ac:64: error: possibly undefined macro: AM_ICONV&lt;br /&gt;If this token and others are legitimate, please use m4_pattern_allow.&lt;br /&gt;See the Autoconf documentation.&lt;br /&gt;make: *** [configure] Error 1&lt;br /&gt;A: yum install -y fontconfig &amp;&amp; yum install -y gettext-devel&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-1370385934679708905?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/1370385934679708905/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=1370385934679708905' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1370385934679708905'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1370385934679708905'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/02/linux.html' title='Linux技巧'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-6984481670728237777</id><published>2009-02-04T21:23:00.000+08:00</published><updated>2009-03-12T16:23:48.639+08:00</updated><title type='text'>MySQL Sandbox(沙盒)</title><content type='html'>Sandbox (computer security), a virtual container in which untrusted programs can be safely run&lt;br /&gt;Sandbox (software development), an online environment in which code or content changes can be tested without affecting the original system –From Wikipedia, the free encyclopedia&lt;br /&gt;沙盒：在这里理解为一个模拟的容器，可以安全运行，而不影响其他程序（MySQL）&lt;br /&gt;&lt;br /&gt;官方网站：http://launchpad.net/mysql-sandbox/&lt;br /&gt;使用MySQL Sandbox可以测试一些新老的MySQL特性，而不影响系统和已经运行的程序&lt;br /&gt;使用说明：&lt;br /&gt;http://forge.mysql.com/wiki/MySQL_Sandbox&lt;br /&gt;&lt;br /&gt;经过测试，感觉不错，只需要下载Mysql_sandbox和MySQL源码包，就可以了。&lt;br /&gt;比较适合想测试MySQL一些特殊功能的朋友。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-6984481670728237777?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/6984481670728237777/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=6984481670728237777' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6984481670728237777'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6984481670728237777'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/02/mysql-sandbox.html' title='MySQL Sandbox(沙盒)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7344546492973938294</id><published>2009-01-16T14:35:00.003+08:00</published><updated>2009-01-16T14:41:42.749+08:00</updated><title type='text'>又走了一个兄弟</title><content type='html'>唉，没有不散的宴席，但是心里还是很不好受。&lt;br /&gt;昨晚一起喝酒，一起游戏。&lt;br /&gt;&lt;br /&gt;在这里呆着对他也没什么好处了，技术不能提高。&lt;br /&gt;工资不足以养活老婆。&lt;br /&gt;&lt;br /&gt;研二了，回学校了。&lt;br /&gt;祝福ing。他有个好老婆。&lt;br /&gt;&lt;br /&gt;还有君君的新网站，做的很好，路过的支持一下。&lt;br /&gt;&lt;a href="http://www.wjunjun.com/"&gt;http://www.wjunjun.com/&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7344546492973938294?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7344546492973938294/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7344546492973938294' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7344546492973938294'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7344546492973938294'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2009/01/blog-post.html' title='又走了一个兄弟'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8412870042722821689</id><published>2008-12-23T18:11:00.001+08:00</published><updated>2008-12-23T18:12:27.382+08:00</updated><title type='text'>偶的新网站</title><content type='html'>&lt;a href="http://www.enlamp.cn/"&gt;http://www.enlamp.cn&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8412870042722821689?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8412870042722821689/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8412870042722821689' title='6 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8412870042722821689'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8412870042722821689'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/blog-post_23.html' title='偶的新网站'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>6</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-6722022903128548009</id><published>2008-12-23T11:24:00.002+08:00</published><updated>2008-12-23T11:30:42.282+08:00</updated><title type='text'>关于Spider的一些问题</title><content type='html'>Sosospider很烦人，就封掉吧。&lt;br /&gt;在服务器里进行封杀&lt;br /&gt;&lt;br /&gt;BrowserMatch Sosospider a_robot=1&lt;br /&gt;BrowserMatch libwww a_robot=1&lt;br /&gt;&lt;br /&gt;&lt;Directory "/www/htdocs"&gt;&lt;br /&gt;中间添加如下&lt;br /&gt;&lt;span style="font-style:italic;"&gt;    Order allow,deny&lt;br /&gt;    Allow from all&lt;br /&gt;    Deny from env=a_robot&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;/Directory&gt;&lt;br /&gt;&lt;br /&gt;统计中还出现BSpider,搜索一下，标识没有BSpider。&lt;br /&gt;原来他用libwww呀。封杀之&lt;br /&gt;http://www.robotstxt.org/db.html&lt;br /&gt;http://www.robotstxt.org/db/bspider.html&lt;br /&gt;&lt;br /&gt;封杀完成，测试&lt;br /&gt;curl -A "libwww" http://www.myweb.com&lt;br /&gt;curl -A "Sosospider" http://www.myweb.com&lt;br /&gt;403了，大功告成。&lt;br /&gt;&lt;br /&gt;curl的详细参数见下面链接&lt;br /&gt;http://curl.haxx.se/docs/manual.html&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-6722022903128548009?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/6722022903128548009/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=6722022903128548009' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6722022903128548009'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6722022903128548009'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/spider.html' title='关于Spider的一些问题'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-1787192822162800532</id><published>2008-12-15T23:42:00.000+08:00</published><updated>2008-12-15T23:47:33.446+08:00</updated><title type='text'>加载php扩展</title><content type='html'>以前安装php的时候，经常需要一些模块，忘了装只能重新编译了&lt;br /&gt;现在才发现，可以直接不用重新编译php的。&lt;br /&gt;&lt;br /&gt;cd 源码目录&lt;br /&gt;cd ext&lt;br /&gt;cd 到你想安装的模块，比如我的 mcrypt&lt;br /&gt;&lt;br /&gt;/usr/local/php5/bin/phpize &lt;br /&gt;./configure --with-php-config=/usr/local/php5/bin/php-config&lt;br /&gt;make&lt;br /&gt;cp modules/mcrypt.so /usr/local/php5/lib/php/extensions&lt;br /&gt;&lt;br /&gt;修改 php.ini&lt;br /&gt;添加&lt;br /&gt;extension="mcrypt.so"&lt;br /&gt;注：检查你的扩展目录，我得已经设置好了&lt;br /&gt;extension_dir = "/usr/local/php5/lib/php/extensions"&lt;br /&gt;所以直接extension="mcrypt.so"就可以。&lt;br /&gt;如果你的没设置，那么需要绝对路径&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-1787192822162800532?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/1787192822162800532/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=1787192822162800532' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1787192822162800532'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1787192822162800532'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/php_15.html' title='加载php扩展'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-1348150180086949132</id><published>2008-12-15T16:35:00.000+08:00</published><updated>2008-12-15T16:41:10.048+08:00</updated><title type='text'>几个小问题</title><content type='html'>1. edyliu-laptop:~$ sudo modprobe vfat&lt;br /&gt;WARNING: Error inserting fat (/lib/modules/2.6.27-7-generic/kernel/fs/fat/fat.ko): Cannot allocate memory&lt;br /&gt;FATAL: Error inserting vfat (/lib/modules/2.6.27-7-generic/kernel/fs/vfat/vfat.ko): Cannot allocate memory&lt;br /&gt;&lt;br /&gt;内存不足，呵呵&lt;br /&gt;可是挂载分区的时候，它提示说内核没有vfat.&lt;br /&gt;free了一些内存，重新来过。一切顺利！&lt;br /&gt;&lt;br /&gt;2. vmware server linux版 对于个人来说， 有点烦人。 总是自动启动， 一生气把它干掉了。&lt;br /&gt;&lt;br /&gt;3. source insight 的 linux 版,看源代码不错的工具&lt;br /&gt;&lt;br /&gt;  sourcenav  http://sourcenav.sourceforge.net/index.html&lt;br /&gt;&lt;br /&gt;4. 读点MySQL的东西，Internal 还是代码。。。。。我接着看&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-1348150180086949132?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/1348150180086949132/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=1348150180086949132' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1348150180086949132'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1348150180086949132'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/blog-post_15.html' title='几个小问题'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-4606586806105895191</id><published>2008-12-11T10:57:00.003+08:00</published><updated>2008-12-11T14:38:14.181+08:00</updated><title type='text'>压力测试之MySQL</title><content type='html'>系统 CentOS 5.1 x86_64&lt;br /&gt;&lt;br /&gt;Step1  install ltp (linux test packages)&lt;br /&gt;rpm -ivh bglibs-1.104-1.x86_64.rpm bglibs-devel-1.104-1.x86_64.rpm&lt;br /&gt;cp /usr/include/unix/* /usr/include/sys/&lt;br /&gt;tar xvzf ltp-full-20081130.tgz&lt;br /&gt;make &amp;&amp; make install&lt;br /&gt;&lt;br /&gt;Step2  install jdbc&lt;br /&gt;http://dev.mysql.com/downloads/connector/j/5.1.html&lt;br /&gt;tar xvzf mysql-connector-java-5.1.7.tar.gz&lt;br /&gt;cp mysql-connector-java-5.1.7/mysql-connector-java-5.1.7-bin.jar ltp-full-20081130/testcases/DOTS/&lt;br /&gt;export CLASSPATH=$CLASSPATH:path---DOTS下的 Dots.jar 和 mysql-connector-java-5.1.7-bin.jar&lt;br /&gt;比如我的&lt;br /&gt;export CLASSPATH=$CLASSPATH:/root/test_db/ltp-full-20081130/testcases/DOTS/Dots.jar:/root/test_db/ltp-full-20081130/testcases/DOTS/mysql-connector-java-5.1.7-bin.jar&lt;br /&gt;&lt;br /&gt;Step3  测试&lt;br /&gt;先执行 &lt;br /&gt;sh PerfMon.sh 开启监听端口，就是监视mysql情况&lt;br /&gt;&lt;br /&gt;再执行&lt;br /&gt;cp config.ini mysql.ini&lt;br /&gt;修改如下信息&lt;br /&gt;UserID = dots&lt;br /&gt;Password = passwd&lt;br /&gt;DriverClass = org.gjt.mm.mysql.Driver&lt;br /&gt;URL = jdbc:mysql://localhost:3306/TESTDB?user=dots&amp;password=passwd&lt;br /&gt;&lt;br /&gt;SERVER_IP = localhost&lt;br /&gt;&lt;br /&gt;最后开启测试&lt;br /&gt;chmod +x Dots.sh &lt;br /&gt;./Dots.sh BTCJ1&lt;br /&gt;./Dots.sh BTCJ2&lt;br /&gt;./Dots.sh BTCJ3&lt;br /&gt;./Dots.sh BTCJ4&lt;br /&gt;./Dots.sh BTCJ5&lt;br /&gt;./Dots.sh BTCJ6&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;1. Q: make LTP 出错&lt;br /&gt;signalfd01.c:58:26: error: sys/signalfd.h: No such file or directory&lt;br /&gt;make[4]: *** [signalfd01] Error 1&lt;br /&gt;&lt;br /&gt;A: 安装 bglibs&lt;br /&gt;&lt;br /&gt;2. 安装监控软件ganglia/munin&lt;br /&gt;&lt;br /&gt;参考：&lt;br /&gt;http://ltp.sourceforge.net/&lt;br /&gt;http://tuxmining.blogspot.com/2008/05/mysql-51-2-weeks-of-stresstests.html&lt;br /&gt;http://ganglia.sourceforge.net/&lt;br /&gt;http://munin.sourceforge.net/&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-4606586806105895191?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/4606586806105895191/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=4606586806105895191' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4606586806105895191'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4606586806105895191'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/mysql.html' title='压力测试之MySQL'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-5253908313367122881</id><published>2008-12-10T17:26:00.000+08:00</published><updated>2008-12-10T17:42:08.973+08:00</updated><title type='text'>用了一下PHP</title><content type='html'>最近程序那边经常要重启，因为用的openvz嘛，他们的程序经常把服务器搞的内存不足。&lt;br /&gt;只能重启了，而我每次都要帮他们重启。&lt;br /&gt;&lt;br /&gt;今天想php可以调用系统命令，让他们自己重启行了。&lt;br /&gt;&lt;?php&lt;br /&gt;&lt;br /&gt;echo "I am Rebooting The Server!"."&lt;br/&gt;";&lt;br /&gt;&lt;br /&gt;$result = exec('sudo vzctl restart 217 2&gt;&amp;1', $retval);&lt;br /&gt;$retval=str_replace("\r","&lt;br/&gt;",$retval);&lt;br /&gt;&lt;br /&gt;foreach($retval as $k =&gt; $row)&lt;br /&gt;{&lt;br /&gt;  if($k == 0 || $k == count($retval)-1)&lt;br /&gt;     echo ($row . "&lt;br/&gt;");&lt;br /&gt;  else&lt;br /&gt;     echo "...............&lt;br/&gt;"; &lt;br /&gt;} &lt;br /&gt;echo "The Server Is Up NOW!";&lt;br /&gt;&lt;br /&gt;主要几点就是&lt;br /&gt;1. 无法显示结果到网页  2&gt;&amp;1 就可以了&lt;br /&gt;2. 无法运行root权限的指令，把daemon加到 sudo组里&lt;br /&gt;    daemon ALL=(ALL) NOPASSWD: /usr/sbin/vzctl （执行指令)&lt;br /&gt;3.  sudo 只能到tty 做如下注释:&lt;br /&gt;    #Defaults    requiretty&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-5253908313367122881?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/5253908313367122881/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=5253908313367122881' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5253908313367122881'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5253908313367122881'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/php.html' title='用了一下PHP'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-582838855431003028</id><published>2008-12-08T13:41:00.001+08:00</published><updated>2008-12-08T13:48:49.435+08:00</updated><title type='text'>SPEC 文件分析(ZT)</title><content type='html'>详细的介绍了 spec文件的书写规则以及关键部分&lt;br /&gt;&lt;br /&gt;spec文件规范&lt;br /&gt;RPM软件包是怎样制作的呢？对大多数Linux开发工程师来说是比较陌生的。&lt;br /&gt;&lt;br /&gt;其实，制作RPM软件包并不是一件复杂的工作，其中的关键在于编写SPEC软件包描述文件。要想制作一个rpm软件包就必须写一个软件包描述文件（SPEC）。这个文件中包含了软件包的诸多信息，如软件包的名字、版本、类别、说明摘要、创建时要执行什么指令、安装时要执行什么操作、以及软件包所要包含的文件列表等等。&lt;br /&gt;&lt;br /&gt;描述文件说明如下：&lt;br /&gt;&lt;br /&gt;（1） 文件头&lt;br /&gt;&lt;br /&gt;一般的spec文件头包含以下几个域：&lt;br /&gt;&lt;br /&gt;Summary：&lt;br /&gt;用一句话概括该软件包尽量多的信息。&lt;br /&gt;Name：&lt;br /&gt;软件包的名字，最终RPM软件包是用该名字与版本号，释出号及体系号来命名软件包的。&lt;br /&gt;Version：&lt;br /&gt;软件版本号。仅当软件包比以前有较大改变时才增加版本号。&lt;br /&gt;Release：&lt;br /&gt;软件包释出号。一般我们对该软件包做了一些小的补丁的时候就应该把释出号加1。&lt;br /&gt;Vendor：&lt;br /&gt;软件开发者的名字。&lt;br /&gt;Copyright：&lt;br /&gt;软件包所采用的版权规则。具体有：GPL（自由软件），BSD，MIT，Public Domain（公共域），Distributable（贡献），commercial（商业），Share（共享）等，一般的开发都写GPL。&lt;br /&gt;Group：&lt;br /&gt;软件包所属类别，具体类别有：&lt;br /&gt;Amusements/Games （娱乐/游戏）&lt;br /&gt;Amusements/Graphics（娱乐/图形）&lt;br /&gt;Applications/Archiving （应用/文档）&lt;br /&gt;Applications/Communications（应用/通讯）&lt;br /&gt;..........&lt;br /&gt;Source：&lt;br /&gt;源程序软件包的名字。如 stardict-2.0.tar.gz。&lt;br /&gt;&lt;br /&gt;（1）%description 段：&lt;br /&gt;软件包详细说明，可写在多个行上。&lt;br /&gt;&lt;br /&gt;（2）%prep段&lt;br /&gt;&lt;br /&gt;这个段是预处理段，通常用来执行一些解开源程序包的命令，为下一步的编译安装作准备。%prep和下面的%build，%install段一样，除了可以执行RPM所定义的宏命令（以%开头）以外，还可以执行SHELL命令，命令可以有很多行，如我们常写的tar解包命令。&lt;br /&gt;&lt;br /&gt;（3）%build段&lt;br /&gt;&lt;br /&gt;本段是建立段，所要执行的命令为生成软件包服务，如make 命令。&lt;br /&gt;&lt;br /&gt;（4）%install段&lt;br /&gt;&lt;br /&gt;本段是安装段，其中的命令在安装软件包时将执行，如make install命令。&lt;br /&gt;&lt;br /&gt;（5）%files段&lt;br /&gt;&lt;br /&gt;本段是文件段，用于定义软件包所包含的文件，分为三类--说明文档（doc），配置文件（config）及执行程序，还可定义文件存取权限，拥有者及组别。&lt;br /&gt;&lt;br /&gt;（6）%changelog段&lt;br /&gt;&lt;br /&gt;本段是修改日志段。你可以将软件的每次修改记录到这里，保存到发布的软件包中，以便查询之用。每一个修改日志都有这样一种格式：第一行是：* 星期 月 日 年 修改人电子信箱。其中：星期、月份均用英文形式的前3个字母，用中文会报错。接下来的行写的是修改了什么地方，可写多行。一般以减号开始，便于后续的查阅。&lt;br /&gt;&lt;br /&gt;打包&lt;br /&gt;如果想发布rpm格式的源码包或者是二进制包，就要使用rpmbuild工具（rpm最新打包工具）。如果我们已经根据本地源码包的成功编译安装而写了 spec文件（该文件要以.spec结束），&lt;br /&gt;那我们就可以建立一个打包环境，也就是目录树的建立，一般是在/usr/src/redhat/目录下建立5个目录。它门分别是BUILD、SOURCE、SPEC、SRPM、RPM。其中BUILD目录用来存放打包过程中的源文件，SOURCE用来存放打包是要用到的源文件和patch，SPEC用来存放spec文件，SRPM、RPM分别存放打包生成的rpm格式的源文件和二进制文件。当然我们可以根据需要来选用不同的参数打包文件，笔者总结如下3条。&lt;br /&gt;&lt;br /&gt;1） 只生成二进制格式的rpm包&lt;br /&gt;rpmbuild -bb xxx.spec&lt;br /&gt;用此命令生成软件包，执行后屏幕将显示如下信息：（每行开头为行号）&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;            1 Executing： %prep&lt;br /&gt;            2 + umask 022&lt;br /&gt;            3 + cd /usr/src/dist/BUILD&lt;br /&gt;            4 + exit 0&lt;br /&gt;            5 Executing： %build&lt;br /&gt;            6 + umask 022&lt;br /&gt;            7 + cd /usr/src/dist/BUILD&lt;br /&gt;            &lt;br /&gt;&lt;br /&gt;生成的文件会在刚才建立的RPM目录下存在。&lt;br /&gt;&lt;br /&gt;2）只生成src格式的rpm包&lt;br /&gt;&lt;br /&gt;rpmbuild -bs xxx.spec&lt;br /&gt;&lt;br /&gt;生成的文件会在刚才建立的SRPM目录下存在。&lt;br /&gt;&lt;br /&gt;3） 只需要生成完整的源文件&lt;br /&gt;&lt;br /&gt;rpmbuild -bp xxx.spec&lt;br /&gt;&lt;br /&gt;源文件存在目录BUILD下。&lt;br /&gt;&lt;br /&gt;读者朋友可能对这个命令不太明白，这个命令的作用就是把tar包解开然后把所有的补丁文件合并而生成一个完整的具最新功能的源文件。&lt;br /&gt;&lt;br /&gt;4） 完全打包&lt;br /&gt;&lt;br /&gt;rpmbuild -ba xxx.spec&lt;br /&gt;&lt;br /&gt;产生以上3个过程分别生成的包。存放在相应的目录下。&lt;br /&gt;&lt;br /&gt;软件包制作完成后可用rpm命令查询，看看效果。如果不满意的话可以再次修改软件包描述文件，重新运行以上命令产生新的RPM软件包。&lt;br /&gt;&lt;br /&gt;典型spec文件分析&lt;br /&gt;通过第一部分的介绍，我们对软件包的管理以及spec文件的一些细节应该掌握的差不多了，接下来通过分析kaffeine.spec（kaffeine是linux平台下的媒体播放器）文件来让读者朋友实践一回spec文件的规范和书写。&lt;br /&gt;&lt;br /&gt;Kaffeine.spec文件内容如下：&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;            %define debug_package %{nil}&lt;br /&gt;            Name:         kaffeine&lt;br /&gt;            Version:        0.4.3&lt;br /&gt;            Release:        25&lt;br /&gt;            Summary:        A xine-based Media Player for KDE&lt;br /&gt;            Group:          Applications/Multimedia&lt;br /&gt;            License:        GPL&lt;br /&gt;            URL:            http://kaffeine.sourceforge.net/&lt;br /&gt;            Source0:        kaffeine-0.4.3.tar.bz2&lt;br /&gt;            Source1:        logo.png&lt;br /&gt;            Source2: icon.tgz&lt;br /&gt;            Source3:        kaffeine.desktop&lt;br /&gt;            Source4:        codecs.tgz&lt;br /&gt;            Patch: kaffeine-0.4.3-fix-hide-crash.patch&lt;br /&gt;            Patch1:kaffeine-0.4.3-without-wizard.patch&lt;br /&gt;            BuildRoot:      /var/tmp/kaffeine-root&lt;br /&gt;            %description&lt;br /&gt;            Kaffeine is a xine based media player for KDE3. It plays back CDs,&lt;br /&gt;            DVDs, and VCDs. It also decodes multimedia files like AVI, MOV, WMV,&lt;br /&gt;            and MP3 from local disk drives, and displays multimedia streamed over&lt;br /&gt;            &lt;br /&gt;以上这部分就是我们第一部分所说的文件头。这一部分主要包括软件包的名称、版本、源代码和patch等信息，通过这些关键字我们可以一目了然。查看以上内容，我们会全面了解该软件包。&lt;br /&gt;&lt;br /&gt;接下来的这一个段就是核心部分，涉及到解包、补丁、编译、安装的过程。&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;            %prep&lt;br /&gt;            %setup -q&lt;br /&gt;            %patch -p1&lt;br /&gt;            %patch1 -p1&lt;br /&gt;            %Build&lt;br /&gt;            make -f admin/Makefile.common cvs&lt;br /&gt;            ./configure --prefix=/usr&lt;br /&gt;            make&lt;br /&gt;            #for mo files&lt;br /&gt;            pushd po&lt;br /&gt;            rm *.gmo&lt;br /&gt;            make&lt;br /&gt;            popd&lt;br /&gt;            %install&lt;br /&gt;            mkdir -p $RPM_BUILD_ROOT&lt;br /&gt;            make install DESTDIR=$RPM_BUILD_ROOT&lt;br /&gt;            mkdir -p $RPM_BUILD_ROOT/usr/share/services&lt;br /&gt;            cp $RPM_BUILD_ROOT/usr/share/apps/kaffeine/mms.protocol $RPM_BUILD_ROOT/usr/share/services&lt;br /&gt;            cp $RPM_BUILD_ROOT/usr/share/apps/kaffeine/rtsp.protocol $RPM_BUILD_ROOT/usr/share/services&lt;br /&gt;            #mkdir -p $RPM_BUILD_ROOT/usr/lib/firefox/plugins&lt;br /&gt;            #cp $RPM_BUILD_ROOT/usr/lib/kaffeineplugin/kaffeineplugin.so&lt;br /&gt;            $RPM_BUILD_ROOT/usr/lib/firefox/plugins&lt;br /&gt;            cp %{SOURCE1} $RPM_BUILD_ROOT/usr/share/apps/kaffeine&lt;br /&gt;            rm -rf $RPM_BUILD_ROOT/usr/share/icons/hicolor/*/apps/kaffeine.png&lt;br /&gt;            rm -rf $RPM_BUILD_ROOT/usr/share/icons/hicolor/*/apps/kaffeine-pause.png&lt;br /&gt;            rm -rf $RPM_BUILD_ROOT/usr/share/icons/hicolor/*/apps/kaffeine-play.png&lt;br /&gt;            rm -rf $RPM_BUILD_ROOT/usr/share/icons/hicolor/*/apps/kaffeine-record.png&lt;br /&gt;            mkdir -p $RPM_BUILD_ROOT/usr/share/icons/crystalsvg&lt;br /&gt;            tar zxvf %{SOURCE2} -C $RPM_BUILD_ROOT/usr/share/icons/crystalsvg&lt;br /&gt;            mkdir -p $RPM_BUILD_ROOT/usr/share/applnk/App/Multimedia&lt;br /&gt;            cp -r %{SOURCE3} $RPM_BUILD_ROOT/usr/share/applnk/App/Multimedia&lt;br /&gt;            mkdir -p $RPM_BUILD_ROOT/usr/lib/win32&lt;br /&gt;            tar zxvf %{SOURCE4} -C $RPM_BUILD_ROOT/usr/lib/win32&lt;br /&gt;            %clean&lt;br /&gt;            rm -rf $RPM_BUILD_ROOT&lt;br /&gt;            %post&lt;br /&gt;            ln -s /dev/cdrom /dev/dvd&lt;br /&gt;            ln -s /dev/cdrom /dev/rdvd&lt;br /&gt;            %files&lt;br /&gt;            %defattr(-,root,root)&lt;br /&gt;            /usr&lt;br /&gt;            &lt;br /&gt;&lt;br /&gt;这部分内容与所要打的包有关系，我们要根据具体情况来写出编译过程。这部分内容是最复杂的内容，当然，我们也可以看出，这样的写法其实就是在写一种规范化的脚本，说到脚本，读者朋友门就应该领会到这部分内容的灵活性了。&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;            %changelog&lt;br /&gt;            * Fri Jul 1  2005 AiLin Yang &lt;alyang@redflag-linux.com&gt; -0.4.3-25&lt;br /&gt;            - modified the fullscreen bottom control panel&lt;br /&gt;            .....&lt;br /&gt;            &lt;br /&gt;&lt;br /&gt;这部分内容可以说是spec文件的最后内容了，它对团队软件开发以及后续的软件维护至关重要，它相当于一个日志，记录了所有的基于该软件包的修改、更新信息。&lt;br /&gt;&lt;br /&gt;小结&lt;br /&gt;要想制作一个RPM格式的软件包必须编写软件包描述文件。其标准命名格式为:软件名-版本号-释出号.spec，这个文件详细描述了有关该软件包的诸多信息,如软件名,版本,类别,说明摘要,创建时要执行什么指令,安装时要执行什么操作,以及软件包所要包含的文件等等。有了这个文件RPM就可以制作出相应的rpm软件包。&lt;br /&gt;&lt;br /&gt;原文作者：&lt;br /&gt;杨爱林，Linux 研发工程师， 通过 alyang@redflag-linux.com 可以跟他联系。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-582838855431003028?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/582838855431003028/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=582838855431003028' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/582838855431003028'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/582838855431003028'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/rpmspec-zt.html' title='SPEC 文件分析(ZT)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8031970127848829779</id><published>2008-12-07T15:17:00.001+08:00</published><updated>2008-12-09T17:09:36.430+08:00</updated><title type='text'>常识积累</title><content type='html'>1. 关于32bit和64bit CPU的一些知识&lt;br /&gt;&lt;br /&gt;通常将CPU称为32位CPU或64位CPU等。个人电脑经常使用的英特尔奔4、赛扬CPU，以及AMD的Athlon XP都是32位CPU。顾名思义，Athlon 64是以64位为单位完成一次计算的CPU。大体上来说，64位CPU能够一次性处理32位CPU分2次完成的计算，因此有望提高处理性能。&lt;br /&gt;   对于64位CPU，可寻址内存也将增加。普通的32位CPU，软件可寻址内存最大为4GB（约40亿字节），而64位CPU理论上最大可使用16EB（exabyte，16×10亿×10亿字节）。而Athlon 64的可寻址内存则小于16EB，为1TB（约1000×10亿字节）。&lt;br /&gt;&lt;br /&gt;2. Ubuntu 8.10的一个好玩的，类似mac的dock&lt;br /&gt;&lt;br /&gt;修改/etc/apt/sources.list&lt;br /&gt;&lt;br /&gt;deb http://repository.cairo-dock.org/ubuntu intrepid cairo-dock&lt;br /&gt;sudo apt-get update&lt;br /&gt;sudo apt-get install cairo-dock cairo-dock-plug-ins&lt;br /&gt;&lt;br /&gt;系统工具 Cario-dock 打开效果看看，帅不？&lt;br /&gt;&lt;br /&gt;3.因为系统而要用Zend optimizer,我装的是v3.3，安装过程一切顺利，重启apache后发现并没有加载Zend optimizer模块，在apache的error_log里也没有发现记录，执行php -v命令有以下输出：&lt;br /&gt;&lt;br /&gt;Failed loading /usr/local/Zend/lib/Optimizer-3.3.0/php-5.1.x/ZendOptimizer.so: /usr/local/Zend/lib/Optimizer-3.3.0/php-5.1.x/ZendOptimizer.so: cannot restore segment prot after reloc: Permission denied&lt;br /&gt;&lt;br /&gt;上网查找原因，说是selinux的原因，服务器确实开着selinux的，更改selinux的配置文件将其设为disable，可我不想重启服务器，有以下解决办法：&lt;br /&gt;&lt;br /&gt;执行命令：setenforce 0&lt;br /&gt;&lt;br /&gt;就可以不重启关闭selinux了&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8031970127848829779?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8031970127848829779/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8031970127848829779' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8031970127848829779'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8031970127848829779'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/blog-post.html' title='常识积累'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-339799560914382784</id><published>2008-12-03T16:01:00.000+08:00</published><updated>2008-12-03T16:05:11.493+08:00</updated><title type='text'>Apache+mod_cband限速</title><content type='html'>http://cband.linux.pl/ 官方被 HX 了，看不到&lt;br /&gt;&lt;br /&gt;下载&lt;br /&gt;wget http://www.sfr-fresh.com/unix/privat/mod-cband-0.9.7.5.tgz&lt;br /&gt;&lt;br /&gt;安装&lt;br /&gt;./configure --with-apxs=/whereis apxs&lt;br /&gt;make &lt;br /&gt;make install&lt;br /&gt;&lt;br /&gt;然后就加载一下&lt;br /&gt;具体用法&lt;br /&gt;cat INSTALL&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-339799560914382784?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/339799560914382784/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=339799560914382784' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/339799560914382784'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/339799560914382784'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/apachemodcband.html' title='Apache+mod_cband限速'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-3966457224425906905</id><published>2008-12-03T12:04:00.000+08:00</published><updated>2008-12-03T12:08:33.610+08:00</updated><title type='text'>Mail服务器RBL反垃圾邮件</title><content type='html'>最近邮件服务器经常队列中堆满垃圾邮件。&lt;br /&gt;&lt;br /&gt;添加了一个RBL,希望能好一点。&lt;br /&gt;smtpd_client_restrictions = reject_rbl_client cblless.anti-spam.org.cn, reject_rbl_client dnsbl.sorbs.net&lt;br /&gt;&lt;br /&gt;maps_rbl_domains = bl.spamcop.net&lt;br /&gt;smtpd_recipient_restrictions = ....&lt;br /&gt;reject_maps_rbl,permit&lt;br /&gt;&lt;br /&gt;参考链接：&lt;br /&gt;http://www.postfix.org/uce.html&lt;br /&gt;&lt;br /&gt;http://anti-spam.org.cn&lt;br /&gt;&lt;br /&gt;http://jimsun.linxnet.com/misc/postfix-anti-UCE.txt&lt;br /&gt;&lt;br /&gt;http://www.us.sorbs.net/&lt;br /&gt;&lt;br /&gt;收工吃饭。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-3966457224425906905?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/3966457224425906905/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=3966457224425906905' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3966457224425906905'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3966457224425906905'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/mailrbl.html' title='Mail服务器RBL反垃圾邮件'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7654611320872163490</id><published>2008-12-02T09:12:00.001+08:00</published><updated>2008-12-02T09:18:52.744+08:00</updated><title type='text'>Probing PCI hardware (bus 00)</title><content type='html'>Linux安装时停止在Probing PCI hardware (bus 00)错误解决办法&lt;br /&gt;&lt;br /&gt;环境：&lt;br /&gt;　　主板是英特尔G35的芯片组。两G条子。硬盘：SATA接口。&lt;br /&gt;&lt;br /&gt;　　操作系统 CentOS4.X&lt;br /&gt;&lt;br /&gt;　　故障：&lt;br /&gt;　　Linux安装时提示 Probing PCI hardware (bus 00)&lt;br /&gt;&lt;br /&gt;　　原因：&lt;br /&gt;　　与硬盘的接口及PCI接口有关。&lt;br /&gt;&lt;br /&gt;　　解决办法：&lt;br /&gt;　　启动到LINUX界面下按F3，后输入linux pci=nommconf 后回车即可。安装完后，重启时还需要输入。&lt;br /&gt;&lt;br /&gt;    安装完之后编辑 /etc/grub.conf 将pci=nommconf 附加到内核后面，在同一行上。如下所示：&lt;br /&gt; &lt;br /&gt;&lt;span style="font-weight:bold;"&gt;kernel /boot/vmlinuz-2.6.9-78.0.5.plus.c4smp ro root=LABEL=/ pci=nommconf&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7654611320872163490?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7654611320872163490/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7654611320872163490' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7654611320872163490'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7654611320872163490'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/12/probing-pci-hardware-bus-00.html' title='Probing PCI hardware (bus 00)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8171538981076246183</id><published>2008-11-28T09:17:00.000+08:00</published><updated>2008-11-28T09:44:17.185+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Server'/><title type='text'>关于CentOS定制的一些问题</title><content type='html'>因为一些系统上的需求，所以想定制一套系统。&lt;br /&gt;&lt;br /&gt;系统是CentOS4.6的，想把一些内核什么的升级一下。&lt;br /&gt;CentOS4.6里面还有hdlist，可是我的目系统是CentOS5.1的&lt;br /&gt;没有genhdlist，一般它在anaconda-runtime里面。&lt;br /&gt;&lt;br /&gt;最后还是用CentOS4.6作为母系统，装上anaconda-runtime才搞定&lt;br /&gt;&lt;br /&gt;主要步骤：&lt;br /&gt;原版iso 在 /db/iso/centos4.6.iso &lt;br /&gt;挂载点 /db/cd&lt;br /&gt;制作目录设置为 /db/c4&lt;br /&gt;&lt;br /&gt;mount -o loop  /db/iso/centos4.6.iso /db/cd&lt;br /&gt;cd /db/cd&lt;br /&gt;tar -cf - . | ( cd /db/c4 ; tar -xvpf - )&lt;br /&gt;cd c4 &amp;&amp; umount /db/cd&lt;br /&gt;&lt;br /&gt;cp updated***.rpm /db/c4/CentOS/RPMS/&lt;br /&gt;cd /db/c4/&lt;br /&gt;&lt;br /&gt;cp CentOS/base/comps.xml repodata/&lt;br /&gt;createrepo -g repodata/comps.xml .&lt;br /&gt;&lt;br /&gt;重新生成 hdlist&lt;br /&gt;/usr/lib/anaconda-runtime/genhdlist &lt;br /&gt;&lt;br /&gt;重新制作ISO&lt;br /&gt;cd /db/c4&lt;br /&gt;mkisofs -R -J -T -r  -l -d -allow-multidot -allow-leading-dots -no-bak -o ../pmail-0.4-i386.iso -b isolinux/isolinux.bin -c isolinux/boot.cat        -no-emul-boot -boot-load-size 4 -boot-info-table .&lt;br /&gt;&lt;br /&gt;PS: 1. genhdlist 需要加一些参数，生成hdlist最好检查一下&lt;br /&gt;    2. 制作好的ISO，用virtualbox/vmware安装测试后，再刻录成盘，减少失败的几率。&lt;br /&gt;&lt;br /&gt;这件事陷入一个自己挖的坑，虽然学到了点东西，但是从实用和性价比上来说，是失败的。&lt;br /&gt;本来这个系统不需要花费一天的时间来做这一套。犯了"重复发明轮子”的错误。以后需要注意做之前的定位。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8171538981076246183?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8171538981076246183/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8171538981076246183' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8171538981076246183'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8171538981076246183'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/centos.html' title='关于CentOS定制的一些问题'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-5532331092754825970</id><published>2008-11-24T14:37:00.000+08:00</published><updated>2008-11-24T15:57:27.541+08:00</updated><title type='text'>飞信机器人在linux系统管理中的应用</title><content type='html'>今天逛www.bsdlover.cn 看到一篇关于飞信机器人的文章&lt;br /&gt;&lt;br /&gt;飞信机器人官方网站：&lt;br /&gt;http://www.it-adv.net/&lt;br /&gt;&lt;br /&gt;闲话少叙，开始飞信之旅。&lt;br /&gt;&lt;br /&gt;OS: CentOS5 (x86_64)&lt;br /&gt;&lt;br /&gt;1 下载&lt;br /&gt;http://www.it-adv.net/index.php?action=downloads&lt;br /&gt;&lt;br /&gt;wget http://www.it-adv.net/fetion/library32.rar&lt;br /&gt;wget http://www.it-adv.net/fetion/download/fetion20080910048-linux.tar.gz&lt;br /&gt;&lt;br /&gt;2 添加必须的库&lt;br /&gt;解压 unrar e library32.rar /usr/lib/&lt;br /&gt;ldconfig -v |grep ACE&lt;br /&gt;应该有如下显示：&lt;br /&gt;libACE.so.5.4.7 -&gt; libACE.so.5.4.7&lt;br /&gt;libACE_SSL.so.5.4.7 -&gt; libACE_SSL.so.5.4.7&lt;br /&gt;&lt;br /&gt;3 tar xvzf fetion20080910048-linux.tar.gz&lt;br /&gt;mv install /usr/local/fetion&lt;br /&gt;cd /usr/local/fetion ; ./fetion -u 手机号 -p 密码&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;安装完成&lt;br /&gt;&lt;br /&gt;联合其他脚本&lt;br /&gt;目标：我要检测磁盘情况，防止有些磁盘被占满。当然了，quota可以做到。&lt;br /&gt;假设我没作quota&lt;br /&gt;&lt;br /&gt;我写的脚本&lt;br /&gt;&lt;br /&gt;/srv/check_disk.sh &lt;br /&gt;#!/bin/bash&lt;br /&gt;&lt;br /&gt;#&lt;br /&gt;#&lt;br /&gt;# Check the Harddisk usesage and warnings&lt;br /&gt;# Author: xfsuper@gmail.com&lt;br /&gt;# Date: 2008/11/5&lt;br /&gt;#&lt;br /&gt;&lt;br /&gt;# Warninglimit is 2G default&lt;br /&gt;# lowlimit is 1G default&lt;br /&gt;warninglimit=2000000&lt;br /&gt;lowlimit=1000000&lt;br /&gt;&lt;br /&gt;filesystems=`df -h | awk '{print $1}' |grep /dev`&lt;br /&gt;&lt;br /&gt;for fs in $filesystems&lt;br /&gt;do&lt;br /&gt;   size=`df -k $fs |grep $fs |awk '{ print $4; }'`&lt;br /&gt;           &lt;br /&gt;   if [ $size -lt $lowlimit ]; then&lt;br /&gt;      size=$((size/(1024*1024))) &lt;br /&gt;      echo "URGENT: Low disk space for $fs in $HOSTNAME,Now it is $size G only" &gt;/tmp/disk_check&lt;br /&gt;      echo "sms 158XXXX3553 URGENT: Low disk space for $fs in $HOSTNAME,Now it is $size G only" &gt; /tmp/send_urg&lt;br /&gt;      echo "exit" &gt;&gt; /tmp/send_urg&lt;br /&gt;&lt;br /&gt;#######   send settings&lt;br /&gt;      mail -s "URGENT: Low disk space for $fs in $HOSTNAME,Now it is $size G only" -c xfsuper@gmail.com xfsuper@gmail.com.com &lt; /tmp/disk_check&lt;br /&gt;      &lt;span style="font-style:italic;"&gt;/usr/local/fetion/fetion -u 158XXXX3553 -b /tmp/send_urg -p XXXXX&lt;/span&gt; &lt;br /&gt;&lt;br /&gt;      break&lt;br /&gt;   fi&lt;br /&gt;   if [ $size -lt $warninglimit ]; then&lt;br /&gt;      size=$((size/(1024*1024))) &lt;br /&gt;      echo "Warning: Low disk space for $fs in $HOSTNAME,Now it is $size G only" &gt; /tmp/disk_check_warn&lt;br /&gt;      echo "sms 158XXXX3553 Warning: Low disk space for $fs in $HOSTNAME,Now it is $size G only" &gt; /tmp/send_warn&lt;br /&gt;      echo "exit" &gt;&gt; /tmp/send_warn&lt;br /&gt;&lt;br /&gt;      mail -s "Warning: Low disk space for $fs in $HOSTNAME,Now it is $size G only" -c xfsuper@gmail.com xfsuper@gmail.com.com &lt; /tmp/disk_check_warn&lt;br /&gt;      &lt;span style="font-style:italic;"&gt;/usr/local/fetion/fetion -u 158XXXX3553 -b /tmp/send_warn -p XXXXX &lt;/span&gt;&lt;br /&gt;   fi&lt;br /&gt;&lt;br /&gt;done&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-5532331092754825970?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/5532331092754825970/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=5532331092754825970' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5532331092754825970'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5532331092754825970'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/linux.html' title='飞信机器人在linux系统管理中的应用'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8928316372240423637</id><published>2008-11-19T16:59:00.000+08:00</published><updated>2008-11-19T17:04:22.147+08:00</updated><title type='text'>Freenas Fire me !</title><content type='html'>不喜欢freenas了，不知道怎么回事。&lt;br /&gt;今天捣鼓了好一会儿都没搞定&lt;br /&gt;以前有些用户直接存到/etc/passwd 里面&lt;br /&gt;今天建了一些存到了/var/etc/passwd里面&lt;br /&gt;很奇怪，并且不给我创建目录。还要自己手动创建&lt;br /&gt;还出现密码错误的现象。。。。。。。&lt;br /&gt;&lt;br /&gt;我放弃了。让它搞崩溃了&lt;br /&gt;&lt;br /&gt;freebsd 7的ssh需要加上这两行才能登录。&lt;br /&gt;PermitRootLogin yes&lt;br /&gt;PasswordAuthentication yes &lt;br /&gt;要不然就出错。。。。。。&lt;br /&gt;普通的用户不能 su ，确实够安全！&lt;br /&gt;真的是“鱼和熊掌，不可兼得”&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8928316372240423637?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8928316372240423637/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8928316372240423637' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8928316372240423637'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8928316372240423637'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/freenas-fire-me.html' title='Freenas Fire me !'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7443451952086201810</id><published>2008-11-15T11:32:00.000+08:00</published><updated>2008-11-15T15:45:31.201+08:00</updated><title type='text'>Web服务器的优化（From Yahoo)</title><content type='html'>昨天把Hypertable+KFS搞定了。&lt;br /&gt;&lt;br /&gt;今天没什么事了，看看一些技术性文章&lt;br /&gt;performance-research from yahoo.com&lt;br /&gt;&lt;br /&gt;1. Reducing the number of HTTP requests has the biggest impact on reducing response time and is often the easiest performance improvement to make&lt;br /&gt;很实话，呵呵，减少请求当然是首选，然后就是推出缓存问题了。&lt;br /&gt;http://yuiblog.com/blog/2006/11/28/performance-research-part-1/&lt;br /&gt;&lt;br /&gt;2. Keep in mind the empty cache user experience. It might be more prevalent than you think!&lt;br /&gt;就是在做客户端缓存的时候，不要忘记没有缓存的用户。客户端缓存不要做得太狠&lt;br /&gt;http://yuiblog.com/blog/2007/01/04/performance-research-part-2/&lt;br /&gt;&lt;br /&gt;3.Eliminate unnecessary cookies; &lt;br /&gt;  Keep cookie sizes as low as possible to minimize the impact on the user response time; &lt;br /&gt;  Be mindful of setting cookies at the appropriate domain level so other sub-domains are not affected.&lt;br /&gt;  Set an Expires date appropriately. An earlier Expires date or none removes the cookie sooner, improving the user response time.&lt;br /&gt;Cookies也是问题的时候可见服务器流量之大了，呵呵，yahoo技术上确实。&lt;br /&gt;http://yuiblog.com/blog/2007/03/01/performance-research-part-3/&lt;br /&gt;&lt;br /&gt;4. Our rule of thumb is to increase the number of parallel downloads by using at least two, but no more than four hostnames. Once again, this underscores the number one rule for improving response times: reduce the number of components in the page.&lt;br /&gt;DNS寻址时间也算进去？佩服！增加&lt;br /&gt;http://yuiblog.com/blog/2007/04/11/performance-research-part-4/&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7443451952086201810?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7443451952086201810/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7443451952086201810' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7443451952086201810'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7443451952086201810'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/webfrom-yahoo.html' title='Web服务器的优化（From Yahoo)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7404912681028297209</id><published>2008-11-14T13:34:00.000+08:00</published><updated>2008-11-14T13:40:38.284+08:00</updated><title type='text'>监控软件之zenoss</title><content type='html'>Zenoss&lt;br /&gt;Open Source Application, Systems &amp;amp; Network Monitoring&lt;br /&gt;www.zenoss.com&lt;br /&gt;应用在多机监控上不错，以前用ganglia/nagios&lt;br /&gt;不过ganglia总得来说还是不错的。&lt;br /&gt;细节还有待进一步研究。&lt;br /&gt;&lt;br /&gt;OpenNMS&lt;br /&gt;Open network management system&lt;br /&gt;opennms.org&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7404912681028297209?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7404912681028297209/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7404912681028297209' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7404912681028297209'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7404912681028297209'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/zenoss.html' title='监控软件之zenoss'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-3422799926955638487</id><published>2008-11-14T09:26:00.002+08:00</published><updated>2008-11-14T10:51:14.538+08:00</updated><title type='text'>Apache的Alias</title><content type='html'>昨天给朋友共享一个电影，没有QQ，MSN又太慢。&lt;br /&gt;还是用我的Apache吧，因为我的电影在Windows的盘里，&lt;br /&gt;挂载上之后做别名，就是403错误，看日志吧。&lt;br /&gt;Alias /movie/ /media/disk/video/&lt;br /&gt;&lt;directory&gt;'&lt;'Directory "&lt;/directory&gt;media/disk/video/" '&gt;'&lt;br /&gt;&lt;directory&gt;   Options Indexes&lt;br /&gt; Order allow,deny&lt;br /&gt; Allow from all&lt;br /&gt;&lt;/directory&gt;&lt;directory&gt;'&lt;'/Directory&lt;/directory&gt;'&gt;'&lt;br /&gt;注:因为它害怕恶意代码，所以你要把单引号去掉&lt;br /&gt;&lt;br /&gt;日志只是提示refused by server&lt;br /&gt;应该是权限问题&lt;br /&gt;edyliu@edyliu-laptop:~$ ll /media/disk/video/&lt;br /&gt;总用量 11556160&lt;br /&gt;drwx------  3 edyliu root     32768 2008-11-14 09:18 .&lt;br /&gt;drwx------ 16 edyliu root     32768 1970-01-01 08:00 ..&lt;br /&gt;-rwx------  1 edyliu root 394587728 2007-10-17 03:07 01.rmvb&lt;br /&gt;&lt;br /&gt;果然是 直接把 apache的用户改了&lt;br /&gt;User edyliu&lt;br /&gt;Group edyliu&lt;br /&gt;&lt;br /&gt;$sudo service httpd graceful&lt;br /&gt;&lt;br /&gt;访问OK!&lt;br /&gt;记住：manual&lt;br /&gt;因为我的电影是中文名，所以直接indexes出现乱码问题，&lt;br /&gt;所以在httpd-autoindex.conf里面修改&lt;br /&gt;&lt;code&gt;IndexOptions Charset=UTF-8 &lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-3422799926955638487?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/3422799926955638487/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=3422799926955638487' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3422799926955638487'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3422799926955638487'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/apachealias.html' title='Apache的Alias'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-4535443908637669863</id><published>2008-11-05T15:44:00.000+08:00</published><updated>2008-11-05T15:46:23.062+08:00</updated><title type='text'>冬日的萧条真的来了吗？</title><content type='html'>一个个离去，个中滋味，很难过。&lt;br /&gt;&lt;br /&gt;记得看toplee的日志，看这冬天，感觉也很不爽。&lt;br /&gt;中午还讨论周末一起去篮球，这个约定也许要无限期推延了。&lt;br /&gt;&lt;br /&gt;朋友不错，工作上的东西，真的很无奈。&lt;br /&gt;一路走好！&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-4535443908637669863?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/4535443908637669863/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=4535443908637669863' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4535443908637669863'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4535443908637669863'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/blog-post.html' title='冬日的萧条真的来了吗？'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-5834912466239918609</id><published>2008-11-05T13:11:00.001+08:00</published><updated>2008-11-05T15:31:46.857+08:00</updated><title type='text'>linux 技巧：使用 screen 管理你的远程会话</title><content type='html'>http://www.ibm.com/developerworks/cn/linux/l-cn-screen/&lt;br /&gt;&lt;br /&gt;screen + 命令&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;C-a ? 显示所有键绑定信息&lt;br /&gt;C-a w 显示所有窗口列表&lt;br /&gt;C-a C-a 切换到之前显示的窗口&lt;br /&gt;C-a c 创建一个新的运行shell的窗口并切换到该窗口&lt;br /&gt;C-a n 切换到下一个窗口&lt;br /&gt;C-a p 切换到前一个窗口(与C-a n相对)&lt;br /&gt;C-a 0..9 切换到窗口0..9&lt;br /&gt;C-a a 发送 C-a到当前窗口&lt;br /&gt;C-a d 暂时断开screen会话&lt;br /&gt;C-a k 杀掉当前窗口&lt;br /&gt;C-a [ 进入拷贝/回滚模式&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;Lazy Linux: 11 secrets for lazy cluster admins&lt;/span&gt;&lt;br /&gt;http://www.ibm.com/developerworks/linux/library/l-11sysadtips/index.html&lt;br /&gt;&lt;p&gt; The secrets are &lt;/p&gt;             &lt;ol&gt;&lt;li&gt;Don't reinvent the wheel.&lt;/li&gt;&lt;li&gt;Use open source.&lt;/li&gt;&lt;li&gt;Automate everything.&lt;/li&gt;&lt;li&gt;Design for scale - plan to be lazy from the start.&lt;/li&gt;&lt;li&gt;Design for hardware manageability.&lt;/li&gt;&lt;li&gt;Use good cluster management software - don't dig wells with teaspoons.&lt;/li&gt;&lt;li&gt;Use open source monitoring solutions.&lt;/li&gt;&lt;li&gt;Control your users with a queuing system.&lt;/li&gt;&lt;li&gt;Verify you get what you pay for - benchmark it!&lt;/li&gt;&lt;li&gt;Manage cluster communication.&lt;/li&gt;&lt;li&gt;Look for ways to become lazier.&lt;/li&gt;&lt;/ol&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-5834912466239918609?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/5834912466239918609/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=5834912466239918609' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5834912466239918609'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5834912466239918609'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/linux-screen.html' title='linux 技巧：使用 screen 管理你的远程会话'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-6722352752960290897</id><published>2008-11-04T15:54:00.000+08:00</published><updated>2008-11-04T15:57:22.638+08:00</updated><title type='text'>linux/freebsd检查硬盘坏道</title><content type='html'>linux 下用 badblock,freebsd 利用硬盘的S.M.A.R.T功能来做. &lt;p&gt;badblocks &lt;br /&gt;功能说明：检查磁盘装置中损坏的区块。  &lt;br /&gt;语法：badblocks [-svw][-b ][-o ][磁盘装置][磁盘区块数][启始区块]  &lt;br /&gt;补充说明：执行指令时须指定所要检查的磁盘装置，及此装置的磁盘区块数。  &lt;br /&gt;参数：  &lt;br /&gt;-b 指定磁盘的区块大小，单位为字节。  &lt;br /&gt;-o 将检查的结果写入指定的输出文件。  &lt;br /&gt;-s 在检查时显示进度。  &lt;br /&gt;-v 执行时显示详细的信息。  &lt;br /&gt;-w 在检查时，执行写入测试。  &lt;br /&gt;[磁盘装置] 指定要检查的磁盘装置。  &lt;br /&gt;[磁盘区块数] 指定磁盘装置的区块总数。  &lt;br /&gt;[启始区块] 指定要从哪个区块开始检查。  &lt;br /&gt;badblocks 检测磁盘坏块  &lt;br /&gt;1)$badblocks -s //显示进度 -v //显示执行详细情况 /dev/sda1  &lt;br /&gt;2)读写方式检测 未挂载的磁盘设备或分区  &lt;br /&gt;$badblocks -s //显示进度 -w //以写去检测 -v //显示执行详细情况 /dev/sda2&lt;/p&gt; &lt;p&gt;freebsd下的&lt;/p&gt; &lt;p&gt;cd /usr/ports/sysutils/smartmontools  &lt;br /&gt;make install   &lt;br /&gt;快速检查硬盘是否有问题   &lt;br /&gt;smartctl -a /dev/ad0   &lt;br /&gt;表面测试   &lt;br /&gt;smartctl -t long /dev/ad0  &lt;br /&gt;好像还有一个badtrk工具&lt;/p&gt; &lt;p&gt;—————————————————————-&lt;/p&gt; &lt;p&gt;以下是别处copy来的&lt;/p&gt; &lt;p&gt;一、缺陷的分类  &lt;br /&gt;如果经检测发现某个硬盘不能完全正常工作，则称这个硬盘是“有缺陷的硬盘”（Defect Hard Disk）。  &lt;br /&gt;根据维修经验，笔者将硬盘的缺陷分为六大类  &lt;br /&gt;①坏扇区（Bad sector），也称缺陷扇区（Defect sector）  &lt;br /&gt;②磁道伺服缺陷（Track Servo defect）?  &lt;br /&gt;③磁头组件缺陷（Heads assembly defect）  &lt;br /&gt;④系统信息错乱（Service information destruction）  &lt;br /&gt;⑤电子线路缺陷（The board of electronics defect）  &lt;br /&gt;⑥综合性能缺陷（Complex reliability defect）  &lt;br /&gt;1.坏扇区（也称缺陷扇区）  &lt;br /&gt;指不能被正常访问或不能被正确读写的扇区。一般表现为：高级格式化后发现有“坏簇（Bad Clusters）；用SCANDISK等工具检查发现有“B”标记；或用某些检测工具发现有“扇区错误提示”等。  &lt;br /&gt;一般每个扇区可以记录512字节的数据，如果其中任何一个字节不正常，该扇区就属于缺陷扇区。每个扇区除了记录512字节的数据外，另外还记录有一些信息：标志信息、校验码、地址信息等，其中任何一部分信息不正常都导致该扇区出现缺陷。  &lt;br /&gt;多数专业检测软件在检测过程中发现缺陷时，都有类似的错误信息提示，常见的扇区缺陷主要有几种情况：  &lt;br /&gt;① 校验错误（ECC uncorrectable errors，又称ECC错误）。系统每次在往扇区中写数据的同时，都根据这些数据经过一定的算法运算生成一个校验码（ECC=Error Correction Code），并将这个校验码记录在该扇区的信息区内。以后从这个扇区读取数据时，都会同时读取其校检码，并对数据重新运算以检查结果是否与校检码一致。如 果一致，则认为这个扇区正常，存放的数据正确有效；如果不一致，则认为该扇区出错，这就是校验错误。这是硬盘最主要的缺陷类型。导致这种缺陷的原因主要 有：磁盘表面磁介质损伤、硬盘写功能不正常、校验码的算法差异。&lt;br /&gt;②IDNF错误（sector ID not found），即扇区标志出错，造成系统在需要读写时找不到相应的扇区。造成这个错误的原因可能是系统参数错乱，导致内部地址转换错乱，系统找不到指定扇 区；也有可能是某个扇区记录的标志信息出错导致系统无法正确辨别扇区。&lt;br /&gt;③AMNF错误（Address Mark Not Found），即地址信息出错。一般是由于某个扇区记录的地址信息出错，系统在对它访问时发现其地址信息与系统编排的信息不一致。  &lt;br /&gt;④坏块标记错误（Bad block mark）。某些软件或病毒程序可以在部分扇区强行写上坏块标记，让系统不使用这些扇区。这种情况严格来说不一定是硬盘本身的缺陷，但想清除这些坏块标记却不容易。  &lt;br /&gt;2.磁道伺服缺陷  &lt;br /&gt;现在的硬盘大多采用嵌入式伺服，硬盘中每个正常的物理磁道都嵌入有一段或几段信息作为伺服信息，以便磁头在寻道时能准确定位及辨别正确编号的物理磁道。如 果某个物理磁道的伺服信息受损，该物理磁道就可能无法被访问。这就是“磁道伺服缺陷”。一般表现为，分区过程非正常中断；格式化过程无法完成；用检测工具 检测时，中途退出或死机，等等。&lt;br /&gt;3.磁头组件缺陷  &lt;br /&gt;指硬盘中磁头组件的某部分不正常，造成部分或全部物理磁头无法正常读写的情况。包括磁头磨损、磁头接触面脏、磁头摆臂变形、音圈受损、磁铁移位等。一般表 现为通电后，磁头动作发出的声音明显不正常，硬盘无法被系统BIOS检测到；无法分区格式化；格式化后发现从前到后都分布有大量的坏簇，等等。&lt;br /&gt;4.系统信息错乱  &lt;br /&gt;每个硬盘内部都有一个系统保留区（service area），里面分成若干模块保存有许多参数和程序。硬盘在通电自检时，要调用其中大部分程序和参数。如果能读出那些程序和参数模块，而且校验正常的话， 硬盘就进入准备状态。如果某些模块读不出或校验不正常，则该硬盘就无法进入准备状态。一般表现为，PC系统的BIOS无法检测到该硬盘或检测到该硬盘却无 法对它进行读写操作。如某些系列硬盘的常见问题：美钻二代系列硬盘通电后，磁头响一声，马达停转；Fujitsu MPG系列在通电后，磁头正常寻道，但 BIOS却检测不到；火球系列，系统能正常认出型号，却不能分区格式化；Western Digital的EB、BB系列，能被系统检测到，却不能分区格式化，等等。&lt;br /&gt;5.电子线路缺陷  &lt;br /&gt;指硬盘的电子线路板中部分线路断路或短路，某些电气元件或IC芯片损坏等。有部分可以通过观察线路板发现缺陷所在，有些则要通过仪器测量后才能确认缺陷部位。一般表现为硬盘在通电后不能正常起转，或者起转后磁头寻道不正常，等等。  &lt;br /&gt;6.综合性能缺陷  &lt;br /&gt;有些硬盘在使用过程中部分芯片特性改变；或者有些硬盘受震动后物理结构产生微小变化（如马达主轴受损）；或者有些硬盘在设计上存在缺陷……最终导致硬盘稳 定性差，或部分性能达不到标准要求。一般表现为，工作时噪音明显增大；读写速度明显太慢；同一系列的硬盘大量出现类似故障；某种故障时有时无等等。&lt;br /&gt;二、厂家处理缺陷的方式  &lt;br /&gt;用户在购买硬盘时，一般都通过各种工具检测硬盘没有缺陷后才会购买。而且，在质保期内可以找销售商将硬盘退回厂家修理。那么，厂家如何保证新硬盘不会被检测到缺陷呢？返修的硬盘又如何处理缺陷呢？首先，让我们来认识硬盘工厂的一些基本处理流程：  &lt;br /&gt;1.在生产线上装配硬盘的硬件部分，用特别设备往盘片写入伺服信号（Servo write）。  &lt;br /&gt;2.将硬盘的系统保留区（service area）格式化，并向系统保留区写入程序模块和参数模块。系统保留区一般位于硬盘0物理面的最前面几十个物理磁道。写入的程序模块一般用于硬盘内部管 理，如低级格式化程序、加密解密程序、自监控程序、自动修复程序等等。写入的参数多达近百项：如型号、系列号、容量、口令、生产厂家与生产日期、配件类 型、区域分配表、缺陷表、出错记录、使用时间记录、S.M.A.R.T表等等，数据量从几百KB到几MB不等。有时参数一经写入就不再改变，如型号、系列 号、生产时间等；而有些参数则可以在使用过程中由内部管理程序自动修改，如出错记录、使用时间记录、S.M.A.R.T记录等。也有些专业的维修人员可以 借助专业的工具软件，随意读取、修改写入硬盘中的程序模块和参数模块。&lt;br /&gt;3.将所使用的盘片表面按物理地址全面扫描，检查出所有的缺陷磁道和缺陷扇区，并将这些缺陷磁道和缺陷扇区按实际物理地址记录在永久缺陷列表（P- list：Permanent defect list）中。这个扫描过程非常严格，能把不稳定不可*的磁道和扇区也检查出来，视同缺陷一并处理。现在的硬盘密度极高，盘片生产过程再精密也很难完全避 免缺陷磁道或缺陷扇区。一般新硬盘的P-list中都有少则数十，多则上万个缺陷记录。P-list是保留在系统保留区中，一般用户是无法查看或修改的。 有些专业的维修人员借助专业的工具软件，可以查看或修改大部分硬盘中的P-list。&lt;br /&gt;4.系统调用内部低级格式化程序，根据相应的内部参数进行内部低级格式化。在内部低级格式化过程中，对所有的磁道和扇区进行编号、信息重写、清零等工作。 在编号时，采用跳过（skipped）的方法忽略掉记录在P-list中的缺陷磁道和缺陷扇区，保证以后用户不会也不能使用到那些缺陷磁道和缺陷扇区。因 此，新硬盘在出售时是无法被检测到缺陷的。如果是返修的硬盘，一般就在厂家特定的维修部门进行检测维修。&lt;br /&gt;小知识：什么是硬盘的磁道和扇区？磁 道是磁盘一个面上的单个数据存储圆圈。如果将磁道作为一个存储单元，从数据管理效率来看实在是太低了，因此，磁道被分成若干编上号的区域，称之为扇区。这 些扇区代表了磁道的分段（如图）。在PC系统中，通过标准格式化的程序产生的扇区容量都为512字节。这里大家需注意的是“扇区”与“簇”的关系，“簇” 是操作系统在读或写一个文件时能处理的最小磁盘单元，一个簇等于一个或多个扇区。&lt;br /&gt;三、硬盘缺陷的处理  &lt;br /&gt;&lt;br /&gt;如果不在硬盘工厂中，对普通用户或维修人员来说，又如何处理硬盘的缺陷呢？前面我们把硬盘的缺陷分为六大类，不同类型的缺陷用不同的处理方法。  &lt;br /&gt;1.对于综合性能缺陷，一般涉及到稳定性问题，用户随时有丢失数据的危险，可以说是“用之担惊，弃之可惜”。维修人员很难从根本上解决问题，建议用户还是趁早更换硬盘。  &lt;br /&gt;2.对于磁头组件缺陷，解决办法是更换磁头组件，这对设备及环境要求较高，维修成本也很高。除非是要求恢复其中的数据，否则不值得进行修复。有条件的维修公司可以在百级净化室中更换硬盘的磁头组件，对数据进行拯救。  &lt;br /&gt;3.对于线路缺陷，一般要求维修人员有电子线路基础，要有测试线路的经验和焊接芯片的设备，当然还要有必需的配件以备更换。目前许多专业维修硬盘的公司都有条件解决这类缺陷。对普通用户而言，最简单的判别和解决办法是找一个相同的正常线路板换上试试。  &lt;br /&gt;4.对于系统信息错乱，需要有专业的工具软件才能解决。首先要找个与待修硬盘参数完全相同的正常硬盘，读出其内部所有模块并保存下来；检查待修硬盘的系统 结构，查到出错的模块，并将正常模块的参数重新写入。笔者用这个方法成功地修复了数以千计有这种缺陷类型的硬盘，而且一般不会破坏原有数据。要想写某系列 硬盘的系统信息，相应的工具软件必须有严格针对性；该硬盘的CPU专用指令集；该硬盘的Firmware结构；内部管理程序和参数模块结构。一般只有硬盘 厂家才能编写这样的专业工具软件，而且视为绝密技术，不向外界提供。但也有一些专业的硬盘研究所研究开发类似的专业工具软件，一般要价很高而且很难买到。&lt;br /&gt;5.对于伺服缺陷，也要借助于专业工具。相应的专业工具可以通过重写来纠正伺服信息，解决部分磁道伺服缺陷。如果有部分无法纠正，则要对盘片进行物理磁道 扫描找出有伺服缺陷的磁道，添加到P-list（或另外的专门磁道缺陷列表）中。然后，运行硬盘内部的低级格式化程序。这段程序能自动根据需要调用相关的 参数模块，自动完成硬盘的低格过程，不需要PC系统的干预。&lt;br /&gt;坏扇区是最常见的缺陷类型，下面笔者着重论述。  &lt;br /&gt;四、坏扇区的修复原理  &lt;br /&gt;按“三包”规定，如果硬盘在质保期内出现缺陷，商家应该为用户更换或修理。现在大容量的硬盘出现一个坏扇区的概率实在很大，如果全部送修的话，硬盘商家就 要为售后服务忙碌不已了。很多硬盘商家都说，硬盘出现少量坏扇区往往是病毒作怪或某些软件造成的，不是真正的坏扇区，只要运行硬盘厂家提供的某些软件，就 可以纠正了。到底是怎么回事呢？从前面对坏扇区的说明来看，坏扇区有多种可能的原因，修复的方法也有几种：&lt;br /&gt;1.通过重写校验码、标志信息等可以纠正一部分坏扇区。现在硬盘厂家都公开提供有一些基本的硬盘维护工具，如各种版本的DM、POWERMAX、 DLGDIAG等，其中都包括有这样的功能项：Zero fill（零填充）或Lowlevel format（低级格式化）。进行这两项功能都会对硬盘的数据进行清零，并重写每个扇区的校验码和标志信息。如果不是磁盘表面介质损伤的话，大部分的坏扇 区可以纠正为正常状态。这就是常听说的：“逻辑坏扇区可以修复”的道理。&lt;br /&gt;2.调用自动修复机制替换坏扇区。为了减少硬盘返修的概率，硬盘厂商在硬盘内部设计了一个自动修复机制?Automatic Reallcation或Automatic Reassign?。现在生产的硬盘都有这样的功能：在对硬盘的读写过程中，如果发现一个坏扇区，则由内部管理程序自动分配一个备用扇区来替换该扇区，并 将该扇区物理位置及其替换情况记录在G-list（增长缺陷表，Grown defects list?中。这样一来，少量的坏扇区有可能在使用过程中被自动替换掉了，对用户的使用没有太大的影响。也有一些硬盘自动修复机制的激发条件要严格一些， 需要运行某些软件来检测判断坏扇区，并发出相应指令激发自动修复功能。比如常用的Lformat（低格）?DM中的Zero fill，Norton中的Wipeinfo和校正工具，西数工具包中的wddiag，IBM的DFT中的Erase，还有一些半专业工具如： HDDspeed、MHDD、HDDL、HDDutility等（大家可以上网搜索下载）。这些工具之所以能在运行过后消除了一些坏扇区，很重要的原因就 是这些工具可以在检测到坏扇区时激发自动修复机制。如果读者能查看G-list就知道，这些“修复工具”运行前后，G-list记录有可能增加一定数量。 如：用HDDspeed可以查看所有Quantum Fireball系列的P-list和G-list；MHDD可以查看IBM和FUJITSU的P-list和G-list。&lt;br /&gt;当然，G- list的记录不会无限制，所有硬盘的G-list都会限定在一定数量范围内。如火球系列限度是500条，美钻二代的限度是636条，西数BB的限度是 508条，等等。超过限度，自动修复机制就不能再起作用。这就是为何少量的坏扇区可以通过上述工具修复，而坏扇区多了不能通过这些工具修复。&lt;br /&gt;3.用专业软件将缺陷扇区记录在P-list中，并进行内部低级格式化。用户在使用硬盘时，是不能按物理地址模式来访问硬盘的。而是按逻辑地址模式来访 问。硬盘在通电自检时，系统会从系统保留区读取一些特定参数（与内部低级格式化时调用的参数有密切关系）存在缓冲区里，用作物理地址与逻辑地址之间转换的 依据。有些专业软件可以将检测到的坏扇区的逻辑地址转换为对应的物理地址，直接记录在P-list中，然后调用内部低级格式化程序进行低级格式化。这样可 以不受G-list的限制，能修复大量的坏扇区，达到厂家修复的效果。&lt;br /&gt;五、关于“坏道”的一点补充  &lt;br /&gt;“坏道（Bad track）”这个概念源于十多年前小容量硬盘（如ST506接口、100MB以下）。当时的硬盘内部没有什么系统保留区，也就没有P-list或G- list。出厂前，厂家就扫描硬盘中存在坏扇区的磁道，并将其位置记录在一张小表格中，贴在硬盘外壳上，注明“Bad track list”，即常说的“坏道表”。而“坏道表”上就列出某磁头某柱面的磁道是坏磁道，这就是我们常听人说的“坏道”。当时所有的硬盘在第一次使用前都要求 做低级格式化（Low level format，简称“低格”），在使用过程中也可以根据需要做低级格式化。在对这个硬盘进行低级格式化前（如用ADM、低版本DM、早期主板中自带的低格 工具等），要将坏道表中记录都填入，或用工具自动扫描所有坏道，然后才进行低级格式化过程。低格过程中，低格程序对所有磁道按一定的规律进行编号，同时将 前面记录或扫描到的坏道排除在外，即“跳过（Skipped）”那些位置，对用户来说可以算是“修好”了“坏道”。而如果哪个用户轻易对硬盘进行低格，却 没有登记坏道，那么低格会令以前曾“跳过”的坏道一个个又重新显现出来，这就是为什么当时人们常说低格会令硬盘增加坏道的原因。&lt;br /&gt;那么，现在笔者为什么不用“坏道”概念而用“缺陷”概念呢？以前的老硬盘，通过低格来修复，只要某磁道中出现一个坏扇区，该磁道就算“坏磁道（Bad Track）”，修复时就整个磁道所有扇区一起“跳过（skipped）”。所以，坏磁道和坏扇区没有区别开来，一起被称为“坏道”也还算贴切。而现在的 硬盘，每个磁道划分为数百上千个扇区，不能因为有一个坏扇区就丢掉整个磁道。而且有些硬盘出厂前P-list就记录数千个坏扇区，如果丢掉数千个磁道（意 味道要丢掉数GB的空间）就太浪费了。而现在的硬盘不同的缺陷有不同的表现，不同的原因，修复方法也各不相同。如果继续用“坏磁道”或“坏道”来概括多种 缺陷，很明显词不达意&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-6722352752960290897?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/6722352752960290897/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=6722352752960290897' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6722352752960290897'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6722352752960290897'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/linuxfreebsd.html' title='linux/freebsd检查硬盘坏道'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-6772867829056372759</id><published>2008-11-04T10:33:00.000+08:00</published><updated>2008-11-04T10:35:41.765+08:00</updated><title type='text'>Nano基础指南(from CU)</title><content type='html'>1.  Nano基础&lt;br /&gt;目的&lt;br /&gt;这是篇nano简明使用指南，帮助你快速了解nano的基本用法。如想获取更多的帮助信息，请参阅：&lt;br /&gt;http://www.nano-editor.org&lt;br /&gt;打开文件与新建文件&lt;br /&gt;使用nano打开或新建文件，只需键入：&lt;br /&gt;代码 1.1: 打开或新建文件&lt;br /&gt;# nano 文件名&lt;br /&gt;Nano是一种单模式编辑器，你可以直接输入文字。如果你要编辑一个像/etc/fstab一样的配置文件，请使用-w参数，例如：&lt;br /&gt;代码 1.2: 禁用自动换行&lt;br /&gt;# nano -w /etc/fstab&lt;br /&gt;警告: 这非常重要。如果在编辑配置文件时忘了加-w参数，可能会导致你的系统无法起动或产生别的异常。&lt;br /&gt;保存和退出&lt;br /&gt;如果你要保存所做的修改，按下Ctrl+O。想要退出，按下Ctrl+X。如果你退出前没有保存所做的修改，它会提示你是否要保存。如果不要，请按N，反之，则按Y。然后它会让你确认要保存的文件名，确认或修改后按Enter即可。&lt;br /&gt;如果你没有修改好而不小心按了保存键，您可以在请求确认文件名时按Ctrl+C来取消。&lt;br /&gt;剪切和粘贴&lt;br /&gt;要剪切一整行，请用Ctrl+K（按住Ctrl不放，再按下K键）。光标所在的行便消失了。要粘贴它，只需把光标移动到您所要粘贴的位置，然后按 Ctrl+U即可。要移动多行，只需多按几次Ctrl+K把需要移动内容都剪切下来，然后按一次Ctrl+U就可以把刚剪切的内容全部粘贴上来。&lt;br /&gt;如果你想使用更精确的剪切控制，则需要给文本做标记。移动光标到需要剪切文本的开头，按下Ctrl+6（或者Alt+A）。然后移动光标到待剪切文本的末 尾：被做了标记的文本便会反白。要撤消文本标记，只需再按一次Ctrl+6。用Ctrl+K来剪切被标记的文本，用Ctrl+U来粘贴。&lt;br /&gt;搜索特定文字&lt;br /&gt;当你想搜索某特定文字时，只要想成"WhereIs"而不是"Search"，事情就简单了。只要按下Ctrl+W，键入你要搜索的字符串，再按Enter就可以了。想再次搜索相同的字符串，可以直接按Alt+W。&lt;br /&gt;注意: 在nano帮助文档里，Ctrl-键被表示为一个脱字符（^），因此Ctrl+W被写成了^W，等等。Alt-键被表示为一个M（从"Meta"而来），因此Alt+W被写成了M-W。&lt;br /&gt;更多选项&lt;br /&gt;如果你有兴趣调整nano设置，一定去看看/etc/nanorc。&lt;br /&gt;要了解更多的nano信息，请参阅：&lt;br /&gt;http://www.nano-editor.org&lt;br /&gt;&lt;br /&gt;from chinaunix.net&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-6772867829056372759?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/6772867829056372759/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=6772867829056372759' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6772867829056372759'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6772867829056372759'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/nanofrom-cu.html' title='Nano基础指南(from CU)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-2802934622943050761</id><published>2008-11-03T17:52:00.000+08:00</published><updated>2008-11-03T17:53:17.385+08:00</updated><title type='text'>生成.htaccess的工具(Cool)</title><content type='html'>可以自动生成.htaccess的工具，很Cool!&lt;br /&gt;http://cooletips.de/htaccess/&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-2802934622943050761?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/2802934622943050761/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=2802934622943050761' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2802934622943050761'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2802934622943050761'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/htaccesscool.html' title='生成.htaccess的工具(Cool)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-3161414374319528936</id><published>2008-11-03T10:16:00.000+08:00</published><updated>2008-11-03T10:18:28.680+08:00</updated><title type='text'>自制版OS8.10发布(Ubuntu810)</title><content type='html'>http://club.pojaa.com/thread-38280-1-1.html&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-3161414374319528936?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/3161414374319528936/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=3161414374319528936' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3161414374319528936'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3161414374319528936'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/os810ubuntu810.html' title='自制版OS8.10发布(Ubuntu810)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7377938103171734749</id><published>2008-11-01T13:31:00.001+08:00</published><updated>2008-11-01T13:37:38.432+08:00</updated><title type='text'>mplayer/codec drvc.dll</title><content type='html'>mplayer使用时出现下面错误&lt;br /&gt;&lt;br /&gt;error：could not open required directshow codec drvc.dll&lt;br /&gt;&lt;br /&gt;解决方法：&lt;br /&gt;&lt;br /&gt;[root@localhost ~]#  find /usr/lib -name drvc*&lt;br /&gt;[root@localhost ~]# find /usr/lib -name drvc*&lt;br /&gt;/usr/lib/codecs/drvc.so&lt;br /&gt;[root@localhost ~]# ldd /usr/lib/codecs/drvc.so&lt;br /&gt;       linux-gate.so.1 =&gt; (0x00110000)&lt;br /&gt;       libstdc++.so.5 =&gt; &lt;span style="color:Red;"&gt;not found&lt;/span&gt;&lt;br /&gt;       libc.so.6 =&gt; /lib/libc.so.6 (0x00162000)&lt;br /&gt;       /lib/ld-linux.so.2 (0x004ed000)&lt;br /&gt;&lt;br /&gt;sudo apt-get install libstdc++5&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7377938103171734749?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7377938103171734749/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7377938103171734749' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7377938103171734749'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7377938103171734749'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/11/mplayercodec-drvcdll.html' title='mplayer/codec drvc.dll'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-3826085992369653541</id><published>2008-10-28T16:40:00.000+08:00</published><updated>2008-10-28T16:41:17.396+08:00</updated><title type='text'>Ubuntu8.10 速配指南(转自cu)</title><content type='html'>从这里开始  &lt;div&gt;请确保你的系统已联入互联网。如有困难请参考HOW-TO连接到互联网或到论坛寻求帮助。&lt;br /&gt;打开终端。单击主菜单中的“应用程序 - 附件 - 终端”。&lt;br /&gt;修改更新服务器列表。请在终端中执行下面的两条命令：&lt;br /&gt;sudo cp /etc/apt/sources.list /etc/apt/sources.list_backup&lt;br /&gt;sudo gedit /etc/apt/sources.list&lt;br /&gt;注意:接下来在打开的文本编辑器中，把你看到的内容全部删掉，访问 我们推荐的源页面。在那里里请选择一组对于你来说速度最快&lt;/div&gt; &lt;div&gt;的更新服务器列表。粘贴到你所看到的窗口中。 &lt;/div&gt; &lt;div&gt;对电信/网通用户，推荐将欧洲官方源服务器粘贴到最后 &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; Intrepid main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; Intrepid-security main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; Intrepid-updates main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; Intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; Intrepid-backports main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; Intrepid main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; Intrepid-security main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; Intrepid-updates main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; Intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; Intrepid-backports main restricted universe multiverse&lt;br /&gt;推荐所有用户加入 ubuntu-cn 源（从以下两个中选择一个即可）*此处暂时用hardy* &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://archive.ubuntu.org.cn/ubuntu-cn/"&gt;http://archive.ubuntu.org.cn/ubuntu-cn/&lt;/a&gt; hardy main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://ubuntu.cn99.com/ubuntu-cn/"&gt;http://ubuntu.cn99.com/ubuntu-cn/&lt;/a&gt; hardy main restricted universe multiverse&lt;br /&gt;4.更新软件包列表。执行下面的命令：&lt;br /&gt;sudo apt-get update&lt;br /&gt;5.安装系统更新&lt;br /&gt;打开“系统-&gt;系统管理-&gt;更新管理器”，安装更新。完成后若系统提示重新启动，请重新启动系统。&lt;br /&gt;&lt;br /&gt;语言支持对话框[编辑] 设置中文环境&lt;br /&gt;重要：继续之前请确定本文前面的操作你都完成了&lt;br /&gt;单击主菜单中的“系统(System) --&gt; 系统管理(Administration) --&gt; 语言支持(language support)”。&lt;br /&gt;在“支持的语言”列表中找到“汉语（Chinese）”，在右端打上勾。同时将默认语言修改为“汉语（Chinese）”并勾选“启用复杂&lt;/div&gt; &lt;div&gt;字符输入支持（Enable support to enter complex characters）”，点击确定按钮。&lt;br /&gt;Ubuntu 这时会下载并安装语言包。安装完毕之后，当你注销后重新登录，界面就变成中文的了。&lt;br /&gt;如果你喜欢用 Adobe Reader 来阅读 pdf 文档，可在官网下载或者本地下载&lt;br /&gt;设置文档查看器 Evince 的中文支持：&lt;br /&gt;sudo apt-get install xpdf-chinese-simplified xpdf-chinese-traditional poppler-data&lt;br /&gt;[编辑] 安装硬件驱动&lt;br /&gt;&lt;br /&gt;硬件支持菜单 如左图打开 “系统-&gt;系统管理-&gt;硬件驱动”。Ubuntu 自动开始查找可用驱动程序，选中你需要启用的硬件驱动程序（&lt;/div&gt; &lt;div&gt;如显卡驱动），Ubuntu将自动为你安装。完装完成后，请按系统提示重启操作系统。  &lt;/div&gt; &lt;div&gt;[编辑] 设置 Firefox&lt;br /&gt;安装Flash插件&lt;br /&gt;sudo apt-get install adobe-flashplugin&lt;br /&gt;另一种方法&lt;br /&gt;wget &lt;a href="http://ubuntu:ubuntuftp@ftp.ubuntu.org.cn/home/dbzhang800/wiki/install_flash_player_10_linux.deb"&gt;http://ubuntu:ubuntuftp@ftp.ubuntu.org.cn/home/dbzhang800/wiki/install_flash_player_10_linux.deb&lt;/a&gt;&lt;br /&gt;sudo dpkg -i install_flash_player_10_linux.deb&lt;br /&gt;关于firefox的插件及其他设置，请参考Firefox常用扩展插件&lt;br /&gt;[编辑] 设置QQ&lt;br /&gt;在 腾讯官方 &lt;a href="http://im.qq.com/qq/linux/download.shtml"&gt;http://im.qq.com/qq/linux/download.shtml&lt;/a&gt; 下载 deb 安装包后，双击即可安装&lt;br /&gt;[编辑] 多媒体应用环境设置&lt;br /&gt;推荐能连接国外网的用户加入Medibuntu源，输入命令 &lt;/div&gt; &lt;div&gt;sudo wget &lt;a href="http://www.medibuntu.org/sources.list.d/intrepid.list"&gt;http://www.medibuntu.org/sources.list.d/intrepid.list&lt;/a&gt; -O /etc/apt/sources.list.d/medibuntu.list&lt;br /&gt;sudo apt-get update &amp;amp;&amp;amp; sudo apt-get install medibuntu-keyring &amp;amp;&amp;amp; sudo apt-get update&lt;br /&gt;其他用户要确保已加入ubuntu-cn源 &lt;/div&gt; &lt;div&gt;安装多媒体解码器，输入命令 &lt;/div&gt; &lt;div&gt;Xine多媒体引擎解码器&lt;br /&gt;sudo apt-get install libxine1-ffmpeg libxine1-all-plugins libxine1-plugins w32codecs gcc-3.3-base libstdc++5&lt;br /&gt;Gstreamer多媒体引擎解码器&lt;br /&gt;sudo apt-get install gstreamer0.10-ffmpeg gstreamer0.10-pitfdll gstreamer0.10-plugins-bad gstreamer0.10-plugins-bad-&lt;/div&gt; &lt;div&gt;multiverse gstreamer0.10-plugins-ugly gstreamer0.10-plugins-ugly-multiverse gstreamer0.10-esd&lt;br /&gt;DVD影碟功能支持&lt;br /&gt;sudo apt-get install libdvdnav4 libdvdread3 libdvdcss2&lt;br /&gt;配置电影播放器 &lt;/div&gt; &lt;div&gt;sudo apt-get remove totem-mozilla -y&lt;br /&gt;sudo apt-get install smplayer smplayer-themes mozilla-mplayer&lt;br /&gt;更多关于电影播放器 (Totem-xine) 的设置问题请参考Xine前端播放器设置问题&lt;br /&gt;配置音乐播放器，输入命令 &lt;/div&gt; &lt;div&gt;sudo apt-get install gstreamer0.10-fluendo-mpegdemux gstreamer0.10-gnonlin libflashsupport&lt;br /&gt;你可能还喜欢音乐播放器 Audacious、xmms、bmp，视频播放器 MPlayer 和 RealPlayer&lt;br /&gt;[编辑] 设置工具软件&lt;br /&gt;安装词典软件 &lt;/div&gt; &lt;div&gt;星际译王 (stardict) 是 Linux 下类似于金山词霸的辞典软件。&lt;/div&gt; &lt;div&gt;&lt;br /&gt;如需给 stardict 添加更多的词库或真人发音，请访问星际译王&lt;br /&gt;准备基本编译工具，输入命令 &lt;/div&gt; &lt;div&gt;sudo apt-get install build-essential autoconf automake1.9 cvs subversion&lt;br /&gt;编译所需软件时使用的开发库请参考该软件的相关文档。可选设置中提供了几个最基础的开发库。 &lt;/div&gt; &lt;div&gt;安装压缩工具&lt;/div&gt; &lt;div&gt;&lt;br /&gt;安装rar、7z、cab格式支持，输入命令&lt;br /&gt;sudo apt-get install unrar p7zip-full cabextract&lt;/div&gt; &lt;div&gt;大功告成，现在我们的系统已经能很好的工作了。请注销重新进入桌面！ &lt;/div&gt; &lt;div&gt;很好，对Ubuntu系统的基本设置，你已经完成。不过这些设置对于你来说远远不够，请参看热门设置条目继续对您的系统进行微调，&lt;/div&gt; &lt;div&gt;当然热门设置里的内容不是所有人必须要做的。请针对自己的情况有选择的操作。 &lt;/div&gt; &lt;div&gt;&lt;br /&gt; &lt;/div&gt; &lt;div&gt; &lt;/div&gt; &lt;div&gt;推荐的源页面&lt;/div&gt; &lt;div&gt;**********************************************************************&lt;/div&gt; &lt;div&gt;Archive.ubuntu.com更新服务器（欧洲，此为官方源，电信网通用户使用)： &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://archive.ubuntu.com/ubuntu/"&gt;http://archive.ubuntu.com/ubuntu/&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;/div&gt; &lt;div&gt;Ubuntu.cn99.com更新服务器（江苏省常州市电信，推荐电信用户使用）： &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://ubuntu.cn99.com/ubuntu/"&gt;http://ubuntu.cn99.com/ubuntu/&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://ubuntu.cn99.com/ubuntu/"&gt;http://ubuntu.cn99.com/ubuntu/&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://ubuntu.cn99.com/ubuntu/"&gt;http://ubuntu.cn99.com/ubuntu/&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://ubuntu.cn99.com/ubuntu/"&gt;http://ubuntu.cn99.com/ubuntu/&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://ubuntu.cn99.com/ubuntu/"&gt;http://ubuntu.cn99.com/ubuntu/&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://ubuntu.cn99.com/ubuntu/"&gt;http://ubuntu.cn99.com/ubuntu/&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://ubuntu.cn99.com/ubuntu/"&gt;http://ubuntu.cn99.com/ubuntu/&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://ubuntu.cn99.com/ubuntu/"&gt;http://ubuntu.cn99.com/ubuntu/&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://ubuntu.cn99.com/ubuntu/"&gt;http://ubuntu.cn99.com/ubuntu/&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://ubuntu.cn99.com/ubuntu/"&gt;http://ubuntu.cn99.com/ubuntu/&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;/div&gt; &lt;div&gt;Mirrors.shlug.org更新服务器（电信服务器，Ubuntu China Official Mirror, maintained by Shanghai Linux User Group）： &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://cn.archive.ubuntu.com/ubuntu"&gt;http://cn.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://cn.archive.ubuntu.com/ubuntu"&gt;http://cn.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://cn.archive.ubuntu.com/ubuntu"&gt;http://cn.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://cn.archive.ubuntu.com/ubuntu"&gt;http://cn.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://cn.archive.ubuntu.com/ubuntu"&gt;http://cn.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://cn.archive.ubuntu.com/ubuntu"&gt;http://cn.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://cn.archive.ubuntu.com/ubuntu"&gt;http://cn.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://cn.archive.ubuntu.com/ubuntu"&gt;http://cn.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://cn.archive.ubuntu.com/ubuntu"&gt;http://cn.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://cn.archive.ubuntu.com/ubuntu"&gt;http://cn.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;/div&gt; &lt;div&gt;Mirror.lupaworld.com更新服务器（浙江省杭州市双线服务器）： &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://mirror.lupaworld.com/ubuntu"&gt;http://mirror.lupaworld.com/ubuntu&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://mirror.lupaworld.com/ubuntu"&gt;http://mirror.lupaworld.com/ubuntu&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://mirror.lupaworld.com/ubuntu"&gt;http://mirror.lupaworld.com/ubuntu&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://mirror.lupaworld.com/ubuntu"&gt;http://mirror.lupaworld.com/ubuntu&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://mirror.lupaworld.com/ubuntu"&gt;http://mirror.lupaworld.com/ubuntu&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://mirror.lupaworld.com/ubuntu"&gt;http://mirror.lupaworld.com/ubuntu&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://mirror.lupaworld.com/ubuntu"&gt;http://mirror.lupaworld.com/ubuntu&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://mirror.lupaworld.com/ubuntu"&gt;http://mirror.lupaworld.com/ubuntu&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://mirror.lupaworld.com/ubuntu"&gt;http://mirror.lupaworld.com/ubuntu&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://mirror.lupaworld.com/ubuntu"&gt;http://mirror.lupaworld.com/ubuntu&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;/div&gt; &lt;div&gt;&lt;br /&gt;厦门大学更新服务器（教育网服务器）： &lt;/div&gt; &lt;div&gt;deb &lt;a href="ftp://ubuntu.realss.cn/ubuntu/"&gt;ftp://ubuntu.realss.cn/ubuntu/&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb &lt;a href="ftp://ubuntu.realss.cn/ubuntu/"&gt;ftp://ubuntu.realss.cn/ubuntu/&lt;/a&gt; intrepid-backports restricted universe multiverse&lt;br /&gt;deb &lt;a href="ftp://ubuntu.realss.cn/ubuntu/"&gt;ftp://ubuntu.realss.cn/ubuntu/&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb &lt;a href="ftp://ubuntu.realss.cn/ubuntu/"&gt;ftp://ubuntu.realss.cn/ubuntu/&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb &lt;a href="ftp://ubuntu.realss.cn/ubuntu/"&gt;ftp://ubuntu.realss.cn/ubuntu/&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="ftp://ubuntu.realss.cn/ubuntu/"&gt;ftp://ubuntu.realss.cn/ubuntu/&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="ftp://ubuntu.realss.cn/ubuntu/"&gt;ftp://ubuntu.realss.cn/ubuntu/&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="ftp://ubuntu.realss.cn/ubuntu/"&gt;ftp://ubuntu.realss.cn/ubuntu/&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="ftp://ubuntu.realss.cn/ubuntu/"&gt;ftp://ubuntu.realss.cn/ubuntu/&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="ftp://ubuntu.realss.cn/ubuntu/"&gt;ftp://ubuntu.realss.cn/ubuntu/&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;/div&gt; &lt;div&gt;成都市 电子科技大学更新服务器（教育网，推荐校园网和网通用户使用）： &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://ubuntu.uestc.edu.cn/ubuntu/"&gt;http://ubuntu.uestc.edu.cn/ubuntu/&lt;/a&gt; intrepid main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ubuntu.uestc.edu.cn/ubuntu/"&gt;http://ubuntu.uestc.edu.cn/ubuntu/&lt;/a&gt; intrepid-backports main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ubuntu.uestc.edu.cn/ubuntu/"&gt;http://ubuntu.uestc.edu.cn/ubuntu/&lt;/a&gt; intrepid-proposed main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ubuntu.uestc.edu.cn/ubuntu/"&gt;http://ubuntu.uestc.edu.cn/ubuntu/&lt;/a&gt; intrepid-security main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ubuntu.uestc.edu.cn/ubuntu/"&gt;http://ubuntu.uestc.edu.cn/ubuntu/&lt;/a&gt; intrepid-updates main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.uestc.edu.cn/ubuntu/"&gt;http://ubuntu.uestc.edu.cn/ubuntu/&lt;/a&gt; intrepid main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.uestc.edu.cn/ubuntu/"&gt;http://ubuntu.uestc.edu.cn/ubuntu/&lt;/a&gt; intrepid-backports main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.uestc.edu.cn/ubuntu/"&gt;http://ubuntu.uestc.edu.cn/ubuntu/&lt;/a&gt; intrepid-proposed main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.uestc.edu.cn/ubuntu/"&gt;http://ubuntu.uestc.edu.cn/ubuntu/&lt;/a&gt; intrepid-security main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.uestc.edu.cn/ubuntu/"&gt;http://ubuntu.uestc.edu.cn/ubuntu/&lt;/a&gt; intrepid-updates main multiverse restricted universe&lt;/div&gt; &lt;div&gt;== 如果无法解析uestc.edu.cn域名，请使用以下地址 ==&lt;/div&gt; &lt;div&gt;deb &lt;a href="http://ubuntu.dormforce.net/ubuntu/"&gt;http://ubuntu.dormforce.net/ubuntu/&lt;/a&gt; intrepid main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ubuntu.dormforce.net/ubuntu/"&gt;http://ubuntu.dormforce.net/ubuntu/&lt;/a&gt; intrepid-backports main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ubuntu.dormforce.net/ubuntu/"&gt;http://ubuntu.dormforce.net/ubuntu/&lt;/a&gt; intrepid-proposed main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ubuntu.dormforce.net/ubuntu/"&gt;http://ubuntu.dormforce.net/ubuntu/&lt;/a&gt; intrepid-security main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ubuntu.dormforce.net/ubuntu/"&gt;http://ubuntu.dormforce.net/ubuntu/&lt;/a&gt; intrepid-updates main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.dormforce.net/ubuntu/"&gt;http://ubuntu.dormforce.net/ubuntu/&lt;/a&gt; intrepid main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.dormforce.net/ubuntu/"&gt;http://ubuntu.dormforce.net/ubuntu/&lt;/a&gt; intrepid-backports main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.dormforce.net/ubuntu/"&gt;http://ubuntu.dormforce.net/ubuntu/&lt;/a&gt; intrepid-proposed main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.dormforce.net/ubuntu/"&gt;http://ubuntu.dormforce.net/ubuntu/&lt;/a&gt; intrepid-security main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.dormforce.net/ubuntu/"&gt;http://ubuntu.dormforce.net/ubuntu/&lt;/a&gt; intrepid-updates main multiverse restricted universe&lt;/div&gt; &lt;div&gt;&lt;br /&gt;上海市上海交通大学更新服务器（教育网，推荐校园网和网通用户使用）： &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://ftp.sjtu.edu.cn/ubuntu/"&gt;http://ftp.sjtu.edu.cn/ubuntu/&lt;/a&gt; intrepid main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ftp.sjtu.edu.cn/ubuntu/"&gt;http://ftp.sjtu.edu.cn/ubuntu/&lt;/a&gt; intrepid-backports main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ftp.sjtu.edu.cn/ubuntu/"&gt;http://ftp.sjtu.edu.cn/ubuntu/&lt;/a&gt; intrepid-proposed main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ftp.sjtu.edu.cn/ubuntu/"&gt;http://ftp.sjtu.edu.cn/ubuntu/&lt;/a&gt; intrepid-security main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://ftp.sjtu.edu.cn/ubuntu/"&gt;http://ftp.sjtu.edu.cn/ubuntu/&lt;/a&gt; intrepid-updates main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ftp.sjtu.edu.cn/ubuntu/"&gt;http://ftp.sjtu.edu.cn/ubuntu/&lt;/a&gt; intrepid main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ftp.sjtu.edu.cn/ubuntu/"&gt;http://ftp.sjtu.edu.cn/ubuntu/&lt;/a&gt; intrepid-backports main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ftp.sjtu.edu.cn/ubuntu/"&gt;http://ftp.sjtu.edu.cn/ubuntu/&lt;/a&gt; intrepid-proposed main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ftp.sjtu.edu.cn/ubuntu/"&gt;http://ftp.sjtu.edu.cn/ubuntu/&lt;/a&gt; intrepid-security main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ftp.sjtu.edu.cn/ubuntu/"&gt;http://ftp.sjtu.edu.cn/ubuntu/&lt;/a&gt; intrepid-updates main multiverse restricted universe&lt;/div&gt; &lt;div&gt;&lt;br /&gt;中国科学技术大学更新服务器（教育网，推荐校园网和网通用户使用）： &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://debian.ustc.edu.cn/ubuntu/"&gt;http://debian.ustc.edu.cn/ubuntu/&lt;/a&gt; intrepid main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://debian.ustc.edu.cn/ubuntu/"&gt;http://debian.ustc.edu.cn/ubuntu/&lt;/a&gt; intrepid-backports main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://debian.ustc.edu.cn/ubuntu/"&gt;http://debian.ustc.edu.cn/ubuntu/&lt;/a&gt; intrepid-proposed main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://debian.ustc.edu.cn/ubuntu/"&gt;http://debian.ustc.edu.cn/ubuntu/&lt;/a&gt; intrepid-security main multiverse restricted universe&lt;br /&gt;deb &lt;a href="http://debian.ustc.edu.cn/ubuntu/"&gt;http://debian.ustc.edu.cn/ubuntu/&lt;/a&gt; intrepid-updates main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://debian.ustc.edu.cn/ubuntu/"&gt;http://debian.ustc.edu.cn/ubuntu/&lt;/a&gt; intrepid main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://debian.ustc.edu.cn/ubuntu/"&gt;http://debian.ustc.edu.cn/ubuntu/&lt;/a&gt; intrepid-backports main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://debian.ustc.edu.cn/ubuntu/"&gt;http://debian.ustc.edu.cn/ubuntu/&lt;/a&gt; intrepid-proposed main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://debian.ustc.edu.cn/ubuntu/"&gt;http://debian.ustc.edu.cn/ubuntu/&lt;/a&gt; intrepid-security main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://debian.ustc.edu.cn/ubuntu/"&gt;http://debian.ustc.edu.cn/ubuntu/&lt;/a&gt; intrepid-updates main multiverse restricted universe&lt;/div&gt; &lt;div&gt;中国台湾 台湾大学更新服务器（推荐网通用户使用，电信PING平均响应速度41MS。强烈推荐此源，比较完整，较少出现同步问题）： &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://ubuntu.csie.ntu.edu.tw/ubuntu/"&gt;http://ubuntu.csie.ntu.edu.tw/ubuntu/&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://ubuntu.csie.ntu.edu.tw/ubuntu/"&gt;http://ubuntu.csie.ntu.edu.tw/ubuntu/&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://ubuntu.csie.ntu.edu.tw/ubuntu/"&gt;http://ubuntu.csie.ntu.edu.tw/ubuntu/&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://ubuntu.csie.ntu.edu.tw/ubuntu/"&gt;http://ubuntu.csie.ntu.edu.tw/ubuntu/&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://ubuntu.csie.ntu.edu.tw/ubuntu/"&gt;http://ubuntu.csie.ntu.edu.tw/ubuntu/&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://ubuntu.csie.ntu.edu.tw/ubuntu/"&gt;http://ubuntu.csie.ntu.edu.tw/ubuntu/&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://ubuntu.csie.ntu.edu.tw/ubuntu/"&gt;http://ubuntu.csie.ntu.edu.tw/ubuntu/&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://ubuntu.csie.ntu.edu.tw/ubuntu/"&gt;http://ubuntu.csie.ntu.edu.tw/ubuntu/&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://ubuntu.csie.ntu.edu.tw/ubuntu/"&gt;http://ubuntu.csie.ntu.edu.tw/ubuntu/&lt;/a&gt; intrepid-proposed main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://ubuntu.csie.ntu.edu.tw/ubuntu/"&gt;http://ubuntu.csie.ntu.edu.tw/ubuntu/&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;mirror.rootguide.org更新服务器（上海市 电信）： &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://mirror.rootguide.org/ubuntu/"&gt;http://mirror.rootguide.org/ubuntu/&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://mirror.rootguide.org/ubuntu/"&gt;http://mirror.rootguide.org/ubuntu/&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://mirror.rootguide.org/ubuntu/"&gt;http://mirror.rootguide.org/ubuntu/&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://mirror.rootguide.org/ubuntu/"&gt;http://mirror.rootguide.org/ubuntu/&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://mirror.rootguide.org/ubuntu/"&gt;http://mirror.rootguide.org/ubuntu/&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://mirror.rootguide.org/ubuntu/"&gt;http://mirror.rootguide.org/ubuntu/&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://mirror.rootguide.org/ubuntu/"&gt;http://mirror.rootguide.org/ubuntu/&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://mirror.rootguide.org/ubuntu/"&gt;http://mirror.rootguide.org/ubuntu/&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://mirror.rootguide.org/ubuntu/"&gt;http://mirror.rootguide.org/ubuntu/&lt;/a&gt; intrepid-proposed main multiverse restricted universe&lt;br /&gt;deb-src &lt;a href="http://mirror.rootguide.org/ubuntu/"&gt;http://mirror.rootguide.org/ubuntu/&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;/div&gt; &lt;div&gt;台湾的官方源速度也相当不错，有时甚至快于内地的： &lt;/div&gt; &lt;div&gt;deb &lt;a href="http://tw.archive.ubuntu.com/ubuntu"&gt;http://tw.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://tw.archive.ubuntu.com/ubuntu"&gt;http://tw.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://tw.archive.ubuntu.com/ubuntu"&gt;http://tw.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://tw.archive.ubuntu.com/ubuntu"&gt;http://tw.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb &lt;a href="http://tw.archive.ubuntu.com/ubuntu"&gt;http://tw.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://tw.archive.ubuntu.com/ubuntu"&gt;http://tw.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://tw.archive.ubuntu.com/ubuntu"&gt;http://tw.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-security main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://tw.archive.ubuntu.com/ubuntu"&gt;http://tw.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-updates main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://tw.archive.ubuntu.com/ubuntu"&gt;http://tw.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-backports main restricted universe multiverse&lt;br /&gt;deb-src &lt;a href="http://tw.archive.ubuntu.com/ubuntu"&gt;http://tw.archive.ubuntu.com/ubuntu&lt;/a&gt; intrepid-proposed main restricted universe multiverse&lt;br /&gt;&lt;br /&gt;转自 chinaunix&lt;br /&gt;原文链接：http://blog.chinaunix.net/u2/82549/showart.php?id=1333440&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-3826085992369653541?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/3826085992369653541/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=3826085992369653541' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3826085992369653541'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3826085992369653541'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/10/ubuntu810-cu.html' title='Ubuntu8.10 速配指南(转自cu)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-5028849532605490545</id><published>2008-10-25T11:04:00.000+08:00</published><updated>2008-10-25T11:15:13.440+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='工作'/><title type='text'>恢复硬盘资料－实战</title><content type='html'>昨天一同事，系统(win)突然死掉，原因不明。&lt;br /&gt;&lt;br /&gt;去看了看，安全模式也不能进入。提示文件丢失。还原吧&lt;br /&gt;结果还原了半天，没完成还原，又死。&lt;br /&gt;再次启动，硬盘动一直亮，winpe也无法进入。&lt;br /&gt;把硬盘线拔掉，winpe正常进入。故硬盘问题。&lt;br /&gt;&lt;br /&gt;用Ubuntu Live CD进入，成功。叹，还是linux比较不错。&lt;br /&gt;fdisk /dev/sdb&lt;br /&gt;比较乱&lt;br /&gt;Command (m for help): p&lt;br /&gt;Disk /dev/sdb: 160.0 GB, 160041885696 bytes&lt;br /&gt;255 heads, 63 sectors/track, 19457 cylinders&lt;br /&gt;Units = cylinders of 16065 * 512 = 8225280 bytes&lt;br /&gt;Disk identifier: 0xf78ff78f&lt;br /&gt;&lt;br /&gt;   Device Boot      Start         End      Blocks   Id  System&lt;br /&gt;/dev/sdb1   *           1        2611    20972826    c  W95 FAT32 (LBA)&lt;br /&gt;/dev/sdb2            2612       19456   135307462+   f  W95 Ext'd (LBA)&lt;br /&gt;/dev/sdb5            2612        7833    41945683+   7  HPFS/NTFS&lt;br /&gt;/dev/sdb6           14208       14232      200781   83  Linux&lt;br /&gt;..............(此处省略N行)&lt;br /&gt;dev/sdb57           7859       13107    42162561    7  HPFS/NTFS&lt;br /&gt;/dev/sdb58           7834        7858      200781   83  Linux&lt;br /&gt;/dev/sdb59           7859       13107    42162561    7  HPFS/NTFS&lt;br /&gt;/dev/sdb60           7834        7858      200781   83  Linux&lt;br /&gt;&lt;br /&gt;x 进入expert模式&lt;br /&gt;按f   fix partition order&lt;br /&gt;w 保存 reboot&lt;br /&gt;&lt;br /&gt;此时可以通过winpe进入看到2个分区，她原本有3个分区。而重要的资料在第三个分区&lt;br /&gt;finaldata 很帅，恢复。。。。。&lt;br /&gt;成功！&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-5028849532605490545?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/5028849532605490545/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=5028849532605490545' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5028849532605490545'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5028849532605490545'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/10/blog-post_25.html' title='恢复硬盘资料－实战'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-4529298875619007536</id><published>2008-10-21T15:04:00.000+08:00</published><updated>2008-10-21T15:34:19.302+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='opensuse'/><category scheme='http://www.blogger.com/atom/ns#' term='dell'/><title type='text'>opensuse安家Dell 1310</title><content type='html'>最近没什么事，蜘蛛基本上被干掉了，然后听了，看了win的一些事，咋说呢？&lt;br /&gt;不让我们用，我们就不用贝。&lt;br /&gt;&lt;br /&gt;Ubuntu升级内核把我的BSD干掉了。很晕&lt;br /&gt;正好好久没用，算了直接删了吧，桌面方面感觉比较一般吧。&lt;br /&gt;换换口味，搞了一套opensuse(11.0)，最新版的，&lt;br /&gt;主要是内核和驱动问题，新版的可能解觉得好一点。&lt;br /&gt;&lt;br /&gt;昨天晚上回去搞的，装上基本上不用汉化。不错的说&lt;br /&gt;可是网卡驱动有问题，我的Dell 1310 网卡是8111/8168B，可是opensuse&lt;br /&gt;用R8169来驱动，不行，就换贝。网上down了8168B的驱动&lt;br /&gt;make 但是 不能 install 晕，直接 cp 过去&lt;br /&gt;depmod -a&lt;br /&gt;rmmod r8169&lt;br /&gt;modprobe r8168&lt;br /&gt;网卡解决&lt;br /&gt;&lt;br /&gt;显卡也要装呀，要不然可能一些桌面效果不能实现。&lt;br /&gt;还是用nv官方的驱动&lt;br /&gt;NVIDIA-Linux-x86-177.80-pkg1.run&lt;br /&gt;sudo gdm-stop&lt;br /&gt;一步步安装ok了&lt;br /&gt;&lt;br /&gt;声卡不发声，还是以前的办法,修改一下sound&lt;br /&gt;cat /etc/modprobe.d/sound&lt;br /&gt;#options snd slots=snd-hda-intel&lt;br /&gt;# u1Nb.01UYOr8aW80:82801H (ICH8 Family) HD Audio Controller&lt;br /&gt;alias snd-card-0 snd-hda-intel&lt;br /&gt;&lt;span style="font-style: italic;"&gt;options snd-hda-intel index=0 model=dell&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;无线bcm4310&lt;br /&gt;b43都不行，只能用ndiswrapper&lt;br /&gt;找到windows的dell驱动，r174291/DRIVER_US&lt;br /&gt;ndiswrapper -i bcmwl5.inf&lt;br /&gt;然后设置网络。OK&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-4529298875619007536?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/4529298875619007536/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=4529298875619007536' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4529298875619007536'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4529298875619007536'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/10/opensusedell-1310.html' title='opensuse安家Dell 1310'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-3721979700289912412</id><published>2008-10-16T11:51:00.000+08:00</published><updated>2008-10-16T11:52:05.585+08:00</updated><title type='text'>Ubuntu下飞鸽的安装</title><content type='html'>&lt;div class="entry"&gt;      &lt;p&gt;有点麻烦，不和f8下直接rpm一下就行了。只能自己编译&lt;/p&gt; &lt;p&gt;以Ubuntu8.0.4为例&lt;/p&gt; &lt;p&gt;1.编译环境&lt;/p&gt; &lt;p&gt;&lt;span class="zw_txt"&gt;sudo apt-get install autoconf&lt;/span&gt;&lt;span class="zw_txt"&gt; automake &lt;/span&gt;&lt;span class="zw_txt"&gt;build-essential&lt;/span&gt;&lt;/p&gt; &lt;p&gt;2.安装一些开发库&lt;/p&gt; &lt;p&gt;&lt;span class="t_tag" onclick="tagshow(event)"&gt;sudo&lt;/span&gt; apt-get install libpanelappletmm-2.6-dev  libgnomeui-dev  libgtk2.0-dev&lt;/p&gt; &lt;p&gt;3.下载g2ipmsg&lt;/p&gt; &lt;p&gt;wget http://www.ipmsg.org/archive/g2ipmsg-0.9.5.tar.gz&lt;/p&gt; &lt;p&gt;4. 安装&lt;/p&gt; &lt;p&gt;./configure &amp;amp;&amp;amp; make &amp;amp;&amp;amp; sudo make install&lt;/p&gt; &lt;p&gt;然后应该在应用程序－&gt;附件里找到了。&lt;/p&gt; &lt;p&gt;5. 一般需要重启系统，我用sudo g2ipmsg没问题，然后重启了一下X就行了&lt;/p&gt;     &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-3721979700289912412?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/3721979700289912412/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=3721979700289912412' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3721979700289912412'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3721979700289912412'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/10/ubuntu.html' title='Ubuntu下飞鸽的安装'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8986517503144648096</id><published>2008-10-08T18:09:00.001+08:00</published><updated>2008-10-08T18:14:20.903+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='dell'/><title type='text'>有些笔记本键盘锁定问题</title><content type='html'>我装Ubuntu 8.0.4.1 不知道什么原因，开机有时会无法使用键盘。&lt;br /&gt;重启就好了，但是在Win下就没问题。&lt;br /&gt;&lt;br /&gt;最后找到一个方案，不知道可行不&lt;br /&gt;在grub的kernel 后面追加上 i8042.nopnp=1 i8042.dumbkbd=1 参数&lt;br /&gt;比如我的&lt;br /&gt;title        Ubuntu 8.04.1, kernel 2.6.27-rc6liu&lt;br /&gt;root        (hd0,6)&lt;br /&gt;kernel        /boot/vmlinuz-2.6.27-rc6liu root=UUID=745f0f17-3ce8-456d-9b6f-e8165d35778f ro quiet splash locale=zh_CN &lt;span style="font-weight: bold;"&gt;i8042.nopnp=1 i8042.dumbkbd=1&lt;/span&gt;&lt;br /&gt;initrd        /boot/initrd.img-2.6.27-rc6liu&lt;br /&gt;&lt;br /&gt;PS:今天把抓取的问题解决了，可以消停一段时间了。呵呵&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8986517503144648096?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8986517503144648096/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8986517503144648096' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8986517503144648096'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8986517503144648096'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/10/blog-post.html' title='有些笔记本键盘锁定问题'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-2856700263810313203</id><published>2008-10-07T17:36:00.000+08:00</published><updated>2008-10-07T17:37:02.617+08:00</updated><title type='text'>Introduction to Chromium</title><content type='html'>Over the past few years, progress in consumer graphics card capabilities       and desktop CPU performance, coupled with advances in high-performance       networks, have enabled a new generation of supercomputer: the commodity       graphics cluster. These new clusters, built from collections of       off-the-shelf Pcs outfitted with consumer graphics cards, offer       unprecedented power for the rendering and display of 3D graphics.       However, the application programming interface to these systems was not       designed for parallel clusters. Chromium provides a common parallel       graphics programming interface to support such clusters. In addition, it       allows most existing serial applications to run without modification, and       enables creation of powerful new parallel graphics applications capable       of fully exploiting the power of these clusters.&lt;br /&gt;&lt;br /&gt;http://chromium.sourceforge.net&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-2856700263810313203?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/2856700263810313203/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=2856700263810313203' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2856700263810313203'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2856700263810313203'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/10/introduction-to-chromium.html' title='Introduction to Chromium'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-4897253282994818435</id><published>2008-09-30T15:06:00.000+08:00</published><updated>2008-09-30T15:22:41.429+08:00</updated><title type='text'>网站防抓取方案探讨</title><content type='html'>最近经常被抓取，搞的大家很崩溃。&lt;br /&gt;封了Ip接着换，很恶心的说。&lt;br /&gt;&lt;br /&gt;http://www.ibm.com/developerworks/cn/linux/network/dif/index.html&lt;br /&gt;&lt;br /&gt;参考上面工具，做了一下设置。&lt;br /&gt;&lt;br /&gt;大体原理：分析 web服务器日志，统计一段时间的访问如果太大。。。。。&lt;br /&gt;那就封贝。&lt;br /&gt;64.55.144.50 美国 Allegiance Telecom Companies Worldwide  2.53 G字节2008年 九月 29日 23:59&lt;br /&gt;&lt;br /&gt;就像这种恶心的Ip，直接干掉！&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-4897253282994818435?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/4897253282994818435/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=4897253282994818435' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4897253282994818435'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4897253282994818435'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/09/blog-post_30.html' title='网站防抓取方案探讨'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-4041711247008332672</id><published>2008-09-28T17:38:00.000+08:00</published><updated>2008-09-28T18:04:56.746+08:00</updated><title type='text'>Ruby &amp; Rubygem</title><content type='html'>因为要搞程序自动部署的东西，所以搞Ruby，不是我要学。呵呵&lt;br /&gt;&lt;br /&gt;Ruby和Rubygem的性质，感觉就像Perl和Cpan那样，一些扩展的东西，可以通过Rubygem来装。但是效率和速度就不敢恭维了。基本上通过gem安装包比较爽。&lt;br /&gt;&lt;br /&gt;http://www.capify.org/     &lt;br /&gt;&lt;h2&gt;&lt;span style="font-size:130%;"&gt;&lt;span class="appname"&gt;Capistrano(&lt;/span&gt;&lt;/span&gt; &lt;span style="font-size:100%;"&gt;自动实施工具&lt;/span&gt;)&lt;/h2&gt;&lt;ul&gt;&lt;li&gt;&lt;em&gt;Great for automating tasks&lt;/em&gt; via SSH on remote servers, like &lt;em&gt;software installation&lt;/em&gt;, &lt;em&gt;application deployment&lt;/em&gt;, &lt;em&gt;configuration management&lt;/em&gt;, ad hoc &lt;em&gt;server monitoring&lt;/em&gt;, and more.&lt;/li&gt;&lt;li&gt;&lt;em&gt;Ideal for system administrators&lt;/em&gt;, whether professional or incidental.&lt;/li&gt;&lt;li&gt;&lt;em&gt;Easy to customize.&lt;/em&gt; Its configuration files use the &lt;a href="http://www.ruby-lang.org/"&gt;Ruby&lt;/a&gt; programming language syntax, but you don't need to know Ruby to do most things with &lt;span class="appname"&gt;Capistrano.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;em&gt;Easy to extend.&lt;/em&gt; &lt;span class="appname"&gt;Capistrano&lt;/span&gt; is written in the &lt;a href="http://www.ruby-lang.org/"&gt;Ruby&lt;/a&gt; programming language, and may be extended easily by writing additional Ruby modules.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;http://www.capify.org/install 安装过程&lt;br /&gt;&lt;br /&gt;下载 gem，不要用 gem install -y capistrano ,用了会累死人的。&lt;br /&gt;直接下载gem，然后用  gem install -l filename.gem&lt;br /&gt;&lt;br /&gt;先下载以下两个包，要不然cap的时候就会出错&lt;br /&gt;wget http://rubyforge.rubyuser.de/gems/&lt;a href="http://rubyforge.rubyuser.de/gems/net-ssh-gateway-1.0.0.gem"&gt;net-ssh-gateway-1.0.0.gem&lt;/a&gt;&lt;br /&gt;wget http://rubyforge.rubyuser.de/gems/net-ssh-2.0.4.gem&lt;br /&gt;wget http://rubyforge.org/frs/download.php/42110/capistrano-2.5.0.gem&lt;br /&gt;&lt;br /&gt;sudo gem install -l &lt;a href="http://rubyforge.rubyuser.de/gems/net-ssh-gateway-1.0.0.gem"&gt;net-ssh-gateway-1.0.0.gem&lt;/a&gt; net-ssh-2.0.4.gem capistrano-2.5.0.gem&lt;br /&gt;&lt;br /&gt;/var/lib/gems/1.8/bin/cap -H&lt;br /&gt;&lt;br /&gt;Q: 'require': no such file to load -- net/ssh/gateway (LoadError)&lt;br /&gt;A: sudo gem install -l &lt;a href="http://rubyforge.rubyuser.de/gems/net-ssh-gateway-1.0.0.gem"&gt;net-ssh-gateway-1.0.0.gem&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-4041711247008332672?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/4041711247008332672/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=4041711247008332672' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4041711247008332672'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4041711247008332672'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/09/ruby-rubygem.html' title='Ruby &amp; Rubygem'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-2292754977937488963</id><published>2008-09-27T10:33:00.000+08:00</published><updated>2008-09-27T10:39:07.617+08:00</updated><title type='text'>Ubuntu下一些问题</title><content type='html'>买了个USB2PS/2的转接线，昨天坏了。才用了几天呀。晕&lt;br /&gt;因为Ubuntu下最近经常开机键盘不能输入，估计是转接线的问题。&lt;br /&gt;中午去换线去。&lt;br /&gt;&lt;br /&gt;vim语法高亮的设置&lt;br /&gt;&lt;br /&gt;Ubuntu8.0.4.1默认带着vim tiny版&lt;br /&gt;所以即使编辑了 ~/.vimrc 开启  syntax on，它会报错&lt;br /&gt;&lt;br /&gt;apt-get install vim-full 就行了&lt;br /&gt;因为要看perl的一些资料，顺便把vim-perl也给装上了。&lt;br /&gt;现在语法高亮了&lt;br /&gt;set tabstop=4&lt;br /&gt;这样按tab后看着就舒服了。呵呵&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-2292754977937488963?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/2292754977937488963/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=2292754977937488963' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2292754977937488963'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2292754977937488963'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/09/ubuntu.html' title='Ubuntu下一些问题'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-5557121060886588383</id><published>2008-09-23T14:00:00.001+08:00</published><updated>2008-09-23T14:09:41.356+08:00</updated><title type='text'>恢复grub</title><content type='html'>今天装 Freebsd，装上了，可是把Grub覆盖了。晕菜。&lt;br /&gt;grub损坏，看不到Ubuntu系统，&lt;br /&gt;&lt;br /&gt;按如下步骤修复：&lt;br /&gt;1. 用 ubuntu 的 Live CD 启动&lt;br /&gt;2. 打开一个终端，运行$sudo grub，会看到 'grub&gt;' 提示符&lt;br /&gt;3. 找出安装ubuntu的磁盘分区(/boot所在分区)，比如我机子是(hd0,6)&lt;br /&gt;4. 运行 grub&gt;root (hd0,6)&lt;br /&gt;5. 运行 grub&gt;setup (hd0) 出现提示文字，最后是“... succeeded”&lt;br /&gt;6. 运行 grub&gt;quit&lt;br /&gt;7. 重启计算机，取出 Live CD&lt;br /&gt;&lt;br /&gt;Freebsd没有r8169的网卡驱动?&lt;br /&gt;&lt;br /&gt;还是先了解青岛有线电视网那边情况吧，多机上网不行？&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-5557121060886588383?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/5557121060886588383/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=5557121060886588383' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5557121060886588383'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5557121060886588383'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/09/grub.html' title='恢复grub'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8290623681191455260</id><published>2008-09-22T15:02:00.001+08:00</published><updated>2008-09-22T17:21:54.134+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='dell'/><title type='text'>dell 1310 &amp; Ubuntu</title><content type='html'>I install Ubuntu 8.0.4.1 on my Dell 1310&lt;br /&gt;&lt;br /&gt;It really took me a time for resolve the Drivers problems.&lt;br /&gt;&lt;br /&gt;Graphics Card: GF8400 GS&lt;br /&gt;I installed NVIDIA-Linux-x86-173.14.05-pkg1.run for My Graphics Card&lt;br /&gt;but it doesn't work on my new kernel linux-2.6.27-rc6liu&lt;br /&gt;finally I found the driver developed by https://launchpad.net&lt;br /&gt;https://launchpad.net/ubuntu/+source/nvidia-graphics-drivers-173/173.14.09-0ubuntu4&lt;br /&gt;download / dpkg&lt;br /&gt;Now the Graphics is Ready!&lt;br /&gt;&lt;br /&gt;Sound Card: Intel-Hda&lt;br /&gt;add the following lines to /etc/modprobe.d/alsa-base&lt;br /&gt;&lt;span style="font-style: italic;"&gt;options snd-hda-intel index=0 model=dell&lt;/span&gt;&lt;br /&gt;Reboot, It works.&lt;br /&gt;&lt;br /&gt;Wireless Card is ready!&lt;br /&gt;I installed Ndiswrapper&lt;br /&gt;sudo apt-get install ndisgtk ndiswrapper-common&lt;br /&gt;&lt;br /&gt;dell 1310 wireless card 1395 installations:&lt;br /&gt;echo -e 'blacklist bcm43xx\nblacklist wl' | sudo tee -a /etc/modprobe.d/blacklist&lt;br /&gt;sudo apt-get install ndiswrapper-utils-1.9&lt;br /&gt;mkdir ~/bcm43xx; cd ~/bcm43xx&lt;br /&gt;&lt;br /&gt;find wireless driver in Dell driver CD&lt;br /&gt;R174291.exe into /home/edy/R174291&lt;br /&gt;cd /home/edy/R174291&lt;br /&gt;sudo ndiswrapper -i bcmwl5.inf&lt;br /&gt;ndiswrapper -l&lt;br /&gt;sudo depmod -a&lt;br /&gt;sudo modprobe ndiswrapper&lt;br /&gt;sudo cp /etc/network/interfaces /etc/network/interfaces.orig&lt;br /&gt;echo -e 'auto lo\niface lo inet loopback\n' | sudo tee /etc/network/interfaces&lt;br /&gt;sudo ndiswrapper -m&lt;br /&gt;echo 'ndiswrapper' | sudo tee -a /etc/modules&lt;br /&gt;echo 'ENABLED=0' | sudo tee -a /etc/default/wpasupplicant&lt;br /&gt;&lt;br /&gt;sudo rmmod b43&lt;br /&gt;sudo rmmod b44&lt;br /&gt;sudo rmmod b43legacy #this step added Apr 27 2008&lt;br /&gt;sudo rmmod wl #this step added Sep 20 2008&lt;br /&gt;sudo rmmod ssb&lt;br /&gt;sudo rmmod ndiswrapper&lt;br /&gt;sudo modprobe ndiswrapper&lt;br /&gt;sudo modprobe ssb&lt;br /&gt;sudo modprobe b44 #this step added May 1 2008&lt;br /&gt;&lt;br /&gt;k.o. le&lt;br /&gt;Tks to everyone who contribute for freedom in Linux/Unix World.&lt;br /&gt;&lt;br /&gt;https://help.ubuntu.com/community/WifiDocs/Driver/bcm43xx/Feisty_No-Fluff&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8290623681191455260?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8290623681191455260/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8290623681191455260' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8290623681191455260'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8290623681191455260'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/09/dell-1310-ubuntu.html' title='dell 1310 &amp; Ubuntu'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-1266884676178532345</id><published>2008-09-18T08:12:00.000+08:00</published><updated>2008-09-18T08:14:43.311+08:00</updated><title type='text'>昨天拿到本了</title><content type='html'>昨天公司让去搞新办公室的网络&lt;br /&gt;&lt;br /&gt;没事，就在信息城那里转了转，转到一本子&lt;br /&gt;&lt;br /&gt;Dell 1310&lt;br /&gt;&lt;br /&gt;CPU T5670&lt;br /&gt;RAM 1G&lt;br /&gt;HD 160G&lt;br /&gt;GF NV8400GS&lt;br /&gt;&lt;br /&gt;还算满意，o(∩_∩)o...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-1266884676178532345?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/1266884676178532345/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=1266884676178532345' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1266884676178532345'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1266884676178532345'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/09/blog-post_18.html' title='昨天拿到本了'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-6283237844867481289</id><published>2008-09-12T10:03:00.004+08:00</published><updated>2008-11-18T14:02:51.376+08:00</updated><title type='text'>Mail服务器的一些笔记</title><content type='html'>最近要搞个免费的Mail服务器&lt;br /&gt;&lt;br /&gt;基本规划是Postfix+Extmail+Maildrop+Clamav+Spam&lt;br /&gt;&lt;br /&gt;有些过程性的东西记录一下&lt;br /&gt;64bit的有些东西确实很烦人。&lt;br /&gt;&lt;br /&gt;Maildrop编译时遇到&lt;br /&gt;1-Q:makedat/makedatprog': No such file or directory&lt;br /&gt;&lt;br /&gt;A: If you get /usr/bin/install: cannot stat `makedat/makedatprog': No such file or directory, please install gdbm-devel and try a 'make distclean' and recompile maildrop again&lt;br /&gt;&lt;br /&gt;2-Q: check /var/log/maillog      The most important installing the Mail server&lt;br /&gt;&lt;br /&gt;3-Q: warning: localhost.localdomain[127.0.0.1]: SASL login authentication failed: no mechanism available&lt;br /&gt;3-A: yum install -y cyrus-sasl    service postfix restart&lt;br /&gt;&lt;br /&gt;4-Q:&lt;br /&gt;Aug  7 22:26:22 mail postfix/smtpd[16829]: warning: xsasl_cyrus_server_get_mechanism_list: no applicable SASL mechanisms&lt;br /&gt;Aug  7 22:26:22 mail postfix/smtpd[16829]: fatal: no SASL authentication mechanisms&lt;br /&gt;Aug  7 22:26:23 mail postfix/master[16825]: warning: process /usr/libexec/postfix/smtpd pid 16829 exit status 1&lt;br /&gt;Aug  7 22:26:23 mail postfix/master[16825]: warning: /usr/libexec/postfix/smtpd: bad command startup -- throttling&lt;br /&gt;Aug  7 22:28:06 mail postfix/smtpd[16830]: warning: xsasl_cyrus_server_get_mechanism_list: no applicable SASL mechanisms&lt;br /&gt;Aug  7 22:28:06 mail postfix/smtpd[16830]: fatal: no SASL authentication mechanisms&lt;br /&gt;Aug  7 22:28:07 mail postfix/master[16825]: warning: process /usr/libexec/postfix/smtpd pid 16830 exit status 1&lt;br /&gt;&lt;br /&gt;4-A:&lt;br /&gt;# ln -s /usr/local/lib/sasl2 /usr/lib/sasl2&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-6283237844867481289?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/6283237844867481289/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=6283237844867481289' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6283237844867481289'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6283237844867481289'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/09/mail.html' title='Mail服务器的一些笔记'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-6895294295027314741</id><published>2008-09-02T12:57:00.001+08:00</published><updated>2008-09-02T12:57:46.839+08:00</updated><title type='text'>cron 指南(转)</title><content type='html'>cron 系统调度进程，使用它在每天得非高峰负荷时间段运行作业，或者在一周或一月中得不同时段运行at命令，在特定时间运行一些特殊作业&amp;amp; 使用它在后台运行一个占用时间不长得进程Nohup，使用它在后台运行一个命令，即使在用户退出时也不受影响。&lt;br /&gt;cron和crontab&lt;br /&gt;&lt;br /&gt;cron 是系统得调度进程，在无需人工干预得情况下运行作业。&lt;br /&gt;crontab命令允许用户提交，编辑或者删除相应得作业。每个用户都有一个crontab文件来保存调度信息&lt;br /&gt;crontab的域&lt;br /&gt;&lt;br /&gt;第1列  分钟1~59&lt;br /&gt;第2列   小时1~23&lt;br /&gt;第3列   日1-31&lt;br /&gt;第4列   月1~12&lt;br /&gt;第5列   星期0~6&lt;br /&gt;第6列   要运行的命令&lt;br /&gt;举例&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;30 21 * * * /apps/bin/clearnup.sh&lt;br /&gt;每晚的21:30运行/apps/bin目录下的cleanup.sh&lt;br /&gt;&lt;br /&gt;45 4 1,10,22 * * /apps/bin/backup.sh&lt;br /&gt;每月的1，20，22号的4:45执行/apps/bin 目录下的 backup.sh&lt;br /&gt;&lt;br /&gt;10 1 * * 6,0 /bin/find -name "core" rm {} \;&lt;br /&gt;每个星期六。日1:10运行一个find 命令&lt;br /&gt;&lt;br /&gt;0,30 18-23 * * * /apps/bin/dbcheck.sh&lt;br /&gt;每天在18:00~23:00每隔30分钟执行/apps/bin目录下的dbcheck.sh&lt;br /&gt;&lt;br /&gt;0 23 * * 6 /apps/bin/qtrend.sh&lt;br /&gt;每周六的23:00执行/apps/bin/qtrend.sh&lt;br /&gt;crontab的命令选项&lt;br /&gt;&lt;br /&gt;crontab [-u user] -e -l -r&lt;br /&gt;-u 用户名&lt;br /&gt;-e 编辑crontab文件&lt;br /&gt;-l 列出crontab文件的内容&lt;br /&gt;-r 删除crontab文件&lt;br /&gt;创建一个crontab文件&lt;br /&gt;&lt;br /&gt;crontab 文件名&lt;br /&gt;列出crontab文件&lt;br /&gt;&lt;br /&gt;crontab -l&lt;br /&gt;crontab -l &gt;$HOME/faintbearcron&lt;br /&gt;编辑/删除crontab文件&lt;br /&gt;&lt;br /&gt;crontab -r / crontab -e&lt;br /&gt;恢复丢失的crontab文件&lt;br /&gt;&lt;br /&gt;crontab &lt;filename&gt;&lt;br /&gt;其中&lt;filename&gt;就是你在$HOME目录中的副本的文件名&lt;br /&gt;&lt;br /&gt;From: http://www.w3pop.com/learn/view/p/1/doc/linux_cron_crontab/&lt;br /&gt;&lt;/filename&gt;&lt;/filename&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-6895294295027314741?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/6895294295027314741/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=6895294295027314741' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6895294295027314741'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6895294295027314741'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/09/cron.html' title='cron 指南(转)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7123207285649815498</id><published>2008-08-27T15:15:00.005+08:00</published><updated>2008-08-27T15:35:59.447+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Server'/><category scheme='http://www.blogger.com/atom/ns#' term='Company'/><title type='text'>Squid日志分析工具Sarg</title><content type='html'>Sarg is a Squid Analysis Report Generator that allow you&lt;br /&gt;&lt;pre&gt;to view "where" your users are going to on the Internet.&lt;br /&gt;&lt;br /&gt;今天简单测试了一下，很不错。比较详细的分析Squid日志。&lt;br /&gt;&lt;br /&gt;安装也很简单&lt;br /&gt;./configure &amp;amp;&amp;amp; make &amp;amp;&amp;amp; make install&lt;br /&gt;&lt;br /&gt;sarg 可以手动分析日志 具体见 sarg -h&lt;br /&gt;默认安装到把 wwwhtml /var/www/html里去&lt;br /&gt;顺便把它给汉了一下。汉的过程很简单&lt;br /&gt;cp English Chinese_UTF8&lt;br /&gt;修改 Chinese_UTF8完了，修改 sarg.conf&lt;br /&gt;language Chinese_UTF8&lt;br /&gt;charset UTF-8&lt;br /&gt;&lt;br /&gt;感觉真的挺不错的。当然了还有不少参数可以修改。&lt;br /&gt;&lt;/pre&gt;&lt;div style="text-align: left;"&gt;&lt;a style="font-weight: bold;" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_UadQ3-HAAB0/SLUCt1dx-QI/AAAAAAAAA-g/JCQBN8yvLwk/s1600-h/2008-08-27-152239_485x202_scrot.png"&gt;&lt;img style="cursor: pointer;" src="http://4.bp.blogspot.com/_UadQ3-HAAB0/SLUCt1dx-QI/AAAAAAAAA-g/JCQBN8yvLwk/s400/2008-08-27-152239_485x202_scrot.png" alt="" id="BLOGGER_PHOTO_ID_5239096727984797954" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;/div&gt;&lt;pre&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_UadQ3-HAAB0/SLUDfwK1s2I/AAAAAAAAA-w/l6F-N6t3STY/s1600-h/2008-08-27-153038_581x340_scrot.png"&gt;&lt;img style="cursor: pointer;" src="http://4.bp.blogspot.com/_UadQ3-HAAB0/SLUDfwK1s2I/AAAAAAAAA-w/l6F-N6t3STY/s400/2008-08-27-153038_581x340_scrot.png" alt="" id="BLOGGER_PHOTO_ID_5239097585556632418" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7123207285649815498?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7123207285649815498/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7123207285649815498' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7123207285649815498'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7123207285649815498'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/squidsarg.html' title='Squid日志分析工具Sarg'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_UadQ3-HAAB0/SLUCt1dx-QI/AAAAAAAAA-g/JCQBN8yvLwk/s72-c/2008-08-27-152239_485x202_scrot.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-3351027336991938447</id><published>2008-08-27T10:17:00.002+08:00</published><updated>2008-08-27T11:06:41.141+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Company'/><category scheme='http://www.blogger.com/atom/ns#' term='apache'/><title type='text'>Apache 访问控制</title><content type='html'>Note: the italic should change to ur own dir and name&lt;br /&gt;&lt;br /&gt;In the httpd.conf add the following lines&lt;br /&gt;!!!delete the "&lt;br /&gt;&lt;code&gt;     "&lt;"Directory &lt;/code&gt;&lt;code&gt;&lt;directory&gt;&lt;span style="font-style: italic;"&gt;/var/www/the/dir/tocontrol/"&gt;"&lt;/span&gt;&lt;code&gt;&lt;/code&gt;&lt;br /&gt;&lt;directory var="" www="" the="" dir="" tocontrol=""&gt;Options MultiViews&lt;br /&gt;AllowOverride AuthConfig&lt;br /&gt;Order allow,deny&lt;br /&gt;Allow from all&lt;br /&gt;"&lt;"/Dircetory"&gt;"&lt;br /&gt;&lt;/directory&gt;&lt;/directory&gt;&lt;br /&gt;&lt;br /&gt;vi &lt;span style="font-style: italic;"&gt;/var/www/the/dir/tocontrol/.htaccess&lt;/span&gt;&lt;br /&gt;add&lt;br /&gt;&lt;code&gt;AuthType Basic&lt;br /&gt;AuthName "Restricted Files"&lt;br /&gt;AuthUserFile &lt;/code&gt;&lt;span style="font-style: italic;"&gt;/var/www/the/dir/tocontrol/.htpaaswd&lt;/span&gt;&lt;br /&gt;&lt;code&gt;       Require user &lt;span style="font-style: italic;font-family:Georgia,serif;" &gt;allow_user&lt;/span&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;/pathto/htpasswd -c &lt;span style="font-style: italic;"&gt;/var/www/the/dir/tocontrol/.htpaaswd allow_user&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-3351027336991938447?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/3351027336991938447/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=3351027336991938447' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3351027336991938447'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3351027336991938447'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/apache.html' title='Apache 访问控制'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8165816026929430680</id><published>2008-08-26T14:53:00.000+08:00</published><updated>2008-08-26T15:03:21.560+08:00</updated><title type='text'>Apache Rewrite Rules</title><content type='html'>http://httpd.apache.org/docs/2.2/rewrite/&lt;br /&gt;&lt;br /&gt;Rewrite很牛的说，很强大。&lt;br /&gt;可以从&lt;br /&gt;/a/b/c -&gt; index.php?p1=a&amp;amp;p2=b&amp;amp;p3=c&lt;br /&gt;/abc/index.php -&gt; index.html&lt;br /&gt;/a/b?c=www -&gt; /a/b/www/index.html&lt;br /&gt;二级域名的实现&lt;br /&gt;还有很多，研究一下上面文档就行了&lt;br /&gt;&lt;br /&gt;这次修改重写主要是实现&lt;br /&gt;/old/index.php?app=what -&gt; /new/what/index.php&lt;br /&gt;憋了一上午，就是没看手册。。。。。。。菜鸟的本性显露无遗&lt;br /&gt;&lt;br /&gt;下文来自官方手册：&lt;br /&gt;&lt;div class="note"&gt;&lt;h3&gt;Modifying the Query String&lt;/h3&gt;       &lt;p&gt;By default, the query string is passed through unchanged. You       can, however, create URLs in the substitution string containing       a query string part. Simply use a question mark inside the       substitution string to indicate that the following text should       be re-injected into the query string. When you want to erase an       existing query string, end the substitution string with just a       question mark. To combine new and old query strings, use the       &lt;code&gt;[QSA]&lt;/code&gt; flag.&lt;/p&gt;也就是它根本不修改参数，必须加上？才能去掉参数&lt;br /&gt;然后就是去掉"app=" 因为QUERY_STRING获得?后所有的，即app=what&lt;br /&gt;通过下面方式解决&lt;br /&gt;RewriteCond %{QUERY_STRING} app=(.*)$&lt;br /&gt;RewriteRule old  /new/%1/index.php? [R=301,L]&lt;br /&gt;&lt;br /&gt;RTFM!!!!!!&lt;br /&gt;      &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8165816026929430680?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8165816026929430680/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8165816026929430680' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8165816026929430680'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8165816026929430680'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/apache-rewrite-rules.html' title='Apache Rewrite Rules'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7162553866077227065</id><published>2008-08-21T14:20:00.000+08:00</published><updated>2008-08-21T14:24:28.484+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Company'/><category scheme='http://www.blogger.com/atom/ns#' term='mail'/><title type='text'>有点晕菜</title><content type='html'>上午有人说邮件有问题，我就检查了一下Zimbra队列。&lt;br /&gt;没问题，检查完了，闲着没事。就看看一些服务器配置。&lt;br /&gt;&lt;br /&gt;因为我们证书私有的嘛，就没事更新一下。更新完了。&lt;br /&gt;service restart&lt;br /&gt;挂了。&lt;br /&gt;&lt;br /&gt;服务都开着，就是连不上。肯定是证书问题。&lt;br /&gt;zimbra证书不要乱动。&lt;br /&gt;&lt;br /&gt;后来把备份恢复。。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7162553866077227065?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7162553866077227065/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7162553866077227065' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7162553866077227065'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7162553866077227065'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/blog-post_21.html' title='有点晕菜'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-6534428869600187799</id><published>2008-08-20T11:34:00.000+08:00</published><updated>2008-08-20T11:40:40.972+08:00</updated><title type='text'>让VirtualBox1.6搞的抓狂了</title><content type='html'>在Ubuntu8.04上装上VirtualBox1.6&lt;br /&gt;&lt;br /&gt;死活就是不能用键盘。。。。。。。。。&lt;br /&gt;&lt;br /&gt;网上解决方案：&lt;br /&gt;&lt;br /&gt;sudo apt-get install scim-bridge-client-qt scim-bridge-client-qt4&lt;br /&gt;&lt;br /&gt;全局里面，去掉自动获取键盘。&lt;br /&gt;&lt;br /&gt;OK! 很晕，难道是输入法的问题？&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-6534428869600187799?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/6534428869600187799/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=6534428869600187799' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6534428869600187799'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6534428869600187799'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/virtualbox16.html' title='让VirtualBox1.6搞的抓狂了'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-297336531518523451</id><published>2008-08-16T15:04:00.000+08:00</published><updated>2008-08-16T15:14:50.048+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Company'/><title type='text'>今天把Mail服务器顺利迁移到本地</title><content type='html'>拖了好几天了，一直上边没安排。昨天下通知，要迁移了。&lt;br /&gt;&lt;br /&gt;先rsync过来吧，但是rsync时，服务器一直working。所以当时有些文件也没有r过来。&lt;br /&gt;但是大部分都过来了，用了近三个小时。&lt;br /&gt;&lt;br /&gt;6:00正式停止服务，这样rsync大约5，6分钟差量同步。顺利完成&lt;br /&gt;&lt;br /&gt;先升级到中间版本，然后再高级，很顺利。然后就是等着dns生效了。呵呵&lt;br /&gt;今天下午2点多生效了，目前一切正常。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-297336531518523451?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/297336531518523451/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=297336531518523451' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/297336531518523451'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/297336531518523451'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/mail.html' title='今天把Mail服务器顺利迁移到本地'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7231476025625283198</id><published>2008-08-15T16:45:00.002+08:00</published><updated>2008-08-16T15:02:00.068+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Company'/><title type='text'>关于服务器虚拟化技术</title><content type='html'>在虚拟化技术中，各种方法都存在着相同之处，但是在实现方法和抽象过程中又各有不同&lt;br /&gt;&lt;br /&gt;目前比较流行的主要有以下三种：&lt;br /&gt;Virtual Machines(VMs)&lt;br /&gt;Virtual Machines 主要是模拟真实硬件，从宿主中获取资源，这种方式用在很多系统模拟其中，它允许寄生虫:-)，这样主要存在的问题是，CPU指令需要额外的权限，不仅仅局限于用户空间。这就需要有VMM(virtual machines monitor)分析代码，保证其安全，不会对系统造成损害。像Vmware, Qemu, VirtualBox，M$ Virtual Server就主要使用这种实现机制。&lt;br /&gt;Vmware多数在win下用，感觉还不错。&lt;br /&gt;&lt;br /&gt;并行技术&lt;br /&gt;这种技术需要VMM，但是大部分工作都交给宿主操作系统来实现，并行技术，允许不同的操作系统运行在同一台主机上，但是需要他们被port过去，并行技术的例子如Xen，不幸的是M$的好像不能用。&lt;br /&gt;&lt;br /&gt;系统级别的虚拟化&lt;br /&gt;如果程序可以隔离和足够安全那么他们就可以共享，OS级别虚拟化，可以在同一个操作系统上运行不同的OS 主要产品： &lt;a href="http://openvz.org/" class="external text" title="http://openvz.org/" rel="nofollow"&gt;OpenVZ&lt;/a&gt;, &lt;a href="http://www.swsoft.com/products/virtuozzo" class="external text" title="http://www.swsoft.com/products/virtuozzo" rel="nofollow"&gt;Virtuozzo&lt;/a&gt;, &lt;a href="http://linux-vserver.org/" class="external text" title="http://linux-vserver.org/" rel="nofollow"&gt;Linux-VServer&lt;/a&gt;, &lt;a href="http://www.sun.com/bigadmin/content/zones/" class="external text" title="http://www.sun.com/bigadmin/content/zones/" rel="nofollow"&gt;Solaris Zones&lt;/a&gt; and &lt;a href="http://www.freebsd.org/doc/en_US.ISO8859-1/books/arch-handbook/jail.html" class="external text" title="http://www.freebsd.org/doc/en_US.ISO8859-1/books/arch-handbook/jail.html" rel="nofollow"&gt;FreeBSD Jails&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;下面我们以OpenVZ为例，说一下系统级别的虚拟化(具体见上一篇日志)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7231476025625283198?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7231476025625283198/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7231476025625283198' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7231476025625283198'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7231476025625283198'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/blog-post_15.html' title='关于服务器虚拟化技术'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-1955702066997220075</id><published>2008-08-13T16:49:00.000+08:00</published><updated>2008-08-13T18:43:57.617+08:00</updated><title type='text'>Ubuntu 8.0.4 Openvz 使用手记</title><content type='html'>Ubuntu 8.0.4 (kernel vmlinuz-2.6.24-16-generic)&lt;br /&gt;&lt;br /&gt;First step:&lt;br /&gt;到&lt;br /&gt;http://download.openvz.org/ 下载对应的内核&lt;br /&gt;&lt;br /&gt;apt-get install linux-openvz&lt;br /&gt;apt-get install vzctl vzquota&lt;br /&gt;&lt;br /&gt;2nd Step:&lt;br /&gt;&lt;br /&gt;vi  /etc/sysctl.conf&lt;br /&gt;修改以下参数：&lt;br /&gt;############ For openvz ######################&lt;br /&gt;# On Hardware Node we generally need&lt;br /&gt;# packet forwarding enabled and proxy arp disabled&lt;br /&gt;net.ipv4.ip_forward = 1&lt;br /&gt;net.ipv4.conf.default.proxy_arp = 0&lt;br /&gt;net.ipv4.conf.eth0.proxy_arp = 100&lt;br /&gt;# Enables source route verification&lt;br /&gt;net.ipv4.conf.all.rp_filter = 1&lt;br /&gt;# Enables the magic-sysrq key&lt;br /&gt;kernel.sysrq = 1&lt;br /&gt;# TCP Explict Congestion Notification&lt;br /&gt;#net.ipv4.tcp_ecn = 0&lt;br /&gt;# we do not want all our interfaces to send redirects&lt;br /&gt;net.ipv4.conf.default.send_redirects = 1&lt;br /&gt;net.ipv4.conf.all.send_redirects = 0&lt;br /&gt;&lt;br /&gt;sysctl -p&lt;br /&gt;&lt;br /&gt;vi /etc/vz/vz.conf&lt;br /&gt;NEIGHBOUR_DEVS=all&lt;br /&gt;&lt;br /&gt;reboot&lt;br /&gt;&lt;br /&gt;$uname -r&lt;br /&gt;2.6.24-openvz-24-004.1d1-686&lt;br /&gt;&lt;br /&gt;3rd Step:&lt;br /&gt;http://wiki.openvz.org/Download/template/precreated&lt;br /&gt;下载templates&lt;br /&gt;cp centos-5-i386-minimal.tar.gz到 /var/lib/vz/template/cache&lt;br /&gt;&lt;br /&gt;4th Step:&lt;br /&gt;vzctl create 101 --ostemplate centos-5-i386-minimal --config vps.basic&lt;br /&gt;&lt;br /&gt;If you want to have the vm started at boot, run&lt;br /&gt;&lt;br /&gt;vzctl set 101 --onboot yes --save&lt;br /&gt;&lt;br /&gt;To set a hostname and IP address for the vm, run:&lt;br /&gt;&lt;br /&gt;vzctl set 101 --hostname test.example.com --save&lt;br /&gt;vzctl set 101 --ipadd 192.168.0.101 --save&lt;br /&gt;&lt;br /&gt;Next we set the number of sockets to 120 and assign a few nameservers to the vm:&lt;br /&gt;&lt;br /&gt;vzctl set 101 --numothersock 120 --save&lt;br /&gt;vzctl set 101 --nameserver 213.133.98.98 --nameserver 213.133.99.99 --nameserver 213.133.100.100 --nameserver 145.253.2.75 --save&lt;br /&gt;&lt;br /&gt;(Instead of using the vzctl set commands, you can as well directly edit the vm's configuration file which is stored in the /etc/vz/conf directory. If the ID of the vm is 101, then the configuration file is /etc/vz/conf/101.conf.)&lt;br /&gt;&lt;br /&gt;To start the vm, run&lt;br /&gt;&lt;br /&gt;vzctl start 101&lt;br /&gt;&lt;br /&gt;To set a root password for the vm, execute&lt;br /&gt;&lt;br /&gt;vzctl exec 101 passwd&lt;br /&gt;&lt;br /&gt;You can now either connect to the vm via SSH (e.g. with PuTTY), or you enter it as follows:&lt;br /&gt;&lt;br /&gt;vzctl enter 101&lt;br /&gt;&lt;br /&gt;To leave the vm's console, type&lt;br /&gt;&lt;br /&gt;exit&lt;br /&gt;&lt;br /&gt;To stop a vm, run&lt;br /&gt;&lt;br /&gt;vzctl stop 101&lt;br /&gt;&lt;br /&gt;To restart a vm, run&lt;br /&gt;&lt;br /&gt;vzctl restart 101&lt;br /&gt;&lt;br /&gt;To delete a vm from the hard drive (it must be stopped before you can do this), run&lt;br /&gt;&lt;br /&gt;vzctl destroy 101&lt;br /&gt;&lt;br /&gt;To get a list of your vms and their statuses, run&lt;br /&gt;&lt;br /&gt;edy@edy-desktop:~$ sudo vzlist -a&lt;br /&gt;     VEID      NPROC STATUS  IP_ADDR         HOSTNAME                       &lt;br /&gt;       14         19 running 192.168.90.14   f8                             &lt;br /&gt;      101          4 running 192.168.0.101   deb-4.0                        &lt;br /&gt;      102          5 running 192.168.0.102   atlinux                        &lt;br /&gt;      103         30 running 192.168.90.13   cent5 &lt;br /&gt;&lt;br /&gt;vzctl 可以控制很多 --diskspace&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-1955702066997220075?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/1955702066997220075/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=1955702066997220075' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1955702066997220075'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1955702066997220075'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/ubuntu-804-openvz.html' title='Ubuntu 8.0.4 Openvz 使用手记'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-961739547208388980</id><published>2008-08-12T17:53:00.000+08:00</published><updated>2008-08-12T18:09:48.640+08:00</updated><title type='text'>Grub损坏修复实战</title><content type='html'>问题：一同事，装了双系统Ubuntu8.0.4 /XP&lt;br /&gt;自己捣鼓着装了一键还原。。。。。。&lt;br /&gt;很显然grub损坏了，进不去Ubuntu了。&lt;br /&gt;&lt;br /&gt;解决：&lt;br /&gt;一般centos/fc什么的都有linux rescue，当然了，这些只能针对相应发行版。&lt;br /&gt;可是Ubuntu8.0.4没找到，这系统就有点郁闷。&lt;br /&gt;&lt;br /&gt;想用Centos来做把，结果它检测不到自己的Centos不能自己挂载。&lt;br /&gt;&lt;br /&gt;最后用Ubuntu8.0.4进入livecd状态&lt;br /&gt;&lt;br /&gt;mount /dev/sda7 /&lt;br /&gt;因为他的系统装在sda7上嘛&lt;br /&gt;然后&lt;br /&gt;grub-install --no-floppy /dev/sda&lt;br /&gt;reboot&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-961739547208388980?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/961739547208388980/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=961739547208388980' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/961739547208388980'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/961739547208388980'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/grub.html' title='Grub损坏修复实战'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8635178863012069649</id><published>2008-08-11T16:06:00.001+08:00</published><updated>2008-08-11T16:06:35.092+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Server'/><title type='text'>N个 httpd+squid+bind=N个 users</title><content type='html'>&lt;p&gt;场景：&lt;/p&gt; &lt;p&gt;开发人员，一人一套开发环境，并且服务器环境相同。共用一套域名&lt;/p&gt; &lt;p&gt;过程：&lt;/p&gt; &lt;p&gt;开始有两套方案，一是VPS，如Openvz。二是ISP, 如ISPconfig&lt;/p&gt; &lt;p&gt;经过实验，openvz只是在宿主上模拟出一台主机，然后可以在这个台主机上构建不同的环境和系统。&lt;/p&gt; &lt;p&gt;这样的话，就需要在新的主机上重新搭建环境。复杂不说，还有一点就是是不是真正能模拟出来。&lt;/p&gt; &lt;p&gt;因为我们的环境已经很复杂了。最后舍弃，不过这个有点好处就是独立的存在主机。&lt;/p&gt; &lt;p&gt;可以做一些简单的服务器，这样可以提高安全系数。&lt;/p&gt; &lt;p&gt;而ISPconfig是针对空间域名提供商开发的，所以会有不同的域名和空间地址。&lt;/p&gt; &lt;p&gt;一套域名用于多个IP有点问题。&lt;/p&gt; &lt;p&gt;最后想是不是可以多 IP ,多服务器。&lt;/p&gt; &lt;p&gt;这样就用http作服务器，squid做代理, bind来做域名解析。&lt;/p&gt; &lt;p&gt;我们创建了8个环境。。。。。。即：8个http 8个squid 8个bind&lt;/p&gt; &lt;p&gt;创建了8个虚拟网卡。&lt;/p&gt; &lt;p&gt;流程 request-&gt;proxy-&gt;dns-&gt;server -------- server-&gt;proxy-&gt;response to client.&lt;/p&gt; &lt;p&gt;这样每个人用不同的代理，就可以访问自己服务器对应的IP地址。&lt;/p&gt; &lt;p&gt;太繁琐，现在想起来，头很大。呵呵，这种环境确实一种挑战。&lt;/p&gt; &lt;p&gt;但是又有点重复的意思，只要调试2个成功了，其余的就是改参数的问题了。&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8635178863012069649?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8635178863012069649/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8635178863012069649' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8635178863012069649'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8635178863012069649'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/n-httpdsquidbindn-users.html' title='N个 httpd+squid+bind=N个 users'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-2129260714576262749</id><published>2008-08-10T12:28:00.000+08:00</published><updated>2008-08-10T12:29:38.278+08:00</updated><title type='text'>一个结束，另一个开始</title><content type='html'>&lt;div&gt; &lt;div&gt;好久没写东西了，也懒的写，生活开始平淡。即使有大小波折，也懒得去记录。&lt;/div&gt; &lt;div&gt;用心去感悟吧，最近走了两个朋友，一个上海去追求自己的爱去了。&lt;/div&gt; &lt;div&gt;另一个不知道即将飘向何方，祝福一下。&lt;/div&gt; &lt;div&gt; &lt;/div&gt; &lt;div&gt;看到静同学写的blog，也有点感触，就顺手写点东西。&lt;/div&gt; &lt;div&gt;也是为情所伤。看的时候听着郭峰的《移情别恋》，呵呵，竟然下一首是《缠绵》。&lt;/div&gt; &lt;div&gt;有种说不出的感觉。&lt;/div&gt; &lt;div&gt; &lt;/div&gt; &lt;div&gt;也明白为什么和兄弟整天喝酒了，也许就是那样就不会去想最复杂的感情。&lt;/div&gt; &lt;div&gt;最近感觉自己像刺猬了，不能离别人太近，要不然就会伤害别人。&lt;/div&gt; &lt;div&gt;也许是工作的原因吧，总是希望自己的喜欢的人聪明一点。可是自己呢？&lt;/div&gt; &lt;div&gt;呵呵，好像我自己也很笨，感情上吧。技术上还是可以小吹一把的。&lt;/div&gt; &lt;div&gt;以后尽量的去对待朋友吧&lt;/div&gt; &lt;div&gt;不过确实有点忙，要学的东西太多了。也希望你们能理解。&lt;/div&gt; &lt;div&gt; &lt;/div&gt; &lt;div&gt;对了，报道一下朋友们的近况：&lt;/div&gt; &lt;div&gt;小祁8.8号领证了。恭喜一下！&lt;/div&gt; &lt;div&gt;下一个结婚的？&lt;/div&gt; &lt;div&gt;兄弟们会是谁呢？老三加油喽。大白痴估计吧。。。。。&lt;/div&gt; &lt;div&gt;老五？&lt;/div&gt; &lt;div&gt; &lt;/div&gt; &lt;div&gt;即将结束的纪念，即将开始的纪念。&lt;/div&gt; &lt;div&gt;静同学，过去就让它过去吧，祝朋友们以后的爱情道路顺利！&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-2129260714576262749?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/2129260714576262749/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=2129260714576262749' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2129260714576262749'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2129260714576262749'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/blog-post.html' title='一个结束，另一个开始'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-2036247741104441935</id><published>2008-08-08T11:02:00.000+08:00</published><updated>2008-08-08T11:37:08.135+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Company'/><category scheme='http://www.blogger.com/atom/ns#' term='使用技巧'/><title type='text'>如何使用Linux做打印服务器</title><content type='html'>&lt;span style="font-family:arial;"&gt;Head: I don't want to write in Chinese, just because i am too lazy to choose the correct words.&lt;br /&gt;I can't use Wubi input methods, so I am sorry. But maybe I will write in Chinese later. For I found that the solutions about linux in Chinese are difficult to find sometimes. so I will write my&lt;br /&gt;experiences.&lt;br /&gt;&lt;br /&gt;使用Windows做打印服务器，应该不是很困难，因为只要打印机共享，如果Linux需要使用的话，直接用smb连接就行了。&lt;br /&gt;&lt;br /&gt;前一阵子用F8做了一次打印服务器，昨天换系统了，呵呵，搞了一个320G的硬盘。所以顺便换了一下系统。ubuntu8.04还是比较顺手的，目前来说，闲话少叙。&lt;br /&gt;&lt;br /&gt;正题：如何让Linux做打印服务器&lt;br /&gt;&lt;br /&gt;手头工具： 网络，Brother DCP-7010 ，PC(Ubuntu)&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Step1:  &lt;/span&gt;&lt;br /&gt;DCP-7010使用Usb连接到我电脑上。&lt;br /&gt;应该可以看到下面信息：&lt;br /&gt;sudo cat /etc/cups/printers.conf&lt;br /&gt;# Printer configuration file for CUPS v1.3.7&lt;br /&gt;# Written by cupsd on 2008-08-08 10:27&lt;br /&gt;&lt;printer&gt;&lt;br /&gt;Info DCP7010&lt;br /&gt;DeviceURI usb://Brother/DCP-7010&lt;br /&gt;State Idle&lt;br /&gt;StateTime 1218162217&lt;br /&gt;Accepting Yes&lt;br /&gt;Shared Yes&lt;br /&gt;JobSheets none none&lt;br /&gt;QuotaPeriod 0&lt;br /&gt;PageLimit 0&lt;br /&gt;KLimit 0&lt;br /&gt;OpPolicy default&lt;br /&gt;ErrorPolicy retry-job&lt;br /&gt;&lt;/printer&gt;&lt;br /&gt;&lt;br /&gt;if u can't find the above info just check the drivers&lt;br /&gt;useful links:&lt;br /&gt;http://solutions.brother.com/linux/sol/printer/linux/lpr_drivers.html&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Step2&lt;/span&gt;&lt;br /&gt;配置 /etc/cups/cupsd.conf&lt;br /&gt;&lt;br /&gt;需要修改的&lt;br /&gt;原：  Listen localhost:631&lt;br /&gt;改为：Listen *:631&lt;br /&gt;这样才能监听网络嘛&lt;br /&gt;&lt;br /&gt;剩下就是权限设定了，我设定如下：&lt;br /&gt;DefaultAuthType None&lt;br /&gt;&lt;location&gt;&lt;br /&gt; Order allow ,deny&lt;br /&gt; Allow from 192.168.90.*&lt;br /&gt;&lt;/location&gt;&lt;br /&gt;&lt;br /&gt;# Restrict access to the admin pages...&lt;br /&gt;&lt;location&gt;&lt;br /&gt; Order allow,deny&lt;br /&gt; Allow from 192.168.90.*&lt;br /&gt;&lt;/location&gt;&lt;br /&gt;&lt;br /&gt;# Restrict access to configuration files...&lt;br /&gt;&lt;location&gt;&lt;br /&gt; AuthType Default&lt;br /&gt;#  Require user @SYSTEM&lt;br /&gt; Order allow,deny&lt;br /&gt; Allow from 192.168.90.*&lt;br /&gt;&lt;/location&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Step3&lt;/span&gt;&lt;br /&gt;/etc/init.d/cupsys restart&lt;br /&gt;奇怪了，Ubuntu下没有service命令？&lt;br /&gt;&lt;br /&gt;window可以通过http://myip/printers/dcp7010 连接使用了。&lt;br /&gt;&lt;br /&gt;主要注意两点，一是监听，二是打印机名&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-2036247741104441935?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/2036247741104441935/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=2036247741104441935' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2036247741104441935'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2036247741104441935'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/linux.html' title='如何使用Linux做打印服务器'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-103226147520657770</id><published>2008-08-05T15:22:00.000+08:00</published><updated>2008-08-05T15:29:56.961+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux VPS'/><title type='text'>openvz install &amp; use</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Installation&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;x86_64 (2 cores)&lt;br /&gt;&lt;br /&gt;CentOS5.1&lt;br /&gt;&lt;br /&gt;cd /etc/yum.repos.d&lt;br /&gt;wget http://download.openvz.org/openvz.repo&lt;br /&gt;rpm --import  http://download.openvz.org/RPM-GPG-Key-OpenVZ&lt;br /&gt;yum install ovzkernel&lt;br /&gt;&lt;br /&gt;(It will install x86 &amp;amp; x86_64, so del the i386, or it will lead to some errors.)&lt;br /&gt;&lt;br /&gt;rpm -e ovzkernel-2.6.18-53.1.19.el5.028stab053.14.i686&lt;br /&gt;&lt;br /&gt;(Change the /etc/sysctl.conf   add or change the values)&lt;br /&gt;# For Openvz&lt;br /&gt;# On Hardware Node we generally need&lt;br /&gt;# packet forwarding enabled and proxy arp disabled&lt;br /&gt;net.ipv4.ip_forward = 1&lt;br /&gt;net.ipv4.conf.default.proxy_arp = 0&lt;br /&gt;# Enables source route verification&lt;br /&gt;#net.ipv4.conf.all.rp_filter = 1&lt;br /&gt;# Enables the magic-sysrq key&lt;br /&gt;kernel.sysrq = 1&lt;br /&gt;# TCP Explict Congestion Notification&lt;br /&gt;#net.ipv4.tcp_ecn = 0&lt;br /&gt;# we do not want all our interfaces to send redirects&lt;br /&gt;net.ipv4.conf.default.send_redirects = 1&lt;br /&gt;net.ipv4.conf.all.send_redirects = 0&lt;br /&gt;&lt;br /&gt;(add the following lines to /etc/modprobe.conf)&lt;br /&gt;options ip_conntrack ip_conntrack_enable_ve0=1&lt;br /&gt;&lt;br /&gt;reboot&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-103226147520657770?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/103226147520657770/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=103226147520657770' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/103226147520657770'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/103226147520657770'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/08/openvz-install-use.html' title='openvz install &amp; use'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-5497604954687087092</id><published>2008-07-26T09:46:00.000+08:00</published><updated>2008-07-26T09:51:58.712+08:00</updated><title type='text'>when ghost meets ghost</title><content type='html'>This morning, a colleague can't boot her XP&lt;br /&gt;good news is her machines install 2 os , the other is Linux, Cool........&lt;br /&gt;&lt;br /&gt;She made ghost of XP , but now ghost can't find the .gho file to recover her XP.&lt;br /&gt;so I boot into Linux mount the partions with .gho and cp to the root of the partions.&lt;br /&gt;but still no found by Ghost.&lt;br /&gt;&lt;br /&gt;then I just define .gho file name, the recover starts..............&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-5497604954687087092?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/5497604954687087092/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=5497604954687087092' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5497604954687087092'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5497604954687087092'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/when-ghost-meets-ghost.html' title='when ghost meets ghost'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-5137708583186461178</id><published>2008-07-25T17:45:00.000+08:00</published><updated>2008-07-25T17:52:06.374+08:00</updated><title type='text'>Some Notes On djbdns</title><content type='html'>http://cr.yp.to/djbdns/install.html&lt;br /&gt;&lt;br /&gt;http://cr.yp.to/daemontools/install.html&lt;br /&gt;&lt;br /&gt;http://cr.yp.to/ucspi-tcp/install.html&lt;br /&gt;&lt;br /&gt;when I installed daemontools/ucspi-tcp  met some errors:&lt;br /&gt;&lt;br /&gt;/usr/bin/ld: errno: TLS definition in /lib/libc.so.6 section .tbss mismatches non-TLS reference in envdir.o&lt;br /&gt;/lib/libc.so.6: could not read symbols: Bad value&lt;br /&gt;collect2: ld 返回 1&lt;br /&gt;make: *** [envdir] 错误 1&lt;br /&gt;Copying commands into ./command...&lt;br /&gt;cp: 无法 stat “compile/svscan”: 没有那个文件或目录&lt;br /&gt;&lt;br /&gt;wget http://www.qmail.org/netqmail-1.05.tar.gz&lt;br /&gt;tar xfz netqmail-1.05.tar.gz&lt;br /&gt;cd /package/admin/daemontools-0.76&lt;br /&gt;patch &lt; patch/to/daemontools-0.76.errno.patch&lt;br /&gt;cd ucspi-tcp-0.88&lt;br /&gt;patch &lt; ucspi-tcp-0.88.errno.patch&lt;br /&gt;&lt;br /&gt;Then all seems ok!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-5137708583186461178?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/5137708583186461178/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=5137708583186461178' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5137708583186461178'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/5137708583186461178'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/some-notes-on-djbdns.html' title='Some Notes On djbdns'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-6058215680985253543</id><published>2008-07-22T16:26:00.000+08:00</published><updated>2008-07-22T16:31:40.135+08:00</updated><title type='text'>Migrate zimbra4.5.4 To zimbra5.0.x</title><content type='html'>On my way, on the edge of  getting pieces.&lt;br /&gt;&lt;br /&gt;the scence:&lt;br /&gt;&lt;br /&gt;Now    remote: running 4.5.4 on CentOS4.4&lt;br /&gt;target localhost : 5.0.x to CentOS4.4&lt;br /&gt;&lt;br /&gt;We have to migrate zimbra to 4.5.11 and then 5.0.x&lt;br /&gt;&lt;br /&gt;after some tries, it seems rsync is impossible&lt;br /&gt;migrate the db doesn't work.&lt;br /&gt;&lt;br /&gt;go to the forums.........&lt;br /&gt;http://wiki.zimbra.com/index.php?title=User_Migration&lt;br /&gt;&lt;br /&gt;new try.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-6058215680985253543?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/6058215680985253543/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=6058215680985253543' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6058215680985253543'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6058215680985253543'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/migrate-zimbra454-to-zimbra50x.html' title='Migrate zimbra4.5.4 To zimbra5.0.x'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-4067815328356488023</id><published>2008-07-22T13:04:00.000+08:00</published><updated>2008-07-22T13:05:15.300+08:00</updated><title type='text'>Enterprise Installation of DNS and BIND</title><content type='html'>http://www.bsdguides.org/guides/freebsd/networking/install_bind&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-4067815328356488023?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/4067815328356488023/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=4067815328356488023' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4067815328356488023'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4067815328356488023'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/enterprise-installation-of-dns-and-bind.html' title='Enterprise Installation of DNS and BIND'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7710059700776703795</id><published>2008-07-21T10:55:00.000+08:00</published><updated>2008-07-21T10:57:04.062+08:00</updated><title type='text'>Patch for app &amp; kernel</title><content type='html'>&lt;table border="0" cellpadding="2" cellspacing="3" width="100%"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td bg style="color:#c00000;"&gt;&lt;span style="font-size:+1;color:#e0e0e0;"&gt;&lt;b&gt;Applying the Patch              &lt;/b&gt;&lt;/span&gt;                 &lt;/td&gt;               &lt;/tr&gt;         &lt;tr&gt;   &lt;td bgcolor="#e0e0e0"&gt; For the purpose of this guide, we will use &lt;code&gt;linux-2.2.x&lt;/code&gt; for the kernel name.  You should replace the &lt;code&gt;x&lt;/code&gt; with the version number of the patch you are installing. &lt;ol&gt;&lt;li&gt;Move the downloaded kernel patch to the &lt;code&gt;/usr/src/linux&lt;/code&gt; directory.  &lt;/li&gt;&lt;li&gt;&lt;code&gt;cd /usr/src/linux&lt;/code&gt; &lt;/li&gt;&lt;li&gt;If you downloaded a patch with a &lt;code&gt;.gz&lt;/code&gt; extension, execute the following command:&lt;br /&gt;&lt;code&gt;gunzip patch-2.2.x.gz&lt;/code&gt; &lt;br /&gt;&lt;br /&gt;If you downloaded a patch with a &lt;code&gt;.bz2&lt;/code&gt; extension, execute the following command:&lt;br /&gt;&lt;code&gt;bunzip2 patch-2.2.x.bz2&lt;/code&gt;  &lt;/li&gt;&lt;li&gt;There should now be a file called &lt;code&gt;patch-2.2.14&lt;/code&gt; in the  &lt;code&gt;/usr/src/linux&lt;/code&gt; directory.  Apply the patch to the kernel source tree with the  following command:&lt;br /&gt;&lt;code&gt;patch -p1 &lt;&gt; &lt;/li&gt;&lt;/ol&gt;      You should now be ready to set the configuation for the new kernel you wish to build.  See the &lt;a href="http://www.linuxheadquarters.com/howto/tuning/kernelconfiguring.shtml"&gt;Configuring a New Kernel&lt;/a&gt; guide for more information.&lt;br /&gt;&lt;br /&gt;&lt;h1&gt;用Diff和Patch工具维护源码&lt;/h1&gt;http://www.ibm.com/developerworks/cn/linux/l-diffp/index.html&lt;br /&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7710059700776703795?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7710059700776703795/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7710059700776703795' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7710059700776703795'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7710059700776703795'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/patch-for-app-kernel.html' title='Patch for app &amp; kernel'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-1671310321328136235</id><published>2008-07-16T15:31:00.000+08:00</published><updated>2008-07-16T15:32:17.382+08:00</updated><title type='text'>how to kick out the Robots&amp;Spiders</title><content type='html'>&lt;div class="entry"&gt;               &lt;p&gt;At first, I ‘d like to thanks for xinbin.chen’s help.&lt;br /&gt;He should be a good teacher who could teach u how to fish not just gave u some fishes.&lt;/p&gt; &lt;p&gt;No more words, let’s get to the point.&lt;/p&gt; &lt;p&gt;There are two popular methods to kick out the Robots &amp;amp; Spiders.&lt;span id="more-24"&gt;&lt;/span&gt;&lt;/p&gt; &lt;p&gt;1: put robots.txt in the www root.&lt;br /&gt;the rules are:&lt;/p&gt; &lt;p&gt;#that u want to allow the spider get ur site&lt;br /&gt;User-agent: somespider&lt;br /&gt;Disallow:&lt;/p&gt; &lt;p&gt;#disallow all the spiders get ur site&lt;br /&gt;User-agent: *&lt;br /&gt;Disallow: /&lt;/p&gt; &lt;p&gt;#disallow certain spider get ur site&lt;br /&gt;User-agent: spider&lt;br /&gt;Disallow: /&lt;/p&gt; &lt;p&gt;but now many spider can pretend themselves as FF, Opera, IE.&lt;br /&gt;so we need some other method. and then the 2nd.&lt;/p&gt; &lt;p&gt;2: If u use apache, U got the good idea.&lt;br /&gt;add the following lines to the httpd.conf&lt;/p&gt; &lt;p&gt;At first, I ‘d like to thanks for xinbin.chen’s help.&lt;br /&gt;He should be a good teacher who could teach u how to fish not just gave u some fishes.&lt;/p&gt; &lt;p&gt;No more words, let’s get to the point.&lt;/p&gt; &lt;p&gt;There are two popular methods to kick out the Robots &amp;amp; Spiders.&lt;/p&gt; &lt;p&gt;1: put robots.txt in the www root.&lt;br /&gt;the rules are:&lt;/p&gt; &lt;p&gt;#that u want to allow the spider get ur site&lt;br /&gt;User-agent: somespider&lt;br /&gt;Disallow:&lt;/p&gt; &lt;p&gt;#disallow all the spiders get ur site&lt;br /&gt;User-agent: *&lt;br /&gt;Disallow: /&lt;/p&gt; &lt;p&gt;#disallow certain spider get ur site&lt;br /&gt;User-agent: spider&lt;br /&gt;Disallow: /&lt;/p&gt; &lt;p&gt;but now many spider can pretend themselves as FF, Opera, IE.&lt;br /&gt;so we need some other method. and then the 2nd.&lt;/p&gt; &lt;p&gt;2: If u use apache, U got the good idea.&lt;br /&gt;add the following lines to the httpd.conf&lt;/p&gt; &lt;p&gt;At first, I ‘d like to thanks for xinbin.chen’s help.&lt;br /&gt;He should be a good teacher who could teach u how to fish not just gave u some fishes.&lt;/p&gt; &lt;p&gt;No more words, let’s get to the point.&lt;/p&gt; &lt;p&gt;There are two popular methods to kick out the Robots &amp;amp; Spiders.&lt;/p&gt; &lt;p&gt;1: put robots.txt in the www root.&lt;br /&gt;the rules are:&lt;/p&gt; &lt;p&gt;#that u want to allow the spider get ur site&lt;br /&gt;User-agent: somespider&lt;br /&gt;Disallow:&lt;/p&gt; &lt;p&gt;#disallow all the spiders get ur site&lt;br /&gt;User-agent: *&lt;br /&gt;Disallow: /&lt;/p&gt; &lt;p&gt;#disallow certain spider get ur site&lt;br /&gt;User-agent: spider&lt;br /&gt;Disallow: /&lt;/p&gt; &lt;p&gt;but now many spider can pretend themselves as FF, Opera, IE.&lt;br /&gt;so we need some other method. and then the 2nd.&lt;/p&gt; &lt;p&gt;2: If u use apache, U got the good idea.&lt;br /&gt;add the following lines to the httpd.conf&lt;/p&gt; &lt;p&gt;SetEnvIfNoCase User_Agent &lt;em&gt;Robot &lt;/em&gt;a_robot=1&lt;br /&gt;SetEnvIfNoCase User_Agent &lt;em&gt;Spider&lt;/em&gt; a_robot=1&lt;/p&gt; &lt;p&gt;the Robot/Spider can change to the spider/robot u want to forbidden.&lt;/p&gt; &lt;p&gt;&lt;directory&gt;&lt;/p&gt; &lt;p&gt;# omit some lines……………………&lt;/p&gt; &lt;p&gt;Order allow,deny&lt;br /&gt;Allow from all&lt;br /&gt;Deny from env=a_robot&lt;/p&gt; &lt;p&gt;&lt;/directory&gt;&lt;/p&gt; &lt;p&gt;apache graceful , it will work.&lt;/p&gt; &lt;p&gt;The is a story when I did this mission. we have squid for our site. I change the proxy and don’t let it cache the dest site. but it still sth wrong. I don’t know how to reslove it until chen told me some princples of squid.&lt;/p&gt; &lt;p&gt;change the paras.&lt;/p&gt; &lt;p&gt;#this two lines for direct the domain not cache.&lt;br /&gt;acl targetdomain dstdomain .urdomain.com&lt;br /&gt;always_direct allow targetdomain&lt;/p&gt; &lt;p&gt;#this line just tell squid not cache the errors, such as ERROR/ forbidden information.&lt;br /&gt;negative_ttl 0&lt;/p&gt;                        &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-1671310321328136235?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/1671310321328136235/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=1671310321328136235' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1671310321328136235'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/1671310321328136235'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/how-to-kick-out-robots.html' title='how to kick out the Robots&amp;Spiders'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-734071229473162306</id><published>2008-07-15T10:06:00.000+08:00</published><updated>2008-07-15T10:07:26.865+08:00</updated><title type='text'>One Words To One Question</title><content type='html'>&lt;p&gt;Q: Set Java Env&lt;/p&gt; &lt;p&gt;A: edit ~/.bash_profile&lt;/p&gt; &lt;p&gt;add the following lines &lt;/p&gt; &lt;p&gt;PATH=$PATH:$HOME/bin:/opt/jdk1.6.0_07/bin&lt;br /&gt;CLASSPATH=.:/opt/jdk1.6.0_07/lib&lt;br /&gt;JAVA_HOME=/opt/jdk1.6.0_07&lt;br /&gt;JRE_HOME=/opt/jdk1.6.0_07/jre&lt;/p&gt; &lt;p&gt;run source .bash_profile&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-734071229473162306?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/734071229473162306/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=734071229473162306' title='9 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/734071229473162306'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/734071229473162306'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/one-words-to-one-question.html' title='One Words To One Question'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>9</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-6336935736011734250</id><published>2008-07-14T10:59:00.000+08:00</published><updated>2008-07-14T11:05:50.710+08:00</updated><title type='text'>GeoIP-City for awstats</title><content type='html'>we can use qq ip data for awstats to log the City Information.&lt;br /&gt;&lt;br /&gt;Note: the words like &lt;span style="font-style: italic;"&gt;this &lt;/span&gt;, u should change according ur enviorment.&lt;br /&gt;Follow me:&lt;br /&gt;&lt;a href="http://www.ieasy.org/reload/cat2/awstats_qqhosti.html"&gt;&lt;/a&gt; &lt;blockquote&gt; &lt;p&gt;1. download &lt;a href="http://www.cz88.net/fox/"&gt;IP data&lt;/a&gt;，and we use QQWry.dat&lt;br /&gt;2. download &lt;a href="http://www.ieasy.org/download/qqhostinfo.pm"&gt;qqhostinof.pm&lt;/a&gt;&lt;br /&gt;3. download &lt;a href="http://www.ieasy.org/download/qqwry.pl"&gt;anaylis QQWry.dat&lt;/a&gt;&lt;br /&gt;4. put them in cgi-bin/plugins&lt;br /&gt;5. change qqwry.pl，change ./QQWry.dat as &lt;span style="font-style: italic;"&gt;/pathto/QQWry.Dat&lt;/span&gt;&lt;br /&gt;6. make change to /etc/awstats/&lt;span style="font-style: italic;"&gt;some.....conf&lt;/span&gt;，add LoadPlugin=”qqhostinfo”&lt;/p&gt; &lt;/blockquote&gt; &lt;p&gt;Now update the awstats, u can find location.&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-6336935736011734250?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/6336935736011734250/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=6336935736011734250' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6336935736011734250'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/6336935736011734250'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/geoip-city-for-awstats.html' title='GeoIP-City for awstats'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8116457895500807455</id><published>2008-07-13T19:20:00.001+08:00</published><updated>2008-07-13T19:42:22.349+08:00</updated><title type='text'>Hypertable+KFS configure logs.</title><content type='html'>Now, the hypertable can run as bin/start-all -servers.sh local&lt;br /&gt;but can't run as bin/start-all-servers.sh kosmos.&lt;br /&gt;&lt;br /&gt;Error Logs:&lt;br /&gt;&lt;br /&gt;if conf/hypertable.cfg change the wrong kfs ports, the errors of&lt;br /&gt;Hypertable.Master.log seems like the following.&lt;br /&gt;&lt;br /&gt;1215947994 ERROR Hypertable.Master : run (/root/hypertable/hypertable/src/cc/Hypertable/Master/RequestHandlerRegisterServer.cc:49): Hypertable::Exception: Error mkdirs DFS directory /hypertable/tables/METADATA/default - DFS BROKER i/o error&lt;br /&gt;      at virtual void Hypertable::DfsBroker::Client::mkdirs(const Hypertable::String&amp;amp;) (/root/hypertable/hypertable/src/cc/DfsBroker/Lib/Client.cc:513)&lt;br /&gt;      at virtual void Hypertable::DfsBroker::Client::mkdirs(const Hypertable::String&amp;amp;) (/root/hypertable/hypertable/src/cc/DfsBroker/Lib/Client.cc:510): No route to host&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;now the kfs up and hypertable.master.log ERROR is :&lt;br /&gt;1215948200 ERROR Hypertable.Master : (/root/hypertable/hypertable/src/cc/Hypertable/Master/Master.cc:451) METADATA update error (row_key = 0: : DFS BROKER i/o error)&lt;br /&gt;&lt;br /&gt;so lead to the Hypertable.master can't up&lt;br /&gt;&lt;br /&gt;1215948306 ERROR hypertable : (/root/hypertable/hypertable/src/cc/AsyncComm/Comm.cc:207) No connection for 10.0.0.205:38050&lt;br /&gt;1215948306 WARN hypertable : (/root/hypertable/hypertable/src/cc/Hypertable/Lib/MasterClient.cc:224) Comm::send_request to 10.0.0.205:38050 failed - COMM not connected&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8116457895500807455?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8116457895500807455/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8116457895500807455' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8116457895500807455'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8116457895500807455'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/hypertablekfs-configure-logs.html' title='Hypertable+KFS configure logs.'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-4443689456731461172</id><published>2008-07-11T21:24:00.000+08:00</published><updated>2008-07-11T21:26:10.952+08:00</updated><title type='text'>Some Useful Tools</title><content type='html'>1.&lt;br /&gt;XAMPP is an easy to install Apache distribution containing MySQL, PHP and Perl.&lt;br /&gt;XAMPP is really very easy to install and to use - just download, extract and start.&lt;br /&gt;http://www.apachefriends.org/en/xampp.html&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-4443689456731461172?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/4443689456731461172/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=4443689456731461172' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4443689456731461172'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/4443689456731461172'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/some-useful-tools.html' title='Some Useful Tools'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-3762810034080425582</id><published>2008-07-09T12:00:00.001+08:00</published><updated>2008-07-09T16:33:27.887+08:00</updated><title type='text'>Fedora Yum source.</title><content type='html'>http://mirrors.fedoraproject.org/&lt;br /&gt;&lt;br /&gt;For China, the following are fast by my test.&lt;br /&gt;U can test by urself. hehe&lt;br /&gt;&lt;br /&gt;http://fedora.candishosting.com.cn/pub/fedora/linux&lt;br /&gt;http://opensource.nchc.org.tw/fedora/linux&lt;br /&gt;http://free.nchc.org.tw/fedora/linux/&lt;br /&gt;http://ftp.twaren.net/Linux/Fedora/linux/&lt;br /&gt;&lt;br /&gt;How to Make Ur Own Mirror&lt;br /&gt;http://fedoraproject.org/wiki/Infrastructure/Mirroring&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-3762810034080425582?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/3762810034080425582/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=3762810034080425582' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3762810034080425582'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/3762810034080425582'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/fedora-yum-source.html' title='Fedora Yum source.'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8755168561911662801</id><published>2008-07-08T14:11:00.000+08:00</published><updated>2008-07-08T14:16:42.960+08:00</updated><title type='text'>How come performance degrade with more data nodes?</title><content type='html'>&lt;div class="post-body entry-content"&gt; &lt;span style="font-weight: bold; font-size: 130%;"&gt;How come performance degrade with more data nodes?&lt;/span&gt;&lt;br /&gt;Some of you might have noticed that performance might actually drop slightly when you move from a two node cluster to a four node cluster. To understand this we need to understand how information is and tables are organized in MySQL Cluster. Moreover, I will also mention a bit on distribution awareness, a feature that can be used to minimze this performance drop in bigger configurations.&lt;br /&gt;&lt;br /&gt;In MySQL Cluster a table divided into fragments and spread on the data nodes.&lt;br /&gt;You have as many fragments (Fx) as you have data nodes (Nx).&lt;br /&gt;If you have four data nodes, then a table will have four fragments:&lt;br /&gt;&lt;br /&gt;Table T1= {F1, F2, F3, F4}&lt;br /&gt;&lt;br /&gt;These fragments will be laid out on the data nodes as follows:&lt;br /&gt;&lt;br /&gt;N1=F1P&lt;br /&gt;N2=F2P&lt;br /&gt;N3=F3P&lt;br /&gt;N4=F4P&lt;br /&gt;&lt;br /&gt;I have written FxP, where P indicates the Primary fragment and potential locking conflicts are resolved on the data node having the Primary fragment for the particular data.&lt;br /&gt;But this does not give you any redundancy. For redundancy you need two two replicas (copies) of the fragments (NoOfReplicas=2 in config.ini) :&lt;br /&gt;&lt;br /&gt;N1=F1P, F2S&lt;br /&gt;N2=F2P, F1S&lt;br /&gt;N3=F3P, F4S&lt;br /&gt;N4=F4P, F3S&lt;br /&gt;&lt;br /&gt;Some explanations:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Nx = data node x&lt;br /&gt;&lt;/li&gt;&lt;li&gt;S = secondary fragment (copy).&lt;/li&gt;&lt;li&gt;P = primary fragment, lock conflicts are handled.&lt;/li&gt;&lt;li&gt;Each data node has a transaction coordinator that is active.&lt;/li&gt;&lt;li&gt;Nodes sharing the same information is called a node group. NG0={N1, N2} shares the same information (same fragments), and NG1{N3, N4} shares the same information.&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;Transactions are started in a round-robin fashion on the cluster from the application, unless you use distribution awareness (startTransaction with a hint). Since transactions are started in round-robin, the transaction might be started on a node not having the particular data! When the the transcation coordinator (who is picked randomly by the application (mysql server of ndbapi program) receives a primary key request (read/write) it calculates a 128-bit hash on the primary key. The first 64-bits tells where in the priamry key hash table the entry should be stored and the second 64-bits identify which fragment the data should be located on. It could be a fragment residing on another node than the TC. If so, the TC has to forward the request (if it is a read it is forwared and the node having the data will reply to the application directly) to that fragment, or initiate the 2PC protocol to update both fragments that should have the data. If the update of a row identified by PK=1 hashes to F1, then both F1P and F1S has to be synchronously updated. The 2PC takes care of that and a little bit more about that later.&lt;br /&gt;&lt;br /&gt;Pretend that you want to read data that is located in fragment F1:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;If you do a read without a lock (CommittedRead), then we can read from both primary and secondary fragment, hence you have 50% chance on hitting the correct nodes (N1 and N2) having you data.&lt;/li&gt;&lt;li&gt;If you read with a lock, the we can only read from F1P, hence we have 25% chance of hitting the right node (N1)!&lt;/li&gt;&lt;/ul&gt;And if you want to write (delete, update, insert)&lt;br /&gt;&lt;ul&gt;&lt;li&gt;If you write to F1, then the nodes N1 and N2 are involved, since both copies have to be updated using the 2PC protocol.&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;The more nodes you have, then more node groups you will have and the probability that a read transaction will end up on a node that does not have the information increases.&lt;br /&gt;For eight nodes, two replicas, you have four node groups and only 25% chance that a read without lock will go to the correct nodes.&lt;br /&gt;&lt;br /&gt;Now, what you have seen is that performance degrades when you go from two data nodes to four nodes.&lt;br /&gt;If you have two nodes, then a table is divided into two fragments:&lt;br /&gt;Table T1= {F1, F2}&lt;br /&gt;&lt;br /&gt;And the information is laid out as (with NoOfReplicas=2):&lt;br /&gt;N1=F1P, F2S&lt;br /&gt;N2=F2P, F1S&lt;br /&gt;&lt;br /&gt;Pretend that you want to read data that is located in fragment F1.&lt;br /&gt;&lt;ul&gt;&lt;li&gt; If you do a read without a lock (CommittedRead), you have 100% chance starting the transaction on the nodes having the data (N1 and N2 both has the data in F1P or F1S)!&lt;/li&gt;&lt;li&gt;If you read with a lock, the we can only read from F1P, hence we have 50% chance of hitting the right node (N1)!&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;And if you write:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;If you write to F1, then the nodes N1 and N2 are involved, since both copies have to be updated using the 2PC protocol. I will not explain the 2PC protocol much more than saying that the transaction coordinator (TC) (can be on any of the nodes) will send: Prepare phase: TC --&gt; F1P --&gt; F1S --&gt; TC , Commit phase: TC --&gt; F1S --&gt; F1P --&gt; TC.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;In this case three different nodes can be involved in a four node cluster, but only two nodes can be involved in the two node cluster, thus reducing the number of messages sent between computers.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size: 130%;"&gt;&lt;span style="font-weight: bold;"&gt;To summarize up to this point&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Reads becomes more expensive with bigger cluster because the chance getting to the wrong nodes increases, thus an extra (and maximally one) network hop is required.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Writes becomes more a little bit more expensive since there are more network hops involved (the mysqld or the ndbapi/ndbj application starts the transaction on data node N3, but the data you are updating is on data nodes N1 and N2).&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style="font-size: 130%;"&gt;&lt;span style="font-weight: bold;"&gt;Distribution awareness&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;By using distribution awareness you can get around these problems and minimize the number of network hops. Distribution awareness ensures that the transaction is started on the node that has the data, or it can also be used to write data to a particular set of nodes.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Reads (with locks or without locks) will now have 100% chance getting to the right node&lt;/li&gt;&lt;li&gt;Writes will now always be handled by the data nodes in one particular node group.&lt;/li&gt;&lt;li&gt;Distribution awareness is supported in NDBAPI and NDBJ, is supported from the MySQL Server from MySQL 5.1.22 - 6.3.4 Carrier Grade Edition.&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;In my next post I plan to illustrate how to use these features from respective access method (SQL or NDBAPI).  &lt;/div&gt;   &lt;span class="post-author vcard"&gt; Posted by &lt;span class="fn"&gt;Johan Andersson&lt;/span&gt; &lt;/span&gt; &lt;span class="post-timestamp"&gt; at &lt;a class="timestamp-link" href="http://johanandersson.blogspot.com/2007/10/data-distribution-and-distribution.html" rel="bookmark" title="permanent link"&gt;&lt;abbr class="published" title="2007-10-29T12:21:00Z"&gt;&lt;/abbr&gt;&lt;/a&gt; &lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8755168561911662801?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8755168561911662801/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8755168561911662801' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8755168561911662801'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8755168561911662801'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/how-come-performance-degrade-with-more.html' title='How come performance degrade with more data nodes?'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-8072988612325786935</id><published>2008-07-03T15:54:00.000+08:00</published><updated>2008-07-03T15:56:35.297+08:00</updated><title type='text'>Storage Engine for MySQL--Falcon</title><content type='html'>MySQL/Sun released a new storage engine "Falcon" in January, 2007. Falcon is a high performance transactional (fully compliant with ACID) storage engine, which is beta at this time (June 2008). In this article, I describe Falcon's features and its architecture in detail.&lt;br /&gt;&lt;br /&gt;More details:&lt;br /&gt;&lt;br /&gt;http://dev.mysql.com/tech-resources/articles/falcon-in-depth.html&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-8072988612325786935?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/8072988612325786935/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=8072988612325786935' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8072988612325786935'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/8072988612325786935'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/07/storage-engine-for-mysql-falcon.html' title='Storage Engine for MySQL--Falcon'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-951291437307994512</id><published>2008-06-28T22:54:00.002+08:00</published><updated>2008-06-30T14:06:51.989+08:00</updated><title type='text'>MySQL Cluster</title><content type='html'>I am busy with MySQL Cluster these day, from 0 to know sth about MySQL Cluster.&lt;br /&gt;like this kind of challenges, Just leave a msg, and record sth.&lt;br /&gt;&lt;br /&gt;how to build MySQL-Cluster&lt;br /&gt;1, get sources from line.&lt;br /&gt;     ftp://ftp.mysql.com/pub/mysql/download/cluster_telco/&lt;br /&gt;2, tar xvzf mysql*.tar.gz&lt;br /&gt;3, CFLAGS="-fPIC" ./configure --with-plugins=max&lt;br /&gt;4, make j4&lt;br /&gt;5, make bin-dist&lt;br /&gt;6, now U can find tar.gz in the source dir, just redistrbute it.&lt;br /&gt;&lt;br /&gt;Here are some useful links.&lt;br /&gt;&lt;br /&gt;http://dev.mysql.com/&lt;br /&gt;&lt;br /&gt;http://johanandersson.blogspot.com/&lt;br /&gt;&lt;br /&gt;http://mikaelronstrom.blogspot.com/&lt;br /&gt;&lt;br /&gt;DBT tools for test MySQL&lt;br /&gt;http://www.iclaustron.com/downloads.html&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-951291437307994512?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/951291437307994512/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=951291437307994512' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/951291437307994512'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/951291437307994512'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/06/mysql-cluster.html' title='MySQL Cluster'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-7055236993695489713</id><published>2008-06-23T10:05:00.000+08:00</published><updated>2008-06-23T10:09:05.701+08:00</updated><title type='text'>Shutdown the past</title><content type='html'>以后用Linux，估计很少登陆QQ空间写东西了。&lt;br /&gt;就写在这里吧，呵呵。&lt;br /&gt;&lt;br /&gt;昨天沙滩足球挂彩，赋闲在家。&lt;br /&gt;好好收拾一下自己，好久没整理了。&lt;br /&gt;&lt;br /&gt;看看麦兜，搞笑的一天。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-7055236993695489713?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/7055236993695489713/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=7055236993695489713' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7055236993695489713'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/7055236993695489713'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/06/shutdown-past.html' title='Shutdown the past'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-2612760788892481851</id><published>2008-06-22T22:06:00.000+08:00</published><updated>2008-06-22T22:08:36.534+08:00</updated><title type='text'>Long Time No See</title><content type='html'>I haven't login into this blog for a long time, but it is still alive.&lt;br /&gt;It is stopped because of the Internet Accident that happened long time ago. the earthquake that made the blog not available.&lt;br /&gt;&lt;br /&gt;Now start a new record!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-2612760788892481851?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/2612760788892481851/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=2612760788892481851' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2612760788892481851'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/2612760788892481851'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2008/06/long-time-no-see.html' title='Long Time No See'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116679525112091938</id><published>2006-12-22T21:31:00.000+08:00</published><updated>2006-12-22T21:48:39.483+08:00</updated><title type='text'>Notes of the LFS making(Fin)</title><content type='html'>&lt;span style="font-size:100%;"&gt;&lt;span style="color: rgb(0, 0, 153);"&gt;&lt;span style="color: rgb(153, 51, 0);"&gt;I focused on the LFS about a week, I have finished installed the LFS,  It can boot and work very well.&lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(153, 51, 0);"&gt;In fact I can finish it in 2 days, but I made some mistakes that shouldn't happen to me.&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="color: rgb(255, 0, 0);"&gt;I didn't read the Notice on the LFS handbook. so I paid!&lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(255, 0, 0);"&gt;Most important: check the $LFS, and chroot (Esp when u reboot the PC).&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;When U install the Perl, U may face this problem:&lt;/span&gt;&lt;br /&gt;Updating man page uname.1&lt;br /&gt;Can't locate POSIX.pm in @INC (@INC contains: /tools/lib/perl5/5.8.4/i686-linux /tools/lib/perl5/5.8.4 /tools/lib/perl5/site_perl/5.8.4/i686-linux /tools/lib/perl5/site_perl/5.8.4 /tools/lib/perl5/site_perl .) at ./help2man line 28.&lt;br /&gt;BEGIN failed--compilation aborted at ./help2man line 28.&lt;br /&gt;make[2]: *** [uname.1] Error 2&lt;br /&gt;make[2]: Leaving directory `/sources/coreutils-5.2.1/man'&lt;br /&gt;make[1]: *** [all-recursive] Error 1&lt;br /&gt;make[1]: Leaving directory `/sources/coreutils-5.2.1'&lt;br /&gt;make: *** [all] Error 2&lt;br /&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);"&gt;Can't locate POSIX.pm in @INC (@INC contains: /tools/lib/perl5/5.8.4/i686-linux /tools/lib/perl5/5.8.4 /tools/lib/perl5/site_perl/5.8.4/i686-linux /tools/lib/perl5/site_perl/5.8.4 /tools/lib/perl5/site_perl .) at ./help2man line 28.&lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);"&gt;#ls /tools/lib/perl5/5.8.X&lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);"&gt;#ln -s /tools/lib/perl5/5.8.X /tools/lib/perl5/5.8.Y&lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);"&gt;#make&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);"&gt;Error on installing&lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);"&gt;Shadow-4.0.9&lt;/span&gt;&lt;br /&gt;./configure --libdir=/lib --enable-shared&lt;br /&gt;&lt;br /&gt;/mnt/lfs/tools/bin/../lib/gcc/i686-pc-linux-gnu/3.4.3/../../../../i686-pc-linux-gnu/bin/ld: cannot find -lgcc_s&lt;br /&gt;collect2: ld returned 1 exit status&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;## ----------- ##&lt;br /&gt;## confdefs.h. ##&lt;br /&gt;## ----------- ##&lt;br /&gt;&lt;br /&gt;#define PACKAGE "shadow"&lt;br /&gt;#define PACKAGE_BUGREPORT ""&lt;br /&gt;#define PACKAGE_NAME ""&lt;br /&gt;#define PACKAGE_STRING ""&lt;br /&gt;#define PACKAGE_TARNAME ""&lt;br /&gt;#define PACKAGE_VERSION ""&lt;br /&gt;#define VERSION "4.0.9"&lt;br /&gt;#define _GNU_SOURCE 1&lt;br /&gt;&lt;br /&gt;configure: exit 77&lt;br /&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);"&gt;Check the $LFS and chroot. :-)&lt;br /&gt;&lt;br /&gt;Most of the check is no need, except the ones needed. :-)&lt;br /&gt;Also, I cp the cmd to the shell.  Wish U good Luck on the LFS!&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116679525112091938?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116679525112091938/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116679525112091938' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116679525112091938'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116679525112091938'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/notes-of-lfs-makingfin.html' title='Notes of the LFS making(Fin)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116650366710534029</id><published>2006-12-19T12:42:00.000+08:00</published><updated>2006-12-19T12:47:47.953+08:00</updated><title type='text'>Notes of the LFS making</title><content type='html'>nYesterday, I began to make the LFS.and have some notes as follow&lt;br /&gt;FATAL: can't create pic/regex.o&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This maybe caused by didn't deleting the gcc-3.4.3 &amp; gcc-build&lt;br /&gt;So we'd better mv gcc-3.4.3 gcc-3.4.3bak &amp;amp;mv gcc-build gcc-buildbak&lt;br /&gt;&lt;br /&gt;If any problems , I will post them.(To be continued).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116650366710534029?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116650366710534029/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116650366710534029' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116650366710534029'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116650366710534029'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/notes-of-lfs-making.html' title='Notes of the LFS making'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116640948996744541</id><published>2006-12-18T09:55:00.000+08:00</published><updated>2006-12-18T10:38:10.213+08:00</updated><title type='text'>I was refused by Inspur!</title><content type='html'>Today, exactly yesterday, My classmates received the interview anouncement. Without mine.&lt;br /&gt;I do want to enter a big IT provider though Inspur have close relationship with Microsoft. To tell the truth,I want to use my linux in my future job. However, Feel depressed to some extent,  At least I tried.&lt;br /&gt;    Their exam is about C++, I don't like to programm. so I choose the Support depart, Why? The exam is basic, I failed. Funny, isn't it?My advantages can't be showed now. So I tell myself, If I am excellent, I will prove it!&lt;br /&gt;    Inspur, I won't let you down, Today, U refused me. Tomorrow, U will find U made a wrong descison. If u still keep so close with Microsoft. We should have our own OS,  I don't want to hear that our national products be eaten by Microsoft.&lt;br /&gt;    Good Luck To Inspur and Myself!&lt;br /&gt;    A new start show on my way to success! Cheer Up!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116640948996744541?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116640948996744541/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116640948996744541' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116640948996744541'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116640948996744541'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/i-was-refused-by-inspur.html' title='I was refused by Inspur!'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116610119198685432</id><published>2006-12-14T20:56:00.000+08:00</published><updated>2006-12-14T20:59:52.146+08:00</updated><title type='text'>Basic tips for Linux programming(ZT)</title><content type='html'>&lt;p&gt;If you’re new to Linux programming, then you might be interested in considering these aspects before you start your wonderful journey. Especially if you’ve programmed in Windows, you might want to change some of your ideas, so that you minimize the “culture” shock you experience when you encounter completely different ideas and ways of thinking.&lt;/p&gt; &lt;p&gt;Here are some of my tips, based on common questions asked in forums about Linux programming especially from experienced Windows programmers.&lt;/p&gt; &lt;h2&gt;Evaluate every available alternative&lt;/h2&gt; &lt;p&gt;Unlike the unified Windows API which provides the Windows programmer with a single method of achieving a certain objective, Linux provides a variety of ways to achieve the same objective. For instance there are a variety of GUI abstraction toolkits, the major ones being QT and GTK to write GUI programs. Again, you need not necessarily choose C or C++. There are many choices for programming including basic shell scripting, Perl, Python and PHP. So do not always have a fixed idea that you need to learn the “hard” way. In fact, you might be surprised to discover the power and elegance of scripting.&lt;/p&gt; &lt;p&gt;Do not be overwhelmed by choices. Just be aware of all of them and pick the tools and techniques that you’re most comfortable with.&lt;/p&gt; &lt;h2&gt;IDEs are not necessarily more productive&lt;/h2&gt; &lt;p&gt;Programmers who’ve used Microsoft Visual Studio extensively to do their development might find it uncomfortable to adapt to Linux’s way of doing things. While there are some pretty decent IDEs in Linux including Kdevelop, anjuta and Eclipse, you might actually find that using a text editor and creating a make file to be a better idea in the long run. Particularly when you are developing Free Software applications, you might not want to tie down development to a particular platform or IDE considering that your code will be shared and other programmers might also be contributing to your project. While IDEs are not always bad, you might find developing smaller projects using a simple text editor and a makefile a better idea.&lt;/p&gt; &lt;h2&gt;Do not look for distribution-specific features&lt;/h2&gt; &lt;p&gt;It might surprise many Windows programmers to know that you can practically make no assumptions about a default Linux configuration on the end user’s machine. Different distros use different configuration file locations and settings. Unless you’re writing a system configuration utility for a particular distro, try and avoid distro-specific assumptions. Also never force users to run as “root” unless your application’s sole purpose is to modify system specific settings.&lt;/p&gt; &lt;h2&gt;Do NOT modify or attempt to modify system files&lt;/h2&gt; &lt;p&gt;Apart from being bad programming etiquette, &lt;/p&gt; &lt;ol&gt;&lt;li&gt;You cannot assume that a certain system file exists on the end user’s machine (because of distribution-specific differences).&lt;/li&gt;&lt;li&gt;You simply cannot modify system files as a “normal” user and you cannot expect a normal productivity app to be run as “root.”&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;In most cases, you will find you hardly have any good reason to touch system specific files.&lt;/p&gt; &lt;h2&gt;Be consistent visually&lt;/h2&gt; &lt;p&gt;GUI programmers, especially GTK and QT programmers, need to understand that these libraries are heavily themeable (meaning that the end-user can modify the visual appearance of GUIs in almost any way possible - including fonts, colours and the widget appearance). Therefore, avoid using specific fonts or colours in your GUIs. You don’t need them. Do not force your end users to install any particular font on their system. Leave your application’s visual rendering entirely to the GUI library that you use. Unless you’re writing a word processor you might hardly ever need to directly handle fonts in your application’s code.&lt;/p&gt; &lt;h2&gt;Be prepared to do some research&lt;/h2&gt; &lt;p&gt;Linux does not come with an MSDN-like tool to provide you documentation for every single programming tool or API available out there. It’s simply not practical because Linux is not developed by a single company. In most cases if you’re using third-party libraries, you will be able to find documentation (either downloadable or online) on the official website of that particular library’s maintainer. Also be aware that quite a few libraries come with incomplete documentation or none at all.&lt;/p&gt; &lt;p&gt;You might have to look for sample code or even at header files to learn more about a particular library. Fortunately you might not encounter this situation in the case of most popular third-party libraries, but it’s better to be prepared nevertheless.&lt;/p&gt; &lt;h2&gt;Do not package dependencies&lt;/h2&gt; &lt;p&gt;When you’re creating a “distributable package” do not include dependencies along with your tarball. Just include the source and provide compiling instructions (the more generic, the better). Also mention the required dependencies in your README or INSTALL files and in your website. Since most Linux distributions have their own package management systems (and if you’re application is good enough, it might even be included in the official package repository), you should leave the dependency handling either to the end user who compiles your program manually or to the distribution package maintainer who ships your application as part of his package. Since every Linux distribution has a different way to manage dependencies, do not interfere with it by creating an “installation” routine that tries to be smart and installs other libraries.&lt;/p&gt; &lt;p&gt;Apart from creating versioning problems, it’s simply tedious and cumbersome to include dependencies with the program. Also try and keep the dependencies to a minimum, particularly if your program tends to use exotic third-party libraries.&lt;/p&gt; &lt;p&gt;Even if you’re not releasing your program as Free Software, try and keep the packaging to a minimum and provide instructions to the user on dependencies.&lt;/p&gt; &lt;p&gt;I hope this has been of use to you as a newbie to Linux programming. Happy programming!&lt;/p&gt;&lt;p&gt;From:&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;a href="http://hari.literaryforums.org/2006/12/11/basic-tips-for-linux-programming/"&gt;http://hari.literaryforums.org/2006/12/11/basic-tips-for-linux-programming/&lt;/a&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116610119198685432?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116610119198685432/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116610119198685432' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116610119198685432'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116610119198685432'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/basic-tips-for-linux-programmingzt.html' title='Basic tips for Linux programming(ZT)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116601936340944494</id><published>2006-12-13T22:03:00.000+08:00</published><updated>2006-12-13T22:16:03.826+08:00</updated><title type='text'>About asking questions.</title><content type='html'>Do u know how to use google? If someone ask me a question about computer.&lt;br /&gt;Before we ask  others  questions, have we consider reslove the problem by ourselves?&lt;br /&gt;Don't always keep asking, "勤学好问" is good words, Do u notice that "勤学" comes first?&lt;br /&gt;I seldom refuse to answer if someone ask me (of course,if I know).But now I want to say, Please check &lt;a href="http://www.google.com"&gt;google&lt;/a&gt;/&lt;a href="http://www.baidu.com"&gt;baidu&lt;/a&gt; first.&lt;br /&gt;&lt;br /&gt;PS: I had this idea,because I read some posts from BBS.Most of the questions could be sloved  by using  &lt;a href="http://www.google.com/"&gt;google&lt;/a&gt;/&lt;a href="http://www.baidu.com/"&gt;baidu&lt;/a&gt;! why do we wait for the others?&lt;br /&gt;In the past, If I lock my putty with Ctrl+S, I would restart the putty. Today I search it. Found the solution: Ctrl+Q. Just simple! But I never thought of google before. :-) Easy and Funny. That's the description of our common problems.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116601936340944494?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116601936340944494/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116601936340944494' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116601936340944494'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116601936340944494'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/about-asking-questions.html' title='About asking questions.'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116597282507429010</id><published>2006-12-13T09:07:00.000+08:00</published><updated>2006-12-13T09:20:25.270+08:00</updated><title type='text'>Excellent Words From Guoing Zhou.</title><content type='html'>This morning, Suddenly read sth about Guoping.Zhou. So search sth about him.&lt;br /&gt;This is his blog &lt;a href="http://blog.sina.com.cn/m/zhouguoping"&gt;http://blog.sina.com.cn/m/zhouguoping&lt;/a&gt;&lt;br /&gt;And I collect some excellent words from that blog, (at least I feel they are excellent. :-)&lt;br /&gt;&lt;span style="font-size:85%;"&gt;什么是人文精神呢？我理解的人文精神，简单地说，就是现在人们经常说的“以人为本”。也就是说，要把人放在最重要的位置上，要尊重人的价值。具体到教育 上，就是要把人身上的那些最宝贵的价值通过教育实现出来，一种合格的教育就应该是把学生身上那些人之为人的价值放在最重要的位置上的，应该是能够让学生把 这些价值实现出来的。教育就是育人，就是要把学生培育成真正的人，亦即人的宝贵禀赋都得到发展的人，而不是仅仅能够满足社会上、市场上某种需要的人。简要 地说，人文精神的核心是尊重人之为人的价值。与此相应，教育的根本使命就是要实现人之为人的价值。&lt;br /&gt;&lt;br /&gt;我认为人身是有三样东西是最宝贵的。第一个是生命，生命对于每个人来说都是最宝贵的，没有生命其它一切都谈不上。第二个是头脑，人是有理性能力的，有智力 活动的。第三是灵魂，人是有精神需要、精神追求、精神生活的。所以，与这三样东西相应，为了实现这三样最宝贵的东西的价值，我们就有相应的教育项目。&lt;br /&gt;&lt;br /&gt;教育最重要的任务，第一是培养学生对知识的兴趣，第二是培养学生自主学习的能力。作为大学生，尤其是研究生，你必须有这个清醒的意识，千万不要把注意力放 在学习死的知识上。你要学会自己安排自己的学习，知道自己要朝哪个方向钻研，应该看些什么书。自主学习是一切有成就的人的共同特点，他们都必定是具备这个 能力的。&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;谈到美育，现在许多家长好像很重视孩子的艺术教育，给孩子报各种班，学各种技能，弹钢琴呀，画画呀，但出发点极其功利，无非是为了孩子将来多一条路可走。 这是很糟糕的，违背了美育的本义，结果只能是败坏孩子对艺术的感觉。艺术是最自由、最没有功利性的精神活动，搀杂进功利的考虑，就不是艺术了。&lt;br /&gt;&lt;br /&gt;人类的精神宝库属于每一个人，向每一个人敞开着，你不走进去享受里面的珍宝，就等于你把自己的权利放弃了，那是何等可惜。&lt;br /&gt;&lt;br /&gt;To read more, U could visit his blog.  &lt;/span&gt;Some of his words hit the faults of our education excatly.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116597282507429010?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116597282507429010/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116597282507429010' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116597282507429010'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116597282507429010'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/excellent-words-from-guoing-zhou.html' title='Excellent Words From Guoing Zhou.'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116588952539438237</id><published>2006-12-12T10:11:00.000+08:00</published><updated>2006-12-12T10:12:05.630+08:00</updated><title type='text'>Grid VS Cluster</title><content type='html'>Grid computing is where you have separate administrative domains over a wide area, machines used by different people trying to cooperate. &lt;p&gt;Clustering is where you have a set of machines in one place, and you're trying to get them look like a single machine.  &lt;/p&gt;&lt;p&gt;There are different aspects from the user's standpoint when they run their jobs, from the administration side when you do things like update the software.&lt;/p&gt;The grid refers to a parallel and distributed system with *distributed* resource management , whereas a cluster hascentralised resource management.&lt;br /&gt;Usually, a Grid would be composed of nodes that are themselves clusters.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Think of a cluster as a 'local' concept, and a grid as a 'global' concept&lt;/span&gt;...&lt;br /&gt;&lt;br /&gt;Now I could understand the difference between the grid and cluster to some extent, what about you?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116588952539438237?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116588952539438237/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116588952539438237' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116588952539438237'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116588952539438237'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/grid-vs-cluster.html' title='Grid VS Cluster'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116576131504744253</id><published>2006-12-10T22:18:00.000+08:00</published><updated>2006-12-10T22:35:15.180+08:00</updated><title type='text'>Some idea of the job!</title><content type='html'>My teacher told me something about job today, To tell the truth, I didn't care the job too much.&lt;br /&gt;I found it's  most exciting do my study, especially the Linux. One of my best friends also&lt;br /&gt;asked me about my plan,  I say "No hurry." It's not because I don't want to assign the job, but no company need some students like me. Don't want to program as a student come from Computer Science.&lt;br /&gt;    The truth is: I want to do sth in the field of Linux/Network. So, I join the CCNA class now. and will gain the CCNA paper to prove sth, therefore, I have the ability that class require. "Who would believe? They won't let u act your ability in the interview." My friends warned me. Yes, I can't operate Linux on the spot, and without RHCE paper. They won't believe. So I do the test...... Pay money for proving sth. Isn't funny? That's the reality.&lt;br /&gt;    I want to find a job that will fit the company and me. That's the development for both of us.  If I could find a job that could fill my favourite, Is the salary a problem? Or, Will I be happy with boring work? Money is one thing, Future is another!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116576131504744253?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116576131504744253/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116576131504744253' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116576131504744253'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116576131504744253'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/some-idea-of-job.html' title='Some idea of the job!'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116556639588233172</id><published>2006-12-08T16:00:00.000+08:00</published><updated>2006-12-08T16:26:36.266+08:00</updated><title type='text'>Build Our First Cluster(Simple Ver)</title><content type='html'>1、Prepare our cluster hosts(at least 2 hosts,U can use Vmware).&lt;br /&gt;      Our example is based on 2 hosts because of my poor pc env. to slow for more hosts.&lt;br /&gt;2、Set the cluster hosts, our hosts are linux&lt;br /&gt;      PC1  ip:192.168.0.150 netmask 255.255.255.0&lt;br /&gt;      PC2  ip:192.168.0.160 netmask 255.255.255.0&lt;br /&gt;      #service sshd start (both the hosts)&lt;br /&gt;&lt;span style="color: rgb(255, 0, 0);"&gt;Note: we should set the ssh service for logging into each other without password.&lt;br /&gt;&lt;span style="color: rgb(0, 0, 0);"&gt;      do as follow:&lt;br /&gt;      a.  pc1$ssh 192.168.0.160 if ok then b&lt;br /&gt;      b.  pc1$ssh-keygen rsa      (passphrse u can type : &lt;span style="font-weight: bold;"&gt;yourpassword  &lt;/span&gt;(twice of course))&lt;br /&gt;      c.  pc1$scp -p .ssh/id_rsa.pub pc2:.ssh/authorized_keys&lt;br /&gt;      d.  pc1$ssh-agent $SHELL&lt;br /&gt;      e.  pc1$ssh-add         (input the : "&lt;span style="font-weight: bold;"&gt;yourpassword&lt;/span&gt;" u just input in step b)&lt;br /&gt;      f.   pc1$ssh 192.168.0.160 will need no password if not check with the follow web site&lt;br /&gt;           &lt;a href="http://kimmo.suominen.com/docs/ssh/"&gt;http://kimmo.suominen.com/docs/ssh/&lt;/a&gt;&lt;br /&gt;3、Get the code and make it.&lt;br /&gt;      &lt;a href="http://www.clustermonkey.net/download/Getting_Started_With_Clusters/your-first-cluster-code.tgz"&gt;the taskmaster code&lt;/a&gt; offered by &lt;a href="http://www.clustermonkey.net"&gt;ClusterMonkey&lt;/a&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;      Put the code for task.c and its Makefile in a subdirectory on your system(s) and build it       (just  entering "make" should do it, if gcc and make are installed and correctly set up).&lt;br /&gt;      Put the resulting "task" binary on a consistent path on all the systems. This might be someplace like  /tmp/task.&lt;br /&gt;      Put the taskmaster script in a convenient place -- probably your working subdirectory where you have the task.c source. If you execute the taskmaster script without arguments (be sure to set its executable bits) it will also tell you its argument list. If it complains about not knowing about threads, you will need to update your version of perl to one that includes thread support.&lt;br /&gt;4、Test the cluster&lt;br /&gt;      $vi hostfile    ( had better in the taskmaster directory:-)&lt;br /&gt;      $cat hostfile&lt;br /&gt;        192.168.0.160&lt;br /&gt;        192.168.0.150&lt;br /&gt;      $chmod +x taskmaster&lt;br /&gt;      $./taskmaster 1 10 1&lt;br /&gt;      $./taskmaster 2 10 1     ( comp the time consume by the task)&lt;br /&gt;      $./taskmaster 1 10 10&lt;br /&gt;      $./taskmaster 2 10 10     ( comp the time consume by the task)&lt;br /&gt;Will You find something different. Then We succeed! Congratulations!&lt;br /&gt;&lt;br /&gt;Reference:&lt;br /&gt;ClusterMonkey Web Site &lt;a href="http://www.clustermonkey.net"&gt;http://www.clustermonkey.net&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116556639588233172?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116556639588233172/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116556639588233172' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116556639588233172'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116556639588233172'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/build-our-first-clustersimple-ver.html' title='Build Our First Cluster(Simple Ver)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116554079777126882</id><published>2006-12-08T09:13:00.000+08:00</published><updated>2006-12-08T09:25:32.273+08:00</updated><title type='text'>Linux security expert Kurt Seifried(Part)</title><content type='html'>&lt;p&gt; &lt;strong&gt;Lc: There's so many distributions out there. Can someone still be a "Linux security" expert today without having to be on top of all the nuances in all the many distributions, or is this another layer of complexity they have to know?&lt;/strong&gt; &lt;/p&gt;  &lt;p&gt; &lt;strong&gt;KS:&lt;/strong&gt; Well, the good news is that most Linux systems are pretty similar. You have the same class of vulnerabilities and attacks in most cases: poor file permissions, badly written applications, etc.&lt;/p&gt;  &lt;p&gt;There are, of course, differences (Where the heck is config file X? And why did they allow this service by default?), but once you learn the core fundamentals, how to read man pages, and probably most importantly of all how to use Google, you should be ok.&lt;/p&gt;&lt;p&gt; &lt;strong&gt;Lc: Do you have any favorite Linux security tools?&lt;/strong&gt; &lt;/p&gt;  &lt;p&gt; &lt;strong&gt;KS:&lt;/strong&gt; &lt;a href="http://www.nsa.gov/selinux/"&gt;SELinux&lt;/a&gt; for host security (fine grained control, but a monster to configure!). &lt;a href="http://insecure.org/nmap/"&gt;Nmap&lt;/a&gt; for verifying that my firewall rules are correct. &lt;a href="http://www.gnu.org/software/emacs/"&gt;Emacs&lt;/a&gt; for editing files to configure my system securely. There is literally no one tool that is my favorite, but indeed hundreds.&lt;/p&gt;  &lt;p&gt; &lt;strong&gt;Lc: What's the one most important thing that your average Linux admin can do to increase security?&lt;/strong&gt; &lt;/p&gt;  &lt;p&gt; &lt;strong&gt;KS:&lt;/strong&gt; I guess that would be run the automatic updater your distribution comes with. If nothing else, this will minimize the number of gaping-wide holes in your system. Security is a holistic practice, you are only as strong as your weakest link, an attacker only needs to find one mistake to exploit a system.&lt;/p&gt;  &lt;p&gt; &lt;strong&gt;Lc: So can it be said that newer software -- like in unstable or beta releases -- is generally more secure than old, tested software that's been around for a few years?&lt;/strong&gt; &lt;/p&gt;  &lt;p&gt; &lt;strong&gt;KS:&lt;/strong&gt; Nope. [The new software] probably contains a ton of security holes as well -- just not widely known ones (yet).&lt;/p&gt;  &lt;p&gt;The difference being, an older version has holes for which I can get exploit code from &lt;a href="http://packetstormsecurity.nl/"&gt;Packet Storm&lt;/a&gt; or &lt;a href="http://www.metasploit.com/"&gt;Metasploit&lt;/a&gt;, and break in trivially. The newer holes take a little more time to develop exploit code for.&lt;/p&gt;&lt;p&gt;Original Link:&lt;br /&gt;&lt;a href="http://www.linux.com/article.pl?sid=06/12/01/18023"&gt;http://www.linux.com/article.pl?sid=06/12/01/18023&lt;/a&gt;&lt;br /&gt;&lt;/p&gt;More About the Linux Security Guide by Kurt Seifried&lt;br /&gt;&lt;a href="http://www.seifried.org/lasg/"&gt;http://www.seifried.org/lasg/&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116554079777126882?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116554079777126882/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116554079777126882' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116554079777126882'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116554079777126882'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/linux-security-expert-kurt.html' title='Linux security expert Kurt Seifried(Part)'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116553736435195254</id><published>2006-12-08T08:19:00.000+08:00</published><updated>2006-12-08T08:22:44.446+08:00</updated><title type='text'>旧的Blog</title><content type='html'>&lt;span style="font-size:85%;"&gt;今天打开看看，有些东西还是 值得收藏的，先连接过去吧&lt;br /&gt;http://xfsuper.cublog.cn&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-size:85%;"&gt;&lt;b&gt;&lt;a target="_blank" class="list1" href="http://blog.chinaunix.net/u/4780/showart.php?id=143326"&gt;&lt;span style="font-size: 10pt;color:#02368d;" &gt;&lt;b&gt;RedHat9.0安装qmail--ABC&lt;/b&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;span style="font-size:85%;"&gt;&lt;b&gt;&lt;a target="_blank" class="list1" href="http://blog.chinaunix.net/u/4780/showart.php?id=143054"&gt;&lt;span style="font-size: 10pt;color:#02368d;" &gt;&lt;b&gt;如果爱.请别用眼泪感动爱情(ZT)&lt;/b&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;/b&gt;&lt;a target="_blank" class="list1" href="http://blog.chinaunix.net/u/4780/showart.php?id=143046"&gt;&lt;span style="font-size: 10pt;color:#02368d;" &gt;&lt;b&gt;Fcitx3.x不能输入问题&lt;/b&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-size:85%;"&gt;&lt;b&gt;&lt;a target="_blank" class="list1" href="http://blog.chinaunix.net/u/4780/showart.php?id=143960"&gt;&lt;span style="font-size: 10pt;color:#02368d;" &gt;&lt;b&gt;用 Linux 打造路由器(转载)&lt;/b&gt;&lt;/span&gt;&lt;/a&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116553736435195254?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116553736435195254/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116553736435195254' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116553736435195254'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116553736435195254'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/blog.html' title='旧的Blog'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116550347223791616</id><published>2006-12-07T22:55:00.000+08:00</published><updated>2006-12-08T08:43:13.510+08:00</updated><title type='text'>GFS与RHCS安装记录（转贴自CU）</title><content type='html'>&lt;span id="zoom" class="f14"  style="font-size:85%;"&gt; GFS与RHCS安装记录&lt;br /&gt;硬件环境 ：双 AMD 275HE双核CPU/4G内存/73G scsi&lt;br /&gt;操作系统 ：RedHat AS 4 update 2&lt;br /&gt;内核版本 ：2.6.9-22.ELsmp&lt;br /&gt;&lt;br /&gt;1. 到redhat 网站上下载相应的Cluster Suite/GFS软件。由于没有注册号，无法通过up2date升级，因此会比较麻烦。&lt;br /&gt;到ftp: //ftp.redhat.com/pub/redhat/linux/updates/enterprise/4AS/en/下载 相应的RHCS和 RHGFS的src.rpm文件，在一个目录下，往往有相同软件的几个版本存在。以下安装笔记中所使用的软件是以RHAS4 U2为 准。&lt;br /&gt; 1.1 安装cman-kernel-2.6.9-39.5.src.rpm&lt;br /&gt;             rpm -iv cman-kernel-2.6.9-39.5.src.rpm&lt;br /&gt;             cd /usr/src/redhat/SPECS&lt;br /&gt;             rpmbuild -ba --nodeps cman-kernel.spec   #加--nodeps 的 原因是提示，kernel-hugemem-devel = 2.6.9-22.EL is needed，尝试解决未果，放弃。希望不会出现问题。&lt;br /&gt;             cd /usr/src/redhat/RPMS/x86_64/&lt;br /&gt;             rpm -ivh cman-ker*&lt;br /&gt;&lt;br /&gt; 1.2  安装magma-1.0.1-4.src.rpm&lt;br /&gt;&lt;br /&gt; 1.3  安装dlm-kernel-2.6.9-37.7.src.rpm&lt;br /&gt;&lt;br /&gt; 1.4  安装dlm-1.0.0-5.src.rpm&lt;br /&gt;&lt;br /&gt;  1.5  安装ccs-1.0.2-0.src.rpm&lt;br /&gt;&lt;br /&gt;  1.6  安装gulm-1.0.4-0.src.rpm&lt;br /&gt;&lt;br /&gt;  1.7  安装magma-plugins-1.0.2-0.src.rpm&lt;br /&gt;&lt;br /&gt;   1.8  安装cman-1.0.11-0.src.rpm&lt;br /&gt;&lt;br /&gt;   1.9  安装fence-1.32.10-0.src.rpm&lt;br /&gt;&lt;br /&gt;   1.10  安装iddev-2.0.0-3.src.rpm&lt;br /&gt;&lt;br /&gt;   1.11  安装perl-Net-Telnet-3.03-1.2.el4.rf.src.rpm&lt;br /&gt;&lt;br /&gt;   1.13  安装piranha-0.8.1-1.src.rpm&lt;br /&gt;&lt;br /&gt;   1.14  安装rgmanager-1.9.38-0.src.rpm&lt;br /&gt;&lt;br /&gt;   1.15  安装system-config-cluster-1.0.16-1.0.src.rpm&lt;br /&gt;&lt;br /&gt;   1.16  安装GFS-kernel-2.6.9-42.1.src.rpm&lt;br /&gt;&lt;br /&gt;   1.17  安装GFS-6.1.2-0.src.rpm&lt;br /&gt;&lt;br /&gt;   1.18  安装gnbd-kernel-2.6.9-9.12.src.rpm&lt;br /&gt;&lt;br /&gt;   1.19  安装gnbd-1.0.1-1.src.rpm&lt;br /&gt;&lt;br /&gt;   1.20  安装lvm2-cluster-2.01.14-1.0.RHEL4.src.rpm&lt;br /&gt;&lt;br /&gt;   1.21  安装rgmanager-1.9.38-0.src.rpm&lt;br /&gt;&lt;br /&gt;   1.22  安装ipvsadm-1.24-7.src.rpm&lt;br /&gt;             rpm -iv ipvsadm-1.24-7.src.rpm&lt;br /&gt;             cd /usr/src/redhat/SPECS&lt;br /&gt;             rpmbuild -ba ipvsadm.spec&lt;br /&gt;             cd /usr/src/redhat/RPMS/x86_64/&lt;br /&gt;             rpm -ivh ipvsadm-*&lt;br /&gt;安装完毕&lt;br /&gt;&lt;br /&gt;2. 完成GFS server的配置（该文章参考suran007 的GFS6.1 ON RHAS4 U2安装文档）&lt;br /&gt;&lt;br /&gt; 2.1 确保相关设备的主机名和IP地址的对应关系都在/etc/hosts中&lt;br /&gt; 例：&lt;br /&gt; 10.1.5.161    host1&lt;br /&gt; 10.1.5.162    host2&lt;br /&gt; 10.1.5.163    host3      #host3作为gnbd的server&lt;br /&gt;&lt;br /&gt;  2.2 在host3上配置GFS通过gnbd进行export&lt;br /&gt;  启动gnbd_serv进程&lt;br /&gt;  root@host3 # /sbin/gnbd_serv –v –n&lt;br /&gt;  导出设备&lt;br /&gt;  root@host3# gnbd_export -v -e gfs -d /dev/sdb1 –c&lt;br /&gt;  查看export状态信息&lt;br /&gt;  root@host3# gnbd_export -v -l&lt;br /&gt;完成GFS server，为了使实验更顺利，建议将防火墙停掉 service iptables stop&lt;br /&gt;&lt;br /&gt;3. 使用system-config-cluster工具对node1和node2进行配置&lt;br /&gt;  在node1的命令格式下输入：system-config-cluster,进入配置界面&lt;br /&gt;  3.1然后在系统中，第一次配置会提示是否要创建配置文件/etc/cluster/cluster.conf，点击"create "&lt;br /&gt;  3.2然后选择 锁机制，选择dlm。&lt;br /&gt;  3.3添加cluster nodes。&lt;br /&gt;       点击“add a cluster node",添加node1,quorum votes填1。&lt;br /&gt;       点击“add a cluster node",添加node2,quorum votes填1。&lt;br /&gt;  3.4 添加fence设备&lt;br /&gt;       在”fence device"中，选择“add a fence device"，这里添加的是"manual Fencing"，名字任意，这里写”web"。&lt;br /&gt;       在"cluster Nodes-&gt;node1和node2”,中“manange fencing for this node"，选择”add a fence level"。&lt;br /&gt;  3.5 创建"failover domains"&lt;br /&gt;       在“manager resource-&gt;failover domains"中，”create a failover domain"，名称为web&lt;br /&gt;       点击“manager resource-&gt;failover domains-&gt;web", "edit failover domain propertis"，在"available cluster node2"中，将node1和 node2都添加进取。&lt;br /&gt;  3.6 创建”resource"&lt;br /&gt;       "create a resource"，选择IP address,地址为“10.1.5.169",后边的monitor link要选中。&lt;br /&gt;       "create a resource"，选择script，name 为"httpd",script为"/etc/init.d/httpd"。&lt;br /&gt;先保存，然后将cluster.conf传到node2相同位置一份。下边要配置gfs的一些resource，但是前提是cluster mananger的进程需要启动才能进行设置。&lt;br /&gt;4. 配置GFS参数&lt;br /&gt;启动cluster进程顺序：&lt;br /&gt;    service ccsd start&lt;br /&gt;    service cman start&lt;br /&gt;    service fenced start&lt;br /&gt;    service clvmd start&lt;br /&gt;    service gfs start&lt;br /&gt;    service rgmanager start&lt;br /&gt;然后在node1上，首先&lt;br /&gt;modprobe gnbd&lt;br /&gt;将gfs通过gnbd倒入：gnbd_import -v -i node3&lt;br /&gt;检查加载状态：gnbd_import  -v  -l&lt;br /&gt;modeprobe  gfs&lt;br /&gt;gfs_mkfs -p lock_dlm -t cluster1:gfs -j 2 /dev/gnbd/gfs 创建文件系统&lt;br /&gt;在node2上重复此操作，只是不用再重做创建文件系统的操作&lt;br /&gt;再打开system-config-cluster，&lt;br /&gt;    接着创建"resource"&lt;br /&gt;    "create a resource"，选择GFS,name "web_content",mount point:"/gfs",device:"dev/gnbd/gfs"。&lt;br /&gt;&lt;br /&gt;5.配置service&lt;br /&gt; 由于是为了实现httpd的集群，因此需要对/etc/httpd/conf/httpd.conf一些内容进行修改，包括&lt;br /&gt; 设置监听地址为floating ip：Listen 10.1.5.169:80&lt;br /&gt; 修改DocumentRoot 为"/gfs/"&lt;br /&gt;        &lt;directory&gt;&lt;br /&gt;  同时chkconfig httpd off,将httpd 的自启动关闭&lt;br /&gt;  "service","create a service", name设为httpd。&lt;br /&gt;  failover domain为 web。&lt;br /&gt;  点”add a shared resource to this service" ,首先把ip address加入。&lt;br /&gt;  选择”10.1.5.169  ip address share",然后再“attach a shared resource to the selecetion",分别添加刚才设的script和gfs的resource。&lt;br /&gt; 保存配置,并复制该文件到node2。&lt;br /&gt;&lt;br /&gt;  分别重新启动进程：&lt;br /&gt;  service rgmanager stop&lt;br /&gt;  service gfs stop&lt;br /&gt;  service clvmd stop&lt;br /&gt;  service fenced stop&lt;br /&gt;  service cman stop&lt;br /&gt;  service ccsd stop&lt;br /&gt;&lt;br /&gt;  service ccsd start&lt;br /&gt;  service cman start&lt;br /&gt;  service fenced start&lt;br /&gt;  service clvmd start&lt;br /&gt;  service gfs start&lt;br /&gt;  service rgmanager start&lt;br /&gt;    &lt;br /&gt;6. 开启service&lt;br /&gt;   打开，system-config-cluster，如果刚才的管理进程都正常的话，将会有cluster management的tab。&lt;br /&gt;    在service 中，点击httpd 按"enable"启动。&lt;br /&gt;&lt;br /&gt;debug技巧：如果无法正常启动，尝试着去掉一些resource，然后再看是否正常启动，来定位故障。&lt;br /&gt;&lt;/directory&gt;&lt;/span&gt;&lt;span id="zoom" class="f14"  style="font-size:85%;"&gt; 如果要学习和试验，建议按如下顺序进行前期的阅读：&lt;br /&gt;Data sharing with a GFS storage cluster :&lt;br /&gt;http://www.redhat.com/magazine/006apr05/features/gfs/  看一遍&lt;br /&gt;Red Hat Cluster Suite Configuring and Managing a Cluster&lt;br /&gt;http://www.redhat.com/docs/manuals/csgfs/pdf/rh-cs-en-4.pdf 看2遍&lt;br /&gt;Red Hat GFS 6.1 Administrator's Guide http://www.redhat.com/docs/manuals/csgfs/pdf/rh-gfs-en-6_1.pdf 看1遍&lt;br /&gt;&lt;br /&gt;GFS6.1 ON RHAS4 U2安装文档 http://bbs.chinaunix.net/viewthread.php?tid=746833&amp;amp;extra=page%3D1 照着做一遍&lt;br /&gt;&lt;br /&gt;现在能有一大概的认识&lt;br /&gt;看http://unixnotebook.blogspot.com/2005/07/redhat-cluster-4-how-to.html 一遍 做试验。&lt;br /&gt;&lt;br /&gt;呵呵，竟然作者在本站有Blog?&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116550347223791616?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116550347223791616/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116550347223791616' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116550347223791616'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116550347223791616'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/gfsrhcscu.html' title='GFS与RHCS安装记录（转贴自CU）'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-37910476.post-116550306426039939</id><published>2006-12-07T22:49:00.000+08:00</published><updated>2006-12-08T08:25:24.176+08:00</updated><title type='text'>庆祝CUPLinux社区开业！</title><content type='html'>&lt;div style="text-align: left;"&gt;&lt;span style="font-size:85%;"&gt;以前找了很多的Blog，都不怎么样，不知道这个能怎么样，毕竟新开业。庆祝一下，如果好就把那些搬家喽。希望能给朋友们带来一些你想要的东西。&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/37910476-116550306426039939?l=cuplinux.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://cuplinux.blogspot.com/feeds/116550306426039939/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=37910476&amp;postID=116550306426039939' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116550306426039939'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/37910476/posts/default/116550306426039939'/><link rel='alternate' type='text/html' href='http://cuplinux.blogspot.com/2006/12/cuplinux.html' title='庆祝CUPLinux社区开业！'/><author><name>晓风</name><uri>http://www.blogger.com/profile/03292113057309764998</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
