<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Spirit of Change &#187; Web Server</title>
	<atom:link href="http://vavai.net/category/server/web-server/feed/" rel="self" type="application/rss+xml" />
	<link>http://vavai.net</link>
	<description>Masim "Vavai" Sugianto Personal Blog</description>
	<lastBuildDate>Tue, 13 Apr 2010 02:26:59 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Apache Web Server &amp; Virtual Host on openSUSE : Part 2</title>
		<link>http://vavai.net/2009/03/02/apache-web-server-virtual-host-on-opensuse-part-2/</link>
		<comments>http://vavai.net/2009/03/02/apache-web-server-virtual-host-on-opensuse-part-2/#comments</comments>
		<pubDate>Mon, 02 Mar 2009 08:55:29 +0000</pubDate>
		<dc:creator>Masim "Vavai" Sugianto</dc:creator>
				<category><![CDATA[OpenSUSE]]></category>
		<category><![CDATA[Web Server]]></category>
		<category><![CDATA[Apache]]></category>

		<guid isPermaLink="false">http://vavai.net/?p=555</guid>
		<description><![CDATA[This is the second part for Apache VirtualHost on openSUSE tutorial. Please refer to part 1 for further information regarding Apache installation on openSUSE.  I prepared the tutorial for presentation on Indonesian openSUSE Community monthly meeting #14 Indonesian openSUSE Community last Saturday. ***** I used 2 sub domain as an example on this tutorial. Don&#8217;t [...]]]></description>
			<content:encoded><![CDATA[<p>This is the second part for Apache VirtualHost on openSUSE tutorial. Please refer to <a href="http://vavai.net/2009/02/23/apache-web-server-virtual-host-on-opensuse-part-1/">part 1</a> for further information regarding Apache installation on openSUSE.  I prepared the tutorial for presentation on Indonesian openSUSE Community monthly meeting #14 Indonesian openSUSE Community last Saturday.</p>
<p style="text-align: center;">*****</p>
<p>I used 2 sub domain as an example on this tutorial. Don&#8217;t forget to replace <strong>dl.opensuse.or.id</strong> and <strong>download.opensuse.or.id</strong> as shown in this tutorial with your own.  Let&#8217;s go with fun <img src='http://vavai.net/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />  :</p>
<ol>
<li>Open folder /etc/apache2/vhosts.d</li>
<li>Copy file vhost.template into a new file name with .conf extension. It will be virtual host configuration. I want to create 2 sub domain and 2 virtual host so I must create <strong>dl.opensuse.or.id.conf</strong> and <strong>download.opensuse.or.id.conf</strong>. Configuration file name may vary but I highly recommended to use the proper name to prevent any misunderstanding</li>
<li>Open file  <strong>dl.opensuse.or.id.conf</strong> and modify some configuration, e.g : name of virtual host, root folder, admin name, etc. Below is an example :
<pre class="brush: cpp">
########################################################################
#
# VirtualHost template
# Note: to use the template, rename it to /etc/apache2/vhost.d/yourvhost.conf.
# Files must have the .conf suffix to be loaded.
#
# See /usr/share/doc/packages/apache2/README.QUICKSTART for further hints
# about virtual hosts.
#
# NameVirtualHost statements can be added to /etc/apache2/listen.conf.
#
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for requests without a known
# server name.
#
NameVirtualHost *:80
&lt;VirtualHost *:80&gt;
ServerAdmin opensuse@opensuse.or.id
ServerName dl.opensuse.or.id

# DocumentRoot: The directory out of which you will serve your
# documents. By default, all requests are taken from this directory, but
# symbolic links and aliases may be used to point to other locations.
DocumentRoot /srv/www/vhosts/dl.opensuse.or.id
# if not specified, the global error log is used
ErrorLog /var/log/apache2/dl.opensuse.or.id-error_log
CustomLog /var/log/apache2/dl.opensuse.or.id-access_log combined

# don&#039;t loose time with IP address lookups
HostnameLookups Off

# needed for named virtual hosts
UseCanonicalName Off

# configures the footer on server-generated documents
ServerSignature On

# Optionally, include *.conf files from /etc/apache2/conf.d/
#
# For example, to allow execution of PHP scripts:
#
# Include /etc/apache2/conf.d/mod_php4.conf
#
# or, to include all configuration snippets added by packages:
# Include /etc/apache2/conf.d/*.conf

# ScriptAlias: This controls which directories contain server scripts.
# ScriptAliases are essentially the same as Aliases, except that
# documents in the realname directory are treated as applications and
# run by the server when requested rather than as documents sent to the client.
# The same rules about trailing &quot;/&quot; apply to ScriptAlias directives as to
# Alias.
#
#    ScriptAlias /cgi-bin/ &quot;/srv/www/vhosts/dl.opensuse.or.id/cgi-bin/&quot;

# &quot;/srv/www/cgi-bin&quot; should be changed to whatever your ScriptAliased
# CGI directory exists, if you have one, and where ScriptAlias points to.
#
#    &lt;Directory &quot;/srv/www/vhosts/dummy-host.example.com/cgi-bin&quot;&gt;
#       AllowOverride None
#       Options +ExecCGI -Includes
#       Order allow,deny
#       Allow from all
#    &lt;/Directory&gt;

# UserDir: The name of the directory that is appended onto a user&#039;s home
# directory if a ~user request is received.
#
# To disable it, simply remove userdir from the list of modules in APACHE_MODULES
# in /etc/sysconfig/apache2.
#
&lt;IfModule mod_userdir.c&gt;
# Note that the name of the user directory (&quot;public_html&quot;) cannot simply be
# changed here, since it is a compile time setting. The apache package
# would have to be rebuilt. You could work around by deleting
# /usr/sbin/suexec, but then all scripts from the directories would be
# executed with the UID of the webserver.
UserDir public_html
# The actual configuration of the directory is in
# /etc/apache2/mod_userdir.conf.
Include /etc/apache2/mod_userdir.conf
# You can, however, change the ~ if you find it awkward, by mapping e.g.
# http://www.example.com/users/karl-heinz/ --&gt; /home/karl-heinz/public_html/
#AliasMatch ^/users/([a-zA-Z0-9-_.]*)/?(.*) /home/$1/public_html/$2
&lt;/IfModule&gt;

#
# This should be changed to whatever you set DocumentRoot to.
#
&lt;Directory &quot;/srv/www/vhosts/dl.opensuse.or.id&quot;&gt;

#
# Possible values for the Options directive are &quot;None&quot;, &quot;All&quot;,
# or any combination of:
#   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
#
# Note that &quot;MultiViews&quot; must be named *explicitly* --- &quot;Options All&quot;
# doesn&#039;t give it to you.
#
# The Options directive is both complicated and important.  Please see
# http://httpd.apache.org/docs-2.2/mod/core.html#options
# for more information.
#
Options All
#Indexes FollowSymLinks

#
# AllowOverride controls what directives may be placed in .htaccess files.
# It can be &quot;All&quot;, &quot;None&quot;, or any combination of the keywords:
#   Options FileInfo AuthConfig Limit
#
AllowOverride None
#
# Controls who can get stuff from this server.
#
Order allow,deny
Allow from all
&lt;/Directory&gt;
&lt;/VirtualHost&gt;
########################################################################
</pre>
</li>
<li>Change the configuration according your purposes</li>
<li>After completing the first virtual host configuration, repeat the same way to second virtual host configuration</li>
<li>Note : for better checking (it should be o real condition), don&#8217;t forget to separate home folder for both virtualhost by changing DocumentRoot configuration. I create a new text file called   <strong>this-is-dl-location.txt</strong> on   /srv/www/vhosts/dl.opensuse.or.id and <strong>this-is-download-location.txt</strong> on   /srv/www/vhosts/download.opensuse.or.id.  By setting this, browsing http://dl.opensuse.or.id will be refer to   /srv/www/vhosts/dl.opensuse.or.id and diplaying it&#8217;s content : <strong>this-is-dl-location.txt</strong></li>
<li>Restart Apache service :
<pre class="brush: cpp">
service apache2 restart</pre>
</li>
<li>Edit /etc/hosts and add 2 address :  dl.opensuse.or.id and download.opensuse.or.id both with same address (your local IP address)  or add an address record into your DNS Server. We need this step to bring the request for virtual address into correct address</li>
<li>Testing the virtual host with the url : <strong>http://dl.opensuse.or.id</strong> and <strong>http://download.opensuse.or.id</strong></li>
<li>BEWARE : Don&#8217;t forget to add prefix <strong>NameVirtualHost *:80</strong> into your virtual host configuration. This is a general bug on many tutorial regarding Apache &amp; VirtualHost setup on openSUSE. Without this prefix, virtual host will only refer to same folder</li>
</ol>
<p>On next part, we will discuss YAST usage for configuring Apache Web Server &amp; Virtual Host on openSUSE<strong></strong></p>
<h3  class="related_post_title">Related Entries</h3><ul class="related_post"><li><a href="http://vavai.net/2009/02/23/apache-web-server-virtual-host-on-opensuse-part-1/" title="Apache Web Server &#038; Virtual Host on openSUSE : Part 1">Apache Web Server &#038; Virtual Host on openSUSE : Part 1</a> (8)</li><li><a href="http://vavai.net/2010/03/31/user-account-integration-between-samba-pdc-zimbra-mail-server-on-opensuse-sles/" title="User Account Integration between Samba PDC &#038; Zimbra Mail Server on openSUSE/SLES">User Account Integration between Samba PDC &#038; Zimbra Mail Server on openSUSE/SLES</a> (2)</li><li><a href="http://vavai.net/2010/03/30/how-to-samba-pdcopenldap-on-opensusesles-part-2-finish/" title="How To : Samba PDC+OpenLDAP on openSUSE/SLES Part 2 (Finish)">How To : Samba PDC+OpenLDAP on openSUSE/SLES Part 2 (Finish)</a> (1)</li><li><a href="http://vavai.net/2010/03/30/how-to-samba-pdcopenldap-on-opensusesles-part-1/" title="How To : Samba PDC+OpenLDAP on openSUSE/SLES Part 1">How To : Samba PDC+OpenLDAP on openSUSE/SLES Part 1</a> (3)</li><li><a href="http://vavai.net/2010/03/30/zimbra-mail-server-with-external-authentication-using-samba-pdcopenldap/" title="Zimbra Mail Server with External Authentication using Samba PDC+OpenLDAP">Zimbra Mail Server with External Authentication using Samba PDC+OpenLDAP</a> (2)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://vavai.net/2009/03/02/apache-web-server-virtual-host-on-opensuse-part-2/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Apache Web Server &amp; Virtual Host on openSUSE : Part 1</title>
		<link>http://vavai.net/2009/02/23/apache-web-server-virtual-host-on-opensuse-part-1/</link>
		<comments>http://vavai.net/2009/02/23/apache-web-server-virtual-host-on-opensuse-part-1/#comments</comments>
		<pubDate>Sun, 22 Feb 2009 23:08:34 +0000</pubDate>
		<dc:creator>Masim "Vavai" Sugianto</dc:creator>
				<category><![CDATA[OpenSUSE]]></category>
		<category><![CDATA[Web Server]]></category>
		<category><![CDATA[Apache]]></category>

		<guid isPermaLink="false">http://vavai.net/?p=512</guid>
		<description><![CDATA[Apache Web Server maybe one of such popular server application and those are so many articles describes an implementation how to &#38;  Apache Web Server tutorial on openSUSE. Even with so many tutorial regarding Apache and virtual host on openSUSE, I&#8217;m going to mad for about 2 days finding why Apache virtual host doesn&#8217;t work [...]]]></description>
			<content:encoded><![CDATA[<p><a class="highslide" onclick="return vz.expand(this)" href="http://vavai.net/wp-content/uploads/2009/02/apache_logo.jpg"><img style=' float: left; padding: 4px; margin: 0 7px 2px 0;'  class="alignleft size-full wp-image-513" title="apache_logo" src="http://vavai.net/wp-content/uploads/2009/02/apache_logo.jpg" alt="apache_logo" width="200" height="150" /></a>Apache Web Server maybe one of such popular server application and those are so many articles describes an implementation how to &amp;  Apache Web Server tutorial on openSUSE. Even with so many tutorial regarding Apache and virtual host on openSUSE, I&#8217;m going to mad for about 2 days finding why Apache virtual host doesn&#8217;t work as it should be.</p>
<p>The problem maybe related to my  fault but I don&#8217;t want any openSUSE fans going to be mad for about a days only for setup Virtual Host on openSUSE <img src='http://vavai.net/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />  . Another reason why I writing the tutorial is because I must preparing a good tutorial for Indonesian openSUSE monthly meeting next Saturday.</p>
<p>Tutorial will be divided into 3 part. Initial part is about Apache installation and simple setup to make &#8220;it Works !&#8221;. The second part will describe about virtual host setup using text configuration and the third part will describe graphical method, an implementation of YAST2 Web Server for setting up Apache and virtual host. Let&#8217;s move on the part 1 : Installing and simple configuration</p>
<p style="text-align: center;">*****</p>
<h2><strong>INSTALLATION</strong></h2>
<h4>Installation using  YAST</h4>
<ol>
<li>Open YAST | Software | Software Management</li>
<li>Change the Filter choice from <strong>Search</strong> to  <strong>Patterns</strong><br />
<img src="http://opensuse.or.id/wp-content/uploads/2008/07/setting-web1.jpeg" alt="setting web" /></li>
<li>Scroll down the option and choose <strong>Server Functions</strong></li>
<li>Thick down  <strong>Web and LAMP Server</strong></li>
<li>Click <strong>Accept</strong> and follow the installation wizard</li>
</ol>
<h4>Installation using Konsole/Terminal</h4>
<ol>
<li>Open Konsole / Terminal (ALT+F2, konsole)</li>
<li>Run the following command:</li>
<pre class="brush: cpp">zypper in -t pattern lamp_server</pre>
</ol>
<h2>Simple Configuration</h2>
<h4>Running the Service</h4>
<ol>
<li>Open <strong>YAST | System | System Services (Runlevel)</strong></li>
<li>Find the service name :  Apache2</li>
<li>Click  start and Enable</li>
<li>we would also activating and running the service using konsole by running this command from konsole :</li>
<pre class="brush: cpp">chkconfig --add apache2
chkconfig apache2 on
service apache2 restart</pre>
</ol>
<h4>Activating Index File</h4>
<p>For security reason, openSUSE disabling unindexed folder. If we try to browse the folder without index.html, it will shocked us with error message<strong> &#8220;Access Forbidden&#8221;.</strong> We may add the index file (e.g : index.php) into Apache configuration or change the index behaviouras describe below  :</p>
<ol>
<li>Open file <strong>/etc/apache2/server-default.conf</strong></li>
<li>Go to the position of DocumentRoot  configuration (see below)</li>
<pre class="brush: cpp">#
# Configure the DocumentRoot
#
&lt;Directory &quot;/srv/www/htdocs&quot;&gt;
# Possible values for the Options directive are &quot;None&quot;, &quot;All&quot;,
# or any combination of:
#   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
#
# Note that &quot;MultiViews&quot; must be named *explicitly* --- &quot;Options All&quot;
# doesn&#039;t give it to you.
#
# The Options directive is both complicated and important.  Please see
# http://httpd.apache.org/docs-2.2/mod/core.html#options
# for more information.
Options None
# AllowOverride controls what directives may be placed in .htaccess files.
# It can be &quot;All&quot;, &quot;None&quot;, or any combination of the keywords:
#   Options FileInfo AuthConfig Limit
AllowOverride None
# Controls who can get stuff from this server.
Order allow,deny
Allow from all
&lt;/Directory&gt;</pre>
<li>Change <strong>Options None</strong> into Options All. We may also using another option (Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews). Please refer to <a href="http://httpd.apache.org/docs-2.2/mod/core.html#options">http://httpd.apache.org/docs-2.2/mod/core.html#options</a> for further information</li>
<li>Restart Apache</li>
<pre class="brush: cpp">service apache2 restart</pre>
</ol>
<h2><strong>Testing the Web Server</strong></h2>
<ol>
<li>Open your browser</li>
<li>Type this address : http://ip-address-web-server or http://hostname or http://localhost (The last option will only be used on your local computer). Contoh : http://192.168.100.1 atau http://vavai.vavai.com</li>
<li>If you get the nice information <strong>It Works!</strong> then you passed the first part of Apache setting <img src='http://vavai.net/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </li>
</ol>
<h2><strong>Note</strong></h2>
<ol>
<li>openSUSE used /srv/www/htdocs as default home folder</li>
<li>Apache configuration could be found at /etc/apache2</li>
<li>If you used Firewall, make an exceptin for port 80 unless you used another port. Port  80 is a standar port for Apache Web Server</li>
</ol>
<h3  class="related_post_title">Related Entries</h3><ul class="related_post"><li><a href="http://vavai.net/2009/03/02/apache-web-server-virtual-host-on-opensuse-part-2/" title=" Apache Web Server &#038; Virtual Host on openSUSE : Part 2"> Apache Web Server &#038; Virtual Host on openSUSE : Part 2</a> (4)</li><li><a href="http://vavai.net/2010/03/31/user-account-integration-between-samba-pdc-zimbra-mail-server-on-opensuse-sles/" title="User Account Integration between Samba PDC &#038; Zimbra Mail Server on openSUSE/SLES">User Account Integration between Samba PDC &#038; Zimbra Mail Server on openSUSE/SLES</a> (2)</li><li><a href="http://vavai.net/2010/03/30/how-to-samba-pdcopenldap-on-opensusesles-part-2-finish/" title="How To : Samba PDC+OpenLDAP on openSUSE/SLES Part 2 (Finish)">How To : Samba PDC+OpenLDAP on openSUSE/SLES Part 2 (Finish)</a> (1)</li><li><a href="http://vavai.net/2010/03/30/how-to-samba-pdcopenldap-on-opensusesles-part-1/" title="How To : Samba PDC+OpenLDAP on openSUSE/SLES Part 1">How To : Samba PDC+OpenLDAP on openSUSE/SLES Part 1</a> (3)</li><li><a href="http://vavai.net/2010/03/30/zimbra-mail-server-with-external-authentication-using-samba-pdcopenldap/" title="Zimbra Mail Server with External Authentication using Samba PDC+OpenLDAP">Zimbra Mail Server with External Authentication using Samba PDC+OpenLDAP</a> (2)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://vavai.net/2009/02/23/apache-web-server-virtual-host-on-opensuse-part-1/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
	</channel>
</rss>
<!-- WP Super Cache is installed but broken. The path to wp-cache-phase1.php in wp-content/advanced-cache.php must be fixed! -->