<?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>Rayed&#039;s Real Life</title>
	<atom:link href="http://rayed.com/wordpress/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://rayed.com/wordpress</link>
	<description>Open Source, Linux, Apache, PHP, Python, MySQL, and very little of my life ;)</description>
	<lastBuildDate>Thu, 10 May 2012 23:12:08 +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>Blast from the past: Small Piece of Saudi Arabia Internet History</title>
		<link>http://rayed.com/wordpress/?p=1001</link>
		<comments>http://rayed.com/wordpress/?p=1001#comments</comments>
		<pubDate>Thu, 10 May 2012 16:27:41 +0000</pubDate>
		<dc:creator>Rayed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[history]]></category>
		<category><![CDATA[isu]]></category>
		<category><![CDATA[kacst]]></category>
		<category><![CDATA[ksu]]></category>
		<category><![CDATA[saudi]]></category>

		<guid isPermaLink="false">http://rayed.com/wordpress/?p=1001</guid>
		<description><![CDATA[Last week my friend Osama Aldosary was cleaning his emails and found this 13 years old email from me back when I was working as a system admin at ISU KACST, and I was administrating the email servers that accept &#8230; <a href="http://rayed.com/wordpress/?p=1001">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Last week my friend Osama Aldosary was cleaning his emails and found this <strong>13 years old</strong> email from me back when I was working as a system admin at <a href="http://www.kacst.edu.sa/ar/depts/isu/Pages/Home.aspx">ISU KACST</a>, and I was administrating the email servers that accept and forward all internet emails for Saudi universities, Osama was working for KSU back then.</p>
<p>Thank you Osama</p>
<p><code><br />
Subject:	New Link Migration Plan<br />
Date:	Wed, 10 Feb 1999 15:34:40 +0307<br />
From:	Rayed Al-Rashed < *****@kacst.edu.sa><br />
Organization:	KACST<br />
To:	*****@kaau.edu.sa, *****@kfupm.edu.sa, *****@ksu.edu.sa, *****@ksu.edu.sa, *****@uqu.edu.sa</p>
<p>Salam Brothers,</p>
<p>As you all know KACST was connected through King Faisal Specializes<br />
Hospital, and since KACST is now connected through ISU, we have to<br />
replace our old IP addresses with the new ones from ISU.</p>
<p>Of course this will affect the leased-line link and E-Mail traffic with<br />
all of you, and we tried to delay the migration as much as we can to<br />
give you enough time to set up your own services through ISU link.</p>
<p>Our dead line to return the old IPs will end in less than a month, then<br />
we have to return them to RIPE, we are going to start our plan to<br />
migrate to the new IPs, and we have to stop the leased-line link and our<br />
old mail relay that serve your domains when we return the old IPs.</p>
<p>I am sure that most of you are ready by now, but if you are facing any<br />
problems we will be happy to help you with it.</p>
<p>NOTE:<br />
Please send me the current state of your migration plan, and the<br />
estimated time to finish.</p>
<p>-----------------------------------------------<br />
Rayed Al-Rashed<br />
Internet Services Unit<br />
King abdullaziz City for Science and Technology<br />
-----------------------------------------------<br />
</code></p>
]]></content:encoded>
			<wfw:commentRss>http://rayed.com/wordpress/?feed=rss2&#038;p=1001</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Django backend benchmark</title>
		<link>http://rayed.com/wordpress/?p=952</link>
		<comments>http://rayed.com/wordpress/?p=952#comments</comments>
		<pubDate>Thu, 10 May 2012 16:10:42 +0000</pubDate>
		<dc:creator>Rayed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[benchmark]]></category>
		<category><![CDATA[db]]></category>
		<category><![CDATA[django]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[postgres]]></category>

		<guid isPermaLink="false">http://rayed.com/wordpress/?p=952</guid>
		<description><![CDATA[I create small Django app and tried to access with different backends, here a the result: Backend Req/Sec PostgreSQL 68.41 PostgreSQL+pgpool 116.12 MySQL 127.61 The test performed using &#8220;ab&#8221; tool, 1000 requests with 5 concurrent clients: $ ab -c 5 &#8230; <a href="http://rayed.com/wordpress/?p=952">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I create small Django app and tried to access with different backends, here a the result:</p>
<table>
<tr>
<th>Backend</th>
<th>Req/Sec</th>
</tr>
<tr>
<td>PostgreSQL</td>
<td>68.41</td>
</tr>
<tr>
<td>PostgreSQL+pgpool</td>
<td>116.12</td>
</tr>
<tr>
<td>MySQL</td>
<td>127.61</td>
</tr>
</table>
<p>The test performed using &#8220;ab&#8221; tool, 1000 requests with 5 concurrent clients:<br />
<code>$ ab -c 5 -n 1000 http://localhost/test</code></p>
]]></content:encoded>
			<wfw:commentRss>http://rayed.com/wordpress/?feed=rss2&#038;p=952</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PostgreSQL on Ubuntu from scratch</title>
		<link>http://rayed.com/wordpress/?p=967</link>
		<comments>http://rayed.com/wordpress/?p=967#comments</comments>
		<pubDate>Thu, 10 May 2012 00:03:36 +0000</pubDate>
		<dc:creator>Rayed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rayed.com/wordpress/?p=967</guid>
		<description><![CDATA[My notes on installing and configuring PostgreSQL on Ubuntu Linux. PostgreSQL is used by many large web sites and services, including Skype, Reddit, Instagram, &#8220;.org&#8221; registerer, check longer list here Prominent Users Best of all it isn&#8217;t owned by anyone, &#8230; <a href="http://rayed.com/wordpress/?p=967">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img alt="" src="http://upload.wikimedia.org/wikipedia/commons/thumb/2/29/Postgresql_elephant.svg/200px-Postgresql_elephant.svg.png" title="PostgreSQL" class="alignright" width="200" height="206" /></p>
<p>My notes on installing and configuring <a href="http://www.postgresql.org/">PostgreSQL</a> on Ubuntu Linux.</p>
<p>PostgreSQL is used by many large web sites and services, including Skype, Reddit, Instagram, &#8220;.org&#8221; registerer, check longer list here <a href="http://en.wikipedia.org/wiki/PostgreSQL#Prominent_users">Prominent Users</a></p>
<p>Best of all it isn&#8217;t owned by anyone, not Oracle nor anyone else!</p>
<p><span id="more-967"></span></p>
<ul>
<li>
Installing PostgreSQL:<br />
<code>$ sudo aptitude install postgresql</code>
</li>
<li>
If you want to allow access from outside, first you need to listen to all IP instead of &#8220;localhost&#8221; only:<br />
<code>$ sudo vi /etc/postgresql/8.4/main/postgresql.conf<br />
:<br />
listen_addresses = '*'<br />
:</code><br />
and allow connecting:<br />
<code>$ sudo vi /etc/postgresql/8.4/main/postgresql.conf<br />
:<br />
host    all         all         10.0.0.0/24          md5<br />
:</code>
</li>
<li>You can start, stop, restart using the commands:<br />
<code>$ sudo /etc/init.d/postgresql-8.4 stop</code>
</li>
<li>To connect as Postgres superuser, type:<br />
<code>$ sudo -u postgres psql<br />
psql (8.4.11)<br />
Type "help" for help.<br />
postgres=#</code><br />
Notice the &#8220;#&#8221; which means superuser, superuser can do anything!</li>
<li>From &#8220;psql&#8221; create a new database using:<br />
<code>postgres=# CREATE DATABASE rayed;<br />
CREATE DATABASE<br />
postgres=# \c rayed<br />
psql (8.4.11)<br />
You are now connected to database "rayed".<br />
rayed=# </code><br />
&#8220;\c&#8221; is used to switch database, notice the prompt changed to &#8220;rayed&#8221; the name of the database.</li>
<li>Let&#8217;s create a new table:<br />
<code>rayed=# CREATE TABLE users (<br />
"user_id" SERIAL,<br />
"email" TEXT,<br />
"firstname" TEXT,<br />
"lastname" TEXT,<br />
"password" TEXT,<br />
PRIMARY KEY ("user_id")<br />
);</code><br />
&#8220;SERIAL&#8221; is a short cut, it will create a database &#8220;sequence&#8221;, read about it is important, and if you are lazy it is an AUTO_INCREMENT field in MySQL. Let&#8217;s see what we have created so far:<br />
<code>rayed=# \d<br />
                List of relations<br />
 Schema |       Name        |   Type   |  Owner<br />
--------+-------------------+----------+----------<br />
 public | users             | table    | postgres<br />
 public | users_user_id_seq | sequence | postgres<br />
(2 rows)</code><br />
Notice the auto created sequence, cool huh!<br />
Try also: &#8220;\d+&#8221;, &#8220;\d users&#8221;, &#8220;\d+ users&#8221;.</li>
<li>To see a list of databse on the system try &#8220;\l&#8221;:<br />
<code>rayed=# \l<br />
                                 List of databases<br />
   Name    |  Owner   | Encoding | Collation  |   Ctype    |   Access privileges<br />
-----------+----------+----------+------------+------------+-----------------------<br />
 postgres  | postgres | UTF8     | en_US.utf8 | en_US.utf8 |<br />
 rayed     | postgres | UTF8     | en_US.utf8 | en_US.utf8 |<br />
 template0 | postgres | UTF8     | en_US.utf8 | en_US.utf8 | =c/postgres<br />
                                                           : postgres=CTc/postgres<br />
 template1 | postgres | UTF8     | en_US.utf8 | en_US.utf8 | =c/postgres<br />
                                                           : postgres=CTc/postgres<br />
(4 rows)</code><br />
You will notice we have 4 databases:</p>
<ul>
<li>postgres: This is where the schema for everything is stored, I think! NEED CHECKING</li>
<li>rayed: the new database we created.</li>
<li>template1: This an empty template database, whenever you create a new database it will be created from this one, you can even change this database to include any custom objects to be copied to new databases.</li>
<li>template0: Another template DB, this one shouldn&#8217;t be touched, it will be used to create new DB for restoring backups.</li>
</ul>
</li>
<li>We will create user named &#8220;rayed&#8221;, and allow it to login:<br />
<code>rayed=# CREATE ROLE rayed LOGIN;<br />
rayed=# \du<br />
            List of roles<br />
 Role name | Attributes  | Member of<br />
-----------+-------------+-----------<br />
 postgres  | Superuser   | {}<br />
           : Create role<br />
           : Create DB<br />
 rayed     |             | {}</code><br />
Now I can login to &#8220;psql&#8221; directly from my account.
</li>
<li>User with a password:<br />
<code>rayed=# ALTER ROLE rayed WITH PASSWORD 'my_pass_word';</code><br />
Now if you try to login from bash:<br />
<code>$ psql </code><br />
Didn&#8217;t ask for a password!!! This because we set &#8220;pg_hba.conf&#8221; to use &#8220;ident&#8221; service and not passwords for local connections, to fix this we add:<br />
<code>$ sudo vi /etc/postgresql/8.4/main/pg_hba.conf<br />
:<br />
local   all         postgres                          ident<br />
local   all         all                               md5<br />
:<br />
$ sudo /etc/init.d/postgresql-8.4 restart<br />
$ psql<br />
Password for user rayed:</code><br />
The changes we made to &#8220;pg_hba.conf&#8221; as follow, &#8220;postgres&#8221; is authenticated using &#8220;ident&#8221; service, other users should use &#8220;md5&#8243; password, order of the lines are important!
</li>
<li>Let&#8217;s try to insert data to our &#8220;users&#8221; table:<br />
<code>rayed=> INSERT INTO users (email) VALUES('rayed@rayed.com');<br />
ERROR:  permission denied for relation users</code><br />
Permission is denied because we created the database &#8220;rayed&#8221; and the table &#8220;users&#8221; from &#8220;postgres&#8221; account, and by default the creator will be the owner, we need to change the owner, from superuser (i.e. postgres) type:<br />
<code>rayed=# ALTER TABLE users OWNER TO rayed;<br />
ALTER TABLE<br />
rayed=# ALTER SEQUENCE users_user_id_seq OWNER TO rayed;<br />
ALTER SEQUENCE</code><br />
Try inserting again, voila!
</li>
<li>Connecting from PHP now, try the example from <a href="http://www.php.net/manual/en/pgsql.examples-basic.php">http://www.php.net/manual/en/pgsql.examples-basic.php</a>, make sure you install PHP PostgreSQL module:<br />
<code> $ sudo aptitude install php5-pgsql</code><br />
Make sure you change the database name, username, and password.
</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://rayed.com/wordpress/?feed=rss2&#038;p=967</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>مقابلتي في اطياف</title>
		<link>http://rayed.com/wordpress/?p=927</link>
		<comments>http://rayed.com/wordpress/?p=927#comments</comments>
		<pubDate>Sun, 06 May 2012 11:53:20 +0000</pubDate>
		<dc:creator>Rayed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rayed.com/wordpress/?p=927</guid>
		<description><![CDATA[مقابلتي في اطياف اكرة صوتي المسجل، بعض الاحيان انسى انه انا جريدة الرياض جريدة الاقتصادية WireFilter حسابي في تويتر حسابي في فليكر روابط ذات علاقة انضم لفريقنا We Are Hiring Atarti 800 XL MSX جامعة جورج واشنطن George Washington University &#8230; <a href="http://rayed.com/wordpress/?p=927">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.atyaf.net/2012/05/%D8%A7%D9%84%D8%AD%D9%84%D9%82%D8%A9-32-%D9%85%D8%B9-%D8%B1%D8%A7%D8%A6%D8%AF-%D8%A7%D9%84%D8%B1%D8%A7%D8%B4%D8%AF/">مقابلتي في اطياف</a><br />
اكرة صوتي المسجل، بعض الاحيان انسى انه انا <img src='http://rayed.com/wordpress/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<ul>
<li><a href="http://www.alriyadh.com/">جريدة الرياض</a></li>
<li><a href="http://www.aleqt.com/">جريدة الاقتصادية</a></li>
<li><a href="http://www.wirefilter.com/">WireFilter</a></li>
<li><a href="https://twitter.com/#!/rayed">حسابي في تويتر</a></li>
<li><a href="http://www.flickr.com/photos/rayed/">حسابي في فليكر</a></li>
</ul>
<h2>روابط ذات علاقة</h2>
<p><a href="http://quiz.wirefilter.com/" style="font-size:180%;">انضم لفريقنا  We Are Hiring</a><br />
<a href="http://www.wirefilter.com/"><img src="http://www.wirefilter.com/templates/wirefilter/css/img/logo.png" /><img src="http://www.wirefilter.com/images/stories/final%20product_no%20bkg.jpg"/></a></p>
<p><a href="http://en.wikipedia.org/wiki/Atari_8-bit_family#Newer_XL_machines"><br />
<img src="http://upload.wikimedia.org/wikipedia/commons/thumb/b/bf/Atari-800XL.jpg/250px-Atari-800XL.jpg" /><br />
Atarti 800 XL</a></p>
<p><a href="http://en.wikipedia.org/wiki/MSX"><br />
<img src="http://upload.wikimedia.org/wikipedia/commons/0/02/YAMAYAMA.JPG" /><br />
MSX</a></p>
<p><a href="http://rayed.com/wordpress/wp-content/uploads/2012/05/learning_pyramid.jpg"><img src="http://rayed.com/wordpress/wp-content/uploads/2012/05/learning_pyramid-300x222.jpg" alt="" title="Learning Pyramid" width="300" height="222" class="alignnone size-medium wp-image-954" /></a></p>
<p><a href="http://www.gwu.edu/"><br />
<img src="http://upload.wikimedia.org/wikipedia/en/thumb/6/6c/GWUlogo.jpeg/162px-GWUlogo.jpeg" /><br />
جامعة جورج واشنطن George Washington University</a><br />
<a href="http://en.wikipedia.org/wiki/George_Washington_University">http://en.wikipedia.org/wiki/George_Washington_University</a></p>
]]></content:encoded>
			<wfw:commentRss>http://rayed.com/wordpress/?feed=rss2&#038;p=927</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Deploying Django</title>
		<link>http://rayed.com/wordpress/?p=920</link>
		<comments>http://rayed.com/wordpress/?p=920#comments</comments>
		<pubDate>Sat, 28 Apr 2012 00:07:30 +0000</pubDate>
		<dc:creator>Rayed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[django]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://rayed.com/wordpress/?p=920</guid>
		<description><![CDATA[Django is a web framework written in Python language, my favorite computer programming language. Python a language is really great language, easy to read and understand, and very easy to learn, but for me I always found setting up Python &#8230; <a href="http://rayed.com/wordpress/?p=920">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href="https://www.djangoproject.com/">Django</a> is a web framework written in <a href="http://www.python.org/">Python</a> language, my favorite computer programming language.</p>
<p>Python a language is really great language, easy to read and understand, and very easy to learn, but for me I always found setting up Python for web development as a challenge, socially if compare it to PHP, which almost works out of the box, actually most people think PHP works only in the web server and can&#8217;t work as stand alone application, search for PHP CLI if you are interested.</p>
<p>I will try here to document an easy Django deployment for my future reference and hopefully it will help others:</p>
<p><span id="more-920"></span></p>
<h2>Step 1: Install virtualenv</h2>
<p><strong>virtualenv</strong> is a tool to create isolated Python environments, by default if you install a new Python package it will be install under <code>/usr/lib/python2.6/site-packages</code>, but what happen if you don&#8217;t have root access in a shared environment for example, or what if you want to install 2 versions of the same package, may be try a newer version.</p>
<p>For these cases you need <strong>virtualenv</strong>, it will allow you to create your own unique  Python environment (or many if you want) where you have your own packages, binaries, and scripts. You can even have multiple environments, wach one with its own packages and versions.</p>
<p>So let&#8217;s install it (this step need root access, ask your admin to install it for you if you don&#8217;t have root):<br />
<code><br />
$ sudo pip install virtualenv<br />
# or ...<br />
$ sudo aptitude install python-virtualenv<br />
</code></p>
<p>Next we will create a new virtual environment &#8220;myenv&#8221;:<br />
<code><br />
$ virtualenv myenv<br />
</code></p>
<p>To activate it type:<br />
<code><br />
$ source myenv/bin/activate<br />
(myenv)$<br />
</code></p>
<p>You will notice that the prompt changed now to include &#8220;(myenv)&#8221;, this mean you are now inside the virtual enviroument, any thing you install from now on will be install inside it (it is just a directory called &#8220;myenv&#8221; feel free to explore it), to leave the environment use the command &#8220;deactivate&#8221;.</p>
<h2>Step 2: Installing Django</h2>
<p>Make sure you the &#8220;myvirt&#8221; is active (from the prompt) and install Django using the following command:<br />
<code><br />
(myenv)$ pip install Django<br />
</code></p>
<p>That is it, we&#8217;ve installed Django &#8230; Thank you for your attention <img src='http://rayed.com/wordpress/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Next we will setup a new Django website, I will use the following directory structure:<br />
<code><br />
$ /home/rayed                 # my home directory<br />
$ /home/rayed/site1          # my website files and directories<br />
$ /home/rayed/site1/myenv    # virtual environment created from previous step<br />
$ /home/rayed/site1/mysite   # Django created project<br />
$ /home/rayed/site1/www      # Static files, images, css, js, etc ...<br />
</code></p>
<p>So here are the commands for easy reference:<br />
<code><br />
$ cd ~<br />
$ mkdir -p site1/www<br />
$ cd site1<br />
site1$ virtualenv myenv<br />
site1$ source myenv/bin/activate<br />
(myenv)site1$ pip install Django<br />
(myenv)site1$ django-admin.py startproject mysite<br />
(myenv)site1$ cd mysite<br />
(myenv)site1/mysite$ python manage.py runserver 0.0.0.0:8000<br />
:<br />
this will start dev server CTRL+C to stop<br />
you can access it <a href="http://localhost:8000/">http://localhost:8000/</a><br />
:<br />
(myenv)site1/mysite$ vi mysite/settings.py     # this will setup the database<br />
(myenv)site1/mysite$ python manage.py syncdb   # this will install basic DB tables<br />
</code></p>
<h2>Step 3: GUnicorn</h2>
<p>For production website you will not use Django development web server, we will use <a href="http://gunicorn.org/">gunicorn</a>, a Python WSGI HTTP Server, it will responsible for running all Django code.</p>
<p><code><br />
# while inside "myenv" install guincorn<br />
(myenv)$ pip install gunicorn<br />
# and run Django<br />
(myenv)$ cd ~/site1/mysite<br />
(myenv) site1/mysite$ gunicorn_django -b 0.0.0.0:8000<br />
</code><br />
Try it out <a href="http://localhost:8000/">http://localhost:8000/</a></p>
<h2>Step 4: Install supervisor (optional)</h2>
<p>We will use <a href="http://supervisord.org/">supervisor </a> to keep an eye on &#8220;gunicorn&#8221;, and restart it automatically if it fails, it will also start it automatically when you restart the machine.</p>
<p><code><br />
$ sudo aptitude install supervisor<br />
$ cat > /etc/supervisor/conf.d/gunicorn.conf<br />
[program:gunicorn]<br />
command=/home/rayed/site1/myenv/bin/gunicorn_django<br />
directory=/home/rayed/site1/mysite/<br />
user=nobody<br />
autostart=true<br />
autorestart=true<br />
redirect_stderr=True<br />
[EOF]<br />
$ sudo supervisorctl update<br />
$ sudo supervisorctl restart gunicorn<br />
</code><br />
Note: by default gunicorn will listen to 127.0.0.1:8000, you can change using the argument &#8220;-b 0.0.0.0:8000&#8243;</p>
<h2>Step 5: Integrating gunicorn with Apache</h2>
<p>gunicorn is a web server, so why do we need Apache? you ask, two reasons:<br />
1- It can&#8217;t handle slow clients (browsers).<br />
2- It can&#8217;t handle static files (images, css, js).</p>
<p>The basic idea is to serve static files directly from (img|css|js|media) and proxy everything else to &#8220;gunicorn&#8221;, here is how:<br />
<code><br />
$ sudo a2enmod proxy_http   # enable Apache HTTP proxy module (Ubuntu &#038; Debian)<br />
$ sudo apache2ctl restart<br />
$ cd ~site1/www<br />
site1/www$ cat > .htaccess<br />
RewriteEngine on<br />
RewriteCond $1 !^(img|css|js|robots\.txt|media)<br />
RewriteRule ^(.*) http://localhost:8000/$1 [P]<br />
[EOF]<br />
</code></p>
<p><strong>Make sure only &#8220;www&#8221; directory is accessible from the web, and not &#8220;mysite&#8221;! your Django code and setting, including the DB username and password will be exposed.</strong></p>
<p>A sample Apache virtual host configuration:<br />
<code><br />
&lt;virtualhost *:80&gt;<br />
        ServerName site1.rayed.com<br />
        DocumentRoot /home/rayed/site1/www<br />
&lt;/virtualhost&gt;<br />
</code></p>
<p>You can also replace Apache with <a href="http://wiki.nginx.org/Main">Nginx</a> which is usually faster with static files.</p>
]]></content:encoded>
			<wfw:commentRss>http://rayed.com/wordpress/?feed=rss2&#038;p=920</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>MENOG 10 In Dubai</title>
		<link>http://rayed.com/wordpress/?p=913</link>
		<comments>http://rayed.com/wordpress/?p=913#comments</comments>
		<pubDate>Thu, 19 Apr 2012 14:32:48 +0000</pubDate>
		<dc:creator>Rayed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rayed.com/wordpress/?p=913</guid>
		<description><![CDATA[If you are working in Internet network operations you don&#8217;t want to miss this event, MENOG -Middle East Network Operator Group- is a conference where network operator from all over the globe and the region of course come to talk &#8230; <a href="http://rayed.com/wordpress/?p=913">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>If you are working in Internet network operations you don&#8217;t want to miss this event, MENOG -Middle East Network Operator Group- is a conference where network operator from all over the globe and the region of course come to talk about network operation issues, trends, etc&#8230;<br />
<a href="http://www.menog.net/meetings/menog10/agenda">MENOG 10 Agenda</a></p>
<p>MENOG is also a great opportunity to get quality education, this time they have 2 workshops one about &#8220;DNS Operations &#038; DNSSEC Deployment&#8221;, and another one about &#8220;IPv6 for ISPs&#8221;, the workshop is 5 days training.<br />
<a href="http://www.menog.net/meetings/menog10/workshops">MENOG 10 Workshops</a></p>
]]></content:encoded>
			<wfw:commentRss>http://rayed.com/wordpress/?feed=rss2&#038;p=913</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Big Book of Monsters</title>
		<link>http://rayed.com/wordpress/?p=904</link>
		<comments>http://rayed.com/wordpress/?p=904#comments</comments>
		<pubDate>Mon, 26 Mar 2012 20:54:50 +0000</pubDate>
		<dc:creator>Rayed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rayed.com/wordpress/?p=904</guid>
		<description><![CDATA[Few months ago while waiting for our flight in the airport I took out my notebook (paper one) and I start drawing with my son Dody, we started drawing different monsters trying to be funny and creative, and we decided &#8230; <a href="http://rayed.com/wordpress/?p=904">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Few months ago while waiting for our flight in the airport I took out my notebook (paper one) and I start drawing with my son Dody, we started drawing different monsters trying to be funny and creative, and we decided to write a book with the name &#8220;The Big Book of Monsters&#8221; where we fill it with drawings of monsters with names and describing their powers.</p>
<p><img src="http://farm7.staticflickr.com/6213/6872681606_0b777acdb4_n_d.jpg"  alt="AngryHorn" title="AngryHorn" /></p>
<p>So here some sample pages:<br />
<a href="http://www.flickr.com/photos/rayed/sets/72157629310316540/">The Big Book of Monsters</a></p>
<p>Hope you enjoy it!</p>
<p>If you have an idea for a monster and you want me to draw please leave a comment, or if you have other ideas for father and son activity/book let me know <img src='http://rayed.com/wordpress/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://rayed.com/wordpress/?feed=rss2&#038;p=904</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Where do Saudi Arabia&#8217;s Top 1000 Websites hosted?</title>
		<link>http://rayed.com/wordpress/?p=905</link>
		<comments>http://rayed.com/wordpress/?p=905#comments</comments>
		<pubDate>Tue, 13 Mar 2012 07:25:48 +0000</pubDate>
		<dc:creator>Rayed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rayed.com/wordpress/?p=905</guid>
		<description><![CDATA[Small report I worked on to find out the hosting location of Saudi Arabia&#8217;s top accessed websites, the aim of this report is to raise the awareness of the lack of Internet hosting in Saudi Arabia, and the slow adoption &#8230; <a href="http://rayed.com/wordpress/?p=905">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Small report I worked on to find out the hosting location of Saudi Arabia&#8217;s top accessed websites, the aim of this report is to raise the awareness of the lack of Internet hosting in Saudi Arabia, and the slow adoption of Saudi TLD &#8220;.sa&#8221;.</p>
<p><a href="http://rayed.com/wordpress/wp-content/uploads/2012/03/hosting.png"><img src="http://rayed.com/wordpress/wp-content/uploads/2012/03/hosting.png" alt="" title="hosting" width="466" height="288" class="alignnone size-full wp-image-907" /></a></p>
<p><strong>Short summary only 8.9% of sites are hosted locally, and only 4.9% have &#8220;.sa&#8221; domain.</strong></p>
<p><a href="http://dev.rayed.com/ix_report/">The Report</a></p>
<p>Please have a look and tell me how can I improve it.</p>
]]></content:encoded>
			<wfw:commentRss>http://rayed.com/wordpress/?feed=rss2&#038;p=905</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My new Arduino kit</title>
		<link>http://rayed.com/wordpress/?p=890</link>
		<comments>http://rayed.com/wordpress/?p=890#comments</comments>
		<pubDate>Mon, 06 Feb 2012 13:50:24 +0000</pubDate>
		<dc:creator>Rayed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[arduino]]></category>
		<category><![CDATA[hardware]]></category>
		<category><![CDATA[microcontroller]]></category>

		<guid isPermaLink="false">http://rayed.com/wordpress/?p=890</guid>
		<description><![CDATA[I ordered The Ultimate Microcontroller Pack with Arduino UNO, in fact I ordered 2 packs one for me and my 6 years old son, and one for my 13 years old nephew Abdullah. I am very excited to try all &#8230; <a href="http://rayed.com/wordpress/?p=890">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I ordered <a href="http://www.makershed.com/Ultimate_Microcontroller_Pack_p/msump.htm">The Ultimate Microcontroller Pack</a> with <a href="http://arduino.cc/">Arduino</a> <a href="http://arduino.cc/en/Main/arduinoBoardUno">UNO</a>, in fact I ordered 2 packs one for me and my 6 years old son, and one for my 13 years old nephew Abdullah.</p>
<p>I am very excited to try all the components, so far I am still with LED and buttons, looking for moving my first <a href="http://handyboard.com/hb/faq/hardware-faqs/dc-vs-servo/">servo</a> and of course my first robot <img src='http://rayed.com/wordpress/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><a href="http://rayed.com/wordpress/wp-content/uploads/2012/02/IMG_3212.jpg"><img src="http://rayed.com/wordpress/wp-content/uploads/2012/02/IMG_3212-300x225.jpg" alt="" title="http://www.makershed.com/Ultimate_Microcontroller_Pack_p/msump.htm" width="300" height="225" class="alignnone size-medium wp-image-894" /></a></p>
<p><a href="http://rayed.com/wordpress/wp-content/uploads/2012/02/IMG_3213.jpg"><img src="http://rayed.com/wordpress/wp-content/uploads/2012/02/IMG_3213-300x225.jpg" alt="" title="Kit components" width="300" height="225" class="alignnone size-medium wp-image-895" /></a></p>
<p><a href="http://rayed.com/wordpress/wp-content/uploads/2012/02/IMG_3214.jpg"><img src="http://rayed.com/wordpress/wp-content/uploads/2012/02/IMG_3214-300x225.jpg" alt="" title="Arduino" width="300" height="225" class="alignnone size-medium wp-image-896" /></a></p>
<p><strong>Features</strong><br />
(1) MakerShield (Prototyping shield)<br />
(1) Mini Breadboard<br />
(2) Micro Servos<br />
(1) LCD Screen 16&#215;2<br />
(2) Force-Sensitive Resistor<br />
(1) 9V Battery Case w/Plug<br />
(1) Component Storage Box<br />
(1) Deluxe Jumper Wire Pack<br />
(1) Full-Size Clear Breadboard<br />
(2) Protoboard 7&#215;9<br />
(1) Heat Shrink Tubing<br />
(10) 330 Ohm Resistors<br />
(10) 10K Ohm Resistors<br />
(10) 1K Ohm Resistors<br />
(10) 10nF Ceramic Capacitors<br />
(10) 100nF Ceramic Capacitors<br />
(5) 100uF Electrolytic Capacitors<br />
(3) 5mm RGB LED<br />
(5) Basic Green LEDs<br />
(5) Basic Red LEDs<br />
(2) Tilt Sensor<br />
(5) Mini Pushbuttons<br />
(3) DPDT Switches<br />
(2) Photo Resistors<br />
(2) Thermistors<br />
(1) Rotary Potentiometer<br />
(1) Transistor NPN<br />
(1) Diode<br />
(1) 8Ohm Speaker with Leads<br />
(1) Piezo Buzzer<br />
(3) 8-Pin Stackable Female Headers<br />
(5) 8-Pin Female Headers<br />
(2) 40-Pin Male Breakaway Headers<br />
(1) 6-Pin Stackable Female Header<br />
(1) 40-Pin Male Breakaway Dual-Headers<br />
(1) Mini DC Motor<br />
(1) Vibration Motor</p>
]]></content:encoded>
			<wfw:commentRss>http://rayed.com/wordpress/?feed=rss2&#038;p=890</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Arduino and other embedded boards</title>
		<link>http://rayed.com/wordpress/?p=884</link>
		<comments>http://rayed.com/wordpress/?p=884#comments</comments>
		<pubDate>Wed, 25 Jan 2012 08:12:24 +0000</pubDate>
		<dc:creator>Rayed</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rayed.com/wordpress/?p=884</guid>
		<description><![CDATA[My list of embedded boards, I hope to keep it updated as I learn more about embedded systems options: Arduino: $15, Atmel AVR, microcontroller. Pinguino: $24, PIC, microcontroller. Netduino: $35, ARM, Microsoft .Net!, Atmel 32-bit microcontroller. Raspberry Pi: $25, ARM, &#8230; <a href="http://rayed.com/wordpress/?p=884">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>My list of embedded boards, I hope to keep it updated as I learn more about embedded systems options:</p>
<ul>
<li><a href="http://www.arduino.cc/">Arduino</a>: <a href="http://www.amazon.com/Arduino-A000046-UNO-board/dp/B004CG4CN4">$15</a>, <a href="http://en.wikipedia.org/wiki/Atmel_AVR">Atmel AVR</a>, microcontroller.</li>
<li><a href="http://pinguino.cc/">Pinguino</a>: $24, <a href="http://en.wikipedia.org/wiki/PIC_microcontroller">PIC</a>, microcontroller.</li>
<li><a href="http://netduino.com/"> Netduino</a>: $35, <a href="http://en.wikipedia.org/wiki/ARM_architecture">ARM</a>, Microsoft .Net!, Atmel 32-bit microcontroller.</li>
<li><a href="http://en.wikipedia.org/wiki/Raspberry_Pi">Raspberry Pi</a>: $25, <a href="http://en.wikipedia.org/wiki/ARM_architecture">ARM</a>, Microprocessor, <a href="http://en.wikipedia.org/wiki/System-on-a-chip">SoC</a>, Good Video (HDMI), Linux.</li>
<li><a href="http://www.pjrc.com/teensy/"> Teensy</a>: $16, Amel AVR, Microcontroller, Tiny.</li>
<li><a href="http://beagleboard.org/">BeagleBoard</a>: $89, ARM, Ethernet, 2GB MicroSD, Linux.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://rayed.com/wordpress/?feed=rss2&#038;p=884</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

