[mythtv-users] mythweb performance: windows vs. linux

Niels Dybdahl Niels at Dybdahl.dk
Wed Mar 15 08:08:30 UTC 2006


On 3/15/06, Rusty McEacharn <mceachrw at gmail.com> wrote:
>
> i just upgraded to .19 from .18.1 and spent three hours last night trying
> to improve the performance of mythweb.  i read every recent post about
> slowness and tried the following with no success:
> -optimize_mythdb.pl
> -move the .htaccess directives to httpd.conf
> -add the following to my.conf
>     key_buffer = 48M
>     max_allowed_packet = 8M
>     table_cache = 128
>     sort_buffer_size = 48M
>     net_buffer_length = 8M
>     thread_cache_size = 4
>     query_cache_type = 1
>     query_cache_size = 4M


It seems you did not read my postings...


the backend performs fine.  performance before and after the upgrade is
> similar.  but, i normally use mythweb from my desktop box (winxp) and .19
> performance is horrible.  so...i stuck a live linux cd in my windows box.
> to my surprise, .19 performance was as it should be.  can a few dual booters
> out there do some testing to confirm this problem?  other suggestions to fix
> this?
>
> backend: 700 mhz celeron, i810, 256 mb ram, fc3 up to date using atrpms
> desktop (windows): a64 3000, nf4, 1000 mb ram, xp pro up to date using
> windows update
> desktop (live linux): same hardware running slax v5.0.7 using copy2ram,
> like knoppix with everything in ram
>
> page load times
> live linux        windows      task
> 9 sec            38 sec         listings, ~150 channels
> 3 sec            30 sec         recorded programs, 7 episodes
> 1 sec            1 sec           backend status
> 3 sec            30 sec         upcoming recordings
> 3 sec            30 sec         search



I had three problems. The first was that the all *.js files were retrieved
for every single page. Look into the apache log file (/var/log/http/...) if
that is the case. After I had switched between different browsers and tried
to open the mouseovers.js file explicitly in a browser, that problem
disappeared and the load time for a listings page dropped from 40 seconds to
12 seconds.

The second problem was due to my high number of recording schedules. The
program listings page retrieves extra information for every single program
that has been set to be recorded, no matter if the program is within the
displayed time frame or not. And I have around 200 scheduled recordings each
week... I fixed it by commenting the following lines out of the file
/var/www/html/mythweb/includes/programs.php:

/*            elseif ($this->chanid) {
                unset($this->filename);
            // Kludge to avoid redefining the object, which doesn't work in
php5
                $tmp = @get_object_vars(load_one_program($this->starttime,
$this->chanid));
                if (is_array($tmp) && count($tmp) > 0) {
                    foreach ($tmp as $key => $value) {
                        $this->$key = $value;
                    }
                }
            }*/

Somebody stated that it does not work with a Safari browser on MacOSX. I
have tested my setup on a Safari browser and it works. I still has not found
any missing information in any of the MythWeb pages, so the lines above seem
unnecessary. The time needed to load the page is now down to 2 seconds.

The third problem is related to the recorded programs page. MythWeb still
runs through all programs to see if their icons are missing or something
like that. Apparently it has problems regenerating a couple of them, and
that slows the page down. I do not use that page very much, so I have not
looked deeper into that problem.

Niels Dybdahl
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mythtv.org/pipermail/mythtv-users/attachments/20060315/2b281bef/attachment-0001.htm 


More information about the mythtv-users mailing list