Kuisirwa uye kumisikidzwa kweWordPress 4.5 Multisite pane Debian Jessie

Kwaziso munharaunda. Ini munguva pfupi yapfuura ndakaona kudiwa kwekuisa uye kugadzirisa vhezheni yazvino ye WordPress pamwe nemukana wekuve neinopfuura imwe webhusaiti mune imwechete yekumisikidza uye chii chiri nani pane debian jessie 🙂 Panguva ino ndichagovana newe kuti ndakazviita sei kuti kana chero nguva ichikosha kana kunakidza, uzviite pasina kutora nguva yakareba uye kuti zvese zvinoshanda nemazvo kuchinangwa chinotarisirwa. Uku kumisikidza pane server yemuno uye kuburikidza nemadirectory.

Tichatanga ne kuisirwa kwedu GLAMP server, uchishandisa MariaDB pachinzvimbo cheMySql (yemunhu kuravira asi inogona kuve neMySql kana uchida):

  1. Isu tinopinda mukati medu terminal se midzi uye tinotanga kuisirwa yedu Apache webhu saiti:
# kukodzera kuisa apache2
  1. Isu tinoenderera nekuisa iyo sevha uye iyo database mutengi:
# kugona kuisa mariadb-server mariadb-mutengi
  1. Gare gare isu tinoisa PHP uye mamwe mapakeji eMariaDB rutsigiro muPHP:
# kukodzera kuisa php5 libapache2-mod-php5 php5-mysqlnd php5-curl php5-gd php5-intl php-pear php5-imagick php5-imap php5-mcrypt php5-memcache php5-pspell php5-recode php5-snmp php5 yakachena php5-xmlrpc php5-xsl
  1. Isu tinotangazve Apache:
# systemctl tangazve apache2
  1. Kana isu tichida kuwedzera kumhanya kwemapeji muPHP zvishoma, isu tinoisa APCu PHP Cache uye titangise Apache zvakare:
# kukodzera kuisa php5-apcu
# systemctl tangazve apache2

Sezvo isu tine yedu GLAMP server yakagadzirira, ikozvino isu tinoenderera neiyo kuisirwa yazvino vhezheni yeWordPress (iyo 4.5 panguva ino):

  1. Isu tinopinda MariaDB semutungamiriri kubva kumushandisi yedu chikamu kana semidzi, kugadzira dhatabhesi, vashandisi uye kushandisa avo maropafadzo:
$ mysql -u mudzi -p
Gadzira Dhatabhesi bdwp1;
Gadzira USER wpususer1 @ localhost IDENTIFIED NE 'password';
IPAI ZVESE ZVAKAITWA ON e1dXNUMX. * KUTI wpususer1 @ localhost;
FLUSH PRIVILEGES;
mbudo
  1. Isu tinotangazve Apache naMariaDB:
# systemctl tangazve apache2
# systemctl kutangazve mysql
 
  1. Isu tinoisa WordPress nenzira inoshanda kuburikidza neiyo terminal:
# cd / tmp
# wget -c http://wordpress.org/latest.zip
# unzip -q yazvino.zip -d / var / www / html /

Kana isu tichida kuziva iro izwi rezwi dhairekitori rine zita rakasiyana kubva pane zvatinoda kune izvo zvekutanga, tinozvichinja seinotevera:

# mv / var / www / html / wordpress / var / www / html / wpmultisite1

Uye isu tinoenderera mberi nekupihwa ropafadzo kumushandisi www-data:

# chown -R www-data.www-data / var / www / html /www
# chmod -R 755 / var / www / html /www
# mkdir -p / var / www / html /www/ wp-zvemukati / uploads
# chown -R www-data.www-data / var / www / html /www/ wp-zvemukati / uploads

Iye zvino isu tinogadzira uye tinogadzira iyo huru yekumisikidza faira kutsanangura kukosha kwe database yedu uye mushandisi akambogadzirwa muMariaDB:

# cd / var / www / html / wpmultisite1
# cp wp-gadzira-sampuro.php wp-gadziriso.php
# Ndakaona wp-config.php (kana nemupepeti wesarudzo yako emacs, nano, gedit, pepa remashizha kana imwewo)

Kuchinja chikamu chechinyorwa chepakutanga:

// ** MySQL marongero - Unogona kuwana urwu ruzivo kubva kune yako webhusaiti ** //
/ ** Zita re database ye WordPress * /
tsanangura ('DB_NAME', 'database_name_here');

/ ** MySQL username yeduramazwi * /
tsanangura ('DB_USER', 'username_here');

/ ** MySQL database password *
tsanangura ('DB_PASSWORD', 'password_here');

Izvi zvinotevera:

// ** MySQL marongero - Unogona kuwana urwu ruzivo kubva kune yako webhusaiti ** //
/ ** Zita re database ye WordPress * /
tsanangura ('DB_NAME', 'e1dXNUMX');

/ ** MySQL username yeduramazwi * /
tsanangura ('DB_USER', 'wpusser1');

/ ** MySQL database password *
tsanangura ('DB_PASSWORD', 'pasiwedhi');

Isu tinochengetedza shanduko uye nekuvhara iyo faira. Iye zvino tinoenda kune yedu yewebhu browser uye mune itsva tebhu tinovhura iyo WordPress yekumisikidza ine inotevera URL:

http://localhost/wpmultisite1/

Mumasikirini anozoonekwa pazasi, tinosarudza mutauro wekumisikidza, zita rewebhusaiti, zita rekushandisa, password yako, email uye mune iyi nyaya hatimaki bhokisi rekupedzisira re "Bvumira saiti indexing" se Iko kuiswa kwemuno.

Iye zvino tinogona kupinda mune yedu yekuisa WordPress. Pakupedzisira tava kuzoita iyo kumisikidzwa kunodiwa kuti WordPress yedu ive nemultisite:

  1. Isu tinoshandisa iyo multisite network nekuwedzera unotevera mutsara kuburikidza neyedu yakasarudzika meseji mufaira wp-config.php, pamusoro pemutsara unoti «/ * Izvozvo zvose, rega kuchinja! Mabhurogi anofara. * /":

/ * Multisite * /
tsanangura ('WP_ALLOW_MULTISITE', ichokwadi);

Kusiya icho chikamu chefaira seinotevera:

/ **
* Kune vagadziri: WordPress debugging modhi.
*
* Chinja izvi zvive zvechokwadi kugonesa kuratidzwa kwezviziviso panguva yekuvandudza.
* Inokurudzirwa zvakanyanya kuti vagadziri vepulagi nemusoro vanoshandisa WP_DEBUG
* munzvimbo dzekuvandudza.
*
* Kuti uwane ruzivo pamusoro pemamwe maumbirwo anogona kushandiswa kugadzirisa dambudziko,
* shanyira Codex.
*
* @link https://codex.wordpress.org/Debugging_in_WordPress
/
tsanangura ('WP_DEBUG', nhema);
/
multisite /
tsanangura ('WP_ALLOW_MULTISITE', ichokwadi);
/
Ndizvozvo, rega kugadzirisa! Kufara blogging. * /

/ ** Absolute nzira ye WordPress directory. * /
kana (! yakatsanangurwa ('ABSPATH'))
tsanangura ('ABSPATH', dirname (file). '/');

Isu tinochengetedza shanduko uye nekuvhara iyo faira.

  1. Isu tinoshandisa Mod_Rewrite module yeApache:
# a2enmod nyorazve
  1. Isu tinogadzirisa iyo Apache faira /etc/apache2/sites-enabled/000-default.conf kuburikidza neyedu sarudzo yemavara edhitaini, tichiwedzera zvinotevera zvirimo:


Sarudzo Indexes FollowSymLinks MultiViews
RegaiOverride Zvose
Order tendera, ramba
tendera kubva kune vese

Kubvumira shanduko kubva kuWordPress .htaccess faira iyo yatichagadzirisa gare gare, tichisiya icho chikamu chemukati medu mu /000-default.conf seinotevera:

#Include conf-inowanikwa / service-cgi-bin.conf
 
                 Sarudzo Indexes FollowSymLinks MultiViews
                 RegaiOverride Zvose
                 Order tendera, ramba
                 tendera kubva kune vese
 

  1. Isu tinotangazve Apache
# systemctl tangazve apache2
  1. Iye zvino tinoenda kune yedu WordPress dashibhodhi uye mune huru pani kuruboshwe, tinosarudza sarudzo «Zvishandiso» uye mukati meiyi «Network kumisikidzwa»:

WP_DL1 WP_DL2 Kamwe zita remambure uye yako email zvapinda, tinobaya kuisa uye nekukurumidza iyo inotevera skrini ichaonekwa:

WP_DL3 Mairi mune yangu mamiriro anoenderana ne / var / www / html / wpmultisite1 anoratidzwa zvine chekuita nezita randakasarudzira dhairekitori rangu reWordPress rakanzi iibi pachinzvimbo chewpmultisite1: / var / www / html / iibi. Zvino tichitevera rairo muhwindo rino, tichaenda kuteedzera zvirimo padanho rekutanga kana bhokisi kune yedu wp-config.php faira kuburikidza neyedu zvinyorwa zvinyorwa pamusoro pemutsara unoti «/ * Izvozvo zvose, rega kuchinja! Mabhurogi anofara. * /»Kuva seinotevera:

/ **
* Kune vagadziri: WordPress debugging modhi.
*
* Chinja izvi zvive zvechokwadi kugonesa kuratidzwa kwezviziviso panguva yekuvandudza.
* Inokurudzirwa zvakanyanya kuti vagadziri vepulagi nemusoro vanoshandisa WP_DEBUG
* munzvimbo dzekuvandudza.
*
* Kuti uwane ruzivo pamusoro pemamwe maumbirwo anogona kushandiswa kugadzirisa dambudziko,
* shanyira Codex.
*
* @link https://codex.wordpress.org/Debugging_in_WordPress
/
tsanangura ('WP_DEBUG', nhema);
/
multisite /
tsanangura ('WP_ALLOW_MULTISITE', ichokwadi);
tsanangura ('MULTISITE', ichokwadi);
tsanangura ('SUBDOMAIN_INSTALL', nhema);
tsanangura ('DOMAIN_CURRENT_SITE', 'Yako.IP.address');
tsanangura ('PATH_CURRENT_SITE', '/ iibi /');
tsanangura ('SITE_ID_CURRENT_SITE', 1);
tsanangura ('BLOG_ID_CURRENT_SITE', 1);
/
Ndizvozvo, rega kugadzirisa! Kufara blogging. * /

Isu tinochengetedza shanduko uye nekuvhara iyo faira. Isu tinoita zvakafanana nezviri mukati medanho repiri kana bhokisi asi izvozvi kugadzirisa iro .htaccess faira kuburikidza nenzira:

# vi /var/www/html/iibi/.htaccess

Kubvisa zvese zvirimo zvepakutanga uye nekunamatira iyo iri mubhokisi, kuve seinotevera:

RewriteEngine On
NyorazveBase / iibi /
NyorazveRule ^ index.php $ - [L]

# wedzera trailing slash ku / wp-admin
NyorazveRule ^ ([_ _ 0-9a-zA-Z -] + /)? Wp-admin $ $ 1wp-admin / [R = 301, L]

NyorazveCond% {REQUEST_FILENAME} -f [OR]
NyorazveCond% {REQUEST_FILENAME} -d
NyorazveRule ^ - [L]
NyorazveRule ^ ([_ _ 0-9a-zA-Z -] + /)? (Wp- (zvemukati | admin | inosanganisira). *) $ 2 [L]
NyorazveRule ^ ([_ _ 0-9a-zA-Z -] + /)? (. *. Php) $ $ 2 [L]
NyorazveRule. index.php [L]

Isu tinochengetedza shanduko uye nekuvhara iyo faira. Isu tinobuda kunze kweWordPress uye tinopinda zvekare mairi.

  1. Pakupedzisira isu tinoyedza yedu WordPress yatove neiyo inogoneswa zvizere uye yakagadzirirwa mashandiro emultisite. Kune izvi tinoenda kukona yekumusoro kuruboshwe, sarudza "My saiti", "Network maneja" uye "Sites". Isu tinosarudza sarudzo «Wedzera nyowani» kumusoro uye pachiratidziri chinotevera tinotsanangudza mumavara ndima «Kero yesaiti (URL)» (zita renzvimbo yako nyowani), «Musoro wesaiti», «Mutauro wesaiti» , «Administrator email» uye tinodzvanya «Wedzera saiti». Iye zvino masaiti avanogadzira anozoonekwa mu "My Sites" uye ivo vanozokwanisa kuzvigadzirisa nenzira imwechete kuburikidza neyavo desktop. Chero chinhu usazeze kubvunza kana kugovana zvaunotaura. Zvido.

Izvo zviri muchinyorwa zvinoomerera pamisimboti yedu ye tsika dzekunyora. Kuti utaure chikanganiso tinya pano.

Makomendi gumi, siya zvako

Siya yako yekutaura

Your kero e havazobvumirwi ichibudiswa.

*

*

  1. Inotarisira iyo data: Miguel Ángel Gatón
  2. Chinangwa cheiyo data: Kudzora SPAM, manejimendi manejimendi.
  3. Legitimation: Kubvuma kwako
  4. Kutaurirana kwedata
  5. Dhata yekuchengetedza: Dhatabhesi inobatwa neOccentus Networks (EU)
  6. Kodzero: Panguva ipi neipi iwe unogona kudzora, kupora uye kudzima ruzivo rwako

  1.   Alejandro akadaro

    Dzidziso yakanaka kwazvo !!

  2.   jatani akadaro

    Ndatenda zvikuru Alejandro. Imwe tsananguro hapana chimwezve. Pandakanga ndichigadzira chinyorwa mumitsara ine iyo apostrophe (') hunhu zvaitaridzika seizvi, asi ikozvino zvashandurwa kuita kamwechete makotesheni (' uye ') mune mimwe mitsara yakaita seinotevera: tsanangura (' WP_ALLOW_MULTISITE ', ichokwadi ); uye ini ndakaedza kuzvigadzirisa ndichiedza kugadzirisa chinyorwa asi zvinongowoneka "Ona". Ndokumbirawo, kana mumwe munhu kubva kuvapepeti kana manejimendi kubva Kubva Linux aona chirevo ichi, ndiudze maitiro andingaite kugadzirisa chinyorwa kuti ndigadzirise iwo iwo ruzivo kana kuti shanduko iyoyo ndapota. Zvido.