[Server-devel] Help needed to decide on distributed server controls

Martin Langhoff martin.langhoff at gmail.com
Mon Mar 1 17:57:12 EST 2010


Hi Andrew,

welcome to the list! Interesting project -- some notes on your questions...

On Mon, Mar 1, 2010 at 5:49 AM, Andrew van der Stock <vanderaj at gmail.com> wrote:
> * Have a XS version that is quite traditional - it'll re-use whatever Moodle uses for the *AMP stack

We use apache, PHP and PostgreSQL. They come with config files that
are selected according to the RAM on the server. On apache and
PostgreSQL startup, we probe for installed memory and run the
appropriate config file.

> * Have a distributed version that allows students to create and share forums on their XO's

Right. I don't know how that'd work on the XO -- as it lacks
Apache+PHP. From a power-consumption PoV Apache/PHP is fairly
well-behaved -- the main burden is the memory footprint. Running MySQL
pr Pg on the XO however will burn through the battery in no time.
SQLite is probably a better option.

On an XO-1, which has very limited RAM (256MB ) and uses jffs2 for
storage I think you'll find it way too tight for any kind of local
LAMP stack.

> I need advice on how best to create a start / stop / restart / share the forum service.
> On the XS, I will re-use whatever controls system services on that platform if that makes sense, but I need a way to start the replication / peering process.

On the XS, a traditional init script is what we use for stuff that
needs to start with the OS. We also have Moodle as the main UI of the
XS, so you could add an administrative control UI.

> On the XO, I am struggling to decide if it's an Activity or a control panel. I am leaning towards control panel as it's something you don't directly interact with.

Keep in mind you cannot assume that the XO (a
power-consumption-conscious laptop) will be running LAMP code all the
time. Make sure that your app / activity is something that the user
starts and stops.

Have a look at the Wikipedia Activity -- it subclasses the webbrowser,
and it starts a python daemon (the wikipedia content is highly
compressed, so this python daemon acts as http server unzipping the
content). And when it exits, it closes the daemon. Highly recommended.

> On either platform, I want to make sure when a forum is running, it appears in My Neighborhood as an Activity that can be shared.

When it is running on the XO, you can programmatically set it to
shared. See the notes on wiki.laptop.org about writing activities that
use the Telepathy API. Experts on such topics roam around
devel at lists.laptop.org ;-)

When it's running on the XS -- I don't know how to make it appear. It
is in my plans to add an "XS" icon in the neighbourhood view that
should expose the key XS services.

> Is there a way I can get the XS to be a repository for the XO's? I'd hate for folks on expensive satellite or slow modem connections to have to download the likely ~ 10 MB every time.

For the activity code? Sure! That's one thing the XS already does. The
deployment team managing the XS will put your activity in the right
place.

> Authentication on XS
>
> Lastly, is there a NIS / LDAP service on the XS that I can use for federation?

No such centralised thing. But the XS/XO have automagic authentication
using some pre-shared info. See the auth/olpcxs moodle module -- the
patched moodle we ship on the XS is here:
http://dev.laptop.org/git/users/martin/moodle.git/log/?h=mdl19-xs

cheers,



m
-- 
 martin.langhoff at gmail.com
 martin at laptop.org -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff


More information about the Server-devel mailing list