What does it mean to be a Palestinian?

September 26, 2010

As a Palestinian, people usually asks me what is Palestine and how we live there. The conflict in the middle east is a very long one and going into the details of that conflict is a very complicated thing. I believe that you can get a PhD studying it and still don’t fully understand what’s going on there. So I wrote this short blog to make things easier to explain. I’m not going into the details of history nor politics because I’m neither a historian nor a politician. I’m just another a Palestinian who live a typical Palestinian life and that’s what I’m going to write about here.

First, since we (Palestinians) don’t have officially a country yet that means there is no such thing called Palestine. Yes, Palestine is just another fictional country name from novels and old stories. If Palestine is just a fictional country then anyone can claim that he/she is a citizen of that country. But as always the case with legends there are some requirements first before you get your citizenship. These requirements are:

  1. You or your ancestors own virtual land on the virtual country called Palestine.
  2. You born in some palace other than the fictional country Palestine, but in some magical way your parents or one of them or grandparents were porn there.
  3. You have all the human rights except any human right given to people in real countries.

So if you meet all the above criteria, congratulations you’re now officially a Palestinian. But as always being said “with great power comes great responsibilities”. Now as a Palestinian you have to deal with the following things.

  1. The citizenship is for lifetime for you and your children; you can’t gave up your citizenship.
  2. You can have any other real citizenship. But the Palestinian citizenship always comes first; you are Palestinian first then you’re treated as a citizen of the other country.
  3. In every airport or checkpoint you will be selected for “random security check”; simile you’re a celebrity now!
  4. If you are only holding a Palestinian citizenship, don’t bother yourself for looking for your country name in any official form you fill outside Palestine (the virtual country which doesn’t exists).

But wait a minute, don’t understand me wrong! not everything of being a Palestinian is bad! There few great things that made Palestinian survive!

  1. Failure is not an option, it is a choice that Palestinians will never choose. If something didn’t work out try again and again one million time until you achieve your goal. Palestinians have been working hard to get their basic human rights for more than 60 years, and they got almost nothing so far but they didn’t let anything stop them from trying again.
  2. Skye is the limit for your dream. Don’t get me wrong when I say dreams, Palestinian don’t just dream they always push them selves to the limit to make things seems to be impossible happen. Just go to any of the Palestinian refugee camps and see what the great things that people are doing there just to survive through the tough life they are living.
  3. Hope Hope Hope…. one million time, no matter how hard today is you will see a big  smile on the Palestinians faces and they will assure you that tomorrow is going to be a better day despite how dark it looks like from today’s eye. It’s not hope built no just dreams, no it’s hope because Palestinian chose not to fail and they will try and tray until they make tomorrow a better day for everyone.

And many other things that made this  great people survive through history.

This is simply the legend of Palestine …

0

Chances for IT Industry in Palestine

July 24, 2010

Two weeks ago a friend of mine sent me an email asking me for ideas to do IT business in Gaza. I’m not an entrepreneur but I have opinion about it, I might be right and I might wrong but I decided to share my thoughts that sent to my friend my it will be beneficial to someone else.

Before starting any business in Gaza or any place in the world, you should study the available local resources. Gaza lacks a lot of things; electricity, water, food, transportation, etc…. But it very rich with something unique; its people. Yes, the type of Palestinian people is very unique. Why is it unique? because these people are born to be engineers, how come? well, everything is a challenge and any one wants to survive has to come with brilliant ideas that overcome all the barriers we have. For example, if you want to do simple thing like cooking go for a Palestinian home in Gaza and see home many alternatives they have! they cook on gas, electricity, wood, old cloths if available, gasoline, and many other things I cannot count. This is just to cook a nice dinner. Now these people not only came with more than one solution for the problem, which is an essential part of being an engineer, they also making trade-offs on a daily basis. Let’s go back to our cooking example, every Gazian home has at least three types of the cooking methods I mentioned and for each meal on the day the family has make a trade-off on which method to use to cook. The choice is based on three factors: Availability, Cost, and Time. These are the principles the people go for four or five years college to learn but we learnt by practice sine we are babies.

From all this and many other every Palestinian learn to be an engineer with a great passion, determination and no fear from failure. If someone failed in doing something, giving up is not an option but trying again and again with learning valuable lessons form each failure so we become better on every new day.

I think that what makes the Palestinian people one of the best educated people in the region, despite all what they are facing. For example now in Gaza people have electricity for less than half of the day in average, but the internet penetration rate is 60%!

I think the best product that we can produce in Gaza is innovation! yes innovation is a very valuable product and it’s more rare than gold! IT industry are the best match for marketing innovation. It doesn’t need huge resources nor capital of investment but it needs brilliant well trained people.

Now back to my friends question, he was really excited by Google’s visit to Gaza and he wanted to do something related to their products so I limited my answer to areas were Google products can be used(Maybe in the future I will blog about a broader business chances in Palestine). Here is and edited version of my answer to him

For the ideas, I cannot tell you specific ideas but I can help by giving some thoughts on directions where to invest:

  1. Focus on small ideas that target community needs, you cannot change the world with on application. By this I mean think about things that people would use everyday, for example small Android apps that organize your daily consumption of calories are successful though it’s very simple (I’m not telling you to write app for daily consumption of calories but just an example)
  2. Google now focusing on having more market share on the Internet advertisement on the Middle East, I heard that advertisements market in the middle is 10 billion dollars per year while internet advertisement is only 100 million dollars. So any idea related to advertisement on the Middle East they will be interested on.
  3. Try to think about integrated experience, like apps that the user would use from a smart phone while going to his work or school, then when he is at his office he will use the same app but from a desktop, and when he is at home he will use the same app from his HD TV (look at Google TV).  The technology to build such applications is not that hard, but the hard part is coming with ideas and apps that the user want to use on the first place. Take social networking as an example, everyone interested to update their status and check out their friends status updates thats why people having Facebook app everywhere from their cellphones to their desktop and now even on their TVes.
  4. Expensive product doesn’t work. To get money you have two options. First making your product for free and using advertisements as source for revenue. This is more suitable for web applications targeting any kind of devices (cellphones, TVes, Desktops). Second, is having more than one small app and selling it for low prices (less than $2) but focusing on selling a very large number of it.
  5. Think global, Gaza is not a big market but we have access to the internet that’s mean you can sell your application to anyone on the world. This sounds scary sometimes for startups in Gaza but they can do it only if they belived in themselfs.

Hopefully this friend and others succeeded in their efforts in making Palestine a better place. Again, I’m not an expert I’m just another Palestinian guy who have an opinion about the subject.

0

Rethinking multicore

July 10, 2010

In the recent months always comes to my mind how we can get over this multicore crisis that we are currently falling on. So I started with some consideration that I think it’s important for any future multicore processors design.

  1. Inherently sequential code can be improved by only small factor. Thus no need to put too much effort to make it 100% parallel, any small improvement in running sequential code is a good achievement.
  2. If a good parallel programming model is provided, software developers will eventually start writing more parallel code. This again minimize the need to make the sequential code run in parallel.
  3. Any future designs should address both fine-grain and coarse-grain parallelism. Addressing both types of parallelism will give the flexibility for the programmer to exploit the maximum parallelism on the application. But it would be better not to let the programmer worry about what type of parallelism, compilers, operating systems, and hardware should take care of it.
  4. Von Neumann architecture  use only one memory port for both data and code, while in Harvard Architecture it uses a port for data and another port for code. While current modern architectures, even those who started as pure Von Neumman,  are using mixed of both architectures. For example Intel L1 cache is divided to both data and code cache, very similar to Harvard Architecture,  while there is only one main memory for both data and code, like Von Neumann. But having 1000s of cores on the same chip will require more memory ports. By more memory ports I don’t using Harvard architecture or building systems similar to NUMAs. We need to figure out a smarter memory schemes that fulfill the needs for 1000s taking in mind that the advancement rate on the memory speed is much less than CPUes.
  5. With all this cores per chip and the amount of the available parallelism, concurrency is going to be a major concern and efficient standardized methods is needed to handle this issue. Handling concurrency should be embedded deep on the stack from the hardware to the operating system to the programming language so the end programmer shouldn’t worry that much about it. Of course it’s not going to be totally free for the programmer to use concurrency, but at least should be very easy, pain free, and efficient.
  6. Another thing that I already talked about in my previous post. We need to rethink about the contract between the different layers of the stack that we built so far. Thinking again is required on each layer as well as on the  contract between the layers.
0

Creating GRUB virtual floppy image

July 5, 2010

I’m was playing with writing my own kernel for fun, but the first thing I realized that I don’t need to write my own boot loader thanks to the multiboot specifications[1].

Most tutorials I saw on the Internet were talking about how to install a grub on a physical floppy. Of course no one these days use floppy disks not they have floppy drives on their machines on the first place. This tutorial is inspired by an OSDev article http://wiki.osdev.org/GRUB#Installing_to_floppy.

Creating a grub boot loader disk, two stages are needed. First stage is creating an auxiliary disk. The auxiliary disk is needed to copy stage1 and stage2 of the grub boot loader[2] in block 1 and block2 of the disk. This means we have a bootable disk but the filesystem of the floppy is corrupted. We need a floppy with a fully functional filesystem that we can use to copy our kernel on it. Second step is create the actual boot floppy with a fully functional filesystem. The second floppy is made by using the auxiliary disk. Enough talking and lets go to the practical steps.

Stage 1: Creating Auxiliary Virtual Floppy

1. The  very first thing is is to create the virtual image that we are going to work on.

dd bs=512 count=2880 if=/dev/zero of=auxiliary.img

Basically, this command will create a file of 2880 block each one is 512 bytes (remember floppy disk is 1.44MB). Because we are reading from /dev/zero the new file will be initialized to zeros.

2. Copy stage1 and stage2 to the image. This is done with the dd command. But things we have to be aware of. First, stage1 should be in the first block of the disk and stage2 in the second block. Second, dd by default with truncate the floppy image, something definitely we don’t want, so make sure to use conv=notrunc option.

dd if=stage1 of=auxiliary.img bs=512 count=1 conv=notrunc
dd if=stage2 of=auxiliary.img bs=512 seek=1 conv=notrunc

You can download a ready made disk from here: auxiliary.img.tar

Stage 2: Making the actual boot disk

1. Same as first stage, we need to create the image file initialized to zeros.

dd bs=512 count=2880 if=/dev/zero of=grubboot.img

2. (Not necessary step, but I like it), Attach the image file that we just creating to a loop device.

sudo losetup /dev/loop1 grubboot.img

By this way we will work our image as an actual block device, rather than just a file. I used this for two reasons. First it’s more convenient to handle block device. Second, when making a file system on a file using mkfs it will complaining about it not being a block device, but still works!

3. Make a filesystem on the boot disk and then mount it. You can choose what ever filesystem you want as long as it’s supported by GRUB!

sudo mkfs /dev/loop1
sudo mount /dev/loop1 /tmp/virtualfloppy

4. Once the filesystem is created and mounted we can play with this little floppy as we want. Now it’s time to create  a boot folder and add stage1 and stage2 to it. The other thing we need is a configuration file for grub menu. This file basically tells grub what operating systems exists and from where to load it. Of course to forget to copy your kernel as well. Here I chose to name by kernel kernel.bin and put it on the boot folder.

sudo mkdir /tmp/virtualfloppy/boot
sudo chmod o+w /tmp/virtualfloppy/boot
sudo cp stage1 /tmp/virtualfloppy/boot
sudo cp stage2 /tmp/virtualfloppy/boot
echo "title   MyOS
root    (fd0)
kernel  /boot/kernel.bin" > tmp/boot/menu.cfg

5. We are almost done. Right now we have a floppy with a filesystem and all our files, but not the boot sector. And here comes the role of the auxiliary disk we created on the first stage. First boot using the auxiliary by any virtual machine software you like (I use VirtualBox[3]). If everything is working good you will see a grub prompt on the virtual machine. Now unmount the auxiliary.img and mount the grubboot.img. After doing this type the following command on the grub prompt.

install (fd0)/boot/stage1 (fd0) (fd0)/boot/stage2 (fd0)/boot/menu.cfg

6. And we are done. Just reboot from grubboot.img and your kernel will be running. One thing worth to mention here, this is a really long process to create a virtual bootable floppy but it’s worth it, because once you created the floppy you just copy your kernel again and again without needing to repeat anything from the previous steps. The other thing to mention is, I’m using the legacy GRUB here because I don’t really need the new features on the newer versions of grub I just need something that boots my kernel.

And if you need just a floppy that works by copying your kernel into without going through all steps, download this ready made image but without a kernel: bootfloppy.img.tar

[1] http://www.gnu.org/software/grub/manual/multiboot/multiboot.html

[2] Probably you can find these files installed into your linux, but if not you can download them from heregrubstages.tar.

[3] VirtualBox http://www.virtualbox.org/

0

Rethinking of Levels of Abstraction

March 24, 2010

It has been a while since my last blog. But I was busy thinking of a lot of crazy ideas and trying to push myself to the limit. Here some of what I’m thinking of right now!

The current modern systems are built in layers and layers of abstraction. The idea behind abstraction is to divide complex systems into layers and each layer has relatively simpler complexity. But we are accumulating on the same layers built one the beginning of the computer age. For example the microprocessor is the same as the first microprocessors built. Some people might argue that and I agree with them we have very advanced microprocessors today comparing to the Intel 8086. But here I’m not talking about the technology, I’m talking about abstraction. Computer designers are using the same interface for the CPU level of abstraction since the creation of the first microprocessors.

This huge accumulation of old levels of abstraction will start failing in keeping serving the current needs for today’s and future’s technology. One example of that is the multicore processors. With the introduction of multicore we start hearing from researchers that we need to rethink of processors, operating systems, and programming paradigms. However, most of the current efforts directed to keep the same contract between the different layers of abstraction and just change the internal of each layer without breaking the contract between the layers.

I think these levels of abstraction are not written in stone and we don’t just need to think about improving each layer, but we need as well thinking of the abstraction levels from time to time. However, I don’t recommend changing the abstraction levels very frequently. But I do think that there are some times where we need to rethink of the whole stack, and today is one of these times.

In rethinking of the abstraction levels there are two approaches. First approach is rebuilding the whole stack again from ground up. This approach gives the designer total freedom of building new stack. One particular project that I like and follows somehow similar approach is the Par Lab at Berkeley [1]. Researchers there are aiming to setting new agenda for multicore research starting from anticipating the future applications and then design new stack the will support these applications.

The other approach of the rethinking of the stack is to use ideas from higher levels of the stack in the bottom of the stack, or vice versa. This approach allows the designer to reuse already well defined and tested solutions. One project I liked that follows the same approach is Factored Operating System (fos) at MIT [2]. They are using the same concepts Internet to design operating system that is service based. I liked this idea very much since I was thinking of it for more than two years. At the beginning I thought that is very crazy idea but not it’s real.

[1] http://parlab.eecs.berkeley.edu/

[2] http://groups.csail.mit.edu/carbon/?page_id=39

1

Be ready, GSoC 2010 is on

February 21, 2010

On Jan 26, Leslie Hawthorn (LH) the program manager of GSoC announced that GSoC is on for 2010[0]. If your are a student or an organization planning to participate in next year program it’s better to get ready from now. The number of students and organizations on 2009 was less than 2008[1].  I hope this year Google will accept more organizations and students than the last year.

Good luck for everyone….

[0] http://groups.google.com/group/google-summer-of-code-discuss/browse_thread/thread/d839c0b02ac15b3f

[1] http://spreadsheets.google.com/pub?key=p6DuoA2lJToKmUzoSq6raZQ&gid=1

0

SC09 Competition

December 12, 2009

Yes, I won something

http://www.udel.edu/udaily/2010/dec/supercomputing120409.html

0

Working for MoG, more about the project!

October 8, 2009

If you from more advanced country it’s simple to send mail because there is a system for addressing, but this is not the case about Gaza and this one of the reasons that the mail never works in Gaza. Therefore, Municipality of Gaza (MoG) started a project funded by the world bank to make system for addressing. The idea is very simple, just give a number to each street and a number for each building on that street. By this way each building will have unique address by the pair (BuildingNo, StreetNo). But implementing this on the ground it not easy as paper. It consumes large human resources because Gaza is old city and it not very well designed city and in many cases people working on that project spend days just thinking how normalize special cases that arise. But this only one part of the project.

My project was the second part of the project. Since every building must have at least one construction permit this mean that each (BuildingNo, StreetNo) pair must point to one or more construction permits. One or more because the building can be built in different phases and each phase must have separate construction permit.

MoG have big old archive of construction permits. This archive contain permits since 1910s but this archive is paper based and no computer records about it. We are now in 2009 and MoG still have no computer system for construction permits all is done manually.

My boss give me a three simple tasks:

1- Get the important data from the paper archive to computer database.

2-Match each construction permit to (BuildingNo, StreetNo).

3-Build new computer based system for future construction permit where each construction permit will automatically attached to (BuildingNo, StreetNo).

These tasks seems very concise and simple!

Next time I will talk more about the nature of the problem and the approaches I took to solve it.

0

Working on a large project with one developer!

October 7, 2009

I worked for five months for Municipality of Gaza (MoG) from February 26, 2009 – July 30 2009. This was the hardest time in my life. During this period I tried hard to push myself to the limits to see how fare can I go. This includes working 12 to 15 hours per day six days per week. I was exhausted but I think I achieved good results and proved (at least) for myself that I can work in extreme work pressure.

During this periods I work on big project and I was responsible of big part of it. I gained a lot of experience and mostly non-technical experience. Things like how to manage team and how to collect business requirements from people know nothing about computers.

I will try on the next few weeks to summarize what I learned on this blog so I don’t forget what I learn and share this experience with others (of course, no one has to work the same amount I worked :) )

0

Two months in US

October 4, 2009

I just moved to study my masters at University of Delaware. I’m now studying computer science which is small shift from my computer engineering background. The movement transition was easy but time consuming.  I hope that I will do well in my new life.

0