I've been updating my themes today and all of a sudden something seems to have happened that is causing the HouseBot server to go to 100% CPU. I haven't yet been able to figure out what has changed but it only seems to happen when I am editing themes. It is using so much CPU that sometimes I can't effectively use Task Manager to stop it (it would take forever) so I just have to reboot the server.
Some of my themes are getting pretty large (the XML file for the one I have been working on today is now 192K and has 20 panels). Do you think I may be hitting some kind of memory issue? I don't seem to have a problem when using the theme in a software remote although I did notice something odd when using the theme on my ViewPad. I went to a popup panel and the first time I opened it everything looked normal. I closed it and opened it again and the second time most of the panel background was white video rather than the standard background I had selected from the Meedio Violet skin. I don't see this same behavior when using the software remote on my PC. Any ideas?
100% CPU usage when editing themes
-
- HouseBot Special Member
- Posts: 409
- Joined: Tue Jul 13, 2004 9:13 am
- Location: Tigard, OR
The size of your Theme shouldn't be causing the CPU issue. If memory is the issue, you should be able to see it in the Task Manager, and you would notice a lot of paging (disk activity).
I know there's an issue with the serial port plugin, where if the comm port setting isn't correct, or the device isn't attached, the CPU sometimes goes very high.
Make sure you don't have any really huge graphic files in the Theme. Large images take longer to load and more memory to manage. They also take much longer to send to the clients. Since the Software Remotes generally run on machines with much less memory than the server, they can be memory issues for the clients. The issue you are describing with the popup panel sounds like it might be memory related.
I know there's an issue with the serial port plugin, where if the comm port setting isn't correct, or the device isn't attached, the CPU sometimes goes very high.
Make sure you don't have any really huge graphic files in the Theme. Large images take longer to load and more memory to manage. They also take much longer to send to the clients. Since the Software Remotes generally run on machines with much less memory than the server, they can be memory issues for the clients. The issue you are describing with the popup panel sounds like it might be memory related.
Scott
-
- Member
- Posts: 42
- Joined: Thu Mar 18, 2004 9:51 am
I am also having this problem. I am also using the Generic Serial plug-in, however my devices using it aren't experiencing problems (that I am aware of), and it seems like a coincidence that it only happens while editing themes.
My theme is very small with minimal graphics and only four panels. Memory using isn't out of the ordinary, nor is it swapping while it does this. As far as I can see in Task Manager, HouseBot is simply spinning in a tight loop. Memory usage is flat while it does this. Sometimes it eventually breaks out of the loop, but most of the time it doesn't.
My theme is very small with minimal graphics and only four panels. Memory using isn't out of the ordinary, nor is it swapping while it does this. As far as I can see in Task Manager, HouseBot is simply spinning in a tight loop. Memory usage is flat while it does this. Sometimes it eventually breaks out of the loop, but most of the time it doesn't.
-
- HouseBot Special Member
- Posts: 409
- Joined: Tue Jul 13, 2004 9:13 am
- Location: Tigard, OR
I don't think this is probably related and I haven't been able to reproduce it at will so I haven't logged it yet - but - I have exeperienced many times where I have an X86 software remote running on my main PC and I'll be working in some other application and things start to slow down.
What I have discovered in these cases is that my CPU usage is 100% and the culprit is always the software remote. In these cases I've found that all I have to do is minimize the software remote and the CPU usage drops back to normal (even if I immediately restore the software remote again).
-- Dave
What I have discovered in these cases is that my CPU usage is 100% and the culprit is always the software remote. In these cases I've found that all I have to do is minimize the software remote and the CPU usage drops back to normal (even if I immediately restore the software remote again).
-- Dave
-
- Member
- Posts: 42
- Joined: Thu Mar 18, 2004 9:51 am
I think I have close to 100% repro case. I'm downloading HouseBot on my virgin machine here at work to try it.
I have a single theme (in addition to the sample theme which I never deleted, but of course don't use) with no graphics outside the 'dark' skin which has four tabs. Except for the background, which is the 640x480 image scaled up to 800x600.
When I'm using the software remote, I notice one problem or another with my theme and say to myself "crap! I need to fix that". So I quit the software remote (the theme editor seems to crash if I don't) and go about adding the button I need or editing the property change value on an existing button.
At this point, the cpu utilization goes up to 100%. Sometimes if I just let it go for a while, it calms down and becomes responsive again.
Whenever the theme editor comes up with the properites window clipping it, this seems to almost always happen. I access HouseBot in one of three different ways: 1024x768 local display, 800x600 remote desktop from a tablet, or 1280x1024 remote desktop from my development machine. At first I was developing most of my theme using the larger display where the properties window was never clipping the theme editor, but I started noticing this when accessing the theme editor from the lower resolution displays.
When the theme editor comes up with the properties window clipping part of it (on any sized display), the theme editor never displays properly. The tabs don't draw and there's parts of the application window which obviously didn't update properly. If I move the properties window around, this straightens itself out. Things are acting OK at this point so far until I add or change a button.
If the theme editor comes up with the properties window not clipping it, things seem to work fine.
By the way, if the properties window was last left outside of the now displayable area, it should move itself so it is visible.
EDIT: Installed a fresh copy on a virgin machine at my office, and I couldn't reproduce this. Even tried setting the affinity mask on the process to emulate not having HT (my HouseBot server is neither SMP nor HT). Could be due to a race condition that doesn't show up on faster machines? I'd be willing to send you my configuration if it would be helpful.
I have a single theme (in addition to the sample theme which I never deleted, but of course don't use) with no graphics outside the 'dark' skin which has four tabs. Except for the background, which is the 640x480 image scaled up to 800x600.
When I'm using the software remote, I notice one problem or another with my theme and say to myself "crap! I need to fix that". So I quit the software remote (the theme editor seems to crash if I don't) and go about adding the button I need or editing the property change value on an existing button.
At this point, the cpu utilization goes up to 100%. Sometimes if I just let it go for a while, it calms down and becomes responsive again.
Whenever the theme editor comes up with the properites window clipping it, this seems to almost always happen. I access HouseBot in one of three different ways: 1024x768 local display, 800x600 remote desktop from a tablet, or 1280x1024 remote desktop from my development machine. At first I was developing most of my theme using the larger display where the properties window was never clipping the theme editor, but I started noticing this when accessing the theme editor from the lower resolution displays.
When the theme editor comes up with the properties window clipping part of it (on any sized display), the theme editor never displays properly. The tabs don't draw and there's parts of the application window which obviously didn't update properly. If I move the properties window around, this straightens itself out. Things are acting OK at this point so far until I add or change a button.
If the theme editor comes up with the properties window not clipping it, things seem to work fine.
By the way, if the properties window was last left outside of the now displayable area, it should move itself so it is visible.
EDIT: Installed a fresh copy on a virgin machine at my office, and I couldn't reproduce this. Even tried setting the affinity mask on the process to emulate not having HT (my HouseBot server is neither SMP nor HT). Could be due to a race condition that doesn't show up on faster machines? I'd be willing to send you my configuration if it would be helpful.