DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:statistics

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
plugin:statistics [2016-08-30 11:47] – [Report Images not rendering] 194.73.108.104plugin:statistics [2024-02-09 22:20] (current) Aleksandr
Line 6: Line 6:
 email      : andi@splitbrain.org email      : andi@splitbrain.org
 type       : admin, action type       : admin, action
-lastupdate : 2016-08-17 +lastupdate : 2024-01-30 
-compatible : Hrun, Ponder Stibbons, Binky, Weatherwax+compatible : Hrun, Ponder Stibbons, Binky, Weatherwax, Elenor of Tsort, Detritus
 depends    :  depends    : 
 conflicts  conflicts 
Line 68: Line 68:
 ===== Installing ===== ===== Installing =====
  
-  - Install the plugin through the [[plugin:Plugin]] Manager or manually. +==== Requirements ==== 
-    - Install php5 mysqli ((for Debian/Ubuntu apt-get install php5-mysql or CentOS etc sudo yum install php-mysqli))  + 
-  - Create the MySQL database.  Without this you wont be **able** to do the next step.+  * A MySQL datatabase 
 +  * mysqli extension for PHP 
 +  * libgd extension for PHP 
 + 
 +==== Installation ==== 
 + 
 +  - Install the plugin through the [[plugin:Extension]] Manager or manually. 
 +  - Create the MySQL database (see below).  Without this you wont be **able** to do the next step.
   - Create the needed MySQL tables with the provided ''db.sql'' file    - Create the needed MySQL tables with the provided ''db.sql'' file 
   - Configure the database access through the [[plugin:config|Config Manager]]   - Configure the database access through the [[plugin:config|Config Manager]]
 +
 +==== DB creation ====
 +
 +On the shell run the following commands:
 +<code>
 +# mysql -u root -p
 +MariaDB [(none)]> CREATE DATABASE stats;
 +MariaDB [(none)]> \q
 +</code>
  
 To create the needed MySQL tables you can  To create the needed MySQL tables you can 
Line 78: Line 94:
   - either use phpmyadmin's import function    - either use phpmyadmin's import function 
      * Select the database that is used by your DokuWiki and chose "Import" from the top-menu, then upload the file.      * Select the database that is used by your DokuWiki and chose "Import" from the top-menu, then upload the file.
-  - import manually using MySQL in your shell  +  - import manually using MySQL in your shell <code>
- +
-**Method 1** +
-<code>+
 # mysql -u db_user -p your_dokuwiki_database < /full/path/to/db.sql # mysql -u db_user -p your_dokuwiki_database < /full/path/to/db.sql
-</code> 
- 
-**Method 2** 
-<code> 
-# mysql -u db_user -p your_dokuwiki_database 
-Enter password: 
-[...] 
-Type 'help;' or '\h' for help. Type '\c' to clear the buffer. 
- 
-mysql> \. /full/path/to/db.sql 
 </code> </code>
  
Line 112: Line 115:
     * when fixed, stats about search bots could be added     * when fixed, stats about search bots could be added
   * the search word parsing is a bit flaky ("don't" is two words)   * the search word parsing is a bit flaky ("don't" is two words)
- 
-===== Known Issues ===== 
-==== Wiki becomes inaccessible ==== 
- 
- 
-**Symptoms: ** Wiki becomes completely inaccessible after install and Databse setup 
- 
-**Cause: ** There is a missing MySQL Component not included in the standard installation of MySQL for the Linux distribution. 
- 
-With MySQL components missing the whole wiki is rendered inaccessible due to MySQL transactions failing prior to logins or any user actions being logged or at least being attempted to log. Reviewing the apache logs revealed my particular issue and exposed the missing components. 
- 
-<code bash> 
-# find all the recent logs being generated on the server in the last 5 minutes only 
-  
-  find / -name '*.log' -mmin -5 
- 
-# the results on my Ubuntu server: 
- 
-/var/log/auth.log 
-/var/log/apache2/error.log 
-/var/log/apache2/access.log 
- 
-# reviewing the apache error log showed: 
-# command: 
-   
-  tail /var/log/apache2/error.log 
- 
-# result: 
- 
-[Tue Aug 30 07:17:08.713698 2016] [:error] [pid 1466] [client xxx.xx.xxx.xx:62175] PHP Fatal error:  Call to undefined function mysqli_connect() in /var/www/wiki/lib/plugins/statistics/helper.php on line 73, referer: http://www.myserver.net/doku.php/linux:shell_scripts?do=login&sectok=ab148cc7681f1269efe3997b20cd5aa2 
- 
-</code> 
- 
-The fix was to install the missing component either php-mysqli((RedHat/CentOS etc)) or php5-mysql((required for Debian/Ubuntu)), depending on the Linux distribution you use.  
- 
-==== Report Images not rendering ==== 
- 
-**Error:** from the apache log again: PHP Fatal error:  Call to undefined function imagecreatetruecolor() 
- 
-**Solution:** apt-get install php5-gd((fix for Debian/Ubuntu, might need another library for other distros.)) 
- 
- 
  
plugin/statistics.1472550433.txt.gz · Last modified: 2016-08-30 11:47 by 194.73.108.104

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki