WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: system performance and flash  (Read 4147 times)

nomer

  • Guest
system performance and flash
« on: January 28, 2012, 09:29:49 AM »
I have an annoying problem. The problem seems to be related to flash. On certain intense flash games the system will lock up. On one occasion I was able to Ctrl+Alt+Bkspace and it very slowly closed everything and gave me the command line.
On other occasions (when none intense flash things e.g. youtube.com) the system has completed locked up for no apparent reason. The only way to "fix" the problem was to kill the system with the power button.

There are several things that come into play here:
  • CPU and RAM -->  Intel(R) Celeron(R) CPU 2.66GHz  and  512 MB of RAM
  • graphics card -->  I have and Intel embedded card, I think it is an Intel 865G graphics controller, but I'll have to confirm that.
  • graphics driver -->  I have no idea what tinycore is using
  • xorg version --> I'm not sure how to check this, but when I run ps I see this line
    Quote
    /usr/bin/Xvesa -br -screen 1280x1024x24 -shadow -mouse /dev/input/mice,5 -nolisten tcp -I
  • browser w/ version --> Chromium 15... Developer build; It is chromium-browser.tcz in the repository
  • flash version --> Adobe flash 11.1.102; got it using getFlash.tcz from the repo.
  • tinycore setup --> booting from usb stick, with mydata.tcz and /tce/optional on it

This is currently the thing that is keeping me from using Linux more. (I also experienced these problems more on Puppy Linux, but that community is a mess so I never tried to solve the problem.)

I'm curious to see if anyone else has experienced system lockup with TinyCore.
I'm also curious to know what the best setup might be for getting better flash performance.

Thanks,
Nomer
« Last Edit: January 28, 2012, 09:31:38 AM by nomer »

Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 7183
    • My Community Forum
Re: system performance and flash
« Reply #1 on: January 28, 2012, 09:38:09 AM »
To get better flash performance simply drop flash.
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."

nomer

  • Guest
Re: system performance and flash
« Reply #2 on: January 28, 2012, 10:54:46 AM »
To get better flash performance simply drop flash.
Yeah, how true.  ;)
Unfortunately, that is not an option for me since I'm not the only one who uses the system.
The rest of the family really likes to use things that require flash.
For me the biggest loss would be free online music provided by grooveshark.com, pandora.com, etc. :-\

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: system performance and flash
« Reply #3 on: January 28, 2012, 11:31:12 AM »
Do you have swap? Flash is a huge memory hog.
The only barriers that can stop you are the ones you create yourself.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11631
Re: system performance and flash
« Reply #4 on: January 28, 2012, 01:20:14 PM »
Hi nomer
Use  gparted.tcz  to add a swap partition to your local hard drive, not the usb stick. Also, check the
cache settings for Chromium and knock them down in size.
Quote
.... it very slowly closed everything ....
That is probably a sign that you ran out of RAM. I get that type of behavior after Opera has been
running a few days. The system slows down, and when I click the close button, Opera takes about
20 or 30 seconds to close and fully unload.

Offline hiro

  • Hero Member
  • *****
  • Posts: 1229
Re: system performance and flash
« Reply #5 on: January 28, 2012, 03:29:46 PM »
Rich, waht you say only happens here if I use the gtk framework with opera instead of plain X. That gtk or how it's used is not right.
in opera:config set File Selector > Dialog Toolkit to 4

I have loadas of problems with flash, too. So I block it by default and only have one swf running at a time (I understand how this is not always possible with complex sites like grooveshark though).

nomer

  • Guest
Re: system performance and flash
« Reply #6 on: January 28, 2012, 06:09:25 PM »
Hmmm.... memory, that is a very real possibility. And it does seem like the best explanation for the strange behavior.
Executing "free" in a terminal gives me something like this:
  totalusedfreesharedbuffers
Mem:503516 41767285844081668
-/+ buffers:336292 167224
Swap: 12587212579676

The hard drive has about 9 GB free out of ~38GB and Windows XP is installed on it. At this point I want to keep XP in a "working" state.
Creating a swap partition about 1 GB in size should be fairly safe, correct?
(This guide should do the trick, I think)

As an alternative, creating a swap file with "swapfile" should be fine correct?

Of course this machine has space for more RAM, and since RAM is relatively cheap, buying some more RAM would certainly be the best option (performance wise).

Thanks,
Nomer

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11631
Re: system performance and flash
« Reply #7 on: January 28, 2012, 08:41:49 PM »
Hi nomer
Before creating a partition, you should have Windows defrag the drive 2 or 3 times, as it doesn't
always manage to fully defrag on the first try. In addition to installing  gparted.tcz  you will also need
to install ntfsprogs.tcz.
Quote
As an alternative, creating a swap file with "swapfile" should be fine correct?
I don't think so. I'm pretty sure you want a Linux file system for that.
One Gig should be fine for a swap partition. When  gparted  asks for the file system type, just pick
swap.

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: system performance and flash
« Reply #8 on: January 28, 2012, 08:57:34 PM »
If you are swapping a Gig, you are impersonating a dead machine.

nomer

  • Guest
Re: system performance and flash
« Reply #9 on: January 29, 2012, 08:47:54 AM »
If you are swapping a Gig, you are impersonating a dead machine.
Really?
Hmmmm......... I was just reading this article
At one point it says:
Quote
[F]or a desktop system, use a swap space of double system memory, as it will allow you to run a large number of applications (many of which may will be idle and easily swapped), making more RAM available for the active applications[.]
In my case, twice my real memory would be 1 GB, but then the author says
Quote
[F]or older desktop machines (with say only 128MB), use as much swap space as you can spare, even up to 1GB.
A little confusing don't you think?  ???
Anyway, I think I'll fire up Windows and defrag the disk while I check what kind of RAM I need and what it might cost.

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: system performance and flash
« Reply #10 on: January 29, 2012, 10:52:06 AM »
That double the RAM suggestion originated when machines had a few Meg of RAM, not a few Gig.
If you start swapping a Gig of RAM, that's all you will be doing.

Offline maro

  • Hero Member
  • *****
  • Posts: 1228
Re: system performance and flash
« Reply #11 on: January 30, 2012, 01:18:11 AM »
Maybe not quite as good as a dedicated swap partition, but why not try to use a 1 GB swap file first before embarking on the possibly greater trouble to repartition the whole drive?

AFAIK it should be possible to create such a file on the NTFS partition, provided one uses the 'ntfs-3g.tcz' extension and mounts the partition in RW mode. Then create a large enough swap file (e.g. via sudo dd if=/dev/zero of=/mnt/sda1/swap_file count=1k bs=1M ; sudo mkswap /mnt/sda1/swap_file) and use it (e.g. via sudo swapon /mnt/sda1/swap_file). Of course the former will have to be done only once and the 'swapon' will need to be somehow integrated in the system start-up process (e.g. via '/opt/bootlocal.sh', conditional to the presence and write access to the swap file).


EDIT: Correction of a silly typo that Rich brought to my attention in reply #14.
« Last Edit: February 03, 2012, 03:12:15 AM by maro »

nomer

  • Guest
Re: system performance and flash
« Reply #12 on: January 31, 2012, 05:54:10 PM »
I've created a swap file on the hard drive using the tool in ControlPanel and I'm using the swap file, so I'll keep an eye out for any problems.
What are the benefits of using a dedicated partition? Do they outweigh the potential for data loss when shrinking the NTFS partition?
Ether way, I think that I'll pick one or two 1GB sticks some time soon here.

Thanks, everyone, for all your help,
Nomer

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: system performance and flash
« Reply #13 on: January 31, 2012, 06:24:31 PM »
There really is not much advantage to using a dedicated partition.
The kernel maps the swap file when it is opened, so there really is
no filesystem overhead to worry about.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11631
Re: system performance and flash
« Reply #14 on: January 31, 2012, 09:02:29 PM »
Hi maro
Speaking of swap, I think you have  if=  and  of=  swapped in your  dd  command.