Thursday Apr 07, 2011

PHP Plug-In for Oracle iPlanet Web Server 7

Finally, I found time to publish a PHP Plug-In for Oracle iPlanet Web Server 7. This plug-in is delivered on a personal effort to help customers try out PHP within Oracle iPlanet Web Server (formerly known as Sun Java System/ONE Web Server 7). You can download the binaries from here .

Currently, the bits are available for Linux (32/64-bit) and Solaris 10 SPARC (32/64-bit) only. If time permits, I will try to make one available for Windows as well. 

Note: Please note that these binaries are made available on a personal basis and is offered with no warranties (both implied and explicit) and my employer - Oracle or any of its affiliates - does not endorse my effort on this. 

I did not have enough time to test enough on these binaries and at beast can be considered for evaluation purposes and if you are deploying this on production then you are very much on your own !!!

Now that I have clarified your legal rights with downloading these binaries, let me just do a quick walk through on how to get PHP working within Oracle iPlanet Web Server 7 (hereforth simply referred as Web Server ). 

- Download latest version (as of April'2011) of Web Server from Oracle E-Delivery. For more information, about this latest release, check out Oracle iPlanet Web Server 7 Update 11 Release Notes

- Once Web Server 7 is successfully installed at say /opt/oracle/webserver7. 

- You will need to download the corresponding version of PHP Plug-In for Web Server 7 from here  (Please download the bits corresponding to your OS)

- Now, unpack this zip file under <Web Server 7 Installation Directory>/plugins directory 

- Finally, go to the unzipped location and run the following commands :

cd /opt/oracle/webserver7/plugins/php

./setupPHP -instancename=https-<hostname of your machine> (this should correspond to the https- directory that you will find within the Web Server 7 installation directory.) 

Now, you are ready to evaluate PHP within Web Server 7. You could proceed to create new PHP scripts or deploy PHP applications like WordPress or Joomla within Web Server 7. 

If you are satisfied with the PHP configuration, you will need to run the following command so that Web Server 7 administration server is aware of your changes.

sriramn@sriramn:~$ cd /opt/oracle/webserver7

sriramn@sriramn:~$ ./admin-server/bin/startserv

sriramn@sriramn:~$ ./bin/wadm pull-config --user=admin --config=HOSTNAME  HOSTNAME

Friday Mar 11, 2011

How Oracle Exalogic and Exadata Deliver Extreme Java and Database Performance

Webcast: How Oracle Exalogic and Exadata Deliver Extreme Java and Database Performance

Customer Registration URL: http://resources.cio.com/show/200001928/00203800023973CIOIDBDF0QB5O/

Date: March 15, 2011
Time: 1:00pm EST/ 10:00am PST

Oracle Exalogic Elastic Cloud is the industry's first engineered platform for enterprise Java application consolidation, and can be integrated with the Oracle Exadata Database Machine to create one high-speed computing
fabric to run middleware grids and database grids. Learn how this combination can deliver extreme Java and database performance, unmatched reliability and scalability, and cloud-enabled elasticity.

Thursday Jun 17, 2010

Sharing data with Fedora 12 as Guest within Mac

I recently tried out Fedora 12 as guest OS using Sun xVM Virtual Box on my Mac laptop. Af course, I had to assign 512 Mb Memory within my Virtual Box settings to get Fedora Installer program to kick off and complete the installation. This was pretty surprising to me. For long time, I have been amazed that Linux hummed along with just 256 Mb RAM. I guess, times have changed now. Otherwise installation went through amazingly fast .  I guess, this is one other area where OpenSolaris need to catch up with..

Now, I wanted Fedora to share my Documents and other useful folders from my Mac (to avoid keeping a duplicate copy of the same in 2 OS'es). So, I had to hack this to get where I wanted (thanks to googling...)

Within your host machine (whether Mac OS X or Windows), you will need to open Virtual Box settings for your guest image and then click on Shared Folders and   select to a share a location that you would like to share.


.




Now, you will need to boot up Fedora and will need to install source rpms of your kernel . It seems that to successfully install VirtualBox guest additions on Linux, Virtual Box tries to dynamically compile its kernel module for your system by looking for kernel source. So, you will need to install the kernel source .  Here is how you can do so...


a) From the top level Virtual Box menu, click on Devices and then click on Install Guest Additions. This will cause Virtual Box to mount Guest additions ISO image.

b) Now, open a command line terminal to install this new guest additions.

  • Now, you will need to install the latest Virtual Box guest additions package. To do so, you will need to select 'Install Guest Additions..' item from VirtualBox -> Devices menu item.
    • sriramn@fedora:-~$>  su (to become root)
    • /media/VBOXADDITIONS\*/VBoxLinuxAdditions-x86.run

d) Finally, you will need to run the following command within OpenSolaris guest to mount the location that you decided to share from your host (in my case, it is Mac OS's ~/Public ) directory.  I was able to do this as shown below




Also, if you would like this particular location to be mounted every time you boot your OpenSolaris guest, you could also add this below line to your /etc/



Now, if you need to copy any file from your OpenSolaris (guest) VM to your host machine , you could simply do something like

sriramn@opensoaris:~$ pfexec cp ~/Documents/foo  /Public/Drop\\ Box/

Hope you find this useful.


Monday Dec 07, 2009

Pet peeves on debugger..

On the topic of debuggers, here are some of my top most pet peeve when it comes to debuggers..

DBX

\* Hate pressing n every time to go to next line. For some reason, Sun Studio folks never provided a alias to 'Enter' key like the way we do have on GDB.

GDB

\* There is no nice way to display complex structures . For example, if you want to display a nested structure with some nested union / structure in it, good luck deciphering them. DBX's print does an excellent job on this .

\* Surprisingly for such a vibrant open source community, still there is no simple way to save your break points. If you need to save your breakpoints so that when you quit gdb and want to run again, you still need to do complex steps like

(gdb) info breakpoints

and  manually  copy the last column to some file or .gdbinit .

Come on, we are now living in Web 2.0 era where there is API's for every thing and at the least I would expect some thing like

(gdb) save-breakpoints.

Af course, one can write kludge macros to save your breakpoints etc.But, that is not elegant though... For some unknown reason, got into ranting mode. Ok, time to dump your head into your debugger..


GDB commands

Didn't realize that GDB had an option called 'commands' to execute extra commands after hitting a break point. That is pretty cool. For example, I can now do some thing like



(gdb) b <function name> if ($data)

(gdb) commands <breakpoint-number>
Type commands for when breakpoint 7 is hit, one per line.
End with a line saying just "end".

commands

silent

print $data

cont

end

 Af course, if you are using DBX on Solaris/OpenSolaris,you would do some thing like when { shell statements } .. Hope this helps some one..

Thursday Jul 30, 2009

Check out Web Stack Enterprise Manager within Web Stack 1.5

Now that GlassFish Web Stack 1.5 release is finally available for download, check out the highlight of this release - Enterprise Manager


Web Stack Enterprise Manager within Web Stack 1.5 offers the following benefits :
  •  Ability to start / stop / restart open source web tier components within Web Stack like Apache HTTP Server, Tomcat, MySQL 5.0/5.1, Squid, Lighttpd.
  • Ability to lay out monitoring statistics of all these components in graph form. You also move back in time within these graphs allowing you to understand the patten of your load etc.
Web Stack Enterprise Manager, unlike the rest of the Sun GlassFish Web Stack 1.5 release , comes with a 30 day evaluation license. You will need to call Sun and buy support for using it post evaluation period. Hey , gotta make money some where..

However, rest of the GlassFish Web Stack 1.5 release is free to download and use (even for your production needs). We hope, you will consider Sun for your production support requirements.  If you have any issues with using Web Stack, please post your issues to our Forum - where some of the developers lurk and will be happy to guide you.

Wednesday Apr 08, 2009

How to check your APC / Memcache performance statistics ...

PHP runtime within OpenSolaris includes performance booster extensions like APC (PHP extension to cache the compiled PHP script) and Memcache (PHP extension to integrate with Memcached server) to deliver the best performance, out of the box,  for production environment. Now, with upcoming release of OpenSolaris 2009.06 (more specifically with Indiana build 111 or above), we have also have made it easy to check out the performance statistics of these extensions which should further help you in getting the maximum juice from your system.

Installing OpenSolaris 2009.06 (preview build)

If you haven't tried OpenSolaris distribution yet, you can pick up the latest OpenSolaris 2009.06 (preview build) ISO image from here. and steps to install AMP (Apache, PHP and MySQL) stack within OpenSolaris is covered in my earlier blog .

Assuming, you have got a working AMP stack on your system and an application like Joomla, Drupal, or MediaWiki working fine , then here is what you need to do to display the performance statistics of these extensions to your browser :


For displaying PHP APC statistics to the browser:

sriramn@sriramn:~> pfexec cp /etc/apache2/2.2/samples-conf.d/php-apc-stats.conf /etc/apache2/2.2/conf.d/

sriramn@sriramn:~> pfexec cp /etc/apache2/2.2/samples-conf.d/php-memcache-stats.conf /etc/apache2/2.2/conf.d/

sriramn@sriramn:~> svcadm restart http:apache22


Now, you should be able to access these statistics of APC and Memcache extensions by going to the http://localhost/stats/apc/ or http://localhost/stats/memcache/  respectively.

Tuning PHP APC

Once configured, APC statistics page , for example, would show this below page. 

This page should provide you with information as to how many PHP pages are cached and if the cache is getting missed etc. If you see frequent APC cache misses etc then you will need to appropriately increase APC shared memory size. You could do this and other APC configuration tuning by visiting PHP APC configuration page .

If you run into any issues, you could always write to us visiting at this link or by visiting our forum.


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 Feb 09, 2009

Alternate ways of getting pecl extensions to work in OpenSolaris

Earlier, I wrote this blog on how to use PECL extensions within OpenSolaris. Now, there will be some scenario where in a simple pecl install <extension name> might not work because of how the script might have been written or what external dependencies like it depends etc.

For example, if you wanted to get mailparse PECL extension working within opensolaris, you would obviously try the following command first

pfexec /usr/php/bin/pecl install mailparse


and would probably be scratching your head when you run into the below error ...

bash-3.2# /usr/php/bin/pecl install mailparse
downloading mailparse-2.1.4.tar ...                                                                                                                                                                                                         
Starting to download mailparse-2.1.4.tar (Unknown size)
........................................done: 188,416 bytes                                                                                                                                                                                 
9 source files, building
running: phpize                                                                                                                                                                                                                             
Configuring for:
PHP Api Version:         20041225                                                                                                                                                                                                           
Zend Module Api No:      20060613
Zend Extension Api No:   220060519                                                                                                                                                                                                          
building in /var/tmp/pear-build-defaultuser/mailparse-2.1.4
...

checking for re2c... no
configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers. 

What the above error means that while PECL framework trying to build the mailparse extension , it is looking for a tool known as 're2c' (which is internally used by PHP). Unfortunately, this tool has not yet made its ways into OpenSolaris yet. I am pretty sure, this tool will soon make its way into OpenSolaris repository as well..

Okay, in these scenario, here is another quickie to get things going for you...

  • Within your OpenSolaris machine, manually download mailparse extension from PECL repository
  • run /usr/php/bin/phpize , followed by configure and build command.

[sriramn@sriramn]'~'>gunzip -c mailparse-1.1.4.tar.gz | tar xvfp -
[sriramn@sriramn]'~'> cd mailparse-1.1.4
[sriramn@sriramn]'~'>/usr/php/bin/phpize
[sriramn@sriramn]'~'>./configure --with-php-config=/usr/php/bin/php-config && gmake && gmake install


Now, mailparse extension should be available under /var/php/5.2/modules directory. If you would like to include any mailparse specific extension, you will need to define them within /etc/php/5.2/php.ini

Af course, for Apache/PHP module to load these new extensions, you will need to restart Apache/PHP server by doing some thing like.. I am sure, you know this already :-)

svcadm restart http:apache22

Friday Jun 27, 2008

What Election has to do with same sex marriage...

Is it just me wondering as to why 'same sex marriage' issue is highlighted only on an election year and conveniently forgotten afterwards. We saw the same issue play it over during the last soap opera -  America Votes 2004 and we are seeing a season repeat with America Votes 2008. I wish, we as American - take this away from the hands of Politicians and decide for ourselves , as a society, on where we stand.

Statutory Signature : Any opinions , thoughts expressed herewith is my personal opinion and has nothing to do with my employer. 

Tuesday Aug 01, 2006

Interesting presentation on DTrace

Ran into this interesting presentation on DTrace from Brendan Gregg. I guess, for folks like myself, with no patience to read through the entire DTrace docs , this presentation might  be very useful .

Monday Jun 19, 2006

Firefox in Indian buses !!!

One cannot promote Firefox brand any better. Ran into these images and felt like sharing it with rest of the Sun community (I am not sure of its authenicity though) Check this out... 
h



Saturday May 20, 2006

Take away from JavaONE'2006

Some of us in the Web Server team were quite busy with meeting existing and potential customers during Java ONE'2006. Some of my colleagues had excellent demos to showcase the the cool stuffs that one can do with our Web Server 7 Technology Preview release. For example, we had demos in the following areas: - How to use Sun Java System Web Server with Netbeans using Web Server Netbeans Plugin One can use this plugin, to develop and debug either J2EE1.4 based Web Applications or Web Services using JAX 2.0 technologies. - How to easilty setup Roller web application using Web Server 7 - How to easily setup Clusters and Session Replication using Web Server 7 - How to take advantage of the rich Web Server 7 Admin CLI features and easily administer (even remotely) Though, I have not personally contributed much to any of these demos, it was a great experience even learning to use these demos. Hopefully, my peers would post their demos for every one who couldn't personally attend Java ONE'2006. I will provide a cross reference to this URL as soon as I know them. Some of the other interesting things, that I would like to take away from Java ONE'2006 event is - Lot of customers though still using Apache were very much interested in having a competition and they were very much interested in our product. - Lot of customer (almost all of them) didn't really know that Web Server 7 is free (like Apache) and free means good to every one. - Almost every one who saw our demo wanted to know when the final version is going to be released. - Web Server 7 is a Technology Preview release and we all want your feedback to improvde this release. We know that there are still bugs (that is why this a Technology Preview and not final release). It was sure a nice break from work being at Java ONE'2006

Sunday May 14, 2006

Who am I ?

I work for Sun Microsystems and more particularly with Sun's Web Server team. These days they are commercially known as Sun Java System Web Server. This team has been around for quite a while under other popular name's like Sun ONE Web Server, IPlanet Web Server, Netscape Enterprise Server.

I relocated to Bay Area from Seattle, to be part of Web Server 7 release. During the development of Web Server 7, I got a chance to work with lot of smart and dedicated minds. This team is truly amazing and I enjoy working with them. Before Web Server 7, I have also briefly worked in different roles for Sun Java System Web Server 6.1's release. Working with this team has taught me as to why employers look for experience before hiring !.


Before Web Server, I was also involved with Sun's another successful product known as Sun Java System ASP Server. Again, also known as Sun ONE ASP Server and Chili!ASP Server from Chili!Soft. Yup, I know - Sun likes to meddle with its product names every once in a while.


I have been happily married for the last 3 years and I constantly struggle to adjust my work with personal life. I guess, I still have a lot to learn in my life.

Have comments, post them !!!
About

Sharing what little I know

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today