Opened 6 years ago

Closed 5 years ago

#12124 closed Bug Report - General (Invalid)

High cpu usage by mythfrontend process in standby when backend is recording

Reported by: finlay@… Owned by:
Priority: minor Milestone: unknown
Component: MythTV - General Version: 0.27-fixes
Severity: low Keywords:
Cc: Ticket locked: no

Description

The mythfrontend process which is in standby mode on a dedicated frontend exhibits an increase in cpu usage (from ~2% to 30-60%) when the backend is recording. When the backend finishes recording the cpu usage returns to the 2% range. The mythfrontend process in standby mode on the backend does not exhibit this increase in cpu usage. If standby mode is disabled for the mythfrontend process then not change in cpu usage is exhibited.

All frontends and the backend are running Mythbuntu 12.04 and fixes/0.27.

Change History (13)

comment:1 Changed 6 years ago by finlay@…

In some cases when the backend recording is finished the high cpu usage of the mythfrontend processes in standby on the dedicated FEs continues. If the mythfrontend is activated the cpu usage drops to the normal range.

The workaround for this problem is to disable standby mode for mythfrontend.

comment:2 Changed 6 years ago by finlay@…

The cpu usage when mythfrontend is in standby mode can be as high as 120% (reported by top) when logging is set to --verbose all,nodatabase. The cpu usage returns to the normal 1% or so when mythfrontend exits standby.

comment:3 Changed 5 years ago by JYA

Resolution: Won't Fix
Status: newclosed

-v all is very verbose. Don't use that

comment:4 Changed 5 years ago by finlay@…

Resolution: Won't Fix
Status: closednew

The problem is the use of frontend standby mode not the use of the -v all which I just added to see if there were any messages that would reveal the problem of increased CPU usage when standby mode kicks in. I normally run without the -v setting and the CPU usage is high (30%-60%) when the frontend is in standby and the backend starts recording. I would have assumed that standby mode would result in a lessening of CPU usage. It appears as if there is some busy wait polling started on the frontend when the backend starts recording.

comment:5 Changed 5 years ago by paulh

Is this on a combined FE/BE or standalone FE?

comment:6 Changed 5 years ago by finlay@…

Standalone frontend.

comment:7 Changed 5 years ago by paulh

I can't reproduce this on master.

What theme are you using? Just wondering if there some kind of animation showing the recording state that's using the cpu?

comment:8 Changed 5 years ago by finlay@…

I'm running a mythbuntu 12.04 system for the frontend and I'm using the mythbuntu theme which provides a status indication for the backend while in standby mode e.g. "Backend is idle" and "Backend is recording". It's not an active animation per se but a fairly static display including a square which is colored green when the backend is recording and colored gray otherwise.

comment:9 Changed 5 years ago by paulh

The MythBuntu? theme uses an alphapulse animation for the recording state which on my system increases the cpu by about 7% when recording.

Can you try to reproduce it when using the MythCenter?-wide theme.

Which paint engine are you using (on the first page of the Appearance settings)?

comment:10 Changed 5 years ago by finlay@…

I get a change from 2% to 20% (or more) when using the mythbuntu theme and opengl paint engine.

The increased CPU usage is not exhibited when using the mythcenter-wide theme and opengl i.e. the CPU usage stays at 2%.

comment:11 Changed 5 years ago by jhecker@…

I have a similar problem.

I think it happened in 0.27 fixes and it's still happening in 0.28.

When the FE log shows: N CoreContext?? mythmainwindow.cpp:2781 (IdleTimeout??) Entering standby mode after 90 minutes of inactivity

The CPU use of FE goes to 100% even in the root menu. I have to quit FE to get the CPU use back to a few %.

I have the standby timer in FE set to 0 now to disable standby mode (was 90 min) but it hasn't helped.

Mythbuntu 14.04 Kernel 3.16

comment:12 in reply to:  11 Changed 5 years ago by paulh

Replying to jhecker@…:

I have a similar problem.

I think it happened in 0.27 fixes and it's still happening in 0.28.

When the FE log shows: N CoreContext?? mythmainwindow.cpp:2781 (IdleTimeout??) Entering standby mode after 90 minutes of inactivity

The CPU use of FE goes to 100% even in the root menu. I have to quit FE to get the CPU use back to a few %.

I have the standby timer in FE set to 0 now to disable standby mode (was 90 min) but it hasn't helped.

Mythbuntu 14.04 Kernel 3.16

I don't think you are seeing the same problem as the OP if you seeing it in the main menu as well.

comment:13 Changed 5 years ago by paulh

Resolution: Invalid
Status: newclosed

This is normal it's just the MythBuntu? theme uses an alphapulse animation when in standby mode which can cause excessive cpu usage on some systems.

Note: See TracTickets for help on using tickets.