パフォーマンス

提供:MoodleDocs
移動先:案内検索

鋭意翻訳中です。

少ないユーザでも、スケールアップした数千名のユーザでも、Moodleを快適に稼動させることが可能です。パフォーマンスに関係する要素は、基本的にどのPHPベースのデータベース主導型システムとも同じです。 また、( アプリケーションレイヤと明確に分離された ) Moodleの設計により、強力に拡張性のあるセットアップを行うことが可能です。( 大規模なMoodleインストール事例をご覧ください。)

大規模なサイトでは、通常ウェブサーバとデータベースサーバを分離します。しかし、小規模なサイトでは、サーバを分離することは通常必要ではありません。

例えば、1台以上のウェブサーバを使用して、Moodleをロードバランスした環境で使用することも可能です。ロードバランス用に分離された複数のウェブサーバでは、同一のデータベースおよび同一のファイル保存エリアを参照するようにしてください。しかし、ロードバランス環境でない場合、アプリケーションレイヤとデータベースの分離で十分にクラスタ化することができます。同様に、データベースをクラスタ化することも可能です ( 例 MySQLクラスタ )。

ウェブサーバのパフォーマンス

  • あなたのウェブサーバの「RAM」の容量はパフォーマンスに関する重要な要素です - 可能な限り多く設置してください ( 例 4GB)。
  • LinuxまたはUnixがサーバに対するMoodle推奨「オペレーティングシステム」です。LinuxやUnixは、高負荷時にMac OSXやWindowsサーバよりも快適に動作します。
  • CPUの負荷を軽減するため、Turck MMCacheまたはThe ionCube PHP Acceleratorのような、PHP acceleratorの利用を強くお勧めします。
  • PHPをApacheモジュールとしてインストールすると、パフォーマンスは ( CGIよりも ) 良くなります。
  • Unix/Linuxシステムでは、( PHPベースのzipライブラリよりも ) システムのzip/unzipコマンドの使用を許可することで、パフォーマンスが大きく改善されます - 管理/設定/詳細設定へアクセスして、適切な実行ファイルのパスを入力してください。( 同様に、duのパスを入れることで、Moodleのディレクトリコンテンツのリスティングスピードが改善されます。)
  • セキュアウェブコネクション ( https ) を使用することで、ウェブサーバおよびクライアントに高い負荷がかかります - 特に効果的にキャッシングが使用されないため、ファイルのリクエスト数が劇的に増加する場合があることに注意してください。この理由から、すべてのMoodleページにhttpsを使用することは、お勧めできません。Moodle詳細設定ページにて、ログインページのみhttpsを利用できるよう設定できます。
  • メモリの使用量が大幅に軽減されるため、Apacheの代わりに、軽いウェブサーバ lighttpdfastCGIの利用でパフォーマンスを良くすることができます。1つのapacheプロセスは、lighttpdfastCGIのすべてのプロセスより多くのメモリを必要とします。管理者が作業に時間を必要とするため、あなたが十分なハードウェアを用意できる場合、これは最良の方法ではないと思われます。
  • httpd.confのMaxRequestsPerChildを20-30くらいに下げることを考えてください。( この値を低く設定し過ぎた場合、パフォーマンスの向上よりシステムのオーバーヘッドが増すことになります )。 php.iniのmemory_limitを少なくとも16Mに下げることも考えてください。 ( Rory Allford氏による推奨 )

データベースのパフォーマンス

各Moodleモジュールのパフォーマンス

Moodle's activity modules, filters, and other plugins can be activated/deactivated. If necessary, you may wish to deactivate some features (such as chat) if not required - but this isn't necessary. Some notes on the performance of certain modules:

  • The Chat module is said to be a hog in terms of frequent HTTP requests to the main server. This can be reduced by setting the module to use Streamed updates, or, if you're using a Unix-based webserver, by running the chat in daemon mode.
  • Brief report on performance for 55 students simultaneously using Quiz
  • The Moodle cron task is triggered by calling the script cron.php. If this is called over HTTP (e.g. using wget or curl) it can take a large amount of memory on large installations. If it is called by directly invoking the php command (e.g. php -f /path/to/moodle/directory/admin/cron.php) efficiency can be much improved.
  • Having too many filters active can have serious effects on server load, especially on lower-end systems. The number of active filters has a direct effect on the perceived latency of your site; that is the time taken for each page impression. For best performance, leave the text cache enabled and do not "Filter all strings" unless you have a specific need. If in doubt profile the performance, and see how your changes affect the processing time.

関連情報