2016年1月22日 星期五

backup

sudo -u postgres pg_dump mediagoblin > xxxx.dbf

2015年12月29日 星期二

sshfs


sudo apt-get install sshfs

sudo modprobe fuse

addgroup fuse

2015年12月28日 星期一

KVM Server Ubuntu





[1] Install KVM and so on.

aptitude -y install qemu-kvm libvirt-bin virtinst bridge-utils



[2] Enable vhost-net.

modprobe vhost_net
lsmod | grep vhost

vhost_net 18063 0
vhost 29009 1 
vhost_net macvtap 18255 1 vhost_net 

echo vhost_net >> /etc/modules



[3] Configure Bridge networking.


vi /etc/network/interfaces 

iface em2 inet manual

auto br0
iface br0 inet static
bridge_ports em2
bridge_stp off
bridge_fd 0
brudge_maxwait 0
#Bride IP
address x.x.x.x


netmask x.x.x.0
network x.x.x.0
broadcast x.x.x.x
gateway x.x.x.x
dns-nameservers x.x.x.x
dns-search xxxxxxx

reboot

2011年8月2日 星期二

PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20090626/memcache.so'

140# php -v
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lib/php/20090626/memcache.so' - /usr/local/lib/php/20090626/memcache.so: Undefined symbol "php_session_create_id" in Unknown on line 0
PHP 5.3.6 with Suhosin-Patch (cli) (built: Aug 2 2011 10:06:18)
Copyright (c) 1997-2011 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2011 Zend Technologies

"autoconf: required version 2.68 not found" error when trying to make php5 from FreeBSD's ports

FreeBSD 8.1

在安裝 php5-extension 一直出現這個訊息

"autoconf: required version 2.68 not found" error when trying to make php5 from FreeBSD's ports....


用pkg_info | grep autoconf

明明就有安裝但老是說找不到~~

因此google 查了一下解決方式


解法

"autoconf: required version 2.68 not found" error when trying to make php5 from FreeBSD's ports
Description
When trying to make php5 (or php5-extensions or one of the other php5-* ports), you get the following error:
autoconf: required version 2.68 not found
*** Error code 1

Solution
Use the following commands to resolve the issue:
cd /usr/ports/devel/autoconf-wrapper && make clean && make deinstall && make reinstall




from http://www.nonstop.co.il/kb/view.php?kb=54

2011年7月26日 星期二

command line for Ubuntu

Check package status:
dpkg -l | grep packagename


設定開機啟動的服務
sysv-rc-conf


if not work
apt-get install sysv-rc-conf

lsof -iTCP:3000

portsnap fetch update
pkgdb -F
portsdb -Uu
portupgrade -a

2010年4月6日 星期二

XDEBUG EXTENSION FOR PHP

http://xdebug.org/

這個看起來不錯,在要Debug的頁面 URL後面加

?XDEBUG_SESSION_START=1

然後 在該Web 的Server 裡開個 VIM 然後 按 F5 @@

剛剛Tim 試範的步驟好像就這樣,不過小小試一下怎麼不太行~~@@ 註記等會來研究一下


看來對PHP Coding 及Debug 不錯用的樣子,特別在這種大型的 CMS內 架構複雜~


可惡~ Tim已經寫好了 操作文件~ 下班後來研究一下

http://docs.google.com/Doc?docid=0AcdTcgfT7cSeZGM4aHhjcm1fMjRkZHZ0bmRkMw&hl=zh_TW