Thank you for your donation!


Cloudsmith graciously provides open-source package management and distribution for our project.


Local display function fails with HDMI in moOde 7.0.1
#71
Thumbs Up 
   
(05-03-2021, 03:27 PM)pmartin Wrote: Try Firefox to solve the Chromium memory bug
Note: this is only a try and is working with one Raspberry Pi 4B whith 2GB of RAM, an Allo Boss DAC Hat, Rotary encoder for volume with button for play/pause (mpc toggle) and a 3,5" HDMI display.

I checked Firefox-esr and this browser is not affected by the memory leak.
I checked for 2 days and still works stable.
Firefox includes a kiosk mode but does not use the whole screen when invoked from .xinitrc, leaving a vertical black border on the right and another one at the bottom of the screen.  

When Firefox runs from a window manager it works right in kiosk mode filling all the diaplay. The lightest window manager I know is awesome.

I tested to start localui running awesome. In awesome config I put autostart of Firefox in kiosk mode.

To check  firefox  with the localui service:


Open a console and install Firefox:


Code:
sudo apt-get install firefox-esr


Install the awesome window manager

Code:
sudo apt-get install awesome


Modify the .xinitrc to run awesome only

Code:
sudo nano /home/pi/.xinitrc

Comment with # chromium command and write as last line:
  
awesome
 
Type  CTRL+0 enter CTRLX to save and close nano editor

Modify /etc/xdg/awesome/awesome/rc.lua to start Firefox with the awesome session

Code:
sudo nano /etc/xdg/awesome/rc.lua

 Paste  this code at the end of file:
Code:
autorun = true
autorunApps =
{
  "/usr/bin/firefox-esr --kiosk --private-window http://localhost",
}
if autorun then
  for app = 1, #autorunApps do
      awful.util.spawn(autorunApps[app])
  end
end

Type  CTRL+0 enter CTRLX to save file and close nano editor

Test the new localui with Firefox typing:
sudo systemctl stop localui
sudo systemctl start localui

If Firefox show bookmarks or other tabs, stop localui and Firefox and just delete all files in folder /home/pi/.mozilla
@pmartin: Awesome, you provided the successful solution to overcome the chromium browser bug that swallows after a certain time the available memory, which resulted in the moode player being non responsive to any command.
With your solution to replace chromium-browser by firefox-esr resolves the issue and moode audio player just continues to play flawlessly.
Great work. thx a lot. Smile

Comments:
When I followed your procedure, I first got error messages when trying to install firefox-esr. That was due to non up to date dependencies, which were quickly resolved by executing the following command at the beginning:
Code:
sudo apt update
I also had to follow your recommendations to overcome the firefox bookmarks / tabs by deleting everything that's inside the /home/pi/.mozilla folder.
After everything worked fine, I also got rid off by everything that was related to chromium:

Code:
sudo apt purge --remove chromium-browser
sudo apt autoremove
sudo apt autoclean
The system is now working since 24+ hours and is not showing any memory degradation.

@Tim & Alaini93: To your question whether this could be due to a faulty RPi 3B+: The answer is No. I had seen this issue now on two different RPi 3B+ and one RPi 4 with 2GB RAM.

@Kent: I read your comprehensive writing about pros and cons to swap the browser. My feedback is that pmartin's proposal is the solution. moode 7.2.0 is just working great again.

thx to all who contribute to this great forum.

Smile
brgds,
Gerhard
Reply
#72
Does it support the auto-hiding overlay scrollbars or are the scrollbars white and always visible?
Enjoy the Music!
moodeaudio.org | Mastodon Feed | GitHub
Reply
#73
       
(05-07-2021, 01:16 PM)Tim Curtis Wrote: Does it support the auto-hiding overlay scrollbars or are the scrollbars white and always visible?

Yes it does support auto-hiding scrollbars. See the attached pictures.
brgds,
Gerhard
Reply
#74
Please post a pic of either Playback view or Tag view. Scrollbars would appear for the Queue list in Playback view or for the Genre/Artist/Album lists in Tag view.
Enjoy the Music!
moodeaudio.org | Mastodon Feed | GitHub
Reply
#75
(05-07-2021, 03:20 PM)Tim Curtis Wrote: Please post a pic of either Playback view or Tag view. Scrollbars would appear for the Queue list in Playback view or for the Genre/Artist/Album lists in Tag view.

Hi Tim,

see attached pictures showing how the UI looks in firefox for
  • tag view
  • playback (short w/o scrollbar & long w/ scrollbar)
  • coverview (setup to automatically switch to cover view after 2 mins)
Hope this addresses your question.
               
brgds,
Gerhard
Reply
#76
Hopefully there is a command line --arg that can enable overlay scrollbars cos those default white ones are really ugly!
Enjoy the Music!
moodeaudio.org | Mastodon Feed | GitHub
Reply
#77
Thanks @pmartin
Firefox is working great, I have been on pause for 7 hours and no problem, moOde is still on.
Reply
#78
I was able to run test today with an HDMI connected display and after 6 hours no issues whatsoever. Memory didn't increase, processor utilization was fine. The system was a Pi-3B+ with Katana DAC and I just left the Stereo Test track paused when I started the test.
Enjoy the Music!
moodeaudio.org | Mastodon Feed | GitHub
Reply
#79
Hi everyone,

I’m concern about the issue.
I use moode and other similar distribution.

I always have trouble when i size up the library handled.
Moode audio was working fine for month and recently i add some more folders to the library and moode audio begin to glitch every 3 or 4 days.
Actually memory leak appear in minutes when i enabled local display.
When free memory is below 40 Mo system is unresponsive and it takes a few minutes before a sudo reboot responds

Can chromium issue be related to library size ?
Perhaps an heavy JS function loaded with categories or music genre or other stuff.

Actual library is about 70k files and 12k Thumbnail
Firefox workaround looks great.

Best regards

About 15 minutes after pausing playlist:

24 Mb free Chromium over 71% of memory usage

top - 18:53:22 up  1:04,  1 user,  load average: 22.28, 18.00, 10.51
Tasks: 177 total,   1 running, 176 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.1 us,  6.3 sy,  0.0 ni,  1.3 id, 92.0 wa,  0.0 hi,  0.3 si,  0.0 st
MiB Mem :    924.8 total,     24.3 free,    856.5 used,     44.1 buff/cache
MiB Swap:      0.0 total,      0.0 free,      0.0 used.      8.7 avail Mem

 PID USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND
  61 root      20   0       0      0      0 S  38.2   0.0   2:08.12 kswapd0
  76 root       0 -20       0      0      0 D   8.1   0.0   0:30.83 kworker/0+
3295 pi        20   0  571608  22136     88 D   2.8   2.3   0:30.21 chromium-+
 877 root      20   0  104716   1024      0 S   1.6   0.1   0:31.92 shairport+
3416 pi        20   0 1118108 677024   4680 D   1.6  71.5  20:07.43 chromium-+
 879 upmpdcli  20   0  222332   1608      0 S   1.4   0.2   0:13.36 upmpdcli
11248 root       0 -20       0      0      0 I   1.3   0.0   0:04.92 kworker/0+
3407 pi        20   0  270440  19632   4476 S   1.2   2.1   1:45.98 chromium-+
 893 root      20   0  133520   1352      0 S   1.1   0.1   0:08.59 djmount
3999 pi        20   0   10676   1264    628 R   1.0   0.1   0:23.13 top
3357 pi        20   0  280128   8048    140 S   0.9   0.8   0:13.21 chromium-+
   9 root      20   0       0      0      0 S   0.7   0.0   0:05.47 ksoftirqd+
Reply


Forum Jump: