buat file script ketik
1
| vi haarp.sh
|
kemudian paste kode di bawah ini
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | #!/bin/bash echo "=========== SIAP2 KOMANDAN ==========="; cd /tmp echo "=========== INSTALL HC V1.0 ==========="; #if [ "$(find . -name "haarpcache1-32bits.tar.gz")" == "" ] ; then wget http://archives.scienceontheweb.net/haarpcache1-32bits.tar.gz -O "haarpcache1-32bits.tar.gz"; #fi gzip -d haarpcache1-32bits.tar.gz tar -xvf haarpcache1-32bits.tar cp libmysqlclient.so.15.0.0 /usr/lib/ cp libmysqlclient.so.15.0.0 /usr/lib/libmysqlclient.so.15 cp -R /tmp/haarpcache/sbin/* /usr/local/sbin chmod a+x /usr/local/sbin/haarp mkdir /var/log/haarp mkdir /var/run/haarp chmod a+rwx /var/log/haarp chmod a+rwx /var/run/haarp cp -R /tmp/haarpcache/etc/init.d/* /etc/init.d chmod a+x /etc/init.d/haarp cp -R /tmp/haarpcache/etc/haarp /etc/haarp mkdir /haarp chmod a+rwx /haarp chown -R apache:apache /haarp/ chmod -R 777 /haarp/ umask 000 /haarp/ echo "MASUKIN ROOT SQL PASSWORD:"; mysql -u root -p < /tmp/haarpcache/haarp.sql; echo "Install OK."; echo "===========EDIT /etc/haarp/haarp.conf di bagian database dan listening port ============="; |
edit logrotate di /etc/logrotate.d/haarpcache
/var/log/haarp/*.log { daily compress rotate 5 missingok notifempty postrotate /etc/init.d/haarp restart > /dev/null endscript }
acl haarp_lst url_regex -i "/etc/haarp/haarp.lst" cache deny haarp_lst cache_peer 127.0.0.1 parent 8081 0 proxy-only no-digest dead_peer_timeout 2 seconds cache_peer_access 127.0.0.1 allow haarp_lst cache_peer_access 127.0.0.1 deny all
No comments:
Post a Comment