Tuesday Feb 09, 2010

Check out latest development build of Web Stack

If you are using Cool Stack or Web Stack for your AMP (Apache, PHP and MySQL) stack needs on either Solaris 10 or Red Hat Enterprise Linux, then you might want to check out the latest development build update of Web Stack. This build delivers PHP 5.2.12 , Apache 2.2.14 etc. 

For more information on how to update to this build, please refer to my earlier blog on this topic. If you run into any issues, please use our forum for any trouble shooting tips.

Wednesday Aug 26, 2009

Using DTrace to analyze your web site

During recent OSCON'09 conference, Jack Adams met with me to discuss on the ways to troubleshoot the problems with his web site. Check out this video.

A Jack Adams conversation with Sriram Natarajan, at OSCON 2009.


Tuesday Mar 03, 2009

OpenSolaris 2008.11 based AMP stack is now available for Amazon EC2

After a long time since my initial post on releasing the OpenSolaris based AMP stack for Amazon EC, Today, we announced the availability of Amazon Machine Image (AMI) for OpenSolaris 2008.11 based AMP (Apache 2.2, MySQL 5.0 and PHP 5.2) on Amazon EC2 envionment. So, if you want to try out Amazon based web services running on enterprise grade OpenSolaris, please check out this announcement for more information.

Monday Jan 12, 2009

What's new with AMP stack in OpenSolaris 2008.11

If you are new to OpenSolaris, please check out this blog on how to get the AMP stack for this platform. 

Since the initial release of OpenSolaris 2008.05 - in the last 4-5 months -  our Web Stack project team has been busy revving up AMP (Apache, MySQL and PHP) stack specific bugs for OpenSolaris 2008.11 as well as porting this stack on Solaris 10 and RedHat Enterprise Linux 5 platforms as part of Sun Web Stack 1.4 release. For more information on this Sun Web Stack 1.4 release, check out this blog from my colleague - Jyri Virkki.

Now, in this blog, I thought I will write some of the important technical issues that has been addressed within AMP stack  for OpenSolaris 2008.11 release.

  1. General version update of AMP components like Apache = 2.2.9, PHP = 5.2.6 and MySQL = 5.0.67.
  2. Apache and PHP configuration files have been updated to provide better performance out of the box.
  3. Apache 2.2.9 now includes additional modules like Perl, FastCGI, DTrace etc
  4. Apache now provides various sample configurations like SSL configuration within /etc/apache2/2.2/samples-conf.d directory. 
  5. MySQL 5.0 server (64-bit) is also now available . However, MySQL server defaults to 32-bit by default. If you would like to run MySQL server as 64-bit, please refer to Administering MySQL server documentation within our wiki.
  6. Experimental MySQL 5.1 server is now available within webstack repository. However, to use MySQL 5.1 within OpenSolaris 2008.11, you will need to explicitly point to Web Stack repository to download and install this server. I guess, more on this in a separate blog !
  7. PHP file layout has been modified to be more in synchronization with the rest of the components. New PHP 5.2.6 file layout within OpenSolaris 2008.11 is /usr/php/5.2 - for all standard binaries, /etc/php/5.2 - for all configuration and /var/php/5.2 - for all data, pecl / pear modules and session specific contents. Also, at the time of startup , PHP engine will look and load all the INI files found under /etc/php/5.2/conf.d directory.
  8. PHP extensions like APC, DTrace is now enabled by default. Also, PECL extensions like XDebug, Memcache, Suhosin, idn and tcpwrap is bundled within OpenSolaris 2008.11. However, they are disabled by default. These extensions are bundled as individual ini files within /etc/php/5.2/conf.d directory.
  9. Individual PHP extensions can be either enabled or disabled by editing their corresponding ini files within /etc/php/5.2/conf.d directory and then restarting Apache SMF service. For more information on restarting Apache SMF service, please visit our Administering Apache Server documentation within our Web Stack Wiki.
  10. PHP extension now includes PEAR / PECL support as well. So, now it should be easy for developers to now download and install their favorite extensions. So, if you wonder as to how to use PEAR or PECL within OpenSolaris, you could do some thing like below
    1. /usr/php/bin/pear install XML_Parser
    2. /usr/php/bin/pecl install inclued

Now, if you install these PECL extensions as shown above, please remember to enable them by editing the php.ini found within /etc/php/5.2/php.ini  location.

You can load any of these PECL php extensions by editing php.ini and adding the following line at the end of the file

extension = [extension name].so

Note: Please note that unlike Linux or other platforms, Solaris engineering folks would like to avoid writing any user data (like data not provided by OS) within /usr location. So, we don't write any dynamic data into /usr. So, what this means is - PEAR or PECL will now install modules under /var/php/5.2/modules directory. However, PHP engine has been patched to look for modules both under /usr/php/5.2/modules as well as /var/php/5.2/modules directory

Hopefully, this acts as a good starting point on what to expect with AMP stack in OpenSolaris 2008.11. For more comprehensive information, please visit our Getting Started Guide or please visit your feedback within our OpenSolaris Web Stack forum .

Setting up AMP Stack within OpenSolaris

With the first release of OpenSolaris - OpenSolaris 2008.05 -  I wrote this and this and this blog on how to use AMP stack for this platform. Well, these blogs very much holds true for the latest release of OpenSolaris - OpenSolaris 2008.11 .

However, OpenSolaris 2008.11 includes a nice GUI application known as Package Manager  is available which further simplifies the process of downloading and configuring software applications that are available within its software repository.  

Let us use this application in this blog to see how easy it is to get an AMP (Apache, PHP and MySQL) stack going on your OpenSolaris 2008.11.

Assuming you have successfully installed opensolaris , let us start Package Manager as shown here

Now, you will need to choose whether you need either 

  • amp -  only the Apache 2.2.8 2.2.9, PHP 5.2.6 and MySQL 5.0.65 5.0.67 runtime
  • amp-dev  -  complete development environment and its tools like cvs, subversion, netbeans along with amp runtime

 and any other software packages that you are interested and click on Install / Update. 

Before Package Manager actually installs the packages on your system, you will get another chance to review your selection like below.

Now, click on Next should start the installation process. That should all be required to complete the installation of AMP runtime stack for OpenSolaris.  

Finally, if you are a GUI person and would prefer a GUI way to start/stop Apache and MySQL services as well as to edit your Apache configuration files then you might want to initialize the Web Stack environment as shown below

 and will need to enter your 'root' password for the initialization to complete. 

Now, if you are a command line person - like myself, you can manage your Apache and MySQL SMF service as below

  • For starting Apache and MySQL service, open a command line window and run the following command

    pfexec /usr/sbin/svcadm enable http:apache22

    pfexec /usr/sbin/svcadm enable mysql:version_50

  • Similarly, for stopping these services, run the following command:

    pfexec /usr/sbin/svcadm disable http:apache22

    pfexec /usr/sbin/svcadm disable mysql:version_50

If in case, you wonder what is SMF - you might wanna check out Service Management Facility project page for more information on how this is useful to you.  

Finally, if you run into any issues, you can check out our  Getting Started Guide or our Web Stack wiki or  feel free to post your issues at our  Web Stack forum page. 


Sharing what little I know


« July 2016