jffs2 mounting by actrd, [Was: I need help]

2017-07-25 Thread James Cameron
On Wed, Jul 26, 2017 at 12:11:23AM -0400, Jhon Diaz wrote:
> When i try to boot my build using actrd, dracut gives me a warning

actrd.zip should only be loaded when a laptop is being booted
securely, when it does not have a developer key, or when the ❌ (cross
mark) game pad key is used to force secure boot when in non-secure
mode.  Purpose of actrd.zip is to obtain a lease or deny use of the
laptop.

http://wiki.laptop.org/go/Firmware_security has more details, as does
the kernel git repository directory olpc/.

What was the warning?  If it goes past too fast, you might be able to
catch it with a serial console, see
http://wiki.laptop.org/go/Serial_adapters

> then spits this out
> mount: mounting /dev/mtd0 on /sysroot failed: Block device required
> I don't know what to do?

Debug it.

Does your kernel have jffs2 support enabled?

Look at the code being run.  You'll find it in the OLPC dracut source
repository.  http://dev.laptop.org/git/users/quozl/dracut-modules-olpc/

Use an SD card or USB drive to boot the laptop and look carefully at
the jffs2 filesystem.

http://wiki.laptop.org/go/Tiny_Core_Linux
http://wiki.laptop.org/go/Cheat_codes

Also, we have several different actrd.zip files, make sure you are
using the right one for the kernel.  It should be in the kernel RPM.

-- 
James Cameron
http://quozl.netrek.org/
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


I need help

2017-07-25 Thread Jhon Diaz
When i try to boot my build using actrd, dracut gives me a warning
then spits this out
mount: mounting /dev/mtd0 on /sysroot failed: Block device required
I don't know what to do?
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Server-devel] [XSCE] need help getting moodle installed and configured hopefully with elgg ie SCALE demo

2017-03-28 Thread Adam Holt
On Tue, Mar 28, 2017 at 10:59 AM, George Hunt  wrote:

> The version of moodle in [Internet-in-a-Box / XSCE] release-6.2 will be a
> rolling snapshot of what "moodle_31_stable" branch downloads, and the time
> that the image is created.
>
> Look at the recent commits in https://github.com/moodle/m
> oodle/commits/MOODLE_31_STABLE. The version that would be installed
> today, if the install from scratch instructions are followed, would be
> 3.1.5.
>
> After the fact, security-conscious operators might, or might not, protect
> themselves by applying Moodle's "every 2 months" patches themselves.
>
> Update is accomplished by going into the /opt/schoolserver/moodle
> directory, and doing a "git pull".  But since this is not tested, they
> should be warned that they run the risk of loosing data or function. (maybe
> it's only a small risk)
>
> I believe the effort to upgrade to the most recent security updates by
> folks who are not systems administrators will contribute to insecurity and
> a more unreliable user experience.
>
> For most offline situations, the best policy is: "If it's not broken,
> don't fix it".
>

*Vital clarif, thx so much George!*

On Tue, Mar 28, 2017 at 10:20 AM, Adam Holt  wrote:
>
>> On Tue, Mar 28, 2017 at 9:08 AM, Tim Moody  wrote:
>>
>>> One trick to answer questions about what is included would be to look at
>>> the release notes to see what was added with each release.
>>>
>>> https://github.com/XSCE/xsce/blob/release-6.2/ReleaseNotes6.1.md
>>>
>>
>> Thanks Tim.
>>
>> Conclusion IIAB/XSCE 6.1 has indeed supported Moodle 3.1 since it was
>> released on Sept 22, 2016.
>>
>> George can you clarify if IIAB/XSCE 6.2 will include Moodle 3.1.5 or
>> similar Moodle 3.1.x, i.e. Moodle's many serious security updates since it
>> was released May 2016?
>>
>> (In any case, let's clarify how security-conscious operators might
>> protect themselves by applying Moodle's "every 2 months" patches
>> themselves.)
>>
>> On Tue, Mar 28, 2017 at 3:30 AM, Tony Anderson 
>>> wrote:
>>>
 Hi, Adam

 George Hunt's image installs Moodle 1.9.5+ (build 20090910). There was
 a major change in Moodle between 1.9 and 2+. So far as I know, XS has
 always used Moodle 1.9.

 Tony


 On 03/28/2017 12:13 PM, Adam Holt wrote:

 Can someone remind me if IIAB/XSCE 6.2 includes Moodle 3.1.x, i.e. the
 LTS version supported for 3 years until 2019, and/or what exact release is
 currently included?

Moodle Roadmap:
https://docs.moodle.org/dev/Releases#Version_support

 (Given the choice, I'm of the opinion that we should stick with Moodle
 3.1.x LTS even though 3.3 is about to be released :)



-- 
Unsung Heroes of OLPC, interviewed live @ http://unleashkids.org !
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Off-topic (sorta) Need help opening Raspberry pi case

2012-12-01 Thread Caryl Bigenho

Hi Guys...
My raspberry pi arrived yesterday and I want to put it into the little clear 
plastic case I got for it. Ed and I have both tried toopen it with no luck. We 
don't want to break it. If anyone on these lists has one, can you tell us the 
secret?
Thanks!
Caryl
P.S. Has anyone tried to run Sugar on the Raspberry pi?
P.P.S. Link to info about the case: 
http://www.newark.com/multicomp/mc-rp001-clr/enclosure-raspberry-pi-clear/dp/07W8936
P.P.P.S. I don't recommend getting your pi at Newark. They really overcharged 
me for the shipping.___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [support-gang] Off-topic (sorta) Need help opening Raspberry pi case

2012-12-01 Thread forster
some Pi ideas

http://tonyforster.blogspot.com.au/

 
 Hi Guys...
 My raspberry pi arrived yesterday and I want to put it into the little clear 
 plastic case I got for it. Ed and I have both tried toopen it with no luck. 
 We don't want to break it. If anyone on these lists has one, can you tell us 
 the secret?
 Thanks!
 Caryl
 P.S. Has anyone tried to run Sugar on the Raspberry pi?
 P.P.S. Link to info about the case: 
 http://www.newark.com/multicomp/mc-rp001-clr/enclosure-raspberry-pi-clear/dp/07W8936
 P.P.P.S. I don't recommend getting your pi at Newark. They really overcharged 
 me for the shipping.  html
 head
 style!--
 .hmmessage P
 {
 margin:0px;
 padding:0px
 }
 body.hmmessage
 {
 font-size: 10pt;
 font-family:Tahoma
 }
 --/style/head
 body class='hmmessage'div dir='ltr'
 Hi Guys...divbr/divdivMy raspberry pi arrived yesterday and I want to 
 put it into the little clear plastic case I got for it. Ed and I have both 
 tried to/divdivopen it with no luck. We don't want to break it. If anyone 
 on these lists has one, can you tell us the 
 secret?/divdivbr/divdivThanks!/divdivbr/divdivCaryl/divdivbr/divdivP.S.
  Has anyone tried to run Sugar on the Raspberry 
 pi?/divdivbr/divdivP.P.S. Link to info about the case: a 
 href=http://www.newark.com/multicomp/mc-rp001-clr/enclosure-raspberry-pi-clear/dp/07W8936;http://www.newark.com/multicomp/mc-rp001-clr/enclosure-raspberry-pi-clear/dp/07W8936/a/divdivbr/divdivP.P.P.S.
  I don't recommend getting your pi at Newark. They really overcharged me for 
 the shipping./div /div/body
 /html___
 support-gang mailing list
 support-g...@lists.laptop.org
 http://lists.laptop.org/listinfo/support-gang

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Off-topic (sorta) Need help opening Raspberry pi case

2012-12-01 Thread Chris Leonard
On Sat, Dec 1, 2012 at 3:36 PM, Caryl Bigenho cbige...@hotmail.com wrote:

 P.S. Has anyone tried to run Sugar on the Raspberry pi?

http://lmgtfy.com/?q=sugar+on+raspberry+pi

I'm surprised there were not more fruit pie sweetener hits :-)

This looks a little promising:

http://wiki.sugarlabs.org/go/Testing/Reports/Sweets_on_Raspberry_pi_armhf_raspbian
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


RE: Off-topic (sorta) Need help opening Raspberry pi case

2012-12-01 Thread Caryl Bigenho

Sounds like something worth trying... when I get the basics figured out (and 
the case open)!. 
Maybe we need a new, special version of Sugar for the Raspberry Pi of 
course, it would be called...
Sugar Pi  ;-D
Seriously though, the more devices that will run Sugar, the better! 
The book I bought about the Raspberry pi that was written by one of the 2 guys 
that designed it says it was designed with children as users in mind.
Caryl

 From: cjlhomeaddr...@gmail.com
 Date: Sat, 1 Dec 2012 17:09:22 -0500
 Subject: Re: Off-topic (sorta) Need help opening Raspberry pi case
 To: cbige...@hotmail.com
 CC: support-g...@lists.laptop.org; i...@lists.sugarlabs.org; 
 devel@lists.laptop.org
 
 On Sat, Dec 1, 2012 at 3:36 PM, Caryl Bigenho cbige...@hotmail.com wrote:
 
  P.S. Has anyone tried to run Sugar on the Raspberry pi?
 
 http://lmgtfy.com/?q=sugar+on+raspberry+pi
 
 I'm surprised there were not more fruit pie sweetener hits :-)
 
 This looks a little promising:
 
 http://wiki.sugarlabs.org/go/Testing/Reports/Sweets_on_Raspberry_pi_armhf_raspbian
  ___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Off-topic (sorta) Need help opening Raspberry pi case

2012-12-01 Thread Chris Leonard
On Sat, Dec 1, 2012 at 7:26 PM, Caryl Bigenho cbige...@hotmail.com wrote:
 Sounds like something worth trying... when I get the basics figured out (and
 the case open)!.

 Maybe we need a new, special version of Sugar for the Raspberry Pi of
 course, it would be called...

 Sugar Pi  ;-D

 Seriously though, the more devices that will run Sugar, the better!


No question that landing Sugar more or less everywhere is a goal.
Sometimes the means of doing so can be a litttle more complex that
jsut installing a build on an XO (e.g. stuff like Sweets
Distribution).

I find it hard to keep track of all of the methods and approaches
tested / employed, but I would hazard to say that an install based on
the Sweets Distribution would be Sweetie Pi.

cjl
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


need help with 'fix clock' problem...

2010-05-24 Thread F Young
Hello!

I purchased the very first versions of the XO laptop through the buy
one give one program in 2007. Although we used several right away and
they worked without any problems...we stored 6 of them away and
recently discovered that none of the screens turn on when powering up.
It appears to be the fix clock problem and since I live in
Kyrgyzstan it is too expensive to ship back to the US to get them
repaired. I would like to try to fix this myself but it would be great
if I can get more specific instructions for the following (from
http://wiki.laptop.org/go/Fix_Clock):

Using an OLPC serial adapter, connect the laptop to your personal
laptop. On the laptop's motherboard, the serial adapter should be
connected to J1. J1 is a small white connector near the wireless
module.

Since I am not familiar with computer hardware at all, here are my questions:

(1) Can you tell me specifically which OLPC serial adapter to buy if I
do NOT want to solder any wires? It would be ideal if you could send
me a link where I can purchase the exact serial adapter online.

(2) I understand that the OLPC serial adapter must be connected to the
J1 Serial Port on the XO's motherboard but I am not sure what kind
of cable is required and how to connect the serial adapter to this
port...Can you send me a photo which illustrates how to connect the
serial adapter to the J1 Serial Port? (It would also be good if you
can include a link to where I can buy the specific cable online.)

Thanks in advance for your help! We want to start training local Kyrgz
kids here but we're surprised when many of these new XO laptops could
not boot up.
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: need help with 'fix clock' problem...

2010-05-24 Thread John Watlington

Please send us a shipping address and we will send
you a couple of the serial adapters and cables.

Regards,
John

On May 23, 2010, at 11:16 PM, F Young wrote:

 Hello!
 
 I purchased the very first versions of the XO laptop through the buy
 one give one program in 2007. Although we used several right away and
 they worked without any problems...we stored 6 of them away and
 recently discovered that none of the screens turn on when powering up.
 It appears to be the fix clock problem and since I live in
 Kyrgyzstan it is too expensive to ship back to the US to get them
 repaired. I would like to try to fix this myself but it would be great
 if I can get more specific instructions for the following (from
 http://wiki.laptop.org/go/Fix_Clock):
 
 Using an OLPC serial adapter, connect the laptop to your personal
 laptop. On the laptop's motherboard, the serial adapter should be
 connected to J1. J1 is a small white connector near the wireless
 module.
 
 Since I am not familiar with computer hardware at all, here are my questions:
 
 (1) Can you tell me specifically which OLPC serial adapter to buy if I
 do NOT want to solder any wires? It would be ideal if you could send
 me a link where I can purchase the exact serial adapter online.
 
 (2) I understand that the OLPC serial adapter must be connected to the
 J1 Serial Port on the XO's motherboard but I am not sure what kind
 of cable is required and how to connect the serial adapter to this
 port...Can you send me a photo which illustrates how to connect the
 serial adapter to the J1 Serial Port? (It would also be good if you
 can include a link to where I can buy the specific cable online.)
 
 Thanks in advance for your help! We want to start training local Kyrgz
 kids here but we're surprised when many of these new XO laptops could
 not boot up.
 ___
 Devel mailing list
 Devel@lists.laptop.org
 http://lists.laptop.org/listinfo/devel

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Need Help: usb drive not visible in the journal

2009-08-01 Thread sumit singh
Hi all,

I am facing a sort of weird problem at this point. On my xo, my usb
drives are not visible in the journal. I mean the icons at the bottom
of the journal are not visible. However, to my surprise my usb
drives(pendrives) are mounted and I can access them from the terminal.
I have tested it with 3 pen drives so I don't think its due to my pen
drive. Moreover, these pen drives are not even visible in the
objectChooser widget when I invoke it through any of the xo activities
like write or paint.

Can anybody please suggest me a solution. Moreover, is there any way
to access the data in the journal through the terminal, I mean there
are many activities which saves data into the journal and I am in
severe need to access that data. Is there any way to do so. I got this
link-  
http://wiki.laptop.org/go/Copy_to_and_from_the_Journal#Copy_from_Journal_script
, but I think the names of files are hashed and I won't be able to
recognize my file in this case.

Kindly give your suggestions.

Regards,
sumit
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Sugar-devel] Need Help: usb drive not visible in the journal

2009-08-01 Thread Walter Bender
What version of Sugar are you running?

re copy-from-journal, if you use the -q flag, it will search on the
title and description fields.

copy-from-journal -q 'title of some journal object' filename

with copy-to-journal, it is it important to use a -m flag

copy to journal foo.png -m image/png

-walter


On Sat, Aug 1, 2009 at 6:46 AM, sumit singhsumit.co...@gmail.com wrote:
 Hi all,

 I am facing a sort of weird problem at this point. On my xo, my usb
 drives are not visible in the journal. I mean the icons at the bottom
 of the journal are not visible. However, to my surprise my usb
 drives(pendrives) are mounted and I can access them from the terminal.
 I have tested it with 3 pen drives so I don't think its due to my pen
 drive. Moreover, these pen drives are not even visible in the
 objectChooser widget when I invoke it through any of the xo activities
 like write or paint.

 Can anybody please suggest me a solution. Moreover, is there any way
 to access the data in the journal through the terminal, I mean there
 are many activities which saves data into the journal and I am in
 severe need to access that data. Is there any way to do so. I got this
 link-  
 http://wiki.laptop.org/go/Copy_to_and_from_the_Journal#Copy_from_Journal_script
 , but I think the names of files are hashed and I won't be able to
 recognize my file in this case.

 Kindly give your suggestions.

 Regards,
 sumit
 ___
 Sugar-devel mailing list
 sugar-de...@lists.sugarlabs.org
 http://lists.sugarlabs.org/listinfo/sugar-devel




-- 
Walter Bender
Sugar Labs
http://www.sugarlabs.org
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Sugar-devel] Need Help: usb drive not visible in the journal

2009-08-01 Thread sumit singh
Hello sir,

Thank You for your reply.

On Sat, Aug 1, 2009 at 5:44 PM, Walter Benderwalter.ben...@gmail.com wrote:
 What version of Sugar are you running?

I am on sugar 0.82 ( 767 build). It was working fine since the last
4-5 months but the problem started suddenly yesterday.

 re copy-from-journal, if you use the -q flag, it will search on the
 title and description fields.

 copy-from-journal -q 'title of some journal object' filename

 with copy-to-journal, it is it important to use a -m flag

 copy to journal foo.png -m image/png

Yes, this should be of gr8 help. Would soon be trying it on the xo.

Regards,
sumit
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Server-devel] A few F9 upgrade things I need help with...

2008-09-09 Thread Jerry Vonau
Martin Langhoff wrote:
 As part of the XS upgrade, I've ended up caught with a number of F9
 oddities -- none of them a complete blocker, but definitely rought
 edges...
 
 - Cannot include beecrypt in Pungi/Revisor build - this is probably a
 bug worthy of filing in BZ but needs a bit of diagnosys.
   http://dev.laptop.org/ticket/8363
 
 - Anaconda conflicts with xs-config - Filed as BZ 461550
   http://dev.laptop.org/ticket/8366
 
 - Anaconda crash during install with USB-disk-based ks.cfg BZ 461453 -
 this probably affects all USB-disk based installs.
 
 - Anaconda: Install from USB disk: only ISO picked up BZ 461548
 
Good Luck I tried, check the anaconda ML archives. Some where I have 
a working anaconda rpm that fixes that. If its OK to use a re-rolled 
version anaconda with XS I might be able to overcome that.

Jerry
___
Server-devel mailing list
[EMAIL PROTECTED]
http://lists.laptop.org/listinfo/server-devel


[Server-devel] A few F9 upgrade things I need help with...

2008-09-08 Thread Martin Langhoff
As part of the XS upgrade, I've ended up caught with a number of F9
oddities -- none of them a complete blocker, but definitely rought
edges...

- Cannot include beecrypt in Pungi/Revisor build - this is probably a
bug worthy of filing in BZ but needs a bit of diagnosys.
  http://dev.laptop.org/ticket/8363

- Anaconda conflicts with xs-config - Filed as BZ 461550
  http://dev.laptop.org/ticket/8366

- Anaconda crash during install with USB-disk-based ks.cfg BZ 461453 -
this probably affects all USB-disk based installs.

- Anaconda: Install from USB disk: only ISO picked up BZ 461548

- Anaconda: Install from USB disk: Awkward to provide a ks.cfg BZ 461549

All of these are - I think - worthwhile to whack for the
ease-of-install experience with Fedora and the XS...

cheers,



m
-- 
 [EMAIL PROTECTED]
 [EMAIL PROTECTED] -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


need help troubleshooting possible jffs2 problem

2008-09-02 Thread Bryan Berry
I am having w/ one of the XO's from a pilot school.

I cannot copy large files from a USB key to the local SSD. The SSD mtd0
is only 47% full. I am trying to transfer a 156 MB file. The XO crashes
when I try to copy the file locally. 

The XO works fine otherwise. I have run test-all and seen no errors. I
have reflashed the OS image (703) and still encounter the problem. The
reflashing process did not display a larger than normal # of bad blocks,
probably only 6-7.

This leads me to think there might be an issue w/ the underlying jffs2
filesystem.

Can someone help me answer the following questions?

1. When I reflash the OS using copy-nand does it reset the filesystem?
2. How can I troubleshoot filesystem issues in general on the XO?

thanks

Bryan
OLE Nepal

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Server-devel] Need help: mounting usb devices on headless machines

2008-08-11 Thread James Cameron
On Mon, Aug 11, 2008 at 12:49:06PM +1200, Martin Langhoff wrote:
 Well, it *seems* that I cannot get a bell to sound on any of the
 systems I can get my hands on today. [...]

Systems that route the PC speaker into the mixer will also need
alsamixer settings changed accordingly.

-- 
James Cameronmailto:[EMAIL PROTECTED] http://quozl.netrek.org/
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Server-devel] Need help: mounting usb devices on headless machines

2008-08-11 Thread James Cameron
On Mon, Aug 11, 2008 at 12:49:06PM +1200, Martin Langhoff wrote:
 Well, it *seems* that I cannot get a bell to sound on any of the
 systems I can get my hands on today. [...]

Systems that route the PC speaker into the mixer will also need
alsamixer settings changed accordingly.

-- 
James Cameronmailto:[EMAIL PROTECTED] http://quozl.netrek.org/
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] Need help: mounting usb devices on headless machines

2008-08-11 Thread Rahul Sundaram
Martin Langhoff wrote:
 On Thu, Aug 7, 2008 at 9:19 PM, Martin Langhoff
 [EMAIL PROTECTED] wrote:
   
 FWIW, I've imported the history into git, made some minor changes and
 it installs and works on F7.

 git
  git://dev.laptop.org/users/martin/usbmount.git

 gitweb
  http://dev.laptop.org/git?p=users/martin/usbmount.git;a=summary
 

 Right, Makefile and spec file in the repo linked above, initial SRPM right 
 here.
 http://fedora.laptop.org/xs/testing/olpc/7/source/SRPMS/usbmount-0.15.4.olpc-1.xs7.src.rpm

 It's a trivial rpm, review  patches welcome
Are you going to submit it for review in Fedora?

Rahul

___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] Need help: mounting usb devices on headless machines

2008-08-10 Thread Martin Langhoff
On Thu, Aug 7, 2008 at 6:52 PM, James Cameron [EMAIL PROTECTED] wrote:
 Don't know about Fedoristas, but on Debian and derivatives this is what
 I do for a backup disk that is identified by UUID and then backed up to
 ... all when plugged in ... beep ... wait for rsync ... beep beep ...
 pull it out.
...
echo -en '\007'  /dev/tty1

Well, it *seems* that I cannot get a bell to sound on any of the
systems I can get my hands on today. 2 XS (F7, based) desktop
machines, 3 different laptops (running F9, Hardy), no bell on
ambiguous autocompletion, no audible response to echo -en '\007' on
any tty. Nothing obvious in termcap/terminfo (I'm not too handy with
those but no 'vb' that I can see).

Hmmm. pcspkr.ko is loaded in all of them.

And the web is full of advise on how to *disable* it, so I guess
modern linuxen have disabled it en-masse, using some trick I can't
spot right now. The obvious place is termcap/terminfo, but nothing
there... Ah, grumble.

ideas?




m
-- 
 [EMAIL PROTECTED]
 [EMAIL PROTECTED] -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Need help: mounting usb devices on headless machines

2008-08-07 Thread Martin Langhoff
Fedoristas in the crowd,

I am trying to find a tool that allows me to

 - automount usb devices when they are plugged in (via udev/hal)
 - would be nice to support removable devices
 - trigger an associated script on mount
 - all on a headless server!

There is no udev/hal automounter that works on headless servers
currently shipping on Fedora. Ivman is packaged, but not shipping
currently (dead upstream, very cumbersome config). Working with the
lvman config files is _not_ fun, and not modular at all - if several
school server pacakges want different things, it'll be a mess.

I have found an alternative that I like more, usbmount, which seems to
work, is trivial to configure, provides the subset of Ivman that I
need,  and makes it simple for other packages to drop hook scripts
into place via /etc/usbmount/mount.d . It doesn't have an active
maintainer though.

So I need some help :-) and it's not too complex.

Option one - point me to something that works and is maintained -- if
you know of a good reliable tool that I missed, I want to know. Can
you help me configure it for this task?

Option two - help me package  tweak usbmount for F7 and F9. The
codebase is *tiny*, we can carry it.

Option three - you are very keen on wrangling ivman's complexity and
baroque xml. Grand! Let's teach it to do /etc/ivman/conf.d/ :-)

Option four: anyone with a better plan?

I'll probably start chipping away at #2 tomorrow...

cheers,



m
-- 
 [EMAIL PROTECTED]
 [EMAIL PROTECTED] -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Server-devel] Need help: mounting usb devices on headless machines

2008-08-07 Thread James Cameron
Don't know about Fedoristas, but on Debian and derivatives this is what
I do for a backup disk that is identified by UUID and then backed up to
... all when plugged in ... beep ... wait for rsync ... beep beep ...
pull it out.


/etc/udev/rules.d/010_local.rules:
# backup drive a 2008-05-02
# (activates on every new block device)
ACTION==add, SUBSYSTEM==block, BUS==usb, 
RUN=/usr/local/bin/add-block-usb

/usr/local/bin/add-block-usb:
#!/bin/sh
set -e

if [ -z ${ID_FS_UUID} ]; then
exit
fi

function backup {
exec 21  /tmp/backup-${ID_FS_UUID}.log
echo -en '\007'  /dev/tty1
mkdir -p /media/backups/${ID_FS_UUID} 
mount -v /dev/disk/by-uuid/${ID_FS_UUID} /media/backups/${ID_FS_UUID} 
cd /a
rsync --archive --verbose --delete-before \
${*} /media/backups/${ID_FS_UUID} 
umount -v /media/backups/${ID_FS_UUID} 
echo -en '\007'  /dev/tty1
sleep 0.4
echo -en '\007'  /dev/tty1
}

case ${ID_FS_UUID} in
2d1418da-0b75-4676-89a2-dae422ffa4f2)
backup backups
break
;;
*)
touch /tmp/backup-${ID_FS_UUID}.ignored
;;
esac

-- 
James Cameronmailto:[EMAIL PROTECTED] http://quozl.netrek.org/
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Server-devel] Need help: mounting usb devices on headless machines

2008-08-07 Thread Martin Langhoff
On Thu, Aug 7, 2008 at 6:52 PM, James Cameron [EMAIL PROTECTED] wrote:
 Don't know about Fedoristas, but on Debian and derivatives this is what

usbmount is a slightly longer and nicer version of that, which will

 - mount various partitions if various partitions are available
 - run scripts from a foo.d directory using run-parts
 - various options including logging

See for yourself here -
http://svn.debian.org/wsvn/usbmount/trunk/usbmount/usbmount?op=filerev=0sc=0

Having it as a middle-tier does a couple of things
 - insulates the other packages from HAL/udev changes. Is it
udev_volume_id or vol_id?
 - each FS get mounted once and but  N scripts from different packages
can be listening for that mount event

my plan is to add beeps too, with a special beeping pattern if
something goes wrong. Time for a learn morse-code activity on the
XO?

cheers,



m
-- 
 [EMAIL PROTECTED]
 [EMAIL PROTECTED] -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help: mounting usb devices on headless machines

2008-08-07 Thread Martin Langhoff
On Thu, Aug 7, 2008 at 6:37 PM, Martin Langhoff
[EMAIL PROTECTED] wrote:
 Option two - help me package  tweak usbmount for F7 and F9. The
 codebase is *tiny*, we can carry it.
...
 I'll probably start chipping away at #2 tomorrow...

FWIW, I've imported the history into git, made some minor changes and
it installs and works on F7.

git
  git://dev.laptop.org/users/martin/usbmount.git

gitweb
  http://dev.laptop.org/git?p=users/martin/usbmount.git;a=summary

Now, about those beeps...


m
-- 
 [EMAIL PROTECTED]
 [EMAIL PROTECTED] -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help: mounting usb devices on headless machines

2008-08-07 Thread Martin Langhoff
On Thu, Aug 7, 2008 at 9:19 PM, Martin Langhoff
[EMAIL PROTECTED] wrote:
 FWIW, I've imported the history into git, made some minor changes and
 it installs and works on F7.

 git
  git://dev.laptop.org/users/martin/usbmount.git

 gitweb
  http://dev.laptop.org/git?p=users/martin/usbmount.git;a=summary

Right, Makefile and spec file in the repo linked above, initial SRPM right here.
http://fedora.laptop.org/xs/testing/olpc/7/source/SRPMS/usbmount-0.15.4.olpc-1.xs7.src.rpm

It's a trivial rpm, review  patches welcome.

cheers,


m
-- 
 [EMAIL PROTECTED]
 [EMAIL PROTECTED] -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help: mounting usb devices on headless machines

2008-08-07 Thread Martin Langhoff
On Fri, Aug 8, 2008 at 12:18 PM, Rahul Sundaram
[EMAIL PROTECTED] wrote:
 Are you going to submit it for review in Fedora?

I don't think so - as I mentioned before, upstream is mostly dead, so
I doubt it'll be accepted. Trivial as it is, I am happy to support it
for as long as we have a use for it within XS. If something better
comes up, we'll switch in a blink.

Supporting it for Fedora is a wider (more varied uses) and longer timeframe.

cheers,


m
-- 
 [EMAIL PROTECTED]
 [EMAIL PROTECTED] -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help: mounting usb devices on headless machines

2008-08-07 Thread Rahul Sundaram
Martin Langhoff wrote:
 On Thu, Aug 7, 2008 at 9:19 PM, Martin Langhoff
 [EMAIL PROTECTED] wrote:
   
 FWIW, I've imported the history into git, made some minor changes and
 it installs and works on F7.

 git
  git://dev.laptop.org/users/martin/usbmount.git

 gitweb
  http://dev.laptop.org/git?p=users/martin/usbmount.git;a=summary
 

 Right, Makefile and spec file in the repo linked above, initial SRPM right 
 here.
 http://fedora.laptop.org/xs/testing/olpc/7/source/SRPMS/usbmount-0.15.4.olpc-1.xs7.src.rpm

 It's a trivial rpm, review  patches welcome
Are you going to submit it for review in Fedora?

Rahul

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Server-devel] Need help: mounting usb devices on headless machines

2008-08-07 Thread James Cameron
Don't know about Fedoristas, but on Debian and derivatives this is what
I do for a backup disk that is identified by UUID and then backed up to
... all when plugged in ... beep ... wait for rsync ... beep beep ...
pull it out.


/etc/udev/rules.d/010_local.rules:
# backup drive a 2008-05-02
# (activates on every new block device)
ACTION==add, SUBSYSTEM==block, BUS==usb, 
RUN=/usr/local/bin/add-block-usb

/usr/local/bin/add-block-usb:
#!/bin/sh
set -e

if [ -z ${ID_FS_UUID} ]; then
exit
fi

function backup {
exec 21  /tmp/backup-${ID_FS_UUID}.log
echo -en '\007'  /dev/tty1
mkdir -p /media/backups/${ID_FS_UUID} 
mount -v /dev/disk/by-uuid/${ID_FS_UUID} /media/backups/${ID_FS_UUID} 
cd /a
rsync --archive --verbose --delete-before \
${*} /media/backups/${ID_FS_UUID} 
umount -v /media/backups/${ID_FS_UUID} 
echo -en '\007'  /dev/tty1
sleep 0.4
echo -en '\007'  /dev/tty1
}

case ${ID_FS_UUID} in
2d1418da-0b75-4676-89a2-dae422ffa4f2)
backup backups
break
;;
*)
touch /tmp/backup-${ID_FS_UUID}.ignored
;;
esac

-- 
James Cameronmailto:[EMAIL PROTECTED] http://quozl.netrek.org/
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] Need help: mounting usb devices on headless machines

2008-08-07 Thread David Van Assche
The LTSP version of Fedora does automounting of drives (usb, floppy,
cd)... maybe take a look at the code used to implement it...

David

On Thu, Aug 7, 2008 at 3:04 PM, Martin Langhoff
[EMAIL PROTECTED] wrote:
 On Thu, Aug 7, 2008 at 6:37 PM, Martin Langhoff
 [EMAIL PROTECTED] wrote:
 Option two - help me package  tweak usbmount for F7 and F9. The
 codebase is *tiny*, we can carry it.
 ...
 I'll probably start chipping away at #2 tomorrow...

 FWIW, I've imported the history into git, made some minor changes and
 it installs and works on F7.

 git
  git://dev.laptop.org/users/martin/usbmount.git

 gitweb
  http://dev.laptop.org/git?p=users/martin/usbmount.git;a=summary

 Now, about those beeps...


 m
 --
  [EMAIL PROTECTED]
  [EMAIL PROTECTED] -- School Server Architect
  - ask interesting questions
  - don't get distracted with shiny stuff - working code first
  - http://wiki.laptop.org/go/User:Martinlanghoff
 ___
 Server-devel mailing list
 Server-devel@lists.laptop.org
 http://lists.laptop.org/listinfo/server-devel

___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] Need help: mounting usb devices on headless machines

2008-08-07 Thread Martin Langhoff
On Thu, Aug 7, 2008 at 9:19 PM, Martin Langhoff
[EMAIL PROTECTED] wrote:
 FWIW, I've imported the history into git, made some minor changes and
 it installs and works on F7.

 git
  git://dev.laptop.org/users/martin/usbmount.git

 gitweb
  http://dev.laptop.org/git?p=users/martin/usbmount.git;a=summary

Right, Makefile and spec file in the repo linked above, initial SRPM right here.
http://fedora.laptop.org/xs/testing/olpc/7/source/SRPMS/usbmount-0.15.4.olpc-1.xs7.src.rpm

It's a trivial rpm, review  patches welcome.

cheers,


m
-- 
 [EMAIL PROTECTED]
 [EMAIL PROTECTED] -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Need help creating .xo file

2008-06-04 Thread shivaprasad javali
Hi All ,
  I was wondering if you could help me out with this.

 I got the activity working fine on the OLPC. Now I want to create a
.xo file for my activity so that I can install the activity on other XO's.
My activity structure is as follows:
-activity --has the .info file and the icon
-bin  -- has a shell script and the exe which i have to run
-lib  -- has the libs which my application is dependent on
- MANIFEST file

There is a shell script in the bin folder which I have included in the exec
tag in activity.info.

I created the activity bundle according to the information in the post
http://olpcnews.com/forum/index.php?topic=1555.0 .
I have named my .xo file name.activity.xo

If I unzip the .xo in the Activities folder and then restart the X-server it
gets installed and I get the icon in the activity tray.

I tried installing it by copying the .xo to a thumb drive and then running
sugar-install-bundle on the XO but it gave me a DBUS timeout error. I also
tried to install it through the browse activity as given in
http://wiki.laptop.org/go/Activities#Manual_installation and through the
Journal without success.

Can you figure out where I am going wrong??

Thanks
Shivaprasad
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help creating .xo file

2008-06-04 Thread Bert Freudenberg
On 04.06.2008, at 08:11, shivaprasad javali wrote:

 Hi All ,
   I was wondering if you could help me out with this.

  I got the activity working fine on the OLPC. Now I want to  
 create a .xo file for my activity so that I can install the activity  
 on other XO's. My activity structure is as follows:
 -activity --has the .info file and the icon
 -bin  -- has a shell script and the exe which i have to run
 -lib  -- has the libs which my application is dependent on
 - MANIFEST file

 There is a shell script in the bin folder which I have included in  
 the exec tag in activity.info.

 I created the activity bundle according to the information in the  
 post http://olpcnews.com/forum/index.php?topic=1555.0 .
 I have named my .xo file name.activity.xo

 If I unzip the .xo in the Activities folder and then restart the X- 
 server it gets installed and I get the icon in the activity tray.

 I tried installing it by copying the .xo to a thumb drive and then  
 running sugar-install-bundle on the XO but it gave me a DBUS timeout  
 error. I also tried to install it through the browse activity as  
 given in http://wiki.laptop.org/go/Activities#Manual_installation  
 and through the Journal without success.

 Can you figure out where I am going wrong??


Not without logs. See

http://wiki.laptop.org/go/Attaching_Sugar_Logs_to_Tickets

- Bert -


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help creating .xo file

2008-06-04 Thread Tomeu Vizoso
2008/6/4 shivaprasad javali [EMAIL PROTECTED]:

 Can you figure out where I am going wrong??

What's your problem? The bundle seems to install correctly as its icon
appears in the shell. Is the problem that the activity doesn't start?
Logs will help in any case, as Bert said.

Regards,

Tomeu
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help creating .xo file

2008-06-04 Thread shivaprasad javali
The Bundle installs correctly only when I unzip it manually and then restart
the X-server. I want to do this through sugar-install-bundle or through
browse activity or through Journal. None of which seem to work.

Anyway when I tried to install through the sugar-install-bundle command It
failed giving a DBus timeout. Here are the log files I got.

Thanks
Shivaprasad

P.S: I didnt which log file would really be useful to you guys so I attached
all of them which I thought had some relevant information.

On Wed, Jun 4, 2008 at 5:12 PM, Tomeu Vizoso [EMAIL PROTECTED] wrote:

 2008/6/4 shivaprasad javali [EMAIL PROTECTED]:
 
  Can you figure out where I am going wrong??

 What's your problem? The bundle seems to install correctly as its icon
 appears in the shell. Is the problem that the activity doesn't start?
 Logs will help in any case, as Bert said.

 Regards,

 Tomeu

1212594090.268322 INFO root: Starting Datastore /home/olpc/.sugar/default/datastore
1212594090.300597 DEBUG root: IndexManager.connect()
1212594090.333430 DEBUG root: IndexManager.flush: True 0
1212594098.207695 DEBUG root: IndexManager.connect()
1212594098.229774 ERROR root: Error while trying to load mount point /media/RED_DEVIL/.olpc.store: Db block overwritten - are there multiple writers?. Will try to renitialize and load again.
1212594098.247106 DEBUG root: IndexManager.connect()
1212594099.492161 DEBUG root: IndexManager.flush: True 0
1212594099.963942 DEBUG root: Content.suggestName: dbus.String(u'WeDo.activity.xo') 'xo'
1212594099.988344 DEBUG root: FileBackingStore._targetFile: '62f2e012-5c7e-4f72-95e9-56f2b1c7fe76' u'WeDo.activity.xo' None None
1212594101.686014 INFO org.sugar.datastore.xapianindex: created e67e8fd4-7cc6-43ef-a006-0ebb96bcd333:1.0
1212594101.688182 DEBUG root: IndexManager.flush: False 0
1212594101.982632 INFO org.sugar.datastore.xapianindex: updated e67e8fd4-7cc6-43ef-a006-0ebb96bcd333:1.0
1212594102.022779 DEBUG root: IndexManager.flush: False 1
1212594102.089718 INFO org.sugar.datastore.xapianindex: created 95900480-ec3c-495f-8176-276035b01085:1.0
1212594102.091860 DEBUG root: IndexManager.flush: False 2
1212594102.294715 INFO org.sugar.datastore.xapianindex: updated 95900480-ec3c-495f-8176-276035b01085:1.0
1212594102.297006 DEBUG root: IndexManager.flush: False 3
1212594102.505951 INFO org.sugar.datastore.xapianindex: created 7e2a419f-2ce7-47a1-8290-2b66d595c302:1.0
1212594102.509034 DEBUG root: IndexManager.flush: False 4
1212594102.617162 INFO org.sugar.datastore.xapianindex: updated 7e2a419f-2ce7-47a1-8290-2b66d595c302:1.0
1212594102.619336 DEBUG root: IndexManager.flush: False 5
1212594102.728013 INFO org.sugar.datastore.xapianindex: created 7843b2ed-4c8d-41bb-bdfd-99638e3c709b:1.0
1212594102.730134 DEBUG root: IndexManager.flush: False 6
1212594102.821709 INFO org.sugar.datastore.xapianindex: updated 7843b2ed-4c8d-41bb-bdfd-99638e3c709b:1.0
1212594102.823852 DEBUG root: IndexManager.flush: False 7
1212594102.962378 INFO org.sugar.datastore.xapianindex: created 507f7e86-0d97-4cd7-bcba-6c9aa46585a4:1.0
1212594102.964514 DEBUG root: IndexManager.flush: False 8
1212594103.032338 INFO org.sugar.datastore.xapianindex: updated 507f7e86-0d97-4cd7-bcba-6c9aa46585a4:1.0
1212594103.034422 DEBUG root: IndexManager.flush: False 9
1212594103.153525 INFO org.sugar.datastore.xapianindex: created 99937bd5-548c-476f-a3db-982fbba85513:1.0
1212594103.155660 DEBUG root: IndexManager.flush: False 10
1212594103.229656 INFO org.sugar.datastore.xapianindex: updated 99937bd5-548c-476f-a3db-982fbba85513:1.0
1212594103.232318 DEBUG root: IndexManager.flush: False 11
1212594103.310825 INFO org.sugar.datastore.xapianindex: created 2d2f3e8b-63a3-4575-9013-0493d595f27c:1.0
1212594103.312964 DEBUG root: IndexManager.flush: False 12
1212594103.367179 INFO org.sugar.datastore.xapianindex: updated 2d2f3e8b-63a3-4575-9013-0493d595f27c:1.0
1212594103.369309 DEBUG root: IndexManager.flush: False 13
1212594103.444890 INFO org.sugar.datastore.xapianindex: created 5e60098d-0228-46f5-9ab1-4ec4bf9c0aeb:1.0
1212594103.447130 DEBUG root: IndexManager.flush: False 14
1212594103.508198 INFO org.sugar.datastore.xapianindex: updated 5e60098d-0228-46f5-9ab1-4ec4bf9c0aeb:1.0
1212594103.510326 DEBUG root: IndexManager.flush: False 15
1212594103.595810 INFO org.sugar.datastore.xapianindex: created 3de8c1ae-010d-4a6a-9d16-40f992b15bd9:1.0
1212594103.597936 DEBUG root: IndexManager.flush: False 16
1212594103.695864 INFO org.sugar.datastore.xapianindex: updated 3de8c1ae-010d-4a6a-9d16-40f992b15bd9:1.0
1212594103.698615 DEBUG root: IndexManager.flush: False 17
1212594103.776684 INFO org.sugar.datastore.xapianindex: created a1d20289-075c-4309-a413-aad249027ad6:1.0
1212594103.778820 DEBUG root: IndexManager.flush: False 18
1212594103.847745 INFO org.sugar.datastore.xapianindex: updated a1d20289-075c-4309-a413-aad249027ad6:1.0
1212594103.849883 DEBUG root: IndexManager.flush: False 19
1212594103.908298 INFO org.sugar.datastore.xapianindex: created 

Re: Need help creating .xo file

2008-06-04 Thread Tomeu Vizoso
Could you upload your .xo somewhere so I can give it a look?

Thanks,

Tomeu

On Wed, Jun 4, 2008 at 3:07 PM, shivaprasad javali [EMAIL PROTECTED] wrote:
 The Bundle installs correctly only when I unzip it manually and then restart
 the X-server. I want to do this through sugar-install-bundle or through
 browse activity or through Journal. None of which seem to work.

 Anyway when I tried to install through the sugar-install-bundle command It
 failed giving a DBus timeout. Here are the log files I got.

 Thanks
 Shivaprasad

 P.S: I didnt which log file would really be useful to you guys so I attached
 all of them which I thought had some relevant information.

 On Wed, Jun 4, 2008 at 5:12 PM, Tomeu Vizoso [EMAIL PROTECTED] wrote:

 2008/6/4 shivaprasad javali [EMAIL PROTECTED]:
 
  Can you figure out where I am going wrong??

 What's your problem? The bundle seems to install correctly as its icon
 appears in the shell. Is the problem that the activity doesn't start?
 Logs will help in any case, as Bert said.

 Regards,

 Tomeu


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help creating .xo file

2008-06-04 Thread Tomeu Vizoso
So can you replace the proprietary code from the bundle, see if you
have the same problem then upload?

Tomeu

On Wed, Jun 4, 2008 at 4:31 PM, shivaprasad javali [EMAIL PROTECTED] wrote:
 Sorry Tomeu. Its a propreitary product .So cannot upload the.xo.

 On Wed, Jun 4, 2008 at 7:51 PM, Tomeu Vizoso [EMAIL PROTECTED] wrote:

 Could you upload your .xo somewhere so I can give it a look?

 Thanks,

 Tomeu

 On Wed, Jun 4, 2008 at 3:07 PM, shivaprasad javali [EMAIL PROTECTED]
 wrote:
  The Bundle installs correctly only when I unzip it manually and then
  restart
  the X-server. I want to do this through sugar-install-bundle or through
  browse activity or through Journal. None of which seem to work.
 
  Anyway when I tried to install through the sugar-install-bundle command
  It
  failed giving a DBus timeout. Here are the log files I got.
 
  Thanks
  Shivaprasad
 
  P.S: I didnt which log file would really be useful to you guys so I
  attached
  all of them which I thought had some relevant information.
 
  On Wed, Jun 4, 2008 at 5:12 PM, Tomeu Vizoso [EMAIL PROTECTED]
  wrote:
 
  2008/6/4 shivaprasad javali [EMAIL PROTECTED]:
  
   Can you figure out where I am going wrong??
 
  What's your problem? The bundle seems to install correctly as its icon
  appears in the shell. Is the problem that the activity doesn't start?
  Logs will help in any case, as Bert said.
 
  Regards,
 
  Tomeu
 
 


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help creating .xo file

2008-06-04 Thread shivaprasad javali
ok. I will try that.

Thanks
Shivaprasad

On Wed, Jun 4, 2008 at 8:05 PM, Tomeu Vizoso [EMAIL PROTECTED] wrote:

 So can you replace the proprietary code from the bundle, see if you
 have the same problem then upload?

 Tomeu

 On Wed, Jun 4, 2008 at 4:31 PM, shivaprasad javali [EMAIL PROTECTED]
 wrote:
  Sorry Tomeu. Its a propreitary product .So cannot upload the.xo.
 
  On Wed, Jun 4, 2008 at 7:51 PM, Tomeu Vizoso [EMAIL PROTECTED]
 wrote:
 
  Could you upload your .xo somewhere so I can give it a look?
 
  Thanks,
 
  Tomeu
 
  On Wed, Jun 4, 2008 at 3:07 PM, shivaprasad javali [EMAIL PROTECTED]
  wrote:
   The Bundle installs correctly only when I unzip it manually and then
   restart
   the X-server. I want to do this through sugar-install-bundle or
 through
   browse activity or through Journal. None of which seem to work.
  
   Anyway when I tried to install through the sugar-install-bundle
 command
   It
   failed giving a DBus timeout. Here are the log files I got.
  
   Thanks
   Shivaprasad
  
   P.S: I didnt which log file would really be useful to you guys so I
   attached
   all of them which I thought had some relevant information.
  
   On Wed, Jun 4, 2008 at 5:12 PM, Tomeu Vizoso [EMAIL PROTECTED]
   wrote:
  
   2008/6/4 shivaprasad javali [EMAIL PROTECTED]:
   
Can you figure out where I am going wrong??
  
   What's your problem? The bundle seems to install correctly as its
 icon
   appears in the shell. Is the problem that the activity doesn't start?
   Logs will help in any case, as Bert said.
  
   Regards,
  
   Tomeu
  
  
 
 

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Need help installing an activity

2008-06-02 Thread shivaprasad javali
Hi,

 I prepared a .xo file for my application to be installed on the XO. I
created the .xo file by running the zip command on the activity folder. Now
if I have to install the activity through a thumb drive, I go to the
terminal move to Activities folder and then unzip the .xo file there. Then I
have to restart the xserver for my activity to show up on the home page.


Is there any way I can install the activity like this without having to
restart the xserver or restart the xserver implicitly??

Also can I do the installation through the journal if I have the .xo
file on a thumb drive??

Thanks
Shivaprasad
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help installing an activity

2008-06-02 Thread Simon Schampijer

http://wiki.laptop.org/go/Activities#Manual_installation

from Browse: http://wiki.laptop.org/go/Browse#Install_an_activity

Best,
Simon


shivaprasad javali wrote:
 Hi,
 
  I prepared a .xo file for my application to be installed on the XO. I
 created the .xo file by running the zip command on the activity folder. Now
 if I have to install the activity through a thumb drive, I go to the
 terminal move to Activities folder and then unzip the .xo file there. Then I
 have to restart the xserver for my activity to show up on the home page.
 
 
 Is there any way I can install the activity like this without having to
 restart the xserver or restart the xserver implicitly??
 
 Also can I do the installation through the journal if I have the .xo
 file on a thumb drive??
 
 Thanks
 Shivaprasad
 
 
 
 
 
 ___
 Devel mailing list
 Devel@lists.laptop.org
 http://lists.laptop.org/listinfo/devel

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help installing an activity

2008-06-02 Thread Tomeu Vizoso
2008/6/2 shivaprasad javali [EMAIL PROTECTED]:
 Sorry didnt observe it properly. It is a D-BUS timeout. I am runing the
 command from the terminal activity on an actual XO.

Which version of the software are you using? Some old versions would
give you that error if the bundle was malformed.

As always, logs would help:

http://wiki.laptop.org/go/Attaching_Sugar_Logs_to_Tickets

Regards,

Tomeu
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help installing an activity

2008-06-02 Thread shivaprasad javali
Hi Bert,

  I tried sugar-install-bundle its giving me an error timeout in the
network connection. Do i have to be connected in the network before I can
run that command??

 Also i tried Simon's suggestion in the follow up mail. When i try
to install it through the browse activity it just stays on that page for a
long time with a waiting mouse cursor and then abruptly quits without
installing the activity. Also i cannot find an entry for that download in
the journal

 Can you think of anything that i might be doing wrong??  When I use
unzip to unzip the .xo file in the appropriate directory and restart the
xserver it works fine.

On Mon, Jun 2, 2008 at 2:10 PM, Bert Freudenberg [EMAIL PROTECTED]
wrote:


 On 02.06.2008, at 10:29, shivaprasad javali wrote:

  Hi,

 I prepared a .xo file for my application to be installed on the XO. I
 created the .xo file by running the zip command on the activity folder. Now
 if I have to install the activity through a thumb drive, I go to the
 terminal move to Activities folder and then unzip the .xo file there. Then I
 have to restart the xserver for my activity to show up on the home page.


Is there any way I can install the activity like this without having to
 restart the xserver or restart the xserver implicitly??


 Yes. Use sugar-install-bundle /path/to/bundle.xo from the Terminal
 activity, which unzips the activity and tells the Sugar shell that it was
 installed.

 Also can I do the installation through the journal if I have the .xo
 file on a thumb drive??



 Yes. Clicking the .xo in the Journal view of your USB drive will install
 it.

 - Bert -



___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help installing an activity

2008-06-02 Thread Bert Freudenberg
Are you sure it is a network timeout, not a D-Bus timeout?

Also, the script will not work from the console, only from the  
Terminal activity.

If this does not work, please open a bug report.

- Bert -


On 02.06.2008, at 12:23, shivaprasad javali wrote:

 Hi Bert,

   I tried sugar-install-bundle its giving me an error  
 timeout in the network connection. Do i have to be connected in the  
 network before I can run that command??

  Also i tried Simon's suggestion in the follow up mail. When  
 i try to install it through the browse activity it just stays on  
 that page for a long time with a waiting mouse cursor and then  
 abruptly quits without installing the activity. Also i cannot find  
 an entry for that download in the journal

  Can you think of anything that i might be doing wrong??  When I  
 use unzip to unzip the .xo file in the appropriate directory and  
 restart the xserver it works fine.

 On Mon, Jun 2, 2008 at 2:10 PM, Bert Freudenberg  
 [EMAIL PROTECTED] wrote:

 On 02.06.2008, at 10:29, shivaprasad javali wrote:

 Hi,

 I prepared a .xo file for my application to be installed on the  
 XO. I created the .xo file by running the zip command on the  
 activity folder. Now if I have to install the activity through a  
 thumb drive, I go to the terminal move to Activities folder and then  
 unzip the .xo file there. Then I have to restart the xserver for my  
 activity to show up on the home page.


Is there any way I can install the activity like this without  
 having to restart the xserver or restart the xserver implicitly??

 Yes. Use sugar-install-bundle /path/to/bundle.xo from the Terminal  
 activity, which unzips the activity and tells the Sugar shell that  
 it was installed.


Also can I do the installation through the journal if I have  
 the .xo file on a thumb drive??


 Yes. Clicking the .xo in the Journal view of your USB drive will  
 install it.

 - Bert -






___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help installing an activity

2008-06-02 Thread Bert Freudenberg

On 02.06.2008, at 10:29, shivaprasad javali wrote:

 Hi,

  I prepared a .xo file for my application to be installed on the  
 XO. I created the .xo file by running the zip command on the  
 activity folder. Now if I have to install the activity through a  
 thumb drive, I go to the terminal move to Activities folder and then  
 unzip the .xo file there. Then I have to restart the xserver for my  
 activity to show up on the home page.


 Is there any way I can install the activity like this without  
 having to restart the xserver or restart the xserver implicitly??

Yes. Use sugar-install-bundle /path/to/bundle.xo from the Terminal  
activity, which unzips the activity and tells the Sugar shell that it  
was installed.

 Also can I do the installation through the journal if I have  
 the .xo file on a thumb drive??


Yes. Clicking the .xo in the Journal view of your USB drive will  
install it.

- Bert -


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help installing an activity

2008-06-02 Thread shivaprasad javali
Sorry didnt observe it properly. It is a D-BUS timeout. I am runing the
command from the terminal activity on an actual XO.

On Mon, Jun 2, 2008 at 4:06 PM, Bert Freudenberg [EMAIL PROTECTED]
wrote:

 Are you sure it is a network timeout, not a D-Bus timeout?

 Also, the script will not work from the console, only from the Terminal
 activity.

 If this does not work, please open a bug report.

 - Bert -



 On 02.06.2008, at 12:23, shivaprasad javali wrote:

  Hi Bert,

  I tried sugar-install-bundle its giving me an error timeout in
 the network connection. Do i have to be connected in the network before I
 can run that command??

 Also i tried Simon's suggestion in the follow up mail. When i try
 to install it through the browse activity it just stays on that page for a
 long time with a waiting mouse cursor and then abruptly quits without
 installing the activity. Also i cannot find an entry for that download in
 the journal

 Can you think of anything that i might be doing wrong??  When I use
 unzip to unzip the .xo file in the appropriate directory and restart the
 xserver it works fine.

 On Mon, Jun 2, 2008 at 2:10 PM, Bert Freudenberg [EMAIL PROTECTED]
 wrote:

 On 02.06.2008, at 10:29, shivaprasad javali wrote:

 Hi,

I prepared a .xo file for my application to be installed on the XO. I
 created the .xo file by running the zip command on the activity folder. Now
 if I have to install the activity through a thumb drive, I go to the
 terminal move to Activities folder and then unzip the .xo file there. Then I
 have to restart the xserver for my activity to show up on the home page.


   Is there any way I can install the activity like this without having to
 restart the xserver or restart the xserver implicitly??

 Yes. Use sugar-install-bundle /path/to/bundle.xo from the Terminal
 activity, which unzips the activity and tells the Sugar shell that it was
 installed.


   Also can I do the installation through the journal if I have the .xo
 file on a thumb drive??


 Yes. Clicking the .xo in the Journal view of your USB drive will install
 it.

 - Bert -







___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help installing an activity

2008-06-02 Thread shivaprasad javali
My directory structure for the activity is:
-activity --has the .info file and the icon
-bin  -- has a shell script and the exe which i have to run
-lib  -- has the libs which my application is dependent on
- MANIFEST file

I used the information in this link : http://www.catmoran.com/olpc/#sugxterm
to sugarize my activity.

Is there any problem with the structure of this bundle??

Also I am relatively new to development on the XO. Is there any command
where I can know the version of my sugar so that I can provide that
information to you??

Thanks Shivaprasad

On Mon, Jun 2, 2008 at 4:22 PM, Tomeu Vizoso [EMAIL PROTECTED] wrote:

 2008/6/2 shivaprasad javali [EMAIL PROTECTED]:
  Sorry didnt observe it properly. It is a D-BUS timeout. I am runing the
  command from the terminal activity on an actual XO.

 Which version of the software are you using? Some old versions would
 give you that error if the bundle was malformed.

 As always, logs would help:

 http://wiki.laptop.org/go/Attaching_Sugar_Logs_to_Tickets

 Regards,

 Tomeu

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Need help with making flash partitions

2008-05-13 Thread Artem Bityutskiy
Hi,

I am trying to create an UBIFS image for OLPC and ask the community
to evaluate it. But I have some troubles I need help to deal with.

The basic approach I am going to use is to create 2 flash partitions
- boot and root. Boot would contain /boot and have JFFS2. OF would
boot the kernel from this partition. Boot would be small, just few
Megs. Root partition would be large and contain everything else and
would be UBIFS.

Mitch kindly referred me to this web page which tells how to create
2 partitions: http://wiki.laptop.org/go/OFW_NAND_FLASH_Updater

My aim is to make UBIFS installation easy - people would just copy
some files to their FAT-formatted USB sticks and reboot. Just like
you update your laptops with JFFS2 images.

But I have troubles with security. Namely, if I change data.img, OF
complains about invalid signature. I tried to remove data.sig file -
it does not help. I tried to put my developer key to the USB stick -
does not help as well. I use B4 prototype and security is disabled
AFAIU.

Any suggestion? Thanks.

-- 
Best Regards,
Artem Bityutskiy (Артём Битюцкий)
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Server-devel] [OLPC India] need help w/ OLPC technical training program

2008-04-09 Thread Martin Langhoff
On Wed, Apr 9, 2008 at 3:38 AM, Bryan Berry [EMAIL PROTECTED] wrote:
 The XS guide would be extremely useful. I am concerned about creating a
  guide for it when it is still under rapid development. Please make sure
  you are in close contact w/ Martin Langhoff so you don't have to
  document a feature or bug that may disappear in a week or two.

  If you haven't already, you should check out Martin's XS Roadmap
  http://wiki.laptop.org/go/XS_Roadmap

I agree 200% with Bryan - at the moment we have an XS build that is
moving quickly (or rather, that is starting to move quickly ;-) ). It
is hard to document such a moving target, specially for beginners.

The path I think Bryan is taking is very smart for the current
situation - aim for decent Linux know-how, and then give them pointers
to the XS specifics (in the wiki).

As we approach 1.0 it will make more sense to have an XS beginners
guide. Hopefully, it will be an easier job too, as things will stop
moving so much ;-)

cheers,



martin

-- 
 [EMAIL PROTECTED]
 [EMAIL PROTECTED] -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Server-devel mailing list
[EMAIL PROTECTED]
http://lists.laptop.org/listinfo/server-devel


Re: Need Help

2008-03-05 Thread Waqas Toor
Hello All,
Thanks,

I found 2 things reading this thread, let me explain what I did,
a) my activity directory was writable by world, why i did this was
becuase i was creating a config file and didnt know the user which
initiates my activity
b) the scripts which were executeable i.e. my Activity main script,
was only readable but still works ( can some one elaborate that for
me? i am a bit confused that how its readable but still executed )

1 thing more, when my activity is running, going to home view shows 2
icons, 1 is the activity icon that i created, 2nd is the black circle
in the right that is associated with my activity. can some body give
me a hint that where i am wrong ?
as i am using glade with gtk

Regards
-- 
Waqas Toor
member of OLPC Pakistan Team


On 3/5/08, Benjamin M. Schwartz [EMAIL PROTECTED] wrote:
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 Michael Stone wrote:
 | On Tue, Mar 04, 2008 at 08:22:31PM -0500, Benjamin M. Schwartz wrote:
 | Michael Stone wrote:
 | | My central error-handling goal has been to compactly express my
 | | assumptions in a form that will prevent them from being violated in
 | | ignorance. Should I have different goals?
 |
 | 1. I find Rainbow very impressive, and I am sure you are well aware of the
 | various arguments made regarding error handling.
 |
 | Thank you. While it's true that I'm aware of some arguments regarding error
 | handling, I'm always interested in improving. It seems like one of the
 | most regularly failed challenges in the craft of programming.
 |
 | In my view, restricting assertions to internal invariants provides an
 | easy way of distinguishing problems in Rainbow from problems in
 | Activities and other parts of the system.
 |
 | True, but the convention that I have established of separating error
 | messages into contract-violations and 'everything else', recorded in
 | per-activity logs and in a daemon-wide log (/var/log/rainbow) would seem
 | to accomplish similar goals.

 I have not read the relevant Rainbow source, so I cannot comment very
 intelligently on this.  However, if Rainbow wishes to log a contract
 violation, it should insert the phrase contract violation into the
 logfile.  Otherwise, how is a person reading the log to know this?

 | 2. Among your goals, you might consider maximizing the ability of novice
 | programmers to figure out what they've done wrong.
 |
 | It's not my primary goal, but I'll agree that it's worth considering.
 |
 | The wiki page on translation even goes so far as to
 | recommend using gettext for error strings, so that users and
 | administrators may debug the system without knowing English.

 I used the phrase debug the system.  That was a poor choice.  I should
 say recognize bugs in the system, and additionally distinguish between
 bugs in the system and bugs in the activities they're developing.

 |
 | I'm still not convinced. Wouldn't we be better served by translating the
 | source code itself, or an overview of the source code like my 'Taste the
 | Rainbow' pages?
 |
 | Consider: in my experience, debugging consists of searching the diff
 | between one's mental model and reality from which it follows that the
 | material which should be translated is the material which provides the
 | clearest, most accurate mental model of the problem.

 Your experience is extremely unusual and non-representative.  You are an
 expert computer scientist who frequently reads source code written by
 others.  You are familiar with the OLPC operating system details,
 including D-Bus and the Bitfrost requirements, perhaps moreso than anyone
 else in the world.

 The people who will be reading these logfiles will be developers who are
 trying to debug their activities.  The activity may have crashed because
 it attempted to violate a Bitfrost rule and was killed by Rainbow.  These
 developers (ideally mostly children) will likely be building their
 activities by making small modifications to existing activities.  That
 means most won't even understand their own code.  How could you possibly
 expect them to understand yours?

 | Also consider: had there been an actual bug in Rainbow, which would have
 | been more useful to Waqas in diagnosing and fixing the problem:
 | translated error messages or better written or documented source code?

 Not fixing.  It is absurd to imagine that any appreciable number of users
 will be able fix Rainbow bugs.  Rather, when Rainbow experiences an
 internal error, it should be extremely obvious that the problem is with
 Rainbow.  For example, an excellent type of behavior would be for Rainbow
 to print, in the logfile:

 RAINBOW BUG: Rainbow has encountered an internal error.  This indicates a
 bug in Rainbow.  The error code is 752.

 This line would be sufficient for activity developers to understand that
 the problem is not simply in their code. It also makes it possible for
 users to participate usefully in the development process, by reporting the
 bug in an 

Re: Need Help

2008-03-04 Thread Tomeu Vizoso
On Tue, Mar 4, 2008 at 6:54 AM, Benjamin M. Schwartz
[EMAIL PROTECTED] wrote:
  Waqas Toor wrote:
  | Hello All,
  |
  | I am having a problem and unable to find any solution regarding that,
  | I have written an activity in using GTK and glade, and have sugarized
  | it according to the hello world tutorial in wiki. but still i dont
  | know what is going on as the icon of the activity stays in the ring
  | and then disappears after some time, i have rechecked my code again
  | and again and cant find any thing that is of Coding error
  |
  |
  | can anybody please see the log i am attaching and tell me is rainbow
  | stoping it ??

  You appear to have discovered a bug in Rainbow, which is dying with an
  assertion failure.  Until Rainbow is fixed, you should do as Walter
  suggested and disable Rainbow.

Ben is right. I think the problem is that your activity dir is world
writable, you could try changing that and continue testing your
activity inside Rainbow. Compare the permissions of your activity dir
and contents with other activities.

Can you enter a ticket about this? I don't know if Rainbow should
abort the launch in these cases, but certainly should give a more
helpful message.

Thanks,

Tomeu
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need Help

2008-03-04 Thread Michael Stone
On Tue, Mar 04, 2008 at 10:12:35AM +0100, Tomeu Vizoso wrote:
 On Tue, Mar 4, 2008 at 6:54 AM, Benjamin M. Schwartz
 [EMAIL PROTECTED] wrote:
   Waqas Toor wrote:
   | can anybody please see the log i am attaching and tell me is rainbow
   | stoping it ??

As Tomeu said, Rainbow has detected that your activity's directory,
/home/olpc/activities/Qirat.activity, is writable by the activity.
Activities are not permitted to modify their own bundles. Consequently,
Rainbow scuttled the launch. 

   You appear to have discovered a bug in Rainbow, which is dying with an
   assertion failure.  Until Rainbow is fixed, you should do as Walter
   suggested and disable Rainbow.

Is there some reason why activities need to write to their (or to other
activities') bundle directories?

 Can you enter a ticket about this? I don't know if Rainbow should
 abort the launch in these cases, but certainly should give a more
 helpful message.

Tomeu: what do you suggest Rainbow should do in response to this kind of
assertion failure? Should we really try to print a more readable
explanation of what failed, given the degree to which such explanations
would bloat the code-base? Also, if so, does this message need to be
localized? 

I'm happy to try to improve the legibility of both the failures and the
code itself; however, the fact that you were able to correctly diagnose
the error (which has never been reported before) and to propose a fix
(change the permissions on the bundle dir) suggests to me that I got at
least one thing right... :)

Michael

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need Help

2008-03-04 Thread Asheesh Laroia
On Tue, 4 Mar 2008, Michael Stone wrote:

 As Tomeu said, Rainbow has detected that your activity's directory, 
 /home/olpc/activities/Qirat.activity, is writable by the activity. 
 Activities are not permitted to modify their own bundles. Consequently, 
 Rainbow scuttled the launch.

That's good of it.

 Tomeu: what do you suggest Rainbow should do in response to this kind of 
 assertion failure? Should we really try to print a more readable 
 explanation of what failed, given the degree to which such explanations 
 would bloat the code-base? Also, if so, does this message need to be 
 localized?

I would suggest printing a URL to a page on wiki.laptop.org that has more 
information and/or an error code with a link to look up the error code. 
(I prefer the former, but the latter could save a few bytes (that I think 
are probably not worth saving) by storing only one URL for looking up the 
problems, plus the error code strings/numbers, combining them at error 
print time.)

-- Asheesh.

-- 
If you do something right once, someone will ask you to do it again.
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need Help

2008-03-04 Thread Benjamin M. Schwartz
On Tue, 2008-03-04 at 17:37 -0500, Michael Stone wrote:
 On Tue, Mar 04, 2008 at 10:12:35AM +0100, Tomeu Vizoso wrote:
  On Tue, Mar 4, 2008 at 6:54 AM, Benjamin M. Schwartz
  [EMAIL PROTECTED] wrote:
Waqas Toor wrote:
| can anybody please see the log i am attaching and tell me is rainbow
| stoping it ??
 
 As Tomeu said, Rainbow has detected that your activity's directory,
 /home/olpc/activities/Qirat.activity, is writable by the activity.
 Activities are not permitted to modify their own bundles. Consequently,
 Rainbow scuttled the launch. 
 
You appear to have discovered a bug in Rainbow, which is dying with an
assertion failure.  Until Rainbow is fixed, you should do as Walter
suggested and disable Rainbow.
 
 Is there some reason why activities need to write to their (or to other
 activities') bundle directories?

I would argue that activities should not be allowed to write to their
bundle directories, and that Rainbow is enforcing the correct
requirement.  I am calling this a bug because Rainbow should achieve
this without an assertion failure.  According to my software engineering
professors, a program should always handle any input data without an
assertion failure.  Assertions are for catching bugs in internal
invariants.  Therefore, any time an assertion failure is reached, it
represents a bug.

If Rainbow wants to disallow this, it should raise a specific exception.

 
  Can you enter a ticket about this? I don't know if Rainbow should
  abort the launch in these cases, but certainly should give a more
  helpful message.

#6640.

--Ben

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need Help

2008-03-04 Thread Michael Stone
On Tue, Mar 04, 2008 at 06:16:34PM -0500, Benjamin M. Schwartz wrote:
 According to my software engineering professors, a program should
 always handle any input data without an assertion failure. Assertions
 are for catching bugs in internal invariants.  Therefore, any time an
 assertion failure is reached, it represents a bug.

My central error-handling goal has been to compactly express my
assumptions in a form that will prevent them from being violated in
ignorance. Should I have different goals?

 If Rainbow wants to disallow this, it should raise a specific exception.

Given your knowledge of Rainbow's clients, both human and software, what
would be gained by spending the time, documentation, and code required
to create and raise a specific exception for each unique way to violate
my assumptions?

   Can you enter a ticket about this? I don't know if Rainbow should
   abort the launch in these cases, but certainly should give a more
   helpful message.

Again, who is the audience for the message? It was clearly helpful for
Tomeu and me; it was clearly not as helpful for Waqas. Waqas - what
could Rainbow have done better for you?

Michael
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need Help

2008-03-04 Thread Benjamin M. Schwartz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Michael Stone wrote:
| On Tue, Mar 04, 2008 at 06:16:34PM -0500, Benjamin M. Schwartz wrote:
| According to my software engineering professors, a program should
| always handle any input data without an assertion failure. Assertions
| are for catching bugs in internal invariants.  Therefore, any time an
| assertion failure is reached, it represents a bug.
|
| My central error-handling goal has been to compactly express my
| assumptions in a form that will prevent them from being violated in
| ignorance. Should I have different goals?

1. I find Rainbow very impressive, and I am sure you are well aware of the
various arguments made regarding error handling.  In my view, restricting
assertions to internal invariants provides an easy way of distinguishing
problems in Rainbow from problems in Activities and other parts of the system.

2. Among your goals, you might consider maximizing the ability of novice
programmers to figure out what they've done wrong.  OLPC's goals include
bringing in many developers who have no experience, so it is important the
system be friendly to, say, Python programs written by people who don't
know Python.  The wiki page on translation even goes so far as to
recommend using gettext for error strings, so that users and
administrators may debug the system without knowing English.

3.  Did this assertion failure result in the termination of the Rainbow
daemon?  It certainly seems like it could have, though your response
suggests otherwise.  Most programs simply exit after an assertion failure,
because the failure indicates that the program's internal state is no
longer sensible.  Raising exceptions for input errors has the distinct
advantage of allowing one to catch exceptions thrown further down the call
stack, instead of exiting.  Note that when I say specific exceptions, it
would be perfectly reasonable to wrap up all errors due to permissions in
a PermissionsException, etc.

- --Ben

-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.7 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHzfXXUJT6e6HFtqQRAhSwAJ4lobW9HT6OWtonFQjQI93ppGlGwACfTgBv
AaXnBTOaXz1QrfGlc80xupU=
=YfUX
-END PGP SIGNATURE-
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need Help

2008-03-04 Thread Michael Stone
On Tue, Mar 04, 2008 at 08:22:31PM -0500, Benjamin M. Schwartz wrote:
 Michael Stone wrote:
 | My central error-handling goal has been to compactly express my
 | assumptions in a form that will prevent them from being violated in
 | ignorance. Should I have different goals?

 1. I find Rainbow very impressive, and I am sure you are well aware of the
 various arguments made regarding error handling.  

Thank you. While it's true that I'm aware of some arguments regarding error
handling, I'm always interested in improving. It seems like one of the
most regularly failed challenges in the craft of programming.

 In my view, restricting assertions to internal invariants provides an
 easy way of distinguishing problems in Rainbow from problems in
 Activities and other parts of the system.

True, but the convention that I have established of separating error
messages into contract-violations and 'everything else', recorded in
per-activity logs and in a daemon-wide log (/var/log/rainbow) would seem
to accomplish similar goals.

 2. Among your goals, you might consider maximizing the ability of novice
 programmers to figure out what they've done wrong.  

It's not my primary goal, but I'll agree that it's worth considering.

 The wiki page on translation even goes so far as to
 recommend using gettext for error strings, so that users and
 administrators may debug the system without knowing English.

I'm still not convinced. Wouldn't we be better served by translating the
source code itself, or an overview of the source code like my 'Taste the
Rainbow' pages?

Consider: in my experience, debugging consists of searching the diff
between one's mental model and reality from which it follows that the
material which should be translated is the material which provides the
clearest, most accurate mental model of the problem.

Also consider: had there been an actual bug in Rainbow, which would have
been more useful to Waqas in diagnosing and fixing the problem:
translated error messages or better written or documented source code?

Put another way, doesn't this kind of error message uselessly duplicate
information that is best recorded in the failing assertion itself (and
in the name of the function containing it, in this case, 

  check_cwd(... [cwd=]/home/olpc/Activities/Qirat.activity)
  assert ck.negative(W_OK, 0)

?

 3.  Did this assertion failure result in the termination of the Rainbow
 daemon?  

The present implementation calls clone() before executing any
activity-launching code. Termination of the child by failure to handle
the AssertionError is a design goal.

 Raising exceptions for input errors has the distinct
 advantage of allowing one to catch exceptions thrown further down the call
 stack, instead of exiting.  Note that when I say specific exceptions, it
 would be perfectly reasonable to wrap up all errors due to permissions in
 a PermissionsException, etc.

First, what can I reasonably expect to accomplish by catching such an
exception? Second, given that the exception is being raised in a child
process that may have been compromised by malicious data, I'm not
terribly interested in informing the main daemon to the particulars of
the failure; the log file is quite sufficient for my purposes.

Michael
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need Help

2008-03-04 Thread Benjamin M. Schwartz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Michael Stone wrote:
| On Tue, Mar 04, 2008 at 08:22:31PM -0500, Benjamin M. Schwartz wrote:
| Michael Stone wrote:
| | My central error-handling goal has been to compactly express my
| | assumptions in a form that will prevent them from being violated in
| | ignorance. Should I have different goals?
|
| 1. I find Rainbow very impressive, and I am sure you are well aware of the
| various arguments made regarding error handling.
|
| Thank you. While it's true that I'm aware of some arguments regarding error
| handling, I'm always interested in improving. It seems like one of the
| most regularly failed challenges in the craft of programming.
|
| In my view, restricting assertions to internal invariants provides an
| easy way of distinguishing problems in Rainbow from problems in
| Activities and other parts of the system.
|
| True, but the convention that I have established of separating error
| messages into contract-violations and 'everything else', recorded in
| per-activity logs and in a daemon-wide log (/var/log/rainbow) would seem
| to accomplish similar goals.

I have not read the relevant Rainbow source, so I cannot comment very
intelligently on this.  However, if Rainbow wishes to log a contract
violation, it should insert the phrase contract violation into the
logfile.  Otherwise, how is a person reading the log to know this?

| 2. Among your goals, you might consider maximizing the ability of novice
| programmers to figure out what they've done wrong.
|
| It's not my primary goal, but I'll agree that it's worth considering.
|
| The wiki page on translation even goes so far as to
| recommend using gettext for error strings, so that users and
| administrators may debug the system without knowing English.

I used the phrase debug the system.  That was a poor choice.  I should
say recognize bugs in the system, and additionally distinguish between
bugs in the system and bugs in the activities they're developing.

|
| I'm still not convinced. Wouldn't we be better served by translating the
| source code itself, or an overview of the source code like my 'Taste the
| Rainbow' pages?
|
| Consider: in my experience, debugging consists of searching the diff
| between one's mental model and reality from which it follows that the
| material which should be translated is the material which provides the
| clearest, most accurate mental model of the problem.

Your experience is extremely unusual and non-representative.  You are an
expert computer scientist who frequently reads source code written by
others.  You are familiar with the OLPC operating system details,
including D-Bus and the Bitfrost requirements, perhaps moreso than anyone
else in the world.

The people who will be reading these logfiles will be developers who are
trying to debug their activities.  The activity may have crashed because
it attempted to violate a Bitfrost rule and was killed by Rainbow.  These
developers (ideally mostly children) will likely be building their
activities by making small modifications to existing activities.  That
means most won't even understand their own code.  How could you possibly
expect them to understand yours?

| Also consider: had there been an actual bug in Rainbow, which would have
| been more useful to Waqas in diagnosing and fixing the problem:
| translated error messages or better written or documented source code?

Not fixing.  It is absurd to imagine that any appreciable number of users
will be able fix Rainbow bugs.  Rather, when Rainbow experiences an
internal error, it should be extremely obvious that the problem is with
Rainbow.  For example, an excellent type of behavior would be for Rainbow
to print, in the logfile:

RAINBOW BUG: Rainbow has encountered an internal error.  This indicates a
bug in Rainbow.  The error code is 752.

This line would be sufficient for activity developers to understand that
the problem is not simply in their code. It also makes it possible for
users to participate usefully in the development process, by reporting the
bug in an unambiguous way.  Error codes are also important because they
allow users to identify problems even when e-mailing logfiles is
impossible due to software bugs or lack of connectivity.  This error line
is also nice because it only needs to be translated once, with the error
code number substituted programmatically.

This output could be improved further by adding an additional sentence,
such as:

This error code indicates that Rainbow's directory permissions have
reached an inconsistent state.

This line, like a BSOD, serves mainly to make users feel like the system's
designers want them to know what's going on in case of a failure.
However, the implementation overhead is undeniably high, especially given
the need for many translations.  On the plus side, these strings also
serve as documentation when reading the source code.

|
| Put another way, doesn't this kind of error message uselessly duplicate

Need Help

2008-03-03 Thread Waqas Toor
Hello All,

I am having a problem and unable to find any solution regarding that,
I have written an activity in using GTK and glade, and have sugarized
it according to the hello world tutorial in wiki. but still i dont
know what is going on as the icon of the activity stays in the ring
and then disappears after some time, i have rechecked my code again
and again and cant find any thing that is of Coding error


can anybody please see the log i am attaching and tell me is rainbow
stoping it ??

regards



-- 
Waqas Toor


org.laptop.sugar.QiratActivity-2.log
Description: Binary data
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need Help

2008-03-03 Thread Benjamin M. Schwartz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Waqas Toor wrote:
| Hello All,
|
| I am having a problem and unable to find any solution regarding that,
| I have written an activity in using GTK and glade, and have sugarized
| it according to the hello world tutorial in wiki. but still i dont
| know what is going on as the icon of the activity stays in the ring
| and then disappears after some time, i have rechecked my code again
| and again and cant find any thing that is of Coding error
|
|
| can anybody please see the log i am attaching and tell me is rainbow
| stoping it ??

You appear to have discovered a bug in Rainbow, which is dying with an
assertion failure.  Until Rainbow is fixed, you should do as Walter
suggested and disable Rainbow.

- --Ben
-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.7 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHzOQBUJT6e6HFtqQRAp/UAJ43nJwJBbCSbZdBEOnPU9KAG7UAuQCfasdz
J571RBiFo6T5quGBz4BSAW8=
=2hyy
-END PGP SIGNATURE-
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Need help to resolve any problems

2007-11-19 Thread Cihan Akkurt
Hi,
I have any problems with my program : Ghost.activity
Can someone help me to resolve them.
Thanks.

Problem with activity-icon.svg :
I created an icon svg format with Inkscape that I see in my development
machine, but the icon is not displayed in the emulator XO. why 

I am committed the icon.svg at this mail


Problem with Manifest in .xo generation :
I can not create Ghost.xo(my program)  because I get this error that appears
each time.

I am committed the manifest file at this mail

[EMAIL PROTECTED]:~/Activities/Ghost.activity$ ./setup.py dist
WARNING: NEWS file is missing.
Traceback (most recent call last):
  File ./setup.py, line 4, in module
bundlebuilder.start(Ghost)
  File
/home/cihan/sugar-jhbuild/build/lib/python2.5/site-packages/sugar/activity/bundlebuilder.py,
line 386, in start
cmd_dist(bundle_name, manifest)
  File
/home/cihan/sugar-jhbuild/build/lib/python2.5/site-packages/sugar/activity/bundlebuilder.py,
line 188, in cmd_dist
bundle_zip.write(filename, os.path.join(base_dir, filename))
  File /usr/lib/python2.5/zipfile.py, line 541, in write
st = os.stat(filename)
OSError: [Errno 2] No such file or directory: 'Ghost.activity'
[EMAIL PROTECTED]:~/Activities/Ghost.activity$


-- 
**
Cihan Akkurt

E-mail : [EMAIL PROTECTED]

Msn : [EMAIL PROTECTED]

Skype : akkuciha

**


MANIFEST
Description: Binary data
attachment: ghost.svg___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Need help to resolve any problems

2007-11-19 Thread Reinier Heeres
Hi Cihan,

Your icon tries to embed a gif file. The actual image data, however, is 
not in there. Try drawing a couple of lines in inkscape and it'll 
probably work.

As for your MANIFEST file: you need to list the files like this:
just.png
question.png
DefaultConfig

So remove the Ghost.activity/ from the beginning of the lines. Also I 
don't think you have to include the activity/ directory, as 
activity.info and the icon will be included automatically. Also leave 
out other directories, and list the individual files.

Cheers,
Reinier

Cihan Akkurt wrote:
 Hi,
 I have any problems with my program : Ghost.activity
 Can someone help me to resolve them.
 Thanks.

 Problem with activity-icon.svg :
 I created an icon svg format with Inkscape that I see in my 
 development machine, but the icon is not displayed in the emulator XO. 
 why 

 I am committed the icon.svg at this mail


 Problem with Manifest in .xo generation :
 I can not create Ghost.xo(my program)  because I get this error that 
 appears each time.

 I am committed the manifest file at this mail

 [EMAIL PROTECTED]:~/Activities/Ghost.activity$ ./setup.py dist
 WARNING: NEWS file is missing.
 Traceback (most recent call last):
   File ./setup.py, line 4, in module
 bundlebuilder.start(Ghost)
   File 
 /home/cihan/sugar-jhbuild/build/lib/python2.5/site-packages/sugar/activity/bundlebuilder.py,
  
 line 386, in start
 cmd_dist(bundle_name, manifest)
   File 
 /home/cihan/sugar-jhbuild/build/lib/python2.5/site-packages/sugar/activity/bundlebuilder.py,
  
 line 188, in cmd_dist
 bundle_zip.write(filename, os.path.join (base_dir, filename))
   File /usr/lib/python2.5/zipfile.py, line 541, in write
 st = os.stat(filename)
 OSError: [Errno 2] No such file or directory: 'Ghost.activity'
 [EMAIL PROTECTED]:~/Activities/Ghost.activity$


 -- 
 **
 Cihan Akkurt

 E-mail : [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]

 Msn : [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]

 Skype : akkuciha

 **
 

 ___
 Devel mailing list
 Devel@lists.laptop.org
 http://lists.laptop.org/listinfo/devel
   
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Ghost My new Activity need help.

2007-11-16 Thread Cihan Akkurt
Hello,

I developed a new activity for OLPC and I would like that someone can check
on a real machine. I need this test to find out if I have to install modules
/ packages before using the software.

In my code, I use import Image (PIL), and I do not know if it is already
installed by default OLPC

I also have a problem with the current directory. In my files. Py the path I
/ home / cihan / Activities / Ghost.activity /
example: locale_dir = / home / cihan / Activities / Ghost.activity
 and I would like to make it easier for portability. I have already tested
os.getcwd () function on Ubuntu but not in the emulator Sugar

I can sent the activity  by e-mail.It is 7 mb.

Sorry for my bad English. I can french if someone can French.

Thanks for your response.

-- 
**
Cihan Akkurt

E-mail : [EMAIL PROTECTED]

Msn : [EMAIL PROTECTED]

Skype : akkuciha

**
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Ghost My new Activity need help.

2007-11-16 Thread Bert Freudenberg
You can see what software is installed in the build logs, e.g.

http://xs-dev.laptop.org/~cscott/olpc/streams/joyride/build286/ 
devel_jffs2/build.log

and you can verify it works by emulation:

http://wiki.laptop.org/go/Emulating_the_XO

The cwd is set to your activity's bundle directory, so you can use  
simply use relative paths to access resource files in the bundle.

- Bert -

On Nov 16, 2007, at 9:37 , Cihan Akkurt wrote:

 Hello,

 I developed a new activity for OLPC and I would like that someone  
 can check on a real machine. I need this test to find out if I have  
 to install modules / packages before using the software.

 In my code, I use import Image (PIL), and I do not know if it is  
 already installed by default OLPC

 I also have a problem with the current directory. In my files. Py  
 the path I / home / cihan / Activities / Ghost.activity /
 example: locale_dir = / home / cihan / Activities / Ghost.activity
  and I would like to make it easier for portability. I have already  
 tested os.getcwd () function on Ubuntu but not in the emulator Sugar

 I can sent the activity  by e-mail.It is 7 mb.

 Sorry for my bad English. I can french if someone can French.

 Thanks for your response.

 -- 
 **
 Cihan Akkurt

 E-mail : [EMAIL PROTECTED]

 Msn : [EMAIL PROTECTED]

 Skype : akkuciha

 **
 ___
 Devel mailing list
 Devel@lists.laptop.org
 http://lists.laptop.org/listinfo/devel

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel