JoomlaWorks

Member Dashboard
  • Home
  • Extensions
    • Commercial
      • Frontpage Slideshow
      • K2 Plugin for sh404SEF
      • Simple Image Gallery Pro
      • SocialConnect
    • Free
      • K2
      • AllVideos
      • DISQUS Comments for Joomla!
      • Simple Image Gallery
      • Simple RSS Feed Reader
    • Free On Github
      • Akismet for Kunena
      • Fill It Up (for Joomla)
      • Fill It Up (for WordPress)
      • IAKI (Import As K2 Image)
      • K2 Example Plugin
      • K2 Links for JCE
      • TinyLetter Subscribe
      • User Extended Fields for K2
  • Templates
    • Commercial Templates
      • Janaro
      • Tamashi
      • Anagram
      • Matchbox
      • Kiji
      • Ibento
      • RadioWave
      • Archetype
      • The Conversationalist
      • Toreda
      • Nokkori
      • NewsWorth
      • BusinessOne
      • nuMuzik
    • Free Templates
      • Takai
      • nuModusVersus
  • Demos
    • Joomla Extension Demos
    • Joomla Template Demos
    • WordPress Plugin Demos
  • Labs
    • Web Apps
      • JoomlaReader
      • JSON 2 JSONP
      • Web Platform Tools
    • JavaScript Projects
      • Coming Soon...
  • Support
    • Documentation for Joomla Extensions
      • AllVideos
      • Frontpage Slideshow
      • Frontpage Slideshow [Standalone]
      • Simple Image Gallery
      • Simple Image Gallery Pro
      • SocialConnect
    • Documentation for Joomla Templates
      • General Resources
        • Installation
        • Content
        • Customization
      • Commercial Templates
      • Free Templates
    • Community Forum
      • Create a free account
      • Community Forum (Categories)
      • Community Forum (Recent Topics)
    • Help Desk
    • Contact
  • About
    • Blog
    • Company
    • License & Terms of Service
    • Privacy Policy
  • My Account
Displaying items by tag: whm
Subscribe to this RSS feed
Install APC/APCu on a WHM/cPanel server the easy way and boost your site's performance!

Install APC/APCu on a WHM/cPanel server the easy way and boost your site's performance!

inBlog
If you run a popular Joomla (or WordPress, Drupalor or any other PHP based CMS) website on either a dedicated server or VPS running WHM/cPanel, chance is you may have stumbled upon performance issues at some point.

Although improving Joomla's performance is a task that requires in-depth analysis, I thought I'd just write a couple of words on improving one aspect of your site's performance quickly and efficiently: PHP execution by using the APC or APCu opcode caching modules. Keep in mind that APC is compatible with PHP up to version 5.3.x. APCu replaces APC for PHP versions 5.4.x or newer and it's currently under active development.

Since PHP 5.3.x is considered obsolete, I'll cover the steps to have APCu installed on your server. If you run PHP 5.3.x either consider updating to 5.5.x/5.6.x or follow the steps below making sure you replace any "apcu" reference with just "apc" (minus the "u").

MORE INFO

Install Ingres DB Community Edition and Ingres support for PHP on CentOS

inBlog

This is a guide to save you from banging your head against a wall, in case you ever want to get PHP talk with Ingres on a CentOS machine.

After hours of searching around and not finding not one damn proper guide, I decided to just write one down (after much trial and error).

What we wanna do is basically query an Ingres database through a CentOS based LAMP server (which runs WHM/CPanel too). So we need to install (unfortunately) the Ingres Community Database (as the PECL Ingres package seems to require it to be installed) and of course we need to install PHP's package for Ingres (PECL Ingres) so we can query an Ingres database from PHP. Still with me?

Let's get started...

1. Install Ingres and PHP/Ingres support on CentOS:

Install Ingres DB Community Edition first as it's obviously required by PECL's Ingres package. Here we install the related RPM for a 32-bit CentOS machine. The process is the same for 64-bit, the file is just different. Sign up on ingres.com for a free account and go to http://www.ingres.com/downloads/ingres-database.php to download the right release. Ingres.com is passing the download link from some script, so if you wanna pinpoint the URL and not download the file to your PC, then upload onto your server, you can simply right-click on the download manager in Firefox and copy the "link location". This will give you the URL where the actual file of the Ingres db relies on the ingres.com site, so you can use "wget". In this case, the path I got was something like "http://98.129.177.132/~GqxCOi/ingres-10.0.0-119-NPTL-gpl-pc-linux-i386.tgz". Don't try this link in particular as it may not work when you read this...

You obviously need root access to the server:

# cd /usr/src
# wget http://98.129.177.132/~GqxCOi/ingres-10.0.0-119-NPTL-gpl-pc-linux-i386.tgz
# tar -zxvf ingres-10.0.0-119-NPTL-gpl-pc-linux-i386.tgz
# cd ingres-10.0.0-119-NPTL-gpl-pc-linux-i386
# sh ingres_express_install.sh

This process will install Ingres in /opt/Ingres/IngresII/

2. Install the PECL Ingres package for PHP.

Using "pecl install ingres" will simply NOT work. So we do it the old-fashioned way. Grab the latest package here: http://pecl.php.net/package/ingres and then do the following:

# cd /usr/src
# wget http://pecl.php.net/get/ingres-2.2.2.tgz
# tar -zxvf ingres-2.2.2.tgz
# cd ingres-2.2.2
# phpize
# ./configure --with-ingres=/opt/Ingres/IngresII
# make
# make install

This process will install the PECL Ingres package for PHP.

We need a couple more things, before we get started.

We need to declare some system variables in Apache. If you use WHM/CPanel, go to Main >> Service Configuration >> Apache Configuration >> Include Editor and choose to edit the "Pre Main Include" file. Add the following 2 lines:

SetEnv II_SYSTEM /opt/Ingres/IngresII
SetEnv LD_LIBRARY_PATH /opt/Ingres/IngresII/ingres/lib

If you don't use Cpanel, just paste these lines into your httpd.conf file.

Now locate the WHM/CPanel php.ini file at /usr/local/lib/php.ini (if you don't use WHM/Cpanel it's probably located in /usr/lib/php.ini). Find the line "; Directory in which the loadable extensions (modules) reside." and right after that add:

extension = "ingres.so"

This will make sure the related PHP extension for Ingres support is loaded by PHP.

That's it.

Go to your "public_html" folder (or any other folder) and test if you got Ingres support for PHP installed properly. We'll use a dummy connection file, so get the code below:

<?php
$link = ingres_connect("database", "user", "password")  or die("Could not connect: " . ingres_error($link));
echo "Connected successfully";
?>

…and save this as "ingres.php". Now visit this file from your browser and if you get a "Warning: ingres_connect()..." then it means Ingress support for PHP is installed properly!

Enjoy!

MORE INFO
BY MAIL BY RSS

Archives

  • February 2019 (3)
  • January 2019 (1)
  • December 2018 (3)
  • October 2018 (5)
  • September 2018 (3)
  • August 2018 (1)
  • July 2018 (1)
  • January 2018 (1)
  • December 2017 (1)
  • October 2017 (1)
  • August 2017 (1)
  • April 2016 (1)

Tag Cloud

1.6 allvideos announcement apache community cpanel development frontpage slideshow joomla k2 opinion plugin release sh404sef simple image gallery pro tips ubuntu update video whm

Latest Entries

  • 15 Feb 2019 New milestone for K2 translations & an important message to the translation teams!
    Written by  Fotis
  • 08 Feb 2019 Simple Image Gallery Pro v3.6.4 released
    Written by  Fotis
  • 02 Feb 2019 Simple RSS Feed Reader v3.7.0 released
    Written by  Fotis
  • 09 Jan 2019 Simple Image Gallery Pro v3.6.3 released
    Written by  Fotis
  • 21 Dec 2018 Simple Image Gallery Pro v3.6.2 released
    Written by  Fotis

Join Our Newsletter

Enter your e-mail address to subscribe to our new or updated product notifications. We send combined newsletters, so we won't spam you every week :)

Get Social

  • Twitter
  • GitHub
  • Facebook
  • GitHub (K2)
  • YouTube
  • Speaker Deck

Grab Our Feeds

  • Extension Updates
  • Blog
  • Videos
  • Presentations
Copyright © 2006 - 2019 JoomlaWorks Ltd.
JoomlaWorks Ltd. and this site is not affiliated with or endorsed by The Joomla! Project™. Any products and services provided through this site are not supported or warrantied by The Joomla! Project or Open Source Matters, Inc. Use of the Joomla!® name, symbol, logo and related trademarks is permitted under a limited license granted by Open Source Matters, Inc.
designed by Nuevvo