今天要重灌hadoop碰到舊資料沒刪乾淨導致裝不起來的問題
寫了一個for i in {1..4}; do ssh "root@host-0$i" ...來刪東西
被ricky哥發現我的蠢樣後建議我用pdsh
經高人指點迅速裝完
1. download
http://sourceforge.net/projects/pdsh/
2.tar jxvf pdsh.xxx.tar.bz2
[under pdsh folder]
3. ./configure --with-ssh (我跟default的rsh不認識XD)
4. make
5. make install
done
測試一下
pdsh -R ssh -w host-[01-04] hostname
不錯
再試
pdsh -R ssh -w host-[01-04] ls -al /usr/lib | grep hadoop
咦?馬上吃屎...沒有pipe還叫做shell script嗎!?
馬上谷歌結果發現另一套
ssssh,擺明就是要解決pipe問題XD
https://code.google.com/p/ssssh/wiki/Details
這套安裝更簡單了
make install大功告成
ssssh -N -w host-01,host-02,host-03,host-04 ls -al /usr/lib |grep hadoop
帥啊老皮
不過這套似乎不支援串hostname號碼
只好動點髒手腳
alias dsh="ssssh -N -w host-01,host-02,host-03,host-04"
這樣的好處是可以搭配-x(exclude) and -w(include)使用
dsh -x host-01 hostname
[2013-03-26 updated]
pdsh用"把command刮起來就行了,但總覺得多一動就是麻煩XD
總網頁瀏覽量
2013年3月25日 星期一
2013年3月21日 星期四
2013年3月16日 星期六
mkv播放沒有字幕的問題
明明就註明內嵌多國語言字幕
但是用MPC偏偏字幕選項都是灰色的
[解]
http://www.myav.com.tw/bbs/showthread.php?threadid=362996&pagenumber=0
原來影片也有大哉問阿
總之,output改一下就可以看了
但是用MPC偏偏字幕選項都是灰色的
[解]
http://www.myav.com.tw/bbs/showthread.php?threadid=362996&pagenumber=0
原來影片也有大哉問阿
總之,output改一下就可以看了
2013年2月17日 星期日
[微食記] 中山站長鼻子大象
2013年2月5日 星期二
台北天母--溫德德式烘培餐館 [差est]
本來要帶女朋友去這裡過生日的,
聽說德國豬腳相當不錯,股哥也是這麼跟我說的。
兩三個禮拜前去電定位,
當天中午又再打過去確定一次,
結果到現場興高采烈要點餐
服務生:不好意思,德國豬腳要先預訂喔
我OS:叉叉的咧,定位的時候沒說阿,我先知什麼都知道逆?
我真的不懂要預訂才吃得到的東西,當初定位時為什麼沒告知,這邏輯在哪阿???
當天領班也只會道歉說要介紹別的餐點,
真的只能用掉漆來形容~.~
聽說德國豬腳相當不錯,股哥也是這麼跟我說的。
兩三個禮拜前去電定位,
當天中午又再打過去確定一次,
結果到現場興高采烈要點餐
服務生:不好意思,德國豬腳要先預訂喔
我OS:叉叉的咧,定位的時候沒說阿,我先知什麼都知道逆?
我真的不懂要預訂才吃得到的東西,當初定位時為什麼沒告知,這邏輯在哪阿???
當天領班也只會道歉說要介紹別的餐點,
真的只能用掉漆來形容~.~
2013年1月20日 星期日
VM copied lead to network unreachable (centos)
When you copied a CentOS VM and boot it up,
after command in ifconfig
You'll found the your ethernet is not working.
and if you try to bring it up,
service network restart
response will be like below...
device eth0 does not seem to be present delaying initialization
The solution:
1. ifconfig -a
2. record your new MAC ADDRESS
(since you copied the vm, macaddr would not be the same with origin one.)
3. vim /etc/udev/rules.d/70-persistent-net.rules
4. modify the ATTR{address} to the recorded one in eth* which you're using
5. vim /etc/sysconfig/network-scripts/ifcfg-eth*
6. modify the HWADDR to the recorded one
7. service network restart
after command in ifconfig
You'll found the your ethernet is not working.
and if you try to bring it up,
service network restart
response will be like below...
device eth0 does not seem to be present delaying initialization
The solution:
1. ifconfig -a
2. record your new MAC ADDRESS
(since you copied the vm, macaddr would not be the same with origin one.)
3. vim /etc/udev/rules.d/70-persistent-net.rules
4. modify the ATTR{address} to the recorded one in eth* which you're using
5. vim /etc/sysconfig/network-scripts/ifcfg-eth*
6. modify the HWADDR to the recorded one
7. service network restart
訂閱:
文章 (Atom)