History顯示指令執行的時間

要從history中查詢剛剛是在哪個時間點下指令的
必需要修改HISTTIMEFORMAT
主要是因為預設history只會排定順序,並不會輸出時間
所以執行下列指令

export HISTTIMEFORMAT="%Y/%m/%d %T "

也可以放到bashrc裡面~

另外要查詢執行指令所花費的時間可以在前面加上time

time 指令
Posted in Linux | Leave a comment

透過php頁面執行shell script時遭遇亂碼…

這一篇要特別感謝 G8 組 組長 JoeG8 組長!!!
謝謝他幫忙測試出是哪邊有問題~

Continue reading

Posted in Hadoop, Linux, PHP | Leave a comment

當執行ffmpeg時出現”[mov,mp4,m4a,3gp,3g2,mj2 @ 0x8b79440]moov atom not found”錯誤

出現這錯誤代表著ffmpeg對來源影像的解析錯誤
可能是影片內容有問題或是當初轉檔時沒轉完等

Posted in FFMpeg | Leave a comment

ClipBucket 修正影片標題中文內容被截取成亂碼

主要是因為truncate對於中文的辨識不太正確
以至於會把中文拆解錯誤,因此需要修改 modifier.truncate.php

參考了網路上的文章:讓 Smarty 的 truncate 支援 UTF-8 的方法
就開始來動手吧

vim /var/www/html/includes/templatelib/plugins/modifier.truncate.php
Continue reading

Posted in ClipBucket | Leave a comment

Which two connections might cause the issue?

A user attempts a remote SSH connection to a newly installed ESXi 5.x host to execute some commands. The SSH connection attempts fails, through the user is able to receive a ICMP ping back from the host.

Which two connections might cause the issue? (Choose two)

A.The shell timeout is set to low.
    Shell Timeout 預設值為0 (disable)
B.The ParentRootLogin option is set to False.
    ParentRootLogin功能設定為ESX平台才有的,ESXi並沒有此功能
C.The SSH service is disabled on the host by default.
    預設情況下,SSH是關閉的
D.The Esxi firewall blocks the SSH protocol by default.
    預設情況下,防火牆禁止SSH的通訊協定,直到SSH Enable後才會開啟

 

Source:http://www.aiotestking.com/vmware/2011/10/which-two-connections-might-cause-the-issue/

Posted in VCP考試 | Leave a comment

ClipBucket 取消頁面中廣告之位置

因為架設ClipBucket主要是用來分享影片、相片
並不是要用廣告來賺錢的
故拿掉的好,不然還要多設定一些…
vim /var/www/html/styles/cbv2new/layout/watch_video.html
#mark這一段資訊

{AD place=ad_300x250}

vim /var/www/html/styles/cbv2new/layout/index.html
#mark下面兩段資訊

{AD place='ad_468x60'} {AD place=ad_300x250}

Posted in ClipBucket | Leave a comment

ClipBucket 修改搜尋關鍵字不正確

在ClipBucket搜尋的預設條件為完整比對
因此必須要修改一些設定才可以讓關鍵字也能夠獲得正確搜尋結果

影片部分
vim /var/www/html/includes/classes/video.class.php
#第1050行
$this->search->use_match_method = true; 修改為 $this->search->use_match_method = false;

相片部分
vim /var/www/html/includes/classes/photo.class.php
#第172行
$this->search->use_match_method = TRUE; 修改為 $this->search->use_match_method = FALSE;

Posted in ClipBucket | Leave a comment

ClipBucket HTML5 Player

雖然可以參考clipbucket新增html5 player的作法修改 CBFolder/includes/functions.php
將以下資訊塞進 “return $swfobj->code;” 前面 (大約是3019行)
Continue reading

Posted in ClipBucket | Leave a comment

ClipBucket 中文化 – 管理選單

這一部分講的主要是針對ClipBucket的管理選單進行中文化
但是選單內的功能內容並沒有 ( 等有餘力再來完成 )
並且這部分會有點麻煩
主要需要搭配前一篇文章的附件進行 ClipBucket 中文化
下面的內容顯示主要是以 (原本內容) ==> (更改的內容) 進行
Continue reading

Posted in ClipBucket | Leave a comment

ClipBucket 中文化

在ClipBucket中文化部分會區分成兩塊
1. 使用者UI
2. 管理者UI

在使用者UI部分
網路上已經有人提供語系檔下載了 ( 系統很茫:ClipBucket 2.6 繁體中文語言下載 )
但是因為我有一些修改
所以還是以附件檔案為主 cb_lang_zh_tw
Continue reading

Posted in ClipBucket | Leave a comment