Koozali.org: home of the SME Server

[SOLVED?] pcre-8.x on SME8b6

Offline mmccarn

  • *
  • 2,627
  • +10/-0
[SOLVED?] pcre-8.x on SME8b6
« on: October 15, 2011, 05:19:39 PM »
I am trying to install and evaluate The Bug Genie on my SME8b6 system.

Requirements include
  • PHP 5.3 (notes)
  • Disable MagicQuotes:
Code: [Select]
db accounts setprop tbg AllowOverride All
echo 'php_flag magic_quotes_gpc Off' > /home/e-smith/files/ibays/tbg/html/.htaccess
signal-event remoteaccess-update
  • PCRE v8 or higher
    The install gives the following message and refuses to proceed:
    Quote
    PCRE librairies version is too old
    The Bug Genie 3 requires PCRE librairies 8.0 or later. You have version 6.6 06-Feb-2006.
    Update your system to the latest release from your usual sources.

The only place I've found a possibly appropriate version of a pcre-8.x rpm is at http://pkgs.org/centos-5-rhel-5/utter-ramblings-i386/pcre-8.02-1.jason.1.i386.rpm.html, pointing to a repository I've never heard of before named 'Utter Ramblings'.

Questions
  • Is there a version of pcre-8.x somewhere that will work with SME8b6?
  • Is a version from 'Utter Ramblings' likely to work, or will it conflict with other SME components?
    • If 'Utter Ramblings' is OK, how do I determine the correct rpm to download?
« Last Edit: October 17, 2011, 02:39:46 PM by mmccarn »

Offline mmccarn

  • *
  • 2,627
  • +10/-0
Re: [SOLVED?] pcre-8.x on SME8b6
« Reply #1 on: October 17, 2011, 02:43:55 PM »
I noticed that 'utterramblings' is mentioned as a repo on in the Centos wiki, so I decided to risk using it to update pcre.

I did this (based on the settings for configuring the dag repo):
Code: [Select]
/sbin/e-smith/db yum_repositories set utterramblings repository \
Name 'UtterRamblings' \
BaseURL 'http://www.jasonlitka.com/media/EL$releasever/$basearch/' \
EnableGroups no \
GPGCheck yes \
GPGKey http://www.jasonlitka.com/media/RPM-GPG-KEY-jlitka \
Visible no \
IncludePkgs pcre \
status enabled
repo setup command modified per note from gregswallow below

Then I did this:
Code: [Select]
signal-event yum-modify
yum --enablerepo=utterramblings update pcre
sv t httpd-e-smith

So far everything looks OK; I'll report back here if I observe any problems with my SME.
« Last Edit: October 17, 2011, 10:14:49 PM by mmccarn »

Offline gregswallow

  • *
  • 651
  • +1/-0
Re: [SOLVED?] pcre-8.x on SME8b6
« Reply #2 on: October 17, 2011, 08:18:54 PM »
Instead of listing what you exclude, it might be better to use:

IncludePkgs pcre
...so you don't inadvertently install something else from that repo

and

status enabled
...so you get notified of updates/fixes.
« Last Edit: October 17, 2011, 10:38:00 PM by gregswallow »

Offline mmccarn

  • *
  • 2,627
  • +10/-0
Re: [SOLVED?] pcre-8.x on SME8b6
« Reply #3 on: October 17, 2011, 10:18:34 PM »
Thanks!

I did this:
* run 'yum update' to confirm that I had no pending updates
* modify the repo setup as you recommended (and update my original post to match)
* run 'yum update' again to verify that no unwanted updates are being offered


Offline soprom

  • *
  • 589
  • +0/-0
    • www.logiciel-libre.org
Re: [SOLVED?] pcre-8.x on SME8b6
« Reply #4 on: November 10, 2011, 09:51:41 PM »
Thanks! It also solves a problem with CakePHP's console...
Sophie from Montréal

Offline pmstewart

  • *
  • 73
  • +0/-0
Re: [SOLVED?] pcre-8.x on SME8b6
« Reply #5 on: February 28, 2014, 12:47:39 AM »
As a follow up post it appears the site has been moved to  - http://yum.jasonlitka.com

Will edit after trying the new code.

Code: [Select]
/sbin/e-smith/db yum_repositories set utterramblings repository \
Name 'UtterRamblings' \
BaseURL 'http://yum.jasonlitka.com/EL$releasever/$basearch/' \
EnableGroups no \
GPGCheck yes \
GPGKey http://yum.jasonlitka.com/RPM-GPG-KEY-jlitka \
Visible no \
IncludePkgs pcre \
status enabled

Works......
« Last Edit: February 28, 2014, 12:27:32 PM by pmstewart »

Offline CharlieBrady

  • *
  • 6,918
  • +3/-0
Re: [SOLVED?] pcre-8.x on SME8b6
« Reply #6 on: March 03, 2014, 01:39:20 AM »
Quote
db accounts setprop tbg AllowOverride All
echo 'php_flag magic_quotes_gpc Off' > /home/e-smith/files/ibays/tbg/html/.htaccess
signal-event remoteaccess-update

A better solution is to disable magic quotes within a location container in httpd.conf using a custom template. .htaccess files are inherently less secure, since the potential exists for them to be modified by a compromised php application, or some other way, e.g. via samba access.

Offline mmccarn

  • *
  • 2,627
  • +10/-0
Re: [SOLVED?] pcre-8.x on SME8b6
« Reply #7 on: March 03, 2014, 02:47:37 PM »
A better solution is to disable magic quotes within a location container in httpd.conf using a custom template. .htaccess files are inherently less secure, since the potential exists for them to be modified by a compromised php application, or some other way, e.g. via samba access.

I'm pretty sure we don't need to do anything to disable magic_quotes_gpc any more, as it is now forcefully set to 'off' in /etc/php.ini:
Bug 7522 (SME 8.1)
Bug 7605 (SME 9.0b1)