dapurhosting.com Blog for Tech

August 27, 2014

Install iRedMail

Filed under: Server — dh @ 6:07 pm
cd /root/
wget https://bitbucket.org/zhb/iredmail/downloads/iRedMail-0.8.7.tar.bz2
tar xjf iRedMail-0.8.7.tar.bz2
cd /root/iRedMail-0.8.7
bash iRedMail.sh

September 1, 2013

Check Mod Security Version

Filed under: Securtiy,Server — Tags: — dh @ 6:17 pm

/scripts/restartsrv_httpd
grep "modsecurity" /usr/local/apache/logs/error_log

Output:

[Mon Sep 02 00:32:46 2013] [notice] ModSecurity for Apache/2.7.5 (http://www.modsecurity.org/) configured.

July 18, 2013

Check Hard Drive Health In Linux With HDSentinel

Filed under: Server — Tags: — dh @ 3:55 am


cd /home/status/
wget http://www.hdsentinel.com/hdslin/hdsentinel_008_x64.zip
unzip hdsentinel*
chmod 755 HDSentinel
./HDSentinel

October 9, 2012

More History

Filed under: Server — dh @ 5:47 am

15 Examples To Master Linux Command Line History

1. Display timestamp using HISTTIMEFORMAT

export HISTTIMEFORMAT='%F %T '

August 16, 2012

Install Bonnie++

Filed under: Server — Tags: , — dh @ 5:29 pm

Download the latest atrpms-repo rpm from http://dl.atrpms.net/el6-x86_64/atrpms/stable/

Install atrpms-repo rpm:

rpm -Uvh atrpms-repo*rpm

Install bonnie++ rpm package:

yum install bonnie++

Source: http://pkgs.org/centos-6-rhel-6/atrpms-x86_64/bonnie++-1.03e-6.el6.x86_64.rpm.html#howto

July 9, 2012

Check Motherboard Type

Filed under: Server — dh @ 12:01 pm

/usr/sbin/dmidecode

July 1, 2012

Error ip_conntrack: table full, dropping packet

Filed under: Apache,Server — Tags: , — dh @ 1:57 pm

Error ip_conntrack: table full, dropping packet terjadi karena banyaknya kunjungan ke server dan menyebabkan database iptable menjadi penuh

solusi:

1. naikkan kapasitas iptable

echo 131072 > /proc/sys/net/ipv4/ip_conntrack_max

2. flush kosongkan iptable

iptables -P
iptables -F

June 15, 2012

Mod_Deflate

Filed under: cPanel/WHM,Server — Tags: — dh @ 6:02 pm

Ke cPanel >> Apache Configuration >> Include Editor >> Post VirtualHost Include >> All Version Tambahkan kode ini


AddOutputFilterByType DEFLATE text/html text/plain text/xml


# Netscape 4.x has some problems…
BrowserMatch ^Mozilla/4 gzip-only-text/html

# Netscape 4.06-4.08 have some more problems
BrowserMatch ^Mozilla/4\.0[678] no-gzip

# MSIE masquerades as Netscape, but it is fine
# BrowserMatch \bMSIE !no-gzip !gzip-only-text/html

# NOTE: Due to a bug in mod_setenvif up to Apache 2.0.48
# the above regex won’t work. You can use the following
# workaround to get the desired effect:
BrowserMatch \bMSI[E] !no-gzip !gzip-only-text/html

# Don’t compress images
SetEnvIfNoCase Request_URI \
\.(?:exe|t?gz|zip|bz2|sit|rar)$ \
no-gzip dont-vary
SetEnvIfNoCase Request_URI \.pdf$ no-gzip dont-vary


# Make sure proxies don’t deliver the wrong content
Header append Vary User-Agent env=!dont-vary

Test:
http://www.whatsmyip.org/http-compression-test/

Install Memcache

Filed under: Apache,Server — Tags: , — dh @ 8:12 am

cd /usr/local/src/
wget https://github.com/downloads/libevent/libevent/libevent-2.0.19-stable.tar.gz
tar xfz libevent*
cd libevent*
./configure
make
sudo make install

sudo ln -s /usr/local/lib/libevent-2.0.so.5 /usr/lib

cd /usr/local/src/
wget http://memcached.googlecode.com/files/memcached-1.4.13.tar.gz
tar xfz memcached*
cd memcached*
./configure
make
sudo make install

test memcached

memcached -d -u nobody -m 1024 127.0.0.1 -p 11211

Kalau error
ln -s /usr/local/lib/libevent-2.0.so.5 /usr/lib64/libevent-2.0.so.5

Install libmemcached
cd /usr/local/src/
wget http://launchpad.net/libmemcached/1.0/1.0.4/+download/libmemcached-1.0.4.tar.gz
tar -zxvf libmemcached-1.0.4.tar.gz
cd libmemcached-1.0.4
./configure
make && make install

Install memcached
pecl install memcached

pecl install memcached

http://forums.cpanel.net/f5/memcached-instalation-memcached-so-missing-257942.html

April 5, 2012

‘./eximstats/sends’ is marked as crashed

Filed under: MySql,Server — dh @ 9:14 am

MySql Error

[ERROR] /usr/sbin/mysqld: Table './eximstats/sends' is marked as crashed and last (automatic?) repair failed

Repair from command line ssh
myisamchk -r /var/lib/mysql/eximstats/sends.MYI

« Newer PostsOlder Posts »

Powered by WordPress