正要測試 Linux-HA 的 heartbeat,系統是 FC3,所以懶毛病又發了,就想能否直接用 rpm 安裝省事。到了官方網站只看到:

Thanks to Joost Soeterbroek, the latest Fedora-compatible versions from Fedora extras can be included simply by issuing this command:

    $ sudo yum install heartbeat@

於是,照著連結到 Fedora extras 找了半天,這才發現只有 FC4 和 FC5 才有懶人包?!不死心,再網路上搜尋看看,結果也只有 1.2.3 版的 FC1 rpm……

好啦,不然就直接用 tar-ball 的方式安裝算了。嗯…或者…要不乾脆自己動手包個 rpm 也好,以後說不定可以省事點:

首先,當然要有個 SPEC 和原始檔什麼的,不過既然有人包了 FC4 的最新版 (2.0.6),就拿它來修改好了:heartbeat-2.0.6-2.fc4.src.rpm

安裝後,直接到 /usr/src/redhat/SPEC 賭賭看(就是懶咩…):

    $ rpmbuild -ba heartbeat.spec
    error: Failed build dependencies:
    glib2-devel is needed by heartbeat-2.0.6-2.i386
    libnet-devel is needed by heartbeat-2.0.6-2.i386
    libtool-ltdl-devel is needed by heartbeat-2.0.6-2.i386
    net-snmp-devel is needed by heartbeat-2.0.6-2.i386
    gnutls-devel is needed by heartbeat-2.0.6-2.i386

哈,天下果然沒有這麼美的事,要不然我早就中樂透了…… XD

yum list 查一查,只缺 libnet-devel 和 libtool-ltdl-devel ,不過好在 FC3 extras 有 libnet-devel ,所以還是照規矩來,把 FC3 extras 加到 /etc/yum.repos.d 去吧:

Update to the latest version of yum and add a file (e.g. fedora-extras.repo) in your /etc/yum.repos.d directory with following content:

[extras]
name=Fedora Extras - $releasever - $basearch
baseurl=http://download.fedora.redhat.com/pub/fedora/linux/extras/$releasever/$basearch/
gpgcheck=1
gpgkey=http://download.fedora.redhat.com/pub/fedora/linux/extras/RPM-GPG-KEY-Fedora-Extras
[extras-testing]
name=Fedora Extras Test Updates - $releasever - $basearch
baseurl=http://download.fedora.redhat.com/pub/fedora/linux/extras/testing/$releasever/$basearch/
gpgcheck=1
gpgkey=http://download.fedora.redhat.com/pub/fedora/linux/extras/RPM-GPG-KEY-Fedora-Extras
enabled=0

[extras-debug]
name=Fedora Extras – $releasever – $basearch – Debugging packages
baseurl=http://download.fedora.redhat.com/pub/fedora/linux/extras/$releasever/$basearch/debug/
gpgcheck=1
gpgkey=http://download.fedora.redhat.com/pub/fedora/linux/extras/RPM-GPG-KEY-Fedora-Extras
enabled=0

再來,當然就是把該裝的 rpm 都裝上去。只除了 libtool-ltdl-devel……

    $ yum -y install glib2-devel libnet-devel net-snmp-devel gnutls-devel

在比較了一下 FC4 的 libtool-ltdl-devel 包裝內容物之後,在 FC3 就是 libtoo 囉。於是再修改 heartbeat.spec,把:

    BuildRequires:    libtool-ltdl-devel

改成:

    BuildRequires:    libtool

似乎有瞄到 requires fedora-usermgmt ,索性也一併用 yum 裝了省得麻煩:

    $ yum -y install fedora-usermgmt

萬事似乎俱備了,再來個 rpmbuild 試看看……

嗯,還是有 error:

    /usr/bin/ld: cannot find -lgcrypt

唔,那肯定是少了 libgcrypt-devel,所以:

    $ yum -y install libgcrypt-devel

嗯,第三次 rpmbuild 囉,反正劉大耳不也找諸葛茅蘆光顧了三次……

好囉,終於看到這幾行字了:

    Wrote: /usr/src/redhat/SRPMS/heartbeat-2.0.6-2.src.rpm
    Wrote: /usr/src/redhat/RPMS/i386/heartbeat-2.0.6-2.i386.rpm
    Wrote: /usr/src/redhat/RPMS/i386/ldirectord-2.0.6-2.i386.rpm
    Wrote: /usr/src/redhat/RPMS/i386/stonith-2.0.6-2.i386.rpm
    Wrote: /usr/src/redhat/RPMS/i386/pils-2.0.6-2.i386.rpm
    Wrote: /usr/src/redhat/RPMS/i386/heartbeat-devel-2.0.6-2.i386.rpm
    Wrote: /usr/src/redhat/RPMS/i386/heartbeat-debuginfo-2.0.6-2.i386.rpm

rpms 都生出來了,那就…打完收工!

至於能不能用呢?……我也不知,下星期再找機器弄個環境來試看看……

喝啤酒先去…… :D

The Fedora Legacy Project
終於要說拜拜了:End of Life times for FC1, FC2, RHL7.3 and RHL9

With Fedora Core 6 Test 2 set to be released July 26th, it is time we announce the End of Life of our various Legacy supported releases.

After much discussion on fedora-legacy-list and the #fedora-legacy IRC channel on the freenode network, we have decided to end of life the following releases when FC6 Test2 is released: Fedora Core 1, Fedora Core 2. This will leave us with supporting just releases 3 and 4 of Fedora Core.

As to our Red Hat Linux releases (7.3 and 9) the following has been decided: New issues (bugs) will be accepted until October 1st of this year. No new bugs will be accepted after that mark. All existing bugs will be resolved to the best of our ability by December 31st of this year. What hasn’t been completed by then will not be completed by the Fedora Legacy project. This will be the end of Fedora Legacy’s support of the Red Hat Linux line of distributions.

所有免費的以 Red Hat 為名的 release,在今年 10 月 1 日之後發現的 bugs 就不管了。所有積存的 bugs 最多也會在今年 12 月 31 日前盡力解決,即使有來不及解決的,也一樣不會再繼續了。至此之後就不再受到 Fedora Legacy 計劃任何的更新支援了。

忽然想到,RH 7.3 似乎是生命週期最長的 release ……

好了,心裡掛了一陣的東西,總算動手了。剛終於下載了 FreeBSD 6.1 release 的 image (嗯? 5.5 也 release 了呀?!) ,燒了光碟,也在那台老 Pentium II 的 PC 上裝起來了……

安裝過程照老方式沒什麼大異,反正我都是習慣裝個 minimal 的環境,剩下就等 cvsup 後再視需要從 ports 安裝。依序裝好 cvsup-without-gui、bash,gnuls 後,再設定一下變環變數。現在就等 cvsup ports-supfile 和 stable-supfile,反正是 Pentium II ,也不期望能有多快,就放著,等明天再來 make world 囉。至於接下來會有什麼不同跟有趣的東西,就慢慢再來玩過了……

趁空檔記一下今天看到的一個新軟體的消息:Picasa for Linux 。從系統需求看到,原來是用 WINE 的方式,所以並不是原生的 Linux 程式。這樣子對 Google 來說當然是方便快捷多了,不過效能如何,目前也沒實機可下載來玩玩測測,只好等日後有機會再看囉……

不過,倒是在 Digg 的回應裡看到有人提供另一個同樣功能的東西:F-Spot ,稍微瀏覽一下網站的介紹,是 for GNOME Desktop 的,所以應該是 Linux 原生程式。功能看來也是非常完整的樣子(嘿…支援 Export to Flickr 呢),似乎更值得下載來和 Picasa 比較一番。記著囉……

[ via: Digg ]

Linux Distribution Chooser
現在的 Linux Distributions 真是多如牛毛,光看 DistroWatch 上所列出的就夠讓人眼花瞭亂的了,更何況恐怕還有許多沒列出來的……

所以常看到很多新接觸 Linux 的人在問:到底要選那個 Distribution 好?其實這問題還真沒個標準的答案,我通常是給「西瓜答案」 — 書店走一趟,那邊大就偎過去準沒錯。

其實,雖說不管任何 Distribution 的核心都是 Linux ,若當 Server,一進到 CLI 介面也真沒什麼差異。不過隨著在一般桌面環境的運用愈趨成熟,各家不管在管理工具、預裝的應用程式或使用者介面的包裝上,已可見越來越多的分化差異處。因此,還真有人弄出了這麼個工具出來:Linux Distribution Chooser

這是個 Web 介面的工具,只要跟著線上指示答完所有的問題,系統就會依據你的回答,挑選出比較合適你的 Linux Distributions 出來。對於新手來說,或多或少也可以是個參考的依據。

目前資料庫裡有這些 Distributions 可選: Fedora Core, Mandriva, SuSE, Debian, MEPIS, Ubuntu, Kubuntu, Linspire, Xandros, PCLinuxOS, Yellowdog Linux, Gentoo, Slackware, Knoppix, OpenSuSE, ArchLinux, Foresight Linux。至於測驗的語言介面則只有英文和挪威文二種,在網站上也正徵求可以幫忙翻譯其他語文介面的人。

我自己好奇的作了趟測試,結果出來的最佳選擇是:Kubuntu, Debian, Ubuntu, Fedora, SuSE 和 Mandriva。另外:Gentoo, Slackware 和 Arch Linux 則是部份合適。

呵…我還真是不挑嘴,目前所有的主流 Distributions 都列出來了嘛…… :)

Ubuntu Center
剛瞄到的新東西:Ubuntu Center Alpha 1 Released – Web Based Ubuntu Control

Ubuntu Center is a web based interface for accessing all kinds of information that’s being stored on your computer running Ubuntu Breezy, Kubuntu, XUbuntu, or even nUbuntu box. Ubuntu Center accomplishes all of this by integrating PHP software licensed under the GPL license in one giant package suitable for use on a Ubuntu computer. This release adds tons of new features and bug fixes and is suitable for everyday use.

稍微瀏覽了一下網站上的資訊,也登入 Demo 網站玩了一會。看起來應是整合了一些既有的 Open source 套件,像是線上管理撥放音樂的 Ampache 、圖檔管理的 phpAlbum 、行事曆的 WebCalendar 、線上書籤 online-bookmark 、torrent 下載的 TorrentFlux …等。

蠻有趣的整合運用,而且是個還在發展中的計劃,所以後續應該還會加上更多的功能模組才是。嗯,或許會演化成另外一個 Webmin?

另外,雖說名字叫 Ubuntu Center,不過我想在其他 Linux Distributions 上,應該也是可以安裝得起來 — 或許需要額外一些調整設定。有時間再下載來瞧瞧……

[ Via: digg ]

整理一下幾則這幾天看到的一些惡魔企鵝相關訊息:

  • FreeBSD

FreeBSD 6.1 已經 release 了呀。看來還是找個時間,正好把桌上那台老 Pentium II 機器拿來物盡其用一番好了。因為工作的關係,已是很久沒跟 FreeBSD 親近了,不曉得又多了那些變化不同處,該動手了……

  • Frenzy

至於這個 base on FreeBSD 的 Frenzy 倒是第一次聽聞,看了看官網上的介紹,原來是個管理用的 Live CD:

Frenzy is a “portable system administrator toolkit,” LiveCD based on FreeBSD. It generally contains software for hardware tests, file system check, security check and network setup and analysis. Size of ISO-image is 200 MBytes (3” CD)

  • Ubuntu

另外,Ubuntu 6.06 LTS (Long Term Support) 的 Flight 7 也 announce 了,離下個月的正式版本亦是不遠了。不過,現在恐怕分不出再多餘的時間安裝測試,看來還是等下個月的正式版本好了。反正放在另一顆硬碟的 5.10 系統暫時也還擱在背包裡,到時再決定升級或是什麼的。

又,在這裡發現個新版本的指南:Ubuntu Dapper Drake 6.06 Guide

  • Vim

天天會用到的 Vim (雖然只是用不到其中十分之一、二的功能)也出新版本了,新增了不少功能呢:spell checking、intelligent completion、tab pages、nternal grep……

不過,對 Vim 從很早印象蠻深刻的反倒是:有次無意間開啟程式時,注意到了主頁面上那句:”Help poor children in Uganda!”。然後在命令列打上:”help iccf” 就看到了更多的訊息:

Vim is Charityware. You can use and copy it as much as you like, but you are encouraged to make a donation for needy children in Uganda. Please see |kcc| below or visit the ICCF web site, available at these mirrors:
http://iccf-holland.org/
http://www.vim.org/iccf/
http://www.iccf.nl/

這次除了瀏覽 announcement 裡新增的功能外,忍不住還是刻意留心是否有 Uganda 這個字眼,果然就在 Credits 裡:

Also thanks to Vim sponsors who supported me while working on Vim 7. I am now going back to a paid job. Please continue sponsoring Vim. The money now goes to help children in Uganda. The more you help them the more I will feel obliged to work on Vim. There is a drought right now, we need to help 200 families with food. http://www.vim.org/sponsor/

my eclipse
最近有需要用 PHP 寫一些程式,於是趁這個機會剛好順便試試久仰大名的 Eclipse

在 ubuntu 上面,理所當然是直接用 apt-get 的方式安裝,由於從 3.01 以後已經是 building and running with GCJ ,所以整個安裝過程當然是沒什麼問題, apt-get 一次包到好……

執行起來一切正常,速度也還不錯,倒是 help ?功能完全不能使用,查了查 ubuntu wiki 才知道是因為 Tomcat 的關係: “The Help system has been disabled completely because we don’t yet have a free Tomcat. Working on that.”

要開發 PHP 的程式,當然還得再加裝 plugin 才行,問了下 Google 得知目前也只有 PHPEclipseTrustudio 這二個 PHP 用的外掛(Zend 據說有計劃,不過除了新聞消息倒是還沒看到有什麼東西)。於是照 PHPEclipse 的說明,利用 Eclipse 的 Software Updates 功能來直接安裝……

結果到這裡碰到第一個問題了:下載正常,但安裝時就會有錯誤訊息無法安裝。當然還是回 ubuntu 找解決方式:Getting Eclipse to work for updates 。終於讓 Eclipe + PHPEclipse 初步合體成功……

看起來一切都還蠻順利的,至於進一步的 DBG Debugger、SQL Plugin 的安裝設定,就等摸得比較熟悉後再來研究好了。至少現在已經有個非常不錯的 PHP IDE 可以上手了。

邊寫 PHP 邊熟悉 Eclipe 的環境時,突然想到何不再加上 CVS 的版本控制功能?雖說只是自己寫的幾支小程式,談不上是什麼專案,不過一來可以趁機會多玩點東西,二來也方便日後的程式碼查考。反正 CVS 的功能已經是內建的,何況還有更好用 subversion 和 subclipse plugin。

於是在 server 端設定好 subversion repository 後,再度使用 Software Updates 功能安裝好 subclipse 。開始準備從 server check out 程式碼出來時,第二個問題出現了:彈出個錯誤訊息視窗,然後整個 Eclipse 就蒸發了……

這可好了,幾番搜索 google 和 ubuntu 後還是沒有頭緒,我個人倒是猜想可能是 native GCJ 的關係。於是,根據這份指南,改用 Sun 的 SDK 測試看看,果然一切正常無誤!

不過,這會又有個小問題產生了:我的 Ctrl+Space 鍵切換中英文輸入的功能竟然失效了?!當然,我知道這組功能鍵是 Eclipse 內建的 Content Assist ,雖說我還是可以利用 gcin 的控制台調開這組切換鍵,但,用了十幾年的習慣,實在很難改的呀……

想了想,最後終於決定索性換成 Sun 的 SDK 和 Eclipse tar ball 的方式來安裝好了……

終於,Eclipse 與我正快樂的相處中…… :D

又,二個小插曲:

  • subclipse 在目前的版本 0.9.37 中加入了中文訊息檔。當然,對我這種習慣英文介面的使用者來說應該是沒什麼差別的。除了……它竟然真的依我的 LC_CTYPE 環境變數自動選擇,而且,更傷腦筋的是我實在非常不習慣「簡體」中文。在找不到任何可切換的設定選項後,只好勞煩自己動手從 jar 檔裡移除訊息檔。看來,subclipse 的開發者還不清楚中文是有分簡瀪體的……
  • 由於我在自己的工作 notebook 上並未安裝 apache ,所以程式的測試都是直接在 server 端上。現在用了 subversion 管理就得額外用點技巧 — subversion 的 faq: website auto update

最近正在研究一下 snort 的東西,說實在的,這種硬梆梆的技術文件啃多了也是有點累的……

不過,今天在看到 CVS 上 signatures 的一個文件檔 (1000.txt) 時,卻忍不住狂笑起來……

這是 revision 1.1 的 comment:

docs docs docs, smoking docs, smoking docs, doing docs, drinking docs.

Pack-a-docs my brother man. Time to kick back, drink some docs and smoke some docs.

這是 revision 1.2 :

What do you think is more exciting, having sex or writing docs?

Having sex or writing docs..uhm..whoo.. Well, how about having sex while writing docs?

That’s a good line. Doesn’t work on a lot of girls though.

哈哈哈哈哈………

咦?原來還有這個活動呀?

所以,這次選拔最後的結果終於揭曉了 (Final result for the FreeBSD logo design competition):

FreeBSD new logo

好吧,如果以後真正式換成了這個新 logo ,的確是漂亮得沒話說。不過,我想我還是會很想念小惡魔的……

Ubuntu 正式推出 5.10 Server 版,這也是 Ubuntu 第一次推出專為 Server 環境使用的版本。

從 announcement 簡單的介紹中可以看到,就如同 desktop 版一樣,只用了一張光碟的容量。

不過,作為強調 server 的版本,自然會有跟 desktop 版不同的一些特點:像是預設即為精簡安裝,只占 400 MB 左右的空間、server-oriented kernel 且完全自動支援多處理器、不提供任何 Xwindow 的桌面環境 (GNOME, kDE 等)、文式介面的開機模式…等。

另外,既然是專為 server 環境設計的,安全自是第一考量。所以在安裝完成開機後完全不開啟任何網路 ports,並立即啟動進行免費的安全更新。而任何網路相關服務也只有在確切的安裝設定後才執行啟用。

[ 詳細的 release note ]

另外,這裡也有一篇非常詳盡的 Ubuntu server 設定的技術文件:”ISP-Server Setup – Ubuntu 5.10 Breezy Badger

Previous