<?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>Ask the German &#187; Apache</title>
	<atom:link href="http://www.askthegerman.com/archives/category/webtech/webserver/apache/feed" rel="self" type="application/rss+xml" />
	<link>http://www.askthegerman.com</link>
	<description>"the owl of Minerva spreads its wings only with the falling of the dusk"</description>
	<lastBuildDate>Thu, 30 Apr 2009 10:26:57 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Tomcat Monitoring</title>
		<link>http://www.askthegerman.com/archives/252</link>
		<comments>http://www.askthegerman.com/archives/252#comments</comments>
		<pubDate>Mon, 02 Feb 2009 09:51:02 +0000</pubDate>
		<dc:creator>Volker</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[Web Technologies]]></category>
		<category><![CDATA[8080]]></category>
		<category><![CDATA[Apache Tomcat]]></category>
		<category><![CDATA[csv]]></category>
		<category><![CDATA[java-servlet]]></category>
		<category><![CDATA[java-X]]></category>
		<category><![CDATA[manager]]></category>
		<category><![CDATA[Monitoring]]></category>
		<category><![CDATA[password]]></category>
		<category><![CDATA[protocol]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[server.conf]]></category>
		<category><![CDATA[Status]]></category>
		<category><![CDATA[tomcat-users.xml]]></category>
		<category><![CDATA[userid]]></category>

		<guid isPermaLink="false">http://www.askthegerman.com/?p=252</guid>
		<description><![CDATA[So you have a wonderful java-servlet and you have a stable and reasonable fast application server like tomcat? But sometimes you have performance breakdowns. Sometimes the application seems to be frozen. Sometimes you just want to know what the hell is going on with your application. So the best way is to say: ÑPlease my [...]]]></description>
			<content:encoded><![CDATA[<p>So you have a wonderful java-servlet and you have a stable and reasonable fast application server like tomcat? But sometimes you have performance breakdowns.</p>
<ul>
<li>Sometimes the application seems to be frozen.</li>
<li>Sometimes you just want to know what the hell<br />       is going on with your application.</li>
</ul>
<p>So the best way is to say:<br />   <strong><em>ÑPlease my little tomcat, tell me ñ how do you feel right now?ì</em></strong></p>
<p>And if you choose the right method you will get some answers.<br />           The good news ahead ñ it isn&#8217;t very difficult to get the information.</p>
<p> You just have to enable the tomcat console. And furthermore you should enable the printout of the garbage collects.<br />   <em>(type &quot;java -X&quot; to get the right gc options for your java-version &#8211; normally something like verbose:gc. I will show you in detail in another article)</em></p>
<p>Just edit the tomcat-users.xml File.</p>
<p>You have to add the roles: manager and admin and add a user and a password that meets your needs. Invent your own username and password and keep it secret. Because userid and password are not encrypted (if you do not explicitly configure https as protocol) you should keep in mind that this is no high sophisticated security.</p>
<p><img alt="Tomcat Monitoring" title="Tomcat Monitoring" src="http://www.askthegerman.com/wp-content/uploads/tomcat/tomcat-monitoring.jpg" height="157" width="429" /></p>
<p>Nevertheless &#8211; save your tomcat-users.xml file and restart tomcat. If your tomcat listens on the standard port (8080) give the manager console a try:</p>
<p><em>http://yourserver-adress:8080/manager/html</em></p>
<p>You will be prompted for a username and password &#8211; if you can remember the values you had put in the tomcat-user.xml file &#8211; go on and put them in. So you can see the console &#8211; not very exciting &#8211; thats true. Here you can just see how many sessions are currently active in an application . And if you want to have fun and you are !not the responsible person for this service you can easily stop an application within the tomcat.</p>
<p>But to be more serious ñ now choose the link in the upper right corner (Server Status) and again the link in the upper right corner (Complete Server Status).<br />           Or just enter:</p>
<p><em>http://yourserver-adress:8080/manager/status/all</em></p>
<p>Take some time to explore the page. Reload the page several times ñ look at how the connections fall and rise. Don&#8217;t forget to check the Memory ñ is enough free memory left ? What is the state of the connections ñ are there any connections left. How many threads are busy? How many spare threads do you have? Perhaps you have to adjust the values in the server.conf file.</p>
<p>Can you imagine that it is very easy to get this values extracted and in a &quot;cvs&quot;-file on a regular basis ? So you can get historical values &#8211; But that is subject for an own article. </p>
<script type="text/javascript">
  addthis_url    = 'http%3A%2F%2Fwww.askthegerman.com%2Farchives%2F252';
  addthis_title  = 'Tomcat+Monitoring';
  addthis_pub    = '';
</script><script type="text/javascript" src="http://s7.addthis.com/js/addthis_widget.php?v=12" ></script>
]]></content:encoded>
			<wfw:commentRss>http://www.askthegerman.com/archives/252/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Password Protect Webfolders</title>
		<link>http://www.askthegerman.com/archives/227</link>
		<comments>http://www.askthegerman.com/archives/227#comments</comments>
		<pubDate>Sun, 14 Dec 2008 11:55:42 +0000</pubDate>
		<dc:creator>Michael</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Operating System]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[UNIX]]></category>
		<category><![CDATA[Webserver]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[.htaccess]]></category>
		<category><![CDATA[.htpasswd]]></category>
		<category><![CDATA[htpasswd2]]></category>
		<category><![CDATA[password]]></category>
		<category><![CDATA[protect]]></category>
		<category><![CDATA[username]]></category>
		<category><![CDATA[webfolder]]></category>
		<category><![CDATA[webroot]]></category>

		<guid isPermaLink="false">http://www.askthegerman.com/?p=227</guid>
		<description><![CDATA[Sometimes we have to place content on our webserver we want to protect and only accessed by privileged users. A basic security can be established by a password restricted folder access, enforced by the Apache Webserver itself. This can be done by some simple instructions added to our .htaccess file: (In case you haven&#8217;t already [...]]]></description>
			<content:encoded><![CDATA[<p>Sometimes we have to place content on our webserver we want to protect and only accessed by privileged users.</p>
<p>A basic security can be established by a password restricted folder access, enforced by the Apache Webserver itself.</p>
<p>This can be done by some simple instructions added to our .htaccess file:<br />     (In case you haven&#8217;t already a .htaccess file, just create a new file calling it .htaccess and locating it in the folder you want to protect.) </p>
<p><em>AuthType Basic<br />     AuthName &quot;Protected Area&quot;<br />     AuthUserFile FILE<br />     require valid-user</em></p>
<p>These commands will tell the Apache webserver that the folder in question (and all below) are now protected and it needs a valid combination of username/password to access it.</p>
<ul>
<li><em>AuthName</em> is some free form text you can specify, telling the visitor what you are asking for and Apache Webserver will show in it&#8217;s dialog box.</li>
</ul>
<ul>
<li><em>AuthUserFile</em> is the reference to the stored .htpasswd file containing all valid username/password combinations to access the folder in question (ususally and best located out of the protected directory tree).</li>
</ul>
<p>Having that done we now need to create the necessary .htpasswd file which we can do interactive on our server with the command:</p>
<p><em>htpasswd2 -c FILE USER</em></p>
<p>Assuming html is your webroot, a valid example, for protecting a folder called images below our webroot and using demouser/demopassword as user credentials, would be:</p>
<p><strong>.htaccess:</strong><br />     (Locate this file within the folder images and be aware to use an absolute path for <em>AuthUserFile, </em>as for <em>www.domain.com</em> would be wrong!)</p>
<p><em>AuthUserFile /home/username/html/.htpasswd<br />     AuthType Basic<br />     AuthName &quot;Login for Secure Area&quot;<br />     require valid-user</em> </p>
<p><strong>.htpasswd</strong><br />     (Create a new file called .htpasswd and locate this file within the folder you&#8217;ve specified within <em>AuthUserFile </em>path<em>.</em>)</p>
<p><em>demouser:$1$OHq3K5v3$pvFrGsHjWwYjpkZhc70T9. </em> </p>
<script type="text/javascript">
  addthis_url    = 'http%3A%2F%2Fwww.askthegerman.com%2Farchives%2F227';
  addthis_title  = 'Password+Protect+Webfolders';
  addthis_pub    = '';
</script><script type="text/javascript" src="http://s7.addthis.com/js/addthis_widget.php?v=12" ></script>
]]></content:encoded>
			<wfw:commentRss>http://www.askthegerman.com/archives/227/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting up BI Publisher against MySQL</title>
		<link>http://www.askthegerman.com/archives/197</link>
		<comments>http://www.askthegerman.com/archives/197#comments</comments>
		<pubDate>Sun, 07 Dec 2008 17:08:35 +0000</pubDate>
		<dc:creator>Michael</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Database]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Oracle]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[Web Technologies]]></category>
		<category><![CDATA[Webserver]]></category>
		<category><![CDATA[Apache Tomcat]]></category>
		<category><![CDATA[BI Publisher]]></category>
		<category><![CDATA[Business Intelligence Suit]]></category>
		<category><![CDATA[Classpath]]></category>
		<category><![CDATA[Data Source]]></category>
		<category><![CDATA[JDBC]]></category>
		<category><![CDATA[LAMP]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[WEBDAV]]></category>
		<category><![CDATA[XML]]></category>
		<category><![CDATA[xmlp-server-config.xml]]></category>
		<category><![CDATA[xmlpserver.war]]></category>
		<category><![CDATA[XMPL Server]]></category>

		<guid isPermaLink="false">http://www.askthegerman.com/?p=197</guid>
		<description><![CDATA[Oracle&#8217;s BI Publisher which is part of the Oracle Business Intelligence Suit has at least within Enterprise Computing environment established as a reliable and preferable choice when it comes to replace the somewhat aged Oracle Reports. Once being familiar with it you will ask yourself about why switching tool when it comes to the need [...]]]></description>
			<content:encoded><![CDATA[<p>Oracle&#8217;s BI Publisher which is part of the Oracle Business Intelligence Suit has at least within Enterprise Computing environment established as a reliable and preferable choice when it comes to replace the somewhat aged Oracle Reports.</p>
<p>Once being familiar with it you will ask yourself about why switching tool when it comes to the need of creating reports in a normal web design world mostly using MySQL Databases within a &quot;LAMP&quot; environment.</p>
<p>Written as an universal reporting tool BI Publishes does offer us a more or less universal data interface based on JDBC connections. And being able to act itself as a callable web service offering WEBDAV services based on XML data exchange it anyway seems to be an excellent choice for this world.</p>
<p>Already Oracle&#8217;s installation instructions does give you a quick idea about setting up BI Publisher working against some MySQL Database. But acting&nbsp; in a Web environment you might find it cool integration the BI Publisher within an already existing Apache Tomcat environment and for exactly this environment I will give you a short explanation about getting things together and ready for work.</p>
<p>First we will pick the BI Publisher software itself by copying the xmlpserver.war file from the distribution DVD and throwing it into the webapps folder of our Apache Tomcat. Waiting a few seconds until the self-deploying mechanism of the Apache Tomcat has extracted the files for us, we need to specify the access path to our project and development repository within the file xmlp-server-config.xml.</p>
<p>Having done that, we need to add the MySQL JDBC driver to our system and making it known within the environment of the Apache Tomcat. (The MySQL JDBC driver can be downloaded from: <a href="http://www.mysql.com/products/connector/j/">http://www.mysql.com/products/connector/j/</a>.) </p>
<p>So with the downloaded fileready, we have to extract it to any place we like onto our disk. Just I would recommend you to put it somewhere close to your MySQL installation for you being able to later on remember it again. Finally extracted and ready to use, we have to add the information about the mysql-connector-java- <version>-bin.jar file to the Java Classpath of the Apache Tomcat and finally restarting it:</version></p>
<p><img alt="Configuring Java Classpath" title="Configuring Java Classpath" src="http://www.askthegerman.com/wp-content/uploads/bip/bip01.jpg" height="290" width="300" />&nbsp;</p>
<p>Having this set, as a last step we have to invoke the BI Publisher itself, in which we then will configure the new JDBC data source within the Admin region of it: </p>
<p><img alt="Configuring JDBC Data Source" title="Configuring JDBC Data Source" src="http://www.askthegerman.com/wp-content/uploads/bip/bip02.jpg" height="155" width="400" />&nbsp;</p>
<p>And now with this tweaking ready, MySQL DB should connect, open and work for you like a charm. </p>
<script type="text/javascript">
  addthis_url    = 'http%3A%2F%2Fwww.askthegerman.com%2Farchives%2F197';
  addthis_title  = 'Setting+up+BI+Publisher+against+MySQL';
  addthis_pub    = '';
</script><script type="text/javascript" src="http://s7.addthis.com/js/addthis_widget.php?v=12" ></script>
]]></content:encoded>
			<wfw:commentRss>http://www.askthegerman.com/archives/197/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP Settings in a Shared Environment</title>
		<link>http://www.askthegerman.com/archives/59</link>
		<comments>http://www.askthegerman.com/archives/59#comments</comments>
		<pubDate>Fri, 07 Nov 2008 15:42:39 +0000</pubDate>
		<dc:creator>Michael</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[Web Technologies]]></category>
		<category><![CDATA[Webserver]]></category>
		<category><![CDATA[.htaccess]]></category>
		<category><![CDATA[configuration]]></category>
		<category><![CDATA[environment]]></category>
		<category><![CDATA[LAMP]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[shared hosting]]></category>

		<guid isPermaLink="false">http://www.askthegerman.com/?p=59</guid>
		<description><![CDATA[Working with LAMP (Linux, Apache, MySQL and PHP) Applications we sooner or later do run into the need to change our actual runtime environment for it. Mostly based on specific PHP settings an application does need to be able to run first, we have to specify, change or increase PHP default settings, but do feel [...]]]></description>
			<content:encoded><![CDATA[<p>Working with LAMP (<strong>L</strong>inux, <strong>A</strong>pache, <strong>M</strong>ySQL and <strong>P</strong>HP) Applications we sooner or later do run into the need to change our actual runtime environment for it. Mostly based on specific PHP settings an application does need to be able to run first, we have to specify, change or increase PHP default settings, but do feel somewhat handicapped within a shared hosting environment. Usually Admins there do not allow everybody allow to modify or hack their central configuration files on the server.</p>
<p>But also for this situation clever developers have thought about a trick to help their community to overcome such hassle.</p>
<p> As a matter of fact it is possible to change PHP configuration settings within .htaccess very easily for everyone.</p>
<p>For example it is possible to</p>
<blockquote><p><span style="font-weight: bold">Prevent Global Variable Injection Attacks</span><strong> with:</strong></p>
</blockquote>
<p><strong> </strong></p>
<ul></ul>
<div class="codecontent">
<ul>
<li><em>php_flag register_globals off</em></li>
</ul>
</div>
<blockquote></blockquote>
<blockquote><p><span style="font-weight: bold">Prevent Cross Site Scripting (XSS) Attacks with:</span></p>
</blockquote>
<ul></ul>
<div class="codecontent">
<ul>
<li><em>php_flag allow_url_fopen off </em></li>
</ul>
</div>
<blockquote></blockquote>
<blockquote><p><span style="font-weight: bold">Prevent Code Injection Attacks with:</span></p>
</blockquote>
<ul></ul>
<div class="codecontent">
<ul>
<li><em>php_flag magic_quotes_gpc on</em></li>
</ul>
<p> To do so</p>
</div>
<p>1. Open the <span style="font-style: italic">.htaccess</span> file located in your site&#8217;s home directory, or if you don&#8217;t have one, create a blank one now. </p>
<p>2. Add any of the following code samples to your .htaccess file, each on it&#8217;s own line.</p>
<script type="text/javascript">
  addthis_url    = 'http%3A%2F%2Fwww.askthegerman.com%2Farchives%2F59';
  addthis_title  = 'PHP+Settings+in+a+Shared+Environment';
  addthis_pub    = '';
</script><script type="text/javascript" src="http://s7.addthis.com/js/addthis_widget.php?v=12" ></script>
]]></content:encoded>
			<wfw:commentRss>http://www.askthegerman.com/archives/59/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Multilingual Websites with Apache</title>
		<link>http://www.askthegerman.com/archives/57</link>
		<comments>http://www.askthegerman.com/archives/57#comments</comments>
		<pubDate>Wed, 05 Nov 2008 21:06:33 +0000</pubDate>
		<dc:creator>Michael</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Web Technologies]]></category>
		<category><![CDATA[Webserver]]></category>
		<category><![CDATA[+Multiviews]]></category>
		<category><![CDATA[.htaccess]]></category>
		<category><![CDATA[AddLanguage]]></category>
		<category><![CDATA[AllowOverride]]></category>
		<category><![CDATA[extention]]></category>
		<category><![CDATA[language]]></category>
		<category><![CDATA[Multilingual]]></category>
		<category><![CDATA[website]]></category>

		<guid isPermaLink="false">http://www.askthegerman.com/?p=57</guid>
		<description><![CDATA[With&#160; AllowOverride set to ALL, Web Administrators and Hosting Provider do gives their customers a powerfull to customize Apache fitting to all their personal needs. Running with this setting, Apache is looking for individual settings specified within a file .htaccess on a per directory basis. This means every folder below our webroot can have individual [...]]]></description>
			<content:encoded><![CDATA[<p>With&nbsp; AllowOverride set to ALL, Web Administrators and Hosting Provider do gives their customers a powerfull to customize Apache fitting to all their personal needs.</p>
<p>Running with this setting, Apache is looking for individual settings specified within a file .htaccess on a per directory basis. This means every folder below our webroot can have individual and different settings for sure.</p>
<p>Mostly this feature is used to enable and enforce access restrictions, but also can be used to build up static multilingual websites as well. Doing so we have to enable need to enable MultiViews within .htaccess file. </p>
<p>A basic example of such a .htaccess file would be:</p>
<p>
<p><em>Options +MultiViews <br /> AddLanguage de de <br /> AddLanguage en en <br /> LanguagePriority de en</em></p>
</p>
<p>Having MultiViews enabled we can add special language extensions to the filename (e.q. index.html.en), helping Apache to identified the correct file containing content in the language requested by the client. So a webbrowser requesting pages in German language and asking an Apache (runing on English language) for a page index.html would automatically get served with a page index.html.de while index.html.en or index.html would be the automatic fallback in case this German page would not be present.</p>
<p>So the basic idea is just to double your webpages having one specific page in every needed language defined by it&#8217;s language specific filename extention.</p>
<script type="text/javascript">
  addthis_url    = 'http%3A%2F%2Fwww.askthegerman.com%2Farchives%2F57';
  addthis_title  = 'Multilingual+Websites+with+Apache';
  addthis_pub    = '';
</script><script type="text/javascript" src="http://s7.addthis.com/js/addthis_widget.php?v=12" ></script>
]]></content:encoded>
			<wfw:commentRss>http://www.askthegerman.com/archives/57/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

