Sporadic XRUNS / Linux

Official support for: bitwig.com
User avatar
KVRist
103 posts since 7 Apr, 2018

Post Mon Jan 07, 2019 10:09 am

Hi all,

currently I'm testing BITWIG (2.4.3) with DEBIAN / STRETCH and before spending 300 € I want to make sure that it's working without problems. So far I like it and I have little problems. I found two issues in the last days:

1) My system is optimized for audio and I get no xruns with other DAWs like Reaper or Renoise until average DSP loads of ~80-90%. With Bitwig I get very rarely (~2/hour) xruns even when the average DSP load shown in JACK (i.e. Cadence from KXStudio) is only ~15%.

2) Once the undo function for midi edits didn't work. After restarting Bitwig it was ok again. I read about that bug here at KVR and it should be solved.

My system:

Code: Select all

System:    Host: fox Kernel: 4.9.0-8-rt-amd64 x86_64 (64 bit)
           Desktop: Xfce 4.12.3 Distro: Debian GNU/Linux 9 (stretch)
Machine:   Device: desktop Mobo: MSI model: H81M-E34 (MS-7817) v: 3.0
           BIOS: American Megatrends v: V17.5 date: 03/30/2015
CPU:       Quad core Intel Core i5-4460 (-MCP-) cache: 6144 KB 
           clock speeds: max: 3400 MHz 1: 3236 MHz 2: 3289 MHz 3: 3254 MHz
           4: 3296 MHz
Graphics:  Card: Intel Xeon E3-1200 v3/4th Gen Core Processor Integrated Graphics Controller
           Display Server: X.Org 1.19.2 drivers: modesetting (unloaded: fbdev,vesa)
           Resolution: 1920x1080@60.00hz
           GLX Renderer: Mesa DRI Intel Haswell Desktop
           GLX Version: 3.0 Mesa 13.0.6
Audio:     Card-1 Intel 8 Series/C220 Series High Definition Audio Controller
           driver: snd_hda_intel
           Card-2 Intel Xeon E3-1200 v3/4th Gen Core Processor HD Audio Controller
           driver: snd_hda_intel
           Card-3 AKAI Professional M.I. LPK25 MIDI Keyboard
           driver: USB Audio
           Card-4 ZOOM driver: USB Audio
           Sound: Advanced Linux Sound Architecture v: k4.9.0-8-rt-amd64
Network:   Card: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller
           driver: r8169
           IF: enp2s0 state: up speed: 1000 Mbps duplex: full
           mac: d8:cb:8a:e8:e9:99
Drives:    HDD Total Size: 500.1GB (16.8% used)
           ID-1: /dev/sdb model: Samsung_SSD_850 size: 250.1GB
           ID-2: USB /dev/sda model: Portable_SSD_T5 size: 250.1GB
Partition: ID-1: / size: 28G used: 15G (58%) fs: ext4 dev: /dev/sdb1
           ID-2: /home size: 194G used: 43G (24%) fs: ext4 dev: /dev/sdb6
           ID-3: swap-1 size: 7.99GB used: 0.00GB (0%) fs: swap dev: /dev/sdb5
Sensors:   System Temperatures: cpu: 38.0C mobo: 44.0C
           Fan Speeds (in rpm): cpu: 870 fan-1: 770 fan-3: 0 fan-4: 0 fan-5: 0
Info:      Processes: 206 Uptime: 1:19 Memory: 2330.9/7422.9MB
           Client: Shell (bash) inxi: 2.3.5 

KVRian
786 posts since 26 May, 2013 from France, Sisteron

Post Tue Jan 08, 2019 6:57 am

Try this:
sudo cpupower frequency-set -g performance

User avatar
KVRist

Topic Starter

103 posts since 7 Apr, 2018

Post Tue Jan 08, 2019 8:15 am

I've done this already. I'll play more to see what's the problem. Thanks.

It's seen in the DSP load. A spike out of nowhere:

https://imgur.com/a/UDl6BKa

KVRian
786 posts since 26 May, 2013 from France, Sisteron

Post Tue Jan 08, 2019 8:27 am

Please can you try this script in the mean time? https://github.com/raboof/realtimeconfigquickscan

User avatar
KVRist

Topic Starter

103 posts since 7 Apr, 2018

Post Tue Jan 08, 2019 8:37 am

Thanks for helping:

== GUI-enabled checks ==
Checking if you are root... no - good
Checking filesystem 'noatime' parameter... 4.9.0 kernel - good
(relatime is default since 2.6.30)
Checking CPU Governors... CPU 0: 'performance' CPU 1: 'performance' CPU 2: 'performance' CPU 3: 'performance' - good
Checking swappiness... 10 - good
Checking for resource-intensive background processes... none found - good
Checking checking sysctl inotify max_user_watches... < 524288 - not good
increase max_user_watches by adding 'fs.inotify.max_user_watches = 524288' to /etc/sysctl.conf and rebooting
For more information, see http://wiki.linuxaudio.org/wiki/system_ ... sysctlconf
Checking access to the high precision event timer... readable - good
Checking access to the real-time clock... readable - good
Checking whether you're in the 'audio' group... yes - good
Checking for multiple 'audio' groups... no - good
Checking the ability to prioritize processes with chrt... yes - good
Checking kernel support for high resolution timers... found - good
Kernel with Real-Time Preemption... found - good
Checking if kernel system timer is high-resolution... found - good
Checking kernel support for tickless timer... found - good
== Other checks ==
Checking filesystem types... ok.
** Set $SOUND_CARD_IRQ to the IRQ of your soundcard to enable more checks.
Find your sound card's IRQ by looking at '/proc/interrupts' and lspci.

And here's the outcome of benchmark test:


Samplerate 48000
Buffersize is 528
jack running with realtime priority
Xrun 1 at DSP load 97.838287
in complete 1 Xruns in 44758 circles
first Xrun happen at DSP load 97.838287 circle 44755

https://linuxmusicians.com/viewtopic.ph ... 8&start=45

User avatar
KVRist

Topic Starter

103 posts since 7 Apr, 2018

Post Wed Jan 16, 2019 7:47 am

no one with similar problems?

User avatar
KVRist
82 posts since 25 Jul, 2014

Post Wed Jan 16, 2019 8:14 am

so, jsut to make sure i'm reading you right. you consider 1 xrun atr high load a problem? a single xrun?

User avatar
KVRist

Topic Starter

103 posts since 7 Apr, 2018

Post Wed Jan 16, 2019 9:36 am

No, of course that's not the problem. The point is that I get xruns with a moderate load of 12%. The question is where the spikes come from.

User avatar
KVRist

Topic Starter

103 posts since 7 Apr, 2018

Post Sat Jun 06, 2020 1:14 pm

Was trying 3.1.3 on a new installation and I'm still getting these sporadic xruns with Debian Buster. Sometimes 10 or more in a row, sometimes none for 30 min playing the same 1 bar loop. The average DSP load is quite low with ~10-20 %. I also tried the "Suspend Never" option in the VST settings.

Another observation: When activating the Multicore option in e.g. DIVA the DSP load goes down a lot. I thought that Bitwig uses multicore support, so why is there any difference at all?

That does not happen with e.g. Reaper or Renoise.

KVRian
786 posts since 26 May, 2013 from France, Sisteron

Post Sat Jun 06, 2020 10:42 pm

Of course you want multicore in Diva, and yes Bitwig process in parallel but it can't process in parallel a single plugin instance, this is the plugin job to process its own voices in parallel.
Do you have those xruns when only using bitwig devices? Does the demo project have xruns as well?
Can you send your project to support@bitwig.com and explain your issue?
Cheers,
Alex

User avatar
KVRist

Topic Starter

103 posts since 7 Apr, 2018

Post Sun Jun 07, 2020 6:12 am

abique wrote:
Sat Jun 06, 2020 10:42 pm
Of course you want multicore in Diva, and yes Bitwig process in parallel but it can't process in parallel a single plugin instance, this is the plugin job to process its own voices in parallel.
Do you have those xruns when only using bitwig devices? Does the demo project have xruns as well?
Can you send your project to support@bitwig.com and explain your issue?
Cheers,
Alex
Hi Alex,

I have the demo songs running for an hour or so without any xrun yet. So the problem may only affect external VSTs (e.g. DIVA or Zynfusion, I tested both and got xruns with both).

I don't have Bitwig installed and just execute the bitwig-studio file in the /opt folder, but I guess that should not be the reason for my issues. As I didn't buy Bitwig yet because of that issue I also can't save any example project. I can ask the support, but there are also quite some other threads with similar issues.

https://answers.bitwig.com/questions/15 ... age-spikes
https://answers.bitwig.com/questions/20 ... inux-xruns
viewtopic.php?t=511856

User avatar
KVRist

Topic Starter

103 posts since 7 Apr, 2018

Post Sun Jun 07, 2020 10:04 am

edit: Seems to happen only with Jack. With Alsa it seems to be ok. Is there a way to log xruns from Alsa?

KVRian
786 posts since 26 May, 2013 from France, Sisteron

Post Sun Jun 07, 2020 11:29 pm

No, our alsa backend does not log xruns. You need to hear them.

User avatar
KVRist

Topic Starter

103 posts since 7 Apr, 2018

Post Tue Jun 09, 2020 7:39 am

abique wrote:
Sun Jun 07, 2020 11:29 pm
No, our alsa backend does not log xruns. You need to hear them.
I was testing Bitwig 3.2 on a laptop yesterday with Jack and Alsa. With Alsa it seems to be ok. With Jack also, but only if I enable the "Server Synchronous Mode" in Jack, i.e. Jack2 behaves like Jack1.

When using Jack without that mode I get xruns reported sometimes in Jack, but the DSP meter in Bitwig is not peaking. Sometimes it is peaking and I also get xruns (the way it should be). For instance when loading devices or opening programs or also spontaneously I'm getting xruns sometimes.

Back on my Desktop PC with Jack and Bitwig 3.2 all seems to be fine when using "Server Synchronous Mode". But now it is also good without using "Server Synchronous Mode" (have to test longer though).

Was there a change in Bitwig 3.2. that might improve this and is there any explanation why I need "Server Synchronous Mode" to be activated?

Beside of that Bitwig is super stable and I'll buy it. :tu:

User avatar
KVRist

Topic Starter

103 posts since 7 Apr, 2018

Post Sat Jun 13, 2020 10:33 am

After some more testing I'm also getting xruns with Server Synchronous Mode and with plain Alsa.
Yesterday I installed the Liquorix kernel and I was running Bitwig fine for 8 hours without any xrun.
Now again with the Liquorix kernel I already got 4 again. And this is with moderate DSP loads of ~20%.

Wonder if it makes sense to install another Distro (e.g. Ubuntu-Studio), but as other DAWs don't make any single xrun I wonder what's different in Bitwig and what can be done to "fix" it on my side.

Anyone else on Linux with similar issues?

As I just execute the binary does installing Bitwig make any change here?

There's a xruncounterscript which is basically a stress test (https://github.com/Gimmeapill/xruncounter) When executing this it reports usually the first xrun at ~98.5 % DSP load, so I guess my system is optimized. When this xrun occurs I don't see it in the Bitwig DSP meter.

On the other hand when I'm getting the spikes they are visible in Bitwig's DSP meter. Does this mean that these xruns are caused by Bitwig and not by any other processes of my system?

Sometimes I even get spikes when transport in Bitwig is off.

Example for spike:
Image

Some more info about the system:

Code: Select all

  Host: marco Kernel: 5.6.0-18.1-liquorix-amd64 x86_64 bits: 64 
  Desktop: Xfce 4.12.4 Distro: Debian GNU/Linux 10 (buster) 
Machine:
  Type: Desktop Mobo: MSI model: H81M-E34 (MS-7817) v: 3.0 
  serial: <root required> BIOS: American Megatrends v: 17.5 date: 03/30/2015 
CPU:
  Topology: Quad Core model: Intel Core i5-4460 bits: 64 type: MCP 
  L2 cache: 6144 KiB 
  Speed: 3216 MHz min/max: 800/3201 MHz Core speeds (MHz): 1: 3216 2: 3277 
  3: 3282 4: 3304 
Graphics:
  Device-1: Intel Xeon E3-1200 v3/4th Gen Core Processor Integrated Graphics 
  driver: i915 v: kernel 
  Display: x11 server: X.Org 1.20.4 driver: modesetting unloaded: fbdev,vesa 
  resolution: 1920x1080~60Hz 
  OpenGL: renderer: Mesa DRI Intel Haswell Desktop v: 4.5 Mesa 18.3.6 
Audio:
  Device-1: Intel Xeon E3-1200 v3/4th Gen Core Processor HD Audio 
  driver: N/A 
  Device-2: AKAI Professional M.I. type: USB 
  driver: hid-generic,snd-usb-audio,usbhid 
  Device-3: BEHRINGER type: USB driver: snd-usb-audio 
  Sound Server: ALSA v: k5.6.0-18.1-liquorix-amd64 
Network:
  Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet 
  driver: r8169 
  IF: enp2s0 state: up speed: 1000 Mbps duplex: full mac: d8:cb:8a:e8:e9:99 
Drives:
  Local Storage: total: 523.08 GiB used: 160.51 GiB (30.7%) 
  ID-1: /dev/sda vendor: Samsung model: SSD 850 EVO 250GB size: 232.89 GiB 
  ID-2: /dev/sdb type: USB vendor: Samsung model: Portable SSD T5 
  size: 232.89 GiB 
  ID-3: /dev/sdc type: USB vendor: SanDisk model: Ultra size: 57.30 GiB 
Partition:
  ID-1: / size: 27.37 GiB used: 12.85 GiB (46.9%) fs: ext4 dev: /dev/sda1 
  ID-2: /home size: 193.40 GiB used: 82.18 GiB (42.5%) fs: ext4 
  dev: /dev/sda6 
  ID-3: swap-1 size: 7.44 GiB used: 0 KiB (0.0%) fs: swap dev: /dev/sda5 
Sensors:
  System Temperatures: cpu: 45.5 C mobo: 43.0 C 
  Fan Speeds (RPM): cpu: 1019 fan-1: 777 fan-3: 0 fan-4: 0 fan-5: 0 
Info:
  Processes: 236 Uptime: 1h 28m Memory: 7.23 GiB used: 3.68 GiB (50.9%) 
  Shell: bash inxi: 3.0.32 

Code: Select all

~/realtimeconfig/realtimeconfigquickscan$ ./realTimeConfigQuickScan.pl 
== GUI-enabled checks ==
Checking if you are root... no - good
Checking filesystem 'noatime' parameter... 5.6.0 kernel - good
(relatime is default since 2.6.30)
Checking CPU Governors... CPU 0: 'performance' CPU 1: 'performance' CPU 2: 'performance' CPU 3: 'performance'  - good
Checking swappiness... 10 - good
Checking for resource-intensive background processes... none found - good
Checking checking sysctl inotify max_user_watches... >= 524288 - good
Checking access to the high precision event timer... readable - good
Checking access to the real-time clock... readable - good
Checking whether you're in the 'audio' group... yes - good
Checking for multiple 'audio' groups... no - good
Checking the ability to prioritize processes with chrt... yes - good
Checking kernel support for high resolution timers... found - good
Kernel with Real-Time Preemption... not found - not good
Kernel without real-time capabilities found
For more information, see http://wiki.linuxaudio.org/wiki/system_configuration#installing_a_real-time_kernel
Checking if kernel system timer is high-resolution... found - good
Checking kernel support for tickless timer... found - good
== Other checks ==
Checking filesystem types... ok.
** Set $SOUND_CARD_IRQ to the IRQ of your soundcard to enable more checks.
   Find your sound card's IRQ by looking at '/proc/interrupts' and lspci.
Last edited by lilith93 on Sat Jun 13, 2020 2:41 pm, edited 1 time in total.

Return to “Bitwig”