Changeset 619
- Timestamp:
- 06/01/07 01:35:14
(1 year ago)
- Author:
- rats
- Message:
- DATABASE:
- changed Englisch language
- GUI:
- Fixed: missing $cfg in tr-function
- started build-in of AWStats (#7)
-
Files:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
| r618 |
r619 |
|
| 16 | 16 | - GUI: |
|---|
| 17 | 17 | * Fixed: missing $cfg in tr-function |
|---|
| | 18 | * started build-in of AWStats (#7) |
|---|
| 18 | 19 | |
|---|
| 19 | 20 | 2007-05-31 Henrik Schytte |
|---|
| r525 |
r619 |
|
| 1 | | # AWSTATS CONFIGURE FILE 6.4 |
|---|
| | 1 | # AWSTATS CONFIGURE FILE 6.6 |
|---|
| 2 | 2 | #----------------------------------------------------------------------------- |
|---|
| 3 | 3 | # Copy this file into awstats.www.mydomain.conf and edit this new config file |
|---|
| … | … | |
| 11 | 11 | # the config value in an AWStats running session and can be used like others. |
|---|
| 12 | 12 | #----------------------------------------------------------------------------- |
|---|
| 13 | | # $Revision: 1.318 $ - $Author: eldy $ - $Date: 2005/06/22 23:20:29 $ |
|---|
| | 13 | # $Revision: 1.327 $ - $Author: eldy $ - $Date: 2006/04/21 22:28:49 $ |
|---|
| 14 | 14 | |
|---|
| 15 | 15 | |
|---|
| … | … | |
| 46 | 46 | # You can also use a pipe if log file come from a pipe : |
|---|
| 47 | 47 | # Example: "gzip -d </var/log/apache/access.log.gz |" |
|---|
| 48 | | # If there is several log files from load balancing servers : |
|---|
| | 48 | # If there are several log files from load balancing servers : |
|---|
| 49 | 49 | # Example: "/pathtotools/logresolvemerge.pl *.log |" |
|---|
| 50 | 50 | # |
|---|
| … | … | |
| 145 | 145 | # virtual web server. In this case, this parameter is only used to generate |
|---|
| 146 | 146 | # full URL's links when ShowLinksOnUrl option is set to 1. |
|---|
| 147 | | # If analysing mail log, enter here the domain name of mail server. |
|---|
| | 147 | # If analyzing mail log, enter here the domain name of mail server. |
|---|
| 148 | 148 | # Example: "myintranetserver" |
|---|
| 149 | 149 | # Example: "www.domain.com" |
|---|
| … | … | |
| 223 | 223 | |
|---|
| 224 | 224 | |
|---|
| 225 | | # When this parameter is set to 1, AWStats add a button on report page to |
|---|
| | 225 | # When this parameter is set to 1, AWStats adds a button on report page to |
|---|
| 226 | 226 | # allow to "update" statistics from a web browser. Warning, when "update" is |
|---|
| 227 | | # made from a browser, AWStats is ran as a CGI by the web server user defined |
|---|
| | 227 | # made from a browser, AWStats is run as a CGI by the web server user defined |
|---|
| 228 | 228 | # in your web server (user "nobody" by default with Apache, "IUSR_XXX" with |
|---|
| 229 | 229 | # IIS), so the "DirData" directory and all already existing history files |
|---|
| … | … | |
| 231 | 231 | # necessary to "Read/Write" (and "Modify" for Windows NTFS file systems). |
|---|
| 232 | 232 | # Warning: Update process can be long so you might experience "time out" |
|---|
| 233 | | # browser errors if you don't launch AWStats enough frequently. |
|---|
| 234 | | # When set to 0, update is only made when AWStats is ran from the command |
|---|
| | 233 | # browser errors if you don't launch AWStats frequently enough. |
|---|
| | 234 | # When set to 0, update is only made when AWStats is run from the command |
|---|
| 235 | 235 | # line interface (or a task scheduler). |
|---|
| 236 | 236 | # Possible values: 0 or 1 |
|---|
| … | … | |
| 240 | 240 | |
|---|
| 241 | 241 | |
|---|
| 242 | | # AWStats save and sort its database on a month basis, this allows to build |
|---|
| 243 | | # build a report quickly. However, if you choose the -month=all from command |
|---|
| 244 | | # line or value '-Year-' from CGI combo form to have a report for all year, |
|---|
| 245 | | # AWStats needs to reload all data for full year, and resort them completely, |
|---|
| | 242 | # AWStats saves and sorts its database on a month basis (except if using |
|---|
| | 243 | # databasebreak option from command line). |
|---|
| | 244 | # However, if you choose the -month=all from command line or |
|---|
| | 245 | # value '-Year-' from CGI combo form to have a report for all year, AWStats |
|---|
| | 246 | # needs to reload all data for full year (each month), and sort them, |
|---|
| 246 | 247 | # requiring a large amount of time, memory and CPU. This might be a problem |
|---|
| 247 | 248 | # for web hosting providers that offer AWStats for large sites, on shared |
|---|
| … | … | |
| 264 | 265 | #----------------------------------------------------------------------------- |
|---|
| 265 | 266 | |
|---|
| 266 | | # When the update process run, AWStats can set a lock file in TEMP or TMP |
|---|
| | 267 | # When the update process runs, AWStats can set a lock file in TEMP or TMP |
|---|
| 267 | 268 | # directory. This lock is to avoid to have 2 update processes running at the |
|---|
| 268 | 269 | # same time to prevent unknown conflicts problems and avoid DoS attacks when |
|---|
| … | … | |
| 329 | 330 | |
|---|
| 330 | 331 | |
|---|
| 331 | | # This parameter give the list of all authorized authenticated users to view |
|---|
| | 332 | # This parameter gives the list of all authorized authenticated users to view |
|---|
| 332 | 333 | # statistics for this domain/config file. This parameter is used only if |
|---|
| 333 | 334 | # AllowAccessFromWebToAuthenticatedUsersOnly is set to 1. |
|---|
| … | … | |
| 340 | 341 | |
|---|
| 341 | 342 | |
|---|
| 342 | | # When this parameter is define to something, the IP address of the user that |
|---|
| 343 | | # read its statistics from a browser (when AWStats is used as a CGI) is |
|---|
| | 343 | # When this parameter is defined to something, the IP address of the user that |
|---|
| | 344 | # reads its statistics from a browser (when AWStats is used as a CGI) is |
|---|
| 344 | 345 | # checked and must match one of the IP address values or ranges. |
|---|
| 345 | 346 | # Change : Effective immediatly |
|---|
| … | … | |
| 350 | 351 | |
|---|
| 351 | 352 | |
|---|
| 352 | | # If the "DirData" directory (see above) does not exists, AWStats return an |
|---|
| | 353 | # If the "DirData" directory (see above) does not exist, AWStats return an |
|---|
| 353 | 354 | # error. However, you can ask AWStats to create it. |
|---|
| 354 | 355 | # This option can be used by some Web Hosting Providers that has defined a |
|---|
| … | … | |
| 373 | 374 | |
|---|
| 374 | 375 | # If you prefer having the report output pages be built as XML compliant pages |
|---|
| 375 | | # instead of simple HTML pages, you can set this to 'xhtml' (May not works |
|---|
| | 376 | # instead of simple HTML pages, you can set this to 'xhtml' (May not work |
|---|
| 376 | 377 | # properly with old browsers). |
|---|
| 377 | 378 | # Change : Effective immediatly |
|---|
| … | … | |
| 386 | 387 | # for both command line user and default web server user (nobody for Unix, |
|---|
| 387 | 388 | # IUSR_xxx for IIS/Windows,...). |
|---|
| 388 | | # To avoid permission's problems between update process (run by an admin user) |
|---|
| | 389 | # To avoid permission problems between update process (run by an admin user) |
|---|
| 389 | 390 | # and CGI process (ran by a low level user), AWStats can save its database |
|---|
| 390 | 391 | # files with read and write permissions for everyone. |
|---|
| 391 | | # By default, AWStats keep default user permissions on updated files. If you |
|---|
| | 392 | # By default, AWStats keeps default user permissions on updated files. If you |
|---|
| 392 | 393 | # set AllowToUpdateStatsFromBrowser to 1, you can change this parameter to 1. |
|---|
| 393 | 394 | # Change : Effective for new updates only |
|---|
| … | … | |
| 403 | 404 | # With 0, no purge is made, so you must use a scheduled task or a web server |
|---|
| 404 | 405 | # that make this purge frequently. |
|---|
| 405 | | # With 1, the purge of the log file is made each time AWStats update is ran. |
|---|
| | 406 | # With 1, the purge of the log file is made each time AWStats update is run. |
|---|
| 406 | 407 | # This parameter doesn't work with IIS (This web server doesn't let its log |
|---|
| 407 | 408 | # file to be purged). |
|---|
| … | … | |
| 428 | 429 | |
|---|
| 429 | 430 | |
|---|
| 430 | | # Each time you run the update process, AWStats overwrite the 'historic file' |
|---|
| | 431 | # Each time you run the update process, AWStats overwrites the 'historic file' |
|---|
| 431 | 432 | # for the month (awstatsMMYYYY[.*].txt) with the updated one. |
|---|
| 432 | 433 | # When write errors occurs (IO, disk full,...), this historic file can be |
|---|
| … | … | |
| 451 | 452 | |
|---|
| 452 | 453 | # Do not include access from clients that match following criteria. |
|---|
| 453 | | # If your log file contains IP adresses in host field, you must enter here |
|---|
| 454 | | # matching IP adresses criteria. |
|---|
| | 454 | # If your log file contains IP addresses in host field, you must enter here |
|---|
| | 455 | # matching IP addresses criteria. |
|---|
| 455 | 456 | # If DNS lookup is already done in your log file, you must enter here hostname |
|---|
| 456 | 457 | # criteria, else enter ip address criteria. |
|---|
| … | … | |
| 497 | 498 | |
|---|
| 498 | 499 | |
|---|
| | 500 | # Use SkipReferrersBlackList if you want to exclude records coming from a SPAM |
|---|
| | 501 | # referrer. Parameter must receive a local file name containing rules applied |
|---|
| | 502 | # on referrer field. If parameter is empty, no filter is applied. |
|---|
| | 503 | # An example of such a file is available in lib/blacklist.txt |
|---|
| | 504 | # You can download updated version at http://www.jayallen.org/comment_spam/ |
|---|
| | 505 | # Change : Effective for new updates only |
|---|
| | 506 | # Example: "/mylibpath/blacklist.txt" |
|---|
| | 507 | # Default: "" |
|---|
| | 508 | # |
|---|
| | 509 | # WARNING!! Using this feature make AWStats running very slower (5 times slower |
|---|
| | 510 | # with black list file provided with AWStats ! |
|---|
| | 511 | # |
|---|
| | 512 | SkipReferrersBlackList="" |
|---|
| | 513 | |
|---|
| | 514 | |
|---|
| 499 | 515 | # Include in stats, only accesses from hosts that match one of following |
|---|
| 500 | 516 | # entries. For example, if you want AWStats to filter access to keep only |
|---|
| 501 | | # stats for visits from particular hosts, you can add those hosts names in |
|---|
| | 517 | # stats for visits from particular hosts, you can add those host names in |
|---|
| 502 | 518 | # this parameter. |
|---|
| 503 | 519 | # If DNS lookup is already done in your log file, you must enter here hostname |
|---|
| … | … | |
| 544 | 560 | # Add here a list of kind of url (file extension) that must be counted as |
|---|
| 545 | 561 | # "Hit only" and not as a "Hit" and "Page/Download". You can set here all |
|---|
| 546 | | # images extensions as they are hit downloaded that must be counted but they |
|---|
| | 562 | # image extensions as they are hit downloaded that must be counted but they |
|---|
| 547 | 563 | # are not viewed pages. URLs with such extensions are not included in the TOP |
|---|
| 548 | 564 | # Pages/URL report. |
|---|
| … | … | |
| 582 | 598 | |
|---|
| 583 | 599 | |
|---|
| 584 | | # Some web servers on some Operating systems (IIS-Windows) considers that a |
|---|
| | 600 | # Some web servers on some Operating systems (IIS-Windows) consider that a |
|---|
| 585 | 601 | # login with same value but different case are the same login. To tell AWStats |
|---|
| 586 | | # to also considers them as one, set this parameter to 1. |
|---|
| | 602 | # to also consider them as one, set this parameter to 1. |
|---|
| 587 | 603 | # Change : Effective for new updates only |
|---|
| 588 | 604 | # Possible values: 0 or 1 |
|---|
| … | … | |
| 612 | 628 | # In URL links, "?" char is used to add parameter's list in URLs. Syntax is: |
|---|
| 613 | 629 | # /mypage.html?param1=value1¶m2=value2 |
|---|
| 614 | | # However, some servers/sites use also others chars to isolate dynamic part of |
|---|
| | 630 | # However, some servers/sites use also other chars to isolate dynamic part of |
|---|
| 615 | 631 | # their URLs. You can complete this list with all such characters. |
|---|
| 616 | 632 | # Change : Effective for new updates only |
|---|
| … | … | |
| 697 | 713 | |
|---|
| 698 | 714 | |
|---|
| 699 | | # When an error occurs, AWStats output a message related to errors. If you |
|---|
| | 715 | # When an error occurs, AWStats outputs a message related to errors. If you |
|---|
| 700 | 716 | # want (in most cases for security reasons) to have no error messages, you |
|---|
| 701 | 717 | # can set this parameter to your personalized generic message. |
|---|
| 702 | 718 | # Change : Effective immediatly |
|---|
| 703 | | # Example: "An error occured. Contact your Administrator" |
|---|
| | 719 | # Example: "An error occurred. Contact your Administrator" |
|---|
| 704 | 720 | # Default: "" |
|---|
| 705 | 721 | # |
|---|
| … | … | |
| 717 | 733 | |
|---|
| 718 | 734 | |
|---|
| 719 | | # To help you to detect if your log format is good, AWStats report an error |
|---|
| | 735 | # To help you to detect if your log format is good, AWStats reports an error |
|---|
| 720 | 736 | # if all the first NbOfLinesForCorruptedLog lines have a format that does not |
|---|
| 721 | 737 | # match the LogFormat parameter. |
|---|
| … | … | |
| 741 | 757 | |
|---|
| 742 | 758 | # DecodeUA must be set to 1 if you use Roxen web server. This server converts |
|---|
| 743 | | # all spaces in user agent field into %20. This make the AWStats robots, os |
|---|
| | 759 | # all spaces in user agent field into %20. This make the AWStats robots, OS |
|---|
| 744 | 760 | # and browsers detection fail in some cases. Just change it to 1 if and only |
|---|
| 745 | 761 | # if your web server is Roxen. |
|---|
| … | … | |
| 751 | 767 | |
|---|
| 752 | 768 | |
|---|
| 753 | | # MiscTrackerUrl can be used to make AWStats able to detect some miscellanous |
|---|
| | 769 | # MiscTrackerUrl can be used to make AWStats able to detect some miscellaneous |
|---|
| 754 | 770 | # things, that can not be tracked on other way, like: |
|---|
| 755 | 771 | # - Javascript disabled |
|---|
| … | … | |
| 763 | 779 | # - Mediaplayer plugin |
|---|
| 764 | 780 | # - Acrobat PDF plugin |
|---|
| 765 | | # To enable all this features, you must copy the awstats_misc_tracker.js file |
|---|
| | 781 | # To enable all these features, you must copy the awstats_misc_tracker.js file |
|---|
| 766 | 782 | # into a /js/ directory stored in your web document root and add the following |
|---|
| 767 | 783 | # HTML code at the end of your index page (but before </BODY>) : |
|---|
| … | … | |
| 787 | 803 | #----------------------------------------------------------------------------- |
|---|
| 788 | 804 | |
|---|
| 789 | | # Following values allows you to define accuracy of AWStats entities (robots, |
|---|
| 790 | | # browsers, os, referers, file types) detection. |
|---|
| | 805 | # The following values allow you to define accuracy of AWStats entities |
|---|
| | 806 | # (robots, browsers, os, referers, file types) detection. |
|---|
| 791 | 807 | # It might be a good idea for large web sites or ISP that provides AWStats to |
|---|
| 792 | 808 | # high number of customers, to set this parameter to 1 (or 0), instead of 2. |
|---|
| 793 | 809 | # Possible values: |
|---|
| 794 | | # 0 = No detection, |
|---|
| 795 | | # 1 = Medium/Standard detection |
|---|
| 796 | | # 2 = Full detection |
|---|
| 797 | | # Change : Effective for new updates only |
|---|
| | 810 | # 0 = No detection, |
|---|
| | 811 | # 1 = Medium/Standard detection |
|---|
| | 812 | # 2 = Full detection |
|---|
| | 813 | # Change : Effective for new updates only |
|---|
| | 814 | # Note : LevelForBrowsersDetection can also accept value "allphones". This |
|---|
| | 815 | # enable detailed detection of phone/pda browsers. |
|---|
| 798 | 816 | # Default: 2 (0 for LevelForWormsDetection) |
|---|
| 799 | 817 | # |
|---|
| 800 | 818 | LevelForBrowsersDetection=2 # 0 disables Browsers detection. |
|---|
| 801 | 819 | # 2 reduces AWStats speed by 2% |
|---|
| | 820 | # allphones reduces AWStats speed by 5% |
|---|
| 802 | 821 | LevelForOSDetection=2 # 0 disables OS detection. |
|---|
| 803 | 822 | # 2 reduces AWStats speed by 3% |
|---|
| … | … | |
| 830 | 849 | |
|---|
| 831 | 850 | |
|---|
| 832 | | # This parameter ask your browser to open detailed reports into a different |
|---|
| | 851 | # This parameter asks your browser to open detailed reports into a different |
|---|
| 833 | 852 | # window than the main page. |
|---|
| 834 | 853 | # Possible values: |
|---|
| … | … | |
| 842 | 861 | |
|---|
| 843 | 862 | # You can add, in the HTML report page, a cache lifetime (in seconds) that |
|---|
| 844 | | # will be returned to browser in HTTP header answer by server. |
|---|
| 845 | | # This parameter is not used when report are built with -staticlinks option. |
|---|
| | 863 | # will be returned to the browser in HTTP header answer by server. |
|---|
| | 864 | # This parameter is not used when reports are built with -staticlinks option. |
|---|
| 846 | 865 | # Example: 3600 |
|---|
| 847 | 866 | # Default: 0 |
|---|
| … | … | |
| 851 | 870 | |
|---|
| 852 | 871 | # To avoid too large web pages, you can ask AWStats to limit number of rows of |
|---|
| 853 | | # all reported charts to this number when no other limit apply. |
|---|
| | 872 | # all reported charts to this number when no other limits apply. |
|---|
| 854 | 873 | # Default: 1000 |
|---|
| 855 | 874 | # |
|---|
| … | … | |
| 858 | 877 | |
|---|
| 859 | 878 | # Set your primary language (ISO-639-1 language codes). |
|---|
| 860 | | # Possible value: |
|---|
| | 879 | # Possible values: |
|---|
| 861 | 880 | # Albanian=al, Bosnian=ba, Bulgarian=bg, Catalan=ca, |
|---|
| 862 | 881 | # Chinese (Taiwan)=tw, Chinese (Simpliefied)=cn, Croatian=hr, Czech=cz, |
|---|
| 863 | 882 | # Danish=dk, Dutch=nl, English=en, Estonian=et, Euskara=eu, Finnish=fi, |
|---|
| 864 | 883 | # French=fr, Galician=gl, German=de, Greek=gr, Hebrew=he, Hungarian=hu, |
|---|
| 865 | | # Icelandic=is, Indonesian=id, Italian=it, Japanese=jp, Korean=kr, |
|---|
| | 884 | # Icelandic=is, Indonesian=id, Italian=it, Japanese=jp, Korean=ko, |
|---|
| 866 | 885 | # Latvian=lv, Norwegian (Nynorsk)=nn, Norwegian (Bokmal)=nb, Polish=pl, |
|---|
| 867 | 886 | # Portuguese=pt, Portuguese (Brazilian)=br, Romanian=ro, Russian=ru, |
|---|
| … | … | |
| 1039 | 1058 | |
|---|
| 1040 | 1059 | # Some graphical reports are followed by the data array of values. |
|---|
| 1041 | | # If you don't want this array (to reduce report size for example), you can |
|---|
| 1042 | | # set thoose options to 0. |
|---|
| | 1060 | # If you don't want this array (to reduce the report size for example), you |
|---|
| | 1061 | # can set thoose options to 0. |
|---|
| 1043 | 1062 | # Possible values: 0 or 1 |
|---|
| 1044 | 1063 | # Default: 1 |
|---|
| … | … | |
| 1055 | 1074 | |
|---|
| 1056 | 1075 | # In the Origin chart, you have stats on where your hits came from. You can |
|---|
| 1057 | | # includes hits on pages that comes from pages of same sites in this chart. |
|---|
| | 1076 | # include hits on pages that come from pages of same sites in this chart. |
|---|
| 1058 | 1077 | # Possible values: 0 or 1 |
|---|
| 1059 | 1078 | # Default: 0 |
|---|
| … | … | |
| 1062 | 1081 | |
|---|
| 1063 | 1082 | |
|---|
| 1064 | | # Following parameter can be used to choose maximum number of lines shown for |
|---|
| 1065 | | # the particular following report. |
|---|
| | 1083 | # The following parameters can be used to choose the maximum number of lines |
|---|
| | 1084 | # shown for the particular following reports. |
|---|
| 1066 | 1085 | # |
|---|
| 1067 | 1086 | # Stats by countries/domains |
|---|
| … | … | |
| 1108 | 1127 | # Choose if you want the week report to start on sunday or monday |
|---|
| 1109 | 1128 | # Possible values: |
|---|
| 1110 | | # 0 - Week start on sunday |
|---|
| 1111 | | # 1 - Week start on monday |
|---|
| | 1129 | # 0 - Week starts on sunday |
|---|
| | 1130 | # 1 - Week starts on monday |
|---|
| 1112 | 1131 | # Default: 1 |
|---|
| 1113 | 1132 | # |
|---|
| … | … | |
| 1115 | 1134 | |
|---|
| 1116 | 1135 | |
|---|
| 1117 | | # List of visible flags that links to other language translations. |
|---|
| | 1136 | # List of visible flags that link to other language translations. |
|---|
| 1118 | 1137 | # See Lang parameter for list of allowed flag/language codes. |
|---|
| 1119 | 1138 | # If you don't want any flag link, set ShowFlagLinks to "". |
|---|
| … | … | |
| 1133 | 1152 | |
|---|
| 1134 | 1153 | |
|---|
| 1135 | | # When AWStats build HTML links in its report pages, it starts thoose link |
|---|
| | 1154 | # When AWStats builds HTML links in its report pages, it starts those links |
|---|
| 1136 | 1155 | # with "http://". However some links might be HTTPS links, so you can enter |
|---|
| 1137 | 1156 | # here the root of all your HTTPS links. If all your site is a SSL web site, |
|---|
| … | … | |
| 1146 | 1165 | |
|---|
| 1147 | 1166 | # Maximum length of URL part shown on stats page (number of characters). |
|---|
| 1148 | | # This affects only URL visible text, link still work. |
|---|
| | 1167 | # This affects only URL visible text, links still work. |
|---|
| 1149 | 1168 | # Default: 64 |
|---|
| 1150 | 1169 | # |
|---|
| … | … | |
| 1174 | 1193 | |
|---|
| 1175 | 1194 | |
|---|
| 1176 | | # Value of maximum bar width/height for horizontal/vertical HTML graphics bar. |
|---|
| | 1195 | # Value of maximum bar width/height for horizontal/vertical HTML graphics bars. |
|---|
| 1177 | 1196 | # Default: 260/90 |
|---|
| 1178 | 1197 | # |
|---|
| … | … | |
| 1191 | 1210 | |
|---|
| 1192 | 1211 | |
|---|
| 1193 | | # Those colors parameters can be used (if StyleSheet parameter is not used) |
|---|
| | 1212 | # Those color parameters can be used (if StyleSheet parameter is not used) |
|---|
| 1194 | 1213 | # to change AWStats look. |
|---|
| 1195 | 1214 | # Example: color_name="RRGGBB" # RRGGBB is Red Green Blue components in Hex |
|---|
| … | … | |
| 1223 | 1242 | #----------------------------------------------------------------------------- |
|---|
| 1224 | 1243 | |
|---|
| 1225 | | # Add here all plugins file you want to load. |
|---|
| | 1244 | # Add here all plugin files you want to load. |
|---|
| 1226 | 1245 | # Plugin files must be .pm files stored in 'plugins' directory. |
|---|
| 1227 | 1246 | # Uncomment LoadPlugin lines to enable a plugin after checking that perl |
|---|
| … | … | |
| 1231 | 1250 | # Perl modules required: None |
|---|
| 1232 | 1251 | # Add some tooltips help on HTML report pages. |
|---|
| 1233 | | # Note that enabled this kind of help will increased HTML report pages size, |
|---|
| | 1252 | # Note that enabling this kind of help will increased HTML report pages size, |
|---|
| 1234 | 1253 | # so server load and bandwidth. |
|---|
| 1235 | 1254 | # |
|---|
| … | … | |
| 1247 | 1266 | # This plugin gives AWStats capability to make reverse DNS lookup on IPv6 |
|---|
| 1248 | 1267 | # addresses. |
|---|
| 1249 | | # Note: If you are interesting in having country report, you should use the |
|---|
| | 1268 | # Note: If you are interested in having country report, you should use the |
|---|
| 1250 | 1269 | # geoipfree or geoip plugin instead of enabled reverse DNS lookup. |
|---|
| 1251 | 1270 | # |
|---|
| … | … | |
| 1254 | 1273 | # Plugin: HashFiles |
|---|
| 1255 | 1274 | # Perl modules required: Storable |
|---|
| 1256 | | # AWStats DNS cache files are read/saved as native hash files. This increase |
|---|
| | 1275 | # AWStats DNS cache files are read/saved as native hash files. This increases |
|---|
| 1257 | 1276 | # DNS cache files loading speed, above all for very large web sites. |
|---|
| 1258 | 1277 | # |
|---|
| … | … | |
| 1268 | 1287 | # This plugin reduces AWStats speed of 8% ! |
|---|
| 1269 | 1288 | # |
|---|
| 1270 | | #LoadPlugin="geoip GEOIP_STANDARD" |
|---|
| | 1289 | #LoadPlugin="geoip GEOIP_STANDARD /pathto/GeoIP.dat" |
|---|
| 1271 | 1290 | |
|---|
| 1272 | 1291 | # Plugin: GeoIPfree |
|---|
| … | … | |
| 1402 | 1421 | |
|---|
| 1403 | 1422 | # You can define your own charts, you choose here what are rows and columns |
|---|
| 1404 | | # keys. This feature is particularly usefull for marketing purpose, tracking |
|---|
| | 1423 | # keys. This feature is particularly useful for marketing purpose, tracking |
|---|
| 1405 | 1424 | # products orders for example. |
|---|
| 1406 | 1425 | # For this, edit all parameters of Extra section. Each set of parameter is a |
|---|
| … | … | |
| 1417 | 1436 | # Put an empty string for no test on code. |
|---|
| 1418 | 1437 | # ExtraSectionConditionX are conditions you can use to count or not the hit, |
|---|
| 1419 | | # Use one of the field condition (URL,URLWITHQUERY,QUERY_STRING,REFERER,UA, |
|---|
| 1420 | | # HOST,extraX) and a regex to match, after a coma. Use "||" for "OR". |
|---|
| | 1438 | # Use one of the field condition |
|---|
| | 1439 | # (URL,URLWITHQUERY,QUERY_STRING,REFERER,UA,HOST,extraX) |
|---|
| | 1440 | # and a regex to match, after a coma. Use "||" for "OR". |
|---|
| 1421 | 1441 | # ExtraSectionFirstColumnTitleX is the first column title of the chart. |
|---|
| 1422 | 1442 | # ExtraSectionFirstColumnValuesX is a string to tell AWStats which field to |
|---|
| 1423 | | # extract value from (URL,URLWITHQUERY,QUERY_STRING,REFERER,UA,HOST,extraX) |
|---|
| | 1443 | # extract value from |
|---|
| | 1444 | # (URL,URLWITHQUERY,QUERY_STRING,REFERER,UA,HOST,VHOST,extraX) |
|---|
| 1424 | 1445 | # and how to extract the value (using regex syntax). Each different value |
|---|
| 1425 | 1446 | # found will appear in first column of report on a different row. Be sure |
|---|
| … | … | |
| 1448 | 1469 | |
|---|
| 1449 | 1470 | |
|---|
| 1450 | | # There is also a global parameter ExtraTrackedRowsLimit that limit the |
|---|
| | 1471 | # There is also a global parameter ExtraTrackedRowsLimit that limits the |
|---|
| 1451 | 1472 | # number of possible rows an ExtraSection can report. This parameter is |
|---|
| 1452 | 1473 | # here to protect too much memory use when you make a bad setup in your |
|---|
| … | … | |
| 1467 | 1488 | # You can include other config files using the directive with the name of the |
|---|
| 1468 | 1489 | # config file. |
|---|
| 1469 | | # This is particularly usefull for users who have a lot of virtual servers, so |
|---|
| | 1490 | # This is particularly useful for users who have a lot of virtual servers, so |
|---|
| 1470 | 1491 | # a lot of config files and want to maintain common values in only one file. |
|---|
| 1471 | 1492 | # Note that when a variable is defined both in a config file and in an |
|---|
| 1472 | 1493 | # included file, AWStats will use the last value read for parameters that |
|---|
| 1473 | 1494 | # contains one value and AWStats will concat all values from both files for |
|---|
| 1474 | | # parameters that are lists of value. |
|---|
| | 1495 | # parameters that are lists of values. |
|---|
| 1475 | 1496 | # |
|---|
| 1476 | 1497 | |
|---|
| r473 |
r619 |
|
| 15 | 15 | |
|---|
| 16 | 16 | # AWStats |
|---|
| 17 | | 30 */2 * * * /usr/share/awstats/tools/awstats_updateall.pl now -awstatsprog=/usr/lib/cgi-bin/awstats/awstats.pl |
|---|
| | 17 | {AWSTATS} |
|---|
| 18 | 18 | |
|---|
| 19 | 19 | # Rootkit Hunter |
|---|
| … | … | |
| 24 | 24 | |
|---|
| 25 | 25 | # delayed tasks END. |
|---|
| 26 | | |
|---|
| r473 |
r619 |
|
| 3 | 3 | |
|---|
| 4 | 4 | # Quota |
|---|
| 5 | | 0 23 * * * {QUOTA_ROOT_DIR}/ispcp-dsk-quota &>{LOG_DIR}/ispcp-qsk-quota.log |
|---|
| | 5 | 0 23 * * * {QUOTA_ROOT_DIR}/ispcp-dsk-quota &>{LOG_DIR}/ispcp-qsk-quota.log |
|---|
| 6 | 6 | |
|---|
| 7 | 7 | # Traffic |
|---|
| 8 | | 0,30 * * * * {TRAFF_ROOT_DIR}/ispcp-srv-traff &>{LOG_DIR}/ispcp-srv-traff.log |
|---|
| 9 | | 0,30 * * * * {TRAFF_ROOT_DIR}/ispcp-vrl-traff &>{LOG_DIR}/ispcp-vrl-traff.log |
|---|
| 10 | | 30 23 * * * {TOOLS_ROOT_DIR}/ispcp-httpd-logs-mngr &>{LOG_DIR}/ispcp-httpd-logs-mngr.log |
|---|
| | 8 | 0,30 * * * * {TRAFF_ROOT_DIR}/ispcp-srv-traff &>{LOG_DIR}/ispcp-srv-traff.log |
|---|
| | 9 | 0,30 * * * * {TRAFF_ROOT_DIR}/ispcp-vrl-traff &>{LOG_DIR}/ispcp-vrl-traff.log |
|---|
| | 10 | 15,45 * * * * {TRAFF_ROOT_DIR}/ispcp-vrl-traff-correction &>{LOG_DIR}/ispcp-vrl-traff-correction.log |
|---|
| | 11 | 30 23 * * * {TOOLS_ROOT_DIR}/ispcp-httpd-logs-mngr &>{LOG_DIR}/ispcp-httpd-logs-mngr.log |
|---|
| 11 | 12 | |
|---|
| 12 | 13 | # Backup |
|---|
| 13 | | 0 1 * * * {BACKUP_ROOT_DIR}/ispcp-backup-all yes &>{LOG_DIR}/ispcp-backup-all-mngr.log |
|---|
| | 14 | 0 1 * * * {BACKUP_ROOT_DIR}/ispcp-backup-all yes &>{LOG_DIR}/ispcp-backup-all-mngr.log |
|---|
| 14 | 15 | |
|---|
| 15 | 16 | # AWStats |
|---|
| 16 | | 30 */2 * * * /usr/share/awstats/tools/awstats_updateall.pl now -awstatsprog=/usr/lib/cgi-bin/awstats/awstats.pl |
|---|
| | 17 | {AWSTATS} |
|---|
| 17 | 18 | |
|---|
| 18 | 19 | # Rootkit Hunter |
|---|
| 19 | | 0 0,12 * * * rkhunter --createlogfile --cronjob |
|---|
| | 20 | 0 0,12 * * * rkhunter --createlogfile --cronjob |
|---|
| 20 | 21 | |
|---|
| 21 | 22 | # [{DMN_NAME}] backup task START. |
|---|
| r514 |
r619 |
|
| 136 | 136 | # AWSTATS data |
|---|
| 137 | 137 | # |
|---|
| 138 | | # Either no or path to the awstats configs dir (mostly: /etc/awstats) |
|---|
| 139 | | AWSTATS_DIR = no |
|---|
| 140 | | |
|---|
| 141 | | AWSTSTS_ROOT_DIR = /var/www/ispcp/engine/awstats |
|---|
| 142 | | |
|---|
| 143 | | AWSTATS_WEB_DIR = /var/www/awstats |
|---|
| | 138 | AWSTATS_ACTIVE = no |
|---|
| | 139 | |
|---|
| | 140 | # could be 'dynamic' = 0 or 'static' = 1 |
|---|
| | 141 | AWSTATS_MODE = 0 |
|---|
| | 142 | |
|---|
| | 143 | AWSTATS_DIR = /etc/awstats |
|---|
| | 144 | |
|---|
| | 145 | AWSTATS_CACHE_DIR = /var/cache/awstats |
|---|
| | 146 | |
|---|
| | 147 | AWSTATS_CONFIG_DIR = /var/www/awstats |
|---|
| | 148 | |
|---|
| | 149 | AWSTATS_ENGINE_DIR = /usr/lib/cgi-bin |
|---|
| | 150 | |
|---|
| | 151 | AWSTATS_WEB_DIR = /usr/share/awstats |
|---|
| | 152 | |
|---|
| 144 | 153 | |
|---|
| 145 | 154 | # |
|---|
| 146 | 155 | # APACHE data |
|---|
| 147 | 156 | # |
|---|
| 148 | | |
|---|
| 149 | 157 | |
|---|
| 150 | 158 | APACHE_NAME = apache2 |
|---|
| r597 |
r619 |
|
| 3325 | 3325 | my $conf_dir = $main::cfg{'CONF_DIR'}; |
|---|
| 3326 | 3326 | |
|---|
| 3327 | | my $awstats_dir = $main::cfg{'AWSTATS_DIR'}; |
|---|
| | 3327 | my $awstats_dir = $main::cfg{'AWSTATS_CONFIG_DIR'}; |
|---|
| 3328 | 3328 | |
|---|
| 3329 | 3329 | my $tpl_dir = "$conf_dir/awstats"; |
|---|
| … | … | |
| 3461 | 3461 | my $dmn_name = @$dmn_data[1]; |
|---|
| 3462 | 3462 | |
|---|
| 3463 | | my $conf_dir = $main::cfg{'CONF_DIR'}; |
|---|
| 3464 | | |
|---|
| 3465 | | my $awstats_dir = $main::cfg{'AWSTATS_DIR'}; |
|---|
| 3466 | | |
|---|
| 3467 | | my $tpl_dir = "$conf_dir/awstats"; |
|---|
| | 3463 | my $awstats_dir = $main::cfg{'AWSTATS_CONFIG_DIR'}; |
|---|
| 3468 | 3464 | |
|---|
| 3469 | 3465 | my $awstats_fname = "awstats.$dmn_name.conf"; |
|---|
| … | … | |
| 3498 | 3494 | my $rs = undef; |
|---|
| 3499 | 3495 | |
|---|
| 3500 | | my $awstats_dir = $main::cfg{'AWSTATS_DIR'}; |
|---|
| | 3496 | my $awstats = $main::cfg{'AWSTATS_ACTIVE'}; |
|---|
| 3501 | 3497 | |
|---|
| 3502 | 3498 | push_el(\@main::el, 'dmn_add_data()', 'Starting...'); |
|---|
| … | … | |
| 3510 | 3506 | } |
|---|
| 3511 | 3507 | |
|---|
| 3512 | | # check wether AWStats is enabled |
|---|
| 3513 | | if ($awstats_dir ne 'no') { |
|---|
| | 3508 | # check whether AWStats is enabled |
|---|
| | 3509 | if ($awstats ne 'no') { |
|---|
| 3514 | 3510 | $rs = dmn_add_awstats_data($dmn_data); |
|---|
| 3515 | 3511 | return $rs if ($rs != 0); |
|---|
| … | … | |
| 3555 | 3551 | } |
|---|
| 3556 | 3552 | |
|---|
| 3557 | | my $awstats_dir = $main::cfg{'AWSTATS_DIR'}; |
|---|
| | 3553 | my $awstats = $main::cfg{'AWSTATS_ACTIVE'}; |
|---|
| 3558 | 3554 | |
|---|
| 3559 | 3555 | $rs = dmn_change_named_data($dmn_data); |
|---|
| … | … | |
| 3569 | 3565 | return $rs if ($rs != 0); |
|---|
| 3570 | 3566 | |
|---|
| 3571 | | # check wether AWStats is enabled |
|---|
| 3572 | | if ($awstats_dir ne 'no') { |
|---|
| | 3567 | # check whether AWStats is enabled |
|---|
| | 3568 | if ($awstats ne 'no') { |
|---|
| 3573 | 3569 | $rs = dmn_change_awstats_data($dmn_data); |
|---|
| 3574 | 3570 | return $rs if ($rs != 0); |
|---|
| … | … | |
| 3592 | 3588 | my $rs = undef; |
|---|
| 3593 | 3589 | |
|---|
| 3594 | | my $awstats_dir = $main::cfg{'AWSTATS_DIR'}; |
|---|
| | 3590 | my $awstats = $main::cfg{'AWSTATS_ACTIVE'}; |
|---|
| 3595 | 3591 | |
|---|
| 3596 | 3592 | push_el(\@main::el, 'dmn_del_data()', 'Starting...'); |
|---|
| … | … | |
| 3604 | 3600 | } |
|---|
| 3605 | 3601 | |
|---|
| 3606 | | # check wether AWStats is enabled |
|---|
| 3607 | | if ($awstats_dir ne 'no') { |
|---|
| | 3602 | # check whether AWStats is enabled |
|---|
| | 3603 | if ($awstats ne 'no') { |
|---|
| 3608 | 3604 | $rs = dmn_del_awstats_data($dmn_data); |
|---|
| 3609 | 3605 | |
|---|
| 3610 | 3606 | return $rs if ($rs != 0); |
|---|
| 3611 | | } |
|---|
| | 3607 | } |
|---|
| 3612 | 3608 | |
|---|
| 3613 | 3609 | $rs = dmn_del_named_data($dmn_data); |
|---|
| r610 |
r619 |
|
| 121 | 121 | $main::ua{'hostname'} = $rdata; |
|---|
| 122 | 122 | $main::ua{'hostname_local'} = ( ($1) ? $1 : $4); |
|---|
| 123 | | + $main::ua{'hostname_local'} =~ s/^([\w][\w-]{0,253}[\w])\.(.*?)$/$1/; |
|---|
| | 123 | $main::ua{'hostname_local'} =~ s/^([\w][\w-]{0,253}[\w])\.(.*?)$/$1/; |
|---|
| 124 | 124 | } else { |
|---|
| 125 | 125 | |
|---|
| … | … | |
| 594 | 594 | } |
|---|
| 595 | 595 | |
|---|
| | 596 | ask_awstats_on { |
|---|
| | 597 | |
|---|
| | 598 | my ($rs, $rdata) = (undef, undef); |
|---|
| | 599 | |
|---|
| | 600 | push_el(\@main::el, 'ask_awstats_on()', 'Starting...'); |
|---|
| | 601 | |
|---|
| | 602 | my $qmsg = "\n Activate AWStats [no]: "; |
|---|
| | 603 | |
|---|
| | 604 | print STDOUT $qmsg; |
|---|
| | 605 | |
|---|
| | 606 | $rdata = readline(\*STDIN); |
|---|
| | 607 | chop($rdata); |
|---|
| | 608 | |
|---|
| | 609 | if (!defined($rdata) || $rdata eq '') { |
|---|
| | 610 | $main::ua{'awstats_on'} = 'no'; |
|---|
| | 611 | } |
|---|
| | 612 | else { |
|---|
| | 613 | if ($rdata eq 'yes' || $rdata eq 'y') { |
|---|
| | 614 | $main::ua{'awstats_on'} = 'yes'; |
|---|
| | 615 | } |
|---|
| | 616 | else if ($rdata eq 'no' || $rdata eq 'n') { |
|---|
| | 617 | $main::ua{'awstats_on'} = 'no'; |
|---|
| | 618 | } |
|---|
| | 619 | else { |
|---|
| | 620 | print STDOUT "\n Only '(y)es' and '(n)o' are allowed!"; |
|---|
| | 621 | return 1; |
|---|
| | 622 | } |
|---|
| | 623 | } |
|---|
| | 624 | |
|---|
| | 625 | push_el(\@main::el, 'ask_awstats_on()', 'Ending...'); |
|---|
| | 626 | |
|---|
| | 627 | return 0; |
|---|
| | 628 | } |
|---|
| | 629 | |
|---|
| | 630 | ask_awstats_dyn { |
|---|
| | 631 | |
|---|
| | 632 | my ($rs, $rdata) = (undef, undef); |
|---|
| | 633 | |
|---|
| | 634 | push_el(\@main::el, 'ask_awstats_dyn()', 'Starting...'); |
|---|
| | 635 | |
|---|
| | 636 | my $qmsg = "\n AWStats Mode ('(d)ynamic' or '(s)tatic') [dynamic]: "; |
|---|
| | 637 | |
|---|
| | 638 | print STDOUT $qmsg; |
|---|
| | 639 | |
|---|
| | 640 | $rdata = readline(\*STDIN); |
|---|
| | 641 | chop($rdata); |
|---|
| | 642 | |
|---|
| | 643 | if (!defined($rdata) || $rdata eq '') { |
|---|
| | 644 | $main::ua{'awstats_dyn'} = '0'; |
|---|
| | 645 | } |
|---|
| | 646 | else { |
|---|
| | 647 | if ($rdata eq 'dynamic' || $rdata eq 'd') { |
|---|
| | 648 | $main::ua{'awstats_dyn'} = '0'; |
|---|
| | 649 | } |
|---|
| | 650 | else if ($rdata eq 'static' || $rdata eq 's') { |
|---|
| | 651 | $main::ua{'awstats_dyn'} = '1'; |
|---|
| | 652 | } |
|---|
| | 653 | else { |
|---|
| | 654 | print STDOUT "\n Only '(d)ynamic' or '(s)tatic' are allowed!"; |
|---|
| | 655 | return 1; |
|---|
| | 656 | } |
|---|
| | 657 | } |
|---|
| | 658 | |
|---|
| | 659 | push_el(\@main::el, 'ask_awstats_dyn()', 'Ending...'); |
|---|
| | 660 | |
|---|
| | 661 | return 0; |
|---|
| | 662 | } |
|---|
| | 663 | |
|---|
| 596 | 664 | sub user_dialog { |
|---|
| 597 | 665 | |
|---|
| … | … | |
| 686 | 754 | } while ($rs == 1); |
|---|
| 687 | 755 | |
|---|
| | 756 | do { |
|---|
| | 757 | |
|---|
| | 758 | $rs = ask_awstats_on(); |
|---|
| | 759 | |
|---|
| | 760 | } while ($rs == 1); |
|---|
| | 761 | |
|---|
| | 762 | do { |
|---|
| | 763 | |
|---|
| | 764 | $rs = ask_awstats_dyn(); |
|---|
| | 765 | |
|---|
| | 766 | } while ($rs == 1); |
|---|
| | 767 | |
|---|
| | 768 | |
|---|
| 688 | 769 | push_el(\@main::el, 'user_dialog()', "hostname: $main::ua{'hostname'}"); |
|---|
| 689 | 770 | |
|---|
| 690 | | push_el(\@main::el, 'user_dialog()', "eth: $main::ua{'eth_ip'}"); |
|---|
| 691 | | |
|---|
| 692 | | push_el(\@main::el, 'user_dialog()', "panel_vhost: $main::ua{'admin_vhost'}"); |
|---|
| 693 | | |
|---|
| 694 | | push_el(\@main::el, 'user_dialog()', "db_host: $main::ua{'db_host'}"); |
|---|
| 695 | | |
|---|
| 696 | | push_el(\@main::el, 'user_dialog()', "db_name: $main::ua{'db_name'}"); |
|---|
| 697 | | |
|---|
| 698 | | push_el(\@main::el, 'user_dialog()', "db_user: $main::ua{'db_user'}"); |
|---|
| 699 | | |
|---|
| 700 | | push_el(\@main::el, 'user_dialog()', "db_password: $main::ua{'db_password'}"); |
|---|
| 701 | | |
|---|
| 702 | | push_el(\@main::el, 'user_dialog()', "admin: $main::ua{'admin'}"); |
|---|
| 703 | | |
|---|
| 704 | | push_el(\@main::el, 'user_dialog()', "admin_password: $main::ua{'admin_password'}"); |
|---|
| 705 | | |
|---|
| 706 | | push_el(\@main::el, 'user_dialog()', "admin_email: $main::ua{'admin_email'}"); |
|---|
| 707 | | |
|---|
| 708 | | push_el(\@main::el, 'user_dialog()', 'Ending...'); |
|---|
| | 771 | push_el(\@main::el, 'user_dialog()', "eth: $main::ua{'eth_ip'}"); |
|---|
| | 772 | |
|---|
| | 773 | push_el(\@main::el, 'user_dialog()', "panel_vhost: $main::ua{'admin_vhost'}"); |
|---|
| | 774 | |
|---|
| | 775 | push_el(\@main::el, 'user_dialog()', "db_host: $main::ua{'db_host'}"); |
|---|
| | 776 | |
|---|
| | 777 | push_el(\@main::el, 'user_dialog()', "db_name: $main::ua{'db_name'}"); |
|---|
| | 778 | |
|---|
| | 779 | push_el(\@main::el, 'user_dialog()', "db_user: $main::ua{'db_user'}"); |
|---|
| | 780 | |
|---|
| | 781 | push_el(\@main::el, 'user_dialog()', "db_password: $main::ua{'db_password'}"); |
|---|
| | 782 | |
|---|
| | 783 | push_el(\@main::el, 'user_dialog()', "admin: $main::ua{'admin'}"); |
|---|
| | 784 | |
|---|
| | 785 | push_el(\@main::el, 'user_dialog()', "admin_password: $main::ua{'admin_password'}"); |
|---|
| | 786 | |
|---|
| | 787 | push_el(\@main::el, 'user_dialog()', "admin_email: $main::ua{'admin_email'}"); |
|---|
| | 788 | |
|---|
| | 789 | push_el(\@main::el, 'user_dialog()', "admin_email: $main::ua{'awstats_on'}"); |
|---|
| | 790 | |
|---|
| | 791 | push_el(\@main::el, 'user_dialog()', "admin_email: $main::ua{'awstats_dyn'}"); |
|---|
| | 792 | |
|---|
| | 793 | push_el(\@main::el, 'user_dialog()', "Ending..."); |
|---|
| 709 | 794 | |
|---|
| 710 | 795 | return 0; |
|---|
| … | … | |
| 1055 | 1140 | $rs = set_conf_val('DEFAULT_ADMIN_ADDRESS', $main::ua{'admin_email'}); |
|---|
| 1056 | 1141 | |
|---|
| | 1142 | return $rs if ($rs != 0); |
|---|
| | 1143 | |
|---|
| | 1144 | $rs = set_conf_val('AWSTATS_ACTIVE', $main::ua{'awstats_on'}); |
|---|
| | 1145 | |
|---|
| | 1146 | return $rs if ($rs != 0); |
|---|
| | 1147 | |
|---|
| | 1148 | $rs = set_conf_val('AWSTATS_MODE', $main::ua{'avstats_dyn'}); |
|---|
| | 1149 | |
|---|
| 1057 | 1150 | $rs = store_conf(); |
|---|
| 1058 | 1151 | |
|---|
| … | … | |
| 1288 | 1381 | my $cfg_dir = "$main::cfg{'GUI_ROOT_DIR'}/tools/pma/"; |
|---|
| 1289 | 1382 | my $tmp_dir = "/var/www/ispcp/gui/phptmp"; |
|---|
| 1290 | | |
|---|
| | 1383 | |
|---|
| 1291 | 1384 | my @rand_data = ('A'..'Z', 'a'..'z', '0'..'9', '.', '/', '-', '*', ',', ':', ';'); |
|---|
| 1292 | 1385 | |
|---|
| 1293 | 1386 | my ($i, $blowfish) = ('', ''); |
|---|
| 1294 | | |
|---|
| | 1387 | |
|---|
| 1295 | 1388 | for ($i = 0; $i < 31; $i++) { |
|---|
| 1296 | | |
|---|
| | 1389 | |
|---|
| 1297 | 1390 | $blowfish .= $rand_data[ rand() * ($#rand_data + 1) ]; |
|---|
| 1298 | | |
|---|
| | 1391 | |
|---|
| 1299 | 1392 | } |
|---|
| 1300 | 1393 | |
|---|
| … | … | |
| 1365 | 1458 | return $rs if ($rs != 0); |
|---|
| 1366 | 1459 | |
|---|
| | 1460 | if ($main::cfg{'AWSTATS_ACTIVE'} eq 'on') { |
|---|
| | 1461 | my $awstats = "15 6 * * * $main::cfg{'ROOT_DIR'}/engine/awstats/awstats_updateall.pl now -awstatsprog=$main::cfg{'AWSTATS_ENGINE_DIR'}/awstats.pl"; |
|---|
| | 1462 | } |
|---|
| | 1463 | else { |
|---|
| | 1464 | my $awstats = ''; |
|---|
| | 1465 | } |
|---|
| | 1466 | |
|---|
| 1367 | 1467 | my %tag_hash = ( |
|---|
| 1368 | 1468 | '{LOG_DIR}' => $main::cfg{'LOG_DIR'}, |
|---|
| … | … | |
| 1370 | 1470 | '{TRAFF_ROOT_DIR}' => $main::cfg{'TRAFF_ROOT_DIR'}, |
|---|
| 1371 | 1471 | '{TOOLS_ROOT_DIR}' => $main::cfg{'TOOLS_ROOT_DIR'}, |
|---|
| 1372 | | '{BACKUP_ROOT_DIR}' => $main::cfg{'BACKUP_ROOT_DIR'} |
|---|
| | 1472 | '{BACKUP_ROOT_DIR}' => $main::cfg{'BACKUP_ROOT_DIR'}, |
|---|
| | 1473 | '{AWSTATS}' => $awstats |
|---|
| 1373 | 1474 | ); |
|---|
| 1374 | 1475 | |
|---|
| … | … | |
| 1420 | 1521 | |
|---|
| 1421 | 1522 | push_el(\@main::el, 'setup_resolver()', 'Starting...'); |
|---|
| 1422 | | |
|---|
| | 1523 | |
|---|
| 1423 | 1524 | my $resolv_file = "/etc/resolv.conf"; |
|---|
| 1424 | 1525 | |
|---|
| … | … | |
| 1426 | 1527 | |
|---|
| 1427 | 1528 | $cmd = "$main::cfg{'CMD_CP'} -p -f $resolv_file $resolv_file.bkp"; |
|---|
| 1428 | | |
|---|
| | 1529 | |
|---|
| 1429 | 1530 | $rs = sys_command_rs($cmd); |
|---|
| 1430 | | |
|---|
| | 1531 | |
|---|
| 1431 | 1532 | return $rs if ($rs != 0); |
|---|
| 1432 | 1533 | |
|---|
| … | … | |
| 1436 | 1537 | $data .= "nameserver $main::cfg{'SECONDARY_DNS'}\n"; |
|---|
| 1437 | 1538 | } |
|---|
| 1438 | | |
|---|
| | 1539 | |
|---|
| 1439 | 1540 | $resolv_data = get_file($resolv_file); |
|---|
| 1440 | | |
|---|
| | 1541 | |
|---|
| 1441 | 1542 | # Comment this line if removing the existing nameservers causes any problem |
|---|
| 1442 | 1543 | $resolv_data =~ s/^nameserver[[:space:]]+[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$//g; |
|---|
| 1443 | | |
|---|
| | 1544 | |
|---|
| 1444 | 1545 | $data .= $resolv_data; |
|---|
| 1445 | 1546 | |
|---|
| … | … | |
| 1465 | 1566 | |
|---|
| 1466 | 1567 | my $ip = $main::ua{'eth_ip'}; |
|---|
| 1467 | | |
|---|
| | 1568 | |
|---|
| 1468 | 1569 | my $hosts_file = "/etc/hosts"; |
|---|
| 1469 | | |
|---|
| | 1570 | |
|---|
| 1470 | 1571 | $cmd = "$main::cfg{'CMD_CP'} -p -f $hosts_file $hosts_file.bkp"; |
|---|
| 1471 | | |
|---|
| | 1572 | |
|---|
| 1472 | 1573 | $rs = sys_command_rs($cmd); |
|---|
| 1473 | | |
|---|
| 1474 | | return $rs if ($rs != 0); |
|---|
| 1475 | | |
|---|
| | 1574 | |
|---|
| | 1575 | return $rs if ($rs != 0); |
|---|
| | 1576 | |
|---|
| 1476 | 1577 | $data = "# 'hosts' file configuration.\n\n"; |
|---|
| 1477 | 1578 | $data .= "127.0.0.1\t$hostname_local\tlocalhost\n"; |
|---|
|