Freebsd

Using 'skim' for input in KDE

| Development | #FreeBSD | #kde | #scim | #skim

I have a long history suffering from inputing Chinese in KDE, where scim does not work well, especially when used with Qt applications. Certain applications like KWord will refuse Chinese when using SCIM.

After some search it seems that ‘skim’ which is scim Qt’ifyed version, would support them well. Moreover, this version seems to have better UI than its GTK counterpart. The port (textproc/skim) is now unmaintained, maybe someone will pick it up? I’ll consider picking it up if there is nobody taking care for it.

参与评论

patched top(1) and kernel to support multiple CPU

| Development | #FreeBSD | #multiprocessor | #top

前几天有人问 FreeBSD 的 top(1) 如何能够显示不同 CPU 的占用情况。这是 patch 过之后的输出:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
last pid:  1773;  load averages:  0.43,  0.19,  0.16                                                                                        up 0+00:34:35  16:17:04
97 processes:  1 running, 96 sleeping
CPU 0: 20.8% user,  0.0% nice,  0.0% system,  0.0% interrupt, 79.2% idle
CPU 1:  3.1% user,  0.0% nice,  0.0% system,  0.0% interrupt, 96.9% idle
Mem: 517M Active, 21M Inact, 577M Wired, 11M Cache, 48K Buf, 810M Free
Swap: 2048M Total, 2048M Free

 PID USERNAME THR PRI NICE SIZE RES STATE C TIME WCPU COMMAND  
 1236 delphij 1 104 0 232M 143M select 1 4:37 37.06% Xorg  
 1768 delphij 1 8 0 164M 52704K nanslp 1 0:07 36.28% kicker  
 1771 delphij 1 8 0 6212K 1664K wait 0 0:00 3.17% sh  
 1772 delphij 1 45 0 8020K 1656K select 1 0:00 2.39% ksysguardd  
 1756 delphij 1 20 0 10648K 3596K pause 1 0:00 1.17% csh  
 1754 delphij 1 4 0 11764K 1588K sbwait 1 0:00 0.78% gnome-pty-helper  
 1751 delphij 2 -8 0 136M 25756K piperd 0 0:00 0.68% gnome-terminal  

FreeBSD 8 中已经包含了这个功能。

参与评论

Micropolis ported to FreeBSD

| Development | #FreeBSD | #micropolis | #port | #Simcity

Today I have ported (a rather hacky patch) Micropolis (a GPL’ed version of SimCity) to FreeBSD.

(20080114) Note: the patch is based on the git version of micropolis-activity, as available from git://dev.laptop.org/projects/micropolis-activity .


参与评论

BSD ar(1) announced

Kai Wang has announced today the BSD ar(1) is available for wider testing. This is amazing work, the creation and list speed are 5-20 times faster than GNU ar(1), and extraction speed is also slightly better than GNU ar(1).

It is also important to note that this version is completely BSD-licensed (yes, that means that you are free from the lair’s license), and is a piece of the vital parts of the FreeBSD DTrace work.

参与评论

让多个 FreeBSD jail 共享同一套 MTA

| Security | #FreeBSD | #jail | #postfix | #sendmail

FreeBSD 从 4.0 版本开始提供了非常强大的虚拟化工具—-jail。对于许多应用来说,jail能够在确保应用程序之间的有效隔离的前提下,最大限度地发挥硬件性能(每个jail不会单独运行自己的内核),而在 jail 内部看来,则基本上与真正的服务器无异,且性能损失很小;通过内核提供的 ABI 模拟,jail能够提供 FreeBSD 早期版本,以及 Linux 2.4.x 或 2.6.x 的兼容能力。

许多传统的 Unix 应用程序假定系统中存在一个可用的 MTA。FreeBSD 中内建了 sendmail,但在 jail 中配置 sendmail 会遇到一个比较麻烦的问题,即在 jail 中,127.0.0.1 指代的是 jail 的 IP 地址而不是本地 loopback 设备。换言之,原本监听本地 socket 的 MTA 变成了监听 jail 对外的 IP,这会是一个安全隐患。

阅读全文…( 本文约 499 字,阅读大致需要 1 分钟 )

Perl 5.10 released

| Development | #FreeBSD | #Perl | #ports

Perl 5.10 发布了!我觉得这对于 p5-* 绝对是一个大事件 :P

参与评论

转投 KDE 了!

| Development | #Desktop | #FreeBSD | #KDE

犹豫了很久,实在是禁不起诱惑……从今天起改用 KDE 了,感觉这个桌面平台比 GNOME 更理性一些。

在 FreeBSD 上安装 KDE 非常简单:portinstall kde。然后配一下.xinitrc让它启动就可以了。

阅读全文…( 本文约 214 字,阅读大致需要 1 分钟 )

arp反攻

| Security | #arp | #attack | #FreeBSD

如果拥有一台以上的服务器,采用arp反攻能够在你冲到机房把那台有问题的服务器的主人抓住吊起来打之前,暂时占据主动。

具体做法是,让这些机器去publish网关和其他节点的正确arp信息。具体细节,请参见 FreeBSD 的 arp(8) 联机手册。

阅读全文…( 本文约 147 字,阅读大致需要 1 分钟 )

在 FreeBSD 下配置 HP LaserJet 4000 和 HP LaserJet 2100 打印机

| Hardware | #apple | #CUPS | #FreeBSD | #printer

以前一直以为配置起来很麻烦,现在看来并不是这样。

我现在的办公室里面使用的是 Windows 打印服务器,而 Windows 打印服务器和 HP 打印机之间是通过 TCP/IP 连接的(不过为什么还需要这个打印服务器?先不管它)。最近因为工作原因需要相当多的打印任务,但是我自己没有合法的 Microsoft Office 授权,因此,寻找合法的、开源解决方案便势在必行了。

我平时使用的桌面系统是 FreeBSD,采用 GNOME 作为窗口管理器,平时主要是用它来进行开发,因此也没研究过打印的事情。说了很多废话,现在我们来看在 FreeBSD 上面需要先做些什么?

阅读全文…( 本文约 773 字,阅读大致需要 2 分钟 )

1GB page on AMD processor

| Kernel | #1gb | #8.0 | #amd | #FreeBSD | #page | #virtual memory

So now AMD 0x10 processors can handle 1GB pages, according to Alan Cox’s commit today! It would be exciting to see it on FreeBSD 8.0 (already in -HEAD).

(I’m still looking for a development desktop PC donation, see the FreeBSD wantlist)

参与评论