跳到主要內容

發表文章

解決Zimbra的Cache is out of date or doesn't exist 的問題

某天, 公司內部作為軟體開發與測試用的Zimbra Email Server 無法順利啟動, 顯示 " Cache is out of date or doesn't exist. " 面對這陌生的問題, 我只能撥電話給當初承包Zimbra安裝工作的系統公司的Zimbra專家... 結果問題意外地容易解決, 那是因為Zimbra 所使用的SSL Certificate 過期了, 只要重新建立新的SSL Certificate 就行了... 步驟如下: /opt/zimbra/bin/zmcertmgr createcrt -new -days 3650 /opt/zimbra/bin/zmcertmgr deploycrt self /opt/zimbra/bin/zmcertmgr deployca /opt/zimbra/bin/zmcertmgr viewdeployedcrt

在CentOS 6 使用VMWare 啟動64Bit 的OS 出現VT 問題的解決辦法

我分別在兩台CentOS 6 (64Bit) 伺服器裡的VMWare 設定了一個新的Virtual Machine (CentOS 64 Bit), 而這個Virtual Machine 的VMDK 檔是從別架電腦拷貝過來的.  因此當我想要啟動時, 出現了以下的問題: This kernel requires an x86-64 CPU, but only detected an i686 CPU. Unable to boot – please use a kernel appropriate for your CPU 以及 This virtual machine is configured for 64-bit guest operating systems. However, 64-bit operation is not possible. This host is VT-capable, but VT is disabled. VT might be disabled if it has been disabled in the BIOS settings or the host has not been power-cycled since changing this setting. (1) Verify that the BIOS settings enable VT and disable 'trusted execution.' (2) Power-cycle the host if either of these BIOS settings have been changed. (3) Power-cycle the host if you have not done so since installing VMware Workstation. (4) Update the host's BIOS to the latest version. For more detailed information, see http://vmware.com/info?id=152. Continue without 64-bit support? 解決辦法: 進入BIOS 如果是Intel Proces...

在CentoS 6.1 安裝7Zip 之後出現 /usr/local/bin/7z: /usr/local/lib/p7zip/7z: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory 的解決辦法

日前在同事安裝好的CentOS 6.1 裡安裝7Zip 之後, 想要使用7Zip 時, 卻出現這個問題: /usr/local/bin/7z: /usr/local/lib/p7zip/7z: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory 我百思不得其解, GLIBC, lsb 什麼的也安裝了, 可是依然出現這個問題... 後來使用  yum install "/lib/ld-linux.so.2" 之後, 卻意外的幫我解決了問題... 以下是我安裝7Zip 的過程: wget http://sourceforge.net/projects/p7zip/files/p7zip/9.20.1/p7zip_9.20.1_x86_linux_bin.tar.bz2/download tar -xjvf p7zip_9.20.1_x86_linux_bin.tar.bz2 cd p7zip_9.20.1 ./install.sh cd .. rm -rf p7zip_9.20.1 rm -rf p7zip_9.20.1_x86_linux_bin.tar.bz2 yum install "/lib/ld-linux.so.2"

在CentOS 6 安裝PHP SSH2 模組

首先: yum install libssh2 libssh2-devel 之後.. wget  http://pecl.php.net/get/ssh2- 0.11.3.tgz phpize ./configure --with-ssh2 make make install   或者以下的方法; pecl install ssh2 channel:// pecl.php.net/ssh2- version 或者以下的方法; pecl install ssh2 channel:// pecl.php.net/ssh2-0. 11.3 完成之後,  vi /etc/php.d/ssh2.ini extension=ssh2.so service httpd restart

CentOS 6 安裝 DenyHosts

yum install denyhosts 倘若找不到, 那就是少了一個repository. rpm -Uvh http://download.fedora.redhat.com/pub/epel/6/x86_64/epel-release-6-5.noarch.rpm rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm yum install denyhosts vi /etc/denyhosts.conf 更改DENY_THRESHOLD_INVALID, DENY_THRESHOLD_VALID 以及 DENY_THRESHOLD_ROOT 此外, 可以將喜歡的IP 加入 /etc/hosts.allow 或者 /etc/hosts.deny vi /etc/hosts.allow sshd: 192.168.1.2 vi /etc/hosts.deny sshd: 192.168.1.3

在CentOS 6 設定 rsync

不曉得為什麼, 與CentOS 5 不同, 搞了半天才找到問題. CentOS 6 版的似乎不會將設定檔給load 進去, 因此別台伺服器一直無法連線 (connection refused) 解決辦法: vi /etc/xinetd.d/rsync disable = yes 改成 disable = no (也可不用改) 修改成:  server_args     = --daemon --config=/etc/rsyncd.conf 倘若之前沒有建立rsyncd.conf... vi /etc/rsyncd.conf [ name ] path = /var/www/ uid = root gid = root 倘若有使用SeLINUX, 記得 setsebool -P allow_rsync_anon_write=1 倘若有使用Firewall, 記得增加一個port: 873 重新啟動伺服器 隨後可以在別台伺服器用這個指令擷取檔案清單:   rsync 192.168.1.10:: name /  或者   rsync 192.168.1.10:: name /www/ 可用這個指令拷貝檔案:  rsync 192.168.1.10:: name /www/data.tar.gz /backup/ /backup/   為本機的檔案目錄,   name /www/data.tar.gz   乃192.168.1.10 這伺服器裡, 存在 /var/www 裡的檔案 -- data.tar.gz