exp:expviewcountcollect
Bring the access logs of every node that serves the installation to the node that counts the page views.
Script bin/php/expviewcountcollect.php, code in kernel/private/classes/commands/expviewcountcollect.php. Run it from the installation root, as the user the web server runs as:
./console exp:expviewcountcollect --help
./console exp:viewcount:collect --help
php bin/php/expviewcountcollect.php --helpHelp text
Bring the access logs of every node that serves the installation to the node that counts them
Each node's web server writes its own log. On the node PrimaryCommand names, this takes over the
count state of the node that counted before and copies every node's logs (logfile.ini
[ViewCountSettings] Nodes[], [AccessLogFileSettings] StorageDir/LogFileName and LogFiles[]) to
MirrorDir/<node>/<path>; exp:viewcount:update then counts each copy from where it stopped.
./console exp:viewcount:collect copy the logs (on the counting node only)
./console exp:viewcount:collect --dry-run what it would copy, nothing written
./console exp:viewcount:collect --all-siteaccesses the logs of every siteaccess, not the administrations
./console exp:viewcount:collect --force here, whatever PrimaryCommand says
./console exp:viewcount:collect --allow-root-user as root (logs only root may read); the copies
go to the owner of the var folder
Exit code: 0 fine (also: not the counting node), 1 an error (no log could be copied, PrimaryCommand
gave no answer), 2 usage error.Options
| Option | Value | Help |
|---|---|---|
--dry-run | Report what would be copied, copy nothing | |
--all-siteaccesses | The logs of every siteaccess of AvailableSiteAccessList, except the administrations | |
--siteaccess-list | required | The logs of these siteaccesses, comma separated (default: logfile.ini [ViewCountSettings] SiteAccessList[], else the siteaccess of -s) |
--force | Collect here, whatever PrimaryCommand says | |
--format | required | text (default) or json |
Read from the option definitions in the code (startup(), getOptions(), options() or ezcConsoleOption). Every script also takes the standard options of the script framework (--help, --siteaccess, --debug, --quiet, --allow-root-user ...).
Related
Generated by ./console exp:help:examples from bin/php/expviewcountcollect.php, kernel/private/classes/commands/expviewcountcollect.php. Do not edit this page: change the source and generate again (how). Free documentation: GFDL 1.3 or later.