RT kernel locking up my machine

Talk about your MIDI interfaces, microphones, keyboards...

Moderators: MattKingUSA, khz

Post Reply
nealfunkbass
Established Member
Posts: 8
Joined: Fri Apr 16, 2010 3:42 pm
Location: USA East Coast

RT kernel locking up my machine

Post by nealfunkbass »

HI there. I just found this place today, and this is my first post to the forum. Hello everyone.

I have a question for you:

I have been running linux at work and at home for about 4 years now.

I recently started looking into the realtime kernel, and some of the audio distros, like Ubuntu Studio, Studio 64, etc.

Whenever I boot from the realtime kernel, my machine will lock up at some point, requiring a hard reset. Sometimes it happens before I log in, sometimes in takes a few minutes. It seems that installing the nvidia drivers makes it worse, but it is hard to tell that for sure since it is so random.

I've been trying to figure this out for a while, but I can't seem to get an answer. I am considering buying a new motherboard, or audio hardware to see if either of those is the issue.

Can any of you offer any wisdom or insight into possible causes for the lockups?

Here is my hardware, in case that has any bearing on any of this. I thank you in advance for any help you can offer.


Motherboard/Video combo:
GIGABYTE GA-73PVM-S2H LGA 775 NVIDIA GeForce 7100 HDMI Micro ATX Intel Motherboard

RAM:
G.SKILL 4GB (2 x 2GB) 240-Pin DDR2 SDRAM DDR2 800 (PC2 6400) Dual Channel Kit Desktop Memory Model F2-6400CL5D-4GBPQ

Sound:
M-Audio MoblePre USB


Thanks
Neal
User avatar
autostatic
Established Member
Posts: 1994
Joined: Wed Dec 09, 2009 5:26 pm
Location: Beverwijk, The Netherlands
Has thanked: 32 times
Been thanked: 104 times
Contact:

Re: RT kernel locking up my machine

Post by autostatic »

Hello nealfunkbass, welcome!
For starters, maybe you could open a terminal and run a tail -f /var/log/syslog in it. This will continuously output what's being added to your syslog. When your system locks maybe the terminal screen reveals where your system chokes on.
Does your system completely freeze? Magic keys don't work either? Alt+SysRq+k or the sequence Alt+SysRq+r-e-i-s-u-b ?

Best,

Jeremy
nealfunkbass
Established Member
Posts: 8
Joined: Fri Apr 16, 2010 3:42 pm
Location: USA East Coast

Re: RT kernel locking up my machine

Post by nealfunkbass »

Thanks Jeremy.

I tried watching /var/log/messages when I was troubleshooting before, but I didn't try syslog. I plan to reinstall and take a look at that.

I will also try the magic keys to see if that let's me out of the freeze.

I will post the results here once I have had a chance to try out your suggestions.
User avatar
autostatic
Established Member
Posts: 1994
Joined: Wed Dec 09, 2009 5:26 pm
Location: Beverwijk, The Netherlands
Has thanked: 32 times
Been thanked: 104 times
Contact:

Re: RT kernel locking up my machine

Post by autostatic »

nealfunkbass wrote:Thanks Jeremy.

I tried watching /var/log/messages when I was troubleshooting before, but I didn't try syslog. I plan to reinstall and take a look at that.

I will also try the magic keys to see if that let's me out of the freeze.

I will post the results here once I have had a chance to try out your suggestions.
Ok, thanks. What distro are you using? On Debian related distro's (Ubuntu, Studio64, Mint) check /var/log/syslog and on Red Hat relatives (Fedora, CentOS) it's /var/log/messages you have to keep an eye on.
SR
Established Member
Posts: 218
Joined: Wed May 07, 2008 6:01 pm
Location: Houston, Tx

Re: RT kernel locking up my machine

Post by SR »

The problem is that with a lot of lockups/crashes the system doesn't have a chance to write what happened into a text file (eg /var/log/messages). A lot of times the message is on the console which isn't visible because you're running X over it. You could have a terminal window sitting there running "watch 'dmesg | tail'", but it still might not catch the crash or very much of it.

At work I used to use netdump so that the crashing system could send it's log messages to another machine on the network while it was happening. I understand that's been replaced with a local disk based service but never had a chance to look into it. It might be worthwhile in this case.
nealfunkbass
Established Member
Posts: 8
Joined: Fri Apr 16, 2010 3:42 pm
Location: USA East Coast

Re: RT kernel locking up my machine

Post by nealfunkbass »

I used the last distro that I installed, since it was still on one of my partitions.

It is ubuntu karmic, with the Ubuntu Studio meta packages installed. This was the last one I tested on when I was going through this the first time, so it's still on the PC

I've been messing around with this for a while now, and I'm going to give the rundown of what has happened so far, in case anyone can spot some kind of pattern, or has any ideas.

Boot to the rt kernel. I could not even get logged in before it would lock up. No keyboard, no mouse. Magic keys did not work.

I looked through syslog and messages, and found different things that didn't seem to be consistent. I did notice a lot of USB entries.

I decided to remove all USB devices except the mobilepre. This includes going to PS/2 mouse and keyboard.

Now when it comes up in the rt kernel, I can log in, and remain logged without it freezing. So far so good.

So, I open two terminal windows and run tail -f /var/log/messages and tail -f /var/log/syslog

Next I try to launch qjackctl from the menu. It never appears. I try to run it again, but nothing. I try to run it from command line to see if there are any messages. However, when I type qjackctl, it never launches, and I can't get my command line back...it is stuck. No ctrl-c...I have to close the window.

Nothing interesting showing up the log windows

I try to restart, but it hangs on during the shutdown process, requiring a hard reset.

When it comes back up, I try again, and get the same results.

I'm going to try going to a different distro, now that I have made it past the freezing.


Does any of this ring any bells? Anything look familiar, or give you any ideas as to the source of the problems?

Thanks
Neal
User avatar
autostatic
Established Member
Posts: 1994
Joined: Wed Dec 09, 2009 5:26 pm
Location: Beverwijk, The Netherlands
Has thanked: 32 times
Been thanked: 104 times
Contact:

Re: RT kernel locking up my machine

Post by autostatic »

Unfortunately no. The information you give is a bit too generic, is it possible to give some more specific output? Like relevant lines in the logs, maybe you could add the output of dmesg > $HOME/Desktop/dmesg-nealfunkbass.txt as an attachment or as a Code block.
User avatar
spm_gl
Established Member
Posts: 358
Joined: Wed Apr 22, 2009 7:58 am
Location: Spreewald, Germany
Contact:

Re: RT kernel locking up my machine

Post by spm_gl »

I had similar problems with Ubuntu Jaunty and the RT kernel. The machine would freeze after about a minute, nothing in the logs. I never solved the problem though.
--- Spreemusik ---
Jan Fuchsmann, Audio Engineer
Check our blog at http://www.spreemusik.com/blog
User avatar
raboof
Established Member
Posts: 1865
Joined: Tue Apr 08, 2008 11:58 am
Location: Deventer, NL
Has thanked: 52 times
Been thanked: 80 times
Contact:

Re: RT kernel locking up my machine

Post by raboof »

nealfunkbass wrote:I decided to remove all USB devices except the mobilepre. This includes going to PS/2 mouse and keyboard.

Now when it comes up in the rt kernel, I can log in, and remain logged without it freezing. So far so good.
Promising I guesss
So, I open two terminal windows and run tail -f /var/log/messages and tail -f /var/log/syslog

Next I try to launch qjackctl from the menu. It never appears. I try to run it again, but nothing. I try to run it from command line to see if there are any messages. However, when I type qjackctl, it never launches, and I can't get my command line back...it is stuck. No ctrl-c...I have to close the window.

I try to restart, but it hangs on during the shutdown process, requiring a hard reset.
if you run 'ifconfig', do you see any network interfaces that are not actually working?

In my experience programs hanging is often caused by faulty network configs - even if all they're trying to do is connect to 'localhost' (which for example PA might try).
nealfunkbass
Established Member
Posts: 8
Joined: Fri Apr 16, 2010 3:42 pm
Location: USA East Coast

Re: RT kernel locking up my machine

Post by nealfunkbass »

Ok, here is the next test:

I did a fresh install of Ubuntu Studio 9.10 x64, since I had that disc handy.

Note: I still have all USB devices disconnected except for the MobliePre, since this got me farther last time.

1. I did a new clean install, then installed all updates and rebooted
2. Next, I had it install the nvidia video drivers, followed by another reboot
3. Then I launched two terminal windows to watch /var/log/messages and /var/log/syslog
4. I notice in the volume control applet that my MobilePre is not getting picked up, but the internal nvidia sound device is. The MobilePre does show up in lsusb and /proc/asound/cards. That is odd.
5. I tried to launch Jack Control from the menu, but got nothing...no error or anything.
6. So I open a terminal and run qjackctl, but it just hangs there with no output, and no jack control
7. Then a saw some messages come up in the two terminal windows that are watching the log files, so I decided to grab that and upload it here.


Attached is the output of dmesg that was taken at this point.
dmesg-output-nealfunkbass.tar.gz
(13.25 KiB) Downloaded 169 times
So, we are not freezing up at this point, which is nice, but it looks like my MobilePre is having issues where it did not previously.

@raboof - I only see eth0 and lo in ifconfig, which is correct.
Thanks again for looking at this. If you have any ideas, I would appreciate it.
User avatar
raboof
Established Member
Posts: 1865
Joined: Tue Apr 08, 2008 11:58 am
Location: Deventer, NL
Has thanked: 52 times
Been thanked: 80 times
Contact:

Re: RT kernel locking up my machine

Post by raboof »

nealfunkbass wrote:5. I tried to launch Jack Control from the menu, but got nothing...no error or anything.
6. So I open a terminal and run qjackctl, but it just hangs there with no output, and no jack control
7. Then a saw some messages come up in the two terminal windows that are watching the log files, so I decided to grab that and upload it here.

Code: Select all

[  240.407043] INFO: task pulseaudio:2547 blocked for more than 120 seconds.
This really shouldn't happen :). Pulseaudio is somehow blocking. It might be interesting to get the output of 'sudo lsof' at the time pulseaudio is blocking - this might give a hint about what it's blocking on.

You could try removing pulseaudio (you don't generally want to use pulseaudio and jack alongside anyway), however it's likely it's not pulseaudio that's the problem here, but whatever component pulseaudio is trying to talk to.
User avatar
autostatic
Established Member
Posts: 1994
Joined: Wed Dec 09, 2009 5:26 pm
Location: Beverwijk, The Netherlands
Has thanked: 32 times
Been thanked: 104 times
Contact:

Re: RT kernel locking up my machine

Post by autostatic »

Thanks for the dmesg output! Looks like PulseAudio is being obnoxious. On Ubuntu /usr/bin/qjackctl is a wrapper script that suspends PulseAudio and starts QjackCtl (the actual QjackCtl binary is /usr/bin/qjackctl.bin). Something goes wrong there I think.
Best thing to do in your case is to disable PulseAudio for your current session/user I think:
  • Create a client.conf file to prevent PulseAudio from respawning. Press Alt+F2 and enter gedit ~/.pulse/client.conf. This will open gedit with an empty file. Enter the line autospawn = no , save and close gedit
  • Create a new Startup Application: System - Preferences - Startup Applications, click Add. Name the entry something like 'Kill PulseAudio' and the command should read 'pulseaudio -k'. Click Add again, then close the Startup Applications Preferences window, log out and log in again. Now PulseAudio gets killed on login and won't respawn because of the autospawn option in the client.conf file.
Let's hope it helps!
nealfunkbass
Established Member
Posts: 8
Joined: Fri Apr 16, 2010 3:42 pm
Location: USA East Coast

Re: RT kernel locking up my machine

Post by nealfunkbass »

I tried a few things, including your suggestion, here's basically what happened:

Clean install of Ubuntu Studio 9.04 x64
Run all updates
create ~/.pulse/client.conf with this line: autospawn = no
create startup script that does this: pulseaudio -k
Reboot for some of the updates to take effect
Try running Jack Control. Works fine.
Install nvidia driver and reboot
It is acting sluggish at first login, and so I log out to restart the X server
When I log back in, it is back to normal
Launch Jack Control....it does not come up, but there is no error message
save dmesg_output_2 to attach to this post

From the logs, it looks like pulseaudio is still causing problems, but it seemed to be fine before I installed the nvidia driver. I am considering trying to remove pulseaudio altogether.

I'm attaching the dmesg output

Once again, thank you for your help with this.
Attachments
dmesg_output_2.tar.gz
(12.49 KiB) Downloaded 154 times
nealfunkbass
Established Member
Posts: 8
Joined: Fri Apr 16, 2010 3:42 pm
Location: USA East Coast

Re: RT kernel locking up my machine

Post by nealfunkbass »

OK, so I finally gave up after battling with that off and on for the last year. I ordered a new motherboard that has an intel chipset, with intel video on board.

I installed Fedora 12 and added the CCRMA stuff.

It's all working fine.

Moral of the story for me: avoid video hardware that requires proprietary drivers.
Post Reply