Tags:
prometricexam_1Add my vote for this tag create new tag
view all tags

Question

I'm running the latest version of TWiki on a Windows 2003 server running Apache 2.0.x & ActivePerl 5.8 using mod_perl. This also has the latest version of PHP on it.

When I access certain pages of my TWiki I get an error. The warn.log file shows "STDERR: Bad file descriptor at...Sandbox.pm line 373". The full error is:

12 May 2006 - 16:49 | Can't steal STDERR: Bad file descriptor at C:/apache2/htdocs/twiki/lib/TWiki/Sandbox.pm line 373. at C:/apache2/htdocs/twiki/lib/TWiki/Sandbox.pm line 373 TWiki::Sandbox::sysCommand('TWiki::Sandbox=HASH(0x67af3f4)', '/bin/egrep -i -l -H -- %TOKEN|U% %FILES|F%', 'TOKEN', '.*', 'FILES', 'ARRAY(0x7b5f940)') called at C:/apache2/htdocs/twiki/lib/TWiki/Store/RcsFile.pm line 347 TWiki::Store::RcsFile::searchInWebContent('TWiki::Store::RcsLite=HASH(0x7879240)', '.*', 'ARRAY(0x7b5fb38)', 'HASH(0x787924c)') called at C:/apache2/htdocs/twiki/lib/TWiki/Store.pm line 1957 TWiki::Store::searchInWebContent('TWiki::Store=HASH(0x774bb90)', '.*', 'Sandbox', 'ARRAY(0x7b5fb38)', 'HASH(0x787924c)') called at C:/apache2/htdocs/twiki/lib/TWiki/Search.pm line 293 TWiki::Search::_searchTopicsInWeb('TWiki::Search=HASH(0x7b6012c)', 'Sandbox', '', '', 'regex', 0, '.*') called at C:/apache2/htdocs/twiki/lib/TWiki/Search.pm line 602 TWiki::Search::searchWeb('TWiki::Search=HASH(0x7b6012c)', 'inline', 1, 'search', '.*', 'basetopic', 'WebHome', 'reverse', 'on', ...) called at C:/apache2/htdocs/twiki/lib/TWiki.pm line 2901 TWiki::_SEARCH('TWiki=HASH(0x75b4ce8)', 'TWiki::Attrs=HASH(0x7d53c68)', 'WebHome', 'Sandbox') called at C:/apache2/htdocs/twiki/lib/TWiki.pm line 2244 TWiki::_expandTagOnTopicRendering('TWiki=HASH(0x75b4ce8)', 'SEARCH', ' ".*" regex="on" nosearch="on" nototal="on" order="modified" ...', 'WebHome', 'Sandbox') called at C:/apache2/htdocs/twiki/lib/TWiki.pm line 2164 TWiki::_processTags('TWiki=HASH(0x75b4ce8)', '---+!! %MAKETEXT{"Welcome to the [_1] web" args="Support"}...', 'CODE(0x729cd9c)', 16, 'WebHome', 'Sandbox') called at C:/apache2/htdocs/twiki/lib/TWiki.pm line 2090 TWiki::_expandAllTags('TWiki=HASH(0x75b4ce8)', 'SCALAR(0x7bbc920)', 'WebHome', 'Sandbox') called at C:/apache2/htdocs/twiki/lib/TWiki.pm line 2433 TWiki::handleCommonTags('TWiki=HASH(0x75b4ce8)', '---+!! %MAKETEXT{"Welcome to the [_1] web" args="Support"}...', 'Sandbox', 'WebHome') called at C:/apache2/htdocs/twiki/lib/TWiki/UI/View.pm line 320 TWiki::UI::View::_prepare('---+!! Welcome to the Support web= tags only? Does it occur always when such a page is called?

  • TWiki 4.0.2 is suffering from a memory leak which hits mod_perl installations. If you are serving an "unlimited" number of requests per process, you will sooner or later hit some system limit - though it would more often be a "can't fork". Check in the task manager how "fat" the apache processes are, and reduce the number of requests per thread. As an alternative, wait for version 4.0.3 (going to be released very soon) or apply the patch attached to Bugs:Item2158 (direct link: http://develop.twiki.org/~develop/cgi-bin/viewfile/Bugs/Item2158?rev=1;filename=Item2158.diff).

-- HaraldJoerg - 15 May 2006

Apache seems to be ok -- doesn't seem to be leaking any memory. It happens only on specific pages as well -- for example: https://mysite.contoso.com/twiki/bin/rename/Main/WebPreferences?action=renameweb always gives this error. It mainly seems to be "executable" pages -- eg: pages that might do something on the server as opposed to "information" type pages... hope that makes sense.

-- TWikiGuest - 15 May 2006

After doing some testing tonight the errors consistently seem to center around grep. EG from the above log entry:

TWiki::Sandbox::sysCommand('TWiki::Sandbox=HASH(0x67af3f4)', '/bin/egrep -i -l -H -- %TOKEN|U% %FILES|F%', 'TOKEN', '.*', 'FILES', 'ARRAY(0x7b5f940)') called at C:/apache2/htdocs/twiki/lib/TWiki/Store/RcsFile.pm line 347

-- TWikiGuest - 16 May 2006

Interesting. is your version of grep GNU-compatible, as required by TWiki?

-- CrawfordCurrie - 16 May 2006

Yes (I would believe so). The cygwin files I got were from WindowsModPerlInstallCookbook in the zip file at the bottom of the page.

I believe I followed those instructions to the letter. I've also tried modifying the paths to the grep files (and others) with every possible combination I can think of.

-- TWikiGuest - 16 May 2006

I just noticed you made a comment on the WindowsModPerlInstallCookbook page. I'll try the other two pages you linked to today and see if it helps any.

-- TWikiGuest - 16 May 2006

Thanks! Following the IndigoPerlCookbook fixed it. smile

-- TWikiGuest - 16 May 2006

Excellent. We really need a good cleanout of some of those pages frown

-- CrawfordCurrie - 16 May 2006

Edit | Attach | Watch | Print version | History: r11 < r10 < r9 < r8 < r7 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r11 - 2006-05-16 - PeterThoeny
 
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.