[Zope] newbie: superuser login authorization failed

Tony McDonald tony.mcdonald@ncl.ac.uk
Sun, 17 Jun 2001 15:32:00 +0100


On 17/6/01 12:58 am, "Nicole Lallande" <nicole@nmlconsulting.com> wrote:

> Source of installation binaries:
> http://starship.python.net/crew/jrush/Zope/Zope232.html - rpm install
> with zserver rather than apache pcgi install (I am still trying the rpm
> installation vs tarball.)
> 

Ok, I'll probably get battered for this, but people seem to have fewer
problems with the tarball than with the RPM. Chris mentioned the linux
binary release, and as someone who started off with binary releases
(Solaris) I can state that they *do work*.


> OS:  RH7.0
> Python: python-1.5.2-27
> Browser: NCommunicator 4.77
> Resources: 
> 1. mailing list archive:  I found a thread written by Darci and Chris -
> Darci was having the problem of loging in as superuser - but then seemed
> to resolve the problem by stopping and restarting zope - which I did ad
> naseum.
> 2. zopedocs
> 3. zope help
> 
> I know it isn't the information in the access file because I ran 'python
> zpasswd.py -u superuser -p mynewpassword -d localhost' - nada -
> 'Authorization failed'  I have tried using NN6 - no joy.
> 

I use this:

% python zpasswd.py -u admin -p 'somerubbish' access

(I note you haven't got a filename in the above zpasswd line).

To create the access file (it can also be called 'inituser', I prefer
access).

Then, I do this (on a stock install)

% ./start

And get this 

[9:14pm tonymcd ~/software/Zope-2.3.3b1-src]% ./start
------
2001-06-16T20:15:00 INFO(0) ZServer HTTP server started at Sat Jun 16
21:15:00 2001
        Hostname: localhost
        Port: 8080
------
2001-06-16T20:15:00 INFO(0) ZServer FTP server started at Sat Jun 16
21:15:00 2001
        Hostname: localhost
        Port: 8021


> a look at the authfailed page source shows:
> 
> <!--
> Traceback (innermost last):
> File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 223,
> in publish_module
> File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 187,
> in publish
> File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 162,
> in publish
> File /usr/lib/python1.5/site-packages/ZPublisher/BaseRequest.py, line
> 462, in traverse
> File /usr/lib/python1.5/site-packages/ZPublisher/HTTPResponse.py, line
> 588, in unauthorized
> Unauthorized: (see above)
> 
> -->
> 
> well - that went right over MY head!
> 

It's a traceback - and yes to people new to Zope, it is daunting. What it's
saying is that you're unauthorized for the URL you were trying to look at.
Was it

http://localhost:8080/manage ?

'cos that's the page most people want to get into after starting a Zope
installation up.

> On the mailing list whenever anyone mentions having a problem with the
> rpm installation the response is try the
> tarball install.  I really do not want to do that if I can avoid it so
> if there is anyone out there who can help me with this..please?
> 
> TIA,
> 
> Nicole

There's the tarball source installation, and the tarball binary
installation. The binary releases are only made for beta and final versions
of Zope (that's why there's no binary for 2.4.0a1 - 'here be dragons!').

If your system has a python installation and a C compiler, installing from
the source tarball boils down to this;

% python wo_pcgi.py

And then sit back and watch as things are compiled up before you.

Later on, you might want to integrate with Apache, and so might do

% python w_pcgi.py

To enable the Persistent CGI machinery.

But, threads on the list recently (VirtualHostMonsters and Apache) have
convinced me to nuke all our CGI machinery and use Zserver (which is what is
actually sitting on port 8080) instead. That is, you may not *need* to do
the 
% python w_pcgi.py
dance.

What I would suggest is
1) D/L the binary tarball for Linux x-86
2) Follow those instructions and you *will* be up and running in no time

Or if you have a working python 1.5.2 and C compiler
1) D/L the source tarball for 2.3.2 and
2) % python wo_pcgi.py

There's a lot of information to assimilate when first using Zope Nicole, not
least the different publishing model the system uses.

It's definitely worth it - we have about a dozen developers thundering away
at Zope now and our productivity is dramatically higher than the old
Perl/PHP days...

HTH
Tone
-- 
Dr Tony McDonald,  Assistant Director, FMCC, http://www.fmcc.org.uk/
The Medical School, Newcastle University Tel: +44 191 243 6140
A Zope list for UK HE/FE  http://www.fmcc.org.uk/mailman/listinfo/zope