Manual:A MediaWiki telepítése

From mediawiki.org
This page is a translated version of the page Manual:Installing MediaWiki and the translation is 31% complete.
Outdated translations are marked like this.

Ez a lap leírja a MediaWiki manuális telepítéséhez szükséges lépéseket. További konfigurációs lépésekhez lásd: Kézikönyv:Rendszeradminisztráció#Beállítás.

MediaWiki installation requires basic familiarity with using a web host. It is easier if you have some experience with Apache (web server software), PHP and MySQL/MariaDB (database). További segítséget a Project: Support desk lapon kérhetsz.

A függelékek szakasz hivatkozásokat tartalmaz a manuális telepítés egyszerűbb alternatíváira, valamint telepítési megjegyzésekre speciális rendszerbeállítások esetén.

Már működő MediaWiki frissítéséhez olvasd el a frissítési útmutatót.

A telepítési követelmények ellenőrzése

Check that your system meets the installation requirements.

Make sure to also check the Kiadási megjegyzések of the MediaWiki version that you plan to install.

A MediaWiki letöltése

Download the MediaWiki tar file from the official download page.

Generally, if you're using a production environment, you want to be running the latest stable release, which is MediaWiki 1.41.0.

Extract the MediaWiki software

A letölthető állományok .tar.gz vagy .zip formátumú archívumok, vagyis használat előtt ki kell őket csomagolni. Ez történhet helyben (később FTP-n feltöltéssel) vagy egyből a webszerveren.

Ezt Windowson például a 7-Zip (ingyenes), WinZip, WinRAR vagy IZArc (ingyenes) programokkal lehet megtenni.

Linuxon és Mac OS X-en a beépített untar módszerrel lehet őket kibontani: tar -xzvf mediawiki-*.tar.gz

If you uncompress the archive file while being the root/admin user, you may want to change file ownership afterwards, depending on your setup. On Linux systems, the command would be using chown as the following: chown -R <new_owner_user> <mediawiki_folder> More info: Manual:Security#File_permissions


Fájlok feltöltése a szerveredre

Ha még nem töltötted fel a fájlokat a webszerverre, tedd meg most.

Erre az alábbi módokon van lehetőséged:

  1. a tömörített állomány felmásolásával
  2. FTP-klienssel – például FileZilla (Windows, Linux, macOS) vagy Cyberduck (Windows, macOS)
  3. by using software already provided by your hosting service, such as the cPanel File Manager

Ha a szoftverben van „feltöltött állományok neveinek kisbetűsre változtatása” opció, kapcsold ki.

Ha installáltad az Apache-t, a telepítési útvonalat a httpd.conf állomány tárolja (ez a [$docroot DocumentRoot] könyvtárban van; valószínűleg $1 vagy {{$2|apache-könyvtár}}). By default, this is /var/www/ or <apache-folder>/htdocs.

The exact location of the Apache server settings and directories file httpd.conf depends on your operating system. Debian és Ubuntu alatt az Apache szerver beállításai és könyvtárai a /etc/apache2/apache2.conf fájlban vannak. In Red Hat and Fedora, the file is /etc/httpd/conf/httpd.conf.

Rename the uploaded folder to whatever you would like to have in the URL. If your web server is running as http://localhost for example, renaming to /w/ directory would mean you would access your wiki at http://localhost/w/index.php.

Do not use /wiki/ if you want to set it up as a Short URL after running the installation script.

Az adatbázis beállítása

MediaWiki's installation script will ask you for a database name and database username, so MediaWiki can store the content of the wiki.

If you already have a database server and know the password for the "root" (admin) user, skip to the #Run the installation script section below.

If you don't know the password for the root user, for example if you are on a hosted server, you will have to create a new database before you run the MediaWiki installation script in the next section.

MariaDB/MySQL are the recommended databases. PostgreSQL and SQLite have limited support and should not be used unless there is a reason to. If you're unsure which database to choose, use MariaDB.

After finishing the database setup, continue with #Run the installation script below.

SQLite

No further setup is required for SQLite if the pdo-sqlite module for PHP is installed on the system.

On the SQLite installation page, choose a database name (which can be anything) and the SQLite database directory. For the database directory, the installer will attempt to use a subdirectory outside of the document root and create it if needed. If this directory is not safe (for example, web-readable), change it manually to avoid making it accessible to everyone on the web.

MariaDB/MySQL

Create the MariaDB/MySQL database and database user. There are several ways:

  • Use a control panel software offered by your Hosting service (example: PhpMyAdmin)
  • Use ssh to log into your host and type the commands below into a MySQL prompt. See the corresponding documentation of your hosting provider. Alternatively, contact your hosting provider to have them create an account for you.

The following commands create a database named my_wiki, a user named wikiuser, and set permissions for the user on that database.

CREATE DATABASE my_wiki;
CREATE USER 'wikiuser'@'localhost' IDENTIFIED BY 'database_password';
GRANT ALL PRIVILEGES ON my_wiki.* TO 'wikiuser'@'localhost' WITH GRANT OPTION;

Ha az adatbázis nem a webszerverrel azonos domainen fut, az alábbiak szerint meg kell adnod a pontos helyet (az alábbi esetben mediawiki.example.com):

GRANT ALL PRIVILEGES ON my_wiki.* TO 'wikiuser'@'mediawiki.example.com' IDENTIFIED BY 'database_password';
Figyelem Figyelem: UNIX-on és Linuxon a MySQL- és MariaDB-naplóbejegyzések egy fájlban tárolódnak, amely tartalmazza az adatbázishoz használt jelszót is. Ha ez zavar, a parancsok futása után a MySQL dokumentációját követve töröld és tiltsd le a .mysql_history fájlt.

PostgreSQL

If you are using PostgreSQL, you will need to either have a database and user created for you, or supply the name of a PostgreSQL user with "superuser" privileges to the configuration form. Often, this is the database user named postgres.

The following commands on a Linux command-line, as the postgres user, create a database user named wikiuser, and a database named my_wiki owned by the user named wikiuser.

 createuser -S -D -R -P -E wikiuser (majd írd be a jelszót)
 createdb -O wikiuser my_wiki

or as superuser (default postgres) execute the following commands at the database prompt:

CREATE USER wikiuser WITH NOCREATEDB NOCREATEROLE NOSUPERUSER ENCRYPTED PASSWORD 'database_password';
CREATE DATABASE my_wiki WITH OWNER wikiuser;

A telepítőszkript futtatása

Következő lépéskét nyisd meg a MediaWiki-telepítésed index.php lapját egy böngészőben: kövesd a Kézikönyv:Konfigurációs szkript utasításait.

További beállítások

Maradj naprakész!

Miután kész vagy a telepítéssel, kövesd a legújabb kiadásokat, és ügyelj adatbázisod biztonságára!

https://lists.wikimedia.org/postorius/lists/mediawiki-announce.lists.wikimedia.org/

Appendices

Alternatives to manual installation

Manual installation is often the preferred method because it gives the user more control and insight into how their wiki is installed, making troubleshooting and maintenance easier. Automated processes, packages, bundles, and services all come with their own idiosyncrasies.

Instead of manually installing MediaWiki, alternative options might be easier:

A root felhasználónak megjegyezhető jelszót válassz.

System-specific instructions

The pages listed on Kézikönyv:Rendszerspecifikus útmutatók give more detailed installation instructions aimed at specific systems.

However, by and large these per-system docs are less maintained and might not always be up to date. First consult A MediaWiki telepítése (this page) before looking at per-system installation documentation.

Running multiple wikis

Importing an existing wiki database

Lásd még