Kurinchi Blogger Scribbles …


Archive for the ‘Apache’ Category

Nov 15
2012

How to setup Apache Tomcat, Java on CentOS?

Last updated: November 13th, 2012

Below set of steps involve setting up Tomcat 6 on CentOS 5 with Java 1.6

Download Apache Tomcat

$ wget http://apache.parentingamerica.com/tomcat/tomcat-6/v6.0.36/bin/apache-tomcat-6.0.36.tar.gz

Go to opt/ folder and extract Tomcat

$ cd /opt

$ tar -xzf apache-tomcat-6.0.36.tar.gz

Create a tomcat user

$ useradd -d /opt/apache-tomcat-6.0.36/ tomcatuser

Change user permission on tomcat folder

$ chown -R tomcatuser:tomcatuser apache-tomcat-6.0.36
(more…)

Sep 11
2012

Apache: How to deny access to a folder or file?

Last updated: September 8th, 2012

Add the following list of lines into .htaccess file or to vhost configuration file appropriate to the folder within the website

<Directory /securedata>
Order Deny,Allow
Deny from all
</Directory>

Same will be the case for denying files within directories

<Files ~ “\.ini$”>
Order allow,deny
Deny from all
</Files>

The above lines of code will be helpful for us to prevent .svn files, .ini files, .htaccess files, include files from display within Apache

Sep 01
2012

How to integrate Zend Framework with WordPress blog or Joomla website?

Last updated: September 1st, 2012

Follow the simple steps given below to integrate Zend framework with other applications like WordPress, Joomla and other such open source or custom web applications.

i) Setup your Zend framework application as usual.

ii) Set the document root of the Zend application to the public folder within Zend install

iii) Now setup a folder for your wordpress or joomla or custom application. Let us assume that we want to create a custom blog application. Create a folder “blog” within “public” folder. Inside blog folder, create two files – .htaccess and index.php. Code for the two files are given below
(more…)

Aug 15
2012

How to configure Zend Framework on an Apache server in a PLESK environment?

Last updated: August 15th, 2012

First, download the Zend framework and unzip the file contents to a location. At the time of the writing ZendFramework-1.11.12 was in use and we have used that version in this example. Key content of the download is the /library folder which has Zend libraries in it.

Then, go to the “conf” folder that was created when the site was created.

Inside the conf folder, create a new file and name it vhost.conf

Add the below contents to vhost.conf and save it. (more…)

Jun 15
2012

How to Send Emails from your local WAMP XAMPP server in windows?

Last updated: June 23rd, 2012

… a question that raises in the mind of programmers developing applications in their local development environments.

This can be achieved by making the following modifications.

Step (i) Install the WAMP / XAMPP server in your windows machine. After this install you will be able to access sites created on the localhost with URL http://localhost

Step (ii) Download and extract the send mail application for Windows from http://glob.com.au/sendmail/. Remember the path where you have extracted sendmail. For e.g. c:\wamp\sendmail

Step (iii) Edit sendmail.ini within c:\wamp\sendmail. This ini file has enough documentation explaining how the configuration changes should happen on the file.
(more…)

Jun 25
2011

Apache: [warn] NameVirtualHost *:80 has no VirtualHosts

Last updated: June 25th, 2011

$ /etc/init.d/apache2 restart

After configuring Apache server settings on the name server, you may encounter a message “[warn] NameVirtualHost 192.168.1.3:80 has no VirtualHosts

The issue may be due to more than one entry of NameVirtualHost lines in the configuration settings. You can find this out by

$ grep NameVirtual * -R
site1:NameVirtualHost *:80
site2:NameVirtualHost *:80

Linux Solution: Remove one of the occurance of the NameVirtualHost and the warning message that you receive will vanish.

Nov 24
2010

How to configure virtual hosts in Apache?

Last updated: May 29th, 2011

Apache server documentation provides us clear set of steps to do name/IP based virtual hosting which is stated in the below URL

http://httpd.apache.org/docs/2.0/vhosts/examples.html

- Running several name-based web sites on a single IP address.
- Name-based hosts on more than one IP address.
- Serving the same content on different IP addresses
- Running different sites on different ports
- IP-based virtual hosting
- Mixed port-based and ip-based virtual hosts
- Mixed name-based and IP-based vhosts
- Using Virtual_host and mod_proxy together
- Migrating a name-based vhost to an IP-based vhost

- Using the ServerPath directive

Apr 01
2010

Apache: client denied by server configuration error

Last updated: April 1st, 2010

Apache Error log shows the message “Client denied by server configuration” and the user sees “Forbidden Access” when they try to visit a web page.

Solution:

Search for the apache configuration file (httpd.conf or vhosts.conf if you have configured a virtual host). Check for the directory permission set for the document root of the web site in question and do the following changes. (more…)

Mar 25
2010

Setting up Zend Framework – for Beginners

Last updated: March 23rd, 2010

Download the latest version of Zend framework from
http://framework.zend.com/download/latest

At the time of writing it was 1.10.2 available at Zend 1.10.2

$ pwd
/tmp

$ wget http://framework.zend.com/releases/ZendFramework-1.10.2/ZendFramework-1.10.2.tar.gz
(more…)

Nov 10
2009

Query string limit in GET data and Size limit in POST Data

Last updated: November 11th, 2009

RFC 2616 – Section 3 states:

“Servers should be cautious about depending on URI lengths above 255 bytes because some older client or proxy implementations may not properly support these lengths.”

Different browser agents support different URI length acceptance. In addition, servers too play a role in accepting/denying URI’s over certain length which may either truncate the URI or may give lengthy URI message indications.

It is always advisable to rely on shorter URI’s and to post data when more field sets are to be transferred across web pages.

POST data too has its limit. In this case, it is the size of the data which is controlled by the server settings.

Some interesting discussions:

Limit on query string GET URL parameters


Valid HTML 4.01 Strict  Valid HTML 4.01 Strict