ZODB install time error
Hi, I hope this is the right forum for me to ask for help. If not, I apologize, but please do direct me to the right place. I am trying to install ZODB 3.4. The OS is Scientific Linux 4.2 on i386 box. Python version is 2.3.4. GCC version is 3.4.4. python and python-devel are installed as rpms. I executed the "python setup.py build". And then when I execute the "python test.py", I get these kind of errors, many of them //== Error in test checkReconnectReadOnly (ZEO.tests.testConnection.FileStorageReconnectionTests) Traceback (most recent call last): File "build/lib.linux-i686-2.3/ZEO/tests/ConnectionTests.py", line 122, in tearDown os.waitpid(pid, 0) OSError: [Errno 10] No child processes ==// I request for help on this. Thanks a lot for any help or hints. Regards, Nagaraj -- +----------------------------------+--------------------------------------+ Nagaraj Panyam | Office tel: +91-22-22782610 Dept of High Energy Physics | Office fax: +91-22-22804610 Tata Instt. of Fundamental Research| Home tel : +91-22-22804936 Mumbai - 400 005, INDIA | **Email** : pn@tifr.res.in +----------------------------------+--------------------------------------+
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 P. Nagaraj wrote:
Hi,
I hope this is the right forum for me to ask for help. If not, I apologize, but please do direct me to the right place.
I am trying to install ZODB 3.4. The OS is Scientific Linux 4.2 on i386 box. Python version is 2.3.4. GCC version is 3.4.4. python and python-devel are installed as rpms.
I executed the "python setup.py build". And then when I execute the "python test.py", I get these kind of errors, many of them
//== Error in test checkReconnectReadOnly (ZEO.tests.testConnection.FileStorageReconnectionTests) Traceback (most recent call last): File "build/lib.linux-i686-2.3/ZEO/tests/ConnectionTests.py", line 122, in tearDown os.waitpid(pid, 0) OSError: [Errno 10] No child processes ==//
I request for help on this. Thanks a lot for any help or hints.
Regards, Nagaraj
I'm CC'ing the 'zodb-dev' mailing list, which is where the folks who maintain ZODB hand out. Tres. - -- =================================================================== Tres Seaver +1 202-558-7113 tseaver@palladion.com Palladion Software "Excellence by Design" http://palladion.com -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFE4LYH+gerLs4ltQ4RAvZKAKCaRdr17VHIRk86dr90Y39d6j+FqQCfdkce TJog1Lh7PhKFbdlTXWKb8bM= =R5xv -----END PGP SIGNATURE-----
P. Nagaraj wrote at 2006-8-14 22:56 +0530:
... I executed the "python setup.py build". And then when I execute the "python test.py", I get these kind of errors, many of them
//== Error in test checkReconnectReadOnly (ZEO.tests.testConnection.FileStorageReconnectionTests) Traceback (most recent call last): File "build/lib.linux-i686-2.3/ZEO/tests/ConnectionTests.py", line 122, in tearDown os.waitpid(pid, 0) OSError: [Errno 10] No child processes ==//
The "waitpid" call should get rid of so called "Zombie" processes (a died child process -- not yet acknowledged by the parent). If for some reason the server could not be created in the first place, then there will be no dead child to reap off. Furthermore, some *nixes allow to call for automatic child reaping *AND* may propagate this option automatically to child processes. In those cases, "waitpid" may non deterministically fail (if the OS was quicker to reap the child). I would put a "try: ... except OSError: pass" around the "waitpid". If there is no child (that's the error you are told about), then there is no Zombie and no need for "waitpid". -- Dieter
Hi Diether, On Tue, 15 Aug 2006, Dieter Maurer wrote:
P. Nagaraj wrote at 2006-8-14 22:56 +0530:
... I executed the "python setup.py build". And then when I execute the "python test.py", I get these kind of errors, many of them
//== Error in test checkReconnectReadOnly (ZEO.tests.testConnection.FileStorageReconnectionTests) Traceback (most recent call last): File "build/lib.linux-i686-2.3/ZEO/tests/ConnectionTests.py", line 122, in tearDown os.waitpid(pid, 0) OSError: [Errno 10] No child processes ==//
The "waitpid" call should get rid of so called "Zombie" processes (a died child process -- not yet acknowledged by the parent).
If for some reason the server could not be created in the first place, then there will be no dead child to reap off.
Furthermore, some *nixes allow to call for automatic child reaping *AND* may propagate this option automatically to child processes. In those cases, "waitpid" may non deterministically fail (if the OS was quicker to reap the child).
I would put a "try: ... except OSError: pass" around the "waitpid". If there is no child (that's the error you are told about), then there is no Zombie and no need for "waitpid".
Your suggestion worked. But one error came up. [ZODB3-3.4.0]# python test.py Running tests from build/lib.linux-i686-2.3 Running unit tests: Error in test testUmask (zdaemon.tests.testzdrun.ZDaemonTests) Traceback (most recent call last): File "build/lib.linux-i686-2.3/zdaemon/tests/testzdrun.py", line 75, in tearDown self.assertEqual(self.expect, output) File "/var/tmp/python2.3-2.3.5-root/usr/lib/python2.3/unittest.py", line 302, in failUnlessEqual raise self.failureException, \ AssertionError: '' != '\n\nFailure in test testUmask (zdaemon.tests.testzdrun.ZDaemonTests)\nTraceback (most recent call last):\n File "build/lib.linux-i686-2.3/zdaemon/tests/testzdrun.py", line 260, in testUmask\n self.assert_(not os.access(path, os.W_OK))\n File "/var/tmp/python2.3-2.3.5-root/usr/lib/python2.3/unittest.py", line 278, in failUnless\n if not expr: raise self.failureException, msg\nAssertionError\n\n' Ran 2173 tests with 1 failures and 1 errors in 160.065 seconds. --// In the error message there is reference to /var/tmp/python2.3-2.3.5-root/usr/lib/python2.3/unittest.py. But I have this: /usr/lib/python2.3/unittest.py Do I have to modify something to remove that error? Thanks for help, again. Regards, Nagaraj -- +----------------------------------+--------------------------------------+ Nagaraj Panyam | Office tel: +91-22-22782610 Dept of High Energy Physics | Office fax: +91-22-22804610 Tata Instt. of Fundamental Research| Home tel : +91-22-22804936 Mumbai - 400 005, INDIA | **Email** : pn@tifr.res.in +----------------------------------+--------------------------------------+
P. Nagaraj wrote at 2006-8-16 17:29 +0530:
Hi Diether,
Wow, the medieval spelling of my name :-)
... Your suggestion worked. But one error came up.
[ZODB3-3.4.0]# python test.py Running tests from build/lib.linux-i686-2.3 Running unit tests:
Error in test testUmask (zdaemon.tests.testzdrun.ZDaemonTests) Traceback (most recent call last): File "build/lib.linux-i686-2.3/zdaemon/tests/testzdrun.py", line 75, in tearDown self.assertEqual(self.expect, output) File "/var/tmp/python2.3-2.3.5-root/usr/lib/python2.3/unittest.py", line 302, in failUnlessEqual raise self.failureException, \ AssertionError: '' != '\n\nFailure in test testUmask (zdaemon.tests.testzdrun.ZDaemonTests)\nTraceback (most recent call last):\n File "build/lib.linux-i686-2.3/zdaemon/tests/testzdrun.py", line 260, in testUmask\n self.assert_(not os.access(path, os.W_OK))\n File "/var/tmp/python2.3-2.3.5-root/usr/lib/python2.3/unittest.py", line 278, in failUnless\n if not expr: raise self.failureException, msg\nAssertionError\n\n'
I think you can ignore this failure in the "testUmask" test of "zdaemon". Almost surely, you will not need this feature. For me, the above looks like a broken test (at least I have problems to decode the 'AssertionError'). -- Dieter
[P. Nagaraj]
[ZODB3-3.4.0]# python test.py Running tests from build/lib.linux-i686-2.3 Running unit tests:
Error in test testUmask (zdaemon.tests.testzdrun.ZDaemonTests) Traceback (most recent call last): File "build/lib.linux-i686-2.3/zdaemon/tests/testzdrun.py", line 75, in tearDown self.assertEqual(self.expect, output) File "/var/tmp/python2.3-2.3.5-root/usr/lib/python2.3/unittest.py", line 302, in failUnlessEqual raise self.failureException, \ AssertionError: '' != '\n\nFailure in test testUmask (zdaemon.tests.testzdrun.ZDaemonTests)\nTraceback (most recent call last):\n File "build/lib.linux-i686-2.3/zdaemon/tests/testzdrun.py", line 260, in testUmask\n self.assert_(not os.access(path, os.W_OK))\n File "/var/tmp/python2.3-2.3.5-root/usr/lib/python2.3/unittest.py", line 278, in failUnless\n if not expr: raise self.failureException, msg\nAssertionError\n\n'
[Dieter Maurer]
I think you can ignore this failure in the "testUmask" test of "zdaemon". Almost surely, you will not need this feature.
For me, the above looks like a broken test (at least I have problems to decode the 'AssertionError').
The test asks zdaemon to run the `touch` command with umask 666. Therefore nobody (except root) should have write access to the file `touch` creates. The failing self.assert_(not os.access(path, os.W_OK)) asserts that write access is in fact not allowed. But note the "except root" in the above: if someone is running as root, there's no chance this can work. More recent versions of zdaemon start the test with this check: if os.getuid() == 0 : self.fail(""" I am root! Do not run the tests as root. Testing proper umask handling cannot be done as root. Furthermore, it is not a good idea and strongly discouraged to run zope, the build system (configure, make) or the tests as root. In general do not run anything as root unless absolutely necessary. """ ) Good advice :-)
participants (4)
-
Dieter Maurer -
P. Nagaraj -
Tim Peters -
Tres Seaver