Amazon EC2 ~ vsftp can't connect

因為amazon的防火牆擋住了port 21

去NETWORK & SECURITY的Security Groups

在底下Inbound

Custom TCP rule

Port range輸入21

再Add Rule

再Apply Rule Changes


reference
http://maxivak.com/setting-up-ftp-server-on-ubuntu-%E2%80%93-amazon-ec2/

Ubuntu ~ install LAMP


sudo apt-get install tasksel

sudo tasksel

select LAMP server

and install


reference
http://www.unixmen.com/install-lamp-with-1-command-in-ubuntu-1010-maverick-meerkat/

Ubuntu ~ remove php

sudo apt-get -y purge php*

reference
http://askubuntu.com/questions/59886/how-to-compelety-remove-php

Ubuntu ~ enable apache mod_rewrite

sudo a2enmod rewrite

然後再restart apache

sudo /etc/init.d/apache2 restart

reference
http://thinkdiff.net/ubuntu-linux/ubuntu-enable-mod_rewrite-in-apache-server/

vi command

以下是我今天用vi使用到的指令.......

會這三招應該簡單的修改都可以辦到了XD


i為進入編輯模式

按Esc打:w為儲存

按Esc打:q!為離開


http://www.washington.edu/computing/unix/vi.html

FileZilla ~ 伺服器以無法路由的 IP Address 送出了被動式回應. 改為使用伺服器 IP Address.

指令: PASV
回應: 227 Entering Passiv Mode (192,168,0,101,8,4)
狀態: 伺服器以無法路由的 IP Address 送出了被動式回應. 改為使用伺服器 IP Address.
指令: LIST
回應: 150 Data connection created for directory listing
錯誤: 連線逾時
錯誤: 無法取得目錄列表

 是FileZilla 設定上出了問題

按照以下步驟

編輯-> 設定 -> 連線 -> FTP -> 被動模式 -> 回覆主動模式

即可取得目錄列表


source
http://blog.xuite.net/ha126269/94113267/43020801

Ubuntu ~ list folder files command

ls - list

reference
http://manpages.ubuntu.com/manpages/lucid/man1/ls.1.html

3dsmax ~ export ASE

http://q3a.ath.cx/level_design/aseexport/

yii ~ findAll example

$model=Auction::model()->findAll(array(
'condition'=>'status=:status AND starttime >= :date',
'params'=>array(':status'=>1, ':date'=>$date),
));


reference
http://stackoverflow.com/questions/7314284/yii-findbyattributes-with-greater-than-attribute

jQuery ~ move element

$("#source").appendTo("#destination");


reference
http://stackoverflow.com/questions/1279957/how-to-move-an-element-into-another-element