<?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>It's not a blog, It's a feature &#187; Administration</title>
	<atom:link href="http://javazquez.com/juan/category/administration/feed/" rel="self" type="application/rss+xml" />
	<link>http://javazquez.com/juan</link>
	<description>Juan A. Vazquez</description>
	<lastBuildDate>Wed, 01 Sep 2010 03:35:23 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Proxy/ReverseProxy and Apache2</title>
		<link>http://javazquez.com/juan/2008/08/16/proxyreverseproxy-and-apache2/</link>
		<comments>http://javazquez.com/juan/2008/08/16/proxyreverseproxy-and-apache2/#comments</comments>
		<pubDate>Sat, 16 Aug 2008 14:37:45 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Administration]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[configuration]]></category>

		<guid isPermaLink="false">http://javazquez.com/juan/?p=13</guid>
		<description><![CDATA[I recently configured Apache2 to be a ReverseProxy/Proxy and thought I would share my experiences while it was still fresh. Having never configured any kind of proxy, I found this webpage very informative. The scenario I would like to use for my example is that I have three internal web servers called Site Local IP Remote [...]]]></description>
			<content:encoded><![CDATA[<p>I recently configured Apache2 to be a ReverseProxy/Proxy and thought I would share my experiences while it was still fresh. Having never configured any kind of proxy, I found <a href="http://httpd.apache.org/docs/2.0/mod/mod_proxy.html">this webpage </a> very informative.  The scenario I would like to use for my example is that I have three internal web servers called</p>
<table>
<th>Site</th>
<th>Local IP</th>
<th>Remote IP</th>
<th>Port</th>
<tr>
<td>www.reallycoolsite.com</td>
<td>192.168.1.102</td>
<td>10.15.22.1</td>
<td>80</td>
</tr>
<tr>
<td>www.justcoolsite.com</td>
<td>192.168.1.102 </td>
<td> 10.15.22.2 </td>
<td>80</td>
</tr>
<tr>
<td>www.reallylamesite.com</td>
<td> 192.168.1.44</td>
<td> 10.15.22.3</td>
<td>80</td>
</tr>
</table>
<p>Alright&#8230;pretty straight forward right? If you are in a situation that I was when I started, you haven&#8217;t done much more than install apache from source and added a few modules here and there occasionally. The way I solved the problem was to create <a href="http://httpd.apache.org/docs/1.3/vhosts/name-based.html">name-based virtual host</a> for each of the servers.<br />
our example would look like</p>
<p><code><br />
#you can listen on specific ports for requests if you like<br />
#(ex->Listen 192.168.1.102:80)<br />
#I use the below statement to listen on 80 for all requests<br />
Listen *:80<br />
#Because we have multiple names mapped to same ip<br />
NameVirtualHost 192.168.1.102:80</p>
<p>&lt;VirtualHost 192.168.1.102:80 &gt;<br />
ServerName www.reallycoolsite.com<br />
ProxyRequests Off<br />
ProxyPass / http://10.15.22.1/<br />
ProxyReverse / http://www.reallycoolsite.com/<br />
ProxyPreserveHost  On<br />
ErrorLog                 reallycoolsite_error_log<br />
<a href="http://httpd.apache.org/docs/2.0/mod/mod_log_config.html#customlog">CustomLog</a> reallycoolsite_access_logs<br />
&lt;/VirtualHost &gt;</p>
<p>&lt;VirtualHost 192.168.1.102:80 &gt;<br />
ServerName www.justcoolsite.com<br />
ProxyRequests Off<br />
ProxyPass / http://10.15.22.2/<br />
ProxyReverse / http://www.justcoolsite.com/<br />
ProxyPreserveHost  On<br />
ErrorLog                 justcoolsite_error_log<br />
<a href="http://httpd.apache.org/docs/2.0/mod/mod_log_config.html#customlog">CustomLog</a> justcoolsite_access_logs<br />
&lt;/VirtualHost &gt;</p>
<p>&lt;VirtualHost 192.168.1.44:80 &gt;<br />
ServerName www.reallylamesite.com<br />
ProxyRequests Off<br />
ProxyPass / http://10.15.22.3/<br />
ProxyReverse / http://www.reallylamesite.com/<br />
ProxyPreserveHost  On<br />
ErrorLog                 reallylamesite_error_log<br />
<a href="http://httpd.apache.org/docs/2.0/mod/mod_log_config.html#customlog">CustomLog</a> reallylamesite_access_logs<br />
&lt;/VirtualHost &gt;<br />
</code></p>
<p>If you receive errors during the communication of your proxy and your server, it may be a good idea to investigate if you have an http protocol error discussed at the bottom of this <a href="http://httpd.apache.org/docs/2.0/mod/mod_proxy.html">page</a><br />
The following two lines are pulled from the reference and fixed a problem I had with one of my IIS servers using SSL(for more info about the issue, go <a href="http://support.microsoft.com/kb/187504">here</a><br />
<strong><br />
SetEnv force-proxy-request-1.0 1<br />
SetEnv proxy-nokeepalive 1<br />
</strong><br />
My apache configuration file(httpd.conf) was the file I used to edit my settings.. Your file may be different depending on how new your apache version is. I found that some implementations called the configuration file apache.conf&#8230;. I hope this blog entry is helpful you, Happy Configuring!</p>
]]></content:encoded>
			<wfw:commentRss>http://javazquez.com/juan/2008/08/16/proxyreverseproxy-and-apache2/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>su vs. &#8220;su -&#8221;  The Mystery Revealed</title>
		<link>http://javazquez.com/juan/2008/06/24/su-vs-su-the-mystery-revealed/</link>
		<comments>http://javazquez.com/juan/2008/06/24/su-vs-su-the-mystery-revealed/#comments</comments>
		<pubDate>Wed, 25 Jun 2008 03:25:07 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Administration]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Bash]]></category>
		<category><![CDATA[Security]]></category>

		<guid isPermaLink="false">http://javazquez.com/juan/?p=6</guid>
		<description><![CDATA[Inquiring minds want to know, what is this su - and why is it different than su? Well, if you are like me, you didn&#8217;t even know that su - existed. I ran into this problem when I was trying to add a new user to a new Linux machine. Remote root login was disabled(for [...]]]></description>
			<content:encoded><![CDATA[<p>Inquiring minds want to know, what is this <code>su - </code> and why is it different than <code>su</code>? Well, if you are like me, you didn&#8217;t even know that <code>su - </code>existed. I ran into this problem when I was trying to add a new user to a new Linux machine. Remote root login was disabled(for obvious reasons:D) and I was logged in with my regular non-privileged user account. Well, normally the story goes like this&#8230;</p>
<ol>
<li>su</li>
<li>Authenticate</li>
<li>useradd <em>account</em></li>
<li>set password</li>
<li>log out of privileged account</li>
<li>Take coffee break from all the hard work and call it a day</li>
</ol>
<p>No so today:( . When I attempted to run step three(<code>useradd</code>), I received a <code><strong>command not found</strong></code> error. &#8220;That&#8217;s weird&#8221; I thought. How could a machine not have this basic command. I looked in the bin directory to see if it was some kind of path error I was having. Thinking that this was the case, I was shocked to see that none of the user commands(adduser, usermod, deluser) where there.</p>
<p>After a few minutes of scratching my head, I asked someone more versed in Linux than I what they thought. After walking through each of the steps I had taken, my mistake was easily spotted. I hadn&#8217;t added the &#8216;-&#8217; to the <code>su</code> command. Thinking that the explanation was weird, I checked with google for the <code>su -</code> command. Sure enough, the <a href="http://en.wikipedia.org/wiki/Su_(Unix)">link</a> to Wikipedia had this to say about it,</p>
<blockquote><p>Optionally, you can use a hyphen with su to invoke a login shell and assume the target    user&#8217;s complete user environment:</p></blockquote>
<p>I am glad I had someone to point this out to me&#8230; It could have been a longer and very frustrating ordeal. It was also a lesson for me to refer more to the man pages(it had the answer there too). I hope this blog entry helps someone else who is confronted with this situation.</p>
]]></content:encoded>
			<wfw:commentRss>http://javazquez.com/juan/2008/06/24/su-vs-su-the-mystery-revealed/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
