Main Page
 The gatekeeper of reality is
 quantified imagination.

Stay notified when site changes by adding your email address:

Your Email:

Bookmark and Share
Email Notification
Project Zend
Purpose
The purpose of this tutorial is to install Zend Server in the CentOS LAMP server VM clone and get Zend Studio (outside the VM) to communicate with Zend Server.

NOTE: This is Part 3 of a larger tutorial of creating a development environment from scratch to installing Zend Server (the defacto web development platform for PHP and mobile applications). Please go to the Main Page -> Programming -> Linux for the whole series.


(Enlarge)
  1. There are a few different ways that you may install Zend Server on CentOS (in our tutorial, into a virtualized LAMP server running in VMWare Workstation).
  2. The easiest method is by installing it via yum. The next easiest is by using the repository tar file that you get by downloading from the Zend website.
  3. What's the difference? While the yum method is extremely convenient, you risk downloading Zend Server 5.6 instead of whatever the latest version may be (in our case, 6x). That means, once it is installed, you may have to turn around and perform an upgrade with the repository file.
  4. With the repository method, it is more hands-on.
  5. I'd opt for the repository method, but this tutorial will cover both.
  6. YUM METHOD OF INSTALLATION:
  7. To begin, go to the prompt and enter "touch /etc/yum.repos.d/zend.repo". Once the file is created edit the file via "gedit /etc/yum.repos.d/zend.repo".

(Enlarge)
  1. YUM METHOD OF INSTALLATION:
  2. Enter the text as indicated and save the file.

(Enlarge)
  1. YUM METHOD OF INSTALLATION:
  2. Find the version of PHP that is installed via "php --version". You'll need this so you can specify which PHP Zend Server will get installed.

(Enlarge)
  1. YUM METHOD OF INSTALLATION:
  2. To install Zend Server that is compatible with the installed version of PHP enter "yum install zend-server-php-5.3".

(Enlarge)
  1. YUM METHOD OF INSTALLATION:
  2. After installation, open Firefox and go to "https://localhost:10082". After going through some webpages to accept license terms, enter administrative credentials and the license, if you see this screen you have two possible problems:
  3. If you are running SELinux, you need to make appropriate changes to allow Zend Server to run (more on that in a moment).
  4. If you've made appropriate changes to SELinux (or don't have it), and you know your Zend Server license is valid, most likely the yum install got an earlier version of Zend Server that your license was not issued for.

(Enlarge)
  1. AFTER ZEND SERVER INSTALLATION - SELinux:
  2. One thing that you can do to determine if SELinux is a problem is to enter "service zend-server restart".
  3. If you see a permissions issue centered around httpd, you've got a problem.

(Enlarge)
  1. AFTER ZEND SERVER INSTALLATION - SELinux:
  2. In order to determine if SELinux is, indeed, causing an issue you can temporarily disable it by editing "/etc/selinux/config" and setting "SELINUX=disabled".

(Enlarge)
  1. AFTER ZEND SERVER INSTALLATION - SELinux:
  2. After a reboot you should be able to enter "setsebool -P httpd_disable_trans=1" to verify that SELinux is disabled.

(Enlarge)
  1. AFTER ZEND SERVER INSTALLATION - Zend Support Tool:
  2. On a side note, once you've installed the Zend support tool "support_tool.sh", you can compile information they need to assist with troubleshooting via entering "/usr/local/zend/bin/support_tool.sh" at the prompt.

(Enlarge)
  1. REPOSITORY METHOD OF INSTALLATION:
  2. Luckily, since VMWare tools is installed on the LAMP server (see earlier tutorial), we can easily copy the Zend Server Repository file from the local hard drive by selecting the file and then Copy.

(Enlarge)
  1. REPOSITORY METHOD OF INSTALLATION:
  2. Then, inside of the VM (in this example the folder /tmp), right-click and select "Paste".

(Enlarge)
  1. REPOSITORY METHOD OF INSTALLATION:
  2. After the file finishes copying, right-click on it and select "Extract Here".

(Enlarge)
  1. REPOSITORY METHOD OF INSTALLATION:
  2. The extraction will create a new folder for the Zend Server installation data.

(Enlarge)
  1. REPOSITORY METHOD OF INSTALLATION:
  2. From the prompt navigate to where the Zend Server installation folder was created, in this case "cd /tmp/ZendServer-RepositoryInstaller-linux". Then enter "./install_zs.sh 5.3" where 5.3 is the version of PHP that is already installed.

(Enlarge)
  1. REPOSITORY METHOD OF INSTALLATION:
  2. The installation process will begin and you will be asked if downloading is okay.

(Enlarge)
  1. REPOSITORY METHOD OF INSTALLATION:
  2. After installation completes might as well perform a "yum clean all".

(Enlarge)
  1. REPOSITORY METHOD OF INSTALLATION:
  2. Open Firefox and enter "https://localhost:10082". You'll have to complete some one-time steps before you can actually start using Zend Server.

(Enlarge)
  1. AFTER INSTALLATION:
  2. Have your order and registration number handy as you'll need it here.

(Enlarge)
  1. AFTER INSTALLATION:
  2. Power off the VM. You may want to check to see if folder sharing is enabled for the VM and select "Enabled until next power off or suspent" or "Always enabled" if needed.

(Enlarge)
  1. AFTER INSTALLATION:
  2. Then power on the VM, login, open "https://localhost:10082" and login to Zend Server.
  3. At this point your LAMP server should be up and running with Zend Server!

(Enlarge)
  1. GETTING ZEND STUDIO AND ZEND SERVER TO COMMUNICATE:
  2. In the developer enviornment, you most likely have Zend Studio installed on your OS and not inside of the LAMP Server VM. There are a few things that you need to do in order to sync-up Zend Studio with Zend Server in the VM.
  3. First ensure that the VM is running (and you are OPTIONALLY logged into Zend Server).
  4. Next, open Zend Studio 10. Select "VMWare Workstation Support" under "Enhancements".

(Enlarge)
  1. GETTING ZEND STUDIO AND ZEND SERVER TO COMMUNICATE:
  2. From the pane that will appear, select "VMware Virtual Machine".

(Enlarge)
  1. GETTING ZEND STUDIO AND ZEND SERVER TO COMMUNICATE:
  2. On the next pane, browse to the VM, specify a connection name (should be unique enough you can easily tell it apart from other connections) and a description.

(Enlarge)
  1. GETTING ZEND STUDIO AND ZEND SERVER TO COMMUNICATE:
  2. Now that the connection has been created, you should be able to right-click on the connection and select "Connect".

(Enlarge)
  1. GETTING ZEND STUDIO AND ZEND SERVER TO COMMUNICATE:
  2. Next, you will need to enter the administrative credentials for Zend Server.

(Enlarge)
  1. GETTING ZEND STUDIO AND ZEND SERVER TO COMMUNICATE:
  2. You'll be prompted to setup password recovery (continue if you want).

(Enlarge)
  1. GETTING ZEND STUDIO AND ZEND SERVER TO COMMUNICATE:
  2. At anytime you can also right-click on the connection and select "Monitor" which provides additional connection information.

(Enlarge)
  1. GETTING ZEND STUDIO AND ZEND SERVER TO COMMUNICATE:
  2. In this case, it is showing we are 100% connected.
  3. At this point you should now be (1) up and running with Zend Server, and, (2) have Zend Studio 10 sync'ed up to Zend Server!


Miscellaneous: Careful with httpd after Zend Server Installation

(Enlarge)
  1. If you've observed Zend Server when it starts up, it will attempt to start httpd even if httpd is already running (say you had httpd set to start at boot).
  2. If httpd is set to be on at boot, you can go to the prompt and enter "chkconfig httpd off".


Miscellaneous: Error with httpd?

(Enlarge)
  1. Before or after Zend Server installation, it is possible that Apache will not start. One of the most common problems is not having a valid host definition. If httpd does not start, you may want to examine your "/etc/hosts" and "/etc/sysconfig/network" files to make sure a "valid syntax" domain is defined.


Miscellaneous: Error with Zend Server 6x at Boot after Installation?

(Enlarge)
  1. When you know that httpd starts normally (such as by "service httpd start" and "service httpd status"), an issue you may come across is seeing "Starting httpd: [crit] (EAI 9)Address family for hostname not supported: alloc_listener: failed to set up sockaddr for 127.0.0.1".

(Enlarge)
  1. That error that gets generated (from the file "/etc/httpd/conf.d/zendserver_gui.conf") centers around the line "Listen 127.0.0.1:10083".
  2. Pending what the folks at Zend may say, one way the error can be avoided if the line is commented out and a new line added "Listen *:10083".

(Enlarge)
  1. Then, from the prompt entering "service zend-server restart" should show everything start up without any errors getting generated.


Miscellaneous: Turning off IPv6 in Firefox

(Enlarge)
  1. Depending on how you've got your LAMP server and environment setup, IPv6 running in the web browser may make webpages slow to load.
  2. One way to narrow down possible "lag" issues is to disable IPv6 in Firefox by starting out and entering "about:config".

(Enlarge)
  1. Locate "network.dns.disableIPv6".

(Enlarge)
  1. Double-click the entry so the value changes to "true".


About Joe