<?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>errr-online.com &#187; Linux</title>
	<atom:link href="http://www.errr-online.com/index.php/tag/linux/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.errr-online.com</link>
	<description>Be on the lookout for useless Information</description>
	<lastBuildDate>Sun, 30 May 2010 04:48:42 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Guruplug Server Plus &#8212; Booting from eSATA</title>
		<link>http://www.errr-online.com/index.php/2010/05/29/guruplug-server-plus-booting-from-esata/</link>
		<comments>http://www.errr-online.com/index.php/2010/05/29/guruplug-server-plus-booting-from-esata/#comments</comments>
		<pubDate>Sun, 30 May 2010 04:48:42 +0000</pubDate>
		<dc:creator>errr</dc:creator>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[GuruPlug]]></category>

		<guid isPermaLink="false">http://www.errr-online.com/?p=64</guid>
		<description><![CDATA[Ive been doing a lot of testing with the guruplug plus lately. Since this thing is a loaner I dont want to make changes to the default settings if I dont have to. This has led me to do all my testing on USB thumbdrives, and on eSATA connected drives. This is a pretty simple [...]]]></description>
			<content:encoded><![CDATA[<p>Ive been doing a lot of testing with the <a href="http://www.globalscaletechnologies.com/c-4-guruplugs.aspx">guruplug plus</a> lately. Since this thing is a loaner I dont want to make changes to the default settings if I dont have to. This has led me to do all my testing on USB thumbdrives, and on eSATA connected drives. This is a pretty simple thing to setup. Below I will walk you through what you need to do in order to boot from an eSATA connected device.</p>
<p>The first thing you need to is get connected to the guruplug through the jtag connector. Instructions for connecting using the jtag connector can be found <a href="http://code.google.com/p/guruplug/downloads/list">here</a>. Once connected power up the guru plug and allow it to boot up. Log in as the root user. If you have not yet, plug in and power up your eSATA drive. When I plugged mine in I got the following:</p>
<blockquote><p>sheevaplug-debian:~# ata1: exception Emask 0&#215;10 SAct 0&#215;0 SErr 0&#215;4010000 action 0xe frozen<br />
ata1: edma_err_cause=00000010 pp_flags=00000000, dev connect<br />
ata1: SError: { PHYRdyChg DevExch }<br />
ata1: hard resetting link<br />
ata1: link is slow to respond, please be patient (ready=0)<br />
ata1: SATA link up 1.5 Gbps (SStatus 113 SControl F300)<br />
ata1.00: ATA-7: WDC WD2000JS-00MHB0, 02.01C03, max UDMA/133<br />
ata1.00: 390721968 sectors, multi 0: LBA48<br />
ata1.00: configured for UDMA/133<br />
ata1: EH complete<br />
scsi 0:0:0:0: Direct-Access     ATA      WDC WD2000JS-00M 02.0 PQ: 0 ANSI: 5<br />
sd 0:0:0:0: Attached scsi generic sg2 type 0<br />
sd 0:0:0:0: [sdc] 390721968 512-byte logical blocks: (200 GB/186 GiB)<br />
sd 0:0:0:0: [sdc] Write Protect is off<br />
sd 0:0:0:0: [sdc] Write cache: enabled, read cache: enabled, doesn&#8217;t support DPO or FUA<br />
 sdc: sdc1<br />
sd 0:0:0:0: [sdc] Attached SCSI disk
</p></blockquote>
<p>Next I need to create a partition on my disk. Normally I would use fdisk for this task but when I try I get:<br />
<code>sheevaplug-debian:~# fdisk /dev/sdc</code></p>
<blockquote><p>
WARNING: GPT (GUID Partition Table) detected on &#8216;/dev/sdc&#8217;! The util fdisk doesn&#8217;t support GPT. Use GNU Parted.
</p></blockquote>
<p>This means I need to install parted.<br />
<code>apt-get install parted</code><br />
Next I can get a partition set up.<br />
<code>parted /dev/sdc</code><br />
Now I already have 1 partition on this drive. We can see that by typing print<br />
<code>parted /dev/sdc</code></p>
<blockquote><p>
GNU Parted 1.8.8<br />
Using /dev/sdc<br />
Welcome to GNU Parted! Type &#8216;help&#8217; to view a list of commands.
</p></blockquote>
<p><code>(parted) print</code></p>
<blockquote><p>Model: ATA WDC WD2000JS-00M (scsi)<br />
Disk /dev/sdc: 200GB<br />
Sector size (logical/physical): 512B/512B<br />
Partition Table: gpt</p>
<p>Number  Start   End     Size    File system  Name     Flags<br />
 1      17.4kB  10.2GB  10.2GB  ext2         primary  boot
</p></blockquote>
<p>I dont want to mess with this first partition so Im going to make a new one. The first partition was created from 0 to 10240 so I need to go from 10241 to 20481 to make another 10.2G partition.<br />
<code>(parted) mkpart primary ext2 10241 20481</code><br />
<code>(parted) print</code></p>
<blockquote><p>
Model: ATA WDC WD2000JS-00M (scsi)<br />
Disk /dev/sdc: 200GB<br />
Sector size (logical/physical): 512B/512B<br />
Partition Table: gpt</p>
<p>Number  Start   End     Size    File system  Name     Flags<br />
 1      17.4kB  10.2GB  10.2GB  ext2         primary  boot<br />
 2      10.2GB  20.5GB  10.2GB  ext3         primary
</p></blockquote>
<p>Next I want to toggle the boot flag so I type toggle and hit enter<br />
<code>(parted) toggle</code></p>
<blockquote><p>
Partition number? 2<br />
Flag to Invert?  boot/hidden/raid/lvm/hp-service/msftres/bios_grub? boot
</p></blockquote>
<p><code>(parted) print</code></p>
<blockquote><p>
Model: ATA WDC WD2000JS-00M (scsi)<br />
Disk /dev/sdc: 200GB<br />
Sector size (logical/physical): 512B/512B<br />
Partition Table: gpt</p>
<p>Number  Start   End     Size    File system  Name     Flags<br />
 1      17.4kB  10.2GB  10.2GB  ext2         primary  boot<br />
 2      10.2GB  20.5GB  10.2GB  ext3         primary  boot
</p></blockquote>
<p>OK. Now Ill type q to quit, and then make a file system on the new partition.<br />
<code>mke2fs /dev/sdc2</code></p>
<blockquote><p>&#8230; &#8230; &#8230;<br />
This filesystem will be automatically checked every 30 mounts or<br />
180 days, whichever comes first.  Use tune2fs -c or -i to override.
</p></blockquote>
<p>Now to mount this new partition.<br />
<code>mount /dev/sdc2 /media/usb1/</code><br />
Now a couple of cp commands will fill this disk with everything you need. This first cp will take a few minutes go grab a drink or something&#8230;<br />
<code>cp -avp / /media/usb1</code><br />
Now to grab dev too. If you look in /media/usb1/dev you will notice it is empty. This would cause a kernel panic if we tried to boot into it now.<br />
<code>cp -ax /dev/ /media/usb1/</code><br />
Now we are just about ready to reboot and start using our eSATA disk. All we need to do now is to give this new system a different name than the default install so its easy to tell them apart. To do this simply edit a configuration file.<br />
<code>echo "errr-esata" > /media/usb1/etc/hostname</code><br />
Now we are ready to reboot. Type reboot and wait for the Marvell count down to appear and hit any key to stop the autoboot.<br />
Now at the Marvell command prompt type<br />
<code>set x_bootargs_root root=/dev/sdc2 rootdelay=10</code><br />
Be sure to use the correct root= line for your drive. This may be sda1 or sdb1 or even sdc1.<br />
Next type boot and hit enter<br />
If you get a kernel panic like so:</p>
<blockquote><p>VFS: Cannot open root device &#8220;sdc2&#8243; or unknown-block(8,34)<br />
Please append a correct &#8220;root=&#8221; boot option; here are the available partitions:<br />
1f00            1024 mtdblock0 (driver?)<br />
1f01            4096 mtdblock1 (driver?)<br />
1f02          519168 mtdblock2 (driver?)<br />
0800       195360984 sda driver: sd<br />
  0801         9999983 sda1<br />
  0802        10000976 sda2<br />
Kernel panic &#8211; not syncing: VFS: Unable to mount root fs on unknown-block(8,34)<br />
[<c0032a34>] (unwind_backtrace+0&#215;0/0xd4) from [<c0043e04>] (panic+0&#215;48/0&#215;134)<br />
[<c0043e04>] (panic+0&#215;48/0&#215;134) from [<c0008f04>] (mount_block_root+0&#215;1c4/0&#215;20c)<br />
[<c0008f04>] (mount_block_root+0&#215;1c4/0&#215;20c) from [<c00091b8>] (prepare_namespace+0&#215;168/0&#215;1cc)<br />
[<c00091b8>] (prepare_namespace+0&#215;168/0&#215;1cc) from [<c0008750>] (kernel_init+0xd4/0&#215;108)<br />
[<c0008750>] (kernel_init+0xd4/0&#215;108) from [<c002e3d0>] (kernel_thread_exit+0&#215;0/0&#215;8)
</p></blockquote>
<p>This means that you have told Marvell to boot from the wrong partition. In this case its telling me that sdc2 is unknown but it shows me there is an sda1 and sda2 so Im going to try sda2 instead.<br />
Next you will get to this:</p>
<blockquote><p>Bluetooth: vendor=0&#215;2df, device=0&#215;9105, class=255, fn=2<br />
btmrvl_sdio mmc0:0001:2: firmware: requesting sd8688_helper.bin<br />
btmrvl_sdio_download_helper: request_firmware(helper) failed, error code = -2<br />
btmrvl_sdio_download_fw: Failed to download helper!<br />
btmrvl_sdio_probe: Downloading firmware failed!
</p></blockquote>
<p>This same thing happens every time on the default file system too it just blows past it instead of waiting.. You can hit ctrl+c here or just wait and it will go on past.<br />
Once it has finished booting we will see we are on our eSATA drive by looking at its host name:</p>
<blockquote><p>Bluetooth: SCO (Voice Link) ver 0.6<br />
Bluetooth: SCO socket layer initialized<br />
Agent registered</p>
<p>Debian GNU/Linux 5.0 errr-esata ttyS0</p>
<p>errr-esata login:
</p></blockquote>
<p>Now I can log in and do what ever to this system and when I reboot unless I intervene it will boot back up in default mode on the default internal flash drive, since what we have done here doesnt last a reboot. I hope this helps some of you out there.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.errr-online.com/index.php/2010/05/29/guruplug-server-plus-booting-from-esata/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Guru Plug Server Plus &#8212; My First Look</title>
		<link>http://www.errr-online.com/index.php/2010/05/12/guru-plug-server-plus-my-first-look/</link>
		<comments>http://www.errr-online.com/index.php/2010/05/12/guru-plug-server-plus-my-first-look/#comments</comments>
		<pubDate>Thu, 13 May 2010 04:46:42 +0000</pubDate>
		<dc:creator>errr</dc:creator>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[First Look]]></category>
		<category><![CDATA[GuruPlug]]></category>

		<guid isPermaLink="false">http://www.errr-online.com/?p=53</guid>
		<description><![CDATA[So my boss Robert got a Guru Plug Server Plus, and to my great surprise and joy he sent it home with me to play with. Getting connected to it was simple, once it was plugged in it showed up in my wireless access point list on windows.

Once connected to the access point I got [...]]]></description>
			<content:encoded><![CDATA[<p>So my boss <a href="http://twitter.com/robertmccallum">Robert</a> got a <a href="http://www.globalscaletechnologies.com/p-32-guruplug-server-plus.aspx">Guru Plug Server Plus</a>, and to my great surprise and joy he sent it home with me to play with. Getting connected to it was simple, once it was plugged in it showed up in my wireless access point list on windows.<br />
<a href="http://www.flickr.com/photos/mikeandsummer/4602515211/" title="guruplug-wap-win by the_real_errr, on Flickr"><img src="http://farm5.static.flickr.com/4010/4602515211_d499a07633_o.png" width="339" height="168" alt="guruplug-wap-win" /></a><br />
Once connected to the access point I got my network info and tried to ssh to the gateway. I was able to log in as root with a <a href="http://en.wikipedia.org/wiki/The_Soup_Nazi">clever</a> default root password. I was greeted with a familiar sight. <a href="http://www.flickr.com/photos/mikeandsummer/4603130006/" title="guruplug-first-boot by the_real_errr, on Flickr"><img src="http://farm2.static.flickr.com/1185/4603130006_5f36210e29.jpg" width="500" height="281" alt="guruplug-first-boot" /></a><br />
Debian GNU/Linux 5.0 I connected the device to the internet and tried to apt-get update but found that didnt work. In the /etc/apt/sources.list file there was an entry for a private internal mirror. I had to comment that out and ran dpkg &#8211;configure -a since the system suggested it. Once I did that apt-get update worked and so I did an apt-get upgrade Upgraded everything that needed it. Next I installed less, and ntp. I went through the list of pre installed packages, it was pretty long. Some of the packages that stood out were <a href="http://redmine.lighttpd.net/projects/lighttpd/wiki/">Lighttpd</a>, PERL, PHP5, Python 2.5, MySQL server and client, exim4, udhcpd, and samba 3.2.5. So for dirt you get a pretty powerful cheap ready to rock LAMP stack and File server and Wireless AP. Not so shabby. This puppy supports booting using all kinds of methods. If you are connected to it though the JTAG you will have the option to keep the system from booting. You will be given a prompt:<br />
<code>Hit any key to stop autoboot:  0<br />
Marvell>> help<br />
</code><br />
This will return a nice long list of options. You can choose between USB, TFTP, NFS, and many others. Im looking forward to the next couple of days of playing. I want to try out quagga and maybe asterisk. Check back soon for an update of what I do.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.errr-online.com/index.php/2010/05/12/guru-plug-server-plus-my-first-look/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Red Hat Enterprise Linux 6 Beta &#8211; My First look</title>
		<link>http://www.errr-online.com/index.php/2010/04/28/red-hat-enterprise-linux-6-beta-my-first-look/</link>
		<comments>http://www.errr-online.com/index.php/2010/04/28/red-hat-enterprise-linux-6-beta-my-first-look/#comments</comments>
		<pubDate>Thu, 29 Apr 2010 04:58:07 +0000</pubDate>
		<dc:creator>errr</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Beta]]></category>
		<category><![CDATA[Desktop]]></category>
		<category><![CDATA[Red Hat]]></category>

		<guid isPermaLink="false">http://www.errr-online.com/?p=50</guid>
		<description><![CDATA[
I spent a few hours tonight playing around with Red Hat Enterprise Linux 6 Beta release tonight. So far it seems really nice. I had no issues getting flash-plugin installed from Adobe. I installed irssi and setup my network to use a static IP. All tasks were very familiar feeling from past releases. I mostly [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.flickr.com/photos/mikeandsummer/4561811159/" title="desktop-3-sysmon-sysinfo by the_real_errr, on Flickr"><img src="http://farm4.static.flickr.com/3386/4561811159_a0631cb4cd.jpg" width="500" height="281" alt="desktop-3-sysmon-sysinfo" /></a></p>
<p>I spent a few hours tonight playing around with Red Hat Enterprise Linux 6 Beta release tonight. So far it seems really nice. I had no issues getting flash-plugin installed from Adobe. I installed irssi and setup my network to use a static IP. All tasks were very familiar feeling from past releases. I mostly messed around with desktop stuff tonight. Tomorrow I hope to get to setup Apache PHP and MySQL, and maybe a few days later I will step through a mail server as well with Postfix.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.errr-online.com/index.php/2010/04/28/red-hat-enterprise-linux-6-beta-my-first-look/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Rename Files Fast from the Linux CLI</title>
		<link>http://www.errr-online.com/index.php/2010/01/14/rename-files-fast-from-the-linux-cli/</link>
		<comments>http://www.errr-online.com/index.php/2010/01/14/rename-files-fast-from-the-linux-cli/#comments</comments>
		<pubDate>Thu, 14 Jan 2010 18:16:26 +0000</pubDate>
		<dc:creator>errr</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[sysadmin]]></category>

		<guid isPermaLink="false">http://www.errr-online.com/?p=17</guid>
		<description><![CDATA[So today I moved our web root from this OLD system to our new server. First things first I tried to hit some of the links and I was served given the option to d/l the file&#8230; Well I could go to the Web server config file and tell it to parse these files as [...]]]></description>
			<content:encoded><![CDATA[<p>So today I moved our web root from this OLD system to our new server. First things first I tried to hit some of the links and I was served given the option to d/l the file&#8230; Well I could go to the Web server config file and tell it to parse these files as php, or how about we ditch the .php3 for something this decade&#8230; like .php So I go to our web root and look for all the files that end in .php3</p>
<blockquote><p>find . -iname &#8220;*.php3&#8243; -print</p></blockquote>
<p>Nice. Now I have a huge list of files here.. How on earth can I rename them with out this taking all day&#8230; I used <i>rename</i> like so:</p>
<blockquote><p>find . -iname &#8220;*.php3&#8243; -print |xargs rename -n &#8217;s/\.php3/\.php/&#8217;</p></blockquote>
<p>This command will NOT actually change ANYTHING on your system. The -n flag says to run through as a test and tell me what you would be doing if I wanted it done&#8230; I can see from this output that I do indeed want to run this command.</p>
<blockquote><p>find . -iname &#8220;*.php3&#8243; -print |xargs rename -v &#8217;s/\.php3/\.php/&#8217;</p></blockquote>
<p>Now this time it did go though and rename and it printed to the screen what it did (thats what the -v flag does verbose). Now I can go though and edit the index file that pointed to these php3 files and remove that 3. Simple and now I dont have that silly 3 on the file names any more.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.errr-online.com/index.php/2010/01/14/rename-files-fast-from-the-linux-cli/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Export xBase/dBase files into MySQL</title>
		<link>http://www.errr-online.com/index.php/2010/01/04/export-xbasedbase-files-into-mysql/</link>
		<comments>http://www.errr-online.com/index.php/2010/01/04/export-xbasedbase-files-into-mysql/#comments</comments>
		<pubDate>Mon, 04 Jan 2010 18:18:36 +0000</pubDate>
		<dc:creator>errr</dc:creator>
				<category><![CDATA[Database]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Conversion]]></category>
		<category><![CDATA[dBase]]></category>
		<category><![CDATA[Export]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[sysadmin]]></category>
		<category><![CDATA[xBase]]></category>

		<guid isPermaLink="false">http://www.errr-online.com/?p=6</guid>
		<description><![CDATA[If you have an application that uses xBase/dBase files to store data you may at some point need to export that data into a real database, like MySQL. This is a really simple task thanks to a nifty app called dbf2mysql. For my example I was using some CRM software called ACT. They used dBase [...]]]></description>
			<content:encoded><![CDATA[<p>If you have an application that uses <a href="http://en.wikipedia.org/wiki/DBase">xBase/dBase</a> files to store data you may at some point need to export that data into a real database, like <a href="http://www.mysql.com/">MySQL</a>. This is a really simple task thanks to a nifty app called <a href="http://sourceforge.net/projects/dbf2mysql/">dbf2mysql</a>. For my example I was using some CRM software called ACT. They used dBase III files to store their data. So I just went to the windows box that was holding my dBase file. I used winscp to move it to my Linux box. Next I used:<br />
<blockquote>dbf2mysql -vvv -c -f -d dbname -r -U dbuser -P dbuserpass CustomerInfo.dbf</p></blockquote>
<p>What this does is turns up the verbose logging to my screen, next the -c will create a table in my database named &#8220;test&#8221; (this is default and can be changed with the -t flag) -f makes all the field named from the dbf file be changed to lower case, next the -d, -U, and -P seem pretty obvious, and that leaves us with the -r which will Trim trailing and leading white space from CHAR type fields. All this info and more can be found in the man page. Here is the trail end of what I got from the output of my command:<br />
<blockquote>fields in dbh 71, allocated mem for query 4293, query size 2156<br />
Inserting records<br />
Inserting record 0<br />
Inserting record 100<br />
Inserting record 200<br />
Inserting record 300<br />
Inserting record 400<br />
Inserting record 500<br />
Inserting record 600<br />
Inserting record 700<br />
Inserting record 800<br />
Closing up&#8230;.
</p></blockquote>
<p>Now I can log into phpmyadmin and verify that all my data has been moved successfully.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.errr-online.com/index.php/2010/01/04/export-xbasedbase-files-into-mysql/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
