2009年5月5日星期二

Ubuntu 9.04 on Thinkpad X61... ...Enjoy it <3>

1. Ubuntu Tweak
Ubuntu Tweak 可以优化系统设置。你可以安装软件,优化桌面设置,配置启动程序,改变系统文件关联等。

要安装 Ubuntu Tweak,首先修改源文件。
sudo gedit /etc/apt/sources.list

添加下列行,保存。
deb http://ppa.launchpad.net/tualatrix/ubuntu jaunty main
deb-src http://ppa.launchpad.net/tualatrix/ubuntu jaunty main

打开终端,更新并安装。
sudo apt-get update
sudo apt-get install ubuntu-tweak
2. Gnome Do

Gnome Do 是允许搜索和快速启动程序的小软件,它如同 Mac 上的 QuickSilver 或是 Windows 上的 Launchy。
sudo apt-get install gnome-do
3. ThinkPad 指点杆中间滚动失效,Howto?
在/etc/hal/fdi/policy下创建mouse-wheel.fdi文件,
sudo gedit /etc/hal/fdi/policy/mouse-wheel.fdi

内容请点击右边--->Click<---

4. PDF中文遭遇乱码,Howto?
sudo apt-get install poppler-data

5. 公司的邮件需要加入网域才能收取,Howto?
sudo apt-get install likewise-open

安装之后会提醒输入域名,完成后确认,再打开Thundebird,是不是可以连上邮件服务器收取公司邮件了呢... :)

6. 磁盘管理软件
sudo apt-get install gparted

2009年5月3日星期日

Ubuntu 9.04 on Thinkpad X61... ...Enjoy it <2>

About Conky
自用Thinkpad X61(7673IFC),1024x768的屏,所以不能加太多显示内容,只配置了-->日期/时间-天气(当天)-System(版本号/在线 时间/电池电量/温度/CPU&RAM信息...)-File System(屏小,就留了个Root盘的空间信息)-Network(无线网卡/有线网卡)<-- 步骤: 1 安装Conky 代码: sudo apt-get install conky 2 download我的配置文件conkyrc_X61改名为.conkyrc放到 主目录(/home/用户名/)下,别忘了前面的.号,是隐藏文件 3 安装配置中用到的字体,Radio Space和Weather fonts,怎么装字体?? :em06
给点提示:
代码:
sudo mkdir /usr/share/fonts/ttf
sudo cp /存放ttf字体的路径/* /usr/share/fonts/ttf
cd /usr/share/fonts/ttf
sudo chmod 744 *
sudo mkfontscale
sudo mkfontdir
sudo fc-cache -f -v
exit

4 安装天气插件 在你的主目录(/home/用户名/)下建立一个文件夹conkyrc,然后把conkyForecast.py拷贝进去,记得要执行
代码:
chmod +x conkyForecast.py

Tips: 我在上海,故配置里的天气预报就是上海的咯,其他地区配置方法:
打开yahoo的天气网址:http://weather.yahoo.com/
在Enter city or zip code:中输入你的城市(只有一些大城市,小城市可以选择较近的),搜索。然后在地址栏中获取你城市的代码,是CHXX开头的一个8字节串。然后编辑配置文件,
代码:
gedit ~/.conkyrc
将其中的CHXX0116替换掉你所在城市的代码
5 一切完成之后运行看看,终端
代码:
conky

是不是很完美呢? 如果有什么小问题可以修改下下 :)
6 让conky虽系统启动,创建一个文件,起名conky.sh。用gedit打开。粘贴如下内容:
代码:
#!/bin/bash
sleep 20 && conky -c /home/用户名/.conkyrc
在startup app里设置开机启动就可以了
详细见论坛发帖:http://forum.ubuntu.org.cn/viewtopic.php?f=24&t=200513
附件下载:http://forum.ubuntu.org.cn/download/file.php?id=63921
附图:

2009年5月2日星期六

Lenovo ThinkPad 购买指南

Lenovo ThinkPad 购买指南
转自未名空间

看到版上众多新 id 踊跃支持 Lenovo 国货,又正处于 MITBBS 市场化改革的大潮中,我老竟然也一夜之间从有产阶级变成了裤衩男,只好出来挣点衣服钱,大家看了觉得好的尽管给我砸包子,觉得好就多砸点,不好就少砸点 kaka

Abstract

This post introduces several basic concepts on Lenovo ThinkPad purchase, and proposes the best way to buy Thinkpad at the minimum cost. Please note that case may vary by your situation. This post is organized as follows: Section I introduces the basic concepts and current research on ThinkPad purchase, Section II gives a real case study to show how to operate. Section III concludes the post.

Section I Introduction and Current Research

1、Public Coupon Code。可以不时从 fatwallet/dealsea 上找到。

2、Employer Purchase Program (EPP): www.lenovo.com/ibmepp
Contractor Purchase Program (CPP): www.lenovo.com/cpp
这两个 Program 都是 15% off anytime。Warranty 20% off plus tax free (超值),$95可以加到3年

EPP 需要IBM员工编号和Last Name,不是每个人都有,但是版上有个著名的"992299"的 CPP Code,效果是一样的。
EPP/CPP 一般不能跟public coupon 一起用,但前几天有一个"USEHOLIDAY" 10% coupon 买 X 系列可以和CPP叠加(super sweet)。

3、FatWallet 的 Fatcash:在 www.fatwallet.com 注册,然后点上面的商家链接过去,在点开的窗口内完成交易,就可以拿FatCash3个月后 Available,可以选check/PayPal支付。最初是 7%,前段时间 3.5%,最近又回到了 6%,不知道 Lenovo在想什么,PC 利润这么薄,还给这么高的回扣。
(补充:刚才楼下有人说 EPP/CPP 不qualify Fatcash,我今年8月还可以,至于新的请自己确认)

4、American Express Tailormade Program,俗称裁缝。以前最高有15%rebate,我前段时间拿过5%,现在没有了,但将来也许又会出现。
必须是 American Express 原发的卡,不能是什么Citi Amex之类。只要是用注册了的卡买的,就自动qualify裁缝店rebate。

5、其它Saving: 属于 Money 版讨论的话题了
比如 HSBC HouseHold 卡,2% anything. Discover卡有段时间是5%之类。

6、Extra warranty: 有人讨论过,几大信用卡公司原则上都提供一年以下的double warranty,就是说你买一年,第二年坏了信用卡公司管修。但是实际上操作起来还是Amex比较容易。曾经有人说过用Amex买的电脑,在3年左右坏 了,然后Amex退钱的case,应持怀疑态度看待。因为信用卡的extended warranty是最多 1 + 1 extra year。

7、传说有人用学校的税号打电话到Lenovo改order变成免税,这属于非法逃税,大家不要贪蝇头小利。


Section II Case Study

1、准备工作:注册 FatWallet/Lenovo/American Express TailorMade 帐号
2、Goto Fatwallet.com,找到Lenovo的链接,点击打开新Lenovo窗口。
3、如果有EPP,可以在地址栏输入:www.lenovo.com/ibmepp,输入 Code CPP 输入 www.lenovo.com/cpp,输入 Code 这样可以 qualify FatCash, Confirmed

如果你的public coupon 比CPP/EPP好,例如20%,则没必要进入CPP/EPP但有时候需要比较一下二者的价格,据说public coupon的discount有时候是把原价升高了。

4、在这个窗口里完成配置
一些个人意见:
不打游戏的话,独立显卡都是浪费钱,Vista Aero跑集成显卡足够了Never waste money upgrade CPU. 从1.6G升到1.8G,做Office/Internet/Email你要是能感觉到区别我就服了你。除非你是做CPU测量的。低频还更省电。 Bluetooth必要,将来接鼠标什么都,甩掉讨厌的尾巴,真正的无线

T系列:推荐SxGA+ 4:3屏幕,不推荐XGA,不推荐T61的14"Widescreen,分辨率低,不对称,设计的人估计脑壳进了水15.4"Wide SXGA+, Good, 但是有点重,体格强壮的话你会喜欢的推荐上7200rpm硬盘,但同价位的话也可以考虑 5400rpm 的大容量有点闲钱的话,Wireless N 的网卡不错,马上主流了

X系列:x61s推荐Ultralight 屏,上8-cell电池的话,不如上x61,因为电池一上,x61s的重量优势全没了。嫌屏幕和键盘小的,外接键盘和Monitor都很便宜,接上就可以跟Desktop一样工作,兼顾x系列的便携和在家工作的需要

Warranty: 产品的质量可以从 Warranty 的价格看出来,就好象反驳百慕大三角的神秘主义可以从保险公司的船舶保费看出来一样。ThinkPad 一贯质量优良,因此只需要$125左右就可以加到3年,CPP/EPP下只要$95。如果你的投资大于$1000,我想应该加上。Laptop现在越来越 成了易耗品,Lenovo接手后价格大幅下降,确实不排除某些部件降低了质量等级的怀疑,但是Anyway,ThinkPad系列的质量仍然是值得称道 的,而且大家也确实能用得起了。好像大家在这上面争论很多,但Lenovo不是慈善机构 You get what you paid for.

5、Apply Coupon
CPP/EPP 一般不能combine public coupon,但是前段时间有个"USEHOLIDAY"的10% extra saving 买 X 系列可以和 CPP 一起用,可以试试看。

6、推荐用Amex Checkout,或者你的更高 cash back 的卡,比如 dealsea 首页5% everything for 3 months 的 Citi Master。

A Saving Sample: 15% CPP + 6% FatCash + 10% USEHOLIDAY + 5% Credit Card Total: 36%这些都是 Extra Saving

Section III Conclusion

1、Lenovo 的订单都是可以打电话改配置的。
2、XP和Vista价格是一样的,不过学校一般有免费的版本,所以我都是省下钱,只买Home Edition自己升级。
3、内存买1G,将来自己升, XP 1G well enough, vista 2G, 4G is wasting money unless you use 64-bit windows system
4、Warranty 保修期内任何时候都可以补买。
5、推荐上Vista,虽然有一些小问题,但是慢慢都会改过来的,大势所趋,我的x61s跑Vista Buz 就挺好;
6、购买 Warranty 是免税的,ThinkPad 的Warranty便宜,CPP/EPP下只要$95就可以加到3年。
7、 正式的 Invoice 可以电话要到,需要Fax。

罗罗嗦嗦说这么多,无非也是想鼓励大家买 Lenovo 支持国货,最近争论特别多,可是咱国家出个品牌真不容易,对咱们海外的人来说也有面子,不让人老美总认为中国人只会做鞋子内裤。自己的品牌就像自己的孩 子,谁家的孩子都会犯毛病,日本的丰田本田说远的当年二战时产的汽车都是垃圾,近的,TOYOTA的Prius原来也是毛病多多,都是国人支持捧起来的。 退一万步讲,ThinkPad的起点已经很高了,Lenovo 整合不容易,拖着大堆美国 IBM 员工 5 年内不能解雇,供应链整合也需要时间,希望大家宽容一点,不要一上来就是一个大标题“天杀的Lenovo”之类。

就算在美国住一辈子,拿绿卡当公民,人家也只会叫你 American Chinese,而不是 Chinese American,包括你的孩子。

一句话,请大家支持国货。

Debian Linux新手Apt-get/dpkg简明入门

Debian是最早的Linux发行版之一。它能引起公众注意就因为它让安装与卸载软件非常简单。在其他发行版还陷在依赖性的泥潭里时,Debian用户因为有更好的包管理系统而免受这些困扰。

所有基于Debian的发行都使用这个包管理系统。Deb包可以把一个应用的文件包在一起,大体就如同Windows上的安装文件。这里要介绍的就是如何使用安装包处理软件来达到我们的目的。

用apt-get的第一步就是引入必需的软件库,Debian的软件库也就是所有Debian软件包的集合,它们存在互联网上的一些公共站点上。把它们的 地址加入,apt-get就能搜索到我们想要的软件。/etc/apt/sources.list是存放这些地址列表的配置文件,其格式如下:

deb [web或ftp地址] [发行版名字][main/contrib/non-free]

比如Ubuntu是一个基于Debian的发行,它的Sources.list可以是这样的:

deb http://in.archive.ubuntu.com/ubuntu breezy main restrcted

你可以自己加上自己的地址。apt-get.org 上面有一些不错的地址列表。

设好地址之后,就要把本机上的软件库跟网上的库同步(只是软件描述信息,不包含软件本身)。这样,本机上就有了一个可用的软件的清单,命令如下:

# apt-get update

运行成功之后,你就可以搜到在你的发行版中有哪些软件了,命令是apt-cache,运行这个命令是在本机是检索,而不连到网上。如:

# apt-cache search baseutils

这个命令可以列出baseutils这个软件包的情况,有还是没有,还有版本等。

看到库里有这个软件包后,就可以安装它:

# apt-get install baseutils

这时我们就可以看到apt-get的威力了。如果baseutils依赖于某个另外的软件,或者一个运行库xyz.0.01.so,apt-get会自动 下载这个包(或含有这个库的软件包)。这叫做自动依赖性处理。通常,如果你只用Debian软件库内的软件,是不会发生找不到包或包版本不对的情况的,除 非用的是正在开发的Testing或Unstable版本。

卸载软件:

# apt-get remove baseutils

如果想看一下库里有多少软件:

# apt-cache stats
Total package names : 22502 (900k)
Normal packages: 17632
Pure virtual packages: 281
Single virtual packages: 1048
Mixed virtual packages: 172
Missing: 3369
...

把本机所有软件升级到最新版:

# apt-get upgrade

最后是最强力的--把整个发行版都升到新版本:

# apt-get dist-upgrade

升级时注意那些影响系统起动的东西,比如升级了内核,升级了grub或lilo等,这之后你应当重新运行grub或是lilo,让它们指向正确的位置,否则升级之后会工作不正常的。

用apt-get安装软件时,它会从网上(在sources.list里指的那个站点)下载所用的软件包,这个包将存在本机上,目录是:/var /cache/apt/archives/。时间长了,这里会变得非常巨大,占用大量的硬盘空间。要想清理这个目录,可以运行:

# apt-get clean

还有一个自动清理功能,它只清除那些没用的或者是不完整的软件包:

# apt-get autoclean

这样在重装某软件时就依然能使用已经下载好的,而不是再到网上去下载。

dpkg - 底层一些的包管理工具

用上apt(高级包管理工具)之后,一般是不需要处理单个的deb文件的。如果需要,就要用dpkg命令。比如想自己装gedit:

# dpkg -i gedit-2.12.1.deb

卸载:

# dpkg -r gedit

这里只写名字即可。还可以加上--purge(-P)标志:

# dpkg -P gedit

这会连同gedit的配置文件一起删除,只用-r的话是不删除配置文件的。

如果不想安装一个deb包,但想看一下它里面有什么文件:

# dpkg -c gedit-2.12.1.deb

如果想多看点信息:

# dpkg -I gedit-2.12.1.deb

也可以用通配符来列出机器上的软件:

# dpkg -l gcc*

这会列出所有gcc开头的软件包:
Desired=Unknown/Install/Remove/Purge/Hold
Status=Not/Installed/Config-files/Unpacked/Failed-config/.
/ Err?=(none)/Hold/Reinst-required/X=both-problems
/ Name Version Description
+++-===============-==============-========================
ii gcc 4.0.1-3 The GNU C compiler
ii gcc-3.3-base 3.3.6-8ubuntu1 The GNU Compiler Colletio
un gcc-3.5 none (no description available)

其中,第1个 i 表示希望安装,第2个 i 表示已经安装,第3个字段是问题(如果有)(这3个字的含义可以看上面那3行,desired, status, err),后面是名字,版本和描述。un就表示,Unknown, not-installed。

如果想看某包是否已经安装:

# dpkg -s gedit

如果想看某软件都有哪些文件,都装到了什么地方:

# dpkg -L gedit

如果只想看其中的某些文件,就加上Grep:

# dpkg -L gedit grep png

当然还有aptitude和Aptitude,前者是终端上运行的带菜单的工具,后者是X窗口上运行的图形化的程序。

还有,列出某包的详情:apt-cache show gedit
一些强制的命令:dpkg --force-help

原文地址: http://linuxhelp.blogspot.com/2005/12/concise-apt-get-dpkg-primer-for-new.html
Debian is one of the earliest Linux distribution around. It caught the public's fancy because of the ease of installing and uninstalling applications on it. When many other linux distributions were bogged down in dependency hell, Debian users were shielded from these problems owing to Debian's superior package handling capablities using apt-get.

All Linux distributions which claim their roots in the Debian distribution use this versatile package manager. For the uninitiated, Debian uses the deb package format for bundling together files belonging to an application. You can look at it as something like a setup installer (Eg: Installshield) in windows counterpart.

Here I will explain how to go about using this package handling utility to get the results that you desire.

The first step needed to use apt-get to your advantage is including the necessary repositories. Repositories are merely collections of softwares which are stored in a public location on the internet. By including the web address of these repositories, you are directing apt-get to search these locations for the desired software. You use the /etc/apt/sources.list file to list the addresses of the repositories. It takes the following format:
deb  [web address] [distribution name][maincontribnon-free]
For example, in Ubuntu a debian based distribution, it could be something like this:
deb http://in.archive.ubuntu.com/ubuntu breezy main restrcted
You can add any repository you like. apt-get.org contains an excellent collection of repositories to suite all tastes.

Once you have set the repositories, the next step is to sync the local software database with the database on the repositories. This will cache a copy of the list of all the remotely available softwares to your machine. This is achieved by running the following command:
# apt-get update
An advantage of this is you now have the power to search for a particular program to see if it is available for your version of distribution using the apt-cache command. And you don't need a net connection to do this. For example,
# apt-cache search baseutils
... will tell me if the package baseutils is available in the repository or not by searching the locally cached copy of the database.

Once you have figured that the package (in our case baseutils) is available, then installing it is as simple as running the following command:
# apt-get install baseutils
The real power of apt-get is realised now. If the baseutils package depends on the availability of a version of the library say, "xyz1.5.6.so". Then apt-get will download the library (or package containing the library) from the net and install it before installing baseutils package. This is known as automatic dependency resolution.

And removing a package is as simple as running the command:
# apt-get remove baseutils
Get statistics about the packages available in the repositories by running the command :
# apt-cache stats
Total package names : 22502 (900k)
Normal packages: 17632
Pure virtual packages: 281
Single virtual packages: 1048
Mixed virtual packages: 172
Missing: 3369
...
To upgrade all the softwares on your system to the latest versions, do the following:
# apt-get upgrade
And finally the king of them all - upgrading the whole distribution to a new version can be done with the command:
# apt-get dist-upgrade
Saving valuable hard disk space
Each time you install an application using apt-get, the package is actually cached in a location on your hard disk. It is usually stored in the location /var/cache/apt/archives/ . Over a period of time, all the cached packages will eat up your valuable hard disk space. You can clear the cache and release hard disk space by using the following command:
# apt-get clean
You could also use autoclean where in, only those packages in the cache which are found useless or partially complete are deleted.
# apt-get autoclean
dpkg - The low level Package management utility
As I said earlier, Debian based distributions use the Deb package format. Usually normal users like you and me are shielded from handling individual deb packages. But if you fall into a situation where you have to install a deb package you use the dpkg utility.
Lets assume I have a deb package called gedit-2.12.1.deb and I want to install it on my machine. I do it using the following command:
# dpkg -i gedit-2.12.1.deb
To remove an installed package, run the command:
# dpkg -r gedit
The main thing to note above is I have used only the name of the program and not the version number while removing the software.
You may also use the --purge (-P) flag for removing software.
# dpkg -P gedit
This will remove gedit along with all its configuration files. Where as -r (--remove) does not delete the configuration files.

Now lets say I do not want to actually install a package but want to see the contents of a Deb package. This can be achieved using the -c flag:
# dpkg -c gedit-2.12.1.deb
To get more information about a package like the authors name,the year in which it was compiled and a short description of its use, you use the -I flag:
# dpkg -I gedit-2.12.1.deb
You can even use wild cards to list the packages on your machine. For example, to see all the gcc packages on your machine, do the following:
# dpkg -l gcc*

Desired=Unknown/Install/Remove/Purge/Hold
Status=Not/Installed/Config-files/Unpacked/Failed-config/.
/ Err?=(none)/Hold/Reinst-required/X=both-problems
/ Name Version Description
+++-===============-==============-========================
ii gcc 4.0.1-3 The GNU C compiler
ii gcc-3.3-base 3.3.6-8ubuntu1 The GNU Compiler Colletio
un gcc-3.5 none (no description available)
un gcc-3.5-base none (no description available)
un gcc-3.5-doc none (no description available)
ii gcc-4.0 4.0.1-4ubuntu9 The GNU C compiler
...
In the above listing, the first 'i' denotes desired state which is install. The second 'i' denotes the actual state ie gcc is installed. The third column gives the error problems if any. The fourth, fifth and sixth column gives the name, version and description of the packages respectively. And gcc-3.5 is not installed on my machine. So the status is given as 'un' which is unknown not-installed.

To check if an individual package is installed, you use the status -s flag:
# dpkg -s gedit
Two days back, I installed beagle (a real time search tool based on Mono) on my machine. But I didn't have a clue about the location of the files as well as what files were installed along with beagle. That was when I used the -L option to get a list of all the files installed by the beagle package.
# dpkg -L beagle
Even better, you can combine the above command with grep to get a listing of all the html documentation of beagle.
# dpkg -L beagle | grep html$
These are just a small sample of the options you can use with dpkg utility. To know more about this tool, check its man page.
If you are alergic to excessive command line activities, then you may also use dselect which is a curses based menu driven front-end to the low level dpkg utility.

GUI front-ends for apt-get
Related Content


Apt-get报错解决方法

某此升级软件出错之后,apt-get就开始罢工,总提示下面的错误
dpkg: parse error, in file `/var/lib/dpkg/available' near line 10442 package `iso-cods':
missing version
E: Sub-process /usr/bin/dpkg returned an error code (2)

怎么解决呢,去报错提示的文件夹下面将old文件替换掉出错文件即可,比如我这个就是把/var/lib/dpkg/下的available-old替换掉available这个文件,再运行apt-get就不会报错了,have a try, enjoy it!

Ubuntu 9.04 On ThinkPad X61.... Enjoy it! <1>

1. 什么是 Ubuntu?
Ubuntu 是一个由 社区 开发的,适用于笔记本电脑、 桌面电脑 和 服务器。 无论您是在家庭、学校还是工作时使用,Ubuntu 都包含了您所需的所有程序:无论是文字处理和电子邮件,还是 Web 服务和编程工具。
Ubuntu 永远 免费。您无需支付任何许可费用。您可以下载、使用以及与您的朋友、家庭、同学或同事分享,而绝对无需任何代价。
Link: 官方首页 官方论坛

2. Ubuntu是众多Linux发行版本中最喜欢的一款了,也是最初接触的一款,一知道出了9.04正式版,马上下载镜像ISO,通过量产U盘直接安装 windows & Ubuntu双系统<因为某些原因,只能向windows妥协>, 安装过程也是一如既往的傻瓜式,具体就不多说了。
Tips:
<1> 像我一样喜欢En界面的话,安装时语言选En(US)就可以了,输入法,中文支持等系统安装好之后再装
<2> 值得注意的地方就是磁盘分区那一步,一定要选择手动管理磁盘,否则..一不小心..珍藏多年的海量电影就化为泡影..欲哭无泪吧


3. 安装完Ubuntu 9.04之后做些什么呢?
3.1 最最首要做得是添加合适的源sources.list, 不同的网络环境下访问源的速度也是不同的,比如网通的用户就访问电信的源,速度慢是正常的,所以我们添加源的目的是?得到更快的下载速度!这样会对后面的维护起到事半功倍的效果哦,hoho
-->点击我查看Wiki源列表<-- 添加源是请选择当前使用的发行版本(9.04)对号入座 <1> 现备份一下当前于sources.list以免出错:sudo cp /etc/apt/sources.list /etc/apt/sources.list_backup
<2> 编辑list, 在最上面加上更快更好的源: sudo gedit /etc/apt/sources.list
我是上海有线通用户 ,用了 Mirror.lupaworld.com更新服务器(浙江省杭州市双线服务器):
deb http://mirror.lupaworld.com/ubuntu jaunty main restricted universe multiverse
deb http://mirror.lupaworld.com/ubuntu jaunty-security main restricted universe multiverse
deb http://mirror.lupaworld.com/ubuntu jaunty-updates main restricted universe multiverse
deb http://mirror.lupaworld.com/ubuntu jaunty-backports main restricted universe multiverse
deb http://mirror.lupaworld.com/ubuntu jaunty-proposed main restricted universe multiverse
deb-src http://mirror.lupaworld.com/ubuntu jaunty main restricted universe multiverse
deb-src http://mirror.lupaworld.com/ubuntu jaunty-security main restricted universe multiverse
deb-src http://mirror.lupaworld.com/ubuntu jaunty-updates main restricted universe multiverse
deb-src http://mirror.lupaworld.com/ubuntu jaunty-backports main restricted universe multiverse
deb-src http://mirror.lupaworld.com/ubuntu jaunty-proposed main restricted universe multiverse

<3> 保存sources.list之后别忘了刷新源列表: sudo apt-get update
Tips:
<1> 怎么知道哪个源速度快?尽量选同网的,电信选电信,网通选网通,另外可以通过ping源地址,简单的查看连接速度
<2> 如果list里有龟速的源,可以直接删除掉,但是如果没有胆量,可以在前面加上#来屏蔽掉,嘿嘿

3.2 添加字体,习惯了雅黑
<1> 下载或者从windows系统copy各种喜欢的ttf字体(比如雅黑msyh.ttf)放在一个文件夹内
<2> Terminal终端里执行下面命令,将需要的字体复制到系统的字体目录下,然后重建字体缓存就可以了
sudo mkdir /usr/share/fonts/ttf
sudo cp /存放ttf字体的路径/* /usr/share/fonts/ttf
cd /usr/share/fonts/ttf
sudo chmod 744 *
sudo mkfontscale
sudo mkfontdir
sudo fc-cache -f -v
exit

<3> 这会儿你就会发现各种可以进行Fonts设置的地方都可以找到你需要的字体了

3.3 习惯了windows桌面,怎么在Ubuntu桌面也放上我的电脑 回收站这些快捷方式呢?
<1> 终端运行gconf-editor,会出来一个类似windows下regedit注册表的管理器Configuration Editor
<2> 在/app/nautilus/desktop右边发现computer_icon_visible这类的key, 打上勾桌面就会有computer icon了,同理network icon/trash icon...

Tips:
可以通过System-->Preferences-->Main Menu, 把System Tool里的Configuration Editor点开,以后就不需要记命令可以直接在左上角系统菜单里找到它了

3.4 安装中文输入法
输入法SCIM是自带的,不过里面没有pinyin而已,so......要做的是: sudo apt-get install scim-pinyin 安装完成之后重启或者登出一下就可以了
Tips:
因为是En系统,也许你会发现,通过快捷键Ctrl+Space无法调出中文拼音,怎么办? System-->Preferences-->Language Support, 勾上"Use input method engines (IME) to enter complex characters" ,设置将会在下次登录起效,All changes take effect next time you log in :).


3.5 安装视频播放器及解码
<1> 最喜欢的当然是万能的Mplayer以及她的前端Smplayer,舒服!
安装:sudo apt-get install mplayer-fonts mplayer mplayer-skins mozilla-mplayer smplayer
在开始用它进行视频播放前还需要进行以下设置(先启动它),然後右键弹出主菜单 -> Preferences/属性 -> Video/视频,在"Available drivers/可用驱动"中选择"x11"或"xv",>在同一窗口下半部份钩上"允许掉帧/Enable frame dropping"。
<2> 有了播放器还是不能放rmvb的,还需要解码器codecs
wget http://www1.mplayerhq.hu/MPlayer/releases/codecs/essential-20071007.tar.bz2
tar -xvjf essential-20071007.tar.bz2
sudo mv essential-20071007 /usr/lib/codecs
Tips:
如果播放rmvb有声音没图像: sudo apt-get install libstdc++5


3.6 Conky, 这个太棒了,是我必需的,可以让你的系统信息在桌面一目了然,而且可以任意配置
<1> 安装: sudo apt-get install conky
<2> 在主目录下建立配置文件".conkyrc" 隐藏文件,别忘了点名的"." , 内容嘛 去百度吧 以后再说,先附上我的 ^0^
代码:
# set to yes if you want Conky to be forked in the background
background no

cpu_avg_samples 2
net_avg_samples 2

out_to_console no

# X font when Xft is disabled, you can pick one with program xfontsel
#font 7x12
#font 6x10
#font 7x13
#font 8x13
#font 7x12
#font *mintsmild.se*
#font -*-*-*-*-*-*-34-*-*-*-*-*-*-*
#font -artwiz-snap-normal-r-normal-*-*-100-*-*-p-*-iso8859-1

# Use Xft?
use_xft yes

# Xft font when Xft is enabled
xftfont sans:size=9

own_window_transparent no
#own_window_colour hotpink
# Text alpha when using Xft
xftalpha 0.8

# on_bottom yes

# mail spool
mail_spool $MAIL

# Update interval in seconds
update_interval 1
# Create own window instead of using desktop (required in nautilus)
own_window yes
own_window_transparent yes
own_window_hints undecorated,below,skip_taskbar
own_window_type override

# Use double buffering (reduces flicker, may not work for everyone)
double_buffer yes

# Minimum size of text area
minimum_size 260 5
maximum_width 400

# Draw shades?
draw_shades no

# Draw outlines?
draw_outline no

# Draw borders around text
draw_borders no

# Stippled borders?
stippled_borders no

# border margins
border_margin 4

# border width
border_width 1

# Default colors and also border colors
default_color white
default_shade_color white
default_outline_color white

# Text alignment, other possible values are commented
#alignment top_left
#minimum_size 10 10
gap_x 20
gap_y 60
alignment top_right
#alignment bottom_left
#alignment bottom_right

# Gap between borders of screen and text

# Add spaces to keep things from moving about? This only affects certain objects.
use_spacer none

# Subtract file system buffers from used memory?
no_buffers yes

# set to yes if you want all text to be in uppercase
uppercase no

# none, xmms, bmp, audacious, infopipe (default is none)
# xmms_player bmp

# boinc (seti) dir
# seti_dir /opt/seti

# Possible variables to be used:
#
# Variable Arguments Description
# acpiacadapter ACPI ac adapter state.
# acpifan ACPI fan state
# acpitemp ACPI temperature.
# adt746xcpu CPU temperature from therm_adt746x
# adt746xfan Fan speed from therm_adt746x
# battery (num) Remaining capasity in ACPI or APM
# battery. ACPI battery number can be
# given as argument (default is BAT0).
# buffers Amount of memory buffered
# cached Amount of memory cached
# color (color) Change drawing color to color
# cpu CPU usage in percents
# cpubar (height) Bar that shows CPU usage, height is
# bar's height in pixels
# downspeed net Download speed in kilobytes
# downspeedf net Download speed in kilobytes with one
# decimal
# exec shell command Executes a shell command and displays
# the output in torsmo. warning: this
# takes a lot more resources than other
# variables. I'd recommend coding wanted
# behaviour in C and posting a patch :-).
# execi interval, shell Same as exec but with specific interval.
# command Interval can't be less than
# update_interval in configuration.
# fs_bar (height), (fs) Bar that shows how much space is used on
# a file system. height is the height in
# pixels. fs is any file on that file
# system.
# fs_free (fs) Free space on a file system available
# for users.
# fs_free_perc (fs) Free percentage of space on a file
# system available for users.
# fs_size (fs) File system size
# fs_used (fs) File system used space
# hr (height) Horizontal line, height is the height in
# pixels
# i2c (dev), type, n I2C sensor from sysfs (Linux 2.6). dev
# may be omitted if you have only one I2C
# device. type is either in (or vol)
# meaning voltage, fan meaning fan or temp
# meaning temperature. n is number of the
# sensor. See /sys/bus/i2c/devices/ on
# your local computer.
# kernel Kernel version
# loadavg (1), (2), (3) System load average, 1 is for past 1
# minute, 2 for past 5 minutes and 3 for
# past 15 minutes.
# machine Machine, i686 for example
# mails Mail count in mail spool. You can use
# program like fetchmail to get mails from
# some server using your favourite
# protocol. See also new_mails.
# mem Amount of memory in use
# membar (height) Bar that shows amount of memory in use
# memmax Total amount of memory
# memperc Percentage of memory in use
# new_mails Unread mail count in mail spool.
# nodename Hostname
# outlinecolor (color) Change outline color
# pre_exec shell command Executes a shell command one time before
# torsmo displays anything and puts output
# as text.
# processes Total processes (sleeping and running)
# running_processes Running processes (not sleeping),
# requires Linux 2.6
# shadecolor (color) Change shading color
# stippled_hr (space), Stippled (dashed) horizontal line
# (height)
# swapbar (height) Bar that shows amount of swap in use
# swap Amount of swap in use
# swapmax Total amount of swap
# swapperc Percentage of swap in use
# sysname System name, Linux for example
# time (format) Local time, see man strftime to get more
# information about format
# totaldown net Total download, overflows at 4 GB on
# Linux with 32-bit arch and there doesn't
# seem to be a way to know how many times
# it has already done that before torsmo
# has started.
# totalup net Total upload, this one too, may overflow
# updates Number of updates (for debugging)
# upspeed net Upload speed in kilobytes
# upspeedf net Upload speed in kilobytes with one
# decimal
# uptime Uptime
# uptime_short Uptime in a shorter format
#
# seti_prog Seti@home current progress
# seti_progbar (height) Seti@home current progress bar
# seti_credit Seti@hoome total user credit




# variable is given either in format $variable or in ${variable}. Latter
# allows characters right after the variable and must be used in network
# stuff because of an argument
#${font Dungeon:style=Bold:pixelsize=10}I can change the font as well
#${font Verdana:size=10}as many times as I choose
#${font Perry:size=10}Including UTF-8,
# stuff after 'TEXT' will be formatted on screen


TEXT
${font Radio Space:size=18}Bruce's Desktop${hr 1}${color}
${font Radio Space:size=12}${color white}${time %Y-%m-%d %a}.
${font Radio Space:size=44}${time %H:%M}$font

${color white}WEATHER ${hr 1}${color}

${execi 3600 python ~/conkyrc/conkyForecast.py --location=CHXX0116 --datatype=CN}
${font Weather:size=44}${color gold}${execi 3600 python ~/conkyrc/conkyForecast.py --location=CHXX0116 --datatype=WF}${font}${color}${voffset -20}${offset 18}${execi 3600 python ~/conkyrc/conkyForecast.py --location=CHXX0116 --datatype=CC}${offset 10}${execi 3600 python ~/conkyrc/conkyForecast.py --location=CHXX0116 --datatype=HT}${offset 10}${execi 3600 python ~/conkyrc/conkyForecast.py --location=CHXX0116 --datatype=WS} ${font Arrows:size=10}${execi 3600 python ~/conkyrc/conkyForecast.py --location=CHXX0116 --datatype=BF}$font
${offset 60}Sol: ${color}${execi 3600 python ~/conkyrc/conkyForecast.py --location=CHXX0116 --datatype=SR}-${execi 3600 python ~/conkyrc/conkyForecast.py --location=CHXX0116 --datatype=SS}
${font Weather:size=26}${execi 3600 python ~/conkyrc/conkyForecast.py --location=CHXX0116 --datatype=WF --startday=1 --endday=4 --spaces=1}${font}
${execi 3600 python ~/conkyrc/conkyForecast.py --location=CHXX0116 --datatype=HT --startday=1 --endday=4 --spaces=11}

${color white}SYSTEM ${hr 1}${color}

Hostname: $alignr$nodename
Kernel: $alignr$kernel
Uptime: $alignr$uptime
Temperature: ${alignr}${acpitemp}°C

CPU: ${alignr}${freq_dyn} MHz
Processes: ${alignr}$processes ($running_processes running)
Load: ${alignr}$loadavg

CPU1 ${alignr}${cpu cpu1}%
${cpubar 4 cpu1}
CPU2 ${alignr}${cpu cpu2}%
${cpubar 4 cpu2}
RAM ${alignr}$mem / $memmax ($memperc%)
${membar 4}

Highest CPU $alignr CPU% MEM%
${top name 1}$alignr${top cpu 1}${top mem 1}
${top name 2}$alignr${top cpu 2}${top mem 2}
${top name 3}$alignr${top cpu 3}${top mem 3}

Highest MEM $alignr CPU% MEM%
${top_mem name 1}$alignr${top_mem cpu 1}${top_mem mem 1}
${top_mem name 2}$alignr${top_mem cpu 2}${top_mem mem 2}
${top_mem name 3}$alignr${top_mem cpu 3}${top_mem mem 3}

${color white}FILE SYSTEM ${hr 1}${color}

Root: ${alignr}${fs_free /} / ${fs_size /}
${fs_bar 4 /}
SYSTEM: ${alignr}${fs_free /media/SYSTEM} / ${fs_size /media/SYSTEM}
${fs_bar 4 /media/SYSTEM}
SOFT: ${alignr}${fs_free /media/SOFT} / ${fs_size /media/SOFT}
${fs_bar 4 /media/SOFT}
DATA: ${alignr}${fs_free /media/DATA} / ${fs_size /media/DATA}
${fs_bar 4 /media/DATA}
TEMP: ${alignr}${fs_free /media/Temp} / ${fs_size /media/Temp}
${fs_bar 4 /media/Temp}

${color white}NETWORK ${hr 1}${color}

Down ${downspeed eth0} Kb/s ${alignr}Up ${upspeed eth0} Kb/s
${downspeedgraph eth0 25,107} ${alignr}${upspeedgraph eth0 25,107}
Total ${totaldown eth0} ${alignr}Total ${totalup eth0}


配9.04自带的DarkRoom主题太棒了,效果图:


3.7 一些个人小偏好
<1> 把终端加到右键菜单:sudo apt-get install nautilus-open-terminal 安装完relogin
<2> 以root权限打开文件夹:sudo apt-get install nautilus-gksu 安装完relogin, 这样右键单击文件或文件夹,可以选择以管理员打开

未完待续... ...

2009年5月1日星期五

与众不同 我是MID

什么是MID

MID是Mobile Internet Devices的英文缩写,中文意思是移动互联网设备。MID诞生于3G时代,可随身携带,可随时随地上网,融合了移动办公、影音娱乐、学习和电子词典、游戏娱乐等功能的新一代随身电子产品。

智器在市场上推出了千元以下的国内第一款超高性价比的MID产品。

什么是ARM

英国ARM公司是全球嵌入式处理器霸主。全球市场上绝大多数的GPS、手机、MID等产品都是用ARM公司的处理器内核,ARM公司从而占有全球绝大部分市场份额。就像绝大部分的电脑里面都安装英特尔公司的处理器一样。

ARM的处理器分几代?

一共三代。

各个公司的芯片型号虽然众多,但都是基于ARM公司的几代芯片内核生产的:ARM7、ARM9、ARM10、ARM11。其中ARM10主要被技术 改造为Xscale品牌的芯片内核使用,可不列入其中。因此,ARM公司的这些芯片内核都是7/9/11的单数版本号的演进方式,一共推出了三代。

处理器对GPS、手机和MID有什么影响?

跟电脑一样,处理器速度越快,开机速度越快,我们安装运行软件也越流畅舒适,界面可以做得更花哨更炫,操作起来没有卡顿的现象。

ARM的处理器有三代,ARM7、ARM9、ARM11,跟电脑一样,新一代的处理器,比老一代的处理器更快。

电脑为什么要升级换代?就是因为处理器速度慢了,我们最主要就是为了升级处理器。

同样的,GPS、手机和MID要看机子是采用哪一代的ARM处理器。老一代的ARM9比起ARM11,运行速度慢了很多。这个因素决定了你购买的产品是否容易被淘汰,甚至买回来就是处在淘汰边沿的产品。

哪些产品还在用老一代的ARM处理器?

目前市面上的非智能手机还在用ARM7处理器,智能手机目前很少一部分用ARM9处理器,大一部分用ARM10处理器改造而来的Xscale(TM)品牌的处理器。GPS用的基本上还是ARM9的处理器。

MP4某品牌即将推出上网产品用的TCC7901处理器,是ARM9处理器。

某出口企业推出的上网产品用三星S3C2443处理器,是ARM9内核处理器,最高主频也只有533,目前暂未能确认该产品是否用了最高主频版本。

该企业采用的S3C2443和智器MID采用的S3C6410,虽然同属韩国三星公司生产的芯片,但是差别巨大。该企业采用的S3C2443是三星多年前的老产品,生产工艺很老;智器采用的S3C6410,是三星最领先的处理器,采用最先进的65纳米工艺生产。

哪些产品在用新一代的ARM11处理器?

诺基亚和苹果的高档智能手机采用ARM11处理器。智器MID采用与苹果iPhone的3G版同样型号的ARM11处理器。

主频533的ARM9和主频667的ARM11差多少?

性能差别非常巨大。即使主频都是533的ARM9和ARM11比较,就像电脑的英特尔奔3处理器和奔4处理器,同主频、不同“辈份”,售价差别很大,性能差距也极大。

从主频上差134(667-533=134),但是内核差了两代(从ARM9到ARM10(Xscale)到ARM11),如果不算ARM10特殊 版本,也差了1代。因此芯片内部的总线带宽、指令执行流水线、缓存等等,ARM9比ARM11都少了几倍。有兴趣的读者可以参考ARM公司提供的相关官方 技术资料。

什么是WM?(Windows Mobile)?

WM是微软公司开发的专门用于智能手机的操作系统,英文全称是Windows Mobile,被国内玩家简称WM。内置WM操作系统的智能手机能够安装大量的软件,从而使得智能手机有更多的可玩性和娱乐性,也可用于办公和商务。

什么是WINCE?它和WM的差别是什么?

WINCE是微软公司在电脑Windows软件之外所开发的另外一套操作系统。用于智能手机的WM操作系统就是在WINCE的基础上开发。WINCE和WM相比,WINCE完善度远不如WM。微软公司的开发重心是WM智能手机操作系统,而不是WINCE。

WM智能手机操作系统上有无数的软件可以安装使用,而WINCE上的软件很有限。微软WM智能手机上的软件,绝大多数都不能在WINCE上运行。

GPS车载导航仪绝大多数都是安装了WINCE操作系统。所以,这就是为什么GPS并不能安装Windows Mobile智能手机上的这么多软件的原因。

目前有些商家采用WINCE作为上网设备的操作系统,广大消费者要注意WINCE和智能手机操作系统WM(Windows Mobile)的巨大区别

什么是Linux

Linux是风靡全世界的开源免费的操作系统。开放的Linux与微软Windows系统是全球最流行的两大电脑操作系统。在移动电话上,Linux已经成为与Symbian OS、Windows Mobile系统并列的三大智能手机操作系统之一。

有哪些电子产品安装了Linux操作系统?

苹果电脑、谷歌Android手机、索尼PS3游戏机都是基于Linux内核做进一步的开发。智器MID也是采用了基于Linux内核的Ubuntu改进版。

Linux强大的地方在哪?

Linux的软件非常丰富,扩展性非常好,性能优异,运行稳定不容易死机。Linux最强大的地方是它的网络功能。例如:BT网络下载软件就首先诞 生于Linux上。另外,Linux上没有病毒和木马入侵,给我们带来很多的便利。Linux占用资源少,同样的软件功能,在Linux上运行往往比在 Windows上运行的效率高。

用Linux和用WINCE有多大差别?

在智能手机领域,Linux的竞争对手是Windows Mobile(WM)系统,而不是WINCE。只有Windows Mobile(WM)系统的庞大软件库才能与Linux的开放软件库相媲美,而在功能上两者各有优缺点。

由于微软公司对WINCE的投入,远远不如对Windows Mobile(WM)系统的投入,所以WINCE近几年都没有什么改变,软件很少,远远不能跟Linux媲美。2008年底曾经有某国产芯片公司号称提供 千元以下的山寨上网本,由于使用一颗ARM9处理器,安装WINCE操作系统(不是Windows XP,也不是Windows Mobile),结果完全不能被广大消费者所接受,而惨遭失败。