gentoo on a production server
task: find an operating system as powerful as gentoo, while makign sure you will never be out of buissnes because your sys admin is trying to "pimp your ride" and rendering the system unusable
proposed solution: use gentoo. *cough* simple isnt it? havoc arises mainly when you becoem lazy and stop keeping your system reasonably in sync with the gentoo project, updating once a week is good, ever two weeks is good, but after 3 weeks motorbiking in the middle of nowwhere you might coem home and find out that you are wwwaaaayyyyyy behind.
automating the task of updating is a bad idea, sometimes stuff breaks, its quite rare these days but can happens, usually because you have been lazy for a while. sometimes human cleverness is needed to update a package, you have to read and understand a little note attached to the update. this can only be done by doing updates once in a while. attachign little post it notes to screens or automatic email reminders or something along these lines, find a babysitter when you go on holiday for long times without internet, having your own server is a 24/7 task, if you cant do it you have to pay ppl to do it for you.
so this part of the problem is "solved". how do we make sure we can break the system and still be back up again within minutes? we mirror the root partition during everyday operation and keep our data on a different partition, mirroring it makes no sense, data has to be backed up using a different strategy, before we update soemthign that might brake we flick a magic switch and stop mirroring, give it a go, if somethign breaks we put our foot on the break and reboot booting the backup system, either we flick the magic "sync" switch and wait that what was our A system gets restored from our B system or we keep it broken chroot() into it and try and fix it, if confident that its all good again, reboot and see what happens(preferabbly in the middle of the nite) if its doesnt work we reboot and go back to the B machine, continue this for as long as you feel like doing it. this system gives you another neat advantage, look:
machine A is live at the moment, serving happily but you have been lazy and fidn that you can not easily update it to the most current software for what ever reason, you flick the magic "sync" switch, clean the root partition of the B machine and start isntalling a brandnew clean system, all set? reboot, new system comes up nicely everybody feels good, old A mchina becomes the B machine(tho this A and B logic doesnt really make any sense, the machiens are equal and there shouldnt be any reason to refer to one as A and the other as B, A is always the one thats serving or has just failed, if we reboot without failing the machien we booted into becomes the A machine.)
naturally all thsi doesnt provide you with a possibility to test your changes before you make them to fidn out if they will brake or not but thats not the aim of all this, buy a nother machien and do your tests there if you want something like this
open issues: how do we implement a mirroring strategy like this? we need a magic "sync" switch otherwise it wont work, quick look at the XEN documentation didnt yield a obvious way of doing it, does the linux kernel have somethign like this? can LVM do it for us? do we have to retreat to a hourly rsync?
proposed solution: use gentoo. *cough* simple isnt it? havoc arises mainly when you becoem lazy and stop keeping your system reasonably in sync with the gentoo project, updating once a week is good, ever two weeks is good, but after 3 weeks motorbiking in the middle of nowwhere you might coem home and find out that you are wwwaaaayyyyyy behind.
automating the task of updating is a bad idea, sometimes stuff breaks, its quite rare these days but can happens, usually because you have been lazy for a while. sometimes human cleverness is needed to update a package, you have to read and understand a little note attached to the update. this can only be done by doing updates once in a while. attachign little post it notes to screens or automatic email reminders or something along these lines, find a babysitter when you go on holiday for long times without internet, having your own server is a 24/7 task, if you cant do it you have to pay ppl to do it for you.
so this part of the problem is "solved". how do we make sure we can break the system and still be back up again within minutes? we mirror the root partition during everyday operation and keep our data on a different partition, mirroring it makes no sense, data has to be backed up using a different strategy, before we update soemthign that might brake we flick a magic switch and stop mirroring, give it a go, if somethign breaks we put our foot on the break and reboot booting the backup system, either we flick the magic "sync" switch and wait that what was our A system gets restored from our B system or we keep it broken chroot() into it and try and fix it, if confident that its all good again, reboot and see what happens(preferabbly in the middle of the nite) if its doesnt work we reboot and go back to the B machine, continue this for as long as you feel like doing it. this system gives you another neat advantage, look:
machine A is live at the moment, serving happily but you have been lazy and fidn that you can not easily update it to the most current software for what ever reason, you flick the magic "sync" switch, clean the root partition of the B machine and start isntalling a brandnew clean system, all set? reboot, new system comes up nicely everybody feels good, old A mchina becomes the B machine(tho this A and B logic doesnt really make any sense, the machiens are equal and there shouldnt be any reason to refer to one as A and the other as B, A is always the one thats serving or has just failed, if we reboot without failing the machien we booted into becomes the A machine.)
naturally all thsi doesnt provide you with a possibility to test your changes before you make them to fidn out if they will brake or not but thats not the aim of all this, buy a nother machien and do your tests there if you want something like this
open issues: how do we implement a mirroring strategy like this? we need a magic "sync" switch otherwise it wont work, quick look at the XEN documentation didnt yield a obvious way of doing it, does the linux kernel have somethign like this? can LVM do it for us? do we have to retreat to a hourly rsync?
0 Comments:
Post a Comment
<< Home