2010-04-14
2009-11-16
Installing XP: ***STOP: 0x0000007B (0xF78D2524,0xC0000034,0x00000000,0x00000000)
Platform: Lenovo SL400 (2743-RK3)
When installing Windows XP, during the booting procedure, it shows up the BSOD screen, "Installing XP: ***STOP: 0x0000007B (0xF78D2524,0xC0000034,0x00000000,0x00000000)". After run the complete memtest86+, it occurs again.
The solution is here, disable HD drive from ACHI to Compatibility.
When installing Windows XP, during the booting procedure, it shows up the BSOD screen, "Installing XP: ***STOP: 0x0000007B (0xF78D2524,0xC0000034,0x00000000,0x00000000)". After run the complete memtest86+, it occurs again.
The solution is here, disable HD drive from ACHI to Compatibility.
2009-08-04
Converting integer to string in ANSI C
const char *base = "BLAH BLAH BLAH";
unsigned int idx = 0;
char *buf = NULL;
buf = (char *) malloc (strlen (base) + sizeof (unsigned int));
sprintf (buf, "%s%d", buf, idx);
printf ("buf: %s\n", buf);
Output
BLAH BLAH BLAH0
2009-05-29
Compaq CQ60-201AU downgrade
First ball, thanks to Compaq Presario CQ60-104AU/ CQ60-210AU 改 XP takes me many hints, and special thanks to Conexant High Definition SmartAudio 221 probbblemmmm!(WİNDOWS XP DRİVERS=), they were just discussing the audio driver.
This downgrade makes me understand that, some vendors combine some components of their product whole only supports vista drivers, it's really sucks. Fortunately, many geeks turn it works fine. So we can search their great solution and study its experiences.
This downgrade makes me understand that, some vendors combine some components of their product whole only supports vista drivers, it's really sucks. Fortunately, many geeks turn it works fine. So we can search their great solution and study its experiences.
2009-05-22
Why was your message broken?
I like send messages rather than dialing to communicate wtih my cellphone. As using so far, I have a big problem in my mind, that, why was messages broken when it was enough long to send? I had asked my service provider CHT, the service-person told me that caused by my OLD-SYLTE-PHONE, it is never happen with newer phone. I did not believe that anyhow. Until today morning, I have read a article on OSNEW.com, Why Text Messages Are Limited to 160 Characters, that pushes me to find something more out.
My Nokia 1650 cellphone supports SMS, EMS and Instant Messaging, spec page said that supports length up to 250 characters, not as long as wikipedia SMS page said, 160 characters.
I have not yet find anything solves it problem to normal message.
My Nokia 1650 cellphone supports SMS, EMS and Instant Messaging, spec page said that supports length up to 250 characters, not as long as wikipedia SMS page said, 160 characters.
I have not yet find anything solves it problem to normal message.
2009-05-21
Abortion
Anyone has this information who has mentioned "abortion". :P
glibc 25.6.4 Aborting a Program
Explanation: Re: Federal censorship regulations
The warning may be tongue in cheek. Anyone living in the US is
aware of the extreme sensitivity of the abortion issue (as it
applies to human foetuses, not computer programs).
Allin Cottrell.
glibc 25.6.4 Aborting a Program
Future Change Warning: Proposed Federal censorship regulations may prohibit us from giving you information about the possibility of calling this function. We would be required to say that this is not an acceptable way of terminating a program. |
Explanation: Re: Federal censorship regulations
The warning may be tongue in cheek. Anyone living in the US is
aware of the extreme sensitivity of the abortion issue (as it
applies to human foetuses, not computer programs).
Allin Cottrell.
2009-02-27
Compilin SQLite from source code
This article is describe how to compile SQLite 3 from its source code scratch.
Steps
1. Setting current path as $TOP variable.
2. Getting source code tarball from official web site, and save it to $TOP.
3. Extracting
4. Detecting something in system environment.
5. Executing make if previous step successful. Doing debug with err.txt if errors occurs during makeing.
6. Installing files to system (/usr/local/), need root permission.
Steps
1. Setting current path as $TOP variable.
export TOP=`pwd`2. Getting source code tarball from official web site, and save it to $TOP.
wget http://www.sqlite.org/sqlite-3.6.11.tar.gz -O $TOP/sqlite-3.6.11.tar.gz3. Extracting
cd $TOP; gzip -dc sqlite-3.6.11.tar.gz | tar -xf - ; cd sqlite-3.6.114. Detecting something in system environment.
./configure5. Executing make if previous step successful. Doing debug with err.txt if errors occurs during makeing.
make 1> /dev/null 2> err.txt6. Installing files to system (/usr/local/), need root permission.
# make install
2009-02-13
tmux - terminal multiplexer
Install steps
1. Downloading all packages, assume you're in bash shell.
2. Unpacking and patch, then compie it.
3. Tuning it
.tmux.conf
# For 0.7
.bashrc
Drawbacks
under testing...
Really runs faster than GNU Screen!!
References
OSNews, Stayin' Alive with GNU Screen, http://osnews.com/comments/20962
mentors.debian.net, http://mentors.debian.net/debian/pool/main/t/tmux/
1. Downloading all packages, assume you're in bash shell.
wget -c http://mentors.debian.net/debian/pool/main/t/tmux/tmux_0.5{-1.d{iff.gz,sc},.orig.tar.gz}2. Unpacking and patch, then compie it.
$ gzip -d tmux_0.5-1.diff.gz
$ tar -zxf tmux_0.5.orig.tar.gz; cd tmux-0.5
$ patch -Np1 < ../tmux_0.5-1.diff
# make 1> /dev/null 2> err.txt && make install
3. Tuning it
.tmux.conf
set prefix ^\
set status on
set status-bg yellow
set status-fg block
set status-right " "
# For 0.7
unbind ^b
set -g prefix ^\
send-prefix
set -g status on
set -g status-bg yellow
set -g status-fg black
set -g utf8 off
.bashrc
alias t='tmux attach -d'
Drawbacks
under testing...
Really runs faster than GNU Screen!!
References
OSNews, Stayin' Alive with GNU Screen, http://osnews.com/comments/20962
mentors.debian.net, http://mentors.debian.net/debian/pool/main/t/tmux/
2009-02-12
SSH Tunnel memo
ssh -CND ${OUTDOOR_PORT} ${USER}@${REMOTE_SERVER}Specifies a port ${OUTDOOR_PORT} forwarding (-D) to ${REMOTE_SERVER} with ${USER}, that without executing the remote commands (-N), and requests all data compressed (-C).
Firefox
Changing its SOCKS Host to localhost and Port to ${OUTDOOR_PORT}.
Opera
Installing the tsocks, do manipulate with links article.
References:
1. code in the ruins, Opera 9/SOCKS hack, http://code.mogrify.org/2006/07/05/opera-9socks-hack/
2. polishlinux.org, SSH Tunnels: Bypass (Almost) Any Firewall, http://polishlinux.org/apps/ssh-tunneling-to-bypass-corporate-firewalls/
2009-01-01
Why didn't Plan 9 take over the world?
Plan 9: The Way the Future Was
Reasons:
*scanty documentation, much confusion and stumbling over fees and licensing.
* In 2003 it looks like Plan 9 failed simply because it fell short of being a compelling enough improvement on Unix to displace its ancestor.
* Some Plan 9 ideas have been absorbed into modern Unixes, particularly the more innovative open-source versions. FreeBSD has a /proc file system modeled exactly on that of Plan 9 that can be used to query or control running processes.
* Experimental 2003 versions of Linux are implementing per-process mount points, a long step toward Plan 9's private namespaces.
* The various open-source Unixes are all moving toward systemwide support for UTF-8, an encoding actually invented for Plan 9.
Conclusion:
Plan 9 is not good enough to take over to the various unix world.
Reasons:
*scanty documentation, much confusion and stumbling over fees and licensing.
* In 2003 it looks like Plan 9 failed simply because it fell short of being a compelling enough improvement on Unix to displace its ancestor.
* Some Plan 9 ideas have been absorbed into modern Unixes, particularly the more innovative open-source versions. FreeBSD has a /proc file system modeled exactly on that of Plan 9 that can be used to query or control running processes.
* Experimental 2003 versions of Linux are implementing per-process mount points, a long step toward Plan 9's private namespaces.
* The various open-source Unixes are all moving toward systemwide support for UTF-8, an encoding actually invented for Plan 9.
Conclusion:
Plan 9 is not good enough to take over to the various unix world.
2008-10-18
Modulus accepts floating type ?
Honda asks me a statement about C++ as like below:
First ball, there is a statement error, "2" is a integer data-type, and b is a lvalue expression as a floating type, so that they doesn't match in type manner. The line sould be modify to this:
Second, modulus (%) only accept the integral computing, refer from the C++ Standard draft, Sec. 5.6, p. 124.
The conclusion is, modulus doesn't accept the floating data.
The next question is, how to get the remainder as like the modulus does?
float a, b;
a = 10.5;
b = a % 2;
First ball, there is a statement error, "2" is a integer data-type, and b is a lvalue expression as a floating type, so that they doesn't match in type manner. The line sould be modify to this:
b = a % 2.0f;
Second, modulus (%) only accept the integral computing, refer from the C++ Standard draft, Sec. 5.6, p. 124.
The conclusion is, modulus doesn't accept the floating data.
The next question is, how to get the remainder as like the modulus does?
2008-06-14
2008-02-03
2008-02-01
2007-12-06
SPARC: What to Do if You Forgot Root Password
SPARC: What to Do if You Forgot Root Password
(Use keyboard abort sequence--Press Stop A keys to stop the system)
ok boot net -s
# mount /dev/dsk/c0t3d0s0 /a
# cd /a/etc
# TERM=vt100
# export TERM
# vi shadow
(Remove root's encrypted password string)
# cd /
# umount /a
# init 6
2007-12-05
Quota setting of Linux & BSD
這四天連續看了 Linux 和 FreeBSD 的手冊,設定 quota,今晚的進度即將邁入 Solaris;都是為了推廣系上得 Unix-account Service,所以需要給每位使用者 quota limit。以下寫下個別的心得。
對於 Linux,是我最熟悉的系統,之前有設定過一次,可是出現錯誤,當下沒有立即排除,造成這次閱讀的時候釐清了一些原本誤解的觀念。例如,Quota 是 kernel mode 的功能,我有一種感覺一直以為要 dependence on HW;要怎樣的 quota limit 就得割一個 partition 給設定檔,一時腦筋轉不過來。既然都是軟體實做了,這些硬體的問題都會克服的。
接著,Venus 是跑 GNU/Debian Linux,大約花了三個小時設定,釐清觀念,事後很開心,翻起 FreeBSD Handbook 接著看。
FreeBSD 是 CoreDure Quad 的壯壯機,fBSD 對於我來說是個新系統,先前的成功經驗,加上對 fBSD 的新鮮感,所以猛看手冊。上次的進度停留在 Ch.4,今天大約花了五個小時,一直看到完。我沒那麼神,中間有些東西我不感興趣,例如 printer setting 還有 networking setting,所以就 skip into next lol。早上開始逐章讀,興致全開,竟然編起 FreeBSD Kernel,我真的很開心,因為學到不少新東西。之前見到 afoofa 說 Linux 的 make menuconfig is such friendy to her, but the interface FreeBSD is a little bit bored and monolithic. 但是我反而覺得 Handbook 教的很詳細,我很感謝 maintainer 把文件寫的那麼清楚,一一介紹,讓我觀念清楚明瞭,可以放心地跟著進度走。
今天編 kernel 都沒有 booting failure,真開心。不過還沒很確定是否要這麼做 make clean cleandepend depend buildkernel installkernel,前面三個步驟是我比較不清楚的。Durning making the source tree, I've found a interesting function, had before in Linux, that is -j, menas make "make" to does something in parallel. And my best argument is "16", not "32". It earns more and more time-saving and performance.
中午吃完飯,一度沉迷在 SMP 的 option。先說的,這篇 Installing the FreeBSD SMP Kernel 已經過期了,裡面的
接著,我又病發了,開始找 SMP 的實做時比較早,心中一直有個感覺,逐漸推翻 FreeBSD 優於 Linux 的看法。Linux 很多人送 code & patch,FreeBSD 則是人數沒有那麼多,而且 Linux 有不少商業公司背書,燒錢改善 Linux。不過,現在下定論還太早,因為各有可取之處。謂之:「量才適性,學而不倦」。
我現在找到最早的 Linux SMP 是 2.0 加入的,1996。而 FreeBSD 是 5.0, in 2003 推出。不過,我也有看見 1986 就在寫的,不知道正確與否。
後來,有個疑問:如果 OS kernel has no SMP supports, can program run as parallel, as like MP? 後來想到,如果 OS 沒有 SMP,四隻 folding@home process 會平分一個 CPU 資源,而有 SMP 的話,每隻都是跑到 99.8% 左右。哈哈~ 可是這又不是純 MP,如果用 icc 編的話,應該也會得到同樣的結果。
好奇 kernel 怎麼知道是 SMP-type cpu,用 asm does detect?
另一支 BSD Family 就是 Solaris,我一直覺得上面的 utilities 功能都不健全,Linux 算是最健全的,fBSD 其次,Solaris 最少。我看,說不定 AIX, IRIX, HP-UP 更少呢~ 可是,也必須承認,因為硬體特性的關係,這些大廠都寫了很多東西支援,是一般 i386 OS (Linux, fBSD) 不會去實做的。
光是 Solaris 要設定 quota 的手冊就翻了兩本,因為要 refer,加上我也對它不熟,所以今天眼睛累,手指也酸了,就先暫擱吧。
對於 Linux,是我最熟悉的系統,之前有設定過一次,可是出現錯誤,當下沒有立即排除,造成這次閱讀的時候釐清了一些原本誤解的觀念。例如,Quota 是 kernel mode 的功能,我有一種感覺一直以為要 dependence on HW;要怎樣的 quota limit 就得割一個 partition 給設定檔,一時腦筋轉不過來。既然都是軟體實做了,這些硬體的問題都會克服的。
接著,Venus 是跑 GNU/Debian Linux,大約花了三個小時設定,釐清觀念,事後很開心,翻起 FreeBSD Handbook 接著看。
FreeBSD 是 CoreDure Quad 的壯壯機,fBSD 對於我來說是個新系統,先前的成功經驗,加上對 fBSD 的新鮮感,所以猛看手冊。上次的進度停留在 Ch.4,今天大約花了五個小時,一直看到完。我沒那麼神,中間有些東西我不感興趣,例如 printer setting 還有 networking setting,所以就 skip into next lol。早上開始逐章讀,興致全開,竟然編起 FreeBSD Kernel,我真的很開心,因為學到不少新東西。之前見到 afoofa 說 Linux 的 make menuconfig is such friendy to her, but the interface FreeBSD is a little bit bored and monolithic. 但是我反而覺得 Handbook 教的很詳細,我很感謝 maintainer 把文件寫的那麼清楚,一一介紹,讓我觀念清楚明瞭,可以放心地跟著進度走。
今天編 kernel 都沒有 booting failure,真開心。不過還沒很確定是否要這麼做 make clean cleandepend depend buildkernel installkernel,前面三個步驟是我比較不清楚的。Durning making the source tree, I've found a interesting function, had before in Linux, that is -j, menas make "make" to does something in parallel. And my best argument is "16", not "32". It earns more and more time-saving and performance.
中午吃完飯,一度沉迷在 SMP 的 option。先說的,這篇 Installing the FreeBSD SMP Kernel 已經過期了,裡面的
APIC_IO, NCPU, NBUS, NAPIC 都已經在 6.2 kernel 失效了,只需要指定 SMP 就行了。接著,我又病發了,開始找 SMP 的實做時比較早,心中一直有個感覺,逐漸推翻 FreeBSD 優於 Linux 的看法。Linux 很多人送 code & patch,FreeBSD 則是人數沒有那麼多,而且 Linux 有不少商業公司背書,燒錢改善 Linux。不過,現在下定論還太早,因為各有可取之處。謂之:「量才適性,學而不倦」。
我現在找到最早的 Linux SMP 是 2.0 加入的,1996。而 FreeBSD 是 5.0, in 2003 推出。不過,我也有看見 1986 就在寫的,不知道正確與否。
後來,有個疑問:如果 OS kernel has no SMP supports, can program run as parallel, as like MP? 後來想到,如果 OS 沒有 SMP,四隻 folding@home process 會平分一個 CPU 資源,而有 SMP 的話,每隻都是跑到 99.8% 左右。哈哈~ 可是這又不是純 MP,如果用 icc 編的話,應該也會得到同樣的結果。
好奇 kernel 怎麼知道是 SMP-type cpu,用 asm does detect?
另一支 BSD Family 就是 Solaris,我一直覺得上面的 utilities 功能都不健全,Linux 算是最健全的,fBSD 其次,Solaris 最少。我看,說不定 AIX, IRIX, HP-UP 更少呢~ 可是,也必須承認,因為硬體特性的關係,這些大廠都寫了很多東西支援,是一般 i386 OS (Linux, fBSD) 不會去實做的。
光是 Solaris 要設定 quota 的手冊就翻了兩本,因為要 refer,加上我也對它不熟,所以今天眼睛累,手指也酸了,就先暫擱吧。
2007-10-22
Howto: Use tar command through network over ssh session
Howto: Use tar command through network over ssh session
tar cf - /foo1 | ssh ffoo@192.168.1.201 "cat > /backup/wwwdata.tar.gz"
2007-10-15
2007-09-24
Ptt 的功能未來可能性
Why Use Parallel Computing?
*Other reasons might include:
**Overcoming memory constraints - single computers have very finite memory resources. For large problems, using the memories of multiple computers may overcome this obstacle.
用 MPI 實做應該可行,不用特地買一台 20,000 NT 的 quad cores 機器。
*Other reasons might include:
**Overcoming memory constraints - single computers have very finite memory resources. For large problems, using the memories of multiple computers may overcome this obstacle.
用 MPI 實做應該可行,不用特地買一台 20,000 NT 的 quad cores 機器。
訂閱:
文章 (Atom)