This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2013-03-03 16:16:12

dbclin
New Scratcher
Registered: 2013-03-03
Posts: 7

Scratch failing to load on thin clients

Hi,
I'm able to successfully run Scratch 1.4 on my Linux Edubuntu 12.04 server but when I try to load it on a thin client there is only a window filled with white (which unfortunately becomes quite rude when I try to close it). When I load using
scratch -v
I get this output:
==================
$ scratch -v
Executing: /usr/lib/squeak/4.4.7-2357/squeakvm -encoding UTF-8 -vm-display-x11 -xshm -plugins /usr/lib/scratch/plugins/:/usr/lib/squeak/4.4.7-2357/ /usr/share/scratch/Scratch.image /home/naftali/-v
XShmAttach: BadAccess (attempt to access private resource denied)
X Error: BadShmSeg (invalid shared segment parameter)
  Major opcode of failed request:  139
  Minor opcode of failed request:  3
  Serial number of failed request: 84
X Error: BadShmSeg (invalid shared segment parameter)
  Major opcode of failed request:  139
  Minor opcode of failed request:  3
  Serial number of failed request: 86
X Error: BadShmSeg (invalid shared segment parameter)
  Major opcode of failed request:  139
  Minor opcode of failed request:  3
  Serial number of failed request: 87
===================

...which seems to suggest a shared memory problem.
Does anyone have any ideas?
Thanks,

Offline

 

#2 2013-03-04 02:51:13

TRocket
Scratcher
Registered: 2009-08-18
Posts: 1000+

Re: Scratch failing to load on thin clients

Looks like it's a problem with X. I seem to remember there are lots of other linux builds with various fixes. I'd suggest trying a different one.


http://i.imgur.com/1QqnHxQ.png

Offline

 

#3 2013-03-04 09:14:48

dbclin
New Scratcher
Registered: 2013-03-03
Posts: 7

Re: Scratch failing to load on thin clients

Thanks, but I'm afraid that won't work in this case - this is a heavily used production environment that can't be changed for just one package.

Offline

 

#4 2013-03-04 17:24:55

TRocket
Scratcher
Registered: 2009-08-18
Posts: 1000+

Re: Scratch failing to load on thin clients

dbclin wrote:

Thanks, but I'm afraid that won't work in this case - this is a heavily used production environment that can't be changed for just one package.

sorry, I meant other scratch builds...

Think I got it now though, looks like
this bug report could also be useful. Looks to me like you can just remove the -Xshm and then it should connect to the correct X server.

If you don't know much about linux, please run "which scratch" then "cat (whatever path you get from the previous command)" and copy the output to this thread. If you are confident with linux, go ahead and edit the file yourself.

Last edited by TRocket (2013-03-04 17:34:30)


http://i.imgur.com/1QqnHxQ.png

Offline

 

#5 2013-03-04 18:06:45

dbclin
New Scratcher
Registered: 2013-03-03
Posts: 7

Re: Scratch failing to load on thin clients

> Think I got it now though, looks like this bug report could also be useful. Looks to me like you can just remove the -Xshm and then it should connect to the correct X server.

That was bang on...worked a charm!
Now I'm working on getting audio going on the thin client. That was the killer a few years ago when I first tried Scratch. Any ideas?
Thanks a million!
David

Offline

 

#6 2013-03-04 22:05:25

dbclin
New Scratcher
Registered: 2013-03-03
Posts: 7

Re: Scratch failing to load on thin clients

Update: I believe that I will move my problem playing sound in Scratch on a thin client over to Edubuntu forums as the problem seems to be more LTSP-oriented (although if anyone here has any insight, I'd be most appreciative).
In case anyone's interested, here's what I've discovered:
Running scratch -v from a client, I got this after trying to play sound:

sound: /dev/dsp: No such file or directory

on that, http://wiki.debian.org/SoundFAQ reported:

"If the audio mixer application is reporting that no mixer is available, or gives an error:
    audio: /dev/dsp: No such file or directory
It is necessary to load the snd-pcm-oss module"

Which suggests that my clients somehow have no access to that module - it must be sucessfully loaded on the system, as Scratch plays sound on my server without trouble.

Thanks TRocket for your help!
David

Offline

 

#7 2013-03-05 02:14:03

TRocket
Scratcher
Registered: 2009-08-18
Posts: 1000+

Re: Scratch failing to load on thin clients

You're welcome! I was about to give you https://lists.ubuntu.com/archives/edubu … 03723.html. But I think it's one you filed  tongue


http://i.imgur.com/1QqnHxQ.png

Offline

 

#8 2013-03-05 12:14:02

dbclin
New Scratcher
Registered: 2013-03-03
Posts: 7

Re: Scratch failing to load on thin clients

TRocket wrote:

You're welcome! I was about to give you lists.ubuntu.com/archives/edubuntu-users/2008-March/003723.html. But I think it's one you filed  tongue

It was my bug. But at least this time I'm not getting sound output through my server's speakers...  smile

Offline

 

#9 2013-03-05 16:01:41

TRocket
Scratcher
Registered: 2009-08-18
Posts: 1000+

Re: Scratch failing to load on thin clients

For the sound, try also adding -vm-sound-alsa or -vm-sound-oss to the script that calls the squeak vm. (The same line you removed the -xshm from)


http://i.imgur.com/1QqnHxQ.png

Offline

 

#10 2013-03-05 17:42:12

dbclin
New Scratcher
Registered: 2013-03-03
Posts: 7

Re: Scratch failing to load on thin clients

TRocket wrote:

For the sound, try also adding -vm-sound-alsa or -vm-sound-oss to the script that calls the squeak vm. (The same line you removed the -xshm from)

Ok. When I tried -vm-sound-alsa I at least managed to get a new error message  smile

soundStart: snd_add_pcm_handler: Function not implemented

which appears to be a known issue. See bugzilla.redhat.com/show_bug.cgi?id=856238 where I found:

"This is a PulseAudio thing -- it's an intentional incompatibility in the ALSA compatibility layer. If you're running PulseAudio, the native support should have been used automatically."

-vm-sound-oss left me where I was before (sound: /dev/dsp: No such file or directory)

Thanks for the ideas,

Offline

 

#11 2013-03-05 18:10:20

dbclin
New Scratcher
Registered: 2013-03-03
Posts: 7

Re: Scratch failing to load on thin clients

I'm rather embarrassed to admit that I "solved" the problem by simply running the Windows build of Scratch under Wine - no hiccups yet!

Offline

 

Board footer