<?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>joepetruska.com &#187; apache</title>
	<atom:link href="https://joepetruska.com/wordpress/?feed=rss2&#038;tag=apache" rel="self" type="application/rss+xml" />
	<link>https://joepetruska.com/wordpress</link>
	<description>nerd tech junk stuff hacks and the like</description>
	<lastBuildDate>Wed, 09 Apr 2014 21:42:35 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>https://wordpress.org/?v=247</generator>
	<item>
		<title>Hacking the POGOplug.  The definitive guide in progress. [PT1]</title>
		<link>https://joepetruska.com/wordpress/?p=12</link>
		<comments>https://joepetruska.com/wordpress/?p=12#comments</comments>
		<pubDate>Thu, 17 May 2012 21:50:23 +0000</pubDate>
		<dc:creator><![CDATA[Joe]]></dc:creator>
				<category><![CDATA[How To]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Tech]]></category>
		<category><![CDATA[The Pogoplug]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[archlinux]]></category>
		<category><![CDATA[guide]]></category>
		<category><![CDATA[hacking]]></category>
		<category><![CDATA[lamp]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[samba]]></category>

		<guid isPermaLink="false">http://joepetruska.com/wordpress/?p=12</guid>
		<description><![CDATA[[Pt1] GOAL: To setup from beginning to end a personalized Pogoplug server.  Installation of Arch Linux, with addition of Apache, PHP, MySQL and whatever else we may decide upon. THINGS YOU WILL NEED: Pogoplug v2...]]></description>
				<content:encoded><![CDATA[<h1><span style="color: #99cc00;">[Pt1]</span></h1>
<p><a href="http://joepetruska.com/wordpress/wp-content/uploads/2012/04/Photo-Apr-22-17-21-31-Small.jpg"><img class="aligncenter size-medium wp-image-17" title="pogoplug" src="http://joepetruska.com/wordpress/wp-content/uploads/2012/04/Photo-Apr-22-17-21-31-Small-300x300.jpg" alt="" width="300" height="300" /></a></p>
<p><strong><span style="color: #00ff00;">GOAL:</span><br />
</strong>To setup from beginning to end a personalized Pogoplug server.  Installation of Arch Linux, with addition of Apache, PHP, MySQL and whatever else we may decide upon.</p>
<p><span style="color: #00ff00;"><strong>THINGS YOU WILL NEED:</strong></span></p>
<ul>
<li>Pogoplug v2 (Pink/Gray)</li>
<li>2gb+ Clean flashdrive or external hard drive</li>
<li>Mac Terminal or Windows Terminal Program (I like <a href="http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html">PuTTY</a>)</li>
<li>Basic Linux knowledge and the ability to follow a manual <img src="https://s.w.org/images/core/emoji/72x72/1f61b.png" alt="😛" class="wp-smiley" style="height: 1em; max-height: 1em;" /></li>
<li>Install time.  (This varies greatly, but figure about 45 min for a Linux veteran, maybe about 90+ for novices.  Depending on what it is you would like to do, configuring this beast could take hours or days..)</li>
</ul>
<h2><span style="color: #ff0000;"><strong>** NOTE **</strong></span></h2>
<p><span style="color: #ff0000;"><br />
Following this guide will void your manufacturer&#8217;s warranty, and will lead to very little official support in the event of imminent failure.  Do not blame me if you mess something up as I assume no responsibility for what you do with this guide.  With that being said.</span></p>
<p><span style="color: #00ff00;"><strong><br />
</strong></span></p>
<p><span style="color: #00ff00;"><strong>Preface:<br />
Intro to the Pogoplug</strong></span></p>
<p>Recently I have taken a keen liking to a little pink web device, the Pogoplug.  When I first read about the Pogoplug, the concept sounded very intriguing.  The ability to run your own cloud server from the home seemed like an excellent idea.  Kick in the ability to hack and run Linux? That would be awesome! I was sold.  I had to have one.</p>
<p>I browsed around for a good deal, as I was on a limited budget.   I found a friend that was selling his device, he didn&#8217;t want it and parted with it cheap.  A Pogoplug Pink v2! Let the hacking begin!</p>
<p>Upon first boot, everything appeared to go well.  I plugged it in, and shortly after the device was fully illuminated and ready to go.  I attempted to access it with the Pogoplug software, but found that I could not.  There was a big problem.  These devices are tied to users Pogoplug accounts by the serial numbers, so if a user does not unregister the device, you cannot do much with it; however I did read that in some cases customer support can grant you access to a device.</p>
<p><a href="http://joepetruska.com/wordpress/wp-content/uploads/2012/04/pogobottom.jpg"><img class="alignnone size-thumbnail wp-image-29" title="pogobottom" src="http://joepetruska.com/wordpress/wp-content/uploads/2012/04/pogobottom-150x150.jpg" alt="" width="150" height="150" /></a><a href="http://joepetruska.com/wordpress/wp-content/uploads/2012/04/Photo-Apr-22-17-21-31-Small.jpg"><br />
</a>In my case it was not that bad. I contacted my friend, he removed it from his account, and it was good to go.</p>
<h2 style="padding-left: 30px;"><span style="color: #ffff99;">** HINT **</span></h2>
<p style="padding-left: 30px;"><span style="color: #ffff99;">It would be to write down your MAC address, which is located under the bar-code on the bottom of the device.  Next, log into your routers administrative page.  You should be able to find a section of your routers configuration services, that allow you to set static leases.  You would want to set a static lease on a headless setup like this, so that you always know at what address you can access your Pogoplug.</span></p>
<p>Have the USB device that you plan to install to handy.  I am using just some old drive that I had laying around.  2 GB PNY.  Nothing special.<span style="text-decoration: underline;"><strong><span style="color: #ff0000; text-decoration: underline;"><br />
Be aware that anything on the drive is going to be erased during the setup process, so make sure to back it up.</span></strong></span></p>
<p><a style="color: #c4513f;" href="http://joepetruska.com/wordpress/wp-content/uploads/2012/04/flashdrive.jpg"><img class="size-thumbnail wp-image-28 alignnone" title="flashdrive" src="http://joepetruska.com/wordpress/wp-content/uploads/2012/04/flashdrive-150x150.jpg" alt="" width="150" height="150" /></a></p>
<h2><span style="color: #ff0000;">** NOTE **</span><br />
<span style="color: #ff0000;">This setup guide is only for (PogoPlug v2)</span></h2>
<h2><strong style="color: #00ff00;"><strong><span style="color: #ff0000;"><span style="color: #ffff00;">Similar setup guides for this and</span> OTHER <span style="color: #ffff00;">compatible devices can be found</span> <span style="color: #ff0000;"><a href="http://archlinuxarm.org/platforms">HERE.</a></span></span></strong></strong></h2>
<p><strong><span style="color: #00ff00;"><br />
Step 1:</span></strong><br />
<strong><span style="color: #00ff00;">Prepare your Pogoplug</span></strong></p>
<p>First with the device on and online,<span style="color: #ff0000;"> remove all of the attached devices</span>.  Attempt to SSH to the IP of the device set by the DHCP. If you are unable to SSH, register and enable SSH through <a href="http://my.pogoplug.com">my.pogoplug.com</a>. The default login (unless changed through <a href="http://my.pogoplug.com">my.pogoplug.com</a>) is root/ceadmin.</p>
<p>Once you are able to connect via SSH make sure you stop the Pogoplug software before continuing.</p>
<pre class="brush: plain; title: ; notranslate"> killall hbwd</pre>
<p>You will only need to do this once as the Pogoplug software will be disabled later in the install</p>
<p>While connected to your Pogoplug, run these commands to download the bootloader that enables booting from USB drives.</p>
<pre class="brush: plain; title: ; notranslate">
cd /tmp
wget http://joepetruska.com/pogoplug/install_uboot_mtd0.sh chmod +x install_uboot_mtd0.sh ./install_uboot_mtd0.sh
chmod +x install_uboot_mtd0.sh
./install_uboot_mtd0.sh
</pre>
<p>After the bootloader finishes downloading, insert the USB drive you intend to use <strong><span style="color: #ff0000;">EVERYTHING WILL BE ERASED</span></strong>.<br />
<span style="color: #ff0000;">Insert the drive into either the front, or the top back USB port.</span><br />
You will now run fdisk to partition the drive.</p>
<p><span style="color: #00ff00;"><strong>Step 2:<br />
Fdisk<br />
</strong><span style="color: #ffffff;">Fdisk will partition your USB flash or hard drive for use by Arch<br />
</span></span></p>
<pre class="brush: plain; title: ; notranslate"> /sbin/fdisk /dev/sda</pre>
<p>fdisk will delete your old partitions</p>
<pre class="brush: plain; title: ; notranslate">
o ## this will remove all partitions
p ## lists any partitions
</pre>
<p>Now we will make the new partitions</p>
<pre class="brush: plain; title: ; notranslate">
n ##first
p ##second
1 ##third
</pre>
<p>Press &#8216;enter&#8217; to continue with defaults.<br />
Exit by pressing &#8216;w&#8217;</p>
<p>Here we create the ext2 filesystem</p>
<pre class="brush: plain; title: ; notranslate">
wget http://archlinuxarm.org/os/pogoplug/mke2fs
chmod 755 mke2fs
./mke2fs /dev/sda1
mkdir usb
mount /dev/sda1 usb
</pre>
<p><span style="color: #00ff00;"><strong>Step 3:<br />
Installing Arch Linux</strong></span><br />
Now we will download and install Arch Linux</p>
<pre class="brush: plain; title: ; notranslate">
cd usb
wget http://archlinuxarm.org/os/ArchLinuxARM-armv5te-latest.tar.gz
tar -xzvf ArchLinuxARM-armv5te-*.tar.gz ## This will take some time
rm ArchLinuxARM-armv5te-*.tar.gz
sync ## Flash drives take longer
</pre>
<p>Now we will clean up and reboot.</p>
<pre class="brush: plain; title: ; notranslate">
cd ..
umount usb
/sbin/reboot
</pre>
<p><span style="color: #ff0000;">If you are running this process from a MAC or Linux machine, your SSH key will be different, and need to be cleared out, to do this run the following</span></p>
<pre class="brush: plain; title: ; notranslate">
ssh-keygen -R 192.168.1.123 ## Your Pogoplug IP
</pre>
<p>Log back in after your Pogoplug reboots using <span style="color: #ff0000;">username:: root <span style="color: #ffffff;">and</span> password:: root</span>.</p>
<p>Congratulations, you just installed ArchLinux onto your new Pogoplug.  Before we finish there are a few things we should do.</p>
<p><span style="color: #00ff00;"><strong>Step 4:<br />
Change Your Root Password</strong></span><br />
This is something <span style="color: #ff0000;">should be done ASAP</span>.  It is very easy just run the following command and follow the prompts:</p>
<pre class="brush: plain; title: ; notranslate">passwd root ## change user password</pre>
<p>Make sure not to forget your root password, as you will use this to login from now on.</p>
<p><strong><span style="color: #00ff00;">** Basic Commands **</span></strong></p>
<pre class="brush: plain; title: ; notranslate">
reboot ## reboots Pogoplug
poweroff ## shuts down Pogoplug to be unplugged
</pre>
<p>These commands should be used for exactly what they imply.  Try not to unplug your Pogoplug while it is running, this could potentially damage your install.<br />
A short repair guide is in the works, so if you have an issue with not booting post it in the comments.</p>
<p>Next time we will take a closer look at some applications to update and install, and start to lay the groundwork for your web-server!</p>
<p><strong><span style="color: #ff6600;">Please let me know of any questions that you may have!</span></strong></p>
<p><span style="color: #ff00ff;"><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&amp;hosted_button_id=8WXPWHENX8X3Y"><span style="color: #ff00ff;">If I helped you out consider buying me a beer <img src="https://s.w.org/images/core/emoji/72x72/1f61b.png" alt="😛" class="wp-smiley" style="height: 1em; max-height: 1em;" /></span></a></span></p>
<h1><strong></strong><span style="color: #ff0000;"><strong><a href="http://joepetruska.com/wordpress/?p=49"><span style="color: #ff0000;">[ PART 2 ] </span></a></strong></span></h1>
]]></content:encoded>
			<wfw:commentRss>https://joepetruska.com/wordpress/?feed=rss2&#038;p=12</wfw:commentRss>
		<slash:comments>15</slash:comments>
		</item>
		<item>
		<title>Hacking the pogoplug. the definitive guide in progress. [PT3]</title>
		<link>https://joepetruska.com/wordpress/?p=133</link>
		<comments>https://joepetruska.com/wordpress/?p=133#comments</comments>
		<pubDate>Sun, 22 Apr 2012 06:43:03 +0000</pubDate>
		<dc:creator><![CDATA[Joe]]></dc:creator>
				<category><![CDATA[How To]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Tech]]></category>
		<category><![CDATA[The Pogoplug]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[archlinux]]></category>
		<category><![CDATA[guide]]></category>
		<category><![CDATA[hacking]]></category>
		<category><![CDATA[lamp]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://joepetruska.com/wordpress/?p=133</guid>
		<description><![CDATA[[Pt3] GOAL: Install the web control panel including Apache/PHP/MySQL and phpMyadmin. THINGS YOU WILL NEED: Pogoplug that has been hacked from Part 2 LETS GET STARTED: Fire up your terminal program.  Where we left off is...]]></description>
				<content:encoded><![CDATA[<h1><span style="color: #99cc00;">[Pt3]</span></h1>
<h1></h1>
<p><a href="http://joepetruska.com/wordpress/wp-content/uploads/2012/04/Photo-Apr-22-17-21-31-Small.jpg"><img class="aligncenter" title="pogoplug" src="http://joepetruska.com/wordpress/wp-content/uploads/2012/04/Photo-Apr-22-17-21-31-Small-300x300.jpg" alt="" width="300" height="300" /></a></p>
<p><strong><span style="color: #00ff00;">GOAL:</span><br />
</strong>Install the web control panel including Apache/PHP/MySQL and phpMyadmin.</p>
<p><span style="color: #00ff00;"><strong>THINGS YOU WILL NEED:</strong></span></p>
<ul>
<li>Pogoplug that has been hacked from <span style="color: #ff0000;"><a title="Part 2" href="http://joepetruska.com/wordpress/?p=49"><span style="color: #ff0000;">Part 2</span></a></span></li>
</ul>
<p><span style="color: #00ff00;"><strong>LETS GET STARTED:</strong></span></p>
<p>Fire up your terminal program.  Where we left off is perfect for setting up the webportal.<br />
<span style="text-decoration: underline; color: #ffff00;"><strong>Make sure to read the content as not all boxes are copy/paste.</strong></span></p>
<p><span style="color: #00ff00;"><strong>Step 1:<br />
Apache / PHP / MySQL:</strong></span></p>
<p>Lets start by installing apache, php and mysql.</p>
<pre class="brush: plain; title: ; notranslate">
pacman -S apache php php5 php-apache mysql&lt;/strong&gt; ## web stuff
</pre>
<p>Start Apache by running the following</p>
<pre class="brush: plain; title: ; notranslate">
rc.d start httpd ## Starts Apache
</pre>
<p><strong><span style="color: #00ff00;">Step 2:</span></strong><br />
<strong><span style="color: #00ff00;">Setting up PHP </span></strong></p>
<p>To setup PHP Add these lines in <code>/etc/httpd/conf/httpd.conf</code>:<br />
Place this in the &#8220;LoadModule&#8221; list anywhere after <code>LoadModule dir_module modules/mod_dir.so</code>:</p>
<pre class="brush: plain; title: ; notranslate">LoadModule php5_module modules/libphp5.so</pre>
<p>Place this line at the end of the &#8216;include&#8217; list:</p>
<pre class="brush: plain; title: ; notranslate">Include conf/extra/php5_module.conf</pre>
<p>Make sure that the following line is uncommented in httpd.conf in the section/(after the line)<code>&lt;IfModule mime_module&gt;</code>:</p>
<pre class="brush: plain; title: ; notranslate">TypesConfig conf/mime.types</pre>
<p>Add this line in <code>/etc/httpd/conf/mime.types</code>:</p>
<pre class="brush: plain; title: ; notranslate">application/x-httpd-php		php php5</pre>
<p>Restart Apache to save changes</p>
<pre class="brush: plain; title: ; notranslate">rc.d restart httpd</pre>
<p><span style="color: #00ff00;"><strong>Step 3:</strong></span><br />
<span style="color: #00ff00;"><strong>Configuring MySQL</strong></span></p>
<p>Now we will configure MySQL.<br />
Edit <strong><code>/etc/php/</code><code>php.ini</code> </strong>(this is in <code>/usr/etc</code> on older systems) to uncomment the following lines (<em>By removing <code>; </code></em>):</p>
<pre class="brush: plain; title: ; notranslate">
;extension=mysqli.so
;extension=mysql.so
</pre>
<p>Start MySQL</p>
<pre class="brush: plain; title: ; notranslate">rc.d start mysqld</pre>
<p>You may need to restart Apache</p>
<p>MySql should now be running,lets change the root password</p>
<pre class="brush: plain; title: ; notranslate">mysqladmin -u root password 'password' ## replace 'password' with your password do not include (',') </pre>
<p><span style="color: #00ff00;"><strong>Step 4:</strong></span><br />
<span style="color: #00ff00;"><strong>Autostart Apache and MySQL<br />
</strong></span><br />
Finally lets add apache and MySQL to the startup.</p>
<pre class="brush: plain; title: ; notranslate">nano /etc/rc.conf</pre>
<p>Scroll down to the bottom to find the following lines</p>
<pre class="brush: plain; title: ; notranslate">
## BEFORE ##
DAEMONS=(ntpd syslog-ng network netfs crond sshd webmin)
## AFTER ##
DAEMONS=(ntpd syslog-ng network netfs crond sshd webmin httpd mysqld)
</pre>
<p>Hit control+&#8217;x&#8217;, follow by &#8216;y&#8217;, follow by &#8216;enter&#8217;.</p>
<p>You have now successfully installed apache php mysql.</p>
<h1><span style="color: #ff0000;"><strong>Reboot your Pogoplug.</strong></span><strong style="color: #ff0000;"> </strong></h1>
<p>A longer, more in depth guide can be found <a title="HERE" href="https://wiki.archlinux.org/index.php/LAMP">HERE</a></p>
<p><span style="color: #00ff00;"><strong>** Basic Commands **</strong></span></p>
<pre class="brush: plain; title: ; notranslate">
rc.d (start/restart/quit) httpd ## basic apache controls
rc.d (start/restart/quit) mysqld ## basic mysql controls&lt;/pre&gt;
</pre>
<p>In the next installment of &#8220;<strong>Hacking the POGOplug.  The definitive guide. Part 4</strong>&#8221; We will look into additional web server software.</p>
<p><span style="color: #ff6600;"><strong>Please let me know of any questions that you may have!  Also, if there are any other features in which you would like to explore!</strong></span></p>
<p><span style="color: #ff00ff;"><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&amp;hosted_button_id=8WXPWHENX8X3Y"><span style="color: #ff00ff;">If I helped you out consider buying me a beer <img src="https://s.w.org/images/core/emoji/72x72/1f61b.png" alt="😛" class="wp-smiley" style="height: 1em; max-height: 1em;" /></span></a></span></p>
<h1>Go to the forums and post your results!</h1>
<h1><a href="http://www.joepetruska.com/forum/">CLICK HERE </a></h1>
]]></content:encoded>
			<wfw:commentRss>https://joepetruska.com/wordpress/?feed=rss2&#038;p=133</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
	</channel>
</rss>
