On Tue, 2009-12-08 at 08:36 +0100, Frank Lin PIAT wrote:
> On Mon, 2009-12-07 at 11:48 -0500, Brent S. Elmer Ph.D. wrote:
> > % moin-mass-migrate
> [..]
> > File "/usr/lib/pymodules/python2.5/MoinMoin/web/contexts.py", line 132,
> > in cfg
> > raise NotFound('<p>No wiki configuration matching the URL found!</p>')
> > werkzeug.exceptions.NotFound: 404 Not Found
>
> > My /etc/moin/wikilist contains the following like it always has.
> >
> > www-data belmer.btv.ibm.com/profitwiki
> > www-data belmer.btv.ibm.com/infrawiki
> >
> > My farmconfig.py contains this:
> >
> > wikis = [
> > ("profitwiki", r"^belmer.btv.ibm.com/profitwiki.*$"), #to add
> > infrawiki bse 4-4-2008
> > ("infrawiki", r"^belmer.btv.ibm.com/infrawiki.*$"), #to add
> > infrawiki bse 4-4-2008
> > ]
>
> The leading caret is wrong, since the live wiki evaluate the full URL,
> including the protocol.
>
> I suggest you use something like:
> ("profitwiki", r".*://belmer.btv.ibm.com/profitwiki/.*"),
>
> Franklin
>
Okay, I see with the 1.9 version of python-moinmoin(or some previous
version) in the package farmconfig.py, they changed the example from
# for multiple wikis, do something like this:
#("moinmoin", r"^moinmo.in/.*$"),
#("moinmaster", r"^master.moinmo.in/.*$"),
to
# for multiple wikis, do something like this:
#("wiki1", r"^http://wiki1\.example\.org/.*$"),
#("wiki2", r"^http://wiki2\.example\.org/.*$"),
I made the change as you suggested and moin-mass-migrate worked.
However, after I restarted apache, I would get this error in the apache
log:
[Tue Dec 08 08:38:45 2009] [error] [client 127.0.0.1] mod_wsgi
(pid=12309): Target WSGI script '/var/www/profitwiki/moin.wsgi' cannot
be loaded as Python module.
[Tue Dec 08 08:38:45 2009] [error] [client 127.0.0.1] mod_wsgi
(pid=12309): Exception occurred processing WSGI script
'/var/www/profitwiki/moin.wsgi'.
[Tue Dec 08 08:38:45 2009] [error] [client 127.0.0.1] Traceback (most
recent call last):
[Tue Dec 08 08:38:45 2009] [error] [client 127.0.0.1] File
"/var/www/profitwiki/moin.wsgi", line 50, in <module>
[Tue Dec 08 08:38:45 2009] [error] [client 127.0.0.1] from
MoinMoin.server.server_wsgi import WsgiConfig, moinmoinApp
[Tue Dec 08 08:38:45 2009] [error] [client 127.0.0.1] ImportError: No
module named server.server_wsgi
[Tue Dec 08 08:38:48 2009] [error] [client 127.0.0.1] File does not
exist: /var/www/favicon.ico
[Tue Dec 08 08:39:10 2009] [error] [client 127.0.1.1] mod_wsgi
(pid=12309): Target WSGI script '/var/www/profitwiki/moin.wsgi' cannot
be loaded as Python module.
So, in order to get around that problem, I recopied moin.wsgi as user
www-data like this and did chmod to 755:
cp /usr/share/moin/server/moin.wsgi /var/www/profitwiki
cp /usr/share/moin/server/moin.wsgi /var/www/infrawiki
That got rid of the wsgi error.
However, when I tried to go to my wiki, I would get an error saying saying:
404 Not Found
No wiki configuration matching the URL found
If I change my farmconfig.py by adding http to look like this to be more like
the example in the package:
("profitwiki", r"^http://belmer.btv.ibm.com/profitwiki/.*$"), #to add
infrawiki bse 4-4-2008
("infrawiki", r"^http://belmer.btv.ibm.com/infrawiki/.*$"), #to add
infrawiki bse 4-4-2008
("profitwiki", r"^http://belmer/profitwiki/.*$"), #to add infrawiki bse
4-4-2008
("infrawiki", r"^http://belmer/infrawiki/.*$"), #to add infrawiki bse
4-4-2008
I get the following error in the apache log:
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] mod_wsgi (pid=16961):
Exception occurred processing WSGI script '/var/www/profitwiki/moin.wsgi'.
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] Traceback (most recent
call last):
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] File
"/usr/lib/pymodules/python2.5/werkzeug/utils.py", line 248, in __call__
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] return
self.app(environ, start_response)
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] File
"/usr/lib/pymodules/python2.5/MoinMoin/wsgiapp.py", line 251, in __call__
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] response =
run(context)
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] File
"/usr/lib/pymodules/python2.5/MoinMoin/wsgiapp.py", line 70, in run
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] response =
dispatch(request, context, action_name)
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] File
"/usr/lib/pymodules/python2.5/MoinMoin/wsgiapp.py", line 118, in dispatch
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] response =
handle_action(context, pagename, action_name)
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] File
"/usr/lib/pymodules/python2.5/MoinMoin/wsgiapp.py", line 177, in handle_action
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1]
handler(context.page.page_name, context)
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] File
"/usr/lib/pymodules/python2.5/MoinMoin/action/__init__.py", line 261, in do_show
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1]
content_only=content_only,
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] File
"/usr/lib/pymodules/python2.5/MoinMoin/Page.py", line 1134, in send_page
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1]
request.user.addTrail(self)
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] File
"/usr/lib/pymodules/python2.5/MoinMoin/user.py", line 882, in addTrail
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] if self._wantTrail():
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] File
"/usr/lib/pymodules/python2.5/MoinMoin/user.py", line 874, in _wantTrail
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] return (not
self.valid and self._request.cfg.cookie_lifetime[0] # anon sessions enabled
[Tue Dec 08 09:29:23 2009] [error] [client 127.0.0.1] TypeError: 'int' object
is unsubscriptable
So, my wiki is still broke.
Any ideas
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]