Difference between revisions of "Mirror Web Internet menjadi Web Lokal"
Jump to navigation
Jump to search
Onnowpurbo (talk | contribs) |
Onnowpurbo (talk | contribs) |
||
| Line 38: | Line 38: | ||
edit file /etc/apache2/ports.conf hapus kalimat 'NameVirtualHost *:80' | edit file /etc/apache2/ports.conf hapus kalimat 'NameVirtualHost *:80' | ||
| − | # vi /etc/apache2/sites-enabled/000-default | + | Edit |
| + | |||
| + | # vi /etc/apache2/sites-enabled/000-default | ||
Tambahan entry untuk masing-masing mesin / host kira-kira sebagai berikut | Tambahan entry untuk masing-masing mesin / host kira-kira sebagai berikut | ||
| Line 55: | Line 57: | ||
</Directory> | </Directory> | ||
</VirtualHost | </VirtualHost | ||
| − | |||
| − | |||
==Edit DNS== | ==Edit DNS== | ||
Revision as of 14:57, 18 November 2011
Pada saat semua situs yang kita butuhkan ada copy-nya di harddisk. Pada saat itu, Internet akan terasa cepat! Berikut adalah usaha untuk membuat supaya Internet menjadi cepat dengan cara mengcopy situs-situs yang bermanfaat ke harddisk lokal walaupun akses melalui web biasa.
Siapkan Folder tempat penyimpanan situs
sudo su mkdir /mirror chown -Rf www-data.www-data /mirror chmod -Rf 777 /mirror
Siapkan Script untuk Download Web
Siapkan script edit file misalnya
touch /usr/local/bin/mirrorbanyakweb.sh chmod -Rf 777 /usr/local/bin/mirrorbanyakweb.sh vi /usr/local/bin/mirrorbanyakweb.sh
isi dengan situs yang ingin anda download
cd /mirror wget -c --level=1 --limit-rate=8K -r -p -U Mozilla http://www.ipl.org/ wget -c --level=1 --limit-rate=8K -r -p -U Mozilla http://ocw.mit.edu/ wget -c --level=1 --limit-rate=8K -r -p -U Mozilla http://www.itb.ac.id/ wget -c --level=1 --limit-rate=8K -r -p -U Mozilla http://www.stkipsurya.ac.id/ wget -c --level=1 --limit-rate=8K -r -p -U Mozilla http://www.ui.ac.id/ chown -Rf www-data.www-data /mirror chmod -Rf 777 /mirror
Setelah di save sebaiknya di test dan pastikan tidak ada error dengan perintah
/usr/local/bin/mirrorbanyakweb.sh
Konfigusi cron
Edit Konfigurasi Apache
edit file /etc/apache2/ports.conf hapus kalimat 'NameVirtualHost *:80'
Edit
# vi /etc/apache2/sites-enabled/000-default
Tambahan entry untuk masing-masing mesin / host kira-kira sebagai berikut
NameVirtualHost *:80
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerName www.ipl.org
DocumentRoot /mirror/
<Directory /mirror/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
</VirtualHost