IGOS Nusantara dan MediaWiki: Perbedaan revisi
(←Membuat halaman berisi 'A') |
|||
| Baris 1: | Baris 1: | ||
| − | + | ||
| + | {{verify}} | ||
| + | {{Installation Guides}} | ||
| + | {{MoveToMediaWiki}} | ||
| + | |||
| + | MediaWiki is available as a part of Fedora Extras (4 or later). In order to install it, you should run | ||
| + | # yum install mediawiki | ||
| + | as root. After installation, open the file <code>/usr/share/doc/mediawiki-x.y.z/INSTALL.fedora</code> and follow the instructions there. | ||
| + | |||
| + | Note that in recent installations the INSTALL file is at <code>/usr/share/mediawiki/INSTALL</code> | ||
| + | |||
| + | If you need support for mathematical formulas, you also need to install <code>mediawiki-math</code>: | ||
| + | # yum install mediawiki-math | ||
| + | |||
| + | If you have a more recent Fedora, there is no package ''mediawiki-math''. Because mediawiki requires "texvc" for LaTeX you'll also need to install ''LabPlot'' | ||
| + | # yum install LabPlot | ||
| + | |||
| + | On Fedora Core 4, installing version 1.5.8-1, additional steps are needed | ||
| + | to enable inline LaTeX translation. Some of these steps are described in | ||
| + | the following file: | ||
| + | |||
| + | /usr/share/doc/mediawiki-math-1.5.8/README | ||
| + | |||
| + | If LaTeX formulas are displayed without translation, you might need to uncomment the following line manually in LocalSettings.php, and possibly also restart your httpd server: | ||
| + | |||
| + | $wgUseTeX = true; | ||
| + | |||
| + | Here is a method to restart the httpd server under Fedora: | ||
| + | |||
| + | /etc/init.d/httpd restart - from root prompt (not recommended) | ||
| + | sudo /etc/init.d/httpd restart - from user prompt with sudo configured | ||
| + | |||
| + | After enabling $wgUseTeX, you might see an error message such as this: | ||
| + | |||
| + | <!-- an effort to make this visually distinct from a *real* error --> | ||
| + | *<p class='error'><small>''Failed to parse (Can't write to or create math output directory):''</small></p> | ||
| + | |||
| + | In MediaWiki file Math.php one finds this source code line: | ||
| + | |||
| + | global $wgMathDirectory, $wgTmpDirectory, $wgInputEncoding; | ||
| + | |||
| + | In my default LocalSettings.php I found these lines: | ||
| + | |||
| + | $IP = "/var/www/mediawiki"; | ||
| + | $wgUploadDirectory = "$IP/images"; | ||
| + | # ... | ||
| + | $wgMathDirectory = "{$wgUploadDirectory}/math"; | ||
| + | $wgTmpDirectory = "{$wgUploadDirectory}/tmp"; | ||
| + | $wgTexvc = '/usr/bin/texvc'; | ||
| + | $wgUseTeX = true; | ||
| + | |||
| + | |||
| + | Which suggested this fix: | ||
| + | |||
| + | cd /var/www/mediawiki/images | ||
| + | sudo mkdir math | ||
| + | sudo mkdir tmp | ||
| + | sudo chown apache math tmp | ||
| + | sudo chmod 775 math tmp | ||
| + | |||
| + | And then there was math. | ||
| + | |||
| + | For Fedora-specific bug reports, use http://bugzilla.redhat.com/ with the product field set to "Fedora Extras" and the component field to "mediawiki". | ||
| + | |||
| + | *<p class='error'><small>''(PNG conversion failed; check for correct installation of latex, dvips, gs, and convert) :''</small></p> | ||
| + | |||
| + | If you have no error with php but no png generated, it's seems to be a problem with a configuration file of Tex. I solved my problem executing | ||
| + | fmtutil-sys --all | ||
| + | For more informations, I found the solution here : | ||
| + | http://forums.fedoraforum.org/showthread.php?t=197978 | ||
| + | |||
| + | == See Also == | ||
| + | |||
| + | *[[SELinux]] | ||
| + | |||
| + | {{languages|Manual:Running MediaWiki on Fedora Core}} | ||
| + | |||
| + | [[Category:Installation|{{PAGENAME}}]] | ||
Revisi per 12 Januari 2010 11.35
Templat:Verify Templat:Installation Guides Templat:MoveToMediaWiki
MediaWiki is available as a part of Fedora Extras (4 or later). In order to install it, you should run
# yum install mediawiki
as root. After installation, open the file /usr/share/doc/mediawiki-x.y.z/INSTALL.fedora and follow the instructions there.
Note that in recent installations the INSTALL file is at /usr/share/mediawiki/INSTALL
If you need support for mathematical formulas, you also need to install mediawiki-math:
# yum install mediawiki-math
If you have a more recent Fedora, there is no package mediawiki-math. Because mediawiki requires "texvc" for LaTeX you'll also need to install LabPlot
# yum install LabPlot
On Fedora Core 4, installing version 1.5.8-1, additional steps are needed to enable inline LaTeX translation. Some of these steps are described in the following file:
/usr/share/doc/mediawiki-math-1.5.8/README
If LaTeX formulas are displayed without translation, you might need to uncomment the following line manually in LocalSettings.php, and possibly also restart your httpd server:
$wgUseTeX = true;
Here is a method to restart the httpd server under Fedora:
/etc/init.d/httpd restart - from root prompt (not recommended) sudo /etc/init.d/httpd restart - from user prompt with sudo configured
After enabling $wgUseTeX, you might see an error message such as this:
Failed to parse (Can't write to or create math output directory):
In MediaWiki file Math.php one finds this source code line:
global $wgMathDirectory, $wgTmpDirectory, $wgInputEncoding;
In my default LocalSettings.php I found these lines:
$IP = "/var/www/mediawiki";
$wgUploadDirectory = "$IP/images";
# ...
$wgMathDirectory = "{$wgUploadDirectory}/math";
$wgTmpDirectory = "{$wgUploadDirectory}/tmp";
$wgTexvc = '/usr/bin/texvc';
$wgUseTeX = true;
Which suggested this fix:
cd /var/www/mediawiki/images sudo mkdir math sudo mkdir tmp sudo chown apache math tmp sudo chmod 775 math tmp
And then there was math.
For Fedora-specific bug reports, use http://bugzilla.redhat.com/ with the product field set to "Fedora Extras" and the component field to "mediawiki".
(PNG conversion failed; check for correct installation of latex, dvips, gs, and convert) :
If you have no error with php but no png generated, it's seems to be a problem with a configuration file of Tex. I solved my problem executing
fmtutil-sys --all
For more informations, I found the solution here : http://forums.fedoraforum.org/showthread.php?t=197978