
Good people, Instead of blaming the poor techie over at KNEC for the slow app, lets give him/her some practical tips... *High Performance Website/Webapplication 101 *1. Server - Get the fastest server you can with the budget you have, fastest processor, as many cores as you can get - Make sure the hard disk RPM is the highest you can get, let 7200 be the minimum - Get bucketloads of RAM, we talking about 8GB minimum here. - Separate the web server from the database server, let each be on its own superfast, kick ass server (see first three points above) - Connect the database server directly to the webserver via a factory made cross over cable; this will save you a few micro seconds per request - If possible, rent several extra servers; maybe three for Apache (yes, I know you use Apache with ServerSignature On<http://www.knec.ac.ke/indexr5.php>) and three for the database, then use appropriate load balancing apps to distribute load over the other servers - If more servers are not an option, then when the time for releasing results comes, give 98% of the staff at KNEC compulsory leave and take their PCs, then make all of them act like one big nasty swarm. - Optimize the CentOS for speed - ... 2. Webserver - Let Apache sit on its own server, maybe two servers, maybe three. If more than one, use a load balancer. - Deactivate modules you dont need, like support for perl, python and etc - Oh yeah, you might want to change ServerSignature to something less "revealing" to the casual browser - ... 3. Database - I am guessing you are using MySQL, if not, ignore this section. - IMHO, MySQL is happiest when swimming in an ocean of RAM on a superfast HDD. - Make sure to test the options in my.cnf coz the defaults may not always be the best. - Let EXPLAIN query_here be your close friend. Explain each and every query and make the necessary changes. There is a ka-column called "rows scanned" or sth like that, let this be as low as possible, 1 being the magical number - Explain will reveal unused indices or missing indices. The philosophy is use is that most columns used in WHERE clauses should have indices - Make sure you have enabled the slow query log, set it to something low like 5 seconds, then monitor it like a baby. Any query which shows up in the slow query log is your enemy and you need to fix it ASAP. - If you have the skill, setup replication across several servers and modify your application to take advantage of your replication. I am guessing since you dont have much writes to the database after the results have been released, setup one server as the Master, then several servers as the slaves and direct all your reads to the slaves. - Head over to quest software and download Spotlight on MySQL<http://www.quest.com/spotlight-on-mysql/>/SQL Server/Linux and use it to watch your database and the underlying OS. Not only does it make the data easy to ingest, but it also looks amazingly cool! - ... 4. PHP - Be frugal, dont create variables unless you really need to, it might save you a bit of RAM - Profile your code, remove dead sections. - Run PageSpeen against each page, and fix the issues it points out. - Test test test! - ... 5. Others - Now, as skunk Phares will tell you, you dont really need many servers, you can get like 2 behemoths and virtualize the hell out of them! - The skunk Odhiambo will tell you, FreeBSD has the fastest TCP/IP stack this side of the Universe, so you might want to run your Apache off that - Some other better placed skunks will also tell you how to make your network super fast - And most def some other skunk will tell you how to make your non-mysql database even faster. - .... 6. ....

Some other skunk will tell you to hit Amazon or some related service and run on a demand server which scales up to demand.

I think this is the meaningful dialogue some skunkers were asking for... We need like 43 replies for this... so here's mine: Yet some other skunker will agree that on demand services from soneone like amazon or rackspace cloud will give you something to fit the budget and give a boost at this time when kenyas peculiar results accessing habits are on the peak. On Tue, Mar 1, 2011 at 11:49 AM, Dennis Kioko <dmbuvi@gmail.com> wrote:
Some other skunk will tell you to hit Amazon or some related service and run on a demand server which scales up to demand. _______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke
-- *“The twentieth century has been characterized by three developments of great political importance: the growth of democracy, the growth of corporate power, and the growth of corporate propaganda as a means of protecting corporate power against democracy”* ~ Alex Carey ~ Tel No: 0x2af23696 I thin

I like where this is going... +1 vote for hosting on the cloud

Have u guys noticed that every time KCSE results are released we have these same discussions? Coz am so sure we did discuss this same time last year and checking the archives would prove me right. ./Ok3ch Sent from my iPad On Mar 1, 2011, at 11:57, Haggai Nyang <haggai.nyang@gmail.com> wrote:
I like where this is going...
+1 vote for hosting on the cloud _______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke

LOL, true. Lets just hack the site, query all the results. Create our own better site and host the results with our ideas in place On Tue, Mar 1, 2011 at 12:11 PM, Okechukwu <okechukwu@gmail.com> wrote:
Have u guys noticed that every time KCSE results are released we have these same discussions? Coz am so sure we did discuss this same time last year and checking the archives would prove me right.
./Ok3ch
Sent from my iPad
On Mar 1, 2011, at 11:57, Haggai Nyang <haggai.nyang@gmail.com> wrote:
I like where this is going...
+1 vote for hosting on the cloud _______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke
Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke

@Okechukwu Same argument for the last 4 years actually... Biggest question would be how to engage with .go.ke... The solutions are not the issue. Implementation is, really... I'm sure the NationMedia website has more hits... -- With Regards, Phares Kariuki | T: +254 734 810 802 | E: pkariuki@gmail.com | Twitter: kaboro | Skype: kariukiphares | B: http://www.kaboro.com/ |

I second that Peter should send this email (these emails) to the knec board, ceo, the country's president (in consultation with the PM), the ICT PS, the MoE PS et al every week until Dec, 2011. If they can't implement then they should use all skunks taxes and hire Karunyu for implementation before Feb 2012. That way I will truly feel we have contributed to our country. Davis. On Tue, 2011-03-01 at 12:11 +0300, Okechukwu wrote:
Have u guys noticed that every time KCSE results are released we have these same discussions? Coz am so sure we did discuss this same time last year and checking the archives would prove me right.
./Ok3ch
Sent from my iPad
On Mar 1, 2011, at 11:57, Haggai Nyang <haggai.nyang@gmail.com> wrote:
I like where this is going...
+1 vote for hosting on the cloud _______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke
Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke
-- Davis Waithaka Maina Business Development Manager Systems Kenya Solutions 4th Fl. KCB Building Enterprise Rd., Nairobi www.systemskenya.com +254 721 305 374

On Tue, Mar 1, 2011 at 11:54, [Brainiac] <arebacollins@gmail.com> wrote:
I think this is the meaningful dialogue some skunkers were asking for... We need like 43 replies for this... so here's mine:
Yet some other skunker will agree that on demand services from soneone like amazon or rackspace cloud will give you something to fit the budget and give a boost at this time when kenyas peculiar results accessing habits are on the peak.
So you guys surmise that hosting the service outside Kenya is better?? I still support the "all Kenyan, all the time" principle. I hate having to rely on some other people, denying the Kenyans employment! KNEC can generate enough money to setup the systems propose by Karunyu. Sometime back (I think it was during KCPE results) I suggested a small server running on SSD. That was a starting point, for such a setup. But anyway, who cares? KNEC does not listen, because they could already have done something. KNEC doesn't read this forum and there is no one in this forum who knows anyone in KNEC who knows anyone who is in authority who can take this issue to the KNEC board (or whatever shit it is called) to take some action. Nkt!! If KNEC was listening, skunkers could solve their problem within a month - at most, and probably for free. Sometimes back while I was at Wananchi, we run this KNEC stuff on a dedicated workstation (running FreeBSD+Apache+MySQL..) and I don't ever recall any complaints then. -- Best regards, Odhiambo WASHINGTON, Nairobi,KE +254733744121/+254722743223 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ Damn!!

KNEC can learn a lot from IIEC. On 3/1/2011 12:50 PM, Odhiambo Washington wrote:
On Tue, Mar 1, 2011 at 11:54, [Brainiac] <arebacollins@gmail.com <mailto:arebacollins@gmail.com>> wrote:
I think this is the meaningful dialogue some skunkers were asking for... We need like 43 replies for this... so here's mine:
Yet some other skunker will agree that on demand services from soneone like amazon or rackspace cloud will give you something to fit the budget and give a boost at this time when kenyas peculiar results accessing habits are on the peak.
So you guys surmise that hosting the service outside Kenya is better?? I still support the "all Kenyan, all the time" principle. I hate having to rely on some other people, denying the Kenyans employment! KNEC can generate enough money to setup the systems propose by Karunyu. Sometime back (I think it was during KCPE results) I suggested a small server running on SSD. That was a starting point, for such a setup.
But anyway, who cares? KNEC does not listen, because they could already have done something. KNEC doesn't read this forum and there is no one in this forum who knows anyone in KNEC who knows anyone who is in authority who can take this issue to the KNEC board (or whatever shit it is called) to take some action. Nkt!!
If KNEC was listening, skunkers could solve their problem within a month - at most, and probably for free.
Sometimes back while I was at Wananchi, we run this KNEC stuff on a dedicated workstation (running FreeBSD+Apache+MySQL..) and I don't ever recall any complaints then.
-- Best regards, Odhiambo WASHINGTON, Nairobi,KE +254733744121/+254722743223 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ Damn!!
_______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke

This thread just shows how much talent we have and that we can write up our own system and performance requirements ( a technical constitution, if you compare it ). This is one more reason why the local Association should exist. Reading @Phares contribution that it's same argument for the last 4 years, we need the legal teeth to fight back with an operational system. I cannot think of a better scenario. Also, if we have to go to court to ensure that the National Image on technology is upheld, then so be it. If KARA could take the City Council to court of parking charges, then imagine what we can correct in this industry by having the ability to tackle such issues. A small step today, a bigger resolution for the future. Some thots. :-)

I actually like the idea of going to court and making sure things happen if they don't happen in the right way. This is now enshrined in our constitution and we should make use of it - and another plus argument for an association. ./Ok3ch On Tue, Mar 1, 2011 at 5:32 PM, aki <aki275@gmail.com> wrote:
This thread just shows how much talent we have and that we can write up our own system and performance requirements ( a technical constitution, if you compare it ). This is one more reason why the local Association should exist. Reading @Phares contribution that it's same argument for the last 4 years, we need the legal teeth to fight back with an operational system. I cannot think of a better scenario. Also, if we have to go to court to ensure that the National Image on technology is upheld, then so be it. If KARA could take the City Council to court of parking charges, then imagine what we can correct in this industry by having the ability to tackle such issues.
A small step today, a bigger resolution for the future.
Some thots. :-)
_______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke
participants (11)
-
[Brainiac]
-
aki
-
Davis Waithaka
-
Dennis Kioko
-
Haggai Nyang
-
James Kagwe
-
Odhiambo Washington
-
Okechukwu
-
Paul Kevin
-
Peter Karunyu
-
Phares Kariuki