1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Frustrated with Mint 16

Discussion in 'General Linux Discussion' started by booman, Apr 9, 2014.

  1. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    I was going to try Mint 16 64-bit because I read if you use 64-bit Wine the problem doesn't exist, but then I realized that these games all require 32-bit virtual drives and PlayOnLinux is only 32-bit. So it probably won't change anything.
    I also downloaded Ubuntu 14.10 Beta, but I hesitate to try it out. I've never really been "into" betas because they can be buggy.
    I totally agree with you Allenskd, Cinnamon does use a lot of resources out-of-the-box. Not exactly sure why, but since I was originally a Windows guy, it was even worse! With today's fast hardware its not so bad, but with Wineserver running in the background I am wasting a lot of resources. I have even tried Openbox DM with these problems and of course the audio issues still exist.
    Right now I'm writing up everything I have done and will post on the LinuxMint forum to see if anyone else has dealt with this.
    I have done your Alsa underrun tutorial two or three times and am still having the problem. Maybe I'm doing it wrong.
    One thing that confuses me is that i have a default.pa in two places:
    • /etc/pulse/default.pa
    • /home/booman/.pulse/default.pa
    If I make a change to one, do I have to make changes to the other? Which takes precedence over the other?
    I also noticed that pulseaudio in the system monitor has a Priority of "Very High" while literally everything else has "Normal".
    Is this correct? Should I set it to Normal?
  2. allenskd

    allenskd Active Member

    Joined:
    Feb 5, 2014
    Messages:
    510
    Likes Received:
    52
    Trophy Points:
    28
    From PA's manual (man):


    REAL-TIME AND HIGH-PRIORITY SCHEDULING
    To minimize the risk of drop-outs during playback it is recommended to run PulseAudio with real-time scheduling if the underlying platform supports it. This decouples the scheduling latency of the PulseAudio dae‐
    mon from the system load and is thus the best way to make sure that PulseAudio always gets CPU time when it needs it to refill the hardware playback buffers. Unfortunately this is a security risk on most systems,
    since PulseAudio runs as user process, and giving realtime scheduling privileges to a user process always comes with the risk that the user misuses it to lock up the system -- which is possible since making a
    process real-time effectively disables preemption.


    -------------------

    Just remove your local default.pa (by local I mean /home/booman/.pulse/default.pa) , the only person who uses the computer is you and having local default.pa is gonna be painful to maintain. Imho

    Remember that you gotta restart pulseaudio after the changes...
  3. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    So removing /home/booman/.pulse/default.pa will reduce drop-outs or is there something I need to comment/uncomment in /etc/pulse/default.pa?

    Also, in your tutorial, should I still add:
    • load-module module-alsa-sink device_id=1
    • load-module module-alsa-sink device_id=2
    Even though I only want device_id=0?
    I know device_id=0 is the default, but I don't want to use my other audio outputs. Just the default.
    Maybe that is why it didn't work for me because I entered device_id=0.

    Code:
     0 [SB            ]: HDA-Intel - HDA ATI SB
                          HDA ATI SB at 0xfdff4000 irq 16
    1 [NVidia        ]: HDA-Intel - HDA NVidia
                          HDA NVidia at 0xfbffc000 irq 19
  4. allenskd

    allenskd Active Member

    Joined:
    Feb 5, 2014
    Messages:
    510
    Likes Received:
    52
    Trophy Points:
    28

    Uhh then just use

    load-module module-alsa-sink device_id=dmix

    dmix should be using the first one, which is 0. Try that

    In configurations, you can do whatever you want, if you just want ONE device then so be it
  5. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    You are right, I get this error with dmix and device_id=1
    Code:
    W: [pulseaudio] sink.c: Default and alternate sample rates are the same.
    E: [pulseaudio] module-alsa-sink.c: Failed to parse module arguments
    E: [pulseaudio] module.c: Failed to load module "module-alsa-sink" (argument: "device_id=1 # 0 is Intel ATI SB Audio Device, 1 is Nvidia HDMI"): initialization failed.
    E: [pulseaudio] main.c: Module load failed.
    E: [pulseaudio] main.c: Failed to initialize daemon.
    
    load-module module-alsa-sink device=dmix
    load-module module-alsa-sink device_id=1 # 0 is Intel ATI SB Audio Device, 1 is Nvidia HDMI
    load-module module-alsa-source device=hw:0,0
  6. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    This is causing my conflict. So do I need this line at all?
    load-module module-alsa-sink device_id=1
  7. allenskd

    allenskd Active Member

    Joined:
    Feb 5, 2014
    Messages:
    510
    Likes Received:
    52
    Trophy Points:
    28
    Please post your full default.pa here
  8. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    Code:
    #!/usr/bin/pulseaudio -nF
    #
    # This file is part of PulseAudio.
    #
    # PulseAudio is free software; you can redistribute it and/or modify it
    # under the terms of the GNU Lesser General Public License as published by
    # the Free Software Foundation; either version 2 of the License, or
    # (at your option) any later version.
    #
    # PulseAudio is distributed in the hope that it will be useful, but
    # WITHOUT ANY WARRANTY; without even the implied warranty of
    # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
    # General Public License for more details.
    #
    # You should have received a copy of the GNU Lesser General Public License
    # along with PulseAudio; if not, write to the Free Software Foundation,
    # Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
    
    # This startup script is used only if PulseAudio is started per-user
    # (i.e. not in system mode)
    
    .nofail
    
    ### Load something into the sample cache
    #load-sample-lazy x11-bell /usr/share/sounds/gtk-events/activate.wav
    #load-sample-lazy pulse-hotplug /usr/share/sounds/linuxmint-login.wav
    #load-sample-lazy pulse-coldplug /usr/share/sounds/linuxmint-login.wav
    #load-sample-lazy pulse-access /usr/share/sounds/generic.wav
    load-sample-dir-lazy /usr/share/sounds/LinuxMint/stereo
    
    .fail
    
    ### Automatically restore the volume of streams and devices
    load-module module-device-restore
    load-module module-stream-restore
    load-module module-card-restore
    
    ### Automatically augment property information from .desktop files
    ### stored in /usr/share/application
    load-module module-augment-properties
    
    ### Load audio drivers statically
    ### (it's probably better to not load these drivers manually, but instead
    ### use module-udev-detect -- see below -- for doing this automatically)
    load-module module-alsa-sink device=dmix
    load-module module-alsa-source device=hw:1,0
    #load-module module-oss device="/dev/dsp" sink_name=output source_name=input
    #load-module module-oss-mmap device="/dev/dsp" sink_name=output source_name=input
    #load-module module-null-sink
    #load-module module-pipe-sink
    
    ### Automatically load driver modules depending on the hardware available
    #.ifexists module-udev-detect.so
    #load-module module-udev-detect use_ucm=0
    #.else
    ### Use the static hardware detection module (for systems that lack udev support)
    #load-module module-detect
    #.endif
    
    ### Automatically connect sink and source if JACK server is present
    .ifexists module-jackdbus-detect.so
    .nofail
    load-module module-jackdbus-detect channels=2
    .fail
    .endif
    
    ### Automatically load driver modules for Bluetooth hardware
    .ifexists module-bluetooth-policy.so
    load-module module-bluetooth-policy
    .endif
    
    .ifexists module-bluetooth-discover.so
    load-module module-bluetooth-discover
    .endif
    
    ### Load several protocols
    .ifexists module-esound-protocol-unix.so
    load-module module-esound-protocol-unix
    .endif
    load-module module-native-protocol-unix
    
    ### Network access (may be configured with paprefs, so leave this commented
    ### here if you plan to use paprefs)
    #load-module module-esound-protocol-tcp
    #load-module module-native-protocol-tcp
    #load-module module-zeroconf-publish
    
    ### Load the RTP receiver module (also configured via paprefs, see above)
    #load-module module-rtp-recv
    
    ### Load the RTP sender module (also configured via paprefs, see above)
    #load-module module-null-sink sink_name=rtp format=s16be channels=2 rate=44100 sink_properties="device.description='RTP Multicast Sink'"
    #load-module module-rtp-send source=rtp.monitor
    
    ### Load additional modules from GConf settings. This can be configured with the paprefs tool.
    ### Please keep in mind that the modules configured by paprefs might conflict with manually
    ### loaded modules.
    .ifexists module-gconf.so
    .nofail
    load-module module-gconf
    .fail
    .endif
    
    ### Automatically restore the default sink/source when changed by the user
    ### during runtime
    ### NOTE: This should be loaded as early as possible so that subsequent modules
    ### that look up the default sink/source get the right value
    load-module module-default-device-restore
    
    ### Automatically move streams to the default sink if the sink they are
    ### connected to dies, similar for sources
    load-module module-rescue-streams
    
    ### Make sure we always have a sink around, even if it is a null sink.
    load-module module-always-sink
    
    ### Honour intended role device property
    load-module module-intended-roles
    
    ### Automatically suspend sinks/sources that become idle for too long
    load-module module-suspend-on-idle
    
    ### If autoexit on idle is enabled we want to make sure we only quit
    ### when no local session needs us anymore.
    .ifexists module-console-kit.so
    load-module module-console-kit
    .endif
    .ifexists module-systemd-login.so
    load-module module-systemd-login
    .endif
    
    ### Enable positioned event sounds
    load-module module-position-event-sounds
    
    ### Cork music/video streams when a phone stream is active
    #load-module module-role-cork
    
    ### Modules to allow autoloading of filters (such as echo cancellation)
    ### on demand. module-filter-heuristics tries to determine what filters
    ### make sense, and module-filter-apply does the heavy-lifting of
    ### loading modules and rerouting streams.
    load-module module-filter-heuristics
    load-module module-filter-apply
    
    ### Load DBus protocol
    #.ifexists module-dbus-protocol.so
    #load-module module-dbus-protocol
    #.endif
    
    # X11 modules should not be started from default.pa so that one daemon
    # can be shared by multiple sessions.
    
    ### Load X11 bell module
    #load-module module-x11-bell sample=bell-windowing-system
    
    ### Register ourselves in the X11 session manager
    #load-module module-x11-xsmp
    
    ### Publish connection data in the X11 root window
    #.ifexists module-x11-publish.so
    #.nofail
    #load-module module-x11-publish
    #.fail
    #.endif
    
    load-module module-switch-on-port-available
    
    ### Make some devices default
    #set-default-sink output
    #set-default-source input
  9. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    did I mention that I didn't create the .asoundrc?
    Does your tutorial require this?
  10. allenskd

    allenskd Active Member

    Joined:
    Feb 5, 2014
    Messages:
    510
    Likes Received:
    52
    Trophy Points:
    28
    I'm confused, that configuration should work just fine... and I don't see device_id=1 in there either....

    And no, you don't need asoundrc with this one
  11. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    Me too...
    I went ahead and tried the Wine Alsa solution linked in your thread. The "underrun" errors are gone, but games are still running slow. I know its not my hardware or configuration because I didn't have these problems previously on Mint 14.
  12. allenskd

    allenskd Active Member

    Joined:
    Feb 5, 2014
    Messages:
    510
    Likes Received:
    52
    Trophy Points:
    28
    Wait, the solution fixes only the audio issues... not graphic issues.... but at this moment I'm totally lost on what your current problems are...

    1) What's the current situation and what's wrong
    2) What have you tried
    3) System specs
    4) In case of emergency, dump mint for a better distro :x
  13. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    1. All of my PlayOnLinux games are frame stuttering or slow
    • Native games like Portal 2 run perfectly
    • Crysis Warhead (PlayOnLinux) runs pretty smooth
    • League of Legends runs pretty smooth
    2. Steps Taken:
    • Wine Solution editing /etc/pulse/default.pa - Underrun error solution
    • Another solution editing /etc/pulse/default.pa - Your tutorial
    • Editing /etc/pulse/daemon.conf - default-fragment-size-msec = 5
    • Tried adding tsched=0 /etc/pulse/default.pa - load-module module-udev-detect tsched=0
    • Creating a custom .asoundrc script -
    Code:
    pcm.!default {
      type plug
      slave.pcm {
        @func getenv
        vars [ ALSAPCM ]
        default "hw:SB"
      }
    }
    3. System Specs
    • Mint 16 32-bit
    • AMD Phenom II 3-Core
    • Integrated audio HDA Intel - HDA ATI SB
    • Nvidia GeForce 550 Ti 2GB
    • Nvidia 319 drivers
    4. Originally the problem was the ALSA underrun error in Wine. I would play a game like Borderlands 2, it would run ok, but about 30 minutes into it, the sound got screwed up and then frame rates dropped to almost nothing. I did your tutorial and it fixed my frame rates and underrun error. A few weeks ago I was testing Star Trek Voyager: Elite Force and it ran poorly no mater what I did. Any version of wine, any resolution any display settings, it just stuttered like CRAZY. Daerandin tested in in Arch and it ran fine. Several game tests later and I'm still having performance issues. I check the default.pa settings and they have been reverted. Probably an update.

    My list in the first few posts are all the games I've had frame stuttering with. The only way to know for sure if its the audio is disabling audio completely and then playing the game. How can I disable ALSA and Pulseaudio temporarily?
  14. allenskd

    allenskd Active Member

    Joined:
    Feb 5, 2014
    Messages:
    510
    Likes Received:
    52
    Trophy Points:
    28
    It doesn't sound like a audio problem at all though... I mean the underrun IS an audio problem but... if the game is running at lets say... 10FPS it would alter the sound but it doesn't mean the audio is having problems, but the whole game is.

    I've ran Tomb Raider with Framerate issues and the sound would get a bit iffy. I'm hoping to have a lightweight installation once I start with Debian... I'm pretty sure I'll notice the differences
  15. Daerandin

    Daerandin Well-Known Member

    Joined:
    Oct 18, 2013
    Messages:
    1,157
    Likes Received:
    259
    Trophy Points:
    83
    Location:
    Northern Norway
    Home page:
    One thing comes to mind. I recall you used a PPA some time ago for the purpose of trying out a newer nvidia driver. Did these problems occur immediately after this, or was it some time later? I am not that familiar with the workings of PPA's that provide packages also found in official repositories, but maybe there could be some leftover library that is causing issues for you.

    If you have some wine games that you have previously had running on Mint 16 without these issues, then give those a try again to see if they suffer from these problems. If so, then obviously some recent change has caused this.
  16. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    I considered that as well, so in Fallout 3 and Risen I have switched several Wine versions including CSMT and doublebuffer, then even tried resolutions and graphics settings on low but still get really bad frame stutters.
    Maybe it is related to a library that Daerandin is speaking of when I tried Nvidia drivers from a PPA and failed, but how do I find it?
    I always had frame rate issues with Wine since I started using Mint 16 and they were related to the underrun problem.
    So I just assumed my recent issues were also related to audio even though I wasn't getting underrun errors.

    I guess I could re-install Mint 16 from scratch... no harm in that?
  17. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    Turns out you are both right! :)
    I installed Mint 16 64-bit and then all my other crap including ia32-libs and now Risen is running beautifully! :D
    It is actually playable now...
    So expect a guide this Friday on Risen.

    I will be loading up Crysis Warhead, Fallout 3, Tron 2.0 and Star Trek Voyager: Elite Force just to make sure.
    Something must have happened with that PPA that didn't work for my video drivers or messing with daemon.conf and .asoundrc.

    Thanks for listening to my griping and helping me! You guys rock.
    Now that it seems I'm stable, I can stick with this for a month until Mint 17 is released.
    I'll try 64-bit again when I install it. Then back to testing again.
  18. Daerandin

    Daerandin Well-Known Member

    Joined:
    Oct 18, 2013
    Messages:
    1,157
    Likes Received:
    259
    Trophy Points:
    83
    Location:
    Northern Norway
    Home page:
    Glad to hear things are back in working order!
  19. booman

    booman Grand High Exalted Mystic Emperor of Linux Gaming Staff Member

    Joined:
    Dec 17, 2012
    Messages:
    8,347
    Likes Received:
    627
    Trophy Points:
    113
    Location:
    Linux, Virginia
    Home page:
    Man I was getting frustrated (Hence the title)
    How can I test a game if all my games are not working?
    Really sucks that I had to install Mint again, but that is how you learn....
    Now my questions is.... was pulseaudio really the problem?
    Either way, I learned a bit about pulseaudio in Linux. Yay!

Share This Page