And also please answer other people's questions, if you know the solution.

Editable subpages are:

# Joy of errors

## Internal Server Error

Hi I am running Centos 5.7 with httpd-x86_64-2.2.3 with mod_wsgi, python 2.4.3 (as per yum) moin-1.9.3. I have it all installed but am receiving Internal server error, here is my apache log:

[Wed Nov 09 14:25:49 2011] [info] mod_wsgi (pid=30427): Create interpreter 'flexo2.amer.gettywan.com|'.
[Wed Nov 09 14:25:49 2011] [info] [client 10.194.100.139] mod_wsgi (pid=30427, process='moin', application='flexo2.amer.gettywan.com|'): Loading WSGI script '/usr/local/share/moin/moin.wsgi'.
[Wed Nov 09 14:25:49 2011] [error] [client 10.194.100.139] mod_wsgi (pid=30427): Target WSGI script '/usr/local/share/moin/moin.wsgi' cannot be loaded as Python module.
[Wed Nov 09 14:25:49 2011] [error] [client 10.194.100.139] mod_wsgi (pid=30427): Exception occurred processing WSGI script '/usr/local/share/moin/moin.wsgi'.
[Wed Nov 09 14:25:49 2011] [error] [client 10.194.100.139] Traceback (most recent call last):
[Wed Nov 09 14:25:49 2011] [error] [client 10.194.100.139]   File "/usr/local/share/moin/moin.wsgi", line 43, in ?
[Wed Nov 09 14:25:49 2011] [error] [client 10.194.100.139]     from MoinMoin.web.serving import make_application
[Wed Nov 09 14:25:49 2011] [error] [client 10.194.100.139] ImportError: No module named MoinMoin.web.serving

Any help is greatly appreciated. Is it python version? Thanks so much.

A: As you see in the last log line, it does not find the MoinMoin code and can't locate and import the code modules. Please fix your sys.path (see moin.wsgi), add the directory that contains the MoinMoin/ code directory. Verify also that the user account running the web service has access to the MoinMoin folder (e.g.: on Apache, the user is by default www-data and you have to add it to the staff group to get access to /usr/local/lib/pythonX.X/site-packages with X.X replaced by your python version).

## Internal Server Error (2)

Hi, I got suddenly Internal Server Error. Could someone help me with it? My apache error-log says this when i try to refresh page:

[Thu Oct 25 12:55:21 2012] [error] 2012-10-25 12:55:21,507 ERROR MoinMoin.wsgiapp:293 An exception has occurred [https://10.1.1.111/moinwiki/].
[Thu Oct 25 12:55:21 2012] [error] Traceback (most recent call last):
[Thu Oct 25 12:55:21 2012] [error]   File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 282, in __call__
[Thu Oct 25 12:55:21 2012] [error]     response = run(context)
[Thu Oct 25 12:55:21 2012] [error]   File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 88, in run
[Thu Oct 25 12:55:21 2012] [error]     response = dispatch(request, context, action_name)
[Thu Oct 25 12:55:21 2012] [error]   File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 136, in dispatch
[Thu Oct 25 12:55:21 2012] [error]     response = handle_action(context, pagename, action_name)
[Thu Oct 25 12:55:21 2012] [error]   File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 195, in handle_action
[Thu Oct 25 12:55:21 2012] [error]     handler(context.page.page_name, context)
[Thu Oct 25 12:55:21 2012] [error]   File "/usr/lib/python2.7/dist-packages/MoinMoin/action/__init__.py", line 268, in do_show
[Thu Oct 25 12:55:21 2012] [error]     content_only=content_only,
[Thu Oct 25 12:55:21 2012] [error]   File "/usr/lib/python2.7/dist-packages/MoinMoin/Page.py", line 1022, in send_page
[Thu Oct 25 12:55:21 2012] [error]     eventlog.EventLog(request).add(request, 'VIEWPAGE', {'pagename': self.page_name})
[Thu Oct 25 12:55:21 2012] [error]   File "/usr/lib/python2.7/dist-packages/MoinMoin/logfile/eventlog.py", line 50, in add
[Thu Oct 25 12:55:21 2012] [error]     self._add(u"%d\\t%s\\t%s\\n" % (mtime_usecs, eventtype, values))
[Thu Oct 25 12:55:21 2012] [error]   File "/usr/lib/python2.7/dist-packages/MoinMoin/logfile/__init__.py", line 460, in _add
[Thu Oct 25 12:55:21 2012] [error]     self._output.write(line)
[Thu Oct 25 12:55:21 2012] [error]   File "/usr/lib/python2.7/dist-packages/MoinMoin/logfile/__init__.py", line 162, in __getattr__
[Thu Oct 25 12:55:21 2012] [error]     self._output = codecs.open(self.__filename, 'a', config.charset)
[Thu Oct 25 12:55:21 2012] [error]   File "/usr/lib/python2.7/codecs.py", line 881, in open
[Thu Oct 25 12:55:21 2012] [error]     file = __builtin__.open(filename, mode, buffering)
[Thu Oct 25 12:55:21 2012] [error] IOError: [Errno 13] Permission denied: '/usr/share/moin/data/event-log'
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111] mod_wsgi (pid=9038): Exception occurred processing WSGI script '/usr/share/moin/moin.wsgi'.
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111] Traceback (most recent call last):
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/dist-packages/werkzeug/wsgi.py", line 411, in __call__
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     return self.app(environ, start_response)
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 282, in __call__
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     response = run(context)
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 88, in run
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     response = dispatch(request, context, action_name)
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 136, in dispatch
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     response = handle_action(context, pagename, action_name)
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 195, in handle_action
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     handler(context.page.page_name, context)
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/dist-packages/MoinMoin/action/__init__.py", line 268, in do_show
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     content_only=content_only,
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/dist-packages/MoinMoin/Page.py", line 1022, in send_page
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     eventlog.EventLog(request).add(request, 'VIEWPAGE', {'pagename': self.page_name})
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/dist-packages/MoinMoin/logfile/eventlog.py", line 50, in add
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     self._add(u"%d\\t%s\\t%s\\n" % (mtime_usecs, eventtype, values))
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/dist-packages/MoinMoin/logfile/__init__.py", line 460, in _add
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     self._output.write(line)
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/dist-packages/MoinMoin/logfile/__init__.py", line 162, in __getattr__
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     self._output = codecs.open(self.__filename, 'a', config.charset)
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]   File "/usr/lib/python2.7/codecs.py", line 881, in open
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111]     file = __builtin__.open(filename, mode, buffering)
[Thu Oct 25 12:55:21 2012] [error] [client 10.1.1.111] IOError: [Errno 13] Permission denied: '/usr/share/moin/data/event-log'

I have tried change event-log permissions, but it didn't help.

Well, that's clearly a permissions issue. Also check permission of all directories on that path. Make sure you know what uid/gid your moin process is running under. -- ThomasWaldmann 2012-10-28 10:44:50

## How do you get moinmoin 1.9.3 to use python 2.6.x rather than 2.7.1? Getting "Unhandled Exception" errors.

I am running Ubuntu Desktop 11.04 with the 11.04 server installed on top via tasksel. I keep getting "Unhandled Exception An unhandled exception was thrown by the application." when running moinmoin 1.9.3. I know its trying to run on python 2.7.1 but there is no support for that yet with moinmoin 1.9.3. I installed python2.6 and put #!/usr/bin/python2.6 at the top of moin.cgi. Is this where 2.6 is located in Ubuntu? Are there any Ubuntu users here? What do I put in moin.cgi for a python 2.6 path?

## Attaching some files fails with "No file content. Delete non ASCII characters from the file name and try again."

I am using Windows, Apache 2.2 with mod_wsgi and MoinMoin 1.9

I try to upload some files and they fail, for example 'httpd-2.2.17-win32-x86-openssl-0.9.9o.msi' will not upload, even when I retype the name replacing the '.' with ',' for all but the '.msi'

Strangely if I zip the file (which just changes the extension) it works ok.

Please create a bug report about this. I just verified that it did behave as expected for a linux server, You can add to the bug report page an example which don't work for your windows server. We need to know which browser you use because of _do_upload

## Navigation problem in Internet Explorer

Hi, we're experiencing this odd navigation event saving changes in text edit mode:

* Internet Explorer cannot display the webpage Most likely causes:
o You are not connected to the Internet.
o The website is encountering problems.
o There might be a typing error in the address.
More information: This problem can be caused by a variety of issues, including:
o Internet connectivity has been lost.
o The website is temporarily unavailable.
o The Domain Name Server (DNS) is not reachable.
o The Domain Name Server (DNS) does not have a listing for the website's domain.
o If this is an HTTPS (secure) address, click Tools, click Internet Options, click Advanced, and check to be sure the SSL and TLS protocols are enabled under the security section.

But it did save the text.

We get this more often than not, when saving changes, both from text and gui edit modes. Also we get it when previewing changes, and when that happens, the changes get lost.

We've tested this with both IE and Firefox, and it is definitely IE specific, or at least, we don't get it, ever, with Firefox.. Our connection settings are exactly the same in both.

We are using python 2.6.1 from python.org, and the PKG-INFO file says MoinMoin 1.8.1. Using IE v7.0.5730.13.

You might consider adding a Help page called HelpOnVersion.

Do you have a version that addresses this problem? We don't have the option of not supporting IE.

Thanks,

Darrell.

Well, one possible cause is missing from the list given by IE:

• Internet Explorer is crap and behaving silly.

Sorry if that sounds funny / not constructive to you, but after having seen lots of IE bugs / non-standard behaviours and waisted many hours trying to work around such crap, maybe it just boils down to that.

What would be helpful is if someone would find out what is triggering this strange IE behaviour and whether there is a workaround. I guess we would then implement that workaround (if it does not harm stuff for standards compliant browsers). Please do not expect that this workaround will be found by moin developers, because (AFAIK) noone of them is using IE and most are quite tired of wasting many hours of their free time just to make that piece of crap of a browser behave.

Another option is to report this problem to Microsoft's IE team. Maybe they can fix it. As other browsers do not show this strange behaviour, it is likely a bug in THEIR software.

-- ThomasWaldmann 2009-02-12 08:12:11

## Cannot create new pages

I have moved my MoinWiki Persona Ed. from 1.5.something to 1.6.0 without problems. But now I cannot add new pages. I create the link, but when clicking on it it display the usual page with: This page does not exist yet. You can create a new empty page, or use one of the page templates.

Action(edit,Create new empty page)

etc.

Now clicking on Action do absolutely nothing except changing to the http://localhost:8080/Action%28edit%2CCreate%20new%20empty%20page%29 Page.

Any idea? Thanks! mario

Is that on Mac OS X? There is a known bug in 1.6.0 for Mac users, it is fixed already in the 1.6 repo (see http://hg.moinmo.in/moin/1.6/ ) and will be in 1.6.1.

mario-> no I'm on WinXP

Do you have replaced the underlay dir of your wiki instance with the shipped one? If so please check if you have a changed MissingPage page in your wiki.

mario-> Solved! I installed 1.6.1 then copied the content of /wiki/pages (except BadContent, already present) from my 1.6.0 installation to 1.6.1 and now everything works as expected. Thanks for your help!

mijo: I had the same problem. I think, I mixed up the underlay-directory. I solved the problem by removing the underlay-dir and reinstalling it with a new one (of the same version!)

IIS will return a 404 error when you click a link to a new WikiWord (ie. a missing link), if the wiki instance virtual directory is not correctly configured. This is caused by IIS returning a custom error message with the 404, rather than the industry standard default of "Not Found". It looks like Moin is reading the contents of the page returned rather than the status code, not sure if that is the correct way to implement the redirect. In any case, the fix is to change the custom error for the wiki virtual directory.

• Right click the wiki instance virtual directory and select Properties

• Click the Custom Errors tab

• Scroll down to 404 (don't worry about 404;2 or 404;3) and click Edit...

• Change the Message Type to Default

• Click Ok

-- ChristopherBrandt 2009-04-09 20:06:00

You may want to read HowTo/MoinOnIIS and modify it if it is not correct. -- ReimarBauer 2009-04-09 20:38:33

## Are there reserved words

I am unable to write the word "Python" without the quotes on some of my pages, when I go to save I get a 403 Forbidden.

"You don't have permission to access /cgi-bin/moin.cgi/blahBlah on this server. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request."

When I remove "Python" from the page, it saves. Are there reserved words or phrases?

Well, you can put anything you like onto LocalBadContent page (which is intended for spam protection, not Python protection ). In case you are running IIS you need to fix its broken http error handling, see the IIS infos in the docs.

## Pages load text but no formatting

I am trying to install Moin on IIS and I am stumped. I get no error messages when loading the page but only the ext shows up, no images and no formating. Since it is a new install I have deleted and reinstalled to see if I somehow missed a step in the configuration but each time it is the same. Any ideas of why fomating and images wouldn't show up?

## Premature end of script headers

I'm trying to get moin running under MyFavorite OS. The Installation documentation seem strange and somewhat false. Yet I've followed the instructions by the book, I get this error with no traceback whatsoever:  Premature end of script headers: moin.cgi  or  The specified CGI application misbehaved by not returning a complete set of HTTP headers.  Running moin.cgi from the command line works fine and returns lots of nice HTML code.

### Solution

This is a common error message which can have a lot of reasons:

• Wrong owner of the wiki directory
• Wrong permissions
• Wrong #!/path/to/python
• ScriptAlias is broken

Try to look into the server error log to get more information.

On an IIS webserver, this error can occur when the IIS engine somehow loses the ability to spawn Python CGI processes correctly. If your configuration is correct and this error mysteriously occurs, try a reboot of the entire system (a simple iisreset does not seem to be enough to solve this problem).

See more troubleshooting tips on the MoinMoinQuestions/Installing page.

## Some of the tests fail

When running action=test, I get few errors:

parser.wiki: DateTime macro ... FAIL
wikidict: names in SystemPagesGroup should be in request.dicts ... FAIL

### Solution

Delete data/cache/wikidicts/* to fix the wikidicts test. The first test might fail on certain system and is a problem with your system libraries, not with moin. There is a note about it and a link to the bug page in the test error report.

## Error when saving page "Page could not get locked. Missing 'current' file?"

I get the error when editing and saving the page FrontPage. I've tried altering the file permissions but with no luck. Since I can't save the first page I've no idea if this affects other pages. -- ThiloPfennig 2006-01-23 07:57:31

### Solution

Go to data/pages/FrontPage/ and rename the current-locked file to current.

• Also try: Go to data/pages/BadContent/ and rename the current-locked file to current. (I think it might alter BadContent on each edit attempt)

• For more details to debug this, edit PageEditor.py and in the _write_file() function inside the loop where it tries to write the file, have the failure be reported into a log file of your choosing with something like this:

except OSError, err:
write_to_my_logfile( 'exception: got an OSError: '+ str(err) )
• Another solution: With my DesktopEdition it happened that I lost the current file in pages/ U  s e r N a m e/MoinEditorBackup. As a result I could not edit any file and got the same error. Rebuilding the current file helped. (I assume I lost the file when saving multiple pages in rapid succession from different browser tabs).

• The above is also true on systems where the slash is encoded (such as "(2f)" for example). So it would be: pages/ U s e r N a m e(2f)MoinEditorBackup instead. In other words, you should make sure that a current file exists in this path. You could copy an existing current file from elsewhere (usually with a content of "00000001"). Why on earth this file had disappeared in the first place is still a mystery.

• Another possible cause: no free disk space

## Error when canceling edit "Page could not get locked. Missing 'current' file?"

We saw this error for one specific user. When she tried to cancel an edit, she would get this error.

### Solution

MoinMoin tries to write UserName/MoinEditorBackup on cancel, so you can recover the edit in case you didn't really want to cancel. These pages exist even if there are no links to them in the Wiki (as was the case for us). Somehow, this page was corrupted and was missing it's "current" file. Deleting the UserName/MoinEditorBackup page was the solution.

## wiki Self confused between different wiki instances

I have installed 3 wiki instances (not as a farm). Looking at the following link on the HelpOnEditing page

* wiki:Self:HelpOnPageCreation#variablesubstitution - which variables are substituted (like @''''''SIG@, @''''''MAILTO@ ...)

generates a link to one of the other wiki instances. This is 'cured' when 'wiki:' removed.

## Could not find a match for url

I'm getting: Could not find a match for url: "10.0.0.27:85/personal-wiki/moin.cgi/?". Check your URL regular expressions in the "wikis" list in "farmconfig.py".

### Solution

If you are not running a wiki farm, delete farmconfig.py from your wiki directory.

## Verification failed for Unrouteable address Sender verify failed

My users get this error when they save pages other people subscribed.

### Solution

Make sure your mail_from is set to a legal address, e.g "My Wiki <noreply@mydomain", when mydomain is real domain.

## Newsfeed under the weather

2.3.5 (#2, Sep 4 2005, 22:01:42) [GCC 3.3.5 (Debian 1:3.3.5-13)] The newsfeed appears to be rendering the RSS successfully when I check the link in my browser, but the feed doesn't load into Firefox when it is Live Bookmarked. This MoinMoin wiki is using the farmconfig.py but I placed the Link Rel in the local mywiki.py config file. What could be wrong?

• Did you try it without html_head?

I did and it doesn't render the RSS instruction in the (html) page header at all! BTW: the failure is because of the XMLNS being <rdf:RDF xmlns:None="http://purl.org/rss/1.0/ ... Why is it xmlns:None? If I save the output file and remove the offending ":None" the file can be successfully read by any news aggregator.

I found a solution - it appeared, at least on my config to require Python2.4.

However, XSLT (even when enabled in the config.py file) from the page XsltVersion returns "XSLT processing is not available!". Is there some other switch than needs to be enabled or action taken? Is it unable to locate a library. Now using Python 2.4.1 (#2, May 5 2005, 11:32:06) [GCC 3.3.5 (Debian 1:3.3.5-12)], with MoinMoin 1.3.4 [Revision 1.3.4 release].

Does anyone who has used XSLT ever read this page? Come on - what needs to be set in order to make this feature work?

• I don't use it, but you need 4suite installed. Exactly. So, initial reporter, why did not you find the advise to install 4suite? This is documented at multiple places.

## WikiWord would not appear with Spaces as Wanted in the UserPreferences

### Solution

edit the wiki.py script and locate the following lines

# handle anchors
parts = word.split("#", 1)
anchor = ""
if len(parts)==2:
word, anchor = parts
#here the change
self.formatter.text(text) +

input the following lines

split_re = re.compile('([%s])([%s])' % (config.chars_lower, config.chars_upper))
text = split_re.sub(r'\1 \2', text)

Email: <Werner DOT Hoevelmanns AT schmiechen DOT de>

I have done exactly as described above, but don't get any result. WikiNames are still written as "WikiNames" and not as "Wiki Names" as should be. If you have any solution or explanation, please publish here, mail me, if possible and delete this text!

<mail AT benschwarz DOT de>

## ImportError: No module named wikiconfig

I done all steps as described in the configuration docs word by word. I'm using Foo OS 3.1 with apache2 (I also tryed apache 1.3). When I try to browse the wiki I allways get this error:

• ImportError: No module named wikiconfig Check that the file...

This error tell you that the moin can't find wikiconfig.py module. This can be caused by:

• Wrong permissions
• Wrong ownership
• You renamed the file
• If you used farmconfig.py, the wiki names in the wikis list may be wrong.

## reference to mywiki for HelpOnEditing / SyntaxReference

I have installed moinmoin using Apache. The wiki is called "twmwiki" and everything seems to work fine. I can edit pages and display them and I can also view the content that came with the installation like HelpOnEditing etc. as long as I use the links from the frontpage. What does not work are the links from the editing page where it says "For more help, see HelpOnEditing or SyntaxReference.". Those link to http://localhost/mywiki/HelpOnEditing which of course does not exist and therefore only returns a 404 error.

I wonder whether this is a configuration error (I could not find any references to "mywiki" in my configuration or a bug in moinmoin? -- twm

• Use cachecleaner script after configuration changes.

I was afflicted with the same problem. HelpOnEditing and SyntaxReference (at the bottom of the edit(text)-page) pointed to host/instance_name/page, but they should point to host/page. ThomasWaldmann suggested to clear data/cache/i18n. That solved the problem.

## Missing SyncPages Action on Desktop Edition

I try to synchronize content of my web based wiki with a Desktop Edition (for offline editing). When I start the synchronisation I got the following error:

Unknown action SyncPages

Is there any possibility to install/activate this action for the local edition?

## Getting [Error 17] Cannot Create a file when that file already exists

I move one wiki instance from one machine to another. It is fine to show the initial page, but when everytime I click a link inside of the initial page. An error message always shows up said [Error 17] Cannot Create a file when that file already exists. This is the url display in address bar http://127.0.0.1/dblue/moin.cgi/dBlueHome. But if i manaually type URL like that myself in address bar http://127.0.0.1/dblue/moin.cgi/dBlueHome?highligh=%28dbluehome%29 or do the search from search field and it turns out showing content fine.

## data_underlay_dir "/srv/www/vhosts/name/cgi-bin/daten/moin/intern/data/underlay/" does not exists, or has incorrect ownership or permissions.

Today is the day.. ok, small problem. I setup a complete new wiki. python... import MoinMoin ... CTRL+D perfect the data directory is beyond cgi-bin the wikiconfig.py is within /srv/www/vhosts/name/cgi-bin/daten/moin/intern/ .. .pyc is generated From the wikiconfig.py:

data_dir = '/srv/www/vhosts/name/cgi-bin/daten/moin/intern/data/'
data_underlay_dir = '/srv/www/vhosts/name/cgi-bin/daten/moin/intern/data/underlay/'

The Rights are 770 from /srv/www/vhosts/name/cgi-bin/daten/ down The group + Username are ok (if y change them, the wikiconfig.py is no longer loaded)

So: the wikiconfig is loaded but the underlay dir never found. I tried: ./underlay/ underlay/ daten/moin/intern/data/underlay/ and ./daten/moin/intern/data/underlay/ and of course the absolut path.

Ah, to create the instance I took: createinstance.sh with: INSTANCE=/srv/www/vhosts/name/cgi-bin/daten/moin/intern

I'am out of Options. Any ideas? oh, apache config is fine. it hast a Alias for moin.cgi in the cgi-bin directory mentioned above.

Traceback:
A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.
1.
/usr/lib/python2.4/site-packages/MoinMoin/multiconfig.py in getConfig (url='name.com/intern')
1. 158 configName = _getConfigName(url)
2. 159 try:
3. 160 config = _config_cache[configName]
4. 161 except KeyError:
5. 162 config = _makeConfig(configName)
* config undefined
* global _config_cache = {}
* configName = 'wikiconfig'
KeyError
'wikiconfig'
* args = ('wikiconfig',)

-- Max 2007-04-09

## Error While Saving Page

When I am trying to save the pages I get the following error. I am setting up MoinMoin on Windows XP and IIS

File "C:\Moin\Lib\site-packages\MoinMoin\request.py", line 1151, in run
handler(self.page.page_name, self)
File "C:\Moin\Lib\site-packages\MoinMoin\wikiaction.py", line 659, in do_edit
savemsg = pg.saveText(savetext, rev, trivial=trivial, comment=comment)
File "C:\Moin\Lib\site-packages\MoinMoin\PageEditor.py", line 976, in saveText
mtime_usecs, rev = self._write_file(newtext, action, comment, extra)
File "C:\Moin\Lib\site-packages\MoinMoin\PageEditor.py", line 867, in _write_file
glog.add(self.request, mtime_usecs, rev, action, self.page_name, None, extra, comment)
File "C:\Moin\Lib\site-packages\MoinMoin\logfile\editlog.py", line 178, in add
File "C:\Moin\Lib\site-packages\MoinMoin\logfile\logfile.py", line 406, in _add
self._output.write(line)
File "C:\Moin\Lib\site-packages\MoinMoin\logfile\logfile.py", line 139, in __getattr__
self._output = codecs.open(self.__filename, 'a', config.charset)
File "C:\Python23\lib\codecs.py", line 566, in open
file = __builtin__.open(filename, mode, buffering)
IOError: [Errno 13]   File "C:\Python23\lib\codecs.py", line 566, in open
file = __builtin__.open(filename, mode, buffering)
IOError: [Errno 13] Permission denied: 'data\\edit-log'

What wrong I am doing ??

Abhishek

## 'module' object has no attribute 'getmro'

I followed the HelpOnInstalling/BasicInstallation instructions carefully, and while most of the test steps seem to work (e.g., "import MoinMoin" is fine), when I run moin.cgi either on the command line or via Apache (CGI), I get:

[...long traceback...]
File "/usr/local/lib/python2.3/site-packages/MoinMoin/support/copy.py", line 74, in _getspecial
for basecls in inspect.getmro(cls):
AttributeError: 'module' object has no attribute 'getmro'}

Same error when I run runtests.py. Apache runs the CGI script but of course moin.cgi is returning a 500 error complaining about this missing attribute. I looked at line 74 of copy.py, and all it's doing is "for basecls in inspect.getmro(cls):". Well, python sure thinks it has it:

[...]
>>> import inspect
>>> inspect.getmro
<function getmro at 0x81d4fb4>

I thought perhaps I wasn't using the right python, so I replaced moin.cgi's #!/usr/bin/env python with an explicitly specified python (2.3) that's the same as the one my shell's PATH prefers. No difference. Help!

• check if the python you run interactively is the same as for cgi (chroot? path?)
• we need the complete python -V output of the python making you troubles
• you can try copying your python's "copy.py" over the one we deliver in MoinMoin/support. Our copy.py is intended to fix some problems that existed in old pythons, but maybe the one your Python has works better for you.

## Moving my Wiki from one PC to another

I am evaluating MoinMoin as a project managment and tracking tool for my work group. I am running it on Windows XP. I recently have had my PC upgraded. The original copy of my Wiki is still running on the old PC but I need to port it over to the new one. I installed Moin, Python, Pyxml etc on the new PC. Next I followed the directions provided in the installation heklp page to create my Wiki again, making sure the name was the same as before. Finally I copied the User and Pages directories within the \MyWiki\Data folder with the onces running on my old PC. Now when I go to my Wiki on the new PC I get the message:

IOError

[Errno 13] Permission denied: 'data\\pages\\<My_Wiki_Name>\\cache\\text_html'

I am at a loss. Any suggestions?

Are you sure that you have used the right owner for the files on the second new XP windows system. Is it the same owner as the wiki instance you have removed and does have this worked before? -- ReimarBauer 2006-05-26 09:58:23

-- Laiq on Friday May 26th, 2006 at 12:13 PM: Thankyou for your response. I really hope you can help me with this.

The Wiki is running fine on the old PC and my user profile and access rights etc in the new PC should be the same as in the old PC.

Yesterday I went in and renamed the text_html file under the all the data\\pages\\<page_name>\\cache folders. With this change I am now able to load and see the Wiki correctly. But now when I edit any page and then try to preview or save it I get the following error and the changes are not saved:

Page could not get locked. Unexpected error (errno=13).

Looking at the traceback it seems the error is coming from: C:\Moin\Lib\site-packages\MoinMoin\PageEditor.py in _write_file

Also now when I run the self-test I see the following errors:

====================================================================== ERROR: testBasicPackageThings (MoinMoin._tests.test_packages.UnsafePackageTestcase)

• Traceback (most recent call last):
• File "C:/Moin/Lib/site-packages\MoinMoin\_tests\test_packages.py", line 54, in setUp

• raise TestSkipped('This test needs to be run using the test wiki.')

TestSkipped: This test needs to be run using the test wiki.

• Traceback (most recent call last):
• File "C:/Moin/Lib/site-packages\MoinMoin\_tests\test_user.py", line 95, in testAsciiPassword

File "C:/Moin/Lib/site-packages\MoinMoin\user.py", line 270, in init

• self.id = getUserId(self._request, self.name)

File "C:/Moin/Lib/site-packages\MoinMoin\user.py", line 68, in getUserId

• cache.update(pickle.dumps(_name2id, PICKLE_PROTOCOL))

File "C:/Moin/Lib/site-packages\MoinMoin\caching.py", line 92, in update

• f = open(self._filename(), 'wb')

IOError: [Errno 13] Permission denied: 'data\\cache\\user\\name2id'

• The second error regarding the user:login is new.

THe first error is there on the wiki runnning on my old PC as well so I think we can ignore it for now.

The "Page could not get locked. Unexpected error (errno=13)." error happened to me because the permissions weren't right in the data directory -- the owner/group hadn't been changed to www-data. I needed to do e.g. chown -R www-data:www-data data .

• peter

## Internal Server Error - Problem with request.py

Hi, this is probably a typical case of PEBKAC, but maybe you could help anyways?

I just tried to set up a MoinMoin Wiki on my computer to try it out. I followed the instructions on this Wiki regarding installation but when I try to open it, i get an internal server error.

My Software: WinXP; Apatche 2.2; Python 2.4.3

the apatche error log entry reads as follows

[Tue May 30 09:57:39 2006] [error] [client 127.0.0.1] (OS 5)Zugriff verweigert  : couldn't create child process: 720005: moin.cgi
[Tue May 30 09:57:39 2006] [error] [client 127.0.0.1] (OS 5)Zugriff verweigert  : couldn't spawn child process: C:/moin/mywiki/moin.cgi

NOTE: Yes, my moin Instance is in c:/moin/mywiki

when I rename moin.cgi to moin2.py and run it in idleI get the following traceback:

Traceback (most recent call last):
File "c:\Python24\Lib\site-packages\MoinMoin\request.py", line 1372, in __init__
msvcrt.setmode(sys.stdin.fileno(), os.O_BINARY)
AttributeError: PyShell instance has no attribute 'fileno'

I didn't touch request.py. *scratches head*

Help would be greatly appreciated, thanks in advance!

Fischi

I also am having the same problem have you solved this yet?

Bryan

Try testing it starting the python interpreter from a cmd, not with idle.

• I've had the same problem. In my case the shebang (1st line with the #!) of the moin.cgi script was incorrect. When i changed it to the absolute path to my python.exe, the error was gone and the wiki started. E. g.: #!c:/Programme/Python/python.exe

• Anselm

## Cannot allocate memory ?

I've seen this message in my apache error log on several occaitions. Cannot allocate memory: couldn't spawn child process: /var/www/ACDCWiki/cgi-bin/moin.cgi Any ideas on what can be done to fix this?

• Do you have any resource (memory) restrictions in place for cgi scripts? If yes, they are maybe not high enough.
• No not that I know of. I have a standard Apache 2.0.46 installation. Python 2.4. Although I have only 128mb ram. Could that be an issue?
• If you are that low on RAM, you should at least have a bigger swap partition / swap file. Maybe use top (Linux) or some other tool on your OS to monitor RAM usage. If you don't need apache2 for other stuff, you could also use moin standalone server and save the memory needed for apache2 and also the startup time needed to load python and libs (standalone stays resident in memory all the time).

## Very narrow editor text area

When editing a page, the editor box is about 13 characters wide.

### Solution

The cause is missing css files:

1. Try to reload the page few times
2. Try to delete the browser cache
3. Check that your url_prefix is configured properly.

## EMail again

I tried to set up EMail notification, but get

(with a real address, of course) when I try to mail something. I'm not sure if the mail system chokes on the unicode notation. Worse: After removing the entries from mail_smarthost and mail_from, the EMail button remains on the user preferences page.

• Then your mailserver seems to be setup incorrectly. Ask the administrator. And the last issue looks like your configuration change is not sensed. Try to make sure that you edited the correct file and clean all related .pyc files. The email button in the user preferences page is new addition, it may be broken and ignore the mail configuration. Note that the "Subscribe" and "Unsubscribe" links are not displayed when email is not configured.

Is there any way to find out if MoinMoin received any errors from the SMTP session?

• Sure, just look at the status message you see after you have saved the page.

Interesting. I managed to find a configuration error on my part, but fixing that doesn't actually make things work. I can now get email sent when I click the "Mail me my account data" button on the UserPreferences page, but I don't get change notifications when I use a test-user login to make changes to a page, but I do get a long traceback where the smptlib module tries to base64-decode something that isn't encoded. Since the traceback includes password information, I'll have to try and debug it myself. I'm using Python 2.4.1 and MoinMoin 1.3.5.

## Wiki runs fine just won't save pages!

I'm running MoinMoin on Fedora 4, Apache 2.0.54, Python 2.4 with mod_python-3.1.4 (as a DSO, no alternative there). The wiki works fine, and I can view the basic pages. The file permissions are set to the webserver name:group, and can write files as it writes the edit-lock file when you preview a page. However, it just will not save any pages! Is there any finer grained logging available than that in httpd's error_log? That gives the very unhelpful error

[Tue Oct 11 15:16:11 2005] [notice] child pid 28195 exit signal Segmentation fault (11)

Any help would be appreciated.

• SIG11 often is related to hardware problems, most often bad RAM or CPU. Maybe use memtest86+ to check if your RAM is working ok.

I'm not convinced it's a hardware problem, as it's a new Supermicro box which has no obvious problems at all. I'll have a look at the memtest you suggested though. All other apps/services are working fine. Thanks for the propmt reply, Thomas. I'll try recompiling mod_python with different options as I compiled Apache to use MPM worker thread. Found the following here:

• "Overall, segmentation faults in mod_python are more likely to be caused by Apache, mod_python and Python being built with differing ideas of how threading is supposed to be enabled."

That maybe true... but it didn't help. I tried compiling Apache with the mpm_prefork option (and recompiling mod_python) but it gave me the same error, though strangely it appeared twice (two error messages) for mpm_worker and only once for mpm_prefork. Go figure. I gave up! If anyone resolves this I'd love to see a solution posted here.

## Install error

/usr/local/python-2.4.2/share/moin/server>python moin.py Traceback (most recent call last):

File "/usr/local/python-2.4.2/lib/python2.4/site-packages/MoinMoin/server/standalone.py", line 41, in ?

• import os, sys, time, urllib, socket, errno, shutil

ImportError: No module named time

How do i go about solving it??

Start an interactive interpreter by entering python and do a manual import time there. If it also fails, get a non-broken python installation. If it works, check if you broke sys.path somewhere in the moin scripts.

## New Wiki Installation: Can see FrontPage, but can't edit??

I just installed my first wiki pages on an apache server running on Linux. Installation was smooth enough. And I've read over the docs and troubleshooting multiple times. I can see the front page when I load http://my.server.com/mywiki, but none of the other pages load when clicked, including Edit! So I'm stuck with a FrontPage. The diagnostic /mywiki?action=test looks fine, all OK. I'm definitely seeing the moin.cgi file and the wiki .py config file, because the FrontPage displays custom images and text, so I'm fairly sure my httpd.conf is OK. And my python files are in the default location, which I have even tried explicitly identifying in the config file. Permissions on all relevant directories is set to apache.apache (same as in my httpd.conf) and mod is a+rX. Any other troubleshooting ideas? I feel like I'm so close!

When I click 'Edit' I get:

Thanks, Alex

I figured out the problem by following an alternate source of installation instructions

The critical issue appears to be the location of the moin.cgi file. I had placed it in a cgi-bin under a copy of htdocs which was all under my wiki instance directory. I had set up an alias and permissions for the htdocs dir to be visible to the server in httpd.conf (but perhaps this was not done properly?). Once I moved the moin.cgi file to my primary cgi-bin located at the same dir level as my default html dir, then it all worked flawlessly. I updated my ScriptAlias to this location and it's all set. Case closed.

• COMMENT

I am very close, too - but here the reason seems to be different. Whatever subpage I open, it does not exist (404). /var/log/apache2/error.log says correctly:

[Fri Aug 10 20:38:16 2007] [error] [client 10.0.2.10] File does not exist: /usr/share/moin/htdocs/SeiteFinden, referer: http://10.0.2.10/wiki - as: {{{$ls /usr/share/moin/htdocs applets common index.html rightsidebar classic favicon.ico modern robots.txt$ locate SeiteFinden /var/www/moinmoin/underlay/pages/SeiteFinden /var/www/moinmoin/underlay/pages/SeiteFinden/current /var/www/moinmoin/underlay/pages/SeiteFinden/revisions }}}

OK, perhaps the same problem here: can see mywiki/moin.cgi but can't see mywiki/moin.cgi/ oder anything like mywiki/moin.cgi/*. Looks like the "/" after moin.cgi isn't interpreted right. Btw, i always do get a 404-error. Any ideas?

The links at the bottom of my edit page are broken. The links that look like the following:

The links are in the form http://example.com/folder/SynataxReference when they should be in the form http://example.com/SyntaxReference. All other links work fine. Only those links refuse to point to the "root" of the server. Why didn't that link change and how do I change it appropriately?

## Trouble running with mod_python

I'm currently trying to run moinmoin 1.5.2 with Apache 2.0.64, python2.4 and mod_python 3.0.1. But I get the error [Sat Feb 18 18:48:37 2006] [error] make_obcallback: could not import mod_python.apache.! Any ideas as to what's wrong??

## UTF-8 does not work in titles of items

Try http://wiki.r2dvd.info/moin.cgi/Čeština. The problem with char encoding is noticable only if you type the url with utf-8 chars directly in your browser, if u come through the anchor above, everything is fine.

## UnicodeDecodeError on moin startup

I'm trying to get desktop moin 1.6.0 running on my office computer which runs Windows XP. When I startup my instance from the command line I get this error:

• UnicodeDecodeError: 'utf8' codec can't decode bytes in position 25-30: unsupported Unicode code range

I'm not very knowledgeable about Windows: do I need to install an updated codec somewhere? -- AmElder 2008-01-14 19:59:40

• Without a bug report including traceback this is hard to tell (you don't need an "updated codec" anywhere for sure, though). This problem is likely some config file or wiki content in a wrong encoding. The config tells the encoding in the first line (the config file content has to be in that encoding), the wiki content has to be utf-8.
• - Thank you, I will submit a bug report, then.

## Embedding of object by chosen formatter not possible

I'm trying to attach a file to my page but when I click on the attachment I get the error "Embedding of object by chosen formatter not possible" and it takes me to the attachment page to download it. This is a word doc. I can get it to work using the do=get url but it is advised not to use that. I would like to use the attachment: option without having to go the attachment page to press download.

• I am having a similar problem in both 1.6.2 and 1.6.3, I didn't seem to have this issue with 1.5.X, although I was also using a different platform. For some reason the wiki is trying to embed the attachment even though it shouldn't based on the mime type of the attached file. I was able to replicate the problem here in the WikiSandBox, so I would guess this is a bug. I will try submitting one. -- JonathanDelgado 2008-05-06 15:54:31

## Looking for attachment in wrong directory

I've attached a file to one of my wiki pages and I can locate the file under WIKI/data/pages/PAGE/attachments (so the attachment process works fine). My problem is that I cannot get to the file from the wiki page. When I click the link to the attachement (link made using attachment:file.pdf) I get a blank page. According to /var/log/httpd-error.log, MoinMoin is looking for the file int the incorrect directory. I have my data_dir set in my wikiconfig, and the attachment makes it to that directory when I upload it, but MoinMoin looks in a different directory when I try to download the file. Any ideas? Thanks! Sean

• Please file a bug report and move this stuff to it. Provide much more details (use the bug template), provide config and log files.
• I rebuilt python and reinstalled moinmoin and everything works again (by the way, I the problem was on freeBSD, Python2.5 - rebuilding completely fixed things)

Hi, I upgraded from 1.5.8 to 1.6.1. I followed the CHANGES instructions. The data upgrade script went through fine. After starting apache (I'm using mod_python, BTW) and trying the wiki in a Browser, only a traceback like the following occurs:

[Wed Mar 19 22:06:04 2008] [notice] mod_python: Creating 8 session mutexes based on 3 max processes and 25 max threads.
[Wed Mar 19 22:06:04 2008] [notice] mod_python: using mutex_directory /tmp
[Wed Mar 19 22:06:04 2008] [notice] Apache/2.2.3 (Debian) mod_python/3.2.10 Python/2.4.4 configured -- resuming normal operations
ERROR:root:RuntimeError: maximum recursion depth exceeded in cmp
Traceback (most recent call last):
File "/usr/local/lib/python2.4/site-packages/MoinMoin/request/__init__.py", line 1248, in run
self.page = wikiutil.getFrontPage(self)
File "/usr/local/lib/python2.4/site-packages/MoinMoin/wikiutil.py", line 783, in getFrontPage
return getLocalizedPage(request, request.cfg.page_front_page)
File "/usr/local/lib/python2.4/site-packages/MoinMoin/wikiutil.py", line 752, in getLocalizedPage
i18n_name = request.getText(pagename, formatted=False)
File "/usr/local/lib/python2.4/site-packages/MoinMoin/request/__init__.py", line 273, in <lambda>
self.getText = lambda text, i18n=self.i18n, request=self, lang=self.lang, **kv: i18n.getText(text, request, lang, **kv)
File "/usr/local/lib/python2.4/site-packages/MoinMoin/i18n/__init__.py", line 257, in getText
dicts = request.dicts
File "/usr/local/lib/python2.4/site-packages/MoinMoin/request/__init__.py", line 366, in getDicts
dicts.scandicts()
File "/usr/local/lib/python2.4/site-packages/MoinMoin/wikidicts.py", line 376, in scandicts
if Page.Page(request, pagename).mtime_usecs() >= self.pageupdate_timestamp:
File "/usr/local/lib/python2.4/site-packages/MoinMoin/Page.py", line 704, in mtime_usecs
for line in logfile.reverse():
File "/usr/local/lib/python2.4/site-packages/MoinMoin/logfile/__init__.py", line 110, in reverse
self.to_end()
File "/usr/local/lib/python2.4/site-packages/MoinMoin/logfile/__init__.py", line 342, in to_end
self._input.seek(0, 2) # to end of file
File "/usr/local/lib/python2.4/site-packages/MoinMoin/logfile/__init__.py", line 158, in __getattr__
return self._input
File "/usr/local/lib/python2.4/site-packages/MoinMoin/logfile/__init__.py", line 158, in __getattr__
return self._input
[... same stuff few hundred times ...]
File "/usr/local/lib/python2.4/site-packages/MoinMoin/logfile/__init__.py", line 158, in __getattr__
return self._input
File "/usr/local/lib/python2.4/site-packages/MoinMoin/logfile/__init__.py", line 132, in __getattr__
if name == "_LogFile__rel_index": # Python black magic: this is the real name of the __rel_index attribute
RuntimeError: maximum recursion depth exceeded in cmp
[Wed Mar 19 22:06:57 2008] [notice] caught SIGTERM, shutting down

Any clues on how the error could be fixed? Seems to me like some log file problem. Permissions are fine though. I'm open for any tips. -- BjörnSchließmann 2008-03-19 22:51:23

• Looks like it can't access a page's edit-log. Please check owner/group/mode of your pages (and use chown -R x.y data ; chmod -R ug+rwX data to set correct owner, group and mode). Especially have a look at data/pages/*Dict/edit-log. If that does not help, apply this patch and retry: http://hg.moinmo.in/moin/1.6/rev/6b64b2cdef2f -- ThomasWaldmann 2008-03-19 23:14:22

• Thank you for the quick help I managed to solve the problem. It was an edit-log, but not in data, but in underlay, as your helpful patch eventually showed (strange, I didn't touch this directory during the upgrade). BTW, is it normal that I have to re-install language packages after upgrade? This should be mentioned in the upgrade guide (or I missed it) -- BjörnSchließmann 2008-03-20 23:11:33

## After upgrade, TableOfContents macro not working with maxdepth

Hi, I've just upgraded from 1.6.0 to 1.7.2 with no problems.

However, when I access the wiki, many of the pages use the TableOfContents macro with the default code as follows:

<<TableOfContents([maxdepth])>>

But when this is rendered it fails with the following error:

<<TableOfContents: Argument "maxdepth" must be an integer value, not "[maxdepth]">>

I can work around this by entering an integer (e.g. 99) instead of maxdepth but that will be painful to change on all of the pages in my wiki.

Any ideas? is there a default to set for maxdepth somewhere?

Thanks, Tom, UK

Maybe you have misunderstood its syntax. When describing some syntax, stuff like [foo] usually means an optional parameter called foo at that place, not that you should type [ f o o ]. So you either can leave it empty or enter an integer at that place. -- ThomasWaldmann 2008-10-17 02:48:19

Hi, thanks I know that but what happened in 1.6.0 was that when you applied the TableOfContents macro, using the GUI editor, it would default to include this maxdepth value, and when rendered, it would display the full tableOfContents. So the users of my Wiki tended to leave this asis which worked fine. Now I've got lots of pages which have this set which aren't displaying the TableOfContents properly

So maybe this is another symptom of the GUI editor as when using text editor you'd have to type the macro in anyway.

## Can't create users after upgrade 1.6->1.7, UserPreferences does not exist (Debian)

After upgrading from 1.6 to 1.7 on debian and creating a fresh wiki instance, I clicked on "login" where a line of text says (like in 1.6) I should go to UserPrefrences to create a new account. However that page does not seem to exist. I even searched /usr/share/moin for it, it simply isn't there. Also manually adding a "?action=newaccount" to the starting page url didn't help.

Hi Henning, please read docs/UPDATE.html and do all steps mentioned there, you likely missed the step to install the new underlay dir to your wiki instance. The systempages and language packs of MoinMoin are kept in the underlay dir. -- ReimarBauer 2008-10-29 10:05:17

Thanks for the quick answer but that doesn't seem to be the problem. What I did was:

• Upgrading from 1.6 to 1.7 with debians package management system
• Creating a new wiki ofter the documentation, ie. copying fresh data and underlay dirs from /usr/share/moin
• Setting up /etc/moin/farmconfig.py to include the new wiki and creating /etc/moin/mywiki.py (which includes absolute and correct paths to underlay and data.

Also I tried renaming the underlay dir (to underlay.bak) which instantly lead to an error message on the new wiki, so it definetely searches in the right place. I also tried reinstalling the moinmoin package (with the package manegement system), and copying data and underlay from anew, but that didn't help either.

I'd guess theres something messed up with the debian package, but I can hardly imagine, since this problem occurs for months now and I can remember at least one new debian package version which did not fix this.

Henning

### Solution

Darn, I finally found out, that not the underlay is the problem but a moinmoin version I had manually installed in /usr/local ages ago. (an "import MoinMoin" followed by a help(MoinMoin) showed me). Thanks for your time, nevertheless

np. Can you tell which MM version debian has now (1.7.x)?

At 2008-11-14 this is 1.5.3-1.2etch in stable, 1.7.1-2 in testing and 1.8.0beta1-1 in experimental. (Obviously I use testing ;))

I have moin 1.5.4 running on a hosted server with Python 2.4.3 . The wiki has run great for a long time. Then suddenly a couple months ago, every attempt to search has resulted in the same traceback error.

I'm reluctant to vertically bloat this section, so I've attached the traceback as an attachment, Davison_Unicode_Trace.html.

If it's helpful to recreate on the original site, here's my link: http://mycompiler.org/Compiler_Wiki/moin.cgi/FrontPage

I'm also trying to get help from my ISP, but I'm almost sure there will come a point where the Moin team can't help more without info. on the python install, and my ISP will think it's a problem with Moin.

Any help greatly appreciated!

Some ideas:

• Did you enable Lupy for indexed search in your wiki config? If yes, I suggest you switch off Lupy.
• If you don't want that, you could also try rebuilding the search index.
• From the error msg, one could also think that the Python is somehow inconsistent internally - some part (C array module) tries to use stuff that is not there. Maybe Python was compiled with wrong features (Python should be always support UCS4, that is 32bit Unicode).
• If ones looks at RecentChanges in that wiki, one finds another problem: the global edit-log is damaged in its structure (one can usually fix that with vim or so).

• As a general note, moin 1.5.4 is rather old, you should upgrade it. The upgrade to 1.5.9 should be rather easy (that fixes some bugs, but is still old), the upgrade to 1.8.x will take a bit more effort.

-- ThomasWaldmann 2009-03-02 07:23:53

## Some users try to save an edit, but delete the page!?

I have a wiki (1.8.1) running on an intranet at work. I am super user and have no problems editing, but when some other users try to make an edit to a page, the page gets deleted. I have to then go back to the page's revision history and revert to a former version to resurrect the page. Any ideas?

Which OS, fstype do you use on the server? Which browser do you and which do they use? super user has nothing to do with storing a page. It is more for suid or to access some special macros.

The wiki is hosted on Ubuntu 8.10 with ext3 FS. The clients are using Win2K with IE6.

Problem solved: It turns out it was down to 'user error'. On clicking 'Save Changes' some users showed a little impatience by clicking 'preview' or 'cancel' buttons before the web page had refreshed back to the normal read-only view. This seems to cause the save operation to fail and the page disappears from the wiki. It is possible to re-instate the page by reverting to the previous version.

Is this a known bug/feature/vulnerability?

No, not known yet. Please file a bug. Try to reproduce it with Firefox or some other browser. Give more information about your server installation. Remove this section here after filing the bug. -- ThomasWaldmann 2009-03-11 10:25:00

## Cannot see Python traceback

Installed version 1.8.4 recently. While doing some changes in sources I've came across the problem that I do not get any traceback in the browser window when there are errors in python code. Just see the empty page. How do I switch this on? (in 1.5.5 I think I saw the traceback with default config).

Tried adding traceback_show=1 to my wikiconfig.py and enabling os.environ['MOIN_DEBUG']='1' in moin.wsgi, but that didn't help.. -- AlexanderAgibalov 2009-06-25 13:23:26

## Locking errors after implementing maint reducewiki

We have a wikifarm using version 1.8.2 with a common underlay folder. On one wiki after using maint reduce wiki, and recreating the pages folder with the reduced set of pages everything works fine. I ignore copying underlay folder pages. On the other it is not possible to save an edited page (preview is OK) and the error Page could not get locked (errno=13) is returned. If I try to delete a page, the error is SaveError has occurred in PageEditor.deletePage. We need locking there I am sure it is me not doing something, but what ? -- GerardODriscoll 2009-08-25 11:52:19

Look into data/pages/PageName and compare it to some page not making trouble. -- ThomasWaldmann 2009-08-25 12:58:08

All pages have the same problem. It appears that the maint reduce wiki is a red herring, so maybe it is the way I am doing this. In my clean up of the pages I had renamed the pages folder as pages.old (for a backup), created a new pages folder, and then copied the relevant pages from the output of the maint reduce wiki. If I rename the pages folder as pages.old, create a new pages folder and copy the HomePage from the .old to pages, manually clear the cache, then open the wiki, I can view the Homepage, but any attempt to save an edited version results in Page could not get locked (errno=13). If I create a new page from the HomePage (there are unresolved links of course) then I can edit and save it. If I then delete the pages folder, and rename pages.old as pages everything is OK. Is there something wrong with the way I am doing this ? -- GerardODriscoll 2009-08-25 15:45:50

• Do you see a traceback, if so please attach it

No traceback on the error. I took this a stage further by
(i) Checked that wiki using the original pages folder opened the HomePage correctly, and that it was possible to edit and save. All works OK
(ii) Renamed the working set of pages as pages.old
(iii) Created a new pages folder, and copied all the contents of pages.old to pages. No. of files, no. of folders and sizes matched after the copy
(iv) Open the wiki, which immediately gave me the error in the attachment HomePage.htm.
(v) Manually cleared the HomePage/cache folder. This allowed me to open the wiki, but does not allow any edits to be saved. The same error is returned Page could not get locked (errno=13)

• Maybe a filesystem permissions issue?

Correct - A permission not propagated correctly. Thanks for the pointer, sorry for the trouble.

## Sometimes I get logged out for no reason

As the heading says some users of our project wiki get logged out sometimes. This happens e.g. if you switch from GUI mode to text mode and vice versa.

## Static Content gets truncated

I'm pretty close - I have MoinMoin running via Apache on Windows Server 2008. The only thing I'm having an issue with is all static content comes through missing the last 800 characters or so. Padding out the .js and .css files help deliver the relevant content, but that's not as easy with images. Any idea where to look? The dynamic content comes through OK, and I have a Django installation on the same server that is also working fine.

• That's rather unusual. How do you serve the static content? By moin builtin static server or via an apache "alias" definition? Can you try the opposite way and report about the results for that case?

## Stackless Python

Does MoinMoin Support Stackless Python explizit or are there any known issues? On MoinMoin 1.8.3 (Standalone Server) with Python 2.5.2 Stackless under Windows XP it works and I couldn't find in a short test any errors or traceback.

Python Version
2.5.2 Stackless 3.1b3 060516 (release25-maint:63825M, May 30 2008, 21:23:25) [MSC v.1310 32 bit (Intel)]

any feedbacks would be nice -- MarcelHäfner 2009-05-06 16:25:41

• Answering myself: Stackless should be 100% compatible for use of normal Python code. If you have Stackless installed and you use Python code which does not make any use of the Stackless functionality, that code should behave exactly the same as it would in a normal Python installation http://zope.stackless.com/wiki/FAQ

## MoinMoin with WSGI can't find datadir

I have set up moinmoin 1.8.2 with cgi successfully. My Config-Files, the moin.cgi, the data dir,.. are all in the folder /web/thiswiki/ . For cgi I used this apache config:

• Alias /moin_css/ "/usr/share/moin/htdocs/"
ScriptAlias /thiswiki      /web/thiswiki/moin.cgi

which worked. Now I installed and loaded the apache WSGI-Mod. I tried this apache-config:

• WSGIScriptAlias /thiswiki      /web/thiswiki/moin.wsgi
WSGIProcessGroup thiswiki
WSGIPassAuthorization On

WSGI is correctly loaded by apache. But If I wanna now access the wiki I'm always getting the error:

data_dir "data" does not exist, or has incorrect ownership or permissions.

Make sure the directory and the subdirectory "pages" are owned by the web server and are readable, writable and executable by the web server user and group.

It is recommended to use absolute paths and not relative paths. Check also the spelling of the directory name.

Error in your configuration file "/usr/lib/python2.5/site-packages/MoinMoin/config/multiconfig.py" around line 189

But the data folder has the correct permissions and the WSGI-processes have the correct owner www-data. Any idea what goes wrong here?

show us the line of moin.wsgi you changed to point to the path of your wikiconfig.py and also show us the data = line of that wikiconfig.py -- ReimarBauer 2009-04-15 11:36:38

Please also report the actual mode of the data directory (e.g. drwxr-xr-x), the owner (at least whether or not it is the web server agent). You can use 'bash> ls -l ...' on the data directory to learn its mode and owner. You can use 'bash> grep -E '(User|Group) ' /etc/apache*/*.conf to learn the web server agent user and group, 2009-05-09 23:23:12

drwxr----- and dependent on your configuration www-data.www-data as owner is mandatory. -- ReimarBauer 2009-05-10 06:31:35

I had this same issue. For me the relative paths that had worked didn't when using wsgi. I had to change the data_dir and data_underlay_dir in wikiconfig.py to use the absolute path as suggested. Hope this helps anyone looking for an answer to this question, as I was.

Possible Resolution (for Linux): I've found that MoinMoin using mod_wsgi will work after disabling SELinux or, at least, changing to the enforcement to "Permissive". I was getting this same error using mod_wsgi. I tried using moin.cgi, which generated different but informative error message. Based on that error, I decided to disable SELinux. Afterwards, moin.cgi and moin.wsgi worked perfectly. This is a workaround, as it disables additional security features in Linux -- (Someone can reword/reformat this to better fit the context. I just wanted to make sure others were able to resolve this issue in the future -- CMD)

The correct way would be:

• restorecon -FvR /path/to/your/wiki
• setsebool -P httpd_unified 1
• setsebool -P allow_httpd_anon_write 1

I completely can't avoid this error on Mac OS X Lion. Using CGI, I tried lots of different paths and directories for "data". Error still exists. Check it, please. Please join us on #moin chat.freenode.net, see MoinMoinChat if you don't have a client. Please prepare a pastebin with your config and verify that you modified the right. You get the config used in SystemInfo as superuser or in the server log.

## Desktop MoinMoin on USB memory stick accessible on Windows and Mac

Is it possible to run the same desktop wiki from the memory stick once on Windows XP PC and later on Mac and back? What I should do to be able to do so?

• You would need to have the python builds for both Mac OS X and Windows on the stick in different directories, then have two scripts that launch wikiserver.py with the respective python binaries. For example: root_of_stick:\winstart.cmd, root_of_stick/macstart.sh, root_of_stick:\python27_win\, root_of_stick\python27_mac\
winstart.cmd:
python27_win\python.exe wikiserver.py
macstart.sh:
python27_mac/python wikiserver.py

Then point your browser @ http://localhost:8080/ @sig@

## Configuring DocBook rendering

I've followed the instructions at HelpOnXmlPages, but cannot get the DocBook renderer to work. I'm running on a Windows Server 2003 box (IIS ver 6.0), and have MoinMoin 1.5.8, Python 2.5.1 and 4Suite-XML 1.0.2 installed. XSLT is enabled, everything according to the setup instructions.

However, when I click on 'Render as DocBook', I get the 'You need to install PyXML to use the DocBook formatter' error. Is there something I'm missing? I'm not a Python expert, so I'm struggling to trace the error and see whats going wrong. Any ideas?

Keith Fletcher, 2007-10-19

## Themes

I have the same trouble with bulleted lists as described above (no scheme is being shown). But I cannot find any reason or solution. I am running Suse Linux 10.1 as admin. Wiki itself is working fine.

My wiki is called DaCapo and stored at /wiki/DaCapo

My Apache-Entry:

Alias /wiki/ "/usr/share/moin/htdocs/"
ScriptAlias /DaCapo "/wiki/DaCapo/cgi-bin/moin.cgi"
<Location /DaCapo>
order deny,allow
deny from all
allow from localhost
allow from 192.168.1.254
AuthType Basic
satisfy any
</Location>

My setting to /wiki/DaCapo/cgi-bin/moin.cgi

sys.path.insert(0, '/usr/lib/python2.4/site-packages/ ')
sys.path.insert(0, '/wiki/DaCapo')

My wikiconfig.py entries:

logo_string = u'<img src="/wiki/DaCapo/DaCapo.png">'
data_dir = '/wiki/DaCapo/data/'
data_underlay_dir = '/wiki/DaCapo/underlay/'
url_prefix = '/wiki'

If I try http://localhost/wiki/modern/css/screen.css then I get "accedd denied".

Could anybody help me? Thank you very much, Matthias

Finally I found the error. To others having the same problem: Please check HelpOnInstalling/ApacheOnLinux at the end. The following worked fine within httpd.conf

Alias /wiki/ "/usr/share/moin/htdocs/"
<Directory "/usr/share/moin/htdocs/">
Order deny,allow
Allow from all
</Directory>

ScriptAlias /DaCapo "/wiki/DaCapo/cgi-bin/moin.cgi"
<Directory "/wiki/DaCapo/cgi-bin/">
Order deny,allow
Allow from all
</Directory>

## Install at provider

I have a personal homepage hosted at a provider. Updating is easy done by uploading the HTML and PHP code. I don't have access to /usr or similar directories. How do I install MoinMoin there ?

• -- Thomas 2007-03-04 15:21:01

Ok - i did a workaround: In installed moinmoin on my home-PC's home directory: /home/myname. It took some time to figure qout which files to edit and how. Finally I had a wiki running at http://localhost/:8000 using the moinmoin-internal server. Should be easy to transfer that to my home-directory at my provider - I thought. I copied all moinmoin directories from my local home directory to my provider. I then edited all config files as described for the cgi installation. Finally I ended with this error message:

• - 1 CGI returned nonzero status Traceback (most recent call last):
• File "/kunden/homepages/...morepathinfo.../cgi-bin/moin.cgi", line 44, in ?
• from MoinMoin.request import RequestCGI

ImportError: No module named MoinMoin.request STDOUT OK STDERR OK -- Thomas 2007-03-04 15:21:01

## Farm on the intranet

• I am working on setting up various wikis for different departments on the company intranet. I was able to get a single wiki working without much trouble. I am using standalone and I am having trouble setting up farmconfig.py correctly or I am incorrect in the way I think it will work. I have modifed my farmconfig.py wikis = [...

wikis = [
("ProductionDeveloper", r"^server/proddev/.*$"), ("ApplicationDeveloper", r"^server/appdev/.*$"),
]
• I am getting errors

Could not find a match for url: "server/FindPage".

Check your URL regular expressions in the "wikis" list in
"farmconfig.py".

and

Could not find a match for url: "server/proddev?action=edit".

Check your URL regular expressions in the "wikis" list in
"farmconfig.py".
• Am I configuring the wiki farm to only work on sub pages? Can I create a farm like above or do I have to have something like below:

wikis = [
("ProductionDeveloper", r"^proddev.server/.*$"), ("ApplicationDeveloper", r"^appdev.server/*$"),
]
• I apologize for posting 3 times. I wanted to try to convey my problem as clearly as possible. It appears that my regular expression is incorrect. I have modified it in many ways and I am not getting the desired results.

## Apache2: where to put the stuff that goes in httpd.conf

I tried following the readme to get MoinMoin to work, but it tells me to put some stuff into httpd.conf, which is the apache1 way of doing things. When I did it anyways, it didn't work. So, where in the apache2 config do I put this:

Alias /wiki "/usr/share/moin/htdocs/"
ScriptAlias /MyWiki "/var/www/moin/moin.cgi"

I think: /etc/apache2/sites-available/default

-- kamagurka 2006-08-24 09:24:20

• For IP-based hosting, try /etc/httpd/conf/vhosts/Vhosts.conf and for name-based, try /etc/httpd/conf/vhosts/nameBased/whatever.conf. Hope that helps.

To store user options there should be a file /etc/apache2/httpd.conf beside the file apache2.conf. You can then put the stuff in httpd.conf and it will be respected by apache after a restart of the Service /etc/init.d/apache2 restart

If this file is not present and is not respected after creation just put the lines in /etc/apache2/apache2.conf

A better way may be the use of a virtual host, so you get rid of the /mywiki/ addition to the URL. So it looks like http://example.com instead of http://example.com/mywiki

-- RalfMoerler 2008-05-16 07:07:30

## Enable RSS feed for RecentChanges

I have converted a Wiki from an ancient (pre 1.0) version to the latest one. It seems to work fine, but I don't get an RSS feed for the RecentChanges. Do I need to explicitly enable anything for this to work? -- twm 2013-06-19 04:56:23

The rss feed is only available if you use a recent version of python (2.5?), or if the pyXML package is installed. No additional configuration is required. -- twm

## No CSS on standalone wiki on lighttpd

I've followed the guide FastCGI to the letter, but I get no CSS while it still find the themes. How do I make the server find the htdocs directory?

• You need to add an alias like this in your lighttpd.conf
$HTTP["host"] == "localhost" { alias.url += ( "/wiki/" => "/the/path/to/htdocs/" ) } ## www.example.com/cgi-bin/moin.cgi/ vs. www.example.com/cgi-bin/moin.cgi When I view www.example.com/cgi-bin/moin.cgi/ in my Browser everything works fine. But when I omit the last slash (i.e. www.example.com/cgi-bin/moin.cgi) I don't start on my page_front_page and MoinMoin complains that the page cgi-bin/moin.cgi does not exist yet. What did I do wrong? What info do you need to help? Is it possible that there is an extra slash in the apache conf corresponding to the following line from HelpOnInstalling/ApacheOnLinux? ScriptAlias /mywiki /usr/local/share/moin/mywiki/cgi-bin/moin.cgi 2009-05-09 07:07:30 ## cgiwrap gives ugly URLs, can it be fixed? I am on a host that requires using cgiwrap so moin.cgi runs as my userid, saving the caches and pages so they can be edited by that same userid (I can't edit pages saved by the httpd user). My wiki URLs look like this: http://www.scons.org/cgi-sys/cgiwrap/scons/moin.cgi/FrontPage. I have no trouble using mod_rewrite in my .htaccess to rewrite /wiki/FrontPage to the above ugly URL, but the links in the wiki pages all still have that long ugly form (I guess moin.cgi is looking at its own URL and using that as the base for the links). Is there a way in the config file or by changing the code to have the wiki links use my /wiki/FooPage syntax? -- GaryOberbrunner Try editing your CGI script (moin.cgi) so that the properties in the Config class are as follows: properties = {'script_name': '/wiki/'} This should tell MoinMoin to use something else for constructing URLs. -- PaulBoddie ## Problems with permissions? (WinXP SP2, Apache2.2.2, Moin1.5.3) I've just installed the latest version of Moin-1.5.3 on a WinXP machine (SP2) running a fresh installation of Apache2.2.2. I appear to be getting the following problem reported in Apache's error.log file: [error] [client 140.79.20.85] client denied by server configuration: C:/Server/Moin/mywiki/moin.cgi When checking moin.cgi (by saving as test_moin.py and running in Python IDE) the following error results: Traceback (most recent call last): File "C:\Program Files\Python24\Lib\site-packages\MoinMoin\request.py", line 1372, in __init__ msvcrt.setmode(sys.stdin.fileno(), os.O_BINARY) IOError: [Errno 9] Bad file descriptor Just wondering if anyone has come across this error before, it appears that there might be a permissions clash, however the installation/setup.py has ensured that all created directories are read-only. I've attempted to change these, however they return to read-only after the change is "complete" - what Moin directories/files specifically require read/write access? I've also checked all paths etc and everything looks about right to me... can someone help here? I do think this is mainly caused by your apache configuration. Have you read http://www.raditha.com/blog/archives/000896.html. Please provide your apache config file if this does not help. -- MichaelRau 2006-05-04 18:10:42 Thanks Michael, from your link below it appears that the configuration file (httpd.conf) of the Apache 2.2 (2.2.2) install might be the problem here... You've indicated that the additional security in this updated release might be the conflict (which causes the document root for the virtual host to become inaccessible)... Can you clarify your resolution for me however... you suggest commenting out the access configuration stuff (what exactly are you referring too here?), or a better solution, to add "Order deny,allow Deny from all" to the virtual host block... Sorry to be a dum dum here, but can you explicitly outline what you suggest here? I am able to browse the default file in the htdocs directory, just not the (mywiki) sub directory... -- Thanks Paul 2006-05-04 07:30:56 I have not seen your httpd.conf file (read http://httpd.apache.org/docs/2.0/configuring.html). But I think, that the order directive is wrong (read http://httpd.apache.org/docs/2.2/mod/mod_authz_host.html#order). Here are the important directives in my httpd.conf file. AddHandler cgi-script .py <Directory "%root%/home"> Options Indexes FollowSymLinks AllowOverride All Order allow,deny Allow from all </Directory> # ============================================================================== # MoinMoin wiki # ============================================================================== Alias /wiki/ "%root%/Python24/share/moin/htdocs/" ScriptAlias /emnosWiki "%root%/home/Moin/emnosWiki/moin.cgi" <Directory "%root%/home/Moin/emnosWiki/"> AllowOverride All Allow From All Options +ExecCGI </Directory> -- MichaelRau 2006-05-04 21:32:41 It appears after completing the suggestions above to the Apache conf file, the error is now a (500 Internal Server error) with the error log indicating: [error] [client 140.79.20.85] (OS 2)The system cannot find the file specified. : couldn't create child process: 720002: moin.cgi [error] [client 140.79.20.85] (OS 2)The system cannot find the file specified. : couldn't spawn child process: C:/Server/Moin/mywiki/moin.cgi Any more suggestions? I think/hope it's getting closer... -- Paul 2006-05-08 03:30:56 Thanks for the clarification here Michael, it was indeed my shebang statement in the moin.cgi file. As Python sets itself in the system path during install "#!python" does indeed work. I've now managed to hit another "permissions" error, this time the Apache error.log file reports: [error] [client 140.79.20.85] client denied by server configuration: C:/Program Files/Python24/share/moin/htdocs/common/js/common.js, referer: http://bs4x51s-hf/mywiki/ [error] [client 140.79.20.85] client denied by server configuration: C:/Program Files/Python24/share/moin/htdocs/modern/css/common.css, referer: http://bs4x51s-hf/mywiki/ [error] [client 140.79.20.85] client denied by server configuration: C:/Program Files/Python24/share/moin/htdocs/modern/css/screen.css, referer: http://bs4x51s-hf/mywiki/ [error] [client 140.79.20.85] client denied by server configuration: C:/Program Files/Python24/share/moin/htdocs/modern/css/print.css, referer: http://bs4x51s-hf/mywiki/ [error] [client 140.79.20.85] client denied by server configuration: C:/Program Files/Python24/share/moin/htdocs/modern/css/projection.css, referer: http://bs4x51s-hf/mywiki/ [error] [client 140.79.20.85] client denied by server configuration: C:/Program Files/Python24/share/moin/htdocs/common/moinmoin.png, referer: http://bs4x51s-hf/mywiki/ [error] [client 140.79.20.85] sys:1: DeprecationWarning: Non-ASCII character '\\xfc' in file C:/Server/Moin/mywiki/moin.cgi on line 10, but no encoding declared; see http://www.python.org/peps/pep-0263.html for details\r The default wiki page is viewable, however the stylesheets and icons are not accessible, and consequently, the page looks a little more chaotic than it should... Michael I've made incorrect assumptions before, so (instead of guessing) I'm wondering if you can shed some light on this error, and possibly help me on the way to a shiny new fully-functioning wiki 1.5.3 -- Paul 2006-05-09 23:47:41 Maybe I'm starting to learn something here... Additional to the Moin directory C:/Server/Moin/mywiki the htdocs dir C:/Program Files/Python24/share/moin/htdocs/ also needs it's directives changed (like below, appended to the end of the httpd.conf file): # MoinMoin installation 13.21 9/5/2006 # Following values appended to the default Apache httpd.conf file Alias /wiki/ "C:/Program Files/Python24/share/moin/htdocs/" ScriptAlias /mywiki "C:/Server/Moin/mywiki/moin.cgi" <Directory "C:/Server/Moin/mywiki/"> AllowOverride All Allow From All Options +ExecCGI </Directory> <Directory "C:/Program Files/Python24/share/moin/htdocs/"> AllowOverride All Allow From All Options +ExecCGI </Directory> Mike, are there any dramas with giving this level of access to both directories? Thanks for all your assistance -- Paul 2006-05-09 03:25:41 ## Upgrade from Desktop edition to standard edition with Apache and retain URLs Running Desktop edition (with Python installed) for a year. Love it. Want to upgrade to Apache for improved performance. (Vanilla CGI will be plenty; don't need mod_python or fastcgi.) However, following the standard instructions to install MoinMoin under Apache results in different URLs for all the pages, which would break all bookmarks. Desktop edition looks as though the server is dedicated to that application, at least on the chosen port. So goes directly to FrontPage, as desired. And a typical page in the wiki is at When I install under Apache, I seem to need to identify the name of the wiki in the URL all the time. (I've done this as an experiment, not yet on the live system.) So now goes to the Apache webroot/index.html rather than to the wiki. To get to the front page of the wiki, I need and internal pages are like That is, the "mywiki/" element needs to appear in every URL. Lots of users have stored bookmarks without the wikiname in them, and I would like not to break them all. How do I setup Aliases or VirtualHosts or whatever in Apache to get the same behavior as the old Desktop edition? Help, please. Thanks in advance. -- RickLandau 2007-05-11 13:35:33 Use a virtual host on apache, so you get rid of the appendix to the URL. I read in some places that using mod_rewrite and .htaccess is the solution but the apache site recommends using virtual hosts instead of .htaccess rewrites because this causes additional server usage by querying the directories for the .htaccess files. Here's a sample that works for me on our Intranet. (Replace the <variables> with your values) NameVirtualHost <IP-Adress>:<Port> <VirtualHost <IP-Adress>:<Port>> ServerName <mysystem.example.com> ServerAdmin <YourMailAdressHere> Alias /wiki /usr/share/moin/htdocs ScriptAlias / </your/wiki/cgi-bin/>moin.cgi/ ErrorLog </var/log/apache2/wiki_error.log> LogLevel warn CustomLog </var/log/apache2/wiki_access.log combined> ServerSignature On </VirtualHost> Also take a look at the http://httpd.apache.org/docs/ Apache documentation for your Version. -- RalfMoerler 2008-05-16 07:07:30 ## Desktop Wiki on a Memory Stick Is it advisable to store the whole installation directory of the Desktop Edition on a memory stick? I would like to have it portable and since those sticks are now large enough, that sounds like a good idea. But what about writing cycles? Can I/should I maybe disable caching? • yes, you could put DE on a stick, works fine. Do you speak on caching for the wiki or for the stick? -- ReimarBauer 2006-01-08 13:59:22 • Caching for the wiki. I was thinking about limiting the storage space required. Since I don't know how moinmoin works, I am concerned about the limited number of writing cycles of those media. It might write something to the same area of the stick over and over again and killing it within a few weeks by doing that. btw. better you add next time questions at the end of this text. -- ReimarBauer 2006-01-08 13:59:22 • I thought adding it in front was what was expected since it says "Add your new questions here" there. I have just added "(at the end)" ## AMD64 Version? Is there a version of MoinMoin which will run on an AMD64 computer running Fedora Core 4? Thanks! • Do you mean that you're looking for an RPM? Otherwise, try installing the tarball using the instructions on this site. For "standalone" mode, it's fairly easy on any OS including Linux. -- TomPurl 2013-06-19 04:56:23 Thanks! I've got it up and running. I was pretty sure that it would work, but I'm really short of time and thought that I had better be proactive in posting a question. ## Another way for Root Wiki? I use mod python and the following Apache setup allow me to do root wiki without moinmodpy RewriteEngine On RewriteLogLevel 0 RewriteRule ^/robots.txt - [last] RewriteRule ^/wiki/ - [last] RewriteRule ^/images/ - [last] RewriteRule ^/cgi-bin/ - [last] # User Dir RewriteRule ^/~(.*) - [last] # Root Wiki RewriteRule ^/?(.*) /mywiki/$1      [last]

<Files mywiki>
# Use mod_python as handler
SetHandler python-program

# set the path to the MoinMoin package and to the moin_config.py
#  PythonPath "['/path/to/moin/lib/python','/path/to/moin/config']+sys.path"
PythonPath "['/var/www/localhost/mywiki']+sys.path"

# choose the ModPy Request class as handler
PythonHandler MoinMoin.request::RequestModPy.run
</Files>

It seems to work fine for me now. Is there any problem or limitation with using this method?

• What do you mean by "without moinmodpy"?

## Cannot get themes to work

My default install of MoinMoin has no theme. Everything that would normally be in a sidebar or along the top just appears as plain-looking text. Menu items are in a bulleted list. My install must be screwed up somehow (file locations or permissions) but so far I've not been able to find the problem.

Some details:

• Running SuSE linux version 9 on an x86
• Installed MoinMoin to the directory /srv/www/MoinMoin

• moin.cgi contains the following paths:
• sys.path.insert(0, '/srv/www/MoinMoin/lib/python2.3/site-packages')
• My user profile page lists the three standard themes (classic, modern, and rightsidebar) but no matter which one I choose things still look ugly.
• All the features seem to work fine, just the formatting is messed up.

Can someone offer suggestions on how to troubleshoot this?

Thanks! --SteveDavison

Obviously your /wiki (?) url_prefix doesn't work or your apache alias configuration doesn't match the moin url_prefix configuration. You can try this without moin by accessing http://server/wiki/modern/css/screen.css (it should show some css source code in that case). -- ThomasWaldmann 2006-01-19 08:34:00

• --> Solution:
Went through all the installation instructions again... I had missed the step to set up an alias in Apache that points to the moin htdocs... Once I added this, everything worked beautifully. (I think in this case, "/srv/www/MoinMoin/" is what is referred to as my MoinMoin "prefix"?)

• Alias /wiki/ /srv/www/MoinMoin/share/moin/htdocs/

## Problems starting moin (initial install)

Q1. I am trying to create a standalone moinmoin wiki on a linode running debian and apache. I have python 2.3 and 2.4. I am using 2.4 for this installation.

I installed to /var/www/moin_python2.4/ in /var/www/moin_python2.4/ the folders are bin, lib, share, test_wiki.

In /var/www/moin_python2.4/share/moin/config/ there is a wikiconfig.py file and also in /var/www/moin_python2.4/share/moin/test_wiki there is a wikiconfig.py file.

I am not sure which I should modify and i am supposed to move the moin.py to the place where wikiconfig.py is but there are two wikiconfig.py locations so which should I move it to? Where should I copy the moin.py file from and what changes to I need to make to it? Also do I need to save it to /usr/bin/env or somewhere?

Q2. I am trying to create a standalone moinmoin wiki on a linux machine running debian. Following the instructions on http://wiki.debian.org/HelpOnInstalling/BasicInstallation, i did a 'python setup.py install --prefix=$HOME/PersonalWiki/MoinMoin'. Then I followed the instructions here to create an instance of the wiki. Then I followed the instruction here on copying moin.py to this directory and inserting the required paths. When I run moin.py I get the following Usage: moin [command] [general options] command subcommand [specific options] ... FATAL ERROR: You must specify a command module and name: ... • Then I tried running 'python moin.py server standalone'. It gives .... File "/home/ganesh/PersonalWiki/MoinMoin/lib/python2.5/site-packages/MoinMoin/server/__init__.py", line 70, in __init__ . "setting and permissions." % self.docs) RuntimeError: Can't access docs directory '/usr/share/moin/htdocs'. Check docs setting and permissions. I tried changing the Defaults in the Config class, it wouldn't work ! A: If you want a standalone wiki, just download the current MoinMoin release, uncompress it, run ./wikiserver.py and you're done. ## Changing the URL I am using the standalone setup and I want the entire wiki to have a base url, eg http://my.machine.net/foo/FrontPage rather then the current http://my.machine.net/FrontPage. Is this possible? If so, how? A: I did it by editing the 'wikiconfig.py' file and the 'httpd.conf' files to point to the new url I wanted, then I manually used the rename function to move the pages over. I guess that would only be of help if there are not too many pages! I do, however, believe that renaming pages can be done as a batch process - but I've never attempted it. ## Updating from 1.0 to 1.3.5/1.5.0 We are running a MoinMoin-Wiki at Version 1.0. Now we plan to upgrade the Wiki to the current release, but I've noticed some basic changes (pathes, encoding). Is there an existing script for migrating old data to the new format? • Get the archive of the new version you want to use (e.g. latest release), read docs/CHANGES starting from the version you use. You will find a pointer to README.migration which answers your question. ## After installing 1.5.1 over 1.5.0 the subscription is gone There is no menu entry for "subscription" and also the subscribed pages from the UserPreferences are gone. I did just an "emerge =moinmoin-1.5.1 && /etc/init.d/apache2 reload". Any hint? -- -- TobiasPolzin 2006-01-30 20:17:40 • Is mail right configured, do check if mail_from in your configuration wikiconfig.py is right used -- ReimarBauer 2006-01-30 20:27:10 • Thanks! Yes, Moinmoin 1.5.0 did not care, but 1.5.1 does. -- TobiasPolzin 2006-01-30 21:07:48 ## How to install a moinmoin wiki farm (No, the existing documentation doesn't help.) Q: I am not sure I completely understand the technical concept and working of a wikifarm (though I know I would like to have one Is the main idea to have different URL aliases always pointing to/executing .../myfarm/moin.cgi which then invokes farmconfig.py to match the url and execute specific wiki configuration? A: Exactly. Q: I've got the basic part working: every request like '.../myfarm/wikiOne/FrontPage' maps to .../myfarm/moin.cgi which invokes farmconfig.py, matches the url against regular expressions and loads the FrontPage from the correct data directory (different title pages, easy to recognise for testing). Then I have a problem: all the system generated links (such as RecentChanges or Edit(Text), etc) displayed on the FrontPage point to .../myfarm/moin.cgi/some_page (like .../myfarm/moin.cgi/RecentChanges). The 'wikiOne' - wiki name in the url - is missing. What have I missed in configuring the farm? I am doing this on IIS and if I make it work, I will describe the procedure here in more detail. A: Your initial assumption is wrong. For each member of your farm, you need to point to its own moin.cgi (however they will all be identical), i.e. '.../myfarm/wikiOne/FrontPage' maps to .../myfarm/wikiOne/moin.cgi. Then use entries like • ("wikione", r".*wikiOne.*$"),

in jour wiki list in farmconfig.py and put individual config in wikione.py etc.

Here's how to do it on IIS:

• create virtual directory wikiOne with:
• local path something like D:\WEBServer\Homepage\moin\wikione
• define application wikiOne with
• extension .cgi, executable "D:\Python23\python.exe" -u %s %s, check "script engine" only

• exec permission "script only"
• enable default document and put "Default.htm" to the top position, do not have moin.cgi in the list
• enable anonymous access for user IUSR_<name_of_server>

• reset "Custom Errors" message type 404 to "Default"
• restart IIS
• test it with http:/your_server/wikiOne/moi.cgi

Do not bother to remove the moin.cgi from URLs - there are ways to do this partially with some redirection and patches but none of them will be satisfactory - you will always end up with the long URL in the end. If you don't want that, use Apache.

## How to move a wiki instance from one machine to another

Install moin as described in the help. When the help tell you to copy the data directory from /usr/share/moin/, copy instead the data directory from your wiki directory on the other machine. Copy also your config files and update the paths if needed.

## Installation via FTP

Is there a way to have Moin installed on a server that you don't have shell access to, and you can't change any Python files?

## IIS questions

### Python Path

I cannot get python to recognize Moin. I have edited the moin.cgi under the instance and added sys.path.insert (0, c:\moin\lib\site-packages') but it does not seem to help. If I try the python import test, I get the error. Any help would be appreciated.....I am running windows 2003 sp1

### IIS6 and 403 Forbidden error

I just installed Moin 1.3.4 on an Windows 2k3 server running IIS6. I installed Python 2.3.5. When I try to access my new wiki, I get "error 403 Forbidden...not authorized".

### Performance

CGI gate is quite slow. There is an MoinMoin ISAPI to invoke wiki from under IIS. And its quite easier to config than CGI gate. Note that this is only tested through version 1.3.5 of Moin. Later releases are said to have issues with the ISAPI.

### General setup

Q: I am getting the error "The specified CGI application misbehaved by not returning a complete set of HTTP headers." There is a note below regarding Python versions, but my versions match the install instructions so I don't think that's it. I'm using Win2k3 Server, IIS, Python 2.3.2, Moin 1.2.2.

Also, when I try to add the Application Extension Mapping, I append the -u %s %s to the executable line, but the dialog complains unless I enclose them in quotes. Could this be the problem? My executable line looks like this:

c:\python23\python.exe -u "%s" "%s"

A:In addition for Windows installations there are two levels of security permission checking - one at the IIS level and other at the file system level. So make sure that

1. You have enable write permissions on your xyzwiki virtual directory in the IIS admin tool (off by default in IIS 6.0).
2. You enable anonymous access in the directory security tab (Anonymous access and authentication control -> Edit)

3. You give write permissions to the Anonymous internet user (IUSR_YOURMACHINENAME) for the xyzwiki folder on your filesystem (right click -> sharing and security -> Add user and give the above user write permissions as well)

A: I had this problem.To get it working I did the following:

• The executable line I use (which works) looks like this:

"C:\python23\python.exe" -u %s %s
• The moin installation wasn't correctly included on my PythonPath. To see if this is a problem try running the following:

> C:\python23\python.exe
>>> import MoinMoin

If that raises an exception, you need to check the PythonPath is correctly configured. It worked after I ensured C:\moin\Lib\site-packages was on the PythonPath. PYTHONPATH is a key in the System Environment Variables found by right-clicking My Computer and going to the advanced tab.

A: The same CGI error occures if you forget to set the path to wikiconfig.py in moin.cgi. I did.

A: This CGI error can also occur on a IIS-based Moin installation when the IIS engine somehow loses the ability to spawn Python CGI processes correctly. Watch the Task Manager for python processes as you quickly refresh the Wiki. If IIS is spawning the process correctly, you should see a python process appear for each successive page request. If it is not, you will see IIS attempt to double the memory for an existing python process and then return the "misbehaved" error. To fix this, reboot the machine--a simple iisreset does not seem to help.

Q: I have tried all the above suggestions. It still does not work. I am trying to install on IIS 6.0 windows server 2003, python 2.5.1, moinmoin 1.6.1. I followed all the instructions carefully. I have given all the permissions in the answers above also. I tried the above suggestion_ IIS is correctly spawning python cgi processes as I can see python processes as i refresh the browser. I don't know what's wrong. But, I had this message "Environment variables in file names will not be expanded" when I tried to create python cgi the web service extensions on IIS with the following values_

extension name : python cgi Files required: D:\python25\python.exe -u "%s" "%s"

Can this be the problem cause?

A: I resolved this CGI error on Windows Server 2003 by changing the line

logging.info("logging initialized")

in moin\Lib\site-packages\MoinMoin\server\__init__.py in moin 1.6.1. This line caused the line "logging initialized" to be printed before any header information and thus causing the above error message. I changed the line to

#logging.info("logging initialized")

and got my first wiki page served.

A: I (foxhop) also had this error after editing the wikiconfig.py file. It seems I pasted in some bad text that corrupted the file. After deleting the text the error went away...

### Removing moin.cgi from the address

I've installed MoinMoin on an IIS server and notice that it seems necessary to always specify /moin.cgi/ in the URL to get it to work, whereas on this wiki and some others, I don't see that. Is there a configuration setting to get IIS to work this way, too?

That question is quite IIS specific. You should ask people that know more about IIS in order to get an answer. I am sure that IIS allows such aliases.

Could you tell me how it's done on any other server and maybe that'll be the clue I need to know what to search for to figure it out?

In Apache for example, you have to set two Aliases: one that maps /wiki to the static htdocs files and another one too map / to the CGI file of MoinMoin. See HelpOnInstalling about this. Feel free to enhance the documentation after you found out how it works.

A: This is easy in IIS... edit the properties on your virtual directory and go to the documents tab. Put "moin.cgi" in the list of documents and move it to the top. That's it.

• - no, this does not work (Windows Server 2003, IIS 6.0)

## 404 error

So my new moinmoin installation shows the initial page beautifully but won't show any non-existing pages. MyStartPage, and any new page I edit in (edit works) just take me to a 404 error when I click on them. Any ideas? I've set R/W access to the virtual directory, and to the /data and /underlay folders, and I've given everyone full access to those directories through Windows. Any ideas?

I got the same problem, is there a chance to solve it? Installed on IIS, Virtual Directory has r/w, and everybode has full access to the moin folder. So how to fix this? Everything works, but I can't create pages, because they are "not" found. I had the error, that to page at all (only "moin.cgi") had been found, this could be fixed by unchecking the option "check for existence of files" (or similiar, translated be me into English) in the IIS.

## 500 error

Messing with the sandbox on my server - whenever I try and edit a page and save it, i get a 500 internal server error. When I refresh the pages, the changes have been saved, but i can't alleviate the issue. Why is this happening?

### Solution

I ran into this also and found the problem was no permissions to edit <mywiki>/data/edit-log. I think this happens if you add IUSR_<computername> to the data folder permissions after you've already edited a page once. I simple removed the edit-log file and let MoinMoin recreate it and all was good. There were error messages complaining about this in the error-log file. --DavidAvraamides

## Configuring a wiki at http://example.com/foo/bar/wiki with mod_python

I configured my wiki at http://example.com/foo/bar/wiki using Apache and mod_python. When I access /foo/bar/wiki/FrontPage moin try to access page bar/wiki/FrontPage, instead of accessing page FrontPage.

### Solution

This is a limitation of mod_python. MoinMoinBugs/ModPyWikiOnlyOneDirDeep explains the problem and contains a patch to make this possible.

## Quota exceeded on Linux ISP while installing - can I remove unwanted languages?

I'm installing on a Linux ISP with Python, CGI, Apache, no admin access. I started as described on HelpOnInstalling/BasicInstallation by downloading, ensuring I had Python, unzipping into a temporary directory, and calling setup.py.

Unfortunately, setup.py provokes an 'out of quota' error from my ISP's system. This appears to happen while copying the pages in wiki/underlay/pages, and is either because I've hit the ISP's limit of 12000 files (I already have lots of other files there), or because I've hit the limit on total size allowed. Is there a quick way to delete languages I don't need, because there are lots of language-variant pages. Removing them will probably solve my problem, but I don't want to have to delete them one at a time by hand.

Also on storage, how much of setup.py is just copying files from a subdirectory where Moin was downloaded to its final location? If I could replace this by moves, it would avoid having two copies of the directories being copied, which would also help my storage.

## Processing HTML

I can not seem to get the latest version of MoinMoin configured correctly to process html. After a clean installation of MoinMoin what steps do I need to take to set up processing of HTML?

• What do you mean by processing it?
• I to am having this problem. With 1.5.1 I attempt to place the #!format htmldirective at the top of a page and then I place the raw HTML. I expect moinmoin to render the page as HTML as per instructions I saw somewhere but nothing happens. There is mention that the HTML parser is not considered secure and has to be "turned on", but I see no mention of how to do that.

Where did you have read this?

you have at first to copy the html.py from ParserMarket into your local wiki data/plugin/parser dir. Then there are two methods to use it one is to use the pragma #format html and the other to use a pasrser call { { {#!html} } } -- ReimarBauer 2006-02-03 21:13:19

## setup.py and moin.cgi

I'm trying to install moin-desktop-1.3.4-2.exe and Python-2.3.4.exe. When running python setup.py install, I found there is no setup.py. I can't find also any moin.cgi file.

• moin-desktop works without installing Python and without running setup.py. That's the whole point of this distribution.

## How to Upgrade from 1.3.5 to 1.5.0

The 1.5.0 docs/README.migration files says to just read CHANGES. But docs/CHANGES does not give instructions under the 1.5.0 heading.

HelpOnUpdating describes the updating process.

## Installing on Fedora: permission denied & SELinux

When following the install instructions HelpOnInstalling/ApacheOnLinux I get following error:

Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator,  root@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.
Apache/2.0.54 (Fedora) Server at localhost Port 80

### Solution

This error is the result of SELinux (Security Enhanced Linux) target policy. To disable SELinux on http requests in Fedora Core (4) click System Settings -> Security Level and on the SELinux tab check the Disable SELinux protection for httpd deamon checkbox in HTTPD service section. This is not the perfect solution and if you care of security you should tweak SELinux file permissions properly. This page describes SELinux and its Apache policies in Fedora.

Q: I am getting the error "The specified CGI application misbehaved by not returning a complete set of HTTP headers." There is a note below regarding Python versions, but my versions match the install instructions so I don't think that's it. I'm using Win2k3 Server, IIS, Python 2.5, Moin 1.5.5a.

Also, when I try to add the Application Extension Mapping, I append the -u %s %s to the executable line, but the dialog complains unless I enclose them in quotes. Could this be the problem?

## Installing moinmoin on hosted webserver

Q: My server company says they have version 2.4.3 of Python running, but when I run the pythontest.cgi script provided on this wiki, nothing comes up for python. What gives? Should I go ahead and try installing the wiki?

A: First make sure that you have execute permission enabled on pythontest.cgi. I had the same problem until I realized I (as file owner) could read and write the file, but not execute it. You might have the same problem with moin.cgi.

## Installing moinmoin

Q:In a wikifarm installation I am getting: "Configuration Error: data_dir "/usr/local/share/moin/wikifarm/wikis/linuxwiki/data" does not exist, or has incorrect ownerships or permissions. Howevwer, the permissions are correct and set to nobody (The Apache user) and read write execute. The directory does exist but is empty. I use the absolute path in the config file.

## Import Error

Q:I followed the instructions on how to install and configure MoinMoin, but when testing the wiki, the server barfs with the following message:

[Tue Dec 19 15:45:33 2006] [error] [client 127.0.0.1] Premature end of script headers: /usr/local/share/moin/mywiki/moin.cgi Traceback (most recent call last):

• File "/usr/local/share/moin/mywiki/moin.cgi", line 39, in ?
• from MoinMoin.request import RequestCGI

ImportError: No module named MoinMoin.request

I found the MoinMoin module in the tar distro, but nowhere under the installation directory (/usr/local). Where should the MoinMoin module go?

A: Try installing Python with the developer headers. I've had the same problem and reinstalled Python with the developer headers, after this the import error was gone. You might check if an installer.log exist when you install MoinMoin with the installerlog option. If not, the setup might not have run correctly, ergo Moin will not work.

Q: After installing MoinMoin over FTP and a minor problem with css, the wiki finally runs, but all links on the main page dont work since they reference moin.cgi : e.g. http://www.myserver.de/cgi-bin/moin.cgi/SystemPagesSetup I get that this might have something to do with apache aliases, but thats something I cant configure since its a hosted server. Is there anyway to solve this ? (MoinMoin is 1.5.6 and Python 2.3.4)

## Problem when installing on Windows XP with Apache 2.2.4 and Python 2.5

I have both Apache and Python installed and running, and installed MoinMoin as explained in the install.html. Still, I keep getting a "403 - Access denied". I can not even run the diagnosis (...=?action=test)

I have edited the moin.cgi and httpd.conf as indicated.

The error.log of Apache shows "[client 127.0.0.1] client denied by server configuration: C:/moin/mywiki/moin.cgi". If I run Python and do "import moinmoin" it tells me no such module exists. What am I missing?

A: Don't know about the importing part but I solved similar error (same Python and Apache version) by adding access rights for the Wiki installation folders in the httpd.conf file:

...
#
# "C:/Program Files/Apache Software Foundation/Apache2.2/cgi-bin" should be changed to
# CGI directory exists, if you have that configured.
#
<Directory "C:/Program Files/Apache Software Foundation/Apache2.2/cgi-bin">
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>

# MoinMoin directory access
<Directory "C:/Python25/share/moin/htdocs/">
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>
<Directory "C:/Moin/mywiki/">
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>
...

## Need dictionary file

Q: I'm trying to get the spell checking to work on my OSX install of MoinMoin. However, It appears that I need a dictionary file, as it wasn't installed with the OS (AFAIK). Any idea where one is available? There is reference to one on the page HelpOnSpellCheck, but the link is no longer valid.

A: Look at /usr/share/dict/words. Moin simply needs a plain text file containing a list of words to check against. If you don't find the file on your system, you can try to search the internet by "Wordlist YourLang" and you'll find things like this: http://www.sil.org/linguistics/wordlists/english/. Simply put the file in your wikiinstance/data/dict dir. This should work. Or just look into the contrib/ directory of the moin download archive.

## Going crazy trying to upgrade

Hello, I tried to upgrade from 1.5.3 to the current version (was 1.5.7, now is 1.5.8), so I tried to upgrade from 1.5.3 to 1.5.4, 1.5.4 to 1.5.5, etc. I never achieved the first upgrade, so I gave up.
Since then, I reinstall another 1.5.3 MoinMoin Wiki to

1. have a clone of the first one which handle our internal documentation (i use rsync for this purpose)
2. try the upgrades on this clone

So, now I have a little time, I just retry the migration on my clone Wiki and another time it fail!

Bur it seems that the steps are :

1. use the migration scripts to convert data
2. install the new version following the INSTALL.html guide
3. do the "post 1.5.3 new style migration"

Ok, so for the migration scripts, I can't understand if I need some to migrate from 1.5.3 to 1.5.4, so as in my /usr/lib/python2.4/site-packages/MoinMoin/script/migration I found 1050300.py 1050301.py and 1050400.py, I ran each.

I then install the 1.5.4 version following the guide. I run through the "Basic Installation" and "Wiki Instance Creation".

For the "post 1.5.3 new style migration", I swith to my www-data user, and invoke

moin --config-dir=/opt/wiki-instances/wikiname --wiki-url=wiki.domain.tld migration data

and I have an error everytime

MoinMoin.error.ConfigurationError:
data_dir "../data" does not exists, or has incorrect ownership or
permissions.

In my wikiconfig.py, I have

data_dir = '../data/'
data_underlay_dir = '../underlay/'

(I'm under Debian, and after the installation, it was the only way to have MoinMoin running)

What can I do?
Is my migration method correct?
Can anyone help me?

-- EricVeirasGalisson 2007-06-04 15:17:16

• Using relative pathes is asking for trouble. And you obviously got trouble.

Ok, I put some absolute paths in my wikiconfig.py and got

Calling migration script for /opt/wiki-instances/wikiname/data, base revision 1050400
Final mig script reached, migration is complete.

I think my migration is complete now, and I can do the same for the following versions. But, does it means that the migration scripts are called by the moin executable or do I need to call them before ? Thanks -- EricVeirasGalisson 2007-06-05 08:28:24

• The pre-1.5.3 mig scripts are called manually (and you also have to remember / determine) which you have already run before and which not. Don't run them twice. The post-1.5.3 mig scripts are called automatically by just using the "moin" command (see README.migration). It will automatically determine the script to start with, depending on some version metadata in your data_dir, and run all scripts needed to upgrade to the current version - unless otherwise noted.

• Hum... the problem is: the README.migration is not very clear (reverse order and so on...), so does it mean that if I'm running a version >= 1.5.3, I don't need to run any migration scripts manually?
So, in this case, the migration procedure is

• install the new version following the INSTALL.html guide
• do the "post 1.5.3 new style migration"
• isn't it?

## error: package directory 'MoinMoin' does not exist

Q: I installed Python (Python 2.5.1) on a win2k system. I downloaded MoinMoi version 1.5.8 and untarred it. When I run the folowing command in the command prompt

C:\Moin\moin-1.5.8\setup.py --quiet install --prefix="C:\moin" --record=install.log

I get the following error:

error: package directory 'MoinMoin' does not exist

Any feedback would be appreciated

A: To answer my own question: Navigate to the script directory (c:\moin\moin-1.5.8\ in this case) before executing the script.

## Embed external non-wiki page

Q: Is it possible somehow to embed an external (non-wiki)page into a MoinMoin page? We have a process monitoring application running with a user interface through JSP. It would be handy if we could embed it in the wiki pages. Maybe in some kind of frame?

A. You could find a way to insert an IFrame somewhere in their. An IFrame lets you embed a webpage within a webpage from a different domain or not. IFrames, unlike Frames, if my memory is correct, lets you embed the a webpage using a kind of html box; kind of like those used for images. You will probably need to make sure the xhtml supports it; this usually means using transitional xhtml instead of strict xhtml for strict xhtml does not accept IFrames. Use your favorite search engine for the details of this. -Nick L.

## Problems installing (Windows XP SP2, Apache 2.2.2, Python 2.5.1)

I'm attempting to upgrade an existing Wiki (Apache 2.2.2, Python 2.4.3, Moin 1.5.4) an in the process also updating Python to the latest release (2.5.1). I removed the previous Python installation and upgraded to 2.5.1 (which now sits in C:/Program Files/Python25) and then proceeded to install the latest release of Moin 1.5.8. Installation appeared to work fine, and I have adjusted the shebang and path-dependent info in moin.cgi, as well as path dependent info in http.conf. When called locally on the commandline, moin.cgi works without reporting any errors, however when I try and call this locally through a browser, I receive the following error:

[Thu Sep 13 11:48:26 2007] [error] [client 127.0.0.1] (OS 2)The system cannot find the file specified.  : couldn't create child process: 720002: moin.cgi
[Thu Sep 13 11:48:26 2007] [error] [client 127.0.0.1] (OS 2)The system cannot find the file specified.  : couldn't spawn child process: C:/Server/Moin/mywiki/moin.cgi

I've attempted to include changes to the directory access rights, as specified in the post above (Problem when installing on Windows XP with Apache 2.2.4 and Python 2.5) however this doesn't appear to have solved the problem..

Does anyone have any tips for me here?

-- Thanks Paul 2007-09-13 11:53:03

• I have just installed the latest version of Moin-1.5.8 on a WinXP machine (SP2) running a fresh installation of Apache2.2. I appear to be getting a problem with permissions. I had the following problem reported in Apache's error.log file, although I followed the same steps as in http://moinmoin.wikiwikiweb.de/HelpOnInstalling/ApacheOnWin32

[error] [client 127.0.0.1] client denied by server configuration: C:/Moin/mywiki/moin.cgi

Any help will be greatly appreciated.

Thanks a lot.

• I just upgraded to Mac OS X 10.5 (Leopard) from 10.4. I had my wiki working very nicely for about a year. The upgrade to Leopard messed up all my web sites because it changed the version of apache and the location of the config files. I successfully changed the apache config file to get my web sites working, and added the alias lines for the wiki (I entered the identical lines from the previous version of the config file). However, now I get a '403 Forbidden' message when I try to access my wiki. I've checked and the wiki is still owned by www (the web server). The permissions don't seem to have changed and I don't see why the upgrade Leopard would affect them. I'm wondering if there is something else I've forgotten in the config file.

Any suggestions would be welcome.

Thanks

• upgrade question from moin-1.5.5 to the latest stable version 1.5.8

can anyone please give me some tips? or point me to an how-to upgrade procedure? does anyone know about problems with upgrades from this versions?

thank you.

## Migration from 1.3.3 to 1.5.8

Hello,

I'm trying to upgrade a wiki from 1.3.3 to 1.5.8, and the following part of the README.migration confuses me:

1.5.3 migration
===============

First make sure you have run all the old mig scripts ONCE (and only once) on

The old style stuff moved here: MoinMoin/script/old/migration/

In that directory, there is also a new 152_to_1050300.py mig script - you
need to run it as the last mig script to switch to new style mig scripts.
It puts a file "meta" in your data dirs that hold the data_format_revision
value. The new style mig scripts use that value to make it much simpler for
you in future.

After this, please continue in section "Post 1.5.3 new style migration".

1.3.4/1.3.5 migration
=====================
We added some mig scripts in moin 1.3.4. So if you have done the 1.2 to 1.3
migration with some earlier moin version (like 1.3.3), then please run the
new scripts, too:
* 12_to_13_mig10.py
* 12_to_13_mig11.py

the 12_to_13_mig11.py says:

migration from moin 1.2 to moin 1.3

12_to_13_mig10.py:

migration from moin 1.3 < patch-xxx to moin 1.3 >= patch-xxx

and 152_to_1050300.py

Migration from moin 1.5.2 to moin 1.5.3

Can you please tell me, where the 1.3.xxx -> 1.5.2 part is?

• There is nothing else except what is described in the README.migration (if we don't change storage between some versions, you don't need a converter script for migrating between those). So, assuming that you correctly migrated to 1.3.3 earlier (and have run everything up to mig9), you need to run mig10, mig11, 152_to_1050300 now and the the post-1.5.3 stuff.

## Using MoinMoin on smartphone (symbian) via Raccoon

Q: There is apache available for Symbian called Raccoon, mod_python is working there. Is it worth an attempt to install MoinMoinWiki on phones having Raccoon installed?

A: I guess it would be too slow. If you have Python on the phone (it won't work without), you can also use the standalone server of moin (will eat less resources, but still be too slow).

## Migration from 1.5.7 to 1.6.0

What do I need to do to convert my data pages to the 1.6.0 syntax? I've read the README.migration and still don't understand what needs to be done. I've located some migration scripts but need a little direction on how to use them.

• In a farm each wiki in the farm has to be migrated separately. The migration requires that you run the migration command twice (which was not obvious for me initially). After running the "migration data" cmd once a file "rename1.txt" is created in the data folder. This file may be changed. Either the modified or the unmodified file "rename1.txt" must be stored under the name "rename2.txt" at the same place. Then the migration command has to be run again. This starts main migration to the new markup. A back-up containing the unconverted data (wiki-pages) is created during the main migration in a folder named "data.pre160". Note that older versions of the pages are not converted - so if an older version is viewed in a moin-1.6 wiki the rendering is broken.
1. Change your config files and server configuration as required (diff 1.5.7 against the new files coming with 1.6.0)
2. Run (make sure that moin.py is on your path or add the path)
• moin.py --config-dir=pathToWikiConfig --wiki-url=http://yourwiki/ migration data

3. Create the rename2.txt file

4. Start main migration (this creates a new 1.6 version for each page that is converted)
• moin.py --config-dir=pathToWikiConfig --wiki-url=http://yourwiki/ migration data

• If the main migration fails you should first fix the problem and then start again: Delete the data-folder that is created during the migration and rename the backup folder from "data.pre160" to "data". Then re-run the migration command.

Thanks very much! This worked nicely.

## manual update to 1.6.0

Hi guys, Im trying to update from 1.5.8 to 1.6.0 atm but run into a small problem. Im using apache2 with fastcgi and python2.5 on a debian system. When I manually upload all files to python2.5/site-packages/MoinMoin, the new/changed ones arent recognized, its still showing up as 1.5.8 (so the update script doesnt even think theres something to update). An Apache restart/stop+start doesnt work, any other way to tell python that there are new files? (would like to prevent a full server restart if possible)

• you have to check your moin.fcg it needs changes do compare it with the example from the server dir.

## Permission denied when trying to migrate data

Trying to upgrade from 1.5.8 to 1.6.1. When running moin.py --config-dir="D:\WikiFarm" --wiki-url=farm1.site.ru/ migration data I get the following traceback:

145852 INFO     logging initialized
Traceback (most recent call last):
File "D:\Moin\_install\moin-1.6.1\moin.py", line 138, in <module> run(Config)
File "D:\Moin\_install\moin-1.6.1\MoinMoin\server\server_standalone.py", line 584, in run httpd = makeServer(config)
File "D:\Moin\_install\moin-1.6.1\MoinMoin\server\server_standalone.py", line 526, in makeServer return serverClass(config)
File "D:\Moin\_install\moin-1.6.1\MoinMoin\server\server_standalone.py", line 176, in __init__ SimpleServer.__init__(self, config)
File "D:\Moin\_install\moin-1.6.1\MoinMoin\server\server_standalone.py", line 63, in __init__ BaseHTTPServer.HTTPServer.__init__(self, address, MoinRequestHandler)
File "C:\Python25\lib\SocketServer.py", line 330, in __init__ self.server_bind()
File "C:\Python25\lib\BaseHTTPServer.py", line 101, in server_bind SocketServer.TCPServer.server_bind(self)
File "C:\Python25\lib\SocketServer.py", line 341, in server_bind self.socket.bind(self.server_address)
File "<string>", line 1, in bind
socket.error: (10013, 'Permission denied')

IIS 6.0 and Python 2.5.1.

• This is the wrong moin.py (the standalone server). You need MoinMoin/script/moin.py.

• Thanks, dealt with this, but another problem:

File "D:\moin\Lib\site-packages\MoinMoin\script\migration\migutil.py", line 50, in listdir
names = [name for name in os.listdir(path)
WindowsError: [Error 3] : 'd:\\WikiFarm\\wiki\\data\\user/*.*'

It seems like the script is looking for a user dir in each farm wiki's data dir, while I have a single user dir for all wikis which I specified in farmconfig.py

• giving it an empty user dir should make that simple program happy.

## Problems Moving Moin to another server

After moving my wiki instance to another server, I copied my /data folder onto the server and immediately started getting the following error on MyStartupPage and all other header links:

"WindowsError[Error 183] Cannot create a file when that file already exists"

I discovered that deleting the /data/cache/ folder fixed the issue. Moin immedatiately recreates the /cache folder os it did not cause any issues. Using the maint cleancache may also work, but I had a lot of troubles getting it to run on the server.

• I hit the same problem, with backup Moin to another Windows 2003 server. I'm running Moin 1.8.4. Deleting /data/cache/ folder alone doesn't work. I have to delete all cache/ folders under each page, in /data/page/.
• The problem may be with windows file abstraction layer which doesn't distinguish files with names which differ only in character cases (like, lowercase and uppercase). Consider avoiding using windows or renaming those pages. -- EugeneSyromyatnikov 2010-06-02 07:16:50 hmm, ntfs has an option for using upper and lowercase chars in filenames. Btw. 1.8.4 is outdated see SecurityFixes and update. -- ReimarBauer 2010-06-02 11:05:00

• NTFS does, win file abstraction layer doesn't (precisely, it does, too, but it's generally unusable). -- EugeneSyromyatnikov 2010-06-02 11:22:58

## It´s not that easy getting a standalone to work

I´m running a Suse 10.2 and installed Python 2.5 and the 1.6.1 moin². Calling up "python moin.py" gives the goo news below, but starting "http://localhost:8080" is not all it takes as the quick manual says.

This is what I get:

222501 INFO logging initialized 222501 INFO Serving on localhost:8080 222501 INFO Running as uid/gid 1000/100 222708 INFO 127.0.0.1 "GET / HTTP/1.1" 500 -

==> here the trouble after calling the localhost in firefox

Exception happened during processing of request from ('127.0.0.1', 22951) Traceback (most recent call last):

• File "/root/moin-1.6.1/MoinMoin/server/server_standalone.py", line 212, in serve_forever_thread File "/usr/lib/python2.5/SocketServer.py", line 254, in finish_request

File "/root/moin-1.6.1/MoinMoin/server/server_standalone.py", line 281, in init File "/usr/lib/python2.5/SocketServer.py", line 521, in init

• self.handle()
• File "/usr/lib/python2.5/BaseHTTPServer.py", line 316, in handle
• self.handle_one_request()
• File "/usr/lib/python2.5/BaseHTTPServer.py", line 310, in handle_one_request
• method()
• File "/root/moin-1.6.1/MoinMoin/server/server_standalone.py", line 306, in do_ALL File "/root/moin-1.6.1/MoinMoin/server/server_standalone.py", line 336, in serve_moin

File "/root/moin-1.6.1/MoinMoin/request/request_standalone.py", line 56, in init File "/root/moin-1.6.1/MoinMoin/request/init.py", line 1418, in fail

ImportError: cannot import name failure

There´s much more to know, isn´t it ??

Completely erase that stuff, log in as user (not root) and start from scratch.

## Problems with basic installation

I am having the worst time trying to install MoinMoin on OSX - I upgraded my computer to Leopard just recently, followed the instructions listed in the Help all to no luck. There are problems, since the most recent version is 1.6.3 - the installer seems to be for 1.6.0 - I tried just changing the numbering appropriately, but cannot find the wiki when I browse to http://localhost/mywiki . Any help would be appreciated - unless I'm missing something on my computer, there is something wrong with the install guide.

• If you have trouble with the apache installation, why don't you simply use python ./moin.py? That's all you need to do to start the standalone server of 1.6.x and have a working wiki. -- ThomasWaldmann 2008-06-19 20:25:26

I'm working on a wiki at work where I have access to the wikiconfig.py file, but not the /wiki/ directory. The sys admins install everything for our wikis and this is the way they have it set up. Is it possible for me to add or modify themes in this case?

## Problem installing with linux + lighttpd + fastcgi + unix socket + site directory (not subdomain).

I'm running a lighttpd server under linux, and I'm trying to get MoinMoin running using fastgci with a unix socket in a site directory as opposed to a subdomain. In other words, I want the URL for getting to MoinMoin to be http://myserver.tld/moin, where the /moin part is the site directory.

However, I can't get this to work. When I go to http://myserver.tld/moin using the configuration described below, I always get a 500 Internal Server error.

Can any of you see what's wrong with my configuration? Here it is:

The directory where the site resides is /home/hippoman/sites/moin, and it contains the following items:

% ls -l
total 13
2 drwxr-sr-x 7 hippoman www-data 2048 Oct  6 20:14 content/
2 drwxrwx--- 7 hippoman www-data 2048 Oct  6 17:26 data/
2 drwxrwx--- 3 hippoman www-data 2048 Oct  6 17:26 underlay/
7 -rw-rw---- 1 hippoman www-data 6705 Oct  6 20:09 wikiconfig.py

The content subdirectory is a copy of the htdocs directory under /usr/local/share/moin (the place where MoinMoin got installed on my system). In other words, it's the static content.

This is the pertinent part of my lighttpd config file:

alias.url = (
# "/moin" => "/home/hippoman/sites/moin/content",
"/moin" => "/home/hippoman/sites/moin",
}
$HTTP["url"] =~ "^/moin\b" { url.rewrite-once = ( "^/moin/robots\.txt" => "/moin/content/robots.txt", "^/moin/favicon\.ico" => "/moin/content/favicon.ico", "^/moin/(.*)" => "/moin/content/$1",
"^/moin$" => "/moin/content" ) server.document-root = "/home/hippoman/sites/moin" accesslog.filename = "/home/hippoman/log/moin.access_log" fastcgi.server = ( "/moin" => (( "socket" => "/var/run/lighttpd/hippoman/moin.socket", "bin-path" => "/root/bin/smoin", "bin-copy-environment" => ( "USER", "LOGNAME", "SHELL" ), "bin-environment" => ( "PATH" => "/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin", "UNAME" => "hippoman", "GNAME" => "www-data", ), "min-procs" => 1, "max-procs" => 4, # "check-local" => "disable", )) ) I tried it both with and without check-local set, but it fails nonetheless. I also tried it with both versions of the /moin alias, with the same error. The /root/bin/smoin script is a wrapper which changes the uid and gid: [HASHBANG]/bin/sh uname=${UNAME:=www-data}
gname=${GNAME:=www-data} unset UNAME unset GNAME exec /usr/bin/sudo \ /usr/local/bin/chpst -u${uname}:${gname} \ /root/bin/local-moin.fcg "$@"

exit 1

... where [HASHBANG] represents #!, which I can't figure out how to escape in the text above using this markup language.

The /root/bin/local-moin.fcg program is my local version of the standard moin.fcg:

... etc. ...

# Debug mode - show detailed error reports
os.environ['MOIN_DEBUG'] = '1'

from MoinMoin.server.server_fastcgi import FastCgiConfig, run

class Config(FastCgiConfig):
loglevel_file = logging.INFO
logPath = '/home/hippoman/log/moin.access_log'
max_requests = 1024
properties = {}
# properties = {'script_name': '/moin'} # use this instead of the line above if your wiki runs under "/moin" url

# for backlog, we use a default of 5. if the listen(backlog) call crashes for you, try a smaller value!
# backlog = 1

run(Config)

I tried it with both versions of the properties setting.

Can anyone see what I'm doing wrong? Thanks in advance.

PS: The wrapper script works fine. I use one just like it to run other fastcgi engines under specific user ID's. Also, the ownerships and file permissions are all correct, as far as I can tell.

PPS: All other sites work fine under my web server, including all of them running under other fastcgi instances.

PPPS: The only error message that I can find in any log file is this (anonymized):

xxx.xxx.xxx.xxx myserver.tld - [06/Oct/2008:21:51:20 -0400] "GET /moin HTTP/1.1" 500 369 "-" "Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.0.3) Gecko/2008092414 Firefox/3.0.3"

## Just installed MoinMoin v1.8.0 and the GUI editor isn't working

When I try to edit a page on my wiki using the Edit(GUI) button I seem to be missing the editing screen. I can see the Save Changes, Preview, ect buttons at the top of the page and the Comment entry at the bottom of the page but the section to actually edit the page is just blank. Have I missed a config setting somewhere to enable GUI editing? I know it is not the browser as I am able to edit other MoinMoin wiki's using the GUI editor.

I figured this out by accident. As an FYI, in my wikiconfig.py I had my url_prefix set incorrectly.

## Guide for MoinMoin on a memory stick?

Has anyone else come up with a guide to installing MoinMoin on a memory stick? I've started one that is centered around Windows, I'm not a Linux or Mac user, at the page PortableMoin. If anyone wants to help categorize it and add information for the other OSes, please feel free.

Robert K, Dec 29 6:39PM GMT

## Is there a way to change global variables?

I'd like to change how the variable SIG is being displayed. Is there a way to change it so the name and date are shown on two lines instead on one next to each other?

## GUI Editor not installed/configured??

I have created 2 moin wiki instances on ubuntu that both appear to work, except that the GUI Editor doesn't appear. The apache log file shows that the /usr/share/moin/htdocs/applets/FCKEditor/fckeditor.js file is being called up, but doesn't exist. How should this editor be configured? I can see some fckeditor config references in the usr/share/docs/python-moinmoin/examples folder, but no information as to how to use these.

Ubuntu 8.10, MoinMoin 1.7.1

debians package manager has dropped the old fckeditor package. 1.8 uses the current fckeditor version and was refactored last gsoc, see MoonByeongweon/SOC2008. You may want to download a recent version.

Same issue appears on Ubuntu 10.10, MoiMoin 1.9.3.

Solution is:

1. Install fckeditor:

sudo apt-get install fckeditor

2. Make it available for MoinMoin:

cd /usr/share/moin/htdocs/applets

sudo rm -rf FCKeditor

sudo ln -s /usr/share/fckeditor FCKeditor

3. Restart web server

## After upgrade MoinMoin 1.6 --> 1.81 edit page no more possible

After the upgrade to MoinMoin 1.81, the pages cannot be edited anymore. It always shows "Locked" (mandarin theme), even if I or the Admin is logged in. Also with the classic theme 'edit' does not work.

Any idea what the problem could be?

Please try "modern" or "modernized", whether it works with those.

I found a workaround for the problem. It had to do with the ACL configuration. There was a group defined - but unfortunately, the new MoinMoin version does not work with this group, so I had do enter all users directly into the file wikiconfig.py.

EpGroup (was working with MoinMoin 1.6)

* UserOne
* UserTwo
* UserThree
* UserFour

wikiconfig.py (was working with MoinMoin 1.6)

wikiconfig.py (works now also on MoinMoin 1.81)

GPL

This workaround works find for me, but sure, it would be nice if the groups also worked in the new version.

## After upgrade one of the farms fails to import theme module

I've got a farm of two wiki's and tried to upgrade from 1.7.2 to 1.8.4 One of the wiki's works fine, but for the second I get the following error:

Traceback (most recent call last):
File "/usr/lib/python2.5/threading.py", line 486, in __bootstrap_inner
self.run()
File "/usr/lib/python2.5/threading.py", line 446, in run
self.__target(*self.__args, **self.__kwargs)
File "/usr/lib/python2.5/site-packages/MoinMoin/support/thfcgi.py", line 537, in accept_handler
req.run()
File "/usr/lib/python2.5/site-packages/MoinMoin/support/thfcgi.py", line 283, in run
self._handle_record(rec)
File "/usr/lib/python2.5/site-packages/MoinMoin/support/thfcgi.py", line 385, in _handle_record
self._handle_app_record(rec)
File "/usr/lib/python2.5/site-packages/MoinMoin/support/thfcgi.py", line 456, in _handle_app_record
self.req_handler(self, self.env, self.getFieldStorage())
File "/usr/lib/python2.5/site-packages/MoinMoin/server/server_fastcgi.py", line 56, in <lambda>
request_fcgi.Request(req, env, form, properties=properties).run()
File "/usr/lib/python2.5/site-packages/MoinMoin/request/__init__.py", line 1205, in run
self.initTheme()
File "/usr/lib/python2.5/site-packages/MoinMoin/request/__init__.py", line 1184, in initTheme
File "/usr/lib/python2.5/site-packages/MoinMoin/request/__init__.py", line 741, in loadTheme
Theme = wikiutil.importPlugin(self.cfg, 'theme', theme_name, 'Theme')
File "/usr/lib/python2.5/site-packages/MoinMoin/wikiutil.py", line 1110, in importPlugin
return importWikiPlugin(cfg, kind, name, function)
File "/usr/lib/python2.5/site-packages/MoinMoin/wikiutil.py", line 1120, in importWikiPlugin
plugins = wikiPlugins(kind, cfg)
File "/usr/lib/python2.5/site-packages/MoinMoin/wikiutil.py", line 1193, in wikiPlugins
module = pysupport.importName(modname, kind)
File "/usr/lib/python2.5/site-packages/MoinMoin/util/pysupport.py", line 81, in importName
module = __import__(modulename, globals(), {}, [name])
ImportError: No module named p_dd8c12da6c9cca3e1448683a3f9a81deb21bd610

I tried to insert my custom  logging.debug  checks in various places of that files in the trace and discovered that this is an attempt to load a standard theme for this wiki. Another wiki uses the same theme too. After dumping to log from the _loadPluginModule in multiconfig.py I can see that this is the correct UID and it seems like no exceptions occur there. htdocs are updated.

After rolling back python/site-packages/MoinMoin to the previous version everthing is fine again.

.fcg files for both wiki's are the same. Config files differ only in sitename, interwikiname and data_dir. All permissions in both ./data ./underlay ./htdocs are double-checked.

So I'm completely stuck now. Can any one help?

-- AlexanderAgibalov 2009-07-02 13:44:19

## Upgrading Moin Moin from 1.5.5 to 1.8.4

I am in the process of updating my Wiki from the old 1.5.5. version to 1.8.4. I have already setup the Wiki on a new server and have copied all my old data from the 1.5.5 machine to the new 1.8.4. Based on reading all the support docs, I need to run some scripts to convert the data to the new format; however, I can't seem to find a script to move from 1.5.5 to 1.8.4 - do I need to convert from 1.5.5 to 1.6.0 then to the next version, etc until I reach 1.8 or is there another way?

Thanks.

-- Stephen Spector

• Migrating data from 1.5.3+ is a one-step process. See "Post 1.5.3 new style migration" in docs/README.migration -- MarkSapiro 2009-09-01 23:17:28

## Upgrade messed up the GUI editor and appearance of pages

Several months ago I had installed and configured moin-1.8.2 from source and had been using it happily afterwards. Until this past weekend. Fedora told me I had 500+ package updates waiting to get installed. I didn't think about the impact it could have on moin and told it to go ahead and install the updates. Turns out one of the updates was moin-1.6.2 which it installed as an rpm and it messed up my wiki instance. Here's what it impacted:

1. No longer seeing visited page history across the top of the screen horizontally with its own header. Now it just appears as an unformatted list.
2. No longer seeing an option to use the GUI editor. Just the text editor.
3. No longer seeing tables formatted as tables. Now it's just text without any borders.

Anyone know how to fix this?

Answer: Deinstall the dist package, make sure everything MoinMoin is gone from /usr/lib/python/sites-packages. If it didn't mix things up, moin should start working again. Maybe clean the cache.

If that isn't enough, just install 1.8.5.

Reply: Deinstalled, removed MoinMoin from site-packages, cleaned cache. Did not fix it. installing 1.8.5 from source, imported my data/pages and it fixed. Thanks.

## SiteNavigation page missing from underlay in 1.9.0

I have just upgraded from 1.8.5 to 1.9.0 and I see there is no SiteNavigation page. I added my old page from 1.8.5 and it seems to work fine. In particular, all the linked pages are present. Is there some reason why it was removed and I shouldn't be using it, or is this an oversight. -- MarkSapiro 2009-12-19 16:44:03

Contents was merged into FindPage (and FindPage is referenced from default navibar).

• Thank you. I never scrolled down far enough on FindPage to see it. My bad. -- MarkSapiro 2009-12-19 16:59:50

## Cannot register new account -- 1.8.7 fresh install

I installed (not upgraded) 1.8.7 on Fedora 10 and cannot figure out how to add any accounts. The login page says "To create an account, see the UserPreferences page" but there is no UserPreferences page; clicking UserPreferences gives "This page does not exist yet". I also tried adding "?action=newaccount" to the URL and it says "Unknown action newaccount". BTW, the SendMyPassword page doesn't exist, either.

This sounds extremly different to the moin-1.8.7 from our download page. By executing of the login action I see If you do not have an account, you can create one now. Forgot your password? So may be look into the Fedora 10 README or other documentations. I guess it is not a 1.8 release perhaps 1.5? -- ReimarBauer 2010-02-28 22:23:02

I know I did install moin-1.8.7. But, based on your note, I checked for other versions. Long ago (probably when I installed Fedora 10) apparently I installed moin-1.6.4 and it was in the path before 1.8.7. I moved it out of the way and now, magically, everything works. Thank you, ReimarBauer. -- -- LarryFenske 2010-03-02 05:52:01

## No help pages in 1.9.1?

I installed (not upgraded) 1.9.1 on Fedora 10 and cannot find any help pages. Do I need to install some other version first, then upgrade to 1.9.1 to get help pages?

• Did you copy the underlay/ directory to your instance directory or set data_underlay_dir appropriately in wikiconfig.py -- MarkSapiro 2010-02-28 18:14:07 Also see LanguageSetup -- MarkSapiro 2010-02-28 18:35:09

Yes, I did copy underlay and set data_underlay_dir. The help files don't seem to exist in the tar.gz distribution.

Oh, I see: LanguageSetup should install the help pages for me. I'll try it. I had gone back to 1.8.7 because it has help pages, but I'm having problems with it, too. Thank you.

With 1.9 we only pre install one page for you. Select in LanguageSetup what you want to have installed

• Honestly, that is a bad idea. English pages should be installed per default, IMHO. Everything else is optional ...

## Need help on url

environment: windows 2008 r2 + iis 7.5 + moin1.9.2 i use the cgi mode(looks like the only way in iis7) to run wiki: http://localhost/moin.cgi some url looks fine:

what' wrong with it?

• -- I'm having the same issue on IIS7 with cgi, any ideas? (2010-07-12)

## Unable to install Moin Moin 1.9.3 on a hosted server

Hi,

i am trying to install the moin-1.9.3 on a hosted server, where i only have ftp access.

I am unable to change the apache config (I think, MoinMoin MUST be installable, without doing so).

Here are the troubles i encountered:

• The Documentation http://moinmo.in/via_ftp_on_vserver is wrong/incomplete.

• The Point "wikiconfig.py anpassen" does not describe, what changes are needed.
• The Point "Dateien hochladen" makes no sense. I think you need to upload the Folder /MoinMoin, don't you?

• I got it workig but i am still confused about the intended directory structure on the server, because the documentations are all different.
• After this trouble i got MoinMoin working with FastCGI. (The Server does not support WSGI). But the entire CSS mechanism is broken.

• The CSS is searched in wiki.domain.tld/moin_static193 -> WTF?

• may be read again in your wikiconfig line 56 to 62 or here

• As far as i can see, the correct path is wiki.domain.tld/MoinMoin/web/static/htaccess
• I found some infos via google telling me to add a Apache Alias. But i can't do so, since i have no access to the apache config and afaik you can not add such a alias to a .htaccess file.
• I played around with the wikiconfig.py file and some other files regarding this. I have no idea, how to fix this.

What is the url to a page of your instance?

Can anyone help?

MoinMoin is a very nice wiki engine. But without root access on the server, you encounter very much installation problems and the documentation is very confusing.

This is may be the documentation for such an installation wants a maintainer. It would help if one make an HowTo for others for this kind of installation

This needs to be easier.

help and just do it

-- trequ

## Using '/' as the "script name"

I did this with older versions of moinmoin, but the moin.cgi script changed (again) and I couln't find how to do it.

I can only use moin.cgi and .htaccess (I'm hosting on Dreamhost).

What I want is that my wiki be seen as http://www.example.com/WikiPage

I already added a couple of lines to .htaccess so that it works partially:

DirectoryIndex moin.cgi index.html

# start the rewrite engine
RewriteEngine On
RewriteBase /

RewriteRule ^(static/|moin_static.*/|moin.cgi) - [last]

RewriteRule ^(.*) moin.cgi/$1 [type=application/x-httpd-cgi] So, if I go to http://www.example.com/WikiPage it shows the correct page. However, if I click on SomePage there, it goes to http://www.example.com/moin.cgi/SomePage , that is, what I need is to convince moinmoin to generate links using only /. In previous versions, there were a properties array that you could set in moin.cgi like: properties = {'script_name': '/'} And in yet older versions, you put something similar as the argument to a function that drawed the page, but I don't know how to do this in 1.9.4. -- MarianoAbsatz 2012-05-03 19:42:39 • In Moin 1.9.4, if you use the moin.fcgi script (it works for CGI, too), you can edit the fix_script_name variable to specify the URL path. For example: fix_script_name = '/' I'm not sure of any reason why you'd use moin.cgi in Moin 1.9, but maybe it is still useful for something. -- PaulBoddie 2012-05-04 11:33:28 That worked alright, thank you (and started using moin.fcgi, btw). -- MarianoAbsatz 2012-05-05 22:33:10 ## upgrade, then unable to find data_dir I had an old moin instance that I installed and ran with very little trouble for several years on an old Windows NT box. The NT box is now gone (I no longer have any access to it) but I have a copy of the data from the old wiki, and I want to set up a new server to access it. I installed python and moin on a new Windows 7 box. Now I can start moin and it seems to come up fine. I can edit pages from the "out of the box" wiki that comes with moin. So far, so good. Now I try to point the new moin instance to the data from my old wiki, which I've restored from a backup. I edit wikiconfig.py to set data_dir. This works just enough to let me know that I'm probably on the right track. If I set data_dir to point to a directory that doesn't exist, I get an error message like: Directory c:\moin\olstuff\data does not exist. But If I fix it to point to c:\moin\oldstuff\data it doesn't display pages from "oldstuff\data", I get some generic "out of the box" front page instead. There is a page called FrontPage in oldstuff\data\pages, so why doesn't it come up? I think the new moin instance is 1.9.3. I'm not sure what version the old server was, but it had been installed several years ago and it ran ever since with no trouble, so I had not upgraded it. Are there incompatibility issues with wikis created with old versions of moin? PaulBerglund 2012-12-05 • OK, I think I've answered part of my own question: there are incompatibilities with wikis build with older versions of moin. I don't know, but I'm guessing that my old installation was 1.5.x or even older (it was more than five years since it had been touched). But I'm guessing that that wouldn't affect my ability to see wiki pages (though they might display incorrectly), right? Also, is there a way, without access to the old server box but just to backup of the pages of the wiki built using it, to tell what moin version that server was running? Even some rule of thumb like "if the old pages have formatting that looks like example1 then its before version 1.x.y, else if it looks like example2 then it's after" would be of help -- PaulBerglund Any links that look like [SomePage] or [SomePage link label] or [http://example.com/ example site] are from Moin 1.5 or earlier, whereas [[SomePage]] or [[SomePage|link label]] or [[http://example.com/|example site]] are from Moin 1.6 or later. Similarly, macros look like [[Macro(args)]] in Moin 1.5 or earlier but look like <<Macro(args)>> in Moin 1.6 or later. Particularly the latter should be easy to find on pages like FindPage. -- PaulBoddie 2012-12-05 14:21:13 • I looked at the file data\meta and it contained the line • data_format_revision: 01050400 so I'm guessing that the previous moin instance was running version 1.5.4. Is that correct? I tried running moin migrate data as described in the migration readme file but that didn't turn out well. The first pass seemed to go OK but the second pass terminated with an error, leaving a number of pages missing or empty (the directory existed but had no contents). I still have the backup so the data getting trashed is not really a problem, but I am no closer to being up and running.--PaulBerglund • Please join us on irc, see http://moinmo.in/MoinMoinChat May be we can help there. -- ReimarBauer 2012-12-06 23:13:27 • The problem turned out to be that the data migration had died (writing something to stderr, but I had missed it) because it wanted to delete a directory that I had open in explorer or a cmd window. I'm up and running now.--PaulBerglund # Configuration Files ## url.com versus url.com/wiki problem Dear friends, our sysadmin has moinmoin working great at xyz.com/wiki But, how to get it working at xyz.com ?? (For example, http://moinmo.in/ works perfectly ... it does not redirect to http://moinmo.in/wiki ) Thanks !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! You may want to read the comments in the moin.wsgi file -- ReimarBauer 2012-07-17 19:37:35 ## How to make RECENT CHANGES go back further in time I would like the RECENT CHANGES to go back more than a couple of months. Actually I would like it to go back a year. How do I configure MOINMOIN to do this? I don't see this in the documentation. ## MoinMoin with Fedora 14 I've installed MoinMoin and mod_python on my Fedora 14 box. I used yum to install both packages. moin-1.9.3-2.fc14.noarch mod_python-3.3.1-14.fc14.i686 I've configured the wiki but when I try to access the main page I get what looks like an FTP style directory listing, showing the wiki root folder and all sub-folders. Any idea as to why this occurs? Additionally, will this version of MoinMoin work with the version of python offerred by Fedora 14. python.i686-2.7-8.fc14.1 ## Invalid escape I´ve done everything as described at http://moinmoin.wikiwikiweb.de/HelpOnInstalling/ApacheOnWin32. When opening http://127.0.0.1/mywiki I get the Message "Import of configuration file "wikiconfig.py" failed because of ValueError: invalid \x escape (...)". • Please paste your configuration. ## Farmconfig matching Trying to get farm_config working if anyone has an example I would appeciate it. • See .../wiki/config/farmconfig.py - that is an example for a working farmconfig setup I have been working with that farm config. I've added ("adminwiki", r"^adminwiki/.*$"), to the wikis array in farmconfig.py and I keep getting an error saying:

Could not find a match for url: "adminwiki".

• Obviously, r"^adminwiki/.*$"does not match "adminwiki". Which URL did you request? The URL I type in is http://adminwiki, but by the time I see it working, it's http://adminwiki/moin.cgi/. I just now got it to work by changing the match string to: r"^adminwiki$" instead.

## Moving several wikis to a wiki farm - (Problem)

Suppose I have two different wikis located under a common base-folder:

• base/wiki1
• base/wiki2

Running moin.py in my "base/wiki1"-Directory works fine and gives access to my "wiki1" content. For example, requesting

http://myserver:8080/NewPage

will try to access "NewPage" in my base/wiki1/data/pages directory. But if I try to turn my two different wikis to a single wiki-farm by using farmconfig.py:

#farmconfig.py:
wikis = [
("wiki1",  r"^myserver:8080/wiki1/.*$"), ("wiki2", r"^myserver:8080/wiki2/.*$")
]

requesting

http://myserver:8080/wiki1/NewPage

will end up accessing "wiki1(2f)NewPage" in my base/wiki1/data/pages directory. Why?

• I have dealt with a similar issue (I believe). You need to go into MoinMoin Request.init and edit the base request. MoinMoin needs PathInfo and ScriptName to look like so:

PathInfo = "/NewPage..." ScriptName = "/wiki1"

PathInfo = "/wiki1/NewPage..." ScriptName = "/"

so you need to put in some code to switch it around so it looks like the former.

• you should not needed to edit any moinmoin intern files to setup a correct farmwiki. maybe beside the farmwiki.py you have still the wikiconfig.py file in your directory or something else missed... you may also have to check your server configration (e.g. if it's apache with mod-wsgi that your aliases are correct; for example I do for every wiki this stuff in my apache config: WSGIScriptAlias /wikixy /var/www/moinmoin/server/moin.wsgi)

## Standalone server - TCP Interfaces

I am trying to make the standalone server accept connections from a limited number of IPs only. To do this I am editing the "interface" field in the moin.py file in the following way "interface = 'some.ip.is.here' ".

• Check if you are binding to an invalid IP, to an invalid port (check that one as well). Especially, look if you want to bind to a port below 1024 and if you run standalone as a root application.

Have the same problem. Trying to make the standalone server accept connections from a limited number of IPs only. To do this I am editing the "interface" field in the wikiserverconfig.py file in the following way "interface = '192.168.1.51' ". IP address is right. I get next error when trying to launch wikiserver.py: "socket.gaierror (11001, "getaddrinfo failed").

## Invalid syntax error after editing wikiconfig.py

• Import of configuration file "wikiconfig.py" failed because of SyntaxError: invalid syntax (wikiconfig.py, line 123).

### Solution

In most cases, you broke the file by adding tab characters. MoinMoin configuration files are Python modules, and does not work with a mix of tabs and spaces. Uses only spaces when you edit moin files.

• Is there any way to totally disable the quick links at the top of the page? (front page is all I need and that I can get from the logo).
• is there any way to tailor what appears in the grey footer at the bottom? (I don't want the spellchecker which is there, and I would like the rename-page facility, which is not there).
• you can simply remove the spellcheck action from action/ directory (or make your own theme to not show it)
• some actions must be enabled, e.g. allowed_actions = ['DeletePage', 'AttachFile', 'RenamePage',]

## Default User Preferences

Is there a way to set the default options for the anonymous user and for all new users?

• You can set some basic options, see HelpOnConfiguration (this includes the theme default, the question marks in front of the links etc.; in MoinMoin 1.2 and 1.3). A few options cannot be set in a global way, though.

## EOL while scanning single-quoted string

• Import of configuration file "wikiconfig.py" failed because of SyntaxError: EOL while scanning single-quoted string (wikiconfig.py, line ...).Goto line ... and check if you have a backslash at the end of the string. If so, try to avoid it. If it still does not work, paste the line here.

## Another port for the DesktopEdition

I can't see an option for changing the port.

## Troubleshooting Configuration

We are having issues with the configuration of MoinMoin. This is the error log. We are setting up a single wiki on the intranet. The farmconfig in moin.cgi is commented out. We have changed the 404 errors as suggested for IIS. We still cannot add NEW PAGES. We are using Moin 1.3.5 Python 2.4.2 and Windows NT. We appreciate your help.

• It looks like your configuration file is not indented correctly. Please upload it in the wiki if you cannot file the fault by yourself.

## Farm with Desktop Edition

You may wonder why would anyone need to run a wikifarm on a DesktopEdition but the truth is that I would like to keep my personal wiki and my work wiki completely separate (work wiki can then be synchronized with a remote server, my personal stuff can stay my own). Can anyone give me a brief outline (provided it is possible to run this with the DesktopEdition on Windows) of how to accomplish this? I am a total newbie with python so instructions as simple as the like of "open eye, insert fork, twist, call 911" would be greatly appreciated. Ivaylo, 2006-02-07

### Solution

Solution working for Windows XP SP2 / MoinMoin Desktop Edition 1.5.3
Let's suppose you want to create a farm of 2 wikis: wiki_biz and wiki_perso

Step 1: create a wiki instance for each wiki

1. Create a copy of C:\Program Files\moin-desktop\wiki\data with all its subfolders at

1. C:\Program Files\moin-desktop\wiki\data_biz

2. C:\Program Files\moin-desktop\wiki\data_perso

Step 2: create a config file for each wiki

Save these 2 files and farmconfig.py (step 3) under C:\Program Files\moin-desktop\

wiki_biz.py

# -*- coding: iso-8859-1 -*-

from farmconfig import FarmConfig

class Config(FarmConfig):

sitename = 'Wiki Biz'
data_dir = 'C:\Program Files\moin-desktop\wiki\data_biz'

wiki_perso.py

# -*- coding: iso-8859-1 -*-

from farmconfig import FarmConfig

class Config(FarmConfig):

sitename = 'Wiki Perso'
data_dir = 'C:\Program Files\moin-desktop\wiki\data_perso'

Step 3: create farmconfig.py

# -*- coding: iso-8859-1 -*-

wikis = [
("wiki_biz",  r"^wiki_biz.*$"), ("wiki_perso", r"^wiki_perso.*$"),
]

from MoinMoin.multiconfig import DefaultConfig

class FarmConfig(DefaultConfig):
# put here the config you want to share among all your wikis in the farm. For example:
tz_offset = 9.0

• edit the hosts file at C:\WINDOWS\system32\drivers\etc\hosts

• replace the following line

127.0.0.1       localhost

with

127.0.0.1       localhost wiki_biz wiki_pers

Using the farm

Start the Wiki engine (moin.py)

Now, you should be able to access your 2 wikis by using the following address:

## Force User Logout On Browser Close

System: Ubuntu 5.10, latest MoinMoin, Apache, and Python packages. Currently, users that log in remain logged in between browser sessions. Due to the way we will be using this wiki, I'd like to set the cookie so that it expires when the browser closes. I have no idea how to do this. Any suggestions? Thanks, Thane

• You can use a low cookie_lifetime value, so the cookie expires when there is some time no activity. This has nothing to do with whether the window is open or closed, though. Maybe one could somehow catch window close with javascript and remove the cookie?

## How to configure a wiki farm running MoinMoin via Apache with mod_python

I have checked the docs at HelpOnConfiguration, HelpOnInstalling/ApacheWithModPython, and HelpOnInstalling for an answer to this. Of all those pages, the only one that begins to address this question is HelpOnInstalling, which simply states:

• Create a directory for your farm, and under it, make two data trees per the /WikiInstanceCreation instructions. In the config directory (by default /usr/share/moin/config) you will find an example farmconfig.py file. Copy this into the farm directory, and edit moin's launcher script (moin.py if you are standalone, moin.cgi if you are cgi, etc.) to point directly at it.

This is not explicit enough for me. What particular MoinMoin file do I need to edit for Apache with mod_python, and what specifically do I need to place or alter within that file to point to my farmconfig.py file? Many thanks in advance. -- ChrisLasher 2006-11-09 01:31:23

• You have to modify sys.path to contain the directory that has your configuration files, so Python can import the config file(s) from there.
• How about a concrete example? Let's say I have two wikis, WikiA and WikiB. Their files are stored in /home/moin/wikia/ and /home/moin/wikib/, respectively. Each one has its own wikiconfig.py under its directory. There is a farmconfig.py script in /home/moin/. What would one need to place in the <Location> directives of the Apache config file such that http://mysite.org/wikia/ goes to WikiA and http://mysite.org/wikia/ WikiB, via mod_python using farmconfig.py?

## How to get spaces in the page_front_page

My site is set to convert spaces to spaces in page names. This works fine, except for the page set to the variable page_front_page in the moinconfig.py config file. So when starting to visit the site without a page name in the URL, the front page is displayed with underscores in the title, where I would expect spaces. Example: http://www.wijgoudenleeuw.nl/ Is there a solution?

• You run an old moin version, can you try if this also happens with the latest one?

I am running debian packages moinmoin-common and python-moinmoin Version: 1.5.3-1.1, the newest version on debian etch = testing.

I fixed this problem without upgrading moin with this line in my apache config (root-wiki style):

RewriteRule ^/$/Name_with_underscores just above the rule for ^(.*)$ . I also wrote a note in the moinconfig.py file about this fix, otherwise I might get crazy later, trying in vain to set another front page.

## Disable ErrorLogs in webbrowser, enable only in flat files

How to disable displaying of any error logs for ordinary user (or for everybody) in browser? I'd like only to have error logs written to the file (for example to /etc/moin/errors , or /var/log/moin-error.log) ?

• Something similiar is planned for 1.6 -- ReimarBauer 2007-04-10 15:59:29

• OK. but is it possible to disable displaying of error informations in webbrowser now? (moinmoin ver. 1.5.x) -- Yanaek

-- Yanaek 2007-04-19

• See CHANGES of moin 1.5.8.

## Even when I edit wikiconfig.py, surge protection won't turn off

surge_action_limits = None this only works for 1.5.5+

to the wikiconfig.py file but the surge protection still locks me out. (Desktop Windows version)

What an annoying feature! It's unacceptable to have my software lock me out for working at a fairly normal speed.

Help, anyone?

• For 1.5.4 you just have to configure high limits, see the help page.

What limits should I set? I've played with the high limites and I still get locked out. This is very frustrating! Any specific suggestions?

I changed the value of some of the variables in wikiconfig.py (following the installation help files). I noticed no changes in the wiki itself, in particular the title did not change. So, I made sure that the path to wikiconfig.py was in the server script. However, it wasn't clear to me what script I should actually be editing, since in the server directory there are moin.cgi and moin.py and both have lines asking for the path to wikiconfig.py. Which script should I be editing, and am I missing anything else? Otherwise my wiki seems to be working quite nicely. I'm running Mac OS X 10.4. Thanks! -- Brian Taylor

• Maybe you yourself are the only one who can answer this. moin.cgi is the cgi adaptor, usually used with apache or some other web server executing moin as a standard cgi script. moin.py is the standalone server, so if you don't want to install apache or some other web server, you can use this "python builtin" web server. -- ThomasWaldmann 2006-09-14 08:29:45

• I figured out the problem. I was editing a copy of the wikiconfig.py file and not the wikiconfig.py file that was in the actual wiki. I'm new to the unix directory structure and it took me a while to figure out my mistake. Thanks for your feedback, though.
• I found that with mod_wsgi, the wikiconfig.py changes did not take effect until I restarted apache2.
• Maybe read the mod_wsgi documentation, it contains useful hints like that when touching moin.wsgi, it will restart the moin daemons.

## CGI-Fehler

Die angegebene CGI-Anwendung hat keinen vollständigen Satz von HTTP-Headern zurückgegeben I'm running Windows 2003, IIS 6. The Configuration seems to be correct, but I always get the cgi-Error. Anyone an idea?

## Supress URLs

Hi, can I prevent URLs entered in an article to be transformed into klickable links? I found a variable to add further protocols, but how to remove e.g. http? Thank You, -- mrdslave.

• You can use preformatted text {{{http://example.com/}}} http://example.com/ or the Verbatim macro [[Verbatim(http://example.com/)]] http://example.com/. But most readers expect to be able to click on a URL - making URL useless seems like a bad idea.

## Trying to enable discussion pages

Hi there. I've read HelpOnConfiguration/SupplementationPage and I've edited my wikiconfig.py, adding an extra line at the end which says

• supplementation_page = True

I've restarted apache2, but I don't see any Discussion pages in my wiki (single instance). I don't understand what's going wrong. I haven't changed the wikiconfig since I first set up the wiki a year or so ago. It's worked fine ever since (apache2 has been upgraded several times - I'm running Debian Etch). Sorry if I'm being really dim. (Yes, I have logged out and then logged back in - still no discussion pages.)

• This is a new 1.6 feature (this wiki and the MoinMaster wiki are running 1.6 now, release 1.6.0 is expected in december).

Thank you - nice to know I'm not stupid. I look forward to the 1.6.0 release.

## Preventing the script name from appearing when using mod_python

Hi, using 1.5.8.

I usually use mod_rewrite in cgi mode so that moin.cgi does not appear in the URLs. As I don't want the name to appear in the URLs generated by MoinMoin, I edit moin.cgi and leave it like this:

from MoinMoin.request import RequestCGI
#request = RequestCGI()
request = RequestCGI(properties={'script_name':'/'})
request.run()

and everything works fine.

Now, I got my own server and I'm trying to set it up to use mod_python... I got everything working (including mod_rewrite), but the stock moinmodpy.py will generate the URLs with it's own name in it...

I guess that there should be something I could do in this part of the code:

from MoinMoin.request import RequestModPy

def handler(request):
moinreq = RequestModPy(request)
return moinreq.run(request)

but I don't know what.

I bearly read Python, so studying request.py is not helping me. Can someone hand me a recipe to do this?

TIA

-- MarianoAbsatz 2007-12-13 20:02:50

### BUMP

Anyone can tell me if the above is indeed possible with mod_python???

I just upgraded to 1.6.3 and I'm not able to do this. What I want is to see http://wiki.example.com/RecentChanges instead of http://wiki.example.com/moinmodpy.py/RecentChanges (and that the links get generated that way internally).

I've done this many times with moin.cgi, but I can't see how to do this with moinmodpy.py.

I'm using moinmoin 1.6.3 with apache 2.2.4 under ubuntu 7.10 (gutsy).

The virtual host config file looks something like this:

<VirtualHost *:80>
ServerName wiki.example.com

DocumentRoot /var/vhost-www/wiki.example.com/

<Directory /var/vhost-www/wiki.example.com/>
AllowOverride None
Order allow,deny
allow from all

#DirectoryIndex moin.cgi index.html
# start the rewrite engine
RewriteEngine On
RewriteBase /

RewriteRule ^moin_static.../ - [last]
RewriteRule ^(/.*/)?moinmodpy.py - [last]

RewriteRule ^(.*)$/var/vhost-www/wiki.example.com/moinmodpy.py$1 [type=application/x-httpd-cgi]

</Directory>

ErrorLog /var/log/apache2/vhost/wiki.example.com/error.log
RewriteLog /var/log/apache2/vhost/wiki.example.com/rewrite.log
RewriteLogLevel 2

# Possible values include: debug, info, notice, warn, error, crit,
LogLevel warn

CustomLog /var/log/apache2/vhost/wiki.example.com/access.log combined
ServerSignature On

## WIKI
#ScriptAlias /moin.cgi /var/vhost-www/wiki.example.com/moin.cgi
<Location />
SetHandler python-program
PythonPath "['/var/vhost-www/wiki.example.com', '/usr/local/etc/moin'] + sys.path"
PythonHandler moinmodpy
PythonDebug On
</Location>
<LocationMatch "/moin_static...">
SetHandler None
</LocationMatch>

</VirtualHost>

in /var/vhost-www/wiki.example.com I have a copy of /usr/local/share/moin/htdocs named moin_static163 and a modified copy of moinmodpy.py as follows:

# -*- coding: iso-8859-1 -*-
"""
MoinMoin - mod_python wrapper for broken mod_python versions

wiki instance:

<Files wiki>
SetHandler python-program
PythonPath "['/path/to/moin/share/moin/cgi-bin'] + sys.path"
PythonHandler moinmodpy
</Files>

Note: this is a wrapper needed because of a bug in
mod_python < 3.1.3

mod_python.apache.resolve_object fails to parse a object with dots.

If you have a newer version, take a look at moinmodpy.htaccess
to see how to use MoinMoin without this wrapper. You can also
look into INSTALL.html to see how you can fix the bug on your own
(a simple one line change).

TODO: this should be refactored so it uses MoinMoin.server package
(see how server_twisted, server_wsgi and server_standalone use it)

@copyright: 2004-2005 by Oliver Graf <ograf@bitart.de>
@license: GNU GPL, see COPYING for details.
"""

# System path configuration

import sys

# Path of the directory where wikiconfig.py is located.
# YOU NEED TO CHANGE THIS TO MATCH YOUR SETUP.
#sys.path.insert(0, '/path/to/wikiconfig')
sys.path.insert(0, '/usr/local/lib/python2.5/site-packages/')

# Path to MoinMoin package, needed if you installed with --prefix=PREFIX
# or if you did not use setup.py.
## sys.path.insert(0, 'PREFIX/lib/python2.3/site-packages')

# Path of the directory where farmconfig is located (if different).
## sys.path.insert(0, '/path/to/farmconfig')
sys.path.insert(0, '/usr/local/etc/moin')

# Debug mode - show detailed error reports
## import os
## os.environ['MOIN_DEBUG'] = '1'

# Simple way
#from MoinMoin.server.server_modpython import modpythonHandler as handler

# Complex way
from MoinMoin.server.server_modpython import ModpythonConfig, modpythonHandler

class MyConfig(ModpythonConfig):
""" Set up local server-specific stuff here """

# Make sure moin will have permission to write to this file!
# Otherwise it will cause a server error.
logPath = "/var/log/moin/moinlog"

# Properties
# Allow overriding any request property by the value defined in
# this dict e.g properties = {'script_name': '/mywiki'}.
## properties = {}
#properties = {'script_name': '/'}

def handler(request):
return modpythonHandler(request, MyConfig)

/usr/local/etc/moin holds my farmconfig.py.

-- MarianoAbsatz 2008-05-03 15:35:09

### SOLVED

Well... it turned out that the mod_rewrite loop was originated by having a <Directory> section within the <VirtualHost> and having the RewriteRule's there... I'll try to elaborate a bit by updating HelpOnInstalling/ApacheWithModPython with some info... but now I'm going to sleep... -- MarianoAbsatz 2008-05-04 11:10:38

## navi_bar and spaces in page names

I have migrated to 1.6 and stumbled upon following: some of the pages have spaces in their names (all well so far, they were renamed from underscores when migrating), but I cannot find out how to write their names into navi_bar. The previous navi_bar = [u'[Hlavná_stránka Hlavná stránka]'] does not work, since Hlavná_stránka is not the same as Hlavná stránka. Replacing the underscore with a space does not work, obviously. Neither does using &x20; or the (semi-expected) pipe [Hlavná_stránka|Hlavná stránka]. Is there any way of escaping the space? I have resorted to renaming the page to Hlavná_stránka (with an underscore), but clearly that is not an universal solution. -- 147.213.138.3 2008-04-30 11:21:49

• For navibar, 1.6 still uses ["Free Link"] syntax. Sorry about this inconsistency, but the respective changeset was forgotten when backporting from 1.7. Starting with 1.7.0, it will consistently use the new link markup. -- ThomasWaldmann 2008-04-30 12:37:04

How do I remove the Quick links form from the page xxx?action=userprefs&sub=prefs completely? I have tried: user_form_remove = ['quick_links'] in wikiconfig.py but that does not work for me.

Thanks. -- JohanZiprus 2013-06-19 04:56:23

## How can I redirect the wiki pages from http to https?

I have installed a wiki (1.7.1) under linux (Apache with modpython). This wiki is configured as root wiki and working fine. I would like redirect all wiki pages from http to https. Who does know the recipe for it?

## Cyrillic pages names

I have several pages named in cyrillic. The problem is that folders in wich the pages are stored on disk are named in unreadable way: for example page 'поезд' (poezd - train in Russian) is stored in "(d0bfd0bed0b5d0b7d0b4)" folder - it seems like a raw unicode output. This is very inconvenient - for example it's hard to access that folder from my macro. Can I make pages with cyrillic names be stored in folders named as the pages themselves? (поезд - поезд, not поезд - (d0bfd0bed0b5d0b7d0b4))

Currently (as of moin 1.7/1.8/1.9 there is no easy way to do this). We did choose this encoding because it works everywhere (no matter what your FS encoding is, no matter whether linux or windows). We are working on improved backend storage for moin >= 2.0. -- ThomasWaldmann 2008-10-17 02:40:26

## Macro names appearing in rendered pages

If accessing a wiki page that doesn't exist, on the new page template we see "Action(edit,Create new empty page)" instead of a link to create a new page. On the RecentChanges page, we see RandomQuote() and Icon(diffrc) rather than a quote and an icon. I believe this behavior started around the time that I updated MoinMoin to 1.7.2. Any ideas how to troubleshoot this problem?

You likely forgot to update your underlay directory with the new one we provide in the distribution archive as wiki/underlay/.

## wiki.py missing

Those instructions are obviously for an old moin version. In recent moins, the wiki parser is in MoinMoin/parser/text_moin_wiki.py.

## Configure MoinMoin to use a different server for static stuff

I see that when I load a page from moinmo.in, the CSS, Javascript, and images actually come from static.moinmo.in. How do you do that?

## Configure MoinMoin standalone to run as www-data on port 80

I'm trying to setup monimoin on an ubuntu box using the built-in server, but running on port 80 as user www-data. I haven't been able to find any examples of these, if you have any please point me in the right direction.

Here's what I've done so far:

• Using the 1.9.3 tarball, I've installed it in /home/wiki like this:
• /home/wiki/
• data/
underlay/
config/

• In the config directory I've placed wikiconfig.py, wikiserverconfig.py and wikiserverlogging.conf. I modified the sys.path in wikiserver.py like:
• sys.path.insert(0, '/home/wiki/config')
sys.path.insert(0, '/home/wiki/lib/python2.7/site-packages')

• ..

• I've installed all the code from the LanguageSetup page and the wiki appears to be running fine when run as me.

• I then added more command-line configuration to wikiserver.py:

sys.argv = ["moin.py",
"server",
"standalone",
"--user=www-data",
"--group=www-data",
"--pidfile=/home/wiki/moinmoin.pid",
"--start"
]

The server works correctly on port 8080 when run as www-data.

• Next I edited wikiserverconfig.py, setting port=80, user='www-data', group='www-data', interface='192.168.1.2' (my ip address)
• Then I added "--port=80" to sys.argv in wikiserver.py and ran the server as "sudo ./wikiserver.py" and (removing "--start") I get:

mecklen@pippin:/home/wiki$sudo ./wikiserver.py Traceback (most recent call last): File "./wikiserver.py", line 47, in <module> MoinScript().run() File "/home/wiki/lib/python2.7/site-packages/MoinMoin/script/__init__.py", line 138, in run self.mainloop() File "/home/wiki/lib/python2.7/site-packages/MoinMoin/script/__init__.py", line 261, in mainloop plugin_class(args[2:], self.options).run() # all starts again there File "/home/wiki/lib/python2.7/site-packages/MoinMoin/script/__init__.py", line 138, in run self.mainloop() File "/home/wiki/lib/python2.7/site-packages/MoinMoin/script/server/standalone.py", line 143, in mainloop run_server(**kwargs) File "/home/wiki/lib/python2.7/site-packages/MoinMoin/web/serving.py", line 159, in run_server **kw) File "/home/wiki/lib/python2.7/site-packages/MoinMoin/support/werkzeug/serving.py", line 392, in run_simple inner() File "/home/wiki/lib/python2.7/site-packages/MoinMoin/support/werkzeug/serving.py", line 378, in inner passthrough_errors).serve_forever() File "/home/wiki/lib/python2.7/site-packages/MoinMoin/support/werkzeug/serving.py", line 251, in make_server passthrough_errors) File "/home/wiki/lib/python2.7/site-packages/MoinMoin/support/werkzeug/serving.py", line 207, in __init__ HTTPServer.__init__(self, (host, int(port)), handler) File "/usr/lib/python2.7/SocketServer.py", line 408, in __init__ self.server_bind() File "/usr/lib/python2.7/BaseHTTPServer.py", line 108, in server_bind SocketServer.TCPServer.server_bind(self) File "/usr/lib/python2.7/SocketServer.py", line 419, in server_bind self.socket.bind(self.server_address) File "/usr/lib/python2.7/socket.py", line 224, in meth return getattr(self._sock,name)(*args) socket.error: [Errno 13] Permission denied It appears that moinmoin is attempting to open port 80 as www-data instead of root. I would have expected it to open port 80 before settting its effective uid/gid. How do I run the built-in http server on port 80? ### Solution Here is an evil hack that seems to have worked (although it cannot be "checked in" with the source). • In site-packages/MoinMoin/web/serving.py comment out the switch_user call: def run_server(hostname='localhost', port=8080, docs=True, debug='off', user=None, group=None, threaded=True, **kw): """ Run a standalone server on specified host/port. """ application = make_application(shared=docs) if port < 1024: if os.name == 'posix' and os.getuid() != 0: raise RuntimeError('Must run as root to serve port number under 1024. ' 'Run as root or change port setting.') # if user: # switch_user(user, group) • In site-packages/MoinMoin/support/werkzeug/serving.py add the os.setgid and os.setuid function calls: class BaseWSGIServer(HTTPServer): multithread = False multiprocess = False def __init__(self, host, port, app, handler=None, passthrough_errors=False): if handler is None: handler = BaseRequestHandler HTTPServer.__init__(self, (host, int(port)), handler) self.app = app self.passthrough_errors = passthrough_errors os.setgid(33) os.setuid(33) The effect of this is to delay the switching the user to www-data until after the HTTPServer code has started listening on port 80. The reason it is unsuitable for checking in is that there is no good way to pass the desired user/group down from run_server through run_simple -> inner -> make_server -> BaseWSGIServer. Also, of course, this may simply be the Wrong Way To Do It. Comments? Please read wikiserverconfig.py -- ReimarBauer 2011-09-29 12:34:08 Thank you for responding. Your answer is a little vague. Of course, I have read those files. In fact, there are two in the 1.9.3 release and they have different contents. The moin-1.9.3/wiki/server/wikiserverconfig.py file describes a variable "interface = 'localhost'", which (as far as I can tell) does nothing, while the moin-1.9.3/wikiserverconfig.py file uses the correct value "hostname = 'localhost'". As to reading them to solve my problem, I was not able to find any information in these very short files which directly relates. There is, of course, the comment "if you use port < 1024, you need to start as root", which I tried as I described above. There is also the comment, "if you start the server as root, the standalone server can change to this user and group, e.g. 'www-data'". When running moinmoin as root I got the backtrace I described and debugged. The bug is that moinmoin invokes switch_user too soon and the socket open fails. Did you read my post? Or perhaps you meant the comment beginning "DEVELOPERS! Do not add...", which doesn't relate at all, unless I could use the custom Config class to change how switch_user works. I think so. So, perhaps you could be more specific in your advice. Can you answer two questions: 1. Should running standalone as www-data on port 80 work when wikiserver.py is run as root, i.e., "sudo python wikiserver.py"? 2. Does this work for you or anyone you know? Thanks, Robert Mecklenburg 2011-10-02 02:24:00 This could be a regression from 1.8 to 1.9 - there have been a few in the general HTTP-related code - because the 1.8 code looks like this (in MoinMoin.server.server_standalone): httpd = makeServer(config) # Run as a safe user (posix only) if os.name == 'posix' and os.getuid() == 0: switchUID(config.uid, config.gid) httpd.serve_forever() It's quite possible that the underlying SocketServer code in 1.8 binds to a port when the server is instantiated, whereas the WSGI stuff defers that to a later point in time, when MoinMoin.support.werkzeug.serving.run_simple is called. That means that the above pattern ("initialise server, switch user, start server") doesn't work because the code is more like "initialise application, switch user, initialise and start server". So yes, the last part has to be punctuated with a "switch user" somehow. -- PaulBoddie 2011-10-02 15:07:40 ## URL prefix with CGI on IIS Is it possible to hide the url prefix like "/mywiki/moin.cgi/MyPage" when MoinMoin is installed as a IIS CGI ? I have to mention that I had to define something like url_mappings = {'/mywiki/moin.cgi/mywiki':'/mywiki'} Is it the right thing to do (the Howto may be uncomplete ?) ? # User Authentication ## HTTP Basic authentication with IIS Is it possible to use HTTP Basic authentication with IIS? In IIS config GUI, in the properties of my website -> Directory Security Tab -> Authentication and access control Edit.. button, I removed everything except Basic authentication. I'm using MoinMoin 1.5, Python 2.4.2 and IIS 6 on Windows 2003. -- RemyRoy 2006-01-24 21:56:24 • Try like this: from MoinMoin.auth import http class Config(DefaultConfig): user_autocreate = True auth = [http] #... Thanks, it works! -- RemyRoy 2006-01-25 16:21:06 ## Problems with http authentication The docs for enabling authentication via http auth specify adding the following to wikiconfig.py from MoinMoin.auth import http auth = [http] This is misleading. To make http auth work, at the *top* of the file add: from MoinMoin.auth import http And *inside* the Config class, add auth = [http] • It doesnt matter where you do this as long as you indent it correctly (to indent, use spaces (say 4 spaces), not tab/s). Note that it appears that the http authentication mechanism is broken in moinmoin 1.5.7-3. I had to use the method defined at http://moinmoin.wikiwikiweb.de/MoinMoinQuestions/Administration (search for Can apache REMOTE_USER replace moinmoin login?) on that page. Also, the main authentication help page at http://moinmaster.wikiwikiweb.de/HelpOnAuthentication cites wrong code: from MoinMoin.auth.http import http from MoinMoin.auth import moin_session auth = [http, moin_session] should be replaced with: from MoinMoin.auth import http auth = [http] This has already been done (corrected?) at http://moinmoin.wikiwikiweb.de/HelpOnAuthentication Hmm, is it wrong on the new site http://moinmo.in/HelpOnAuthentication ? -- PascalR 2008-01-29 10:49:03 This don't work on MoinMoin 1.7, I get the error 'module' object has no attribute 'name' -- fho This works thx Reimar -- fho ### How to set .htaccess file for HTTP Basic auth with Apache I'm running MoinMoin 1.6 on Apache and Python 2.4.4. My ISP is allowing only FTP access to my /htdocs and /cgi-bin directory, there is only HTTP Basic Authentication and the only way to configure Apache are the .htaccess files in my directorys. I have the moin.py file in the /cgi-bin directory and the rest of MoinMoin is in /htdocs/moin160. In the /cgi-bin directory the Apache configuration trough the .htaccess file does not work. Does the Authentication with HTTP Basic works with .htaccess settings in the /htdocs/moin160 directory? In case it is possible, how should my .htaccess file look like? -- PascalR 2008-01-29 10:49:03 ## How do I implement LDAP authentication through Apache One way to achieve this is to use basic authentication in Apache and http auth in moinmoin (better if you configure ssl in Apache so that password in basic authentication is not in cleartext) I put the configuration produced below inside a VirtualHost directive in apache site-configuration (e.g., /etc/apache2/sites-available/default on Ubuntu; of course, I had first made sure LDAP server was up and running fine and the LDAP module was loaded properly in Apache; also note that in Ubuntu, in the simplest default setup, speaking of version 7.10, the LDAP search query below should have cn instead of uid though that is a bad strategy and you should instead configure LDAP properly and use uid attribute instead of cn; also in case you do not have a domain, Ubuntu will setup the initial LDAP entries under the domain named nodomain instead of somedomain): <IfModule !mod_fastcgi.c> ScriptAlias /MyWiki "/usr/share/moin/mywiki/moin.cgi" Alias /wiki/ "/usr/share/moin/htdocs/" </IfModule> <IfModule mod_fastcgi.c> AddHandler fastcgi-script .fcgi .fcg ScriptAlias /MyWiki "/usr/share/moin/mywiki/moin.fcg" Alias /wiki/ "/usr/share/moin/htdocs/" </IfModule> <Directory "/usr/share/moin/mywiki"> Order allow,deny allow from all AuthType Basic AuthBasicProvider ldap AuthName "Wiki" # tweak this ldap query to return a unique user name AuthLDAPURL "ldap://localhost:389/dc=somedomain?uid" Require ldap-user AnLDAPUser </Directory> <Directory "/usr/share/moin/htdocs"> Order allow,deny allow from all AuthType Basic AuthBasicProvider ldap AuthName "Wiki" # tweak this ldap query to return a unique user name AuthLDAPURL "ldap://localhost:389/dc=somedomain?uid" Require ldap-user AnLDAPUser </Directory> For basic authentication, I also disabled the login/logout link (was no point having it there): see http://moinmoin.wikiwikiweb.de/HelpOnConfiguration to learn how to do it. ## How do I implement LDAP authentication I have MoinMoin setup and running fine...I would like to use our Active Directory server via LDAP to authenticate and create users. I have read a few pages in this Wiki about it but they don't seem to work. Can someone give me some step by step instructions as in which files to edit/download? Thanks in advance. • ldap/ad support is in 1.5.3 including some sample config. ## How do I integrate LDAP authentication with moin moin? (1) I read several pages on this site that MoinMoin can be integrated with LDAP but none of them seem to be explanatory on what needs to be changed, One page lists the wikiconfig other pages just list python code but dont say what file the code needs to be placed in. Can someone please help me with some instructions. Thanks Chris • For information on authentication in general see HelpOnAuthentication. Unfortunately it looks like it hasn't been updated to document the LDAP authentication support. Basically in your wiki configuration you need to add/edit an auth parameter to be a list of authentication methods. This normally defaults to just [moin_cookie]. You need to add in the ldap authentication before that, as import MoinMoin ; auth = [MoinMoin.auth.ldap_login, MoinMoin.auth.moin_cookie]. You'll also need to add quite a few LDAP-specific configuration parameters to tell it how to query/bind to your particular LDAP server. The best thing to do until documentation is written is to read through the MoinMoin source code file MoinMoin/auth.py and look for the ldap_login() function. I haven't used it, but it looks like it wants these configuration parameters: ldap_coding, ldap_uri, ldap_binddn, ldap_bindpw, ldap_base, ldap_scope, ldap_timeout, ldap_name_attribute, ldap_email_attribute. From reading the code it looks like ldap_enconding is the character set used to communicate with your server, such as 'ascii'. ldap_binddn and ldap_bindpw is a user/pass binding for LDAP used for the initial query for the user (once the user is located in your tree, a second bind is performed with the user's DN and the pass-in password). ldap_base, ldap_scope, ldap_name_attribute, and ldap_timeout are used for the initial query for the user--the query filter is something like (UNAM=johndoe) if ldap_name_attribute is UNAM and johndoe is the entered username, and is limited to the tree rooted at ldap_base and within ldap_scope. The ldap_email_attribute names the field which contains the user's email address. -- DeronMeranda When authenticating against Microsoft AD with LDAP username is not casesensitive but MM is. It can cause some trouble like users login some time with lower and some time with uppercase. MM creates two profiles with different settings, so when a User edits a page he might get a diff-email when the other profile has an abonnement on that page. To change all usernames to lowercase add following entries to auth.py These changes are for 1.5.x only, newer versions authenticate another way about line 131 add • if username: username = username.lower() should look like this def moin_cookie(request, **kw): """ authenticate via the MOIN_ID cookie """ username = kw.get('name') if username: username = username.lower() about line 331 (ldap_login) add • if username: username = username.lower() should look like this username = kw.get('name') if username: username = username.lower() after this names in all profiles (data/user) must be lowercase, uppercase should be changed to lowercase. ## LDAP or Active Directory? Is a Userauthentification over LDAP and/or Active Directory possible? Thanks -- Pablo ## http + ldap authentication (NTLM + Active Directory) Autologin with auth.http is working on IIS6 with NTLM (Integrated Windows Authentication). Manual login with auth.ldap_login + auth.moin_cookie works, too. Is it possible to combine these methods to autologin with NTLM/http and get aliasname and email from LDAP? • Yes, you just have to write some code using the existing username (user_obj.name or similar) to make an ldap lookup and update the user object (and save it to disk). If you hack auth stuff, try to use latest moin version. ## How do I integrate LDAP authentication with moin moin? (2) I have seen DeronMeranda post but need more infomation. I understand I have to add the following line in my wikiconfig.py for LDAP authentication from MoinMoin.auth import ldap_login, moin_cookie auth = [ldap_login, moin_cookie] Looking at MoinMoin/auth.py in MoinMoin were do I place the following parameters: ldap_coding, ldap_uri, ldap_binddn, ldap_bindpw, ldap_base, ldap_scope, ldap_timeout, ldap_name_attribute, ldap_email_attribute. • Into your wikiconfig.py How do I debug this? By setting ldap_verbose in the same place as the above parameters ? • Yes. Were do the debug messages appear ?. • Look into apache error.log (if you use apache). Is there any other place I can be pointed to for LDAP authentication in MoinMoin. • There is a sample config in wiki/config/more_samples/ called ldap_smb_farmconfig.py . Be sure to read the comments, as some of the ldap_* variables are required. Help will be greatly appreciated.-- Jehan Why bother with banging your head to get MoinMoin to talk to your Active Directory LDAP server? Use Apache's LDAP authentication module instead, and pass it to MoinMoin's HTTP authentication method! My .htaccess: AuthName "My Wiki" AuthBasicProvider ldap AuthLDAPBindDN " user@doamin.tld " AuthLDAPBindPassword "mypassword" AuthType Basic AuthLDAPURL "ldap://mydc.domain.tld:389/DC=Domain,DC=tld?sAMAccountName?sub?(objectClass=user)" NONE Require ldap-attribute objectClass=user ## How do I integrate LDAP authentication with moin moin? (3) Looking at MoinMoin/auth.py in MoinMoin were do I place the following parameters: ldap_coding, ldap_uri, ldap_binddn, ldap_bindpw, ldap_base, ldap_scope, ldap_timeout, ldap_name_attribute, ldap_email_attribute. • You say Into your wikiconfig.py Can you give me an example of what I need to put in wikiconfig.py for one of the variables lets say ldap_binddn Unfortunately the sample config in wiki/config/more_samples/ is not great at all. • Well, we can't know your ldap setup, but the config you see in ldap_smb_farmconfig.py is a real world example for Active Directory (with the real company name replaced by example.org). You don't need the smb_* stuff btw. If you can read python (it's easy), maybe look at MoinMoin/auth.py -> def ldap_login(... - as you see there, the following happens: • it initializes an ldap connection to ldap_uri • it expands ldap_binddn and ldap_bindpw with some variable content like username and password etc. (this is optional, you also can use some fixed value) • it binds to the directory using this (as that stuff is a encoded string, it uses ldap_coding to encode name and password - this is interesting for non-ASCII characters) • now it makes up a ldap filter string "(%s=%s)" with ldap_name_attribute (where is the username stored?) and the current username and uses this filter to search for that username in that attribute, using ldap_base as base DN and ldap_scope for the scope. • depending on how much hits this search returns, the following will happen: • none: we didn't find the user, auth will fail (as far as ldap_login is concerned) • more than 1: we have multiple users of that name, this is no good (auth will fail ...) • one: great, we found that (unique) username in the directory and can continue • now it will bind again to the directory, using the DN we found in the search and the password given at login • if this fails, it'll break out with an exception like ldap.INVALID_CREDENTIALS (auth will fail ...) • if it succeeds, the password was obviously correct for this username, so we construct a user object now: • we fetch the email address for the user profile from ldap (from ldap_email_attribute) and decode it using ldap_coding • we fetch surname and givenname from sn and givenName attributes and make up the aliasname for the profile using them (this is nice if the login username is cryptic) • the wiki username will be the one given for login • we make sure the cookie_lifetime is honoured, thus the cookie will expire, forcing the user to re-login after expiry • the end, auth succeeded! Thank you Jehan ## Notes for ldaps • Use an ldap_uri like 'ldaps://some.ldap.host', then don't worry about ldap_start_tls (it is ignored w/ldaps URI) • * Be sure that if ldap_tls_cacert{dir,file} are set, they only have the necessary certs • python-ldap seems to move _really_ slowly if you have a lot of CA certificates (at least on Debian ## Ubuntu 9.04, MoinMoin 1.8.2 and OpenLDAP server After following the Ubuntu Documentation on installing MoinMoin (https://help.ubuntu.com/8.04/serverguide/C/moinmoin.html with some minor changes to the Alias entry in the Apache2 config), here's how I got LDAP authentication working on Ubuntu 9.04 which uses MoinMoin 1.8.2 against an OpenLDAP server after installing the python-ldap package (via sudo apt-get install python-ldap). ### LDAP (without SSL or TLS) LDAP with an unencrypted connection was straightforward. I added the following configuration to the end of my wiki config file (/etc/moin/mywiki.py). I've removed all the comments that appeared in the sample LDAP authentication snippet file /usr/share/moin/config/more_samples/ldap_wikiconfig_snippet for brevity. You will definitely need to change the server_uri setting and may need to change other settings such as bind_dn to match your OpenLDAP setup. from MoinMoin.auth.ldap_login import LDAPAuth ldap_authenticator1 = LDAPAuth( server_uri='ldap://ldap.domainname.com/', bind_dn='uid=%(username)s,ou=people,dc=domainname,dc=com', bind_pw='%(password)s', scope=2, referrals=0, search_filter='(uid=%(username)s)', givenname_attribute='givenName', surname_attribute='sn', aliasname_attribute='displayName', email_attribute='mailRoutingAddress', email_callback=None, coding='utf-8', timeout=10, start_tls=0, tls_cacertdir=None, tls_cacertfile=None, tls_certfile=None, tls_keyfile=None, tls_require_cert=0, bind_once=True, autocreate=True, ) auth = [ldap_authenticator1, ] cookie_lifetime = 1 ### LDAP over SSL (ldaps) Using Ubuntu 9.04, I initially tried to get ldaps to work by first getting #LDAP (without SSL or TLS) to work, then to modify the server_uri and tls_cacertfile entries. However, this came back with an LDAP server connect failure error. The problem was that the tls_* config settings that were not being used were set to '' when they needed to be set to None. Commenting them out didn't help as the default values as set in ldap_login.py are also set to ''. I notice that in the current release (MoinMoin 1.8.4 at the time of writing) the default values in ldap_login.py are set to None so that little bug has been fixed. The following settings in /etc/moin/mywiki.py got ldaps working a treat on Ubuntu 9.04 against an OpenLDAP server. You will definitely need to change the server_uri setting and may need to change other settings such as bind_dn and tls_cacertfile to match your OpenLDAP setup. from MoinMoin.auth.ldap_login import LDAPAuth ldap_authenticator1 = LDAPAuth( server_uri='ldaps://ldap.domainname.com/', bind_dn='uid=%(username)s,ou=people,dc=domainname,dc=com', bind_pw='%(password)s', scope=2, referrals=0, search_filter='(uid=%(username)s)', givenname_attribute='givenName', surname_attribute='sn', aliasname_attribute='displayName', email_attribute='mailRoutingAddress', email_callback=None, coding='utf-8', timeout=10, start_tls=0, # ignored when using ldaps tls_cacertdir=None, tls_cacertfile='/etc/ssl/certs/ca-certificates.crt', tls_certfile=None, tls_keyfile=None, tls_require_cert=0, bind_once=True, autocreate=True, ) auth = [ldap_authenticator1, ] cookie_lifetime = 1 ### LDAP with TLS (start_tls) The problem I described in #LDAP over SSL (ldaps) also occurred for me when using start_tls. Here are the settings I used to get start_tls working on Ubuntu 9.04 against an OpenLDAP server. You will definitely need to change the server_uri setting and may need to change other settings such as bind_dn and tls_cacertfile to match your OpenLDAP setup. from MoinMoin.auth.ldap_login import LDAPAuth ldap_authenticator1 = LDAPAuth( server_uri='ldap://ldap.domainname.com/', bind_dn='uid=%(username)s,ou=people,dc=domainname,dc=com', bind_pw='%(password)s', scope=2, referrals=0, search_filter='(uid=%(username)s)', givenname_attribute='givenName', surname_attribute='sn', aliasname_attribute='displayName', email_attribute='mailRoutingAddress', email_callback=None, coding='utf-8', timeout=10, start_tls=2, tls_cacertdir=None, tls_cacertfile='/etc/ssl/certs/ca-certificates.crt', tls_certfile=None, tls_keyfile=None, tls_require_cert=0, bind_once=True, autocreate=True, ) auth = [ldap_authenticator1, ] cookie_lifetime = 1 ## LDAP Groups I want to permit only members of certain LDAP group to logon to my wiki. I have modified auth.py like the following: try: request.log("MEMBER %s" % ldap_dict['memberOf'].index("CN=blob,CN=Users,DC=vmware,DC=com")) except: request.log("NOT A MEMEBER of blob!") else: return user_obj, True if result_length != 1: I thought this would work since if the user is a member of blob, it'll return the user object. But currently, it lets everyone log on, just like before. Any suggestions? • Set ldap_filter (there is a commented out example in the sample ldap config). ## How to require SSL+httpd auth for specific operations I can get SSL+httpd auth working just fine, but I can't figure out how to set things up so that both are required for write/admin/etc access, but neither are required for read access. Any ideas? ## SSL Login Is it possible for just the login/user create/user preferences portion of a wiki to be redirected to a secure link, but all other pages run in a non-encrypted fashion? -- MichaelLaccetti 2007-02-27 05:19:02 • No, and if you use moin's cookie stuff, it wouldn't make much sense as the cookie transmission happens on every request and would need protection also. • Even if they shared the same URL; just used https:// for login? Cookies work for the same domain, regardless of encryption. -- 74.100.133.5 2007-03-01 04:55:22 How can you configure moin to require SSL for everything (On apache)? It seems to ignore the RequireSSL flag in httpd.conf. -- Alexander Faucher <<DateDate()>> ## Embedding MoinMoin -- Automatic User Login? I'm looking to embed MoinMoin into an application that uses php, and I was wondering how I could go about using php_session for a single sign on integration. I see that it's currently only supported with eGroupWare 1.2, but examples on how to use php_session to extract session info seems to not be around, as well as trying to get it to work for another application. Any help here? Thanks in advance. StevenM 05-Mar-2008 I'd like to use MoinMoin as a Wiki-based knowledge base by opening an appropriate URL from inside an application. Since my application has a user database built-in, it is necessary to promote the user ID to the wiki. Provided that the MoinMoin user IDs are the same as the application's: Is it possible to embed the user ID (and, optionally, the password) into the URL of the wiki page to be shown? Thx... StefanK 14-Dec-2006 • Look at MoinMoin/auth.py (and there is also some old code for 3rd party cookies in contrib/ in the MoinMoin archive) I needed similar functionality to hook salesforce.com into MoinMoin as a knowledge base. Another use for me is for a phone/email list page for my neighborhood. While I don't want to force everyone to create a user profile and login just to get to the phone number list, I also want to deny access to anonymous Internet users that might happen onto my site. I found (url) which has the format for logging in with a one-click URL. One-click login requires this format: http://someserver.org/moin/moin.cgi/HomePage?action=login&name=somename&password=yourpwd&login=login Now I can create a standard 'guest' account and email the one-click URL. The page will be fairly safe from anonymous Internet bad people and the intended recipients have a good end-user experience.- CraigA 4/1/2007 Feedback: the discussion link above showed the way for me: I had to disable the POST-only check for the login action (userform.py, approx. line 90). Now simply GETting the URL works fine. Thank you very much! StefanK 21-Feb-2007 Feedback: This was the best bit of information I have found on the web for a while, works like a charm. Thank you so much for reposting it from the MoinMoinChat link. DominicF 03/12/2009 ## How can I implement single login for a farm I would like have users log into all wiki in our farm form one login. The users accounts are already shared across the farm but you have to login to each instance spereratly. I did try setting cookie_domain = 'mainwiki' but this just prevented login form working. I am not sure that I used it correctly. We are using moin in standalone with one main wiki (mainwiki), and some project specific wikis (projecta.mainwiki and projectb.mainwiki). Cheers, -- ManuPoletti 2008-04-29 00:59:43 I have got the same problem. We run a wikifarm with many wikis. But the question now is: What do i have to do, that one useraccount is able to write/revert whatever in every wiki? Madis R. 09-Sep-2008 Solution: • Optional: Create a single wiki for the user homepages. Use also user_homewiki to configure that all user homepages are saved on the same wiki • Put all the userdata into a same directory (use the config user_dir) • Use the same cache dir for all farm wikis (use the config cache_dir) • Now you can configure the session cookies to use the same cookie_domain and also use the same cookie_path. for more information see HelpOnConfiguration and here HelpOnSessions, bye -- MarcelHäfner 2009-04-04 08:04:02 In answer to my previous post (2008-04-29) you need to set the cookie_domain config item to be the common part of the domain name that your wikis will share. -- ManuPoletti2013-06-19 04:56:23 ## How do I integrate LDAP authentication with moin moin? (4) I have combined LDAP/AD authentication with moinmoin auth for cases when the user is not listed in AD. Firstly, I just added config data from samples followed by auth = [my_ldap_authenticator, MoinAuth()] line. But I discovered that if the user connected to LDAP successfully, but could not be authenticated there then according to the auth/ldap_login.py the authentication stoped with CancelLogin . When I replaced that line with ContinueLogin , like it is implemented for ldap.SERVER_DOWN exception then everything worked fine. So I wonder why don't developers use ContinueLogin for ldap.INVALID_CREDENTIALS too? -- AlexanderAgibalov 2009-06-30 13:40:55 I thought the usual usecase for LDAP it that it is authoritative about who is able to login and who not, thus it does not set the continue flag if someone is not in the directory. -- ThomasWaldmann 2009-06-30 18:06:58 OK, I see. Then I'll just apply this patch myself for every upgrade of my wiki. The reason why I need this is that we have corporate users who are listed in AD and several contractual employees who are not. Currenly we are using native authentication, but people continue to constantly forget not only their passwords, but usernames too But they always remember their AD credentials. -- AlexanderAgibalov 2009-07-01 11:02:18 I have the same usecase for LDAP fall through to native moinmoin authentication, external contractors mixed with AD users. -- diepes 2012-09-11 10:58:55 ## Authentication drops on IE8 Some users of my MoinMoin 1.8.4 (seems that this mostly concerns users with limited windows accounts) after upgrading to IE8 experience the following problem: they login sucessfully, then navigate to any page and their authentication drops for no reasons, so they have to re-login. Earlier it helped to switch to the IE's "Compatiblity view" (couldn't find how to save this setting), but it seems that with some recent IE patches this doesn't work anymore for most of the users. So I wonder what's the problem is and how to fix it? Any chances that this is fixed in moin 1.9 ? -- AlexanderAgibalov 2009-11-05 08:08:55 The "logged in session" depends on moin's session cookie. So maybe try clearing all moin-related cookies from the user's browser and then log in again. If you can reproduce the problem, please file a bug giving all details about how to reproduce. Whether it works better with 1.9 you could check with 1.9.0rc1 (I don't remember fixing anything related to that, though). -- ThomasWaldmann 2009-11-05 08:20:24 At last found a virtual machine where I experience the issue myself. Discovered that the problem is solved by cleaning up the user Cookies directory MANUALLY. Using the native IE's cleanup mechanism doesn't help. A bit surpised by the cause of this behavior. -- AlexanderAgibalov 2009-11-06 12:03:58 # Permissions and ACL related ## allow 'admins' to delete/overwrite attachments? At the moment only superadmins are allowed to delete or overwrite attachments on our page, is there any way to configure a 1.8 moinmoin to make this possible for normal admins/special usergroups? Tried several searches here on that theme but wasnt very successfull as it seems. • I don't think your problem is related to "superuser" configuration, but rather a standard ACL problem. For deleting or overwriting (which is deleting and writing) attachments, you need to have "write" and "delete" rights on the respective wiki page. If you are not logged in, you usually don't have "delete" rights. If it still does not work after logging in, check your acl_rights_* configuration and the ACLs on that page. ## Disallow removal of own admin permission Users often make mistakes editing ACL strings and inadvertantly change the page permission such that they cannot revert the change. There should be a configuration option disallow removal of your own read/write/admin permission on a page. Or maybe a confirmation dialog warning them that they are about to remove their own permission from the page. -- VitaliyShchupak 2008-07-20 11:48:22 • This is why you don't give admin rights to users not capable of correctly using it. -- ThomasWaldmann 2008-07-20 12:10:37 ## Is it possible to disable read on ALL pages except login? I want to prevent viewing of every single page (all, even the help pages) in my wiki. Users in a certain group will be able to view pages after logging in. The problem is that many pages (Help, recent changes, etc...) specify read for All in their ACL. The only way to override that is to specifly no privs for All in acl_rights_before, but then that would block everyone from the login page too. The FAQ above for closed community says to use acl_rights_default and set All : blank, but that won't stop people from seeing help and recent changes. Is there any way to do this other than to edit every page in the system to remove the All : read line? • You have two options: 1. Change the ACL of all problem system pages and add All: to block anonymous users. You want to do this change with a script, so you can fix the ACLs after upgrading the system. 2. Write custom SecurityPolicy that block anonymous users on all pages expect the login page. This should be easier and avoid upgrading issues. System / Help page ACLs were changed in moin 1.7 (they just take away "write" rights now and otherwise use Default ACLs. So if you change your default ACL, the change is also implemented by the system / help pages. ## Why is block all except login possible with the following scenario? In MoinMoin ver. 1.6.0, with acl_hierarchic = True and acl_rights_after = u"All:", the above (block all pages except login) is accomplished. We have acl_rights_before set to allow a specific admin group all privileges, and acl_rights_default set to allow a user group read,write,delete,revert. Only users in either the admin or user groups can view pages at all. My question is, why does this work? Is it a bug or a feature? • Sorry, I have trouble to understand your question. • There is a bug in hierarchic ACL processing, see SecurityFixes. <- That's why it's behaving in that manner. Thanks. • Strictly taken, using "All:" ACL doesn't make much sense (it does no harm, but it is not necessary). ## Administrating ACLs is cumbersome Here's what I want to do. I want a certain user to be able to manage ACLs for a certain area of the wiki... say everything under a certain page. Without any hierarchical access control scheme, I can't just give him admin rights to the top page and let him go. It means that every single page he creates that needs any sort of access control, I have to go and manually add them to each page ONE AT A TIME! This is not only an annoyance for me, it also slows him down. So I came up with an Idea I thought might work... Create a template that contains an ACL line giving this author admin rights, and restricting read rights so that only he has access to that template. I thought this might allow him to create pages by basing them off of this template. But alas, it appears that creating a page from a template amounts to a cut and paste of the text from the template, so non-admin types are not allowed to "add" the ACL's to the new page (even though they were already granted in the template). Does anyone know of a way to give someone the ability to create certain pages with them as an admin, but without giving them admin rights to the entire wiki? -- SteveDavison 2007-03-01 22:03:43 ## You can't change ACLs on this page since you have no admin rights on it! I get this error msg when I try and save a newpage w/ ACL's on it and I the TrustedGroup has admin rights to both. Here's the ACLs on the page #acl TrustedGroup:read,write,delete,revert,admin Here's the ACLs on the template for the new pages created by this group #acl TrustedGroup:read,write,delete,revert,admin the result is the new pages fail to save w/ this error You can't change ACLs on this page since you have no admin rights on it! thanks in advance --Andrew • I added acl_rights_before = u"admin:admin,read,write,delete,revert TrustedGroup:admin,read,write,delete,revert" to the wikiconfig.py and trusted group can add pages now! Seems that before doing this TrustedGroup could admin, edit pages, edit the ACL lines on the pages, just not save a new page w/ an ACL line included. Not sure if a bug or pilot error... ## Lost Admin Rights? I think I'm in over my head. I am completely new to wikis. But yesterday I set up a wiki page and specified myself as the administrator. I then set up a users page, and I went to edit one of the names I listed, and it said "You are not allowed to change this page." I can't figure out what happened. Thank you -- Laura 19 Dec 06 • The page HelpOnAccessControlLists in your wiki describes how it works. Keep in mind that "admin" right only means "being able to change ACLs", it does not include any other right like "read" or "write". ## attachments only for certain users Is it possible to finetune ACL to allow anonymous and new registered users to edit the page but WITHOUT the permission to add attachments. and add an ACL rule to each user that should be allowed to add attachments. thank you for your responds. HatschMa 01/12/2006 Not with a standard moin, it just uses the page ACLs for the page's attachments. For moin 1.5 you could patch AttachFile.py to not check for "write" rights, but for "attachwrite" right and add that right to the valid ACLs list. In some future moin version (not 1.6), file attachments will be first class items with own ACLs. ## Project group members need permission to create new group pages? I set up some independent groups, each one with it's own adminstrator. The default permissions permit Known users to read/write/edit but not admin for default pages. I set up templates for each group that allow the group to read/write/edit their pages and their admin user to read/write/edit/admin. I find that the group users get a "you can't change the permission of this page" when they try to create a new page using the group template. Is there a trick here to make that work? Is that what AutoAdmin is for? Many thanks in advance for your help. • Any suggestions about where to look on this one? 2013-06-19 04:56:23 ## How to change a protected page into a non protected page In my local wiki (MoinMoin Version 1.5.2 on IRIX64) the page WikiSandBox is a protected page ("Geschützte Seite"). Even though I have administrator rights I did not found a way so that any user can experiment with this page. What can I do to change the status of this page? • How are ACLs configured in wikiconfig.py? • acl_rights_default = u'StudentGroup:read,write,delete,revert All:read' acl_rights_before = u'AdminGroup:read,write,delete,revert,admin ' I belong to the AdminGroup but I cannot edit this page, too. • Is there an ACL line in your WikiSandBox? • I think it is the default WikiSandBox without any ACL and because of this problem I had no chance to modify it. (Of course you can change the source code via the operating system.) It has the following lines in the beginning of the page: {{{## Please edit system and help pages ONLY in the moinmaster wiki! For more #format wiki #language en (...)}}} • Maybe check filesystem access rights for the underlay directory. And probably who is the owner of this dir and who is the owner of the webserver process. Does it match? I made some tests varying owner and file permissions but had no success. It remains protected. I solved the problem for me by copying the directory WikiSandBox manually from underlay/pages into the data/pages directory and changed its file permissions according to other files in this directory. Beside my special problem I have some difficulties in understanding the general concept of the underlay directory. I understand that pages in this directory are normally read-only and should not be altered by users. There are only few exceptions like e.g. the WikiSandBox. But what do you have to do when you like to change such a page (in a perfect installed wiki setup). How do you change the state of a page from "protected" to "non-protected"? ## Adding Myself As An Administrator I just installed the latest stable version of Moin on FreeBSD + Apache in my$HOME directory on a shared web server. Everything is working very well except for the fact that I can't act as an administrator in my wiki.

I found the MoinMoinQuestions/Administration "How To Become An Administrator", and followed its directions. First, I registered with the site using a username of TomPurl. I then checked the $INSTANCE/data/user directory and made sure that the TomPurl username existed. I then added the following line to$INSTANCE/wikiconfig.py:

I then logged into Firefox, but was unable to delete, rename, or add attachments to pages. To troubleshoot, I deleted all of my cookies and then logged in again. Still, no luck. I've even restarted Apache.

Can anyone else think of something that I could try to get this to work?

Thanks! - TomPurl

• probably you have missed to set

allowed_actions = ['DeletePage', 'AttachFile', 'RenamePage']

in your wikiconfig.py -- ReimarBauer 2005-12-30 18:19:39

## How to prevent user-creation?

I don't want to have any users except me. I'm running Version 1.5.0beta4, so that http://moinmoin.wikiwikiweb.de/FeatureRequests/NewUserCreationACL won't run. (i tried everything, but i didn't get it)

• I can't find anything on that page that mentions disabling user creation. The login page seems to double as an account creation page. I need access to a login page, but not account creation. How do we fix that?

• Strange that this is a new feature - nobody wants his Wiki to be potentially spammed by billions of bots or something. Should be a basic feature

• I've set the ACL on UserPreferences for All to nothing ("All: ") while keeping rights for registered users ("MoinPagesEditorGroup:read,write,delete,revert"). It seems to me that this lets people still login but disables creating new user accounts. Am I missing something?

I'm doing a wiki page for a company. My boss will be the admin, got all the rights etc. This wiki will not be edited by unknown people, only the users that my boss allow. How do the admin add the users to a group or what? Thanks.~

## How do I set the limit on the size of attachments?

MoinMoin does not offer this facility, but if you use apache >= 1.3.2 then you might like to look at the LimitRequestBody directive

## Prevent Editing When Not Logged In

I've searched and searched for how to do this, but can find nothing. I think the ability exists, since I have seen mention in several other questions of someone not being able to edit a page because they are not logged in. Are there instructions anywhere that describe how to configure MoinMoin to require login for edits? Thanks. --SteveDavison

## Disable overwriting attachments for common users

Common users (anonymous and logged in) can't delete attachments, only administrators can do that. Which is good, because these changes can't be reverted. But I found out that anonymous users can overwrite attachments with whatever they want, it's enough to check "Overwrite existing attachment of same name" checkbox (moinmoin 1.5.7). This way evil anonymous users can destroy all my images/other attachments on my wiki in a few minutes, and I cannot revert it. How can I disable overwriting feature for non-admins? --Kamil

## Changing ACL-Rights on user-created pages without giving every user ACL-'admin' rights on the whole Wiki?

I want to make it possible for normal Users to set ACL write-permission only for themselves on their pages, to create a simple Character-Database ( http://mylairexil.de/wiki/CharakterSeiten ) is this possible without giving every ACL-'admin' rights for the whole wiki, and without intervention of an Admin or TrustedUser on every Charpage?

You should define "their" pages. Moin does not have the concept of page "owner". However, if you to give write access to sub pages of the user page, you can do this with a custom security policy. Subclass MoinMoin.security.Permissions, and define a write method that check the current page name against the current user name and allow only the user to write on his sub pages ignoring the page ACL. See SecurityPolicy for more info.

Version 1.5 has autoadmin security policy that give admin rights to user pages, but it is not recommended for common users, because they will not be able to set ACL correctly. see HelpOnAutoAdmin.

• I am confused about this as well. "their" := the page they created. This is a variation I need: I want to be able to approve the potential users when applying. However, once someone is an user, they should be able to create "private" pages (e.g. set their own permissions and edit the list of users who are 'collaborating' on the page). Is this possible? Thanks! -- ranko

## Cannot get AutoAdmin to work

I want to enable users the ability to setup their Homepage using the HomepageTemplate with a pre-defined ACL. To do this they need 'admin' rights. I am using AutoAdmin and below is what I did

1. Added the following line to wikiconfig.py, using Moin version 1.6.1

But it does not seem to enable 'admin' rights. Am I missing something, can you help?

Kim Tran - 2013-06-19 04:56:23

## Also cannot get AutoAdmin to work

The HelpOnAutoAdmin page is woefully inadequate. It mentions things but does not explain them fully or even tell you what they do.

Are page/ReadGroup and page/ReadWriteGroup supposed to work on projects as well as users? And how do you get them to work?

I can only assume that if a user is in ReadGroup or ReadWriteGroup that they are able to read all subpages by default, and the ReadWriteGroup also can edit. But I set up the ReadGroup and ReadWriteGroup pages with nothing in them, and I can still see and edit all of the subpages. Do I have to add ReadGroup, etc., to the AutoAdminGroup page as well as the page/AdminGroup in order to activate them?

HelpOnAutoAdmin mentions that you can set up project/ReadGroup, project/ReadWriteGroup, etc., but doesn't say what the "etc." includes. Can I create a project/RevertGroup or project/DeleteGroup? Or what about a WriteRevertGroup?

And another thing that needs explanation is, how exactly do these groups affect the ACL's of a page? Is it sort of like an automatic #acl +ReadGroup:read +ReadWriteGroup:read,write +AdminGroup:admin added to each subpage? If the subpage has its own ACL line, does this prevent the AutoAdmin ACLs from working (i.e., do the automatic rights work like "default", "before", or "after" ACL rights?

Oh, I should mention that I'm using version 1.5.8; I checked the latest HelpOnAutoAdmin and it seems to be identical to the 1.5.8 page, so I assume there haven't been significant changes since.

Thanks for any help... -- SteveDavison 2008-07-03 04:52:36

## NewPage macro + ACL = You are not allowed to edit this page

I am using Moin 1.7 and am trying to set it to use the NewPage macro to make structured page creation easier on the users. I also have ACL's (hierarchic, if this matters) enabled. Now a certain user belonging to a certain group can easily create sub pages, perform edits, and do what they need to do. However, when they try to perform this task through the NewPage macro they get an error that says "You are not allowed to edit this page." As I have said before, creating this page and loading the proper template by hand works just fine. I don't know if this is the proper avenue to have this question answered but any help would be appreciated.

Cameron

## Groups in ACL are ignored

Just updated from 1.5.5a to 1.7.1. To be more precise, old wiki was on Windows server with IIS and CGI. Then I installed 1.7.1 on Linux machine with Apache and fastcgi. Copied ./data, removed cache, removed all old macros, parsers and themes, performed pages migration. I took wikiconfig.py from the new distro and updated it accordingly.

I have very tight security policy with lots of groups. Now after upgrade only users who are specified explicitly in acl_rights_before, acl_rights_default or in a page's ACL get proper authorization. If user is the member of some group then he doesn't get authorized despite this group being mentioned in ACL. Look like group membership is just ignored.

I've tried switching acl_hierarchic off, searched through this site, read CHANGES and MIGRATION documents, looked in the sources, but still can't find the cause of the problem.

• You likely missed the part of docs/CHANGES talking about page_*_regex configuration having changed. If you just need the usual "for English" behaviour, you can just delete all those regexes from wiki config. If you need to have it recognize something complex (like e.g. matching group page names for different languages), you have to read docs/CHANGES. -- ThomasWaldmann 2008-08-11 12:19:17

• Well, I did really miss that part. But all the pages in my wiki have English names, so I didn't get any positive result after editing or disabling those regexes.
• Do you have stopped the server and cleaned the old dict cache? You can verify as superuser using the SystemAdmin page if all works after you had restarted the server process. -- ReimarBauer 2008-08-11 14:29:00

• Yes, I tried both /etc/init.d/apache2 stop/start and apache2ctl restart. Cleaned cache manually by removing everything from ./data/cache before server restart. On SystemAdmin page I can only see user accounts and list of attachments. -- AlexanderAgibalov

2008-08-12 05:49:07

• Can you pastebin your wikiconfig.py? And please check if the timestamp of the pyc file is newer as the py file. I don't know what is wrong yet but it is easier to figure out if you meet us at chat.freenode.net #moin. -- ReimarBauer 2008-08-12 18:36:28

• Here it is. I removed all the commented lines. .pyc file is recreated each time after I make changes in .py -- AlexanderAgibalov 2008-08-14 06:55:40

# -*- coding: utf-8 -*-
from MoinMoin.config.multiconfig import DefaultConfig
class Config(DefaultConfig):
sitename = u'Ext.Wiki'
logo_string = u'<img src="/moin_static171/common/moinmoin.png" alt="MoinMoin Logo">'
page_front_page = u"FirstPage"
data_dir = '/db/extwiki/data/'
data_underlay_dir = '/db/extwiki/underlay/'
url_prefix_static = '/moin_static171'
superuser = [u"AlexanderAgibalov", u"GrigoryBaytsur"]
acl_hierarchic = True
surge_action_limits = None # disable surge protection
navi_bar = [
u'%(page_front_page)s',
u'RecentChanges',
u'FindPage',
u'HelpContents',
]
theme_default = 'modern'
language_default = 'en'

#page_category_regex = u'^Category[A-Z]'
page_category_regex = ur'(?P<all>Category(?P<key>\S+))'
page_dict_regex = u'[a-z]Dict$' page_form_regex = u'[a-z]Form$'
page_group_regex = u'[a-z]Group$' page_template_regex = u'[a-z]Template$'

show_hosts = 1

Remove the old rules or use the new syntax for

page_dict_regex = u'[a-z]Dict$' page_form_regex = u'[a-z]Form$'
page_group_regex = u'[a-z]Group$' page_template_regex = u'[a-z]Template$'

see * HINT: page_*_regex processing had to be changed to fix category search. in the CHANGES file or look into MoinMoin.config.multiconfig. e.g.

page_category_regex =  ur'(?P<all>Category(?P<key>(?!Template)\S+))'
page_dict_regex = ur'(?P<all>(?P<key>\S+)Dict)'
page_group_regex = ur'(?P<all>(?P<key>\S+)Group)'
page_template_regex = ur'(?P<all>(?P<key>\S+)Template)'

you can remove the vars completly if they are the defaults. -- ReimarBauer 2008-08-14 09:05:37

Note that this doesn't make too much sense:

Reasons:

• there is no ACL right called "none"
• what you likely want is to not give Known and All any rights
• you do that by just not giving them any rights
• if you don't have a conflicting ACL otherwise, it is enough to not mention Known and All
• if you don't explicitely give some user or group some rights, they won't have rights (note that the internal default of acl_rights_default DOES give Known and All group some rights, but for your case this does not matter as you are overriding acl_rights_default)
• if Alexander is in acl_rights_before and gets all rights there, you don't need to give him rights in acl_rights_default
• not sure what your MxGroup ACL settings are for. Looks like you want to give them read and write rights ever (you don't need to repeat that in default ACL), but delete,revert,admin only by default if the page ACL does not override the default.

Thus, you maybe want this:

• Oh. You were right since the beginning. The problem was indeed with regex. Sorry for wasting your time. -- AlexanderAgibalov 2008-08-14 13:18:49

## Groups are ignored in ACLs

2008-09-09 FrankSteinhauer
I have the same problem as AlexanderAgibalov (and Cameron) above - my Groups seem to be ignored. We're using MoinMoin 1.6.2.

From wikiconfig.py:

#commented out the page_xxx_regex lines

Page TestApprovalGroup: (created by a member of the AdminGroup)

=== All members of the ACL group "TestApprovalGroup" ===
* SomeUser (part of the test department)

<<BR>>
----

Now SomeUser is not allowed to change the page TestApprovalGroup. Furthermore, he's not able to create a new page and set any ACLs. This looks like a "feature", since he has no admin rights yet he's not allowed to give himself the admin rights - but still it's strange. Now I have to add all "XxxApprovalGroup"s to the acl_rights_before

What is the approve right? Have you restarted the server process after removing the page_*_regex and do you have cleaned the dict cache? -- ReimarBauer 2008-09-09 15:41:34

## After upgrade to 1.9.2, from 1.8.1, acl_hierarchic does not work the same

The pertinent lines of my wikiconfig.py file are:
acl_hierarchic = True

I have a page called DnD, for which I want admins to have full rights and players and DMs to only be able to read. It has the ACL line:

I have a child page called DnD/DMs, for which I want admins to have full rights, players none, and DMs to have read and write access. It has the ACL line:

I then have grandchild page DnD/DMs/DragonLance, for which I want admins to have full rights and players and DMs none. It has the ACL line:
#acl DnDDMsGroup:

Everyhing was working fine in 1.8.1. After the upgrade, admins can no longer access the child page nor the grandchild page. Oddly, players can access the grandchild page.

What happened?

# How it looks, using Themes

## MoinMoin favicon not showing.

I am using 1.9.3 remotely on a shared hosting account and the default blue/white MoinMoin favicon will not show up (it does show using Desktop Edition on my MacBook). How do I get the icon to show on tabs and bookmarks? I saw some config files around here about adding the html_head line but that did not work.

what does the server logs tell, where does it look for the favicon? May be it is only a wrong url/path.

• It was paths, I was taking the html_head code too literally as a default configuration, I had to add an additional directory per my installation needs. It works great, little icon shows up, thanks.

## Resize and position of <div id="page">

I'm triyng to change the css properties for DIV layer id="page" but it seems to be sticky. I'm not able to resize or move it around. Any idea will be appreciated.

I'm trying to setup a multi-lingual wiki site. I want to add several links on the navigation bar. But unlike the links of system and help pages, the links I added can not be recognized as multi-lingual by default. How can I enable this function to my own links?

• To have multi-lingual in the navigation bar, a translation of the pagename must be in the translation files, and a page with that name must exists. You need to create your own translation dictionaries. See HelpOnLanguages how to do that.

Is there any way to disable the username|login link that appears at the top right of the page next to the search box in the 'modern' theme?

• You need to modify the theme.

## Where can I suggest changes to the default (modern) theme?

Open a MoinMoinBugs or FeatureRequests page. If nobody cares about your suggestion, create your own theme and publish in on ThemeMarket.

## How can I edit the Editor Page?

I like to edit the Editor Page. More precisely, I like to add some more syntax examples, (e.g. for line breaks ''BR'' or @SIG@.) So how can I configure that info on the Editors page?

• editor_quickhelp in your wikiconfig (see MoinMoin/multiconfig.py for details)

## Problem configuring with non-default Theme

I am trying change the theme of RUSLUG wiki. In the process, I seem to have broken the themes. I cannot debug the problem. I've tried both re-creating the instance from scratch from the directions from Gauss. I also removed the debian moinmoin-common package and reinstalled, but the wiki still seems unhappy.

My problem was solved, the solution is here HelpOnInstalling/TroubleShooting. I had url_prefix set to the ScriptAlias rather than the Alias in the wikiconfig.py for my instance. Maybe there should be a strong negative comment (NOT ScriptAlias in Apache) to prevent further confusion?

## How to add info to immutable installation pages?

I developed a way to use MoinMoin from under IIS (MoinMoin ISAPI) and suppose it should be included in the IIS installation pages that I can't change. Whom should I ask for it?

How is it possibile to link the logo_string to a different side and not as on default to the wiki itselfs? -- ReimarBauer 2005-11-13 09:52:17

## How can I include a "rollover" effect in tables?

What is the correct style coding for changing the background colour ofa table (whole, cell or row) when the mouse hovers over it? -- Thanks,Casethejoint.

• Modify the CSS on the theme and use pseudo classes in there.

## Using MoinMoin as a filter

I would like to be able to write some static website content in wiki markup without making use of the editing, revisioning, etc. aspects of a full wiki. Can anyone give me some pointers on how to apply Moin's markup-to-HTML transformation from a Python script? Cheers!

• look at the theme modern_cms this comes nearly to the aspect you want. You could suppress some more things if you want

## FrontPage

Hi all, how do I remove the title FrontPage at my FrontPage, whereby when you click it, it will do a full text search. Thanks.

• The page name you see there is an important part of navigation and should not be removed. If you insist on removing it, write your own theme (inherit most stuff from ThemeBase or modern theme).

## How can I change the page title layout?

I use the Mentalhealth theme but dislike the way the page title is displayed at the top, it appears as a bulleted list item... doesn't stand out much!

• Clear your browser cache. If it doesn't help, the theme isn't ready for 1.5. To see the changes from whatever version you used before to 1.5.0 maybe simply use diff -ur old/wiki/htdocs/modern 1.5/wiki/htdocs/modern. Esp. the header stuff changed from lists to spans. -- ThomasWaldmann 2006-01-18 09:34:55

• I actually don't have any older version. Just curious how to patch existing theme to work with current version. Is there any document on porting thems to version 1.5? -- PavelAntokolsky 2006-01-18 13:16:49

I like the way the Modern theme displays a large title, could someone please point me to which file/lines to copy from the modern theme to replicate the effect in Mentalhealth? I had a look but couldn't find it. Actually I couldn't even find the modern.py which I would think is where I should be looking.

• See MoinMoin/theme/ directory. The css is in wiki/htdocs/modern/css/. The stuff you look for is "location", "trail", etc. - some stuff changed from <li> to <span>.

• Thanks, that helped, had to change the <li> so that it doesn't look like an <li> at all - like so: #pagelocation li {display: inline;}

This is how it is currently looking (Mentalhealth theme), which I don't like:

This is how the Modern theme displays the same thing (as best I can do with the formatting), which I do like. (This is the located just above the page trail):

As a side note, I really like the way the title in moinmoin.wikiwikiweb.de appears, but it seems different from the modern theme in the latest MoinMoinDesktopEdition. I guess I have to wait for the next release?

-- DanielMundy 2006-01-11 04:40:27

## Different theme.py for sub-pages?

One of my customisations to the Mentalhealth theme was to add a .png image to the top of the right-side-bar. I've noticed that on my sub-pages, eg. HelpOnEditing/SubPages, the image does not appear. Any ideas? Thanks, -- DanielMundy 2006-01-13 01:05:00

• What is the URL you are using for the image? It should be absolute (starts with a "/"). Even though the moin storage backend does not treat the slash in the page/subpage in any special way, your browser will. So if you have a relative URL the browser will itself compute an equivalent absolute URL based upon what it thinks the current "directory" is. Obviously for a subpage this will result in a different URL, and likely a broken image link. -- DeronMeranda 2006-01-15 07:39:00

• Thanks, that was exactly the problem. -- DanielMundy 2006-01-15 22:49:43

## override default theme for one page

Is there a way to override the default theme on one page using the editor, i.e., without configuration file changes? For example, if a wiki is using classic as the default theme, can I cause it to use modern on a page simply by inserting code when I edit a page? Obviously I can change it in my preferences, but I need to change the default theme on one page so it will display even for users who are not logged in. -- 24.205.227.69 2007-03-21 20:07:56 (ps - this page, MoinMoinQuestions, is way too large and as a result has serious performance issues, could be broken up?)

You can add an argument to the macro described at ThemesMacro. -- ReimarBauer 2007-03-21 22:55:28

Actually, I can't add an argument to the macro, I don't have access to the config files -- I'm a user of the wiki, not an admin. Now that I think about it, it's probably a good idea that users can't make changes of this type via the editor. Thank you for the suggestion. -- 24.205.227.69 2007-03-24 19:24:27

## Mouse Over ToolTip Possible?

I've converting from FlexWiki to MoinMoin. One of the nice features in FlexWiki is the ability to have a Summary defined for a topic. That summary is an attribute of the topic; when you put the cursor over a link to that topic the summary comes up in a tooltip.

Is this possible in MoinMoin?

• No, not yet. But you could check whether we already have a FeatureRequest for that and if not, create a new one for that (and remove the text from here). -- ThomasWaldmann 2007-05-08 18:11:45

I am new to MoinMoin, but in order to transfer an existing site, I must be able to have a textbox as in Wikipedia. Do I have to modify the py-files?

Do you ask about getting a frame around a table and that aligned to somewhere? If so do have a look at ParserMarket/Frame.

A little more complex... A table right-aligned that is fed by values, where the parameters shall be fed from an "easy to fill" list in the page... Ideally, the parameters/values should be matched with a MySQL-table, but that is anything but urgent. The implementation of an "infobox" is... I had a look also at macro/CardMacro, but seem to have a "logical problem" interpreting it to do what I want it to do...? Can one combine these two (and how)? I am "just a web developer" with an Admin handling the technical side of Moinmoin for me... I could write the code for the static page (using PHP to handle the variables), but am "lost" with MoinMoin... Thanks for any help.

## Who viewed what page?

It would be very useful to be able to evaluate who is accessing what pages and how often. It's not so much to play "Big Brother" and profile individual users, but the hits data as it stands is pretty useless (IMO). When someone is working on a page and editing it regularly, it creates so many hits that it's impossible to tell if anyone is actually making use of the pages, or if we're just writing in our secret diaries. So if we could at least filter out the known editors of a page, the remaining hits would be meaningful. Further, being able to see who is viewing the page can give us an idea of what teams are making use of the information, and help to weed out multiple hits from the same person. (If one person views the page 10 times because they are navigating between different pages or opening/closing browsers, it really doesn't mean they're getting 10 times the use out of the page, and is not nearly as significant as if 10 different people were using the page.)

I noticed in the edit-log, the editor information is stored, but I could not make out anything that looked like identifying info. in the event-log. Is this tracked in any way? Thanks. -- SteveDavison 2007-03-01 10:35:18

## Is there a way to configure MoinMoin, that it shows existing attachments directly at the end of the page?

I think, not everybody will notice, that there are attachments on this page. Therefore I tried to change this behaviour but did not managed to. Thx for help

• [[AttachList]] macro evaluates to the list of attachments of the current page. Insert this macro in any place on your page you want and they're all visible.

I'm having the same problem, so let me rephrase the question: Is there are a way to get an attachment list like the one generated by [[AttachList]] automatically at the bottom of every page that has attachments? Thanks! -- MichaelSchuelke

In principle, you can add something similiar as this to Page.py, before endContent. This patch is currently for 1.6. -- ReimarBauer 2007-05-25 13:59:12

wikiutil.renderText you can get from the MiniPage at MacroMarket for 1.5.x versions.

--- a/MoinMoin/Page.py  Wed May 23 17:41:00 2007 +0200
+++ b/MoinMoin/Page.py  Fri May 25 15:44:36 2007 +0200
@@ -1091,7 +1091,7 @@ class Page(object):
request.write(self.formatter.startDocument(self.page_name))
if self.default_formatter:
if self.rev:
@@ -1159,6 +1159,8 @@ class Page(object):
from MoinMoin.macro.FootNote import emit_footnotes
request.write(emit_footnotes(request, self.formatter))
+            from MoinMoin.parser.text_moin_wiki import Parser as WikiParser
+            request.write(wikiutil.renderText(self.request, WikiParser, '[[AttachList]]'))
# end wiki content div
request.write(self.formatter.endContent())

Simple solution for 1.5.8: edit Page.py to add a couple lines around line 1264 like this:

# check for pending footnotes
if getattr(request, 'footnotes', None) and not omit_footnotes:
from MoinMoin.macro.FootNote import emit_footnotes
request.write(emit_footnotes(request, self.formatter))

from MoinMoin.parser.wiki import Parser as WikiParser
WikiParser('[[AttachList]]', request).format(self.formatter)
# END NEW STUFF

# end wiki content div
request.write(self.formatter.endContent())

## Moin in frames

Hi, I would like to know if somebody has tested Moin as part of a frame or something similar. I am thinking about that because a potential customer wants a wiki implemented on his pages and I do wiki hosting. So this means I would not install a wiki on the customers web server. -- ThiloPfennig 2006-01-22 10:30:30

• Maybe just try it. I think it will only have the usual "frame usability problems" like not being able to bookmark or use the URL with the browser. -- ThomasWaldmann 2006-01-22 10:54:23

## Turn off Thank You Header?

I'm new to moinmoin, and can't seem to figure out how to turn off the automatic "Thank you for your changes. Your attention to detail is appreciated" message. I searched, but I can't seem to find this out. How can I make it so the banner never appears?

• I think you have to disable this option in your theme. In my case, i had to comment this out:
# self.msg(d),

-- Best Regards, Andreas Traub DateTime

• Note that this will hide more useful messages while editing, and user interface for renaming and deleting pages and other actions.
• You can try altering saveText method in PageEditor to return empty msg in that case, do it with care though. -- DonLeri I have added a patch no_thanks_message.patch which will disable the thank you message only. You can read the file (plain text) or use WinMerge or any patch tool to apply it to your wiki. All other messages are not suppressed. It is tested on MoinMoin 1.9.1 (running Python 2.6).

How can I avoid an attached icon (the earthball-icon for example) for linked images?

[[http://www.larpzeit.de/[|{{http://www.larpzeit.de/Bilder/Banner/Banner-468x60_40kb.gif|LARP Zeit]}}]]

shows the earthball-icon, so it looks quite odd. Especially if there are many external linked images on one page. Is there an easy way to avoid the icons for image-links on per link base, per side or for the entire wiki?

-- MelaEckenfels 2008-06-17 17:05:46

• One way is to comment out / delete the respective lines in the css sheets. If you don't want the earth-icon remove
a.www:before {content: url(../img/moin-www.png); margin: 0 0.2em;}
• from common.css and the corresponding similar line from msie.css.

• Hello, thanks for this info, but I'm looking for other ways, probably more flexible ways to hide moin-www.png. Is there a way to selectively hide moin-www.png icon? For instance, 1) based on server domain name, i.e., if a MoinMoin Wiki resides on http://www.yyy.zzz, do not show moin-www.png on any link that has yyy.zzz domain name. 2) based on list of server domain names either defined by list in a configuration file, or provided by a simple textfile file, like intermap.txt (kind of). - MinsooKim

## Question: How do I change the div #header size?

I am currently working on a new theme based on the modern theme and I have problems changing the layout of the div #header since the contents of this container seem to be fixed somehow. How, and specifically in which file, can I change that? For example I want the #logo to appear in the top of the #header and I want all the other containers (#username, #searchform etc.) to be under #logo (y-axis)?

Thanks. -- JohanZiprus 2013-06-19 04:56:23

You need to override the CSS. To figure out what CSS to override, a good tool to use is the Firefox browser with the Web Developer extension installed. Assuming Firefox is installed, do Tools, Add-ons, Browse All Add-ons, Web Development, search for Web Developer by Chris Pederick, install it and restart Firefox. Load a web page using your theme, click Ctrl-Shift-Y, mouse over the element you want to customize and click. Everything you need to know about the present CSS styling for the element will appear in the lower half of the screen. To figure out what to change, you will probably want to invest in a book on CSS. -- RogerHaase 2008-06-30 20:23:48

## Question: How do I move #username to .editbar?

When changing the modern theme I have aligned the text in the .editbar to the right and I want the contents of the #username to appear in the left side of the .editbar only, not in the header (I also only show the .editbar in the footer since this is going to be a CMS-like site). My problem is that when I remove the #username in the #header tag in my theme.py file it still shows in the #header when reloading the page. My second problem is how to edit the .editbar so the #username contents appear there instead. When looking at the methods/functions editbar() and editbarItems() in init.py it does not seem to be changeable from there?

Thanks. -- JohanZiprus 2013-06-19 04:56:23

If you think you removed #username and it is still there, a guess is you missed :>). If you haven't already done so, you may want to download several contributed themes and look over the code. Maybe you can find one that has moved #username to a different position and that will provide a clue.

## How do I change the default FONT-SIZE?

Hello, I've got just al little question. Is there a way to change the default font-size of the main texts in the wiki? Thanks in advance. -- 2013-06-19 04:56:23

• Hello, just edit your /(moin directory)/wiki/htdocs/(yourtheme)/css/common.css. There you can edit the html-section and increase your font size, e.g. font-size: 1.3em;. MatthewKnodler -- 2013-06-19 04:56:23

## How do I include custom smileys and images in my themes?

Hello, I would like to improve my MoinMoin Wiki with custom smileys and images. Therefore, I created for example a "Priority 4" Icon. Then I inserted it in my /moin-1.8.0/build/lib/MoinMoin/theme/modernized.py and /moin-1.8.0/MoinMoin/theme/modernized.py according as following:

• '{4}': ("{4}", 'prio4.png', 15, 13),

MatthewKnodler -- 2013-06-19 04:56:23

Nevertheless, when I restarted the server of my Desktop edition (under Linux), inserting {4} didn't work for me. I even deleted the pyc files, nothing worked. How do I customize my modernized theme?

## My own Theme does not work for me on Ubuntu 8.10

I did exatly the steps described in "HelpOnThemes" to custumize my own theme. I copied the theme folder usr/share/moin/htdocs/modern to usr/share/moin/htdocs/mytheme. Then I copied the file /usr/share/python-support/pyhton-moinmoin/MoinMoin/theme/modern.py to the file /usr/share/moin/data/plugins/theme/mytheme.py and edited the file to modify the theme name. Afterwards I reseted the server but my own theme is not available to select. Where is my mistake?

Harald Hammerl -- 2013-06-19 04:56:23

I wonder a bit about your wiki instance location is it really /usr/sharemoin/ ? I guess you've copied the mytheme.py to the template wiki and not to your wiki instance. If I am wrong check the owner and the accessrights. -- ReimarBauer 2009-04-19 17:32:24

Again "/usr/share/moin/data/" is not your wiki instance it is the template wiki data path. Your wiki instance likly is named mywiki or something what describes your content. You have copied /usr/share/moin/data/ to your instance location at the time you have setup your instance. If you run moin-1.8 and you are the superuser of your wiki you can get the data_dir path of your instance by adding <<WikiConfig>> to one of your pages. -- ReimarBauer 2009-05-20 06:58:01

## How do I change the font size of the text in ~--~?

My "small" text doesn't look small enough for me. How can I make it smaller?

## When I print my page I want to exclude embedded images {{attachment:foo.jpg}} from printing. How do I do that?

As a workaround disable images in your browser and then print

## Where have I to put the *.po Files with the Translations ?

I have really searched, but I cannot find the place where I must put the german language file de.simplemente.po for the theme simplemente ( ThemeMarket/SimpleMente ).

Is perhaps (in an ubuntu-installation) the place /usr/share/pyshared/MoinMoin/i18n and a softlink in /usr/lib/pymodules/python2.6/MoinMoin/i18n correct, and I only have to clean my cache in some way ?

By the way, is there anywhere a discription of the directories used by MoinMoin and what there meaning is ?

## Default and Custom themes do not load in browser. This occured after a Ubuntu upgrade. Any suggestions on how to remedy?

Just upgraded from Ubuntu 8.10 to 9.10 and found that mywiki was no longer working. I received an error associated with the moin.cgi. I remedied this problem by copying the moin.cgi from the server folder to the mywiki folder. This corrected the error, but resulted in mywiki only showing texts sans themes. Any idea what to do to remedy the problem? Thanks,

## Where would I put static files local to a particular wiki installation?

I have a custom logo that I would like to use in place of the default one. I don't want to put this in the site-packages web\static\htdocs directory since this could be overwritten on upgrade.

Anywhere on your server, just add a directory directive for access rights and an Alias

I could attach this to a page but the attach: shorthand will not work across the site. So where would I put it under the wiki instance diretory?

if you use moins builtin server for static files it must be below MoinMoin/web/static. But you also can use apache additional

## What is a superuser?

A superuser has some special "super" rights like installing packages. To define what a superuser is (it can be more than one) set this variable to the main user(s) in the wikiconfig.py file:

superuser = [u"ExampleGirl", ]

## Access Control

Access Control defines who may do what in a wiki. Moin does it with ACLs.

### What are ACLs?

An administrator is someone with full or limited admin rights. These can be defined either by changing the configuration files, or by defining a group like AdminGroup and list members.

• You have to be an administrator to work with ACLs!

### What are Groups?

A group in MoinMoin wiki defines a group of users. The groups can consist of: Users, other groups, all registered users (Known) or all possible users (All). We will call all possible entries "members". A group page should ends with the term Group, but it can be localized and customized by the admin. UserGroup should work for default install.

A group contains the member names in a unnumbered list. Anything on the page which is not a list will be ignored by the group parser.

• These are the members of this group:
* [[User Name With Spaces]]

Note: the group name must be in CamelCase.

### I get: "You can't change ACLs on this page since you have no admin rights on it!" What does that mean?

It means that the wiki thinks you tried to change the access rights of a page by editing a line with "#acl" (either you tried to edit, remove or add it). Only users with admin rights can do that. Please contact somebody like the wiki admin.

### Is it possible to enable the ''delete page'' right only for some users?

Yes. Create a group page like "DeleteGroup" and add the members that should be able to delete pages. then add this to the acl_rights_before setting in the wiki config:

+DeleteGroup:delete

This adds the right "delete" to all members of the DeleteGroup. There are other ways to do it, but this is the most elegant way.

### How to hide certain pages from all users but some users?

1. Create KeyUsersGroup, see How To Create Groups

2. On the pages that need to be hidden, use this ACL line.

### Setting a wiki for closed community

1. Create the group MembersGroup and add the members user names. See How To Create Groups

2. In your configuration file, either wikiconfig.py or farmconfig.py, set these variables:

acl_rights_default = u"All:"

These acl rights will result in problems on page-specific acls (as everyone is a member of MembersGroup, then acl processing stops - so page specific acls are ignored.) As an alternative, define the acl rights the following way:

acl_rights_default = u"MembersGroup:write All:"
acl evaluation order:
1. acl_rights_before are evaluated (so MembersGroup can read)

2. page acl rights (if exist) - your chance to stop MembersGroup from writing

3. acl_rights_default

So, pages without acls will still allow someone from MembersGroup to read and write the page. And page-specific acls work again... such as this page acl I used on MembersGroup page to only allow me to edit the list of members (for a closed community):

#format wiki
These are people that can access the wiki:
* JohnDoe
* JaneFrank
* ...

signed John Doe, happy Moin user

### How to allow only registered users to edit pages?

Note that this does not give you much security, as anyone, even a robot can register an account just to spam your wiki.

### How to disable new page creation

There is no explicit page creation right (see also HelpOnAccessControlLists for permissions and CategorySpam). You need to modify acl_rights_default (which is only used when no other ACLs are given on the page being accessed) to something like

acl_rights_default = \

so that only the Trusted group can write to new, blank pages (which of course have no ACL yet), and then try to make sure that all pages have a ACL that overrides that and allows that proper people to write to that page.

### How do I add a Edit-review-publish workflow?

There is no builtin workflow like this, but you use acl to create such workflow.

1. First prevent editing on all page for anyone but a group of people you would like to create pages, for example, EditorsGroup

2. Put this acl on new pages to be edited by your editors:
3. Now your editors can edit those pages, but those pages are hidden from all others.
4. Review the edits
5. To publish, change the All: acl to All:read

### How do I add a new users group with limited rights but access to system/underlay pages?

Hi,

I'm currently running MM 1.8 in a corporate environment with a limited number of users. My Acls are set like this:

• acl_hierarchic = True

AdminsGroup is the user group which use the wiki in a daily basis and administer it (it's a limited number of people). ReadersGroup is a simple access to a limited number of people which need a read access to all the content (my boss and the like).

Now I want to add another group of users (call it AnotherGroup) with limited rights: I don't want it to be able to view all the content but only specific pages and to write only to specific pages too. It works using #acl on pages and using hierarchic acl I can give them the possibility to create pages under one. My problem is with underlay/system pages, for example SandBox and help pages: they can't even read them.

How can I do? -- EricVeirasGalisson 2009-06-29 15:22:00

Looks like you have a problem. The acl on the underlay pages is just #acl -All:write Default (that means it just takes away write rights from the default acl). Your default acl does not allow reading for them, so they can't read. One possible solution: modify acls on underlay pages manually for the most important pages.

• ok,... that it's not good! do you think about another solution to solve my problem? maybe even changing actual acls? (keeping the same behaviour). I'm a little reluctant to change underlay pages ACLs... -- EricVeirasGalisson 2009-06-30 07:50:25

## How to control who is able to create a user account?

There is no official, supported solution with the current MoinMoin versions (1.5.8), anyone can create an account. Also, you can't protect UserPreferences page, as anyone can add this macro to any page and use it to create a user account. Unofficial solutions:

• If the goal is to control who can edit pages don't worry about user accounts and see Setting a wiki for closed community.

• You can change file permissions on the data/user directory on your Wiki instance, and forbid file creation (with Linux chmod a-w .) because each account is a different file. Additionally you can apply this patch moin-1.5-allow-create-form-disabling.patchto add wiki instance option that allows per instance disabling of wiki "create user" interface. Example instance configuration (wikiconfig.py) follows:

user_account_creation_enabled = False
def __init__(self, siteid):
DefaultConfig.__init__(self, siteid)
self.user_form_fields[0] = ('name', _('Name'), "text", "36", '')

The first line disables create interface. The constructor sets name field trail to empty string. The patch does not disable creation but only interface to it, so chmod the data/user directory. You can use this script moin_useradd.py to create accounts. It will be cool if someone improves the tweak to actually disable account creation not only the interface to it, thus chmod tweak will not be required.

• HTTP Authentication: One alternative can be to use HTTP authentification. Accounts are created automatically when the users connects to the page. See HelpOnAuthentication for details

• With moinmoin 1.6.3 you can also simply add one line to wikiconfig.py like so:

password_checker = lambda req, un, pw: 'Sorry, no account creation or password change possible'

## How to use HTTPS with Twisted server

This is not possible with current twisted server, it may easy to do using customized twisted server, based on MoinMoin.server.twistedmoin.

## How to setup mail subscription?

Enable mail in your farm or wiki configuration:

mail_smarthost = 'mail.mydomain.com' # your smtp host

hint: to test your mail subscription, try to edit a page while you are NOT logged in as yourself, the wiki will not tell you about your changes.

## Excluding System Pages from Search Results

There is no easy solution like "Don't search in system pages switch". There are several things you can do:

• Use minus modifier in searches. for example, the search -t:help excluding system pages will not search any page with 'help' in the name. But it will search help pages in all other languages.

• Remove all the system pages in languages you don't need - which is usually anything but your local language spoken by your users.
• Install two wikis, a Help wiki, with all the help pages, and NO user pages, as a help system. And the User wiki, with NO help pages. Add links between the two wikis in the navigation bar.
• Write some code in search.py to filter out system pages in search. Note that searches as a page Filter function, that filter pages by the search term. You might want to override this and add a system page filter by page name. The problem is that you DO want to search the help pages many times, so you need an easy way to search for help when you need it.

## How to run a wiki without CamelCase

I don't want CamelCase to automatically turn into links in my wiki. How can I disable this behavior?

• Install ParserMarket/NoCamelCase plugin. You can set it as the default parser, use it for certain pages, or use it for sections of a page.

## How to migrate from MediaWiki

I want to migrate my wiki from MediaWiki to MoinMoin (missing the ACLs). I want to import existing pages including the change history. Is there a migration script in existence?

### Solution

There is a quick-and-dirty one on MediaWikiConverter, and there is a parser on on ParserMarket (which lacks support for advanced formatting options, though) which could display the pages if you do not want to convert the markup. Unfortunately, I do not know any advanced converter/full-featured solution.

## Advantages of running a farm

You just need one server, you just have to care for one installation (which can be upgraded easily), you can easily setup multiple wikis which differ just slightly, you can separate content of one wiki by running multiple farms, etc. pp.

## Can apache REMOTE_USER replace moinmoin login?

Yes, you can set MoinMoin to read from the webserver's REMOTE_USER and autocreate accounts accordingly. Just add to your wikiconfig.py :

from MoinMoin.auth.http import HTTPAuth
auth = [HTTPAuth(autocreate=True)]

Older notes (probably can be deleted now) :

I understand that this is essentially the same question as above. I'm running moinmoin version 1.5.2, and would like to rely entirely on server authentication to control access. Is it possible to identify users who are not logged in (and have no user profile) using the REMOTE_USER environment variable? Specifically, I'd like the value of this variable to appear in the editor field in the "info" view for each page. Based on various posts on this site, I've included the following in wikiconfig.py:

from MoinMoin.auth import http
from MoinMoin.auth import sslclientcert

class Config(DefaultConfig):

user_autocreate = True
auth = [http, sslclientcert]

If this is working, I am unable to see an effect. Can anyone help or refer me to the appropriate documentation?

• What you've done looks correct, it should work. Are you sure your web server sets REMOTE_USER etc. for moin? Note that sslclientcert is not needed for what you described, so you can remove it except if you want to use SSL client certificates for authentication. If you can't fix it, maybe upgrade to latest release and if it still doesn't work, file a bug report.

Update from the OP:

I identified the problem, and the solution may be useful for others. If the above does not work, check the value of the AUTH_TYPE environment variable. I added the following to wikiconfig.py:

from MoinMoin.auth import http
from MoinMoin import user
def uw_auth(request, **kw):
env = request.env

if env.get('AUTH_TYPE','') == 'UWNetID': # your institution's authentication method here
u.create_or_update()
return u, False
else:
# authentication failed, try the next method
return None, True

class Config(DefaultConfig):

user_autocreate = True
auth = [uw_auth, http]

A question for the community: is this an acceptable/safe workaround for a nonstandard server authentication method?

• If REMOTE_USER being set still means that this user has been correctly authenticated, yes. That AUTH_TYPE is rather unusual, though.

## Why is MoinMoin dialling home?

I found that each time I save a page, MoinMoin tries to connect to moinmaster.wikiwikiweb.de. If my firewall blocks this, the save is delayed.

• This is the AntiSpam system trying to get an updated BadContent page. No information is sent from the server in the process. If you don't need AntiSpam, for example in an intranet installation, you can disable it by editing your configuration file and removing or commenting the line that says

from MoinMoin.util.antispam import SecurityPolicy

## How do I dis/enable FullSearchCached ? (version 1.5.2)

Or is it enabled if I see it in SystemInfo? In MoinMoinRelease1.5/CHANGES it says "Use it if you do not depend on fresh search results but prefer raw speed."

## Is it possible to compress my wiki-instance or reduce the version history?

Is there any possibility of either compressing the wiki-instance by eliminating parts of the /revisions-Directory or by decreasing the number of revision history (the default seems to be 100!) or by specifying a certain date to remove all history files which are older than that date?

• The limit of 100 revisions is only for display, revision storage is not limited.
• You can manually remove old revision files if you need to and there is an automatic feature that removes ALL revisions except the last one:

•  moin ... maint reducewiki  will flatten the wiki to the single latest revision. You need to add some options, run moin with no arguments to see them.

## Having two content areas not parallel but as set and subset

Hello, I’m trying to find a wiki for our institute. I already did some research in the internet but there is one issue, which is not so detailed described as I need it to make a decision which wiki to choose (and I don’t really like the idea of installing and trying with 3 or 4 wikis).

We will need two areas, one which will contain basic information, that is also used by students, and one which contains also actual research topics. As you surely guessed one thing we need is, that students can’t read in the research internals. I know that this can be managed, but I would like researchers to use the basic topics as well and not having these topics twice. So they are not two parallel areas but one is a subset of the other - and here some questions pop up:

- If a researcher is naming a BasicTopic in an article of the research area, will he create a parallel Topic in the research area, also the Topic already exists in the basic area (if he is not using any special link, because he would not know if it exists (or not think about it))?

- I guess it should be no problem to set different (for example) background colours to the template for basic and research. Can the user rights for this pages be also part of the templates or how would one define for a new Topic if it is part of the basic or research area and therefore by whom it can be read?

- can all this be solved by categories?

It would be nice if you could give me a short explanation how this could be solved in your wiki-engine (please as I’m not a programmer be economical with technical terms Thank you very much in advance, Best regards Oliver

• Make a wikifarm: one wiki for all, one for the researchers.

## disable spell checking

What is the most clean way to disable spell checking?

## Backing Up

What is the recommended way to back up a moinmoin wiki? I have read about WikiBackup but have found this action doesn't work and found references that it is not functional in v 1.5. This way seemed the easiest... I have read the general info on MoinMoinBackup so I know I need to backup the data dir. I also have read about the WikiBackupScript but haven't tried it yet. I currently am backing up by ftp'ing the entire data dir to my computer but this is slow. Recommendations? Info: my wiki is using v 1.5.7 and running on a host with only ftp access. Thanks

• The WikiBackup stuff (action=backup) should work now, if not please file a bug. The reason for the CHANGES hint about "this is experimental stuff, don't rely on it" is that it didn't get tested too much and esp. desaster recovery and restore might have problems. But if you make a backup with the backup action and check yourself whether it worked and is complete, this is better than not making any backup just because it takes too long using ftp.

Is there a way to programatically add users? I would like to integrate MoinMoin into an existing web site that already has a registration facility, and I can already hear comments from users who will have to effectively register twice. The registration is form based ie not tied to an http authentication or REMOTE_USER. Thanks.

• Two ways to solve this: either you write your own auth method (just reusing some user data from your other user base) or you use some user creation script (see MoinMoin/script/...).

## Is it possible to merge 2 wikis?

Is there any way to grab the conents of one wiki, and add it to another wiki?

## Using relative URL rather than absolute ones ?

By default, MoinMoin uses absolute URLs. Is it possible to use relative ones instead ? I look a little bit everywhere in the documentation but i didn't find anything about this ( i may have missed it). Anyway i think it's worth a short entry here.

## Can we specify different startpages for different groups of people?

We are running a MoinMoin instance since 1 year and a half in a intranet. We are a group of tech-savvy people, each login is in the AdminsGroup. Our MoinMoin instance is now full of interesting knowledge we want to share with other people: I have created logins and a group OtherGroup. The problem is: the actual startpage is organized to have links to useful pages for AdminsGroup and is a place for coordination, we don't want OtherGroup people to use this startpage (not interesting for them, they can't read the pages linked...), how can I change the startpage for some group or someone? Is this only possible? -- EricVeirasGalisson 2008-02-05 15:18:21

• I do have a similliar situation on some of our wikis. I did solved it by creating a start page with content readable from users. This page includes other pages which have more restrictive rights. Because of included pages do have to repect acls only users with access right can get access to these informations.

## Adding new pages via batch script

I have much content in form of text or html that i want to pump into my wiki. But this is nothing i can and will do over a webbroswer - i seek some way to add pages with a script or something like that. Any idea?

• Look at wiki xmlrpc, see MoinMoin/xmlrpc/*, esp. the putPage method. This method assumes that you have content in correct format, e.g. utf-8 encoded wiki markup. If you only have html or other text formats, you have to convert it somehow. Maybe search this wiki for "html import", IIRC there was some way, but you have to find it yourself. In general, if you expect short response times, maybe just hang on our IRC channel and do some research on your own before asking.

## How to limit login time / set automatic logout?

To increase safety of the wiki I want to make sure that the wiki logs users out after a certain time. What's the simplest way to do that?

• Make sure "remember login information" is off in the user preferernces

## Easy migration

Hi, just today I realize that my recent installed 1.6.2 need to be upgraded to 1.6.3 to fix some serious security issues. The normal solution is to download MM 1.6.3 and make a installation/migration, but I wonder if a simpler solution exists, like applying a patch to my current installation, or tracking my own code with Mercurial or something else... Is there a way to do this? Can I imagine tracking my own MM instances with Mercurial? Do someone have a solution to this problem? Thanks in advance. -- EricVeirasGalisson 2008-04-21 12:53:59

• You can run the moin code from a mercurial workdir. If you also point your webserver into the workdir for the static files stuff, minor upgrades should be rather easy. You still will have to read docs/CHANGES about configuration changes and run the mig scripts.

## HowTo for SyncJob ?

In moin version 1.6.2/3 I have tried to setup a SyncJob in order to backup my wiki. I have read the page "HelpOnSynchronisation". I have also created a "intermap.txt" file, first in folder moin-1.6.2 later in folder wiki/data.
In both cases I got an IOError: unsupported XML-RPC protocol.
Unfortunately the information for synching a wiki is spread in different files. I would very much appreciate, if someone (Alexander Schremmer would be great) could please give me a hint how to debug the SyncJob action, or write a HowTo.
I already inserted "import pdb/pdb.set_trace()" in file "wikisync.py" line 168 (class MoinRemoteWiki), but it is very difficult for me to figure out (stepping and printing) where the link to the remote wiki is searched for. The variable "wikiurl" did show just a '/'.
Greetings, Rudi 2008-04-22 17:30

HelpOnSynchronisation was actualized some days ago

Please check the remote wiki's wiki config for actions_excluded - the builtin default of it (actions_excluded = ['xmlrpc']) disables xmlrpc (this default was chosen to not open your wiki to automatic read/write access by xmlrpc except if you really decide to want that). To allow xmlrpc (wikisync is based on xmlrpc, so it won't work if you don't allow it), remove 'xmlrpc' from the exclusion list (e.g. actions_excluded = [] if you don't want to exclude any other actions).

You may want to protect your wiki by using ACL rules.

Greetings, Rudi 2008-04-23 18:07

The "xmlrpc" (Remote Procedure Call) for the SyncJob can be enabled in "wikiconfig.py".

actions_excluded = multiconfig.DefaultConfig.actions_excluded[:]
actions_excluded.remove('xmlrpc')

You should have defined also a good acl_rights_default on your wiki. -- ReimarBauer 2010-12-18 07:22:24

• Then you have to restart the moin wiki, actual version 1.9.2.
Moin version 1.9.3 does unfortunately have a sync problem up to now.

-- RudolfReuter 2010-12-17 22:17:56

## Is it possible to use dynamic mail configuration?

I would like to configure email support to use the current user's login and password for the mail_from and mail_login entries in the wikiconfig. Goal is, when a user changes a page, the subscription eMail is sent from that user's account (which is identical to the username in my environment). Is that possible? Supplying a default user/pw is not possible (unsafe).

• What do you mean by "unsafe"? The sender email address can be a no-reply address (and replies directly written to /dev/null or rejected if there are some). Wouldn't using the personal email give multiple new problems:
• privacy: maybe the editor does not want to disclose his email to every user that is subscribed to some page he edits. He even doesn't know who is subscribed until he saves.
• not wiki way: if there is a direct reply possible via email, discussions are pushed from the wiki page to the email inbounds. That gives you a problem back that you maybe tried to solve with a wiki.

'Unsafe' means, I do not want to write my personal login into the config file, and the Mail Administrator in my big company (big meaning very big and very complicated) will definitly not provide me with a dummy address as you proposed - he will probably kill me for asking

• The privacy issue is not a problem, as the wiki is an internal one, so everyone knows (or could at least look up) the mailaddresses anyway.
• 'not wiki way' is probably correct, but I want to do it either way - so, is there a possibility?

You could change the code rather easily to use the editors mail address as from: address, but you can't easily get his password (we only store a password hash, no cleartext password). But as long as the destination address doesn't require relaying (because the target mailserver is the destination domain's mailserver), the mailserver would likely accept the mail even from an unauthenticated connection.

## How to get rid of the thank you message after editting

Whenever you edit something, you would get a thank you message for editting the page (or creating it.) Now, if you navigate to a new page, and press back, you will get an error. I figured the error is caused by the "thank you" message (because the #preview is append to the end of the page's name).

Is there a way to get rid of this error? If not, is there a way to get rid of the thank you message? Thanks -- 12.109.151.100 2008-07-31 18:44:59

Don't go back by the browsers button use the navigation of the theme

## How to add additional icon to icon toolbar when editting by GUI

I want to put the @_SIG_@ variable as a clickable icon on the icon toolbar when editing by GUI. Is there a way to do so? Thanks -- 12.109.151.100 2008-07-31 18:49:00

That needs a modification in fckeditor javascript code.

## Adding search engine to an external html page

Hi, I was wondering if there's a way to include the MoinMoin search engine for my wiki onto an external webpage that's written in HTML. I want to be able to put the search engine on the external page, which is not part of the Wiki, and have the engine search my Wiki only. Is this possible? Thanks -- 12.109.151.100 2008-07-31 20:24:20

## Trivial change flag not visible

We are using just starting to use Moin Ver. 1.8.2 but the Trivial change flag does not appear when we edit. I can't find anything that indicates that this is a configurable option. How do we make it available ?

• I assume you don't have email enabled. Do you see the Subscribe/Unsubscribe link in the edit bar? This also appears only if email from the wiki is enabled.

Correct- e-mail not configured yet. Thanks Gerry

## Page name translation for multiple languages

The documentation says:
A page name is translated only if the wiki knows about the language, the wiki translation contain a translation for the name, and a page with that translation exists. If any of this is false, the original name will be displayed.
So using 1.8.2 I have installed Italian, created an ItalianDict page and created two pages TestPage and PaginaProva. I can see that Italian is installed because all the standard messages are in Italian as are the navigation bar tabs. Further the <<GetVal(ItalianDict, TestPage)>> returns PaginaProva so the dictionary is working fine.
So therefore after changing my language to Italian, I presume that my TestPage link should now be shown as PaginaProva, and that when I navigate to it, I should navigate to PaginaProva, which should be the displayed name on the navigation bar tab. Unfortunately it all remains as it does in the English version. I supose this is some misunderstanding by me. Any suggestions ? -- GerardODriscoll 2009-05-21 15:43:56

No response to my query above. Has anyone implemented a multiple language site using MoinMoin ? -- GerardODriscoll 2009-08-24 11:41:10

It won't magically change links in your content. There is special code that does this for navibar and front page. -- ThomasWaldmann 2009-08-24 11:50:51

## Managing users in groups

Im writing an authentication (auth) against an external MySql database. I need to manage the ACL rights of wiki users and i have decided to manage this through groups. The group(s) that users belong to are maintained in the external database. Is there a way of automatically maintaining groups in moinmoin? I dont want to maintain groups by hand as there are too many users, and users move between groups.

In the MoinMoin 1.9 groups code was refactored and now it is possible to write backends for groups. See Groups2009 for more details.

ConfigLazyGroups is an example how such a backend can be implemented. You should subclass LazyGroupsBackend and overwrite needed methosd (see ConfigLazyGroups).

Also, there is a patch for a LDAP backend -- DmitrijsMilajevs

## Is 'url_mapping' the right way to handle changing drive-Letters (G:, H:, I:) of a standalone-wiki on usb-stick?

Hello, and thanks for the perfect job, i'm using and loving MoinMoin as Desktop-Version for years now under Kubuntu 10.04.
Now, that we're beginning to use Confluence at work, some are astonished, how powerfull MoinMoin is even in comparison to Confluence.

• I have MoinMoin with modwsgi-I/F running at apache2 at home and have build a standalone wiki completely based on portable apps running on an 16GB-U3-Stick (U3-launch, ASuite, Portable Python) .
The only Problem is, that all external links are dead-links, when i use the wiki on another Laptop / PC, where the drive-letter for the usb-stick changes.
Is there an easy way to solve that?

I guess that solves it

MoinMoin/script/moin.py ... maint cleancache

MoinMoin/script/moin.py ... maint makecache

see HelpOnMoinCommand -- ReimarBauer 2011-09-21 14:09:17

-- EMuede (Ewald Müller) 2011-09-21 14:00:00

I think, the problem is a bit more complex and is not solved by renewing the cache:

On many places in the wiki i used external links f.e. to 'G:\Offline_kopie\blah\dingens.txt' as an absolute adress. I don't use relative references 'cause they are too 'far away' from the wiki-subdirectories.

If the stick lands on drive-letter 'I:' i have to manually change all the links, therfore i wanted to use a system-variable ?home_drive? or an {url_mapping} instead.

Read about InterWikiMap. You can use that for any kind of links. Then you have only one place where you need to change it. A page can also be updated by a cli script.

There is also a second advantage: The Wiki can be hold small (for backup, maintenance) and serves only as a a comfortable index to the greater amount of external stored data. The whole external Datastructure is -for security- stored a second time on a share, so i could switch to that strukture by using the {url_mapping} ?

May be you are also interested in https://utils.icg.kfa-juelich.de/docs/wiki-xmlrpc-extensions/0.2/wiki-xmlrpc-extensions/ForkWikiContent.html

Very interesting tool! I solved this problem by copying the whole wiki-content from stick to harddrive and used FileSync to synchronize them. I could switch the wikiserver.py (from G: or D: f.e.) in PortablePython depending on the wiki (or copy), i want to use. I'm not used to program in python (though i had >10yr. PL/I-Experience), maybe i would only need one changed system-variable (like mentioned above) to redirect the links?

-- EMuede (Ewald Müller) 2011-09-21 20:00:00

As I mentioned already read about InterWiki. If you define links like 1938 then for those links you need only to change the InterWikiMap page. But this only partly solves your problem. The cache files are dependent to the python version used. So on a different python you need to invalidate them.

# Attachments

## PDF attachments do not load in browser

Since I upgraded to version 1.5.3 the pdf attachments on my wiki pages will not load in my browser. I can download them and view them in acrobat, but cannot view them via the acrobat plugin. I see this behavior only with docs on my wiki. What can I do to correct this? -- JamesCurry 2006-04-23 11:30:21

• Hi! I am having the same problem - but only on machines running Acrobat 7 (+Firefox + Windows XP) not on those using the older version of Acrobat 5 which displays a pdf's first page quite nicely. The Acrobat 7 plugin always gives an error message twice before I can download the attachment and view it in the external viewer. JensBachtler

• and what does adobe 8 do ?

## Question: Can you copy a page and all of its attachments?

Is it possible to copy a page and all of its attachments, do some small changes to the page and upload the changed page as a new page?

Thanks. -- JohanZiprus 2013-06-19 04:56:24

-- MarcelHäfner 2008-06-24 15:29:51

## Question: Action on Opening an Attachment?

I'm using the DeskTopEdition as a PIM and it is very good. I was planning on using the pages as a project logbook and storing associated project files as attachments.

• You could store the files locally and link to them. This is not possible in most browsers either. Check the paragraph "Links to files" on the page DesktopEdition for further information.

## serving files in zip archive attachments?

Is that possible? -- MSt 2006-02-24 13:15:17

• No, but you can extract them before you want to serve them.

## How can I center ( or right justify ) image attachments?

If I install the html.py plugin I can do something like:

{{{#!html
<P align='CENTER'>
<img src='http://homepage.mac.com/levanj/.Pictures/Morini.jpg'>
</P>
} } }

And the image will be fetched an be centered in the page. Is there any decoration that can appear around

•        attachement:Jerry.jpg

That can achieve the same effect?

Jerry

## How can I use an attached image as link?

This my wiki page:

Infos und News 2010
[[Anchor(top)]]
*[#kw16 KW 16]
*[#kw14 KW 14]
*[#kw13 KW 13]
*[#kw11 KW 11]
'''[[Anchor(kw16)]]KW 16'''
[#top TOP]
* [attachment:diesUndDas16.pdf Dies und das 16]
'''[[Anchor(kw14)]]KW 14'''
[#top TOP]
* [attachment:diesUndDas14.pdf Dies und das 14]
'''[[Anchor(kw13)]]KW 13'''
[#top TOP]
* [attachment:diesUndDas13.pdf Dies und das 13]
'''[[Anchor(kw11)]]KW 11'''
[#top TOP]
* [attachment:diesUndDas11.pdf Dies und das 11]

This works but I wanted to replace "TOP" with an image called "image_TOP.png". I tried so many things but none of these worked. Is it possible to use an image to link to an anchor? Thanks for an answer.

in recent moin versions you can do it by

[[WikiSandBox#anchorname1|{{attachment:python_logo.png|text describing image|width=100}}]]

An example of that was added at bottom of WikiSandBox

Because of the syntax you showed I guess you have a moin version before 1.6. Please read SecurityFixes and update as soon as possible.

-- ReimarBauer 2010-04-22 10:32:14

# E-Mail

## This email already belongs to somebody else

(update problem; solved )

"Diese E-Mail-Adresse gehört bereits jemand anderem": This is the message I get if I want to update the user preferences of my own account. What I have done:

• install moin-1.5.0beta; create an instance moin-1.5.0beta/MyInstance
• create user MaxMustermann with email Mustermann@nirwana.net

• install moin-1.5.2 into a new location; create a new instance moin-1.5.2/MyInstance
• DO NOT: create user ErikaMustermann with email Mustermann@nirwana.net

• copy the old data directory into the new instance: cp -R moin-1.5.0beta/MyInstance/data  moin-1.5.2/MyInstance

• login with MaxMustermann; the email Mustermann@nirwana.net is shown

• chance the default theme, "save preferences": get the error message.

The idea was to keep the old version running. The problem arises if you merge the user data of two running instances.

Solution: allow a mapping of different users to the same email address. -- Yes, I am aware of that: Somewhere else in this wiki there was the discussion, if one email adress should allow more than one UserNames. IMHO this should be allowed: It ist quite useful e.g. for demonstration or admin purposes; mainly it allows to play several social roles in the same group. The current moinmoin policy arises the need to have several distinct mail aliases on my server. Would it not be better to know within the wiki which different users have the same email? jbusse

Use the [[MailTo()]] macro: <FooBar@FooBar.foo>. You can also do spam protection: <FooBar AT FooBar DOT foo>.

# Images

## Can one right-align images

How do one align images in the text? I would like the image to be right aligned and the text to flow around it on the left side. Thanks in advance.

## Including external graphics with non-standard URLs

How can I include into a MoinMoin wiki page a graphic from some other ressource, if its URL does not end in .gif, .jpgetc.?

## In-Line Image Syntax

I can't seem to find the appropriate syntax to embed an image in-line, position it on the page, set the size, etc. Any input on this appreciated.

To resize an image and/or provide an alt tag for it use MacroMarket/Image.py . To align images see SectionParser or ParserMarket/Frame. ParserMarket/Frame by Reimar Bauer is really great and easy to use but has - since it is relatively new - still some issue

For size and alt tag you can just use

{{ image | alt | width=123px, height=456px }}

## Position and size of attached images??

When I display an attached picture with attachment:albumcover.pngIt positions itself to the left of the page, and with the size the picture has. But I want to be able to have the picture aligned right and with a smaller size. Is this possible?? I suppose I could put it in a table with a tablestyle that positions it where I want it. But I can't change the size that way can I??

I want to display a few images, all in a line. It can be done with attachment:a.png attachment:b.png attachment:c.png, but I need to use ImageLink. But every ImageLink forces line break (like BR), so it is impossible to have a row of images (and I don't want to use tables everytime). How can I stop ImageLink from forcing linebreaks? It's not even documented, that it should do it. If I want a linebreak, I can do it on my own :/

May be you have an older version, please check SystemInfo. Here it works as supposed. -- ReimarBauer 2007-04-13 19:11:31

• Well, I know now why it didn't work for me. It works, unless you want to indent it (by using space as a first character) and text/space between them. This way, it forces linebreak. Maybe it's a bug, maybe it isn't (rather is). See this (and see the code):

not-indented:

indented (and wrongly linebreaked):

I've added a bugreport, see MoinMoinBugs/IndentingAndSpaceBetweenTwoMacroCallsGivesLineBreak

indented (without the space in between not linebreaked): current workaround

# Importing from other editors

## Copy/paste from Microsoft Equation Editor 3.0

Is there a easy way to copy/paste mathematical formulas from MS Eqation editor 3.0 to Wiki pages. Failing that, any workaround would be appreciated.

## Paste from Word does not appear to work in MoinMoin 1.5

Whenever I try to paste from MS Word in the gui editor some invisible formatting seems to come along for the ride and mess things up. I use the paste from Word option every time. I have tried checking both options for "Ignore Font Face..." and "Remove Styles Definitions", neither seems to do anything. If I paste from word, and then manually go through "sanitizing" the styles then things seem to work OK. But I thought that was the point of the paste from Word option, to do that for me. Word 2003 seems to be much worse than Word 97, but that is from limited testing, and I did still see problems with Word 97. I never tested 2000 or XP though.

-- I experience the same problem using Word 2003 and Word 2007. I'm going to test in Word 2000 as well. Is there some secret to getting this to work? --

## Importing text file

Is there an easy & quick way to import data from a text file and convert it into multiple wiki pages, using a simple separator between entries ?

I am confused about the resetting password feature, this is with 1.5.3. When it sends the email the password is the SHA encrypted value, and the text on UserPreferences says to "Just copy and paste it into the login mask into the password field and log in." But I can't seem to get it to work. When I paste that into the password field and try to login it tells me "Sorry, wrong password" Is this a bug or am I doing something wrong?

I found the source of the problem, and also a fix. See MoinMoinBugs/ResetPasswordEmailImproperlyEncoded

I have not been able to set the wiki up so that it emails lost user passwords to people. Is there any way that I can retrieve a lost-password manually from the data/user files (or elsewhere)?

• With a recent moin version (like 1.5.3+) you can change to that user on your UserPreferences page if you are a superuser. Then just set him a new password and tell him.

• No, but you can manually log in by appending ?action=userform&uid= followed by the filename of the user's data file (grep in .../data/userfor the user name) to the page URL.

• Alternatively, you can use the following script to generate a new encrypted password. Insert this password into the file containing the user profile.

passwd = "something"

from MoinMoin.support.python_compatibility import hash_new
import base64
from MoinMoin.util import random_string
salt = random_string(20)
hash = hash_new("sha1", passwd)
hash.update(salt)
print base64.encodestring(hash.digest() + salt).rstrip()

I have access to the config files, but email apparently isn't enabled (even though I put in an SMTP server in wikiconfig.py just now) and thus there is no "mail me my account data" link. I tried pasting in the SHA-1 hash from my file in wiki/share/moin/data/user/... but it won't accept it. How can I get access again? It seems ridiculous to me that a lost password for an admin account is unrecoverable!

• Did you enter the mail_from variable too, otherwise I'd suggest to do it -- ReimarBauer 2006-06-01 06:50:32

# Printing

## Changing Print font size

How do you change the font size for the print page?

• If your are admin: by changing the file print.css which lies in htdocs/theme_name/css/
• If your are a user: by changing the scale in print preview of your browser (under 'File'). Works in Firefox 3, IE 7, Flock 1.2.4. Chrome has a "Text zoom" option under the current page control.

# Tables

## Nesting a table in a list

Is it possible to nest a table in an li element? - resulting in i.e.

<ul>
<li>Item A</li>
<li>Item B <table>
<tr>
<td>A</td><td>B</td>
</tr>
<tr>
<td>C</td><td>D</td>
</tr>
</table></li>
<li>Item C</li>
</ul>

When I try

* Item A
* Item B || A || B ||
|| C || D ||
* Item C

I don't get the desired result ...

A workaround is to add the table on a subpage and to include it

* Item A
* Item B <<Include(/Table)>>

Another one is to add nested markup by the MacroMarket/MiniPage macro

## Editing Tables In GUI

We have users that don't really get the special characters in Wiki and so don't like to use the Wiki. Therefore we are upgrading to this later version of MoinMoin Wiki. I have tried using the GUI editor, but there is a distinct lack of help text on using the GUI, as far as I can find. But the GUI should have even more help for those types of people that use it. Yes some things are just like standard programs that they use, so those parts should be easy for them. But there are other things that are not in standard programs and should have extensive help available. Anyway, I could find no way to edit an existing table - in particular to add or remove rows or columns. There is a button that sometimes is enabled, but it only seems to be able to insert a new table, even though it says "Insert/Edit". Hopefully I am missing something simple. Otherwise there seems a major usability problem here. How does someone perform these operations in the GUI? [I won't go in to more advanced things, such as spanning, which are probably very hard to put into the GUI, but the ones that I am asking about are very basic table manipulations.] Thanks.

• Hmm did you tried as in other programs the right mouse click in a table. The icons and the text behind them should help to find the action you are asking for. Some of these functions may not be implemented for each case or combination completly by now. If you got a wiki syntax error please file a bug report at MoinMoinBugs. This does much help to improve this tool -- ReimarBauer 2006-07-06 05:31:21

• I found out that we had some sort of configuration problem, probably due to permissions. Everything seems to work correctly now - and it is pretty nice (and it does have span (merge)). (Although I did not see any help for the GUI.) Sorry for the false alarm.
• As you know the editor is the fckeditor. We would be glad if someone could help to add a short description on that on moinmaster.wikiwikiweb.de. If it's the first time helping with documentation please read EditingOnMoinMaster before hand. -- ReimarBauer 2006-07-06 21:31:15

## Borderless tables

||<style="border: none;"> borderless table || produces a borderless cell, which works with firefox and IE6. <tablestyle="border: hidden;"> works with firefox, but not IE6. Bordless tables don't seem to be covered in the HelpOnTablesexamples.

• -- I posted this here originally because I had been bitten by MoinMoinBugs/TableStylesAreNotRespected and couldn't produce borderless tables. -- GregWhittier 2006-03-29 14:21:55

• -- You may want to look at MacroMarket/Columns if you need simple column layout rather than complex tables. It will result in a borderless presentation. -- DanONeill 2007-08-15

## Default Table Formatting

I'm trying to figure out how to customize tables using CSS. What I want is something like in MediaWiki with the Wikitable class where the table formats with certain colors, header and borders based on a tableclass. I've tried pasting the Wikitable CSS code into the common.css file from sinorcaformoin (the theme I'm using). I can't seem to get this to work. I've even edited the default table settings in this file and can get some but not all the formatting to affect a table. For instance, I can't seem to get padding to change. What I really want is for the first row to take the heading (th) formatting. I'm new to CSS and I'm getting pretty frustrated. Any suggestions would be very welcome. Regards, Eric Shain

## Marking up a table for automatic row numbering

Q: I would like to create a table who's first column is autonumbered..

 1 stuff 2 more stuff

This would allow for easy insertion of data. Thanks, Dave.

Reply : I am not sure how to understand this. Where should the number come from? e.g.ParserMarket/sctable or ParserMarket/sstable

Reply to reply : I was hoping the rows would be autonumbered starting at 1 - Dave Thanks for the sctable pointer

## Lists inside of a table cell

can I include list in a table cell? I've tried:

|| 1. aaa<<BR>> 1. bbb<<BR>> 1. ccc||

but this produces incorrect numbering:

 1. aaa 1. bbb 1. ccc

## Nested tables

Can I somehow create a table inside another table's cell?

• Use the Include macro or MacroMarket/MiniPage.

• Thanks, I did but how to make the inner table to keep the whole outer table's cell space? Now there is much free space between outer table cell's borders and the inner table borders
•   ||<<MiniPage(||aaaaaaaaaaa||)>>||
Produces sth like:

 aaaaaaaaaaa

-

• The css for tables needs changes.

# Searching

## Can FullSearch also do un-formatted output?

2008-07-10 Is there an option for <<FullSearch(...)>> to output results not like:

1. firstresult
2. secondresult
3. ...

but like:

firstresult, secondresult, thirdresult, ...

It would consume much less space on the screen. I would like to dynamically show pages from Categories on the starting page. The list output destroys the whole layout of the starting page, while unstructured output would look very nice like tag clouds...

## How do I avoid searching the WikiHelp when performing a full text search?

I'd like to find sg. via full text search, but i'm getting lots of results of WikiHelp which makes it hard to find the (few) entries of my own wiki data.

• for which version do you ask?

I'm using MoinMoin Version 1.2.4 [Revision 1.187] Can you please tell me from which version on it is possible to suppress searching the WikiHelp?

• Currently (as of 1.5.3), you can't suppress it. But using 1.5.3+ you can reduce the amount of system and help pages by only installing the languages you need.

I want to make a link to a search to all my pages starting with 'Categorie', I tried several ways :

Anyone have a solution to this problem ? -- EricVeirasGalisson 2006-04-14 08:15:19

• Yes, the page CategorieCategorie already does what you are trying. On it, there is a search marco that creats the list (see HelpOnMacros and HelpOnSearching. Ok, but this is the solution for the next problem (how to search for categories) but not to link to a search. Maybe, there is no solution, nevermind, i'll manage with that. Thanks. -- EricVeirasGalisson 2006-04-18 06:51:06

I found very different implementation for backlinks:

• [[FullSearch()]]

• [[FullSearch(regex:\bCategoryName\b -title:regex:^Category)]]

• [[FullSearch(regex:(----(-*)(\r)?\n)(.*)CategoryName\b)]](This seems to match the stuff generated by the "Make this page belong to category" option)

# Other

Before I upgraded my wiki I was able to use he syntax Link to a page with an action however with the latest version the editor translates the ? and = to %syntax? Is there a way to do a wiki link to a page with an action? Is there an escape sequence for the special characters?

You can use link parameters with [[wikipage|Link to a page with an action|&action=edit]] which render Link to a page with an action

Marc Zonzon

## How to successfully create categories that have more than one word in their name?

I'm not responsible for the configuration or installation of the wiki, but I'm the editor of a MoinMoin-powered wiki and I'm having some bizarre trouble with categories, even if I've followed the instructions found on HelpOnCategories - it seems that I can create categories (by adding the CategoryWhatever tag in the respective pages) only if their name is a one-letter one, like CategoryWhatever. When I try to enter multiple words in the title of a category, it creates a new page. Can you please explain category creation step by step to see if I'm doing anything wrong? Otherwise I'm guessing that there's a kind of setting in the configuration that prevents me from naming categories as I would - thanks.

Edit - I figured it out - when the new page is created I just click on the CategoryTemplate and then it turns the new page into a category. Phew.

## How to ignore markup?

Is it possible to ignore the wiki markup. For example if you want to write a date at the beginning of an indented paragraph MoinMoin interprets this date as a list entry. See example below:

• This is an indented text. The next line should start with the date: 21. August 2008 but what you see is this:
• August 2008 (hmm, this is a list entry and not what I want)

21. August 2008 (that's how it looks with backticks)  21. August 2008 (this one has a backticked leading space ... also not what I want)

I know that enclosing it in backticks would solve that problem but it will also switch the font to monospace. Is there any other way to ignore the markup for certain entries?

Seems that I found the answer myself: a list without bullets will help. Put a 'space .' infront of the indented paragraph. Example:

• This is an indented text. The next line starts with an un-bulleted list to show the date correctly.
• 21. August 2008

To ignore CamelCase for example put the exclamation point in front of the text that isn't intended to be CamelCase

### Discussion

First note that the "Make this page belong to category" option format is not very important, as anyone can change the text on the page. You should not assume that all categories are created using this format.

In moin 1.3.4, search has a new linkto: modifier. This modifier does not search in the page text but in the page links cache files, which is much faster and put less load on the server. The [[FullSearch()]]syntax should use this option. But this will find any page that link to the page title, even if its not a category. The last syntax using the hr should more correct, but if someone deleted the hr or added whitespace or comments below it, it will not find the page.

Since categories are not defined in a strict way, there is no one good way to search them. Adding Categories:prefix might help to fix this problem.

## Escaping Categories

Pages can be attached to some category, but how can this be made undone? (without deleting or renaming the page of course)

### Solution

Simply remove the category tag at the end of the page.

## Is wiki markup in headings possible?

Wikimarkup in headings is not possible in default, but is possible with a patch. See FeatureRequests/TitleFormatting

## E-mail notification of all changes

How can we force sending eMail notification of each change to registered users which have subscribed to mail notification?

### Solution

Insert .* in your UserPreferences to subscribe to every page. Also, look at CategorySpam. There is a UserPreferences switch Subscribe to trivial changes which allows you to see even changes which were marked as trivialby the submitter.

## MathML

See MathMlSupport.

## How Do I Subscribe To A Category

I'd like to track all pages that fall under a (say) CategoryDiscussion category. I don't think there is a title RegularExpression (for use in UserPreferences) to accomplish this. Should I file a FeatureRequest? I saw a "FeatureRequest#Page Subscription Options" (under Old Feature Requests, but I don't know what Old means -- won't be implemented? -- MicahElliott

## Change default HompepageTemplate

How is the new homepage mechanism implemented? Can i change the default template that is give by the name HomepageTemplate. As I translate templates into my local language the HomepageTemplate has another name (ending "Template" changed) -- ThiloPfennig 2006-02-05 11:06:09

• See cfg.page_template_regex.

## Help with regular expressions in subscribe field

I am trying to subscribe to a group of pages and their sub pages using a regular expression

The page names are of the form VerPlanning/Metrics.

I can subscribe to all pages with .*

However I want to be able to subscribe to *VerPlanning* and this does not seem to work. Any hints or examples would be really appreciated.

• *VerPlanning* is not a valid regular expression. It means zero of more of nothing, then VerPlannin, then zero or more g What you like to use is .*VerPlanning.* or VerPlanning/? - it is not clear from the question what should be the correct pattern. Please see HelpOnSubscribing -- RayMosteller

## MonthCalendar ease of use question for entries

I want to use the MonthCalendar as a group vacation calendar. I wanted to have a calendar for the group and provide a template with everone's name on it. If someone was planning vacation for a day then they would mark their name so it would show up when the pointer is held over that day. It appears that only the first level headers show up. Could Other list entries be added? For example, *.

Thanks,

GlennOpdyckehansen, <glennoph AT gmail DOT com>

• MonthCalendar currently only displays first level headlines. The space you have in that bubble is somewhat limited, so I don't know whether it makes sense to include more headline levels or other content of the target page. If everybody puts his name into a firstlevel header, it would solve your problem maybe. -- ThomasWaldmann 2006-06-23 06:22:41

## How can I put current day and time to a title?

I mean just like MonthCalendar. if I put a [[DateTime(2006-09-13T13:20:26Z)]] into a Newpage macro it expoands but expands to the current time. What i want is rather a substitution by the current time. Did I miss that or is it described somewehere on the docs? I want to egenrate pagenames like ExamplePage-08-13-2006-14:00

• I solved this problem. Use this code (works in moin 1.9):
•  = News =

<<TableOfContents>>

Click to post a news item: <<NewPage(NewNewsPostTemplate,Post a new item,@SELF,%Y-%m-%d.%H%M%S)>>
• This will create a new subpage with the name yyyy-mm-dd.hhmmss (ex: wiki/News/2012-04-19.160449). The %Y, %m, etc are Python codes. See http://moinmo.in/JohannesBerg/NicerMoinBlog for more info. Good luck! signed happy Moin user

## Is there an alternative GUI editor?

I was wondering if there is any extensions out there for a bit better GUI editor that include more buttons/shortcuts?

• You can if you use iceweasel/firefox install an add-on called "It's All Text". With this you can edit with your favourite editor. I'm soon going to start making a moinmoin mode (not syntax) for Vim... -- Fri Feb 2 22:48:31 CET 2007

## Displaying only page content

We want to use the wiki-information for a help-window in our client application. In this window we would only want to have the page-content. The user should be able to navigate from page to page using page links.

Create a minimal content theme for your wiki that does nothing:

# content.py
from MoinMoin.theme import ThemeBase
class Theme(ThemeBase):
name = 'modern' # use modern css and images

Copy this file to your wiki/data/plugin/theme/content.py, and in your wiki cofniguration file, set theme_default = 'content'.

## Regex: all pages but certain ones

I want to list all subpages, that do not contain the word "Server". I tried <<PageList(Your search query "OurProjects/^(Server" is invalid. Please refer to HelpOnSearching for more information.)>> but that didn't deliver anything. I also tried

again no result.

Are the MoinMoin-regex somewhat non-standard?

## Indexing of Catchwords

I'm looking about a function like catchwords in library systems and to create an index over it. So I could use (maybe) the '#pragma keywords word1, word2, word3' and would like to get an output like WordIndex.

• Why don't you simply use the search function when looking for some catchword?

• I don't like to search for a special word. I would like to get a list of catchwords and a link to the pages where is it located like the WordIndex or TitleIndex function of MoinMoin.

Any help how I could implement this would be helpful. I tried to adapt the WordIndex function to a macro but without any Python knowledge and about the existing MoinMoin objects it's quite difficult.

Bye the way - which editor would you suggest for Python programming?

• You can use any text editor you like (it should be able to expand tab key to 4 spaces). Many people use vim or emacs (you have to get used to them). If you prefer something IDE like, try eric3.

• Thanks - I will try it.

## Full History

How can I display links to all versions of a page? Currently only the last 100 are shown at the page history. BTW: Manually editing the URL is not an option.

• We don't offer more than 100 revisions from the web UI (mainly due to performance reasons and because it is usually not needed). Why / for what do you need that? You can have access to every revision ever made via the filesystem.

• Our wiki has a news page that gets updated regularly, the last 100 revisions only go back for a few months. My users have asked me about access to the older versions. Since they have no shell access they could only fetch older versions by manipulating the query string which poses two problems:

• Usability: The average user isn't able to manipulate the query string, even more the date format isn't very intuitive (is it a unix date?)
• Frames: By entering the URL manually you loose the navigation frame.
I'm sure that other people are missing this feature as well, a link to the next 100 revision at the bottom would be nice. I'm not sure but is this really such a big performance hit?

• Adding a link to the next 100 revisions sounds like a candidate for FeatureRequests, but if you just want to show all revisions all the time in the history table, edit wikiaction.py and find the following lines in the history() function:

count += 1
if count >= 100:
break

Change break to pass, and you'll see all revisions. The performance hit will (obviously) depend on the number of revisions for the page you're looking at; viewing the history of a page with 1000 revisions will take about 10 times as long as a page with 100 revisions. -- BradeyHonsinger 2006-10-26 18:33:11

• There is now a Feature Request: http://moinmoin.wikiwikiweb.de/FeatureRequests/NextInfoPage --Neal McBurnett

## Is it possible to use a list of pagenames which are not in CamelCase but this will be handled as an automatic wikipage link?

I would like to create a list of possible WikI page names, which will be handled the same way as names in CamelCase are handled. I.e. MoinMoin should automatically create a link the that page. Examples for such names are ABC DEF ABC123 DEF222 and even 1234. This would save a lot time for users (and for me...) - is this possible?

No, not out of the box. You would've to write your own wiki parser for such a thing. There was a thing named GaGa parser some time ago (pre-1.3) that linked every word which had an existing page, but I didn't revive it yet for 1.3+ due to performance reasons (getting a page list is much more time consuming in 1.3 than before). Maybe you can write your own parser, reusing code from wiki.py (parser) and putting the words to link onto a wikidict page. If you don't want to write it yourself, there are FeatureRequests and MoinBounties. -- ThomasWaldmann 2005-12-03 09:32:27

Thomas, thanks for your comment. I will know at least have a starting point. Thanks, Henk

## Can i synchronize my wiki with a local one?

I would like to have my wiki on my notebook to have all my information with me when travelling. When returning i like to syncronize with the ServerVersion of my wiki. Is there any way to syncronize in one or better both directions?

• I'm using unison as a synchroniser. I'm using it to fully synchronise both copies (desktop, notebook) with deletions and all. It needs some setup but works fine, at least for me, because I'm using it under the following preconditions:

• I am the sole user of the wiki (DesktopEdition) at the desktop and the notebook.

• I always do a sync when switching from desktop to notebook or vice versa. If you forget a sync, this could become a problem.

## E-mailing the diffs as a digest

When page are changed more than a few times per day, a person who wants to receive e-mail containing those changes can get a lot of e-mails.

## Slideshows

I am would like to create a slideshow over several existing pages on my wiki. The pages are in no particular order and in different subfolders. (The slideshow should point to different character pages for an MMORPG guild that is spread over several games, so I may wish to add both StarWarsGalaxies/Humpty as well as WorldOfWarcraft/Dumpty).

• The right way is to have short subpages that consist of the Navigation macro and a Include.

## Subscribing to RecentChanges

I noticed that you can subscribe to the RecentChanges page. Does this make sense? How does it actually work? I do not receive notifications to 'changes' to this page.

### Solution

If you want to subscribe to all pages, go to GetVal(UserPreferences) and enter .*into the list of subscribed pages.

## Question: Can I create user defined variable in a page?

I have to type a common URL path quite a bit in some of my pages for inline images. It would be nice to define a variable at the beginning of the page and refer to it later - e.g. #define IMGURL=//www.mywebsite.com/users/fred/fred_wiki/images

and then go

http:$IMAGURL/smiley.png in the text. • Yes, you can create a page below your WikiHomepage called MyDict and add a dictionary definition on it. After that, you can "call" it on the page like @IMAGEURL@. See WikiDict. Hmm, I think that this won't solve my problem. I want to be able to add the variable in the text, and perhaps change it later. Don't @VARIABLES@ get replaced after edit? Also I'd like to be able to set the variables in the page in question. I think that TWiki does this, but I've installed MoinMoinnowandpreferit. I can't abide Perl. I have managed to hack the feature by modifying request.py, page.py and wiki.py. I've never written python before, so my code is probably appalling, but it seems to work! I added a new pp command called '#set' and you go '#set variable value'. By default$variables are ignored - for backwards compatibility - but as soon as page.py sees a "#set" command, variable_mode is switched on and subsequent $variables are replaced. Do you want to add this feature? Do you want to see my appalling code? We like to see only nice code I think you can get the same effect with pragma and a macro and not change to moin code. First, you add values to the page with a pragma: #pragma foo bar #pragma bar baz This will put foo and bar into request.pragma dict. Now you write a tiny macro called Get.pythat get the argument: Dependencies = [] def execute(macro, args): replacement = macro.request.getPragma(args) if replacement is None: return '[[Expand(%s)]]' % macro.formatter.text(args) return macro.formatter.text(replacement) On the page, you use Get(foo) when you want to expand something. It may be too verbose compared with$foo or ${foo} - but I'm not sure if this feature is needed for most users. ## Question: How do I include inline material from an external link? I want to include some material from another site in-line. This ability is aluded to in the help, but the technique itself is not explicitly described. How do you do it? ## How to edit individual subtitles MediaWiki has this nice property that you canedit each subtitle individually instead of editing the whole page. Thatmakes it easy to locate the piece you want to modify in long pages. Isthis possible with MoinMoin too? If not, is there a way to ask for a new feature? • this could be done by Include with the editlink option look at HelpOn/Include ## How can I refer to an attachment in my User CSS URL I would like to upload a css file as an attachment and refer to it in User Preferences -- it this possible? • Just use the AttachFile get URL as shown on the AttachFilepage. Alternatively, you can also put the CSS directly on a page. Search this wiki for title containing CSS to see how. ## Include without <P>? Is there a way to include a page without breaking the current paragraph? • No. ## How do you give editing access to anybody as long as they are logged in? Search this page for "registered users." ## Formulas Is there any "best" way to integrate mathematical formulas in MoinMoin 1.5 betax Wiki Pages? ## How do I remove attachments from a page Sorry, maybe this question is a little bit dump, but I've been looking through the documentation trying to figure out how to delete attachments on pages, but I didn't find anything. Maybe I missed something. But anyway. Would anybody be so kind to give me a hint on how to delete attachments. Thanks in advance. • Just use action AttachFile on the page. It lists your attachments and allows you to download, show or delete them. You should also remove the markup that refers to the attachment from your page, otherwise you will be asked to upload the attachment again. If there are many attachments on the page better you rename the page and add a prefix e.g. DeleteThisPage. Then delete the page and it's subdirs on the server that is much easier. -- ReimarBauer 2005-12-05 22:45:54 Thanks for your immediate reply. But when pressing the AttachFile I do not get a link to delete the attachment. There is just a link to load and show the attachment. Do I have to change the configuration of the wiki to see this action? 2013-06-19 04:56:24 Look into your wikiconfig.py if you have a line like this allowed_actions = ['DeletePage', 'AttachFile', 'RenamePage' ] and if you use acls then the acl right delete must be given to you. Or just try logging in. Thanks the delete right was missing in an acl. ## How do I make a form on a page? Is this even possible? I'd like to be able to design a form into a wiki page. I could then program an action to respond to the form, or redirect the form to another site which handles it. If MoinMoin doesn't let you create forms, are there any plans to in the future? If so, have you decided how they will be described in wiki format yet? • This is listed as "TODO" on HelpMiscellaneous/ExperimentalFeatures (and has been since at least 1.1 ) There's a macro Form.py that suggests that there is some support and a proposed markup, but I don't quite remember the markup. Probably best way is to steal code from one of the actions or macros that use forms (I started from userform.py), however you will end up coding your forms in HTML. -- RobertSeeger 2005-12-06 14:32:13 ## Alert icon when certain page changes? Hello. I'm setting up a basic intranet wiki with a likewise basic "announcements" page (I won't say "blog") that I'd like to link to on the frontpage Is there a way that users landing on the frontpage can be alerted when a new announcement has been posted? I'm thinking of an icon that stays up for 24 hrs after a new post goes up, or just a time-stamp next to the "announcments" link on the frontpage... Probably a simple solution is to use a page which first five lines are included to the FrontPage. New items need to be added always on top of this page. Look at HelpOnMacros/Include -- ReimarBauer 2005-12-27 21:59:04 ## Is it possible to figure out who has done the most updates? To get a vague impression, go to RecentChanges. To get exact numbers, write a macro reading the global edit-log. ## Words containing the /-character If I name an article AC/DC. The link in the top of the page is written AC/ DC with a space in it. Also if I click the AC part and article named AC is loaded. Is there a way of naming an article with words containing the / without this behaviour?? • No, as the slash is used as kind of path separator. Maybe make the page named ACDC or AcDc or AC\DC and a headline = AC/DC =on it. ## What are dict pages? In the configuration there are some entries more or less undocumented: page_dict_regex, page_form_regex, page_group_regex, page_template_regex I conjecture that "forms" are this not working feature (FeatureRequests/FormEditing, FormSamples) and groups are used for acl, but the other two? -- -- TobiasPolzin 2006-01-30 20:17:40 • dicts are used e.g. for extending the navi_bar with custom translatable items. • templates are used for creation of new pages, see the list there when you try to ## Viewing Document Title and Content Using The Include Macro I'm trying to put a blog-ish front-end on my wiki using the include macro. I'm having a few problems, so any help with these questions would be grealy appreciated. 1. Is there a way to display both the title of the page and the content using this macro? The HelpOnMacros/Include page infers that titles should be included by default, but I never see it. 2. I can't see the title of my included pages, even if I use the titlesonlyparameter. Here's the macro line that I'm using: • [[Include(^BlogTest/.*,, to="^----$", sort=descending, items=7, titlesonly)]]

• That macro doesn't show any content (which is expected) but it also doesn't show the titles. Is there something that I'm missing? If I get rid of the titlesonlyparameter, then I see the content, but no title.

Please show us which version you are trying (SystemInfo)

Q: I have an HTML file attached to some page. I link to it using attachment:something.html and that works fine.

However, this particular file is large, automatically generated one, and I would like to create links directing to the anchors in it, like:

attachment:something.html#line20052

This is not possible, whole something.html#line20052 string is considered to be the name of a new file.

Is there any patch/solution I could use, apart from using long, ugly, error-prone and due-to-change GET url?

• Thanks. - nosek

Look at HelpOnEditing/SubPages. On this page "HelpOnEditing/SubPages" is not rendered as a link (see first example). "HelpOnEditing/SubPagesXxxx" would, thus I conjecture that just links to the page itself are not rendered as links. Is this a bug or a feature?

• Of course this is a feature.

## ''' How can I insert background image to my page? '''

Is the a way in moinmoin where I can insert a background image aside from the color background.Coz I want my page to have a background image. Thanks.......

## How can I include Return characters in a table cell?

If a place text that includes returns (new lines) in a cell, the table breaks. In particular, this prevents me from placing a bulleted or numbered list in a cell. Is there a special character that I can use in a cell that will not break the table? Or is there a table format that will not break when it includes returns? I already tried a CVS table.

Thanks.

-- DavideAndrea Mar-17-2006 (try @ SIG @ without the blanks)

Do you speak about something like this?

 * one * two next cell

see MacroMarket/MiniPage -- ReimarBauer 2006-03-17 18:18:23

You could also use the Include macro inside a table cell to do this:

Create a page FooTasks with e.g. following contents:

-- Taufan 2011-01-06

## How can I change the text color in the table at the same using the width size?

• hello I'm working on a table and what I'd like to do is to change the text color of the table and give specific size of the table.But my problem is whenever I change the text color the size doesn't make on the size that I specify same as well on the size when the size is the size I specify but the color doesn't change. Thanks in advance and hope you will help me with this problem......

## Is there a way of creating discussion pages for every page like in Wikipedia ?

I want to set up an Internet Site for a non commercial Projekt. All People (about 30) involved should build the Internet Site together, wich is why a wiki is perfect.

Because of the Gui Editor and the fact that I don´t need a special database for it I would like to use MoinMoin

But we also want the Public to use the Pages for Information, so Discussion should be kept off the normal pages. Discussion should, like in Wikipedia, be visible by clicking on a standardized discussion Button.

Is there a way to achive this is MoinMoin, maybe an extension or a kind of macro ? btw: I dont want to Insert a discussion Link manually in every page.

Gunter Kramp

• I'd very much like that, too. It seems strange to me that there's no easy way to do this; a better answer than what amounts to "RTFM" would be nice, too. -- kamagurka 2006-08-23

• or look at PageEditor.py and change it for your needs

-- ReimarBauer 2006-03-22 04:02:18

## Add spaces in a line

What is the easiest way to add "n" spaces in a text line?

moin equivalent of "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"

Thanks

-- JeanJacquesKahn 2006-03-24 15:18:10

• Use backtick to surround the spaces (like           this). The spaces will be in a different font, but hopefully that doesn't matter.

like            this

-- SteveDavison 2006-03-24 16:37:55

Thanks -- JeanJacquesKahn 2006-03-27 08:32:18

## How to define a common group definition in a wiki farm?

We need to give rights to the same group of people on all the wikis of a farm  ex.: FarmAdminGroup .

I created a group definition page in the underlay pages that can be seen from any wiki, but the correct access rights are only granted after saving a local copy in each wiki.

Any idea? -- JeanJacquesKahn 2006-04-07 16:22:48

It should work. If it doesn't, it is maybe because of the wikis don't notice the updated page. In that case, you could remove the file data/cache/wikidicts/dicts_groups after updating the group page. If it still doesn't work, stop wiki, delete file, start wiki. If you run a moin 1.5.2+, please file a bug. -- ThomasWaldmann 2006-04-07 16:58:53

It helped indeed, thanks -- JeanJacquesKahn 2006-04-28 08:46:26

### UTC

How can I show UTC date and time in a similar way to Wikimedia (see http://en.wikipedia.org/wiki/UTC ) ????????

• Moin internally only uses UTC, but calculates your local time according to your UserPreferences setting on page view. If you set your timezone offset to 0, you get UTC. If you need both localtime here and UTC there, write some UTC date/time macros.

## Ignore New Line in Source code

Hello all, is it possible to ignore a new line in Wiki Text Mode? I want to do the following to improve the readability:

|| Cell 1      || Cell2 ||
|| Cell 3
second line
bla bla     || Cell4 ||

this should result to the following:

 Cell1 Cell2 Cell3 second line bla bal Cell4

A: No, the table parser can't parse that.

May be a continuation sign for a line could solve this too. If so please add a feature request about this. I am not sure if \ will be the right sign for this. -- ReimarBauer 2006-05-22 20:52:03

|| Cell 1      || Cell2 ||