2012年2月16日 星期四

iscsi ietd for ubuntu

http://manpages.ubuntu.com/manpages/hardy/man5/ietd.conf.5.html

# apt-get install iscsitarget
# mkdir data
# dd if=/dev/zero of=/data/iscsi bs=1M count=256
# vi /etc/ietd.conf
Target iqn.2-11-09.org.weithenn:iscsi-ha
Lun 0 Path=/data/iscsi,Type=fileio
# /etc/init.d/iscsitarget start

connect this service from Windows 7 with "iscsi initiator"

2012年2月5日 星期日

cacti: poller table and runtime problem.

http://forums.cacti.net/about29135.html
http://forums.cacti.net/about25765.html
http://www.cacti.net/downloads/docs/html/cli_poller_output_empty.html

1. Change Cacti log level to HIGH, or DEBUG.
2. run `php -q poller_output_empty.php`.
3. If the table problem solves, RRD should be processed normaly which shows GREEN in log.

2012年2月3日 星期五

one-way sync backup with unison

http://superuser.com/questions/97497/one-way-syncing-backup-with-unison

unison /folder1/ /folder2/ -silent -force /folder1/

2012年2月1日 星期三

java chinese fonts

http://hugedream.blogspot.com/2009/09/java.html


# cd /usr/lib/jvm/java-6-sun/jre/lib/fonts/
# mkdir fallback
# cd fallback
# ln -s /usr/share/fonts/truetype/arphic/uming.ttc .

2012年1月29日 星期日

iptables -d -D for destination / delete

http://phorum.study-area.org/index.php?topic=22912.0
http://www.linuxquestions.org/questions/linux-networking-3/iptables-to-destination-muliple-ip-port-43946/


iptables -D INPUT x <------ x=該行的line-number
如何知道line-number的值 ----> iptables -nL --line-numbers

2012年1月28日 星期六

port 6010 listening...


FreeBSD-Security: RE: sshd listening on port 6010

www.derkeiler.com › ... › 2001-03 - 頁庫存檔 - 翻譯這個網頁
5 Mar 2001 – Just disable X11 forwarding if you dont want it. ... 

2012年1月25日 星期三

rpm -qs = dpkg -S


Search for the package containing a specific file.

rpm -qs = dpkg -S

2012年1月24日 星期二

java plugin for firefox on Linux

http://java.com/zh_TW/download/help/linux_install.xml

0. check firefox url -- about:plugins.
1. install java from java.com
2. soft link the libnpjp2.so to firefox plugins folder, e.g. /usr/lib/mozilla/plugins.
$ sudo ln -s /usr/local/jre1.6.0_30/lib/i386/libnpjp2.so .
3. restart firefox, and everything's done!!

2012年1月22日 星期日

cacti: fix rrd update problem

http://www.cacti.net/downloads/docs/html/scripts.html

if rrd stops updating, then:

1. create new data sources to replace the old ones from graphs, then delete the old rrd files.
2. restart httpd, and run cli/ scripts to poller_output_empty or rebuild_pollor_cache.
3. reduce system usage by adjusting polling interval in cron and settings, from 1min to 5min.
4. disable unused data sources to lower system usage.
5. check cacti log in utilities to make sure everything is green!!

drupal: usingdrupal source code

http://usingdrupal.com/source_code


Important Note! The source code we are providing here is only for use with the Drupal 6 version of the book. The source code for the Drupal 7 version (now in Rough Cuts) will not be available until the book is complete.

2012年1月18日 星期三

drupal: warning: array_merge()

http://drupal.org/node/791118


@giozzz, the same thing applies to you, this probably only occurs with certain nodes. Could you check the node and make sure that all the files actually exist (in the database "files" table) when viewing/editing those nodes?
Thanks for your response, I've checked right now, and it was one picture missing in the ddblock I have on front page. Sorry for bothering you for nothing and thanks again!

2012年1月17日 星期二

drupal: hide login menu

http://drupal.org/node/98617


Go to administer -> blocks then disable User Login block you can still access it bywww.your_domain.com/?q=user/login (if don't have clean urls) orwww.your_domain.com/user/login

drupal: 隱藏作者、時間欄位

http://drupaltaiwan.org/forum/20070828/1481

在版型設定 > 整體設定 裡頭,「顯示文章的張貼資訊」中就可以調整
圖示的話是在左邊

drupal: Flashvideo fix

http://www.comptoncoms.com/wordpress/2011/04/drupal-flashvideo-fix-april-2011/


FFmpeg has been versioning just as Drupal has, so the default command in the Flashvideo > Content Type Setting > FFMPEG settings is likely wrong. If you are using a recent version of FFmpeg you may need to change the command line to replace “mp3” with “libmp3lame”. At any rate you will need to understand the commands for FFmpeg to make the conversion do what you want.
Content type is the second problem. In the original any number of videos could be placed on the node to include the original video and the converted flash version. But that process no longer seems to work. The original upload video content type needs to have under the “display fields “ the type excluded.
Last is the player problem. The whole time that Flashvideo has been versioning, the media player has been drastically changing as well. With a whole lot of work you can get the original Flowplayer to work with Flashvideo, but then you will not have the poster image only a black screen. Even worse is that if you turn on Jquery with SWF Tools, your Views module no longer works. So I strongly recommend the JW_player. You will need to install the jwplayermodule, but it is worth the effort and the added cost. The player retails for $89. With JWplayer 5.5 you can insert video into any content type. The instructions are in a PDF for Drupal with the download. It is a very nifty solution that uses file attachment. After you have installed the JWplayer module you will need to put a copy of player.swf from the JWplayer directory into the directory where the videos are output and rename it “Player.swf”.