[Zope] Re: Using property() function in Zope 2.8
Fred Drake wrote: On 7/6/06, Rob Miller <[EMAIL PROTECTED]> wrote: it's not an answer to your original question (i have nothing to add to what fred already replied) but TeamSpace solves this by using a ComputedAttribute instead of a property for the dynamic local roles. Yeah, I forgot all about ComputedAttribute. That's probably what you want if your class is an ExtensionClass. Yeah. I remember too now. I don't think I have used one of those since 2000 in plain Zope. Thanks. -- hilsen/regards Max M, Denmark http://www.mxm.dk/ IT's Mad Science Phone: +45 66 11 84 94 Mobile: +45 29 93 42 96 ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Zope installation woes
no offense, but you should really listen to those advice given. it'll take you lesser time to get a working web application than to do it "on the job" as you said. i hope you do realise that on-the-job could also mean researching and studying the work at hand before actually being more productive. you didn't read the docs properly to get zope running, IMHO. if you wanna get zope+cmf running well and to what you want, start reading and learn. On 7/6/06, russ <[EMAIL PROTECTED]> wrote: o.k. when running that I saw this: unix 2 [ ACC ] STREAM LISTENING 546729 15600/python /home/zope/instance/var/zopectlsock.15599 Does this mean it's running? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 06 July 2006 15:44 To: russ Subject: RE: [Zope] Zope installation woes if your zope instance does not show in the output from: netstat -ap | grep LISTEN (issued as root) then there's no sense in trying to figure out how to telnet to localhost 8080 (or whatever port your zope is running on) as there's nothing listening for the inbound connection. i.e., until your zope instance is running correctly so shows up in the netstat output, trying to connect inbound to it will fail and prove nothing. [there are a variety of things that can cause an inbound connection to a service to fail. you need to take the debugging one step at a time, starting with confirming that there's actually a service running.] - Rick Original Message > Date: Thursday, July 06, 2006 10:28:46 AM +0100 > From: russ <[EMAIL PROTECTED]> > Subject: RE: [Zope] Zope installation woes > > What does it mean if this is listed under ps -eLf: > > zope 15601 15600 15601 01 Jul05 ?00:00:05 > /usr/bin/python /usr/ > > ...but isn't anywhere to be seen under netstat -p ? > > & how do I telnet to port 8080 *on* the same machine? > > Sorry :S > > -Original Message- > From: replies-lists-zope > Sent: 05 July 2006 18:59 > To: russ > Subject: RE: [Zope] Zope installation woes > > use the "ps" command to see that that process is still running. also > use the "netstat" command (with the -p flag (as root)) to see/confirm > what port zope is listening on. > > if it's running, on port 8080, then try to telnet to port 8080, both > as "localhost 8080" and "hostname 8080" (both from the server > itself). if both of those work, then telnet to "hostname 8080" from > a "remote" machine (e.g., the desktop machine you've been using your > browser from). if the telnets from the server work, but the telnet > from the "remote" host doesn't, then your issue is likely to be a > firewall. > > > > > Original Message >> Date: Wednesday, July 05, 2006 06:24:40 PM +0100 >> From: russ <[EMAIL PROTECTED]> >> To: 'Jonathan' <[EMAIL PROTECTED]>, zope@zope.org >> Subject: RE: [Zope] Zope installation woes >> >> Well I've tried to follow your steps with the exception of point 15 >> (mkzopeinstance.py doesn't reside in my python directory, it's in the >> zope/bin folder). At the last stage I hit enter and got: >> >> bash-3.00$ ./zopectl start >> . daemon process started, pid=15601 >> >> And now what? http://www.domain.tld:8080 still produces nothing. >> >> :( >> >> ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev ) ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: Using property() function in Zope 2.8
On 7/6/06, Rob Miller <[EMAIL PROTECTED]> wrote: it's not an answer to your original question (i have nothing to add to what fred already replied) but TeamSpace solves this by using a ComputedAttribute instead of a property for the dynamic local roles. Yeah, I forgot all about ComputedAttribute. That's probably what you want if your class is an ExtensionClass. -Fred -- Fred L. Drake, Jr. "Every sin is the result of a collaboration." --Lucius Annaeus Seneca ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: Using property() function in Zope 2.8
On Thu, 06 Jul 2006 21:19:36 +0200, Max M wrote: > I needed to dynamically generate local roles for an Archetypes based > content object today. > > Different layers in my Plone stack breaks all rules and reads the > __ac_local_roles__ variable directly, instead of calling get_local_roles() > > So to maximize the compatibility between Zopes zmi and Plones local roles > management I wanted to make '__ac_local_roles__' a property with setters > and getters. it's not an answer to your original question (i have nothing to add to what fred already replied) but TeamSpace solves this by using a ComputedAttribute instead of a property for the dynamic local roles. all of the pertinent code is here, hope you find it useful: http://svn.plone.org/view/collective/teamspace/tags/1.4/security.py?rev=24604&view=auto -r ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Trying to trap ConflictError - Resolved!
- Original Message - From: <[EMAIL PROTECTED]> To: "Jonathan" <[EMAIL PROTECTED]> Cc: "Michael Dunstan" <[EMAIL PROTECTED]>; Sent: Thursday, July 06, 2006 2:56 PM Subject: Re: [Zope] Trying to trap ConflictError Jonathan wrote at 2006-7-6 09:53 -0400: ... From what I understand from the above code, the error is being raised because the oid already exists and the object pointed to by the old oid is different from the object pointed to by the new oid, hence the conflict error. You interpretation is slightly wrong. What really differs is not the object (or "oid") but the timestamp. Each persistent object has a timestamp "_p_serial" which identifies the transaction that made the last change to the object. When an object is loaded from the ZODB, its timestamp is recorded (in "_p_serial"). When later a change to the object should be commited, the recorded timestamp is compared to the object's current timestamp in the ZODB. If the timestamps differ, then the object was modified by a concurrent transaction and our modification is likely to be based on stale information. As a result a "ConflictError" is raised. Thanks Dieter, this got me pointed in the right direction... The problem was due to multiple processes simultaneously accessing a 'MakeId' routine (as some had suggested earlier in this investigation!). Even though the routine returned a 10 digit id consisting of a 7 digit timestamp + 3 random digits, there were still id collisions. Changing the MakeId routine to return a 10 character string (all 10 characters randomly generated) eliminated the ConflictErrors that were occurring during heavy load testing. Thanks to everyone for the great assistance!!! Jonathan ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Trying to trap ConflictError
On 7/7/06, Michael Dunstan <[EMAIL PROTECTED]> wrote: An oid is an identifier for a persistent state of an object. As the state of an object evolves from transaction to transaction it gets a new oid for each state. Two concurrent transactions that involve the same object will start with the same state, i.e. the same oid, for that object. Sorry. Ignore that. :-( Note to self, don't even read email before morning caffeine intake. ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Trying to trap ConflictError
Jonathan wrote at 2006-7-6 09:53 -0400: > ... >>From what I understand from the above code, the error is being raised >because the oid already exists and the object pointed to by the old oid is >different from the object pointed to by the new oid, hence the conflict >error. You interpretation is slightly wrong. What really differs is not the object (or "oid") but the timestamp. Each persistent object has a timestamp "_p_serial" which identifies the transaction that made the last change to the object. When an object is loaded from the ZODB, its timestamp is recorded (in "_p_serial"). When later a change to the object should be commited, the recorded timestamp is compared to the object's current timestamp in the ZODB. If the timestamps differ, then the object was modified by a concurrent transaction and our modification is likely to be based on stale information. As a result a "ConflictError" is raised. -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Using property() function in Zope 2.8
On 7/6/06, Max M <[EMAIL PROTECTED]> wrote: There is a lot of things missing for brevity. It is an archetypes based class, and all kinds of interesting stuff is happening in that stack. Ok, well, I don't know archetypes myself; hopefully someone with more specific knowledge of that can help. Specific code for the get/set/del functions is probably required, at least. I tried to check that out. But then it says something like: "_PropTest__mxm__ac_local_roles__ No such attribute" That suggests that there's metaclass stuff going on, or the specific code differs from the example shown in relevant details (or both). -Fred -- Fred L. Drake, Jr. "Every sin is the result of a collaboration." --Lucius Annaeus Seneca ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Using property() function in Zope 2.8
On 7/6/06, Max M <[EMAIL PROTECTED]> wrote: This code below works in plain Python. But when I add them to my zope class, and run the tester() method I get an "Attributer Error: __ac_local_roles__" Descriptors in general are not guarantteed to work on old-style classes. Your PropTest class certainly looks like it falls into that category (I'm assuming you didn't elide anything for brevity), so I wouldn't expect it to work. That said, reading such a descriptor will work for classic classes. The real error is getting masked, however: it's not that __ac_local_roles__ isn't defined, it's that __mxm__ac_local_roles__ isn't defined, and the getter isn't dealing with that effectively (or, it is, depending on your opinion). -Fred -- Fred L. Drake, Jr. "Every sin is the result of a collaboration." --Lucius Annaeus Seneca ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Trying to trap ConflictError
On 7/7/06, Jonathan <[EMAIL PROTECTED]> wrote: I haven't been able to determine how the oid's are generated, other than "little-endian 64-bit unsigned integers that will be assigned more or less sequentially", but I can't figure out how the same oid is being used twice (on the other hand I could be totally off-base as I am really way over my head here!). An oid is an identifier for a persistent state of an object. As the state of an object evolves from transaction to transaction it gets a new oid for each state. Two concurrent transactions that involve the same object will start with the same state, i.e. the same oid, for that object. Some detail about how BTrees behave can be found in http://www.zope.org/Wikis/ZODB/BTreeConflictResolution Also might be illustrative to run fsdump to see what is happening in your transactions. See http://www.zope.org/Wikis/ZODB/FileStorageBackup. You'll need FileStorage for that. And that only shows you details of successful transactions. cheers michael ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Using property() function in Zope 2.8
I needed to dynamically generate local roles for an Archetypes based content object today. Different layers in my Plone stack breaks all rules and reads the __ac_local_roles__ variable directly, instead of calling get_local_roles() So to maximize the compatibility between Zopes zmi and Plones local roles management I wanted to make '__ac_local_roles__' a property with setters and getters. My AT class was based via a few hops on: 'from ExtensionClass import Base'. And as far as I understand from the release notes Zope 2.8.x should use extension classes based on new style classes. So the property function should work. This code below works in plain Python. But when I add them to my zope class, and run the tester() method I get an "Attributer Error: __ac_local_roles__" Any ideas/comments? # -*- coding: latin-1 -*- class PropTest: def get__ac_local_roles__(self): return self.__mxm__ac_local_roles__ def set__ac_local_roles__(self, value): self.__mxm__ac_local_roles__ = value def del__ac_local_roles__(self): del self.__mxm__ac_local_roles__ __ac_local_roles__ = property(get__ac_local_roles__, set__ac_local_roles__, del__ac_local_roles__, "Local roles on object") def tester(self): return self.__ac_local_roles__ if __name__ == '__main__': p = PropTest() p.__ac_local_roles__ = 'working' print p.tester() -- hilsen/regards Max M, Denmark http://www.mxm.dk/ IT's Mad Science Phone: +45 66 11 84 94 Mobile: +45 29 93 42 96 ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
RE: [Zope] Zope installation woes
o.k. when running that I saw this: unix 2 [ ACC ] STREAM LISTENING 546729 15600/python /home/zope/instance/var/zopectlsock.15599 Does this mean it's running? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 06 July 2006 15:44 To: russ Subject: RE: [Zope] Zope installation woes if your zope instance does not show in the output from: netstat -ap | grep LISTEN (issued as root) then there's no sense in trying to figure out how to telnet to localhost 8080 (or whatever port your zope is running on) as there's nothing listening for the inbound connection. i.e., until your zope instance is running correctly so shows up in the netstat output, trying to connect inbound to it will fail and prove nothing. [there are a variety of things that can cause an inbound connection to a service to fail. you need to take the debugging one step at a time, starting with confirming that there's actually a service running.] - Rick Original Message > Date: Thursday, July 06, 2006 10:28:46 AM +0100 > From: russ <[EMAIL PROTECTED]> > Subject: RE: [Zope] Zope installation woes > > What does it mean if this is listed under ps -eLf: > > zope 15601 15600 15601 01 Jul05 ?00:00:05 > /usr/bin/python /usr/ > > ...but isn't anywhere to be seen under netstat -p ? > > & how do I telnet to port 8080 *on* the same machine? > > Sorry :S > > -Original Message- > From: replies-lists-zope > Sent: 05 July 2006 18:59 > To: russ > Subject: RE: [Zope] Zope installation woes > > use the "ps" command to see that that process is still running. also > use the "netstat" command (with the -p flag (as root)) to see/confirm > what port zope is listening on. > > if it's running, on port 8080, then try to telnet to port 8080, both > as "localhost 8080" and "hostname 8080" (both from the server > itself). if both of those work, then telnet to "hostname 8080" from > a "remote" machine (e.g., the desktop machine you've been using your > browser from). if the telnets from the server work, but the telnet > from the "remote" host doesn't, then your issue is likely to be a > firewall. > > > > > Original Message >> Date: Wednesday, July 05, 2006 06:24:40 PM +0100 >> From: russ <[EMAIL PROTECTED]> >> To: 'Jonathan' <[EMAIL PROTECTED]>, zope@zope.org >> Subject: RE: [Zope] Zope installation woes >> >> Well I've tried to follow your steps with the exception of point 15 >> (mkzopeinstance.py doesn't reside in my python directory, it's in the >> zope/bin folder). At the last stage I hit enter and got: >> >> bash-3.00$ ./zopectl start >> . daemon process started, pid=15601 >> >> And now what? http://www.domain.tld:8080 still produces nothing. >> >> :( >> >> ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Trying to trap ConflictError
- Original Message - From: "Michael Dunstan" <[EMAIL PROTECTED]> To: "Jonathan" <[EMAIL PROTECTED]> Cc: Sent: Wednesday, July 05, 2006 5:15 PM Subject: Re: [Zope] Trying to trap ConflictError TempoaryStorage.py has a few tuning constants. The above error reads as though RECENTLY_GC_OIDS_LEN is too small for your application. It may well be that the default tuning of TempoaryStorage does not match your application very well. It would be useful to try FileStorage to help decide on where to focus attention. If FileStorage behaves a lot better then that also suggests that TempoaryStorage is miss-tuned for your application. Thanks for the idea Micheal... as a test I changed from TemporaryStorage to FileStorage to see if the ConflictErrors would 'go away'. However, the ConflictErrors still occur! This leads me to believe that the problem is not related to TemporaryStorage. Further investigation led to the discovery that ConflictErrors are being raised by TemporaryStorage and FileStorage in the same 'store' routines. Here is the relevant code from TemporaryStorage: def store(self, oid, serial, data, version, transaction): if transaction is not self._transaction: raise POSException.StorageTransactionError(self, transaction) self._lock_acquire() try: if self._index.has_key(oid): oserial=self._index[oid] if serial != oserial: newdata = self.tryToResolveConflict( oid, oserial, serial, data) if not newdata: raise POSException.ConflictError( oid=oid, serials=(oserial, serial), data=data)# * Conflict Error raised here else: data = newdata else: oserial = serial newserial=self._tid self._tmp.append((oid, data)) return serial == oserial and newserial or ResolvedSerial finally: self._lock_release() From what I understand from the above code, the error is being raised because the oid already exists and the object pointed to by the old oid is different from the object pointed to by the new oid, hence the conflict error. I haven't been able to determine how the oid's are generated, other than "little-endian 64-bit unsigned integers that will be assigned more or less sequentially", but I can't figure out how the same oid is being used twice (on the other hand I could be totally off-base as I am really way over my head here!). Once again, any and all ideas, comments, suggestions are greatly appreciated! Jonathan ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Zope installation woes
Thanks for your help guys, much appreciated. I'll see what I can find on the subject. R. -Original Message- From: Jonathan [mailto:[EMAIL PROTECTED] Sent: 06 July 2006 13:08 To: russ; zope@zope.org Subject: Re: [Zope] Zope installation woes - Original Message - From: "russ" <[EMAIL PROTECTED]> To: "'Sascha Welter'" <[EMAIL PROTECTED]>; Sent: Thursday, July 06, 2006 5:38 AM Subject: RE: [Zope] Zope installation woes >I agree Sascha, I would prefer to much more grounded in the ways of the > command line before attempting this stuff. I'm trying to get this running > as I was hoping that it wouldn't be too involved and would be able to get > busy creating Plone sites. I don't have the luxury of time to learn more > about this in general beforehand and so made the decision to learn "on the > job" as it were. You may see this as foolish, and it probably is, but I > entered into this hoping that I wouldn't have to get my hands too dirty. > I > now find myself in uncharted territory, not wanting to turn back. > > So do you think I should throw in the towel now? If you only have one server available and if it is a production server, then you need to think about the ramifications of crashing that server. 'Production server' means different things to different organizations, and if no-one is going to be screaming at you if you kill the server then carry on! However, if your organization takes a dim view of production server downtime, then I would caution you against proceeding! You don't need to be a linux expert to install zope, but you do need at least a rudimentary understanding of how linux works and how some basic commands work. I would recommend spending some time reading the intro chapters of some linux documentation (you can find some at http://www.linux.org/docs/, and there is a good doc at: http://www.centos.org/docs/4/html/rhel-rg-en-4/) - it may seem like a waste of time, but it will save you time and aggravation in the future. If you do not want to spend the time on linux/zope and you just want to 'get working', you could look at some of the zope hosting companies (they already have zope up and running, and they look after maintaining the 'infrastructure', which lets you focus on your application). Jonathan ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Zope installation woes
- Original Message - From: "russ" <[EMAIL PROTECTED]> To: "'Sascha Welter'" <[EMAIL PROTECTED]>; Sent: Thursday, July 06, 2006 5:38 AM Subject: RE: [Zope] Zope installation woes I agree Sascha, I would prefer to much more grounded in the ways of the command line before attempting this stuff. I'm trying to get this running as I was hoping that it wouldn't be too involved and would be able to get busy creating Plone sites. I don't have the luxury of time to learn more about this in general beforehand and so made the decision to learn "on the job" as it were. You may see this as foolish, and it probably is, but I entered into this hoping that I wouldn't have to get my hands too dirty. I now find myself in uncharted territory, not wanting to turn back. So do you think I should throw in the towel now? If you only have one server available and if it is a production server, then you need to think about the ramifications of crashing that server. 'Production server' means different things to different organizations, and if no-one is going to be screaming at you if you kill the server then carry on! However, if your organization takes a dim view of production server downtime, then I would caution you against proceeding! You don't need to be a linux expert to install zope, but you do need at least a rudimentary understanding of how linux works and how some basic commands work. I would recommend spending some time reading the intro chapters of some linux documentation (you can find some at http://www.linux.org/docs/, and there is a good doc at: http://www.centos.org/docs/4/html/rhel-rg-en-4/) - it may seem like a waste of time, but it will save you time and aggravation in the future. If you do not want to spend the time on linux/zope and you just want to 'get working', you could look at some of the zope hosting companies (they already have zope up and running, and they look after maintaining the 'infrastructure', which lets you focus on your application). Jonathan ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
RE: [Zope] Zope installation woes
I agree Sascha, I would prefer to much more grounded in the ways of the command line before attempting this stuff. I'm trying to get this running as I was hoping that it wouldn't be too involved and would be able to get busy creating Plone sites. I don't have the luxury of time to learn more about this in general beforehand and so made the decision to learn "on the job" as it were. You may see this as foolish, and it probably is, but I entered into this hoping that I wouldn't have to get my hands too dirty. I now find myself in uncharted territory, not wanting to turn back. So do you think I should throw in the towel now? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Sascha Welter Sent: 06 July 2006 10:14 To: zope@zope.org Subject: RE: [Zope] Zope installation woes (Wed, Jul 05, 2006 at 12:00:08PM -0400) [EMAIL PROTECTED] wrote/schrieb/egrapse: > From: "russ" <[EMAIL PROTECTED]> > Subject: RE: [Zope] Zope installation woes > Firstly I'll just mention a little bit more about the server. We have > cPanel and Apache running. There's a number of accounts setup in cPanel and It appears that this is a production server. ... Jonathan wrote: > If zope is not running try starting zope with the command: ./zopectl fg > this should allow you to see any errors that are generated while zope > tries to start up. good advice ... russ wrote: > I can't see anything relating to zope specifically & running the zopect1 > command results in this: > > [EMAIL PROTECTED] [/usr/local/zope/instance3/bin]# > /usr/local/zope/instance3/bin/zopect1 fg > -bash: /usr/local/zope/instance3/bin/zopect1: No such file or directory ... later Jonathan replied: > Don't give up! And now my point: Jonathan, I disagree here. Russ, you are running a command you don't know about (and you don't even care enough to check the spelling) as *root* on a *production* server. Please notify the servers administrator and/or owner about this. You shouldn't be allowed near a root prompt. At least till you've done your homework to the extend that you pay attention before doing anything as root. Besides, nobody told you to do this as root. When giving commands as root, you can destroy everything that is on that server. For starters try it with `rm -rf /`. Why don't you try the installation first on a test machine or personal workstation? We all have to learn stuff first, but a production server isn't a learning environment. Nowadays it is *very* easy to get a Unix clone system to play around with. There is also documentation to be found about Zope and System Administration in general, for free on the Internet. [Stepping down from Soap Box] Have a nice day + Regards, Sascha ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev ) ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
RE: [Zope] Zope installation woes
What does it mean if this is listed under ps -eLf: zope 15601 15600 15601 01 Jul05 ?00:00:05 /usr/bin/python /usr/ ...but isn't anywhere to be seen under netstat -p ? & how do I telnet to port 8080 *on* the same machine? Sorry :S -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 05 July 2006 18:59 To: russ Subject: RE: [Zope] Zope installation woes use the "ps" command to see that that process is still running. also use the "netstat" command (with the -p flag (as root)) to see/confirm what port zope is listening on. if it's running, on port 8080, then try to telnet to port 8080, both as "localhost:8080" and "hostname:8080" (both from the server itself). if both of those work, then telnet to "hostname:8080" from a "remote" machine (e.g., the desktop machine you've been using yoru browser from). if the telnets from the server work, but the telnet from the "remote" host doesn't, then your issue is likely to be a firewall. Original Message > Date: Wednesday, July 05, 2006 06:24:40 PM +0100 > From: russ <[EMAIL PROTECTED]> > To: 'Jonathan' <[EMAIL PROTECTED]>, zope@zope.org > Subject: RE: [Zope] Zope installation woes > > Well I've tried to follow your steps with the exception of point 15 > (mkzopeinstance.py doesn't reside in my python directory, it's in the > zope/bin folder). At the last stage I hit enter and got: > > bash-3.00$ ./zopectl start > . daemon process started, pid=15601 > > And now what? http://www.domain.tld:8080 still produces nothing. > > :( > > > -Original Message- > From: Jonathan [mailto:[EMAIL PROTECTED] > Sent: 05 July 2006 17:14 > To: russ; zope@zope.org > Subject: Re: [Zope] Zope installation woes > > > - Original Message - > From: "russ" <[EMAIL PROTECTED]> > To: > Sent: Wednesday, July 05, 2006 11:37 AM > Subject: RE: [Zope] Zope installation woes > > >> O.k. thanks, >> >> There are a number of lines like this: >> >> mailman 2485 2468 2485 01 Jun29 ?00:00:00 >> /usr/bin/python2.4 /u >> >> ...and a few like this: >> >> root 12796 11967 12796 01 13:10 pts/100:00:00 >> /usr/bin/python /usr/ > > These are not zope entries, you are looking for something like: > > zope 3158 1 3158 01 07:52 ?00:00:00 > /usr/local/bin/python > /usr/local/Zope-2.9.2/lib/python/zdaemon/zdrun.py -S > /usr/local/Zope-2.9.2/l > > zope 3159 3158 3159 05 07:52 ?00:00:02 > /usr/local/bin/python > /usr/local/Zope-2.9.2/lib/python/Zope2/Startup/run.py -C > /apps/zope/etc/zope > > > >> I can't see anything relating to zope specifically & running the >> zopect1 command results in this: >> >> [EMAIL PROTECTED] [/usr/local/zope/instance3/bin]# >> /usr/local/zope/instance3/bin/zopect1 fg >> -bash: /usr/local/zope/instance3/bin/zopect1: No such file or >> directory > > in your local zope/bin directory you should have some script files > like: runzope, runzope.bat and zopectl (this is what I have with zope > 2.9.2 installation) > > If you do not have these files, then something is truly pooched. > > Here are the steps I used to install zope 2.9.2 (linux os) > > 1) download zope 2.9.2 tarball into /usr/local/src (I used wget) > 2) tar -xzf the zope tarball (unpack it) > 3) change directory (cd) to the new zope subdirectory (created by the > tar command) > 4) make sure you have python 2.4.2 (this is for zope 2.9.2, check > what you need for zope 2.9.3). My python 2.4.2 is installed in > /usr/local/bin and this directory is contained with the PATH > environment variable (type echo $PATH at the command prompt - if the > directory containing your python 2.x is > > not in PATH you will need to modify PATH) > 5) at the command line enter: ./configure > 6) at the command line enter: make > 7) at the command line enter: make install(This will install zope > in /usr/local/zope-2.9.x) > > Now you need to add a 'zope' user to your system (if you do not > already have > > one) > 8) cd /etc > 9) groupadd zope (unless you already have a zope group defined) > 10) useradd -g zope zope (this creates a zope user) > 11) passwd zope (sets a password for the new user) > 12) usermod -d /apps/zope zope (sets the home directory for the new > user to /apps/zope) > > Now you need to create a zope instance: > > 13) change directory to /usr/local/zope-2.9.x/bin > 14) su zope (change to the zope user you created earlier) > 15) at the command line enter: /usr/local/bin/python > mkzopeinstance.py (note: replace /usr/local/bin/python with the > location of your python 2.4.x installation) > You will be prompted for a zope instance home (i use /apps/zope), a > username > > and a password (your zope admin account) > 16) change directory to the new zope instance home (eg. cd > /apps/zope) and you should see several subdirectories. > 17) check the ownership of the directories/files - they should all be > owned by zope and belong t
RE: [Zope] Zope installation woes
(Wed, Jul 05, 2006 at 12:00:08PM -0400) [EMAIL PROTECTED] wrote/schrieb/egrapse: > From: "russ" <[EMAIL PROTECTED]> > Subject: RE: [Zope] Zope installation woes > Firstly I'll just mention a little bit more about the server. We have > cPanel and Apache running. There's a number of accounts setup in cPanel and It appears that this is a production server. ... Jonathan wrote: > If zope is not running try starting zope with the command: ./zopectl fg > this should allow you to see any errors that are generated while zope > tries to start up. good advice ... russ wrote: > I can't see anything relating to zope specifically & running the zopect1 > command results in this: > > [EMAIL PROTECTED] [/usr/local/zope/instance3/bin]# > /usr/local/zope/instance3/bin/zopect1 fg > -bash: /usr/local/zope/instance3/bin/zopect1: No such file or directory ... later Jonathan replied: > Don't give up! And now my point: Jonathan, I disagree here. Russ, you are running a command you don't know about (and you don't even care enough to check the spelling) as *root* on a *production* server. Please notify the servers administrator and/or owner about this. You shouldn't be allowed near a root prompt. At least till you've done your homework to the extend that you pay attention before doing anything as root. Besides, nobody told you to do this as root. When giving commands as root, you can destroy everything that is on that server. For starters try it with `rm -rf /`. Why don't you try the installation first on a test machine or personal workstation? We all have to learn stuff first, but a production server isn't a learning environment. Nowadays it is *very* easy to get a Unix clone system to play around with. There is also documentation to be found about Zope and System Administration in general, for free on the Internet. [Stepping down from Soap Box] Have a nice day + Regards, Sascha ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )