星期日, 十月 08, 2006

[攻略] 用 squidnt 打造超强 windows 代理服务器

[webnote]
[software] 
 

February 13, 2006

[攻略] 用 squidnt 打造超强 windows 代理服务器

http://windtear.net/archives/2006/02/13/000917.html  [攻略] 用 squidnt 打造超强 windows 代理服务器  关于 squid 这里就不多写了 直接进入主题  --1-- 下载 http://www.acmeconsulting.it/pagine/opensource/download/squid.htm http://www.acmeconsulting.it/pagine/opensource/download/squid-2.5.STABLE12-NT-bin.zip  --2-- 解压在c:根目录 c:\squid  --3-- 配置 c:\squid\etc\mime.conf (默认有 mime.conf.default 拷贝一份或者改名都行) c:\squid\etc\squid.conf(下面给个简单代理服务器样例 如果要公开 想配多灵活都可以)  squid.conf 样例: 可能你需要修改的地方: 代理端口3128 内存大小64 cache目录 允许网段 国外代理(如果没有可以把那4+5行删掉) offline_mode off http_port 3128 icp_port 0 snmp_port 0 htcp_port 0  acl QUERY urlpath_regex cgi-bin \? no_cache deny QUERY  cache_mem 64 MB maximum_object_size 8192 KB maximum_object_size_in_memory 8192 KB cache_replacement_policy heap LFUDA memory_replacement_policy heap LFUDA  cache_dir ufs c:/squid/var/cache 100 4 4 cache_access_log none #cache_access_log c:/squid/var/logs/access.log cache_log c:/squid/var/logs/cache.log cache_store_log none  emulate_httpd_log on dns_nameservers 202.106.0.20  refresh_pattern .		0	5%	604800 half_closed_clients off  acl myhome src 192.168.0.0/16 acl manager proto cache_object acl localhost src 127.0.0.1/255.255.255.255 acl all src 0/0  acl PURGE method PURGE http_access allow PURGE localhost http_access deny PURGE   http_access allow manager localhost http_access deny manager  http_access allow localhost http_access allow myhome  http_access deny all  acl cantdirect dstdomain .sourceforge.net acl cantdirect dstdomain .freebsd.org acl cantdirect dstdomain .wikipedia.org acl cantdirect dstdomain .wikimedia.org  cache_peer 国外代理 parent 端口 0 no-query no-digest no-netdb-exchange cache_peer_access 国外代理 allow cantdirect cache_peer_access 国外代理 deny all always_direct deny cantdirect always_direct allow !cantdirect  icp_access deny all shutdown_lifetime 5 seconds  ignore_unknown_nameservers on  cache_mgr 你的email visible_hostname squidnt.ipcn.org  httpd_accel_host virtual httpd_accel_port 80 httpd_accel_single_host off httpd_accel_with_proxy on httpd_accel_uses_host_header on logfile_rotate 0  forwarded_for off log_icp_queries off  client_persistent_connections on server_persistent_connections on client_db off  # reload_into_ims off negative_ttl 300 seconds  --4-- 启动 新建 c:\squid\var\cache 目录 (根据配置指向建) 开始 - 运行 - "c:\squid\sbin\squid -z" 初始化 cache 目录结构 开始 - 运行 - "c:\squid\sbin\squid -i" 安装squidnt服务  ok 可以用了 家里其他机器或者本机浏览器设置代理即可 以后系统启动会自动 (如果不重起可以 开始 - 运行 - "net start squidnt" 启动)  其他需求可以慢慢看帮助 或者到水木新软版发文讨论 可以增积分 

星期六, 十月 07, 2006

花费百万元留学8年 硕士回国后月薪仅千余元

[webnote]
 
 
花费百万元留学8年 硕士回国后月薪仅千余元
赵腾 | 大千世界 | 出处:文艺副刊| 2006年10月07日 14:09 | 阅读 33 次
        

   核心提示:父母花费多达百万元送重庆一男子出国留学,取得2个硕士学位后回国。结果在国内几经波折,最后仅能当一名广告业务员,月薪1500元。

留学8年挣了2个硕士学位,可现在月均收入仅1500元;优秀的中学生被送到德国留学8年,连大学也没有考上……重庆协和心理顾问事务所所长谭刚强介绍,近日,留学生、"海归"进行心理咨询的案例增多,留学生问题亟待关注。

"海归"业务员月薪千元

"这辈子能把留学投入的钱,赚回来就满足了。"刘里(化名)向心理咨询师诉苦,"海归"的他还要用父母的钱才能维持应酬和生活。

刘里今年45岁。1980年大学毕业后,先后在一所中学和一个公司工作,但刘里不满意。1990年,刘里到澳大利亚南部的一所大学,攻读经济学硕士。回国后,刘里在上海、深圳待了2年,发现自己的知识不实用;刘里再一次奔赴澳大利亚,在墨尔本一所大学攻读MBA,2000年回国。8年留学生涯,刘里花掉了家里上百万元的积蓄。

回重庆后,他开了一家管理咨询公司。2年后,公司以亏了30余万元破产告终。现在,刘里不得不在一家广告公司当业务员,月均收入仅1500元。

优生留学8年大学也没考上

和刘里不同,26岁的小李(化名)初中一毕业,就被望子成龙的父母,安排到德国留学,不料到德国8年时间,原本在重庆属于优生的小李,在德国连大学也没有考上。"参加各种补习学校、补习文化语言,把时间就折腾完了。"

2004年,小李回重庆过春节后,准备又回德国"高考",不料德国大使馆却以"8年时间没考上大学,有移民倾向"为由,拒绝为其办理签证。恼怒的小李当即把母亲暴打了一顿,并将母亲赶出了家门,理由是"母亲没有和大使馆疏通好关系"。

小李的母亲哭诉,8年时间,小李不但花费家里100万元钱,而且连个文凭也没有。现在,小李的同龄人都已经大学毕业,找到比较满意的工作了,要不是当初盲目跟风送孩子留学,也许小李会更好些。

专家建议

留学应制订学有所成的计划

谭刚强表示,现在不少留学生属于跟风,容易出现"社会综合适应征"。不能适应国内环境,找不到位置。

谭刚强建议,留学一定要慎重,一定要制订学有所成的计划,要与留学地的文化、经济、社会背景结合起来。此外,回国后找准自己的定位,坚持从国内的实情出发办事。

Emacs是一种信仰!世界最强编辑器介绍

[webnote]
[software] 
 

Emacs是一种信仰!世界最强编辑器介绍


编者按:这个世界最强是个怎么样的强法呢?一说:Emacs是一种"信仰"。另说:世界上的程序员分三种,一种使用Emacs,一种使用vim,剩余的是其它。(完全无视其他编辑器的存在……)

  来看看这个被人奉为信仰、可以煮咖啡的编辑器是个什么样子。

一、Emacs的历史

  Emacs程序的最初版本是由RichardStallman在1975年写成(年龄比很多读者都大吧 :) )。之后其衍生版本众多。目前使用得最多的两个版本是RichardStallman在1984年开发的一个版本――GNUEmacs和1991年由JamieZawinski写成的 XEmacs。

  看看他的简称你会头晕。

  E. M. A. C. S.

Emacs Makes A Computer Slow
Escape Meta Alt Control Shift
Emacs Makers Are Crazy Sickos
Emacs Makes All Computing Simple
Emacs Makefiles Annihilate C-Shells
Emacs Manuals Always Cause Senility
Emacs May Allow Customized Screwups
Emacs Manuals Are Cryptic and Surreal
Eventually Munches All Computer Storage
Eight Megabytes And Constantly Swapping
Elsewhere Maybe All Commands are Simple
Excellent Manuals Are Clearly Suppressed
Emacs May Alienate Clients and Supporters
Except by Middle Aged Computer Scientists
Extended Macros Are Considered Superfluous
Every Mode Accelerates Creation of Software
Each Manual's Audience is Completely Stupefied
Exceptionally Mediocre Algorithm for Computer Scientists
Easily Maintained with the Assistance of Chemical Solutions
Eradication of Memory Accomplished with Complete Simplicity
  (PConline注:请原谅没有翻译。专有名词的翻译比较困难,而且很多东西翻译后就完全失去其原有的味道了。)

二、Emacs 能做什么

  很多人不理解为什么 Emacs 的用户那么多,他们是如此的热爱 Emacs,甚至有的人把它当成了"信仰"。虽然笔者没有这个信仰,但是它的确很好,很喜欢用它编辑各种文件,现在来看看 Emacs 能做什么。 

  据笔者所知,Emacs 的能力包括:

  1.编辑文本

  Emacs 编辑文本的能力是非常强的。它的其它很多功能都是依赖于强大的编辑能力。Emacs 是人性化的设计,它非常可靠,不会莫名其妙弄坏你的文件,用它编辑重要的文本信心有保障。

  可能你开头觉得它的键绑定用起来非常不顺手。它有很多长长的 "快捷键",比如按下Ctrl-h再按Ctrl-i…… 比起 VIM 的一个键的快捷键的确慢很多。但是 Emacs 的优势不在于击键的频率,它的目标是用一个键,甚至不按键盘,就完成复杂而智能的操作。面对 Emacs,你感觉自己像是一个魔法师,轻轻一挥魔棒,任务就完成了。

  Emacs 的文本处理能力极强,不管你要处理自然语言还是机器语言。不管是中文还是英语,不管是小说、HTML,还是 C 程序、Java 程序,都可以按 M-e 向前移动一句话(C和Java语句),按 M-k 删除一句话,按 M -} 移动一段话,按 M-p (笔者自己设定的按键) 删除一段话。因为 Emacs 知道,什么样算是一句话 (sentence-end),什么算是一段话(paragraph-start)。而且它知道在不同的文档里,句子和段落有什么区别。 

  笔者只要按 M-q 就可以把一段话排的规规矩矩。只要按一个键就可以把一个数字列表重新排序。在 HTML 文档里只要按 C-c backspace 就可以把一组tag删掉,按C -c C-c i 就可以插入一个图片,按 C-c C-v 就可以马上把这个文档送到一个 Mozilla 窗口去预览……在 LaTeX 文档里按  C-c C-r RET 就可以把文档里选定的区域送给 LaTeX 处理,马上看到效果。

  现在你是不是感觉自己更像魔法师了?继续!


图1 Windows下的emacs

  Emacs 有非常友好而强大的人机界面。在搜索替换字符串时,你就能明显感觉到这个优点。它在输入regexp(正则表达式)搜索的时候还能进行  incremental search,而且对部分匹配的字串都有非常漂亮的加量。在替换的时候,它独有 recursive edit,可以打断替换过程,编辑附近的需要纠正的文字,然后继续替换。这个功能对很多人都是非常重要的,因为,在替换过程中,被替换的文字附近的文字很可能会因为它被替换而需要修改。看看这个抓图,就是 isearch 输入一个正则表达式的情况。
 


图2 用isearch输入正则表达式

Emacs 能识别多种自然语言符号,它能知道哪些符号是括号,那些是标点。看看这个抓图里,Emacs 显示了中文书名号的匹配情况。 《正确》,和《错误> 。


图6 书名号的匹配(一)(+上图可点击放大)

  Emacs 的键是可以任意绑定的。甚至可以使用 Windows 键盘上的 Win 和 Menu 键来控制。笔者的"Win + 鼠标中键"可以弹出一个buffer 里所有引用到的文件和URL的列表,当点击它们就可以编辑那个文件或者在 Mozilla 中打开连接,如图8。



图8 笔者的"Win + 鼠标中键"功能(+上图可点击放大)

  你能想到的和你不能想到的编辑功能,Emacs 都能完成。说到这里你可能又会说:"这个功能,vi也有","这个功能, UltraEdit 都有"……对,这些能力可能很多其它程序也有。对,但是让一个 Emacs 拥有这些功能比起其它程序的确要费少得多的力气。很多热心的爱好者看到其它编辑器有一个很酷的功能,他就可以想办法把它加入到 Emacs 里面。Emacs 可以被不断的扩充。其实,你平常用到的几乎所有功能都是扩展的功能。 

  建立一个微小的基本功能的集合,然后把所有复杂功能作为这些基本功能的组合。这体现了一种程序设计的哲学。不同于 Windows, 也不同于 UNIX,它更好的协调了程序的灵活性和同一性。 

  Emacs 编辑文本方面的扩展简直没法计数。folding、 narrow、 outline……这些给人带来了很大的方便,已经被许许多多的人采用。 

2.编辑程序

  程序也是一种特殊的文本文件。因为 Emacs 特别适合编辑程序,所以特别在这里提出。Emacs 可以方便的编辑任何类型的计算机语言程序代码,而且为它们提供语法加亮,自动缩进。你可以对程序的语句进行操作。比如向下移动一个 list,删除整个 C 函数…… 你可以用一个键就把许多行注释重新排的整整齐齐。

  一些扩展可以让你方便的浏览代码,而且它们可以识别代码的语义。列出函数名、参数和类型、变量名、类、宏、方法、defun、include 的文件。当你编辑程序时,Emacs 可以帮你补全函数名,参数等等。你可以在代码中间自由的穿梭。

  你可以使用 Ediff 来比较两个或者三个文件,Emacs 可以把不同的地方高亮,而且修改过的地方有特别明显的颜色不同。笔者经常用这个功能很快找到修改过的代码里新出现的错误的位置,如图9。



图9 Emacs上的高亮功能(+上图可点击放大)

  你用一个指头就可以让 Emacs 调用编译器编译程序,列出错误列表,启动调试器,在另一个窗口显示当前执行源代码的位置。




更多请见http://www.pconline.com.cn/pcedu/soft/gj/photo/0609/865628.html

星期五, 十月 06, 2006

《三国演义》中最精辟的十句话赏析

[webnote]
 
 
《三国演义》中最精辟的十句话赏析
1、"人中吕布,马中赤兔"
一共八个字却称赞了两件事物,足可见微言之大义。而且朗朗上口,妇孺皆宜。后来关羽虽然也得到了赤兔,但也没听别人这么说过,估计作者肯定是吕温侯的FANS,否则也不会这么肉麻。
2、"马氏五常,白眉最良"
老马家五个儿子,为大家所熟知的只有马良、马谡哥俩。马良的确才华出众,为刘备坐稳西川出了不少力,可惜死得较早。马谡虽说智商较高,也一度取得诸葛亮的赏识,只可惜后来一步棋走错,丢了街亭。因此当人读起这一句话时,一则叹马良死得过早,二则叹马谡聪明一世,糊涂一时。
3、"鞠躬尽瘁,死而后已"
有人说《后出师表》不是诸葛亮写的,且不论是谁写的,这里的"鞠躬尽瘁,死而后已"却是诸葛亮真实的写照,也是最能表现诸葛亮后期六出祁山无力回天时的心情,因而也成为现代人常挂在嘴边的一个词。
4、"既生瑜,何生亮"
在《三国演义》里,周瑜是心胸狭窄、永不服输的代名词,也只有当他病入膏肓不久于人世时,才会由口及心地发出这样的感慨。只不过这句话过于自卑,长了诸葛志气,灭了自己威风。使得二人的形象在人们心中格式化了。
5、"子龙一身都是胆也!"
这是赵云迷们最津津乐道的评语,原因是在《三国演义》里赵云并不是作者重点描写的对象,但由于他每回出场都是英姿飒爽,攻无不克,能得到主子这么一句肯定,当然是高兴得找不到北了。不过也可以看出刘备没有知人之能:赵云跟了自己这么多年,到这时才知道他的胆识,平时只给他一些压粮运草、打扫战场、保护家属的杂活,真是埋没英雄。
6、"伏龙、凤雏二人得一,可安天下"
司马徽一向看好诸葛亮和庞统,曾经把诸葛亮比成姜尚、张良,所以这话从他嘴里说出来一点也不奇怪。二人倒也有些经天纬地的本事,因此这么说也不过分。奇怪的是刘备二人皆得,反倒不能安天下了,不能不引人思考。
7、"内事不决问张昭,外事不决问周瑜"
孙策当政时常常霸气有余而策略不足,想不到他倒还有些识人之能,生前信任太史慈回城招降众人,临死时还给孙权留下了这样的忠告,深刻看出了两人的处事风格。事实也验证了他的准确性,张昭主外事时主张投降曹操;周瑜主内事时把孙权的妹子糊里糊涂地嫁给了刘备。而二人各行其是时却做得近乎完美。
8、"生子当如孙仲谋"
小时候看《三国》,很不明白这句话的含义,到底是在夸孙权还是在骂孙权。稍大了一点后才知道,曹操其实和孙权他爹孙坚是一辈的,这么说没什么不可以。另外曹操的主要意思是夸孙权能守住父兄基业,跟袁绍和刘表的那几个败家子不同。怪不得辛弃疾很是欣赏孙权,并在自己的词里引用了这句话。
9、"天下英雄,惟使君与操耳!"
个人认为,在曹操说过的所有的话里面,这句话是最精辟的。难怪刘备会吓掉勺子,连苍天也打了个冷战,以为泄露了天机。其实曹操也就是这么一说,试探一下而已,后来又被刘备一糊弄,否定了自己有生以来说过的最正确的一句话。
10、"治世之能臣,乱世之奸雄"
这一句话,不仅给曹操的一生定了性,也道出了曹操的能力,在治世是治国安邦之臣,在乱世则是独霸一方的军事首领。而曹操听到这话面露喜色的原因还有一点,就是没有说他能成为皇帝,而他也不愿登基称帝,在史书上成了王莽、董卓一类的人。


Trackback: http://tb.donews.net/TrackBack.aspx?PostId=1054192

Top Ten Geek Wallets

[webnote]
 
 

Style - October 03 2006

Top Ten Geek Wallets
 

Geek Wallet

Wallets are a pretty good element of style to get geeky with: you can hide them most of the time, only bringing them out for show when you need to buy something or show your geek friends. A lot of guys see full-grain leather as an indicator of a fine wallet, but it takes a particular sensibility to appreciate stainless steel or dot matrix paper. Some guys go for a feature like a see-through license compartment, but it takes a geek to seek out a wallet built with a nano compartment. But one thing we can all agree upon, that George Costanza wallet just doesn't cut it in the tech environment these days. In honor of geeks who accessorize, we present you with the Top Ten Geek Wallets.

 

dot matrix wallet
Dot Matrix Wallet: Anyone who feels sentimental about Dot Matrix Paper, even if expressed through irony, is operating on a healthy dose of geek sensibility. Made from Tyvek, this Dot Matrix Wallet looks like something only a geek could love and is made from a material that no one but a geek could truly understand.

 

rfid passport case

RFID-Blocking Wallet and Passport Cases: A geek's fascination with technology, its power to monitor the individual, and the methods the individual might use to evade that monitoring is often only a slight distance from paranoia. But that counts, too. RFID tags, like those currently found in passports and a variety of bank cards, can be read through most wallets with a basic receiver. Of course, this RFID Blocking Wallet is made to keep the man out of your business.

 

illuminating wallet

Walit Illuminating Wallet: The intention behind the Illuminating Wallet is totally sensible: when you open your wallet in low lighting, the wallet lights up to give you an idea of what bills you are handling. But the kind of glee that comes from having this sort of tricked out billfold can't be measured in sensible terms. Powered by three replaceable watch batteries, the Walit's electroluminescent strip makes it all happen.

 

 

walluminate

DIY Illuminated Wallet: Walluminate: For a die-hard tech geek, the only thing that might improve upon the Illuminating Wallet above is a guide for building it yourself. Make:Blog comes to the rescue, offering the how-to in a trully geek-friendly form: the podcast. Dubbed the Walluminate, this wallet utilizes LEDs from an old cell phone to light the interior bill pocket.

 

 

crossword wallet
Crossword Wallet: Did the concept of geek exist before the computer age? No? Well what did they call your dorky grandfather who spent all his free time with his head in a crossword puzzle. Niche-brilliant, socially awkward, and infatuated with intellectual games...sounds like a geek from here. This Crossword Wallet celebrates the old-school geek.

 

 

stainless steel wallet
Stainless Steel Wallet: Why would you want a stainless steel wallet? Sounds a little uncomfortable right? Not when it's made from a cloth variation on stainless steel that is otherwise only used in industrial applications. What kind of person do you have to be carry this kind of thing around, doubtlessly anticipating the chance to show it off? I think you know where we're going with this...

 

 

nano wallet

C.E.O. Billfold Wallet (AKA: nano Wallet): It probably didn't take long after the arrival of the first nano for someone to realize that it was thin enough for him to slip into his wallet. Thereafter, it likely wasn't long before some designer set to creating a wallet built specifically for an iPod. This full-leather C.E.O. Billfold Wallet looks great as a wallet on its own, featuring standard credit card pockets and clear ID pocket alongside a nano pocket with a plastic screen cover, a click wheel protector, and ready access to both the hold button and the earphone jack.

 

 

mophie knox

Mophie Knox Aluminum nano Wallet: By the time the 2nd generation nano rolled around, a few people who had used the nano Wallet above had probably realized that smashing the player in that wallet was a real possibility. Enter the Mophie Knox, made with aircraft grade aluminum, designed to hold your iPod on one side and your cash and cards on the other. The wallet's play-through design allows you to plug in while the Knox is closed.

 

 

the rawhide

Tyvek Wallet: Rawhide Tri-Fold: If the Dot Matrix Wallet mentioned above is a little too clever for you, this standard Rawhide Tri-Fold should do the trick. The basic wallet is cool and understated, but still features the miracle of Tyvek, a material that, as mentioned above, only a science loving geek can trully understand. The perfect mix of geek and chic--is this not Kevin Rose's wallet?

 

 

the sammy

The Sammy Titanium Wallet: Featuring sheet titanium, a military specification extruded aluminum piano hinge and rivets, and hand finished in a state-of-the-art aerospace facility, this piece, known simply as The Sammy, is enough to geek out on as an industrial gadget. Of course, you also get to carry it around in your pocket as a functional wallet that includes a riveted money clip and and a slot for credit cards and business cards. This one is only for the geeks that can afford it: $320 (Brushed), $340 (Polished).

By: robert o'neill

google站内搜索

Google