[Sugar-devel] Adding support for new datastore to the XS...

Martin Langhoff martin.langhoff at gmail.com
Wed May 6 07:48:26 EDT 2009


Tomeu, Sugaristas,

looking at the new DS as implemented in SoaS. To confirm, is this
 http://wiki.sugarlabs.org/go/Development_Team/Datastore_Rewrite what
is implemented in 0.84?

Maybe tagging the wikipage with a version moniker helps? Something at
the top that says "Sugar 0.88"...

cheers,


m
---------- Forwarded message ----------
From: Martin Langhoff <martin.langhoff at gmail.com>
Date: Tue, May 5, 2009 at 4:52 PM
Subject: Re: [Server-devel] backup : problem opening
/library/users/XXXX/datastore-xxxxx/store
To: Hamilton Chua <hamilton.chua at gmail.com>, XS Devel
<server-devel at lists.laptop.org>


Hi Hamilton,

Let's keep this on the list. Is that from a recent SoaS? The datastore
storage format has changed then, and we need to add support to Moodle
for it.

More work! :-p

Sugaristas, if I want to support the 0.84 datastore, is the on-disk
layout well explained anywhere? There's many pages, none says what
version they are authoritative for... I suspect the right page is:

 http://wiki.sugarlabs.org/go/Development_Team/Datastore_Rewrite

Hamiton's orig email below for reference...



m

On Tue, May 5, 2009 at 4:38 PM, Hamilton Chua <hamilton.chua at gmail.com> wrote:
> Thanks Martin, I think this will be very helpful.
> I looked at the contents of the data store folder and mine looks like ...
>
> [root at schoolserver1 THW40541797]# cd datastore-latest/
> [root at schoolserver1 datastore-latest]# ls -lah
> total 15K
> drwxr-xr-x+ 6 THW40541797 THW40541797 1.0K 2009-04-23 23:24 .
> drwxr-x---+ 7 THW40541797 THW40541797 1.0K 2009-04-23 23:19 ..
> drwxr-xr-x+ 3 THW40541797 THW40541797 1.0K 2009-04-24 10:31 5f
> drwxr-xr-x+ 4 THW40541797 THW40541797 1.0K 2009-04-24 11:02 checksums
> drwxr-xr-x+ 3 THW40541797 THW40541797 1.0K 2009-04-24 10:36 f6
> drwxr-xr-x+ 2 THW40541797 THW40541797 1.0K 2009-04-24 11:03 index
> -rw-r--r--+ 2 THW40541797 THW40541797    0 2009-04-24 10:30 index_updated
> -rw-r--r--+ 2 THW40541797 THW40541797    1 2009-04-24 10:30 version
>
> there is no store folder, instead there are 4 folders and 2 files.
>
>
>
>
> On Tue, Apr 28, 2009 at 12:58 AM, Martin Langhoff
> <martin.langhoff at gmail.com> wrote:
>>
>> On Mon, Apr 27, 2009 at 3:59 PM, Hamilton Chua <hamilton.chua at gmail.com>
>> wrote:
>> > Thanks so much for replying. I don't have an XO laptop so I'm unable to
>> > verify how backup/restore should really work but from your reply below
>> > I'm guessing that there really should be a store directory
>>
>> Ah, thought you had one. Sorry. Here's a sample from an XS dev box I have
>> here
>>
>> [root at schoolserver1 web]# ls -lah /library/users/
>> total 28K
>> drwxr-xr-x   6 root        root        4.0K 2009-04-03 06:51 .
>> drwxr-xr-x   9 root        root        4.0K 2009-02-27 17:48 ..
>> drwxr-x---+ 24 CSN7470319B CSN7470319B 4.0K 2009-04-27 10:11 CSN7470319B
>> drwxr-x---+ 10 SHC84601226 SHC84601226 4.0K 2009-04-02 20:02 SHC84601226
>> drwxr-x---+  6 SHF80801EE8 SHF80801EE8 4.0K 2009-01-21 12:17 SHF80801EE8
>> drwx------   5 SHF8080271C SHF8080271C 4.0K 2009-04-03 06:51 SHF8080271C
>>
>> This is the directory for a specific user - showing the hard-linked
>> snapshots. Names of the dirs are teh UTC time in which the snapshot
>> was completed. The little '+' sign means that they have ACLs (the only
>> ACL is so that apache can read them).
>>
>> [root at schoolserver1 web]# ls -lah /library/users/CSN7470319B/
>> total 112K
>> drwxr-x---+ 24 CSN7470319B CSN7470319B 4.0K 2009-04-27 10:11 .
>> drwxr-xr-x   6 root        root        4.0K 2009-04-03 06:51 ..
>> -rw-r--r--   1 CSN7470319B CSN7470319B   18 2008-02-29 09:27 .bash_logout
>> -rw-r--r--   1 CSN7470319B CSN7470319B  176 2008-02-29 09:27 .bash_profile
>> -rw-r--r--   1 CSN7470319B CSN7470319B  124 2008-02-29 09:27 .bashrc
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-01-21_15:43
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-03-25_15:06
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-03-26_00:08
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-03-27_00:11
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-03-28_00:02
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-03-29_00:13
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-03-30_09:12
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-03-31_00:06
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-01_00:04
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-02_16:02
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-03_00:02
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-10_20:32
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-13_10:42
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-14_06:14
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-15_20:19
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-17_12:08
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-23_14:42
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-24_00:10
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-2009-04-27_14:11
>> drwxr-xr-x   3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43
>> datastore-current
>> lrwxrwxrwx   1 CSN7470319B CSN7470319B   53 2009-04-27 10:11
>> datastore-latest ->
>> /library/users/CSN7470319B/datastore-2009-04-27_14:11
>> -rw-r--r--   1 CSN7470319B CSN7470319B  500 2008-05-23 13:35 .emacs
>> drwxr-xr-x   2 CSN7470319B CSN7470319B 4.0K 2008-04-06 16:43 .gnome2
>> drwx------   2 CSN7470319B root        4.0K 2009-01-21 10:14 .ssh
>>
>> [root at schoolserver1 web]# ls -lah
>> /library/users/CSN7470319B/datastore-2009-04-27_14:11
>> total 124K
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43 .
>> drwxr-x---+ 24 CSN7470319B CSN7470319B 4.0K 2009-04-27 10:11 ..
>> drwxr-xr-x+  4 CSN7470319B CSN7470319B 112K 2009-04-24 07:32 store
>>
>> This is a particular datastore -- fairly large so I've skipped the
>> records inthe middle -
>>
>> [root at schoolserver1 web]# ls -lah
>> /library/users/CSN7470319B/datastore-2009-04-27_14:11/store/ | head
>> total 243M
>> drwxr-xr-x+  4 CSN7470319B CSN7470319B 112K 2009-04-24 07:32 .
>> drwxr-xr-x+  3 CSN7470319B CSN7470319B 4.0K 2008-05-13 09:43 ..
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B  348 2008-10-07 19:26
>> 005714d1-f432-4d85-acdc-7d2a8a261395.metadata
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B  721 2008-10-21 12:15
>> 007610f6-62ec-4a74-af49-2d1f8cafe0fc
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B  378 2008-10-21 12:15
>> 007610f6-62ec-4a74-af49-2d1f8cafe0fc.metadata
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B  36K 2008-11-25 14:42
>> 01032138-bb02-4132-a33e-51bb464f34dd
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B  275 2008-11-25 14:42
>> 01032138-bb02-4132-a33e-51bb464f34dd.metadata
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B  308 2008-11-25 09:34
>> 015e6039-26b6-4424-bbe2-934564ae0f20.metadata
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B  304 2008-10-23 11:17
>> 0174d375-d574-49b2-aa7b-5dca4e22c52e
>> [root at schoolserver1 web]# ls -lah
>> /library/users/CSN7470319B/datastore-2009-04-27_14:11/store/ | tail
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B 4.4K 2008-10-21 04:19
>> ff0f7b98-e62c-45dd-8912-25619988ef07
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B  355 2008-10-21 04:19
>> ff0f7b98-e62c-45dd-8912-25619988ef07.metadata
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B  990 2008-08-29 20:43
>> ff13d2e5-8ba1-44ac-ad7f-d0c23e806587
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B  397 2008-08-29 20:43
>> ff13d2e5-8ba1-44ac-ad7f-d0c23e806587.metadata
>> -rw-r--r--+ 19 CSN7470319B CSN7470319B  932 2009-02-27 17:25
>> ffbed191-707c-4281-944b-ab342ebb3012
>> -rw-r--r--+ 19 CSN7470319B CSN7470319B  345 2009-02-27 17:25
>> ffbed191-707c-4281-944b-ab342ebb3012.metadata
>> drwxr-xr-x+  2 CSN7470319B CSN7470319B 4.0K 2009-04-24 07:33 index
>> -rw-r--r--+ 20 CSN7470319B CSN7470319B    0 2008-07-08 21:58
>> .metadata.exported
>> -rwxr-xr-x+ 20 CSN7470319B CSN7470319B  128 2008-05-13 09:43 metainfo
>> drwxr-xr-x+  2 CSN7470319B CSN7470319B  56K 2009-04-24 07:32 preview
>>
>> hope that helps!
>>
>> cheers,
>>
>>
>>
>> martin
>> --
>>  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
>
>



--
 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



-- 
 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 Sugar-devel mailing list