Re: Problems after Debian upgrade

"Karl O. Pinc" <[email protected]>
Newsgroups gmane.comp.web.wiki.moin.general
Message-ID <1370555691.12792.3@mofo>
It is often useful to see the /usr/share/doc/<packagename>/
README.Debian(.gz) file.  It may contain debian specific upgrade
instructions.

On 06/06/2013 02:03:41 AM, R.Bauer wrote:
> On 22.05.2013 19:17, Tasslehoff Burrfoot wrote:
> > First of all let me thank all of you for quick reply and for your
> > time :)
> >
> >> my guess is that you upgraded from python 2.6 to 2.7. This means
> >> that you might have to reinstall all python packages that you
> >> manually installed (like moin). Check your
> >> /usr/local/lib/python2.[67]/dist-packages. You will probably find
> >> MoinMoin in 2.6 but not in 2.7.
> >
> > I checked and confirm that under
> > /usr/local/lib/python2.6/dist-packages/ I got a MoinMoin file ad
> > directory, under /usr/local/lib/python2.7/dist-packages/ I got
> > nothing. --- ritz:/usr/local/lib/python2.6/dist-packages# ls -l
> > /usr/local/lib/python2.7/dist-packages/ totale 0
> > ritz:/usr/local/lib/python2.6/dist-packages# ls -l
> > /usr/local/lib/python2.6/dist-packages/ totale 6 drwxr-sr-x  2 root
> > staff  568 mar 18 23:12 jabberbot -rw-r--r--  1 root staff 3203 mar
> > 18 23:13 moin-1.9.7-py2.6.egg-info drwxr-sr-x 28 root staff 1688
> > mar 18 23:13 MoinMoin
> >
> > What should I do? I can safely create a symlink under
> > /usr/local/lib/python2.7/dist-packages/ to the
> > python2.6/dist-packages file and directory or there's a better
> > solution. I presume there's some compiled stuff in this directory.
> 
> 
> You can just copy the MoinMoin dir to the new location.
> But then remove all .pyc files. Have a look at the output  of
> cd  /usr/local/lib/python2.7/dist-packages/MoinMoin
> find . | grep .pyc$
> 
> if this is the right filter do a
> rm `find . | grep .pyc$`
> 
> (these are backticks, to enclose the right command)
> 
> or make it a list and remove it by a loop
> 
> Make sure that the directory and files could be read by the service
> user
> e.g.
> cd  /usr/local/lib/python2.7/dist-packages/
> chmod -R a+rX MoinMoin
> 
> >
> > Reguarding compile, I found this page
> > (http://moinmo.in/HelpOnUpdatingPython) and tried to lauch: python
> > -c "import compileall;
> > compileall.compile_dir('/usr/local/share/moin')" It seems to work
> > without error but still nothing under
> > /usr/local/lib/python2.7/dist-packages/ and nothing changed on the
> > website.
> >
> > I also tried to configure two alternatives for python using Debian
> > scripts (update-alternatives) but nothing changed, I presume
> > because wheezy mod_wsgi is compiled for the default distribution
> > python package (2.7.3).
> >
> > Obviously on every test I tried to restart Apache to reload
> > modules.
> >
> >> For every python upgrade, you need to run moin --config-dir=...
> >> --wiki-url=http://... maint cleancache for each of your wikis.
> >>
> >> Run the command using the same user as the moin process owner.
> >
> > I got some problems lauching this command (also as root or apache
> > user), I got this error: Traceback (most recent call last): File
> > "/usr/local/bin/moin", line 5, in <module> from
> > MoinMoin.script.moin import run ImportError: No module named
> > MoinMoin.script.moin
> 
> you get that message if your configured default python can't find the
> library
> 
> same happens likly with
> > python
> >>> import MoinMoin
> 
> Have also a look into the script
> 
> cat /usr/local/bin/moin
> 
> May be there is also a path set,
> 
> for comparison the content of that file we deliver:
> http://hg.moinmo.in/moin/1.9/file/4790615ddfb6/setup.py#l172
> 
> 
> 
> >
> > I thought it was caused by packages under Python directory, so I
> > tried to lauch It directly using python2.6 binary and it worked:
> > apache@ritz:~$ /usr/bin/python2.6 $(which moin)
> > --config-dir=/usr/local/share/moin --wiki-url=wiki/ maint
> > cleancache 2013-05-22 19:10:06,404 INFO MoinMoin.log:151 using
> > logging configuration read from built-in fallback in MoinMoin.log
> > module 2013-05-22 19:10:06,407 INFO MoinMoin.log:157 Running
> > MoinMoin 1.9.7 release code from
> > /usr/local/lib/python2.6/dist-packages/MoinMoin 2013-05-22
> > 19:10:07,341 WARNING MoinMoin.log:112
> > /usr/local/lib/python2.6/dist-packages/MoinMoin/support/pygments/
> plugin.py:39:
> >
> >
> UserWarning: Module pygments was already imported from
> > /usr/local/lib/python2.6/dist-packages/MoinMoin/support/pygments/
> __init__.pyc,
> >
> >
> but /usr/lib/python2.6/dist-packages is being added to sys.path
> > 2013-05-22 19:10:08,411 INFO MoinMoin.config.multiconfig:127 using
> > wiki config: /usr/local/share/moin/wikiconfig.pyc
> >
> >> BTW, you never should load mod_wsgi (needed by moin) and
> >> mod_python (needed by what?) at the same time.
> >>
> >> In fact, you should not use mod_python at all any more. It's dead
> >> and smells strangely since quite a while.
> >
> > You're right, I don't use mod_python, perhaps it's an old module
> > from previous setup, this server was installed as Debian etch and
> > upgraded to lenny, squeeze and now wheezy, on an old Via EPIA
> > 5000A. I immediately removed it.
> >
> > Thanks
> >
> > Tasslehoff Burrfoot
> >
> > --- Public PGP key block at http://tasslehoff.burrfoot.it/url/pgp
> >
> > 
> ------------------------------------------------------------------------------
> >
> >
> Try New Relic Now & We'll Send You this Cool Shirt
> > New Relic is the only SaaS-based application performance monitoring
> > service that delivers powerful full stack analytics. Optimize and
> > monitor your browser, app, & servers with just a few lines of code.
> > Try New Relic and get this awesome Nerd Life shirt!
> > http://p.sf.net/sfu/newrelic_d2d_may
> >
> 
> 




Karl <[email protected]>
Free Software:  "You don't pay back, you pay forward."
                 -- Robert A. Heinlein


------------------------------------------------------------------------------
How ServiceNow helps IT people transform IT departments:
1. A cloud service to automate IT design, transition and operations
2. Dashboards that offer high-level views of enterprise services
3. A single system of record for all IT processes
http://p.sf.net/sfu/servicenow-d2d-j
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.