Jump to: navigation, search
This page is a translated version of the page Manual:$wgExternalServers and the translation is 46% complete.

Other languages:
Deutsch • ‎English • ‎español • ‎français • ‎italiano • ‎日本語 • ‎polski • ‎português • ‎português do Brasil
MySQL specific: $wgExternalServers
外部 MySQL サーバーの配列。
導入されたバージョン: 1.5.0 (r9118)
除去されたバージョン: 使用中
可能な値: (下記参照)
既定値: array()
他の設定: アルファベット順 | 機能順


外部 MySQL サーバーの配列です。

$wgExternalServers collects all the usable clusters with all usable nodes of a cluster.

The top-level array's keys denote a cluster's name (The below example defines only one cluster. It has the name demoCluster).

The value to those keys are again arrays. They hold the specifications of the individual nodes.

The first node is consider the master. All writes to the database are performed through this master node.

Zero or more slave nodes may follow. (In the example below, you find two slave nodes).

Each node may have its own host, user, password, dbname, and type, as shown in the example. The load parameter allows to specify how much of the load should pass through this note.


$wgExternalServers = array( 'demoCluster' => array (
  array( 'host' => '', 'user' => 'userM',  'password' =>'pwdM',  'dbname' => 'dbM',  'type' => "mysql", 'load' => 1 ),
  array( 'host' => '', 'user' => 'userS1', 'password' =>'pwdS1', 'dbname' => 'dbS1', 'type' => "mysql", 'load' => 1 ),
  array( 'host' => '', 'user' => 'userS2', 'password' =>'pwdS2', 'dbname' => 'dbS2', 'type' => "mysql", 'load' => 1 )

(See External Storage for a discussion of this example, and how to turn this into a usable cluster configuration.)