<?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>Nigel Pond &#187; linux</title>
	<atom:link href="http://www.nigelpond.com/category/linux/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.nigelpond.com</link>
	<description>Just a personal blog, domain thingy...</description>
	<lastBuildDate>Tue, 06 Oct 2009 14:09:59 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Using gnuplot to plot 3D graphs&#8230;</title>
		<link>http://www.nigelpond.com/2009/10/06/using-gnuplot-to-plot-3d-graphs/</link>
		<comments>http://www.nigelpond.com/2009/10/06/using-gnuplot-to-plot-3d-graphs/#comments</comments>
		<pubDate>Tue, 06 Oct 2009 14:09:59 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[awk]]></category>
		<category><![CDATA[gnuplot]]></category>
		<category><![CDATA[prime]]></category>
		<category><![CDATA[prime numbers]]></category>

		<guid isPermaLink="false">http://www.nigelpond.com/?p=46</guid>
		<description><![CDATA[&#8230;with a little help from awk&#8230;
For instance the following awk took the list of the 1st 1000 prime numbers and added a column for the difference between each of the prime numbers:
&#8220;awk &#8216;{ p = $1; getline; p = $1 &#8211; p; print NR&#8221; &#8220;p&#8221; &#8220;$1 }&#8217; plist.txt &#62; p8.txt&#8221;
Here&#8217;s the gnuplot file:
set dgrid3d 20,20
set [...]]]></description>
			<content:encoded><![CDATA[<p>&#8230;with a little help from awk&#8230;</p>
<p>For instance the following awk took the list of the 1st 1000 prime numbers and added a column for the difference between each of the prime numbers:</p>
<p>&#8220;awk &#8216;{ p = $1; getline; p = $1 &#8211; p; print NR&#8221; &#8220;p&#8221; &#8220;$1 }&#8217; plist.txt &gt; p8.txt&#8221;</p>
<p>Here&#8217;s the gnuplot file:</p>
<p>set dgrid3d 20,20<br />
set hidden3d<br />
set ticslevel 0<br />
set term png<br />
set out &#8220;p17.png&#8221;<br />
splot &#8220;p8.txt&#8221; using 1:2:3 title &#8220;prime&#8221; with lines</p>
<p>And here&#8217;s the graph it created:</p>
<div class="wp-caption aligncenter" style="width: 650px"><img title="1st 1000 prime numbers 3D graph -plotted against the difference between each of the prime numbers." src="http://www.nigelpond.com/images/p17.png" alt="1st 1000 prime numbers 3D graph -plotted against the difference between each of the prime numbers." width="640" height="480" /><p class="wp-caption-text">1st 1000 prime numbers 3D graph -plotted against the difference between each of the prime numbers.</p></div>
<p>Here are some more graphs &#8211; again using the 1st 1000 prime numbers for data but for each one I&#8217;ve created another column of data based upon some manipulation of the primes:</p>
<div class="wp-caption aligncenter" style="width: 650px"><img title="3D plot of 1st 1000 prime numbers" src="http://www.nigelpond.com/images/p12.png" alt="3D plot of 1st 1000 prime numbers" width="640" height="480" /><p class="wp-caption-text">3D plot of 1st 1000 prime numbers</p></div>
<div class="wp-caption aligncenter" style="width: 650px"><img title="3D graph plot of the 1st 1000 prime numbers" src="http://www.nigelpond.com/images/p14.png" alt="3D graph plot of the 1st 1000 prime numbers" width="640" height="480" /><p class="wp-caption-text">3D graph plot of the 1st 1000 prime numbers</p></div>
<div class="wp-caption aligncenter" style="width: 650px"><img title="3D plot of the 1st 1000 prime numbers" src="http://www.nigelpond.com/images/p15.png" alt="3D plot of the 1st 1000 prime numbers" width="640" height="480" /><p class="wp-caption-text">3D plot of the 1st 1000 prime numbers</p></div>
<div class="wp-caption aligncenter" style="width: 650px"><img title="3D gnuplot graph of the 1st 1000 prime numbers" src="http://www.nigelpond.com/images/p16.png" alt="3D gnuplot graph of the 1st 1000 prime numbers" width="640" height="480" /><p class="wp-caption-text">3D gnuplot graph of the 1st 1000 prime numbers</p></div>
]]></content:encoded>
			<wfw:commentRss>http://www.nigelpond.com/2009/10/06/using-gnuplot-to-plot-3d-graphs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Enabling SSL under Red Hat Enterprise Linux</title>
		<link>http://www.nigelpond.com/2009/05/29/enabling-ssl-under-red-hat-enterprise-linux/</link>
		<comments>http://www.nigelpond.com/2009/05/29/enabling-ssl-under-red-hat-enterprise-linux/#comments</comments>
		<pubDate>Fri, 29 May 2009 12:16:51 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.nigelpond.com/?p=42</guid>
		<description><![CDATA[Create the keys &#8211; replace the O, OU &#38; URL with your own data.  These are locally signed keys:
# openssl req -new -x509 -sha1 -newkey rsa:1024 \
&#62; -nodes -keyout test.key -out test.crt \
&#62; -subj &#8216;/O=NP/OU=Support/CN=www.example.com&#8217;
Generating a 1024 bit RSA private key
&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;.++++++
&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;.++++++
writing new private key to &#8216;test.key&#8217;
&#8212;&#8211;
Put the keys in their respective folders:
# ls -lrt
total 912
-rw-r&#8211;r&#8211; [...]]]></description>
			<content:encoded><![CDATA[<p>Create the keys &#8211; replace the O, OU &amp; URL with your own data.  These are locally signed keys:</p>
<p># openssl req -new -x509 -sha1 -newkey rsa:1024 \<br />
&gt; -nodes -keyout test.key -out test.crt \<br />
&gt; -subj &#8216;/O=NP/OU=Support/CN=www.example.com&#8217;<br />
Generating a 1024 bit RSA private key<br />
&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;.++++++<br />
&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;.++++++<br />
writing new private key to &#8216;test.key&#8217;<br />
&#8212;&#8211;</p>
<p>Put the keys in their respective folders:</p>
<p># ls -lrt<br />
total 912<br />
-rw-r&#8211;r&#8211; 1 root root 441017 Dec 16 16:09 ca-bundle.crt<br />
-rw-r&#8211;r&#8211; 1 root root   2240 Dec 16 16:10 Makefile<br />
-rwxr-xr-x 1 root root    610 Dec 16 16:10 make-dummy-cert<br />
-rw-r&#8211;r&#8211; 1 root root 441017 Dec 16 16:10 ca-bundle.crt.rpmnew<br />
-rw&#8212;&#8212;- 1 root root   1468 Apr 24 18:13 localhost.crt<br />
-rw-r&#8211;r&#8211; 1 root root    952 May 27 10:17 test.crt</p>
<p>Updated the /etc/httpd/conf.d/ssl.conf file:</p>
<p>#SSLCertificateFile /etc/pki/tls/certs/localhost.crt<br />
SSLCertificateFile /etc/pki/tls/certs/test.crt</p>
<p>#SSLCertificateKeyFile /etc/pki/tls/private/localhost.key<br />
SSLCertificateKeyFile /etc/pki/tls/private/test.key</p>
<p>Also added Directory instructions for password authentication within the virtual host section (&lt;VirtualHost _default_:443&gt; :</p>
<p>&lt;Directory /&gt;<br />
Options FollowSymLinks<br />
AllowOverride None<br />
AuthType basic<br />
AuthName &#8220;Private&#8221;<br />
AuthUserFile /var/www/folder/passwords<br />
Require valid-user<br />
Order allow,deny<br />
&lt;/Directory&gt;<br />
The files couldn&#8217;t be seen by apache because I&#8217;d created them under root (SELinux enabled) so I had to run these<br />
commands:</p>
<p># restorecon /etc/pki/tls/private/test.key<br />
# restorecon /etc/pki/tls/certs/test.crt</p>
<p>To redirect all requests over SSL I put this in the .htaccess file in the document root (/var/www/html)</p>
<p>RewriteEngine On<br />
RewriteCond %{SERVER_PORT} 80<br />
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]</p>
<p>At first the above didn&#8217;t work because I had AllowOverride None set in the /etc/httpd/conf/httpd.conf file:</p>
<p>#    AllowOverride None<br />
AllowOverride All</p>
<p>Restart apache:</p>
<p>$ service httpd restart</p>
<p>Once changed to All the rewrite works!!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nigelpond.com/2009/05/29/enabling-ssl-under-red-hat-enterprise-linux/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to format a USB stick on Fedora Core 10 Linux</title>
		<link>http://www.nigelpond.com/2009/05/29/how-to-format-a-usb-stick-on-fedora-core-10-linux/</link>
		<comments>http://www.nigelpond.com/2009/05/29/how-to-format-a-usb-stick-on-fedora-core-10-linux/#comments</comments>
		<pubDate>Fri, 29 May 2009 12:06:18 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.nigelpond.com/?p=40</guid>
		<description><![CDATA[Formatting a 16GB (Cruzer micro 16) USB Stick on Fedora 10.
Power up your Fedora machine and login then stick in USB stick.
Fedora 10 mounts USB device automatically.
Find the USB drives system name and mount point:
$ mount
~
/dev/sdb1 on /media/disk type vfat (rw,nosuid,nodev,uhelper=hal,shortname=lower,uid=500)
Unmount USB disk:
$ umount /media/disk
Found that fdisk /dev/sdb1 didn&#8217;t work as a normal user so [...]]]></description>
			<content:encoded><![CDATA[<p>Formatting a 16GB (Cruzer micro 16) USB Stick on Fedora 10.</p>
<p>Power up your Fedora machine and login then stick in USB stick.</p>
<p>Fedora 10 mounts USB device automatically.</p>
<p>Find the USB drives system name and mount point:</p>
<p>$ mount</p>
<p>~<br />
/dev/sdb1 on /media/disk type vfat (rw,nosuid,nodev,uhelper=hal,shortname=lower,uid=500)</p>
<p>Unmount USB disk:</p>
<p>$ umount /media/disk</p>
<p>Found that fdisk /dev/sdb1 didn&#8217;t work as a normal user so su to root:</p>
<p>$ su -<br />
Password:</p>
<p>$ fdisk /dev/sdb1</p>
<p>Options:</p>
<p>p &#8211; to show partition<br />
n &#8211; for new partition<br />
defaults &#8211; take all the defaults until returned to &#8220;Command (m for help):&#8221;<br />
w &#8211; to write the changes</p>
<p>I got some errors here but decided to try the mkfs.ext3 command anyway&#8230;</p>
<p>$ mkfs.ext3 -b 4096 /dev/sdb1</p>
<p>I noticed that fdisk ($ fdisk -l) still showed it as FAT32 but once I removed the stick and stuck it back in again (automatically mounted by Fedora) a right-click on the icon and a show of properties showed that it was ext3.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nigelpond.com/2009/05/29/how-to-format-a-usb-stick-on-fedora-core-10-linux/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
