Basics like how to use ssh, how to login to DA etc..I would like to have Country stats in awstats
Basics like how to use ssh, how to login to DA etc..I would like to have Country stats in awstats
Although there are more complex/recommended ways of enabling country stats in awstats (the geoip plugin), a very quick and easy way to enable basic country stats in awstats is to edit:
/home/username/domains/domain.com/awstats/.data/awstats.domain.com.conf
and set:
DNSLookup=1
Please Note that this will likely slow down the computation of stats significantly, since many reverse IP lookups would need to be done.
A better method for doing the Country stats is to use the GeoIP plugin.
A very rough guide would be as following (beyond our support):
1)
wget http://maxmind.com/download/geoip/api/c/GeoIP.tar.gz
tar xvzf GeoIP.tar.gz
cd GeoIP*
./configure
make
make install
2)
cpan -i Geo::IP
3) And the edit the domain’s awstats configs file:
/home/username/domains/domain.com/awstats/.data/awstats.domain.com.conf
and set:
LoadPlugin=”geoip GEOIP_STANDARD /usr/local/share/GeoIP/GeoIP.dat”
You can leave the other setting as DNSLookups=0
If you would like to have default values for your new domains, the template can be found here:
/usr/local/awstats/wwwroot/cgi-bin/awstats.model.conf
on the first run of AwStats, this will will be copying over. This template is not used for existing domains, only new domains.
I wish to change the IP of my domain, but have no downtime, whatsoever.
This example shows how you can change the IP of your domain without having any downtime.
This assumes both IPs are going to be on the same box.
We will also use the Multi-IP system and just assign the 2nd IP to 1 domain, and temporarily have 2 IPs on the same User account (you can change it later if you want).
This allows multiple domains to be on the User account, and they will be unaffected.
We will assume we have domain.com using 1.2.3.4, and we will change the domain (not the User) to use 1.2.3.5, but still allow 1.2.3.4 to work in the background for a short period (hence no-downtime).
1) Add 1.2.3.5 as a 2nd IP to the domain using the Multi-IP System
2) Edit your dns to remove all 1.2.3.4 IPs:
User Level -> domain.com -> DNS Management -> remove all A records that point to 1.2.3.4.
Please Note, leave your TXT record (spf) if 1.2.3.4 is your server IP. Outbound emails will always leave from your server IP, so it needs to stay put.
3) Wait 4 hours. Then wait some more (maybe a day). This is for dns propagation. We need the old 1.2.3.4 IP to get flush out of the dns system on everyones dns servers (not just yours).
4) Once the dns has propagated and been flushed out, then you can fully remove 1.2.3.4 from the domain (and User if you want).
User Level -> Domain Setup -> domain.com -> remove 1.2.3.4.
OR, to remove it from the User (has to be doing quickly):
– Remove 1.2.3.5 from the domain
– Re-add 1.2.3.4 to the domain
– Go to Reseller Level -> List Users -> username: remove the 1.2.3.5 additional IP.
– At the same page, change the main IP for the user from 1.2.3.4 to 1.2.3.5.