• Do not register here on develop.twiki.org, login with your twiki.org account.
• Use View topic Item7848 for generic doc work for TWiki-6.1.1. Use View topic Item7851 for doc work on extensions that are not part of a release. More... Close
• Anything you create or change in standard webs (Main, TWiki, Sandbox etc) will be automatically reverted on every SVN update.
Does this site look broken?. Use the LitterTray web for test cases.

Item7440: TWiki6+mod_perl not running as it should due to bin/backuprestoreplugin

Item Form Data

AppliesTo: Component: Priority: CurrentState: WaitingFor: TargetRelease ReleasedIn
Engine BackupRestorePlugin Normal Closed   n/a  

Edit Form Data

Summary:
Reported By:
Codebase:
Applies To:
Component:
Priority:
Current State:
Waiting For:
Target Release:
Released In:
 

Detail

  1. I downloaded a fresh copy of TWiki-6.0.0, created the apache config file with http://twiki.org/cgi-bin/view/TWiki/ApacheConfigGenerator choosing mod_perl under Execution of TWiki's Perl scripts.
  2. Then I created Local.Lib.cfg, set the absolute path inside, and ran /twiki/bin/configure.
  3. After this I un-commented the mod_perl code in my apache conf file, and created /tools/mod_perl_startup.pl (given by ApacheConfigGenerator)

I restarted my apache server, and even though it didn't complain, I got this message when I returned back to TWiki:

TWiki Installation Error

Template "oopsattention" not found.
Check the configuration settings for {TemplateDir} and {TemplatePath}.

With the document title being "Untitled document".

This is the error_log after apache restart:

[Mon Feb 24 16:13:16 2014] [notice] caught SIGTERM, shutting down
[Mon Feb 24 16:13:17 2014] backuprestore: Variable "$cfg" will not stay shared at /www_doc/twiki/bin/backuprestore line 30.
[Mon Feb 24 16:13:17 2014] [notice] SELinux policy enabled; httpd running as context unconfined_u:system_r:httpd_t:s0
[Mon Feb 24 16:13:17 2014] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Mon Feb 24 16:13:17 2014] backuprestore: Variable "$cfg" will not stay shared at /www_doc/twiki/bin/backuprestore line 30.
[Mon Feb 24 16:13:17 2014] [notice] Digest: generating secret for digest authentication ...
[Mon Feb 24 16:13:17 2014] [notice] Digest: done
[Mon Feb 24 16:13:17 2014] [notice] Apache/2.2.15 (Unix) DAV/2 mod_ssl/2.2.15 OpenSSL/1.0.0-fips mod_perl/2.0.4 Perl/v5.10.1 configured -- resuming normal operations

It complains about "$cfg not staying shared": backuprestore: Variable "$cfg" will not stay shared at /www_doc/twiki/bin/backuprestore line 30.

I tried to see if disabling the BackupRestorePlugin in lib/LocalSite.cfg helped, but no. However, removing the bin/backuprestore script alltogether made TWiki work again.

Reading a bit on the mod_perl documentation, it seems to me like the problem could be related to the namespace of the $cfg variable: http://perl.apache.org/docs/general/perl_reference/perl_reference.html#my____Scoped_Variable_in_Nested_Subroutines

Any thought on how this can be fixed? FYI I am very fresh to mod_perl smile

Update:
I guess adding backuprestore to the "do not precompile" list in /tools/mod_perl_startup.pl will be the correct thing to do?

-if ($script !~ m/configure|register|resetpasswd/) { # don't precompile uncommon commands especially configure
+if ($script !~ m/backuprestore|configure|register|resetpasswd/) { # don't precompile uncommon commands especially configure

If so, backuprestore should be added to the list in http://twiki.org/cgi-bin/view/TWiki/ApacheConfigGenerator.

Comments?

-- TWiki:Main.TerjeAndersen - 2014-02-24

Thank you Terje! I updated TWiki:TWiki.ApacheConfigGenerator accordingly - was easier than debugging the "$cfg not staying shared" issue.

-- TWiki:Main.PeterThoeny - 2014-02-24

ItemTemplate
Summary TWiki6+mod_perl not running as it should due to bin/backuprestoreplugin
ReportedBy TWiki:Main.TerjeAndersen
Codebase 6.0.0
SVN Range TWiki-6.0.1-trunk, Thu, 09 Jan 2014, build 26720
AppliesTo Engine
Component BackupRestorePlugin
Priority Normal
CurrentState Closed
WaitingFor

Checkins

TargetRelease n/a
ReleasedIn

Edit | Attach | Watch | Print version | History: r2 < r1 | Backlinks | Raw View |  Raw edit | More topic actions
Topic revision: r2 - 2014-02-24 - PeterThoeny
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2023 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback