Installation MediaWiki: Difference between revisions

From ICO wiki
Jump to navigationJump to search
Lphanvan (talk | contribs)
Lphanvan (talk | contribs)
 
(22 intermediate revisions by the same user not shown)
Line 1: Line 1:
== Mediawiki installation  ==
== Mediawiki installation  ==
Autor: Lauri Vosandi
Autor: Lauri Vosandi


'''REMEMBER:''' all of the installation executed by these command line below need to be under '''ROOT''':
'''REMEMBER:''' all of the installation executed by these command line below need to be under '''ROOT''':
Line 7: Line 8:
You should install apache2, mysql-server and php by root:<br>  
You should install apache2, mysql-server and php by root:<br>  
<pre>
<pre>
root@kaka:~#apt-get install apache2 mysql-server php
lauri@kaka: sudo -i
 
sudo apt-get install php libapache2-mod-php php-mcrypt php-mysql


sudo apt-get install php7.0-mbstring
root@kaka:~# apt-get install apache2 mysql-server php


git clone https://gerrit.wikimedia.org/r/p/mediawiki/vendor.git
root@kaka:~# sudo apt-get install php libapache2-mod-php php-mcrypt php-mysql
 
service apache2 restart


root@kaka:~# apt install python-minimal
</pre>
</pre>


Line 31: Line 29:
root@kaka:/var/www/html# rm index.html
root@kaka:/var/www/html# rm index.html


root@kaka:/var/www/html# git clone //insert link here.
root@kaka:/var/www/html# git clone https://github.com/lauriitcollege/core.git


root@kaka:/var/www/html# ls
root@kaka:/var/www/html# ls
Line 37: Line 35:
If it shows directory "core", keep following:
If it shows directory "core", keep following:
<pre>
<pre>
root@kaka:/var/www/html# cd /core
root@kaka:/var/www/html# chmod 777 core
 
root@kaka:/var/www/html# cd core


root@kaka:/var/www/html/core# cp -r * /var/www/html/
root@kaka:/var/www/html/core# cp -r * /var/www/html/
Line 43: Line 43:
Check files from core already copied to main folder of html
Check files from core already copied to main folder of html
<pre>
<pre>
root@kaka:/var/www/html/core# ls
root@kaka:/var/www/html/core# cd /var/www/html/
 
 
 


root@kaka:/var/www/html/# ls
</pre>
</pre>
Now, try to refresh the page.
Now, try to refresh the page.
Line 55: Line 53:
After refreshing the page. It could give you some of error which is normal.
After refreshing the page. It could give you some of error which is normal.


First you need to add plugins:
<pre>
root@kaka:/var/www/html/#: python plugins.py
</pre>
If it shows you this error related to '''php''':
If it shows you this error related to '''php''':
<pre>
<pre>
Line 67: Line 70:


<pre>
<pre>
lauri@kaka: sudo -i
root@kaka:~# cd /var/www/html
root@kaka:/var/www/html# git clone https://gerrit.wikimedia.org/r/p/mediawiki/vendor.git
root@kaka:/var/www/html# git clone https://gerrit.wikimedia.org/r/p/mediawiki/vendor.git


Line 76: Line 75:
</pre>
</pre>


if it demands '''mbstring''' or something else:
if it demands '''mbstring''' and '''xml''' or something else:


<pre>
<pre>
root@kaka:/var/www/html# apt-get install php-mbstring
root@kaka:/var/www/html# apt-get install php-mbstring
root@kaka:/var/www/html# apt-get install php-xml
root@kaka:/var/www/html# service apache2 restart
</pre>
</pre>


Line 98: Line 101:
After finish your configuration, it will automatically download the '''Localsetting.php''' to your download directory or you should click to download it manually. Follow those command line.
After finish your configuration, it will automatically download the '''Localsetting.php''' to your download directory or you should click to download it manually. Follow those command line.


You need to copy '''Localsetting.php'''  to /html directory  
You need to copy '''Localsetting.php'''  to /var/www/html/ directory  


***NOTE: your user folder is different from mine "lauri"
***NOTE: your user folder is different from mine "lauri"
Line 111: Line 114:
</pre>
</pre>


Refresh the page to see its change.
Refresh the page to see its change Or Click to "if you have install your Localsetting you can enter the wiki"


=== Install skin for wiki  ===
=== Install skin for wiki  ===
Line 132: Line 135:
<pre>
<pre>


root@kaka:/home/lauri/html/# chmod 777 skins
root@kaka:/var/www/html/# rm -r skins/
 
root@kaka:/home/lauri/html/# rm -r skins/


root@kaka:/home/lauri/html/# mkdir skins  # Remember to make a new skins folder, and check if it has created.
root@kaka:/var/www/html/# mkdir skins  # Remember to make a new skins folder, and check if it has created.


</pre>
</pre>
Line 142: Line 143:
Now download the skin package:
Now download the skin package:
<pre>
<pre>
root@kaka:/home/lauri/html/# git clone //insert link here.
root@kaka:/var/www/html/# git clone https://github.com/lauriitcollege/Vector.git
 
root@kaka:/var/www/html/# cd Vector/
 
root@kaka:/var/www/html/Vector/# tar -xzf Vector-REL1_27-d11a80a.tar.gz -C /var/www/html/skins
 
root@kaka:/var/www/html/Vector/# cd /var/www/html/skins


root@kaka:/home/lauri/html/# tar -xzf PACKAGE_NAME.tar.gz -C /var/www/html/skins
root@kaka:/var/www/html/skins/# ls      #check if Vector folder has been copied.


</pre>
</pre>
Line 154: Line 161:


<pre>
<pre>
root@kaka:/home/lauri/html/: nano Localsetting.php
root@kaka:/var/www/html/skins/# cd /var/www/html/
 
root@kaka:/var/www/html/: nano LocalSetting.php
</pre>
</pre>
and Add:
and Add:
<pre>
<pre>
wfLoadSkin( 'Vector' )
wfLoadSkin( 'Vector' );
 
sudo service apache2 restart  # restart apache2
</pre>
</pre>

Latest revision as of 00:57, 21 September 2016

Mediawiki installation

Autor: Lauri Vosandi


REMEMBER: all of the installation executed by these command line below need to be under ROOT:

Mediawiki Download and Requirements

You should install apache2, mysql-server and php by root:

lauri@kaka: sudo -i

root@kaka:~# apt-get install apache2 mysql-server php

root@kaka:~# sudo apt-get install php libapache2-mod-php php-mcrypt php-mysql

root@kaka:~# apt install python-minimal

Download

I recommend you install the newest version for wiki. Followed these command line below:

lauri@kaka: sudo -i

root@kaka: apt install git

root@kaka:~# cd /var/www/html

root@kaka:/var/www/html# rm index.html

root@kaka:/var/www/html# git clone https://github.com/lauriitcollege/core.git

root@kaka:/var/www/html# ls

If it shows directory "core", keep following:

root@kaka:/var/www/html# chmod 777 core

root@kaka:/var/www/html# cd core

root@kaka:/var/www/html/core# cp -r * /var/www/html/

Check files from core already copied to main folder of html

root@kaka:/var/www/html/core# cd /var/www/html/

root@kaka:/var/www/html/# ls

Now, try to refresh the page.

Solving Problems

After refreshing the page. It could give you some of error which is normal.

First you need to add plugins:


root@kaka:/var/www/html/#: python plugins.py

If it shows you this error related to php:

sudo apt-get install php libapache2-mod-php php-mcrypt php-mysql

sudo service apache2 restart

If it shows you this error: "some external libraries that MediaWiki requires are no longer"

you need to install:

root@kaka:/var/www/html# git clone https://gerrit.wikimedia.org/r/p/mediawiki/vendor.git

root@kaka:/var/www/html# service apache2 restart

if it demands mbstring and xml or something else:

root@kaka:/var/www/html# apt-get install php-mbstring

root@kaka:/var/www/html# apt-get install php-xml

root@kaka:/var/www/html# service apache2 restart

Installation

Now, refresh the page, if it gives no error, you need to click to install your wiki and configure your page:

Keep following the step what wiki page gives.

- Configure Database where you need to put your root account as well as Administrator account for main page.

- Configure wiki's name in which you will define your wiki page's name

- Configure some basic website interface such as language..so forth.

Localsetting.php

After finish your configuration, it will automatically download the Localsetting.php to your download directory or you should click to download it manually. Follow those command line.

You need to copy Localsetting.php to /var/www/html/ directory

      • NOTE: your user folder is different from mine "lauri"

lauri@kaka: sudo -i

root@kaka:~# cd /home/lauri/Downloads/

root@kaka:/home/lauri/Downloads/# cp -r Localsetthing.php /var/www/html/

Refresh the page to see its change Or Click to "if you have install your Localsetting you can enter the wiki"

Install skin for wiki

After copying the Localsetting.php to your own html folder. Refresh the page if nothing changes it will give you the message below:

"Whoops! The default skin for your wiki, defined in $wgDefaultSkin as vector, is not available."

it means you need to install the skin (theme) for wiki. Here I will take Vector ( skin's name ) to install.


lauri@kaka: sudo -i

root@kaka:~# cd /var/www/html/

Here, you have to remove the original skins folder and create the new one. Following:


root@kaka:/var/www/html/# rm -r skins/

root@kaka:/var/www/html/# mkdir skins   # Remember to make a new skins folder, and check if it has created.

Now download the skin package:

root@kaka:/var/www/html/# git clone https://github.com/lauriitcollege/Vector.git

root@kaka:/var/www/html/# cd Vector/

root@kaka:/var/www/html/Vector/# tar -xzf Vector-REL1_27-d11a80a.tar.gz -C /var/www/html/skins

root@kaka:/var/www/html/Vector/# cd /var/www/html/skins

root@kaka:/var/www/html/skins/# ls       #check if Vector folder has been copied.

Check the Vector folder has already in the skins folder. If it does, One more step to finish your Wiki installation.

Now open the Localsetting.php and add the line in the end: ;


root@kaka:/var/www/html/skins/# cd /var/www/html/

root@kaka:/var/www/html/: nano LocalSetting.php

and Add:

wfLoadSkin( 'Vector' );

sudo service apache2 restart  # restart apache2