TracModPythonバージョン 1バージョン 2 との変更


以下の違いを無視:
日時:
2015/05/27 0:24:03 (11年前)
更新者:
trac
コメント:

--

凡例:

変更なし
追加
削除
更新
  • TracModPython

    v1 v2  
    1 = Trac and mod_python =
     1= Trac と mod_python = #Tracandmod_python
    22[[TracGuideToc]]
    33
    4 Trac supports [http://www.modpython.org/ mod_python], which speeds up Trac's response times considerably, especially compared to [TracCgi CGI], and permits use of many Apache features not possible with [wiki:TracStandalone tracd]/mod_proxy.
     4Trac では [http://www.modpython.org/ mod_python] を利用可能です。 [http://www.modpython.org/ mod_python] は Trac のレスポンスタイムを飛躍的に向上し、特に [TracCgi CGI] と比べて、 [wiki:TracStandalone tracd]/mod_proxy では使用できない多くの Apache 機能を使えるようにします。
    55
    66{{{#!div class="important"
    77** A Word of Warning **
    88
    9 As of 16^th^ June 2010, the mod_python project is officially dead.  If you are considering using mod_python for a new installation, '''please don't'''!  There are known issues which will not be fixed and there are now better alternatives.  Check out the main TracInstall pages for your target version for more information.
    10 }}}
    11 
    12 
    13 These instructions are for Apache 2; if you are still using Apache 1.3, you may have some luck with [trac:wiki:TracModPython2.7 TracModPython2.7], but you'll be totally on your own.
     92010 年 6 月 16 日に、 mod_python プロジェクトが正式に終了しました。もし mod_python を新しいインストールで使用することを考えているならば、 '''お願いだからしないで下さい'''! 解決されない既知の課題がありますし、今ではより良い代替手段もあります。詳細については、インストールしようとしているバージョンの TracInstall ページをチェックして下さい。
     10}}}
     11
     12
     13以下の説明は Apache2 のためのものです; まだ Apache1.3 を使用しているなら、 [trac:TracModPython2.7 TracModPython2.7] にいくつか情報がありますが、すべてあなた一人で設定することになるでしょう。
    1414
    1515[[PageOutline(2-3,Overview,inline)]]
    1616
    17 == Simple configuration: single project == #Simpleconfiguration
    18 
    19 If you just installed mod_python, you may have to add a line to load the module in the Apache configuration:
     17== シンプルな設定: 単一プロジェクト == #Simpleconfiguration
     18
     19mod_python をインストールしたら、 Apache の設定ファイルに以下の一行を追加してモジュールをロードしなければなりません:
    2020{{{
    2121LoadModule python_module modules/mod_python.so
    2222}}}
    2323
    24 ''Note: The exact path to the module depends on how the HTTPD installation is laid out.''
    25 
    26 On Debian using apt-get
     24''Note: モジュールがインストールされている正しいパスは HTTPD をどこにインストールしたかによって変わります。''
     25
     26Debian で apt-get を使用する場合
    2727{{{
    2828apt-get install libapache2-mod-python libapache2-mod-python-doc
    2929}}}
    30 (Still on Debian) after you have installed mod_python, you must enable the modules in apache2 (equivalent of the above Load Module directive):
     30(Debian の続き) mod_python をインストールした後に、apache2 (上の Load Module に相当するもの) のモジュールを有効にしなければなりません :
    3131{{{
    3232a2enmod python
    3333}}}
    34 On Fedora use, using yum:
     34Fedora で yum を使用する場合:
    3535{{{
    3636yum install mod_python
    3737}}}
    38 You can test your mod_python installation by adding the following to your httpd.conf.  You should remove this when you are done testing for security reasons. Note: mod_python.testhandler is only available in mod_python 3.2+.
     38httpd.conf に以下を加えることで、 mod_python がインストールされたかテストすることができます。セキュリティ上の理由から、テストが終わった時点で以下のコンフィグは削除するべきです。 Note: mod_python.testhandler は mod_python 3.2+ で利用可能です。
    3939{{{
    4040#!xml
     
    4848}}}
    4949
    50 A simple setup of Trac on mod_python looks like this:
     50mod_python を使用した簡単な Trac のセットアップ方法は以下のようになります:
    5151{{{
    5252#!xml
     
    5454   SetHandler mod_python
    5555   PythonInterpreter main_interpreter
    56    PythonHandler trac.web.modpython_frontend 
     56   PythonHandler trac.web.modpython_frontend
    5757   PythonOption TracEnv /var/trac/myproject
    5858   PythonOption TracUriRoot /projects/myproject
     
    6262}}}
    6363
    64 The option '''`TracUriRoot`''' may or may not be necessary in your setup. Try your configuration without it; if the URLs produced by Trac look wrong, if Trac does not seem to recognize URLs correctly, or you get an odd "No handler matched request to..." error, add the '''`TracUriRoot`''' option.  You will notice that the `Location` and '''`TracUriRoot`''' have the same path.
    65 
    66 The options available are
     64'''`TracUriRoot`''' オプションは不要な場合もあります。 `TracUriRoot` オプションを付けずに試し、 Trac が正しく URL を生成できないか、 "No handler matched request to..." というエラーが出るようであれば '''`TracUriRoot`''' を追加して下さい。 `Location` と '''`TracUriRoot`''' が同じパスになるようにしてください。
     65
     66!PythonOption の一覧は以下の通りです。
    6767{{{
    6868    # For a single project
     
    8181    PythonOption TracLocale en_GB.UTF8
    8282
    83     # See description above       
     83    # See description above
    8484    PythonOption TracUriRoot /projects/myproject
    8585}}}
    8686
    87 === Python Egg Cache ===
    88 
    89 Compressed python eggs like Genshi are normally extracted into a directory named `.python-eggs` in the users home directory. Since apache's home usually is not writable an alternate egg cache directory can be specified like this:
     87=== Python Egg Cache === #PythonEggCache
     88
     89Genshi のように圧縮された Python egg は通常、実行するユーザのホームディレクトリ配下の `.python-eggs` ディレクトリに展開されます。  Apache のホームディレクトリは多くの場合、書き込みできないようになっているので、他のディレクトリを egg cache として指定しなければなりません:
    9090{{{
    9191PythonOption PYTHON_EGG_CACHE /var/trac/myprojects/egg-cache
    9292}}}
    9393
    94 or you can uncompress the Genshi egg to resolve problems extracting from it.
    95 
    96 === Configuring Authentication ===
    97 
    98 See corresponding section in the [wiki:TracModWSGI#ConfiguringAuthentication] page.
    99 
    100 
    101 == Advanced Configuration
    102 
    103 === Setting the Python Egg Cache ===
    104 
    105 If the Egg Cache isn't writeable by your Web server, you'll either have to change the permissions, or point Python to a location where Apache can write. This can manifest itself as a ''500 internal server error'' and/or a complaint in the syslog.
     94又は Genshi の egg を解凍して展開することで、この問題を回避できます。
     95
     96=== 認証設定 === #ConfiguringAuthentication
     97
     98[wiki:TracModWSGI#ConfiguringAuthentication] ページの対応する項目を参照してください。
     99
     100
     101== 詳細な設定 == #AdvancedConfiguration
     102
     103=== Python Egg Cache を設定する === #SettingthePythonEggCache
     104
     105Web サーバが Egg Cache に書き込みできない場合、パーミッションを変更するか、 Apache が書き込み可能な場所を指定する必要があります。設定しないと ''500 Internal Server Error'' や syslog へのエラー出力が発生します。
    106106
    107107{{{
     
    109109<Location /projects/myproject>
    110110  ...
    111   PythonOption PYTHON_EGG_CACHE /tmp 
    112   ...
    113 </Location>
    114 }}}
    115 
    116 
    117 === Setting the !PythonPath ===
    118 
    119 If the Trac installation isn't installed in your Python path, you'll have to tell Apache where to find the Trac mod_python handler  using the `PythonPath` directive:
     111  PythonOption PYTHON_EGG_CACHE /tmp
     112  ...
     113</Location>
     114}}}
     115
     116
     117=== !PythonPath を設定する === #SettingthePythonPath
     118
     119もし Trac のインストールが、通常の Python ライブラリのパスの中に無い場合、 Apache が Trac の mod_python ハンドラを見つけられるように `PythonPath` ディレクティブで指定しなければなりません:
    120120{{{
    121121#!xml
     
    127127}}}
    128128
    129 Be careful about using the !PythonPath directive, and ''not'' `SetEnv PYTHONPATH`, as the latter won't work.
    130 
    131 === Setting up multiple projects ===
    132 
    133 The Trac mod_python handler supports a configuration option similar to Subversion's `SvnParentPath`, called `TracEnvParentDir`:
     129!PythonPath ディレクティブを使用するときは気をつけてください。そして、 `SetEnv PYTHONPATH` は動かないので ''使用しない'' で下さい。
     130
     131=== マルチプロジェクトのセットアップ === #Settingupmultipleprojects
     132
     133Trac の mod_python ハンドラには Subversion の `SvnParentPath` とよく似た `TracEnvParentDir` というコンフィグレーションオプションがあります。
    134134{{{
    135135#!xml
     
    137137  SetHandler mod_python
    138138  PythonInterpreter main_interpreter
    139   PythonHandler trac.web.modpython_frontend 
     139  PythonHandler trac.web.modpython_frontend
    140140  PythonOption TracEnvParentDir /var/trac
    141141  PythonOption TracUriRoot /projects
     
    143143}}}
    144144
    145 When you request the `/projects` URL, you will get a listing of all subdirectories of the directory you set as `TracEnvParentDir` that look like Trac environment directories. Selecting any project in the list will bring you to the corresponding Trac environment.
    146 
    147 If you don't want to have the subdirectory listing as your projects home page you can use a
     145`/projects` の URL をリクエストすると、 TracEnvironment の親ディレクトリ `TracEnvParentDir` として設定したディレクトリ配下のサブディレクトリ一覧が表示されます。その一覧から何かプロジェクトを選択するとそれに該当する TracEnvironment を開くことができます。
     146
     147あなたのプロジェクトのホームページとして、サブディレクトリのリストが必要ないならば、以下のようにすることができます
    148148{{{
    149149#!xml
     
    151151}}}
    152152
    153 This will instruct Apache to use mod_python for all locations different from root while having the possibility of placing a custom home page for root in your !DocumentRoot folder.
    154 
    155 You can also use the same authentication realm for all of the projects using a `<LocationMatch>` directive:
     153これは !DocumentRoot フォルダの直下にカスタムホームページとして配置されていない場合には、すべてのロケーションで代わりに mod_python を使用することを Apache に教えます。
     154
     155すべてのプロジェクトに対して、 `<LocationMatch>` ディレクティブを使用することによって同じ認証の仕組みを使用することができます。
    156156{{{
    157157#!xml
     
    164164}}}
    165165
    166 === Virtual Host Configuration ===
    167 
    168 Below is the sample configuration required to set up your trac as a virtual server (i.e. when you access it at the URLs like
    169 !http://trac.mycompany.com):
     166=== 仮想ホストの設定 === #VirtualHostConfiguration
     167
     168以下に示す例は Trac を仮想サーバーとしてセットアップするときに必要な設定です。 (例えば、!http://trac.mycompany.com といった
     169URL でアクセスすることができます):
    170170
    171171{{{
     
    190190}}}
    191191
    192 This does not seem to work in all cases. What you can do if it does not:
    193  * Try using `<LocationMatch>` instead of `<Location>`
    194  * <Location /> may, in your server setup, refer to the complete host instead of simple the root of the server. This means that everything (including the login directory referenced below) will be sent to python and authentication does not work (i.e. you get the infamous Authentication information missing error). If this applies to you, try using a sub-directory for trac instead of the root (i.e. /web/ and /web/login instead of / and /login).
    195  * Depending on apache's `NameVirtualHost` configuration, you may need to use `<VirtualHost *:80>` instead of `<VirtualHost *>`.
    196 
    197 For a virtual host that supports multiple projects replace "`TracEnv`" /var/trac/myproject with "`TracEnvParentDir`" /var/trac/
    198 
    199 Note: !DocumentRoot should not point to your Trac project env. As Asmodai wrote on #trac: "suppose there's a webserver bug that allows disclosure of !DocumentRoot they could then leech the entire Trac environment".
    200 
    201 == Troubleshooting ==
    202 
    203 In general, if you get server error pages, you can either check the Apache error log, or enable the `PythonDebug` option:
     192この設定は全てのケースでうまく動くわけではありません。動かない場合は以下を試してください:
     193 * `<Location>` の代わりに `<LocationMatch>` を使用する
     194 * <Location />  はサーバの設定によっては、単にサーバのルートではなく完全なホスト名を参照していることがあります。このような場合、 (上記の例では下段にあたるログイン用ディレクトリを含む) 全てのリクエストが Python に送信され、認証が動かなくなります (認証を行おうとすると、認証が設定されていないというエラー画面が表示されます)。 URL を変更できるのであれば (/, /login の代わりに /web/, /web/login などのように) ルートではなくサブディレクトリを使ってみてください
     195 * Apache の `NameVirtualHost` を設定している場合、 `<VirtualHost *>` ではなく `<VirtualHost *:80>` を使用せねばならないかもしれません
     196
     197複数のプロジェクトをサポートする仮想ホストの設定では、 "`TracEnv`" /var/trac/myproject を "`TracEnvParentDir`" /var/trac/ に置き換えて下さい。
     198
     199Note: !DocumentRoot は TracEnvironment と同じディレクトリにしないでください。 何かのバグがあった場合に TracEnvironment の内容が外部からアクセス可能になってしまうおそれがあります。
     200
     201== トラブルシューティング == #Troubleshooting
     202
     203サーバエラーのページがでたときには、 まずは Apache のエラーログを確認するか、 `PythonDebug` オプションを有効にして下さい:
    204204{{{
    205205#!xml
     
    210210}}}
    211211
    212 For multiple projects, try restarting the server as well.
    213 
    214 === Login Not Working ===
    215 If you've used `<Location />` directive, it will override any other directives, as well as `<Location /login>`.
    216 The workaround is to use negation expression as follows (for multi project setups):
     212複数プロジェクトの場合は、全てのプロジェクトでサーバを再起動してみてください。
     213
     214=== 動作しないログイン === #LoginNotWorking
     215`<Location />` ディレクティブを使用した場合、 他のディレクティブ同様、`<Location /Login>` ディレクティブをオーバーライドします。
     216この問題を回避するには、次のように否定表現を使用します (マルチプロジェクト設定向け):
    217217{{{
    218218#!xml
     
    233233
    234234   #remove these if you don't want to force SSL
    235    RewriteEngine On 
     235   RewriteEngine On
    236236   RewriteCond %{HTTPS} off
    237237   RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}
     
    246246=== Expat-related segmentation faults === #expat
    247247
    248 This problem will most certainly hit you on Unix when using Python 2.4.
    249 In Python 2.4, some version of Expat (an XML parser library written in C) is used,
    250 and if Apache is using another version, this results in segmentation faults.
    251 As Trac 0.11 is using Genshi, which will indirectly use Expat, that problem
    252 can now hit you even if everything was working fine before with Trac 0.10.
    253 
    254 See Graham Dumpleton's detailed [http://www.dscpl.com.au/wiki/ModPython/Articles/ExpatCausingApacheCrash explanation and workarounds] for the issue.
    255 
    256 === Form submission problems ===
    257 
    258 If you're experiencing problems submitting some of the forms in Trac (a common problem is that you get redirected to the start page after submission), check whether your {{{DocumentRoot}}} contains a folder or file with the same path that you mapped the mod_python handler to. For some reason, mod_python gets confused when it is mapped to a location that also matches a static resource.
    259 
    260 === Problem with virtual host configuration ===
    261 
    262 If the <Location /> directive is used, setting the `DocumentRoot` may result in a ''403 (Forbidden)'' error. Either remove the `DocumentRoot` directive, or make sure that accessing the directory it points is allowed (in a corresponding `<Directory>` block).
    263 
    264 Using <Location /> together with `SetHandler` resulted in having everything handled by mod_python, which leads to not being able download any CSS or images/icons. I used <Location /trac> `SetHandler None` </Location> to circumvent the problem, though I do not know if this is the most elegant solution.
    265 
    266 === Problem with zipped egg ===
    267 
    268 It's possible that your version of mod_python will not import modules from zipped eggs. If you encounter an `ImportError: No module named trac` in your Apache logs but you think everything is where it should be, this might be your problem. Look in your site-packages directory; if the Trac module appears as a ''file'' rather than a ''directory'', then this might be your problem. To rectify, try installing Trac using the `--always-unzip` option, like this:
    269 
    270 {{{
    271 easy_install --always-unzip Trac-0.12b1.zip
    272 }}}
    273 
    274 === Using .htaccess ===
    275 
    276 Although it may seem trivial to rewrite the above configuration as a directory in your document root with a `.htaccess` file, this does not work. Apache will append a "/" to any Trac URLs, which interferes with its correct operation.
    277 
    278 It may be possible to work around this with mod_rewrite, but I failed to get this working. In all, it is more hassle than it is worth. Stick to the provided instructions. :)
    279 
    280 A success story: For me it worked out-of-box, with following trivial config:
     248この問題は Unix 上で Python 2.4 を使用するとき、ほぼ確実に発生します。
     249Python 2.4 の使用する Expat (C で書かれた XML パーザライブラリ) と
     250Apache の使用する Expat のバージョンが異なる場合に、セグメンテーションフォルトが発生します。
     251Trac 0.11 は Genshi (間接的に Expat が使用される) を使用しているため、
     252以前 Trac 0.10 で正常に動いていたとしても、現在のあなたの環境で問題が起こり得ます。
     253
     254Graham Dumpleton が、この問題について詳しく書いています。問題の [http://www.dscpl.com.au/wiki/ModPython/Articles/ExpatCausingApacheCrash 説明と回避方法] を確認してください。
     255
     256=== フォームを送信するときの問題 === #Formsubmissionproblems
     257
     258もし、 Trac で何かしらのフォームを送信したときに、トラブルに見舞われたら (送信後にスタートページにリダイレクトされてしまう、などがよくある問題です)  {{{DocumentRoot}}} の中に mod_python をマッピングしたパスと同じフォルダやファイルが存在しないか確認してください。どういうわけか、 mod_python は静的リソースと同じところにマッピングされると混乱してしまいます。
     259
     260=== 仮想ホストの設定においての問題 === #Problemwithvirtualhostconfiguration
     261
     262<Location /> ディレクティブが使用されている場合に `DocumentRoot` を設定すると ''403 (Forbidden)'' エラーになることがあります。 `DocumentRoot` ディレクティブを削除するか、アクセスが許されているディレクトリに設定されているかどうかを確認して下さい (対応する `<Directory>` ブロックにて)
     263
     264<Location /> で `SetHandler` を使用すると、すべてを mod_python でハンドルすることになりますが、いかなる CSS も image/icons もダウンロードできなくなります。この問題を回避するために、われわれは <Location /trac> で `SetHandler None` を使用しています。しかし、この方法がエレガントな解決方法だとは思っていません。
     265
     266=== Zip された egg での問題 === #Problemwithzippedegg
     267
     268mod_python のバージョンによっては Zip された egg ファイルからモジュールを import できないことがあります。 Apache のログに `ImportError: No module named trac` が出力される場合、問題が発生している原因であると考えられます。 Python の site-packages ディレクトリを見てみてください。 Trac のモジュールが ''ディレクトリ'' ではなく ''ファイル'' として配置されている場合、問題の原因と考えられます。解決するためには、下記の上に `--always-unzip` オプションと伴に Trac をインストールしてみてください。
     269
     270{{{
     271easy_install --always-unzip Trac-0.12.zip
     272}}}
     273
     274=== .htaccess ファイルを使用する === #Using.htaccess
     275
     276ディレクトリの設定をほんのちょっと修正するには `.htaccess` ファイルを使用すればいいかもしれませんが、これは動作しません。 Apache が Trac の URL に "/" (スラッシュ) を追加すると、正しい動作を妨げてしまいます。
     277
     278それでは、 mod_rewrite を使用すればいいように見えますが、これも動作しません。とにかく、百害あって一利なしです。指示に従ってください。 :)
     279
     280成功した事例:  以下の設定値で成功した事例があります:
    281281{{{#!xml
    282282SetHandler mod_python
    283283PythonInterpreter main_interpreter
    284 PythonHandler trac.web.modpython_frontend 
     284PythonHandler trac.web.modpython_frontend
    285285PythonOption TracEnv /system/path/to/this/directory
    286286PythonOption TracUriRoot /path/on/apache
     
    292292}}}
    293293
    294 The `TracUriRoot` is obviously the path you need to enter to the browser to get to the trac (e.g. domain.tld/projects/trac)
    295 
    296 === Additional .htaccess help ===
    297 
    298 If you are using the .htaccess method you may have additional problems if your trac directory is inheriting .htaccess directives from another.  This may also help to add to your .htaccess file:
     294`TracUriRoot` は Web ブラウザが取得する Trac のパスを明示的に設定するのに使用します。 (例: domain.tld/projects/trac)
     295
     296=== .htaccess 使用時の特記事項 === #Additional.htaccesshelp
     297
     298.htaccess を使用している場合、 Trac のディレクトリが他のディレクトリで設定されたた .htaccess ディレクティブを継承し、問題を生じることがあります。このような場合、以下のように .htaccess ファイルに設定してみて下さい:
    299299
    300300{{{
     
    304304}}}
    305305
    306 === Platform specific issues
    307 ==== Win32 Issues ====
    308 If you run trac with mod_python < 3.2 on Windows, uploading attachments will '''not''' work. This problem is resolved in mod_python 3.1.4 or later, so please upgrade mod_python to fix this.
    309 
    310 
    311 ==== OS X issues ====
    312 
    313 When using mod_python on OS X you will not be able to restart Apache using `apachectl restart`. This is apparently fixed in mod_python 3.2, but there's also a patch available for earlier versions [http://www.dscpl.com.au/projects/vampire/patches.html here].
    314 
    315 ==== SELinux issues ====
    316 
    317 If Trac reports something like: ''Cannot get shared lock on db.lock''
    318 The security context on the repository may need to be set:
     306=== 特定のプラットフォームでの問題 === #Platformspecificissues
     307==== Win32 での問題 ==== #Win32issues
     308Windows 上で mod_python 3.2 より前のバージョンで Trac を動かしている場合、添付ファイルのアップロードが '''動かない''' でしょう。この問題は 3.1.4 以降で解決されました。 mod_python をアップグレードしてこの問題を解決してください。
     309
     310
     311==== OS X での問題 ==== #OSXissues
     312
     313OS X で mod_python を使用するとき、 `apachectl restart` コマンドで Apache の再起動ができないでしょう。これは、 mod_python 3.2 でおそらく修正されるでしょう。しかし、 [http://www.dscpl.com.au/projects/vampire/patches.html ここ] にあるパッチを適用すれば、 3.2 以前のバージョンでもこの問題を回避できます。
     314
     315==== SELinux での問題 ==== #SELinuxissues
     316
     317もし、 Trac が ''Cannot get shared lock on db.lock'' というようなメッセージが出力したら、
     318リポジトリに セキュリティコンテキストを設定する必要があるでしょう:
    319319
    320320{{{
     
    322322}}}
    323323
    324 See also [http://subversion.tigris.org/faq.html#reposperms]
    325 
    326 ==== FreeBSD issues ====
    327 Pay attention to the version of the installed mod_python and sqlite packages. Ports have both the new and old ones, but earlier versions of pysqlite and mod_python won't integrate as the former requires threaded support in python, and the latter requires a threadless install.
    328 
    329 If you compiled and installed apache2, apache wouldn´t support threads (cause it doesn´t work very well on FreeBSD). You could force thread support when running ./configure for apache, using --enable-threads, but this isn´t recommendable.
    330 The best option [http://modpython.org/pipermail/mod_python/2006-September/021983.html seems to be] adding to /usr/local/apache2/bin/ennvars the line
     324[http://subversion.tigris.org/faq.html#reposperms] も参考にして下さい
     325
     326==== FreeBSD での問題 ==== #FreeBSDissues
     327mod_python と sqlite パッケージのインストールバージョンに注意して下さい。 Ports には両パッケージともいろいろなバージョンがありますが、初期の pysqlite と mod_python は組み合わせることができません。前者は python のスレッド機能サポートが必要ですし、 後者 は python のスレッド機能なしのインストールが必要です。
     328
     329apache2 を普通にコンパイルしてインストールした場合、 apache はスレッドのサポートなしになります (これが FreeBSD 上であまりよく動かない原因)。 --enable-threads を使用して ./configure を実行することで apache にスレッドのサポートありにすることができますが、これはお勧めできません。
     330最良のオプションは /usr/local/apache2/bin/ennvars に下記の一行を追加することだと [http://modpython.org/pipermail/mod_python/2006-September/021983.html 考えられます。]
    331331
    332332{{{
     
    335335
    336336
    337 ==== Fedora 7 Issues ====
    338 Make sure you install the 'python-sqlite2' package as it seems to be required for TracModPython but not for tracd
    339 
    340 
    341 === Subversion issues ===
    342 
    343 If you get the following Trac Error `Unsupported version control system "svn"` only under mod_python, though it works well on the command-line and even with TracStandalone, chances are that you forgot to add the path to the Python bindings with the [TracModPython#ConfiguringPythonPath PythonPath] directive. (The better way is to add a link to the bindings in the Python `site-packages` directory, or create a `.pth` file in that directory.)
    344 
    345 If this is not the case, it's possible that you're using Subversion libraries that are binary incompatible with the apache ones (an incompatibility of the `apr` libraries is usually the cause). In that case, you also won't be able to use the svn modules for Apache (`mod_dav_svn`).
    346 
    347 You also need a recent version of `mod_python` in order to avoid a runtime error ({{{argument number 2: a 'apr_pool_t *' is expected}}}) due to the default usage of multiple sub-interpreters. 3.2.8 ''should'' work, though it's probably better to use the workaround described in [trac:#3371 #3371], in order to force the use of the main interpreter:
     337==== Fedora 7 での問題 ==== #Fedore7Issues
     338'python-sqlite2' を必ずインストールしてください。tracd では必須ではありませんが、 TracModPython では必須です。
     339
     340
     341=== Subversion での問題 === #Subversionissues
     342
     343コマンドラインや TracStandalone で使用しているときは動くのに、 mod_python を使用しているときのみ、 `Unsupported version control system "svn"` というエラーが出力される場合、 [wiki:"TracModPython#SettingthePythonPath" PythonPath] ディレクティブに Python bindings へのパスを追加するのを忘れている可能性があります。 (Python の `site-packages` ディレクトリに Python binding へのリンクを追加するか、 `.pth` ファイルを作っておくのがベターです。)
     344
     345これに当てはまらない場合、使用している Subversion のライブラリが Apache が使用しているバージョンと適合性がないかもしれません。 (たいてい `apr` ライブラリの不適合性が原因になります。) その場合、 Apache の svn モジュール (`mod_dav_svn`) も使用できないでしょう。
     346
     347また、ランタイムエラー ({{{argument number 2: a 'apr_pool_t *' is expected}}}) を抑止するためにも、複数のサブインタプリタを使用できる最近のバージョンの `mod_python` が必要になります。 3.2.8 では ''たぶん'' 動きますが、 [trac:#3371] に記述されている通り、メインインタプリタを使用するように強制するワークアラウンドを使用する方がおそらく良いでしょう:
    348348{{{
    349349PythonInterpreter main_interpreter
    350350}}}
    351 This is anyway the recommended workaround for other well-known issues seen when using the Python bindings for Subversion within mod_python ([trac:#2611 #2611], [trac:#3455 #3455]). See in particular Graham Dumpleton's comment in [trac:comment:9:ticket:3455 #3455] explaining the issue.
    352 
    353 === Page layout issues ===
    354 
    355 If the formatting of the Trac pages look weird chances are that the style sheets governing the page layout are not handled properly by the web server. Try adding the following lines to your apache configuration:
     351これは、よく知られている mod_python と Subversion の Python バインディングの他の問題 ([trac:#2611], [trac:#3455]) について推奨しているワークアラウンドです。 [trac:comment:9:ticket:3455 #3455] Graham Dumpleton のコメントに問題点が指摘されています。
     352
     353=== ページレイアウトの問題 === #Pagelayoutissues
     354
     355Trac のページフォーマットが奇妙に見えるなら、ページレイアウトを管理するスタイルシートが Web サーバによって適切に扱われていない可能性が考えられます。 Apache のコンフィグに以下を追加してみてください:
    356356{{{
    357357#!xml
     
    362362}}}
    363363
    364 Note: For the above configuration to have any effect it must be put after the configuration of your project root location, i.e. {{{<Location /myproject />}}}.
    365 
    366 Also, setting `PythonOptimize On` seems to mess up the page headers and footers, in addition to hiding the documentation for macros and plugins (see #Trac8956). Considering how little effect the option has, it is probably a good idea to leave it `Off`.
    367 
    368 === HTTPS issues ===
    369 
    370 If you want to run Trac fully under https you might find that it tries to redirect to plain http. In this case just add the following line to your apache configuration:
     364Note: 上記のコンフィグが効果を発揮するためには、プロジェクトの root 位置のコンフィグ後に追加しなければなりません。つまり {{{<Location /myproject />}}} 以降です。
     365
     366また `PythonOptimize On` が設定されている場合、ページのヘッダとフッタの表示が乱れたり、マクロやプラグインのドキュメンテーションが表示されないことがあります ([trac:#8956] 参照)。オプションの設定によって影響を受ける箇所について充分考慮できない場合は `Off` に設定する方がよいでしょう。
     367
     368=== HTTPS の問題 === #HTTPSissues
     369
     370Trac を完全に https で実行したいにも関わらず、プレーンな http にリダイレクトされる場合、 Apache のコンフィグに以下を追加してください:
    371371{{{
    372372#!xml
     
    380380
    381381
    382 === Segmentation fault with php5-mhash or other php5 modules ===
    383 You may encounter segfaults (reported on debian etch) if php5-mhash module is installed. Try to remove it to see if this solves the problem. See debian bug report [http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=411487]
    384 
    385 Some people also have troubles when using php5 compiled with its own 3rd party libraries instead of system libraries. Check here [http://www.djangoproject.com/documentation/modpython/#if-you-get-a-segmentation-fault]
     382=== php5-mhash または その他の php5 モジュールのセグメンテーションフォルト === #Segmentationfaultwithphp5-mhashorotherphp5modules
     383php5-mhash モジュールがインストールされている場合、 (debian etch について報告された) セグメンテーションフォルトに遭遇するでしょう。 php-mhash を削除して、問題が解決するかを確かめてみてください。 debian のバグレポート [http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=411487] を参考にして下さい。
     384
     385システムライブラリの代わりに、サードパーティのライブラリでコンパイルされた php5 を使用する一部の人々にもトラブルが発生します。ここを確認してください [http://www.djangoproject.com/documentation/modpython/#if-you-get-a-segmentation-fault]
    386386
    387387----