busybox-1.01/networking/libiproute/libiproute.a(iptunnel.o):iptunnel.c:(.text+0x574): more undefined references to `__cpu_to_be16′ follow在 Google 大神指示下找到一篇答案 修改 networking/libiproute/iptunnel.c
#include# 後面加上 #include
介紹一堆美食日記,生活日記,電腦筆記
busybox-1.01/networking/libiproute/libiproute.a(iptunnel.o):iptunnel.c:(.text+0x574): more undefined references to `__cpu_to_be16′ follow在 Google 大神指示下找到一篇答案 修改 networking/libiproute/iptunnel.c
#include# 後面加上 #include
# 安裝 Ruby 環境 $ sudo apt-get install ruby $ sudo apt-get install rake $ sudo apt-get install rubygemsRuby 的安裝只需要一行指令
gem install sass另外也可以透過 git 方式來安裝
git clone git://github.com/nex3/sass.git cd sass rake install安裝好就會 bin 目錄多出了 sass sass-convert scss 3個指令,如何轉換呢?也相當容易
mv style.css style.scss sass --watch style.scss:style.cssstyle.scss 是您寫的 SASS CSS 檔案 style.css 是您要輸出的檔案名稱 至於如何撰寫 Sass 語法,就請大家參考線上手冊,文件非常清楚,相信很容易看的懂
error: Untracked working tree file ‘XXXXXXXX’ would be overwritten by merge.這是因為當你 git rm –cached 檔案之後,切換 branch 時候會遇到衝突,本來的 master 分支還是存在這些檔案阿,因此這時候就要靠 git clean 來清掉移除檔案,可以利用 git help clean 來查看使用手冊。 Ref: Force git to overwrite local files on pull.
1. 先設定檔案權限,請將檔案權限改成 400 chmod 400 mykey.pem 2. 透過 ssh 軟體 pietty (上面阿正老師連結有教學)或 Linux ssh 指令 ssh -i mykey.pem ec2-user@ec2-XXXXXX.compute-1.amazonaws.com進去主機之後就是一般的 Linux 操作,可以參考 鳥哥的Linux 私房菜,當然我想玩家們都會發現一直透過 mykey.pem 登入會有點麻煩,而且假設 pem 檔案消失,又要去 Console 申請一次,所以底下教大家如何不必透過 mykey.pem 方式登入,其實也很容易,就是修改 /etc/ssh/sshd_config。
1. 打開 /etc/ssh/sshd_config 找到 PasswordAuthentication PasswordAuthentication no 改成 PasswordAuthentication yes 2. 存檔後,重新啟動 sshd /etc/init.d/sshd restart上述設定完成之後,就可以直接透過 ssh -l ec2-user xxx.xxx.xxx.xxx 的方式來遠端 Linux 主機,透過 yum 繼續安裝 Apache + MySQL + PHP,方法如下:
yum groupinstall "Web Server" yum groupinstall "MySQL Database"最後請參考計算 Amazon 每個月所需費用,不要傷了自己的荷包 XD,Micro Instance 的方案規格就很足夠我用
613 MB memory Up to 2 EC2 Compute Units (for short periodic bursts) EBS storage only 32-bit or 64-bit platform I/O Performance: Low API name: t1.micro
Severity: Notice Message: Trying to get property of non-object Filename: controllers/google_url.php Line Number: 24之後我在 Windows 利用 Appserv 架設好這環境,發現是同樣問題,但是在 FreeBSD 跟 Ubuntu 上面都不會出現這錯誤訊息,接著在程式馬上面看看 curl 吐出什麼資料:
Curl error: SSL certificate problem, verify that the CA cert is OK. Details: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed把這錯誤訊息拿去 Google 發現到這篇解法 Curl: SSL certificate problem, verify that the CA cert is OK,只要跳過驗證憑證就可以了
curl_setopt ($ch, CURLOPT_SSL_VERIFYHOST, 0); curl_setopt ($ch, CURLOPT_SSL_VERIFYPEER, 0);可以參考 PHP 官方 curl_setopt 的設定說明。
Ubunut 10.10 32 Desktop 版本 Apache/2.2.16 (Ubuntu) PHP 5.3.3-1ubuntu9.5 with Suhosin-Patch (cli) MySQL 5.1.491. 先下載 1.3.8 版本 2. 解壓縮到 /var/www 底下 3. 設定 apache virtual host 複製 virtual host 設定檔
cp /etc/apache2/sites-available/default /etc/apache2/sites-available/cakephp修改設定檔
ServerName cakephp.localhost DocumentRoot /var/www/cakephp/app/webroot4. 啟動 apache virtual host 跟 mod_rewrite 模組Options All AllowOverride All Order allow,deny allow from all
a2enmod rewrite a2ensite cakephpServerName 部份可以自己亂取,之後到 /etc/hosts 裡面加入 127.0.0.1 就可以了 5. 將 app/tmp 目錄改成 apache 使用者,這樣確定該目錄可以寫入 大致上就這樣完成了,可以參考 CakePHP 線上手冊