kanotix.com

Kanotix Requests - Realtime kernel

brodders - 27.09.2006, 17:58 Uhr
Titel: Realtime kernel
Hi...

..is there a reason why Kanotix does not ship with the RT kernel?

This is always nice to use in other distros - all the multimedia LiveCD's have RT as standard - makes their distros very snappy and slick to use.

Why not Kanotix?? What is the downside?

brodders
slh - 27.09.2006, 18:03 Uhr
Titel: RE: Realtime kernel
What do YOU expect from a realtime kernel?

--
(hint, realtime degrades performance significantly)
brodders - 28.09.2006, 17:52 Uhr
Titel:
Hi,

my understanding the RT kernel is to minimise delays - typically for audio / multimedia apps, which need (?why - what's wrong with buffering?) instant responses. The patches tweek the schedular and insert more I/O event task checking in blocks of code which would otherwise hog time (so delaying response).

Why do I like RT distros? Well, using say dyna:bolic it is very clear that the RT mods make the system extremely smooth in use.

That's it. I like the responsive feel of <it's done> over <..it's done> !

No functional benefit - except the feel of using the distro. It's better.

So I wonder - why not ship as standard like this - what is the downside?

brodders
mzilikazi - 28.09.2006, 18:21 Uhr
Titel:
The rt patches don't cause any noticible speed improvement here but I do use an rt kernel for my audio applications e.g. Ardour, XMMS, etc. It's quite simple to build your own rt kernel and there is even a Howto for your reading enjoyment. In case you did not notice Kanotix is not billed as a multimedia distro.
brodders - 29.09.2006, 09:39 Uhr
Titel:
Hi mzilikazi,

Smilie I am aware of these things...

but my Q still stands, let me rephrase it:

Given various advantages, why does Kanotix not ship with the RT kernel as standard?


I suppse that there is a downside which militates against this.

..but what?

brodders
jackiebrown - 30.09.2006, 01:44 Uhr
Titel: Re: RE: Realtime kernel
brodders hat folgendes geschrieben::

I suppse that there is a downside which militates against this.

..but what?

brodders


slh hat folgendes geschrieben::
(hint, realtime degrades performance significantly)

piper - 30.09.2006, 03:50 Uhr
Titel: RE: Re: RE: Realtime kernel
And

mzilikazi wrote
Code:
Kanotix is not billed as a multimedia distro

jackiebrown - 30.09.2006, 04:20 Uhr
Titel: RE: Re: RE: Realtime kernel
Makes it easy when we can just quote (from the same 1 page thread) - right piper Winken
slh - 30.09.2006, 13:02 Uhr
Titel: RE: Re: RE: Realtime kernel
Another question for you, what improvements would an -rt kernel do for the general user, defined by:
- browsing the web
- reading emails
- listening to mp3/ ogg vorbis via amaroK
- using kaffeine/ vdr/ kdetv to watch/ record TV/ videos
- using webcams and VoIP services
- burning CDs/ DVDs with k3b/ wodim
- doing office related tasks with koffice, OOo2, abiword, gnumeric
- using wlan
- playing ego shooter games
- doing graphics design with gimp
- being a C/ C++, perl, python, sh, ruby, scheme, cobol, algol, ... developer and doing heavy compiling
- doing web design with quanta+
- hosting several servers like apache, *SQL, postfix/ exim/ sendmail, dhcpd, bind9, rsync, samba, nfsd
- designing in inkscape
- 3d modelling with blender
- cutting/ transcoding videos
- [ . . . ]
- or something really strange, like using the live CD or using notebooks on batteries

?

--
I'm honestly interested in your answer or different definitions for the majority of kanotix users.
Cathbard - 30.09.2006, 14:14 Uhr
Titel:
I use a RT kernel because I use Ardour, Muse etc so I just compile it myself. What would be nice however is an option to patch the kernel with RT in H2's script. Hint hint Winken
Recording apps in linux are brilliant but patching the kernel for RT often scares people away which is a shame. A script would be nice.
piper - 30.09.2006, 15:38 Uhr
Titel: Re: RE: Re: RE: Realtime kernel
jackiebrown hat folgendes geschrieben::
Makes it easy when we can just quote (from the same 1 page thread) - right piper Winken


hehe Winken

Cathbard hat folgendes geschrieben::
Hint hint


lol, alot of work, I presume Winken
kelmo - 30.09.2006, 19:37 Uhr
Titel: RE: Re: RE: Re: RE: Realtime kernel
Why would we blindly introduce an intricate, invasive patch that significant modifies core behaviours of the kernel just so a smal subset of the population may feel as if they now have an advantage when using their audio apps?

Best wait until the guru's (linux kernel maintainers) integrate this functionality in the future.

Kel.
DeepDayze - 30.09.2006, 19:38 Uhr
Titel: RE: Re: RE: Re: RE: Realtime kernel
makes sense
brodders - 01.10.2006, 18:10 Uhr
Titel: RE: Re: RE: Re: RE: Realtime kernel
Smilie

Aha! ..it must be all that then

brodders
+ smily icon for "squints and resolves to get better glasses..."
mzilikazi - 02.10.2006, 00:40 Uhr
Titel: Re: RE: Re: RE: Re: RE: Realtime kernel
kelmo hat folgendes geschrieben::
blah blah blah the population may feel as if they now have an advantage when using their audio apps?


It's not a feeling kelmo - there is a genuine difference. You should try it next time you want to record your didgeridoo. Auf den Arm nehmen
mzilikazi - 02.10.2006, 00:46 Uhr
Titel:
Cathbard hat folgendes geschrieben::
What would be nice however is an option to patch the kernel with RT in H2's script.


Better yet would be an rt kernel ready to download & install. I *may* put an effort to that end in the near future. 2.6.18-rt3 honestly did not work so well and I dropped back to 2.6.17-rt Now that patch-2.6.18-rt5 is out I need to recompile and test for a while.
wegface - 02.10.2006, 15:21 Uhr
Titel:
If it wasnt absoultely necessary to patch the kernel to acheive decent audio latencies then we surely wouldnt all bother? And those of us who use serious auidio apps thank mzilikazi for his excellent how to- which recieves decent interest to this date- and acheives RT kernel within less than 10 mins. Of course Kano is no musician (to my knowledge anyway lol) and this is HIS distro, so we wont be seeing an RT kernel ship with kanotix- it would be a waste of (valuable) disk space.
Cathbard - 04.10.2006, 22:21 Uhr
Titel:
An RT kernel shipped in the iso wouldn't even be on the wish list. That would have to be a private DAW project of some sort. However, looking forward to MZ's kernel packages, thats the way to do it. Nice one.
h2 - 05.10.2006, 05:12 Uhr
Titel:
If someone creates a rt kernel that is fully compatible with the install directions for kanotix standard kernels it's no problem to add that option to du-fixes, but only if the kernel package is 100% compatible with the standard kanotix formats.
mzilikazi - 06.10.2006, 06:10 Uhr
Titel:
Edit This kernel is still available BUT you can also download a newer version from an actual (unofficial) Debian repo.


Kernel 2.6.18-mz-rt5 can be downloaded from here.
This is packaged just like the Kanotix kernels. It is patched with the same patchset used on 2.6.18-slh-up-2.

All modules plus kernel image, headers and doc are in a zip file.
Download the .zip archive, unpack and run the install-realtime-kernel.sh.

Only problem so far is that lirc modules failed to build for me. No chance to figure out why just yet so if you really need lirc you would need to build that module yourself until I get it fixed.

Please test the mz-source.sh script as well.

You'll also need this PAM module or realtime WILL NOT work.

I'll add the PAM module to the next kernel.zip

Please test and report back. Enjoy! Cool
brummer - 06.10.2006, 13:23 Uhr
Titel:
thanks a lot for this, so many musician can see the real performens from jackd ardur rosegarden ..... without compile a one kernel
i put a link in german forum for that
i enjoy it Sehr glücklich
mzilikazi - 09.10.2006, 21:32 Uhr
Titel:
OK made a few changes:
Added PAM module to zip archive.
The install-realtime-kernel.sh will install the PAM module for you.
Small fix for stupid error in mz-source.sh
Moved rt5 patch to a different mirror. When ingo uploads a new patch the old one is removed!
This would not work too well for building a realtime patched kernl source. Smilie

Just tested the install-realtime-kernel.sh, mz-source.sh on a fresh RC4 installation. It works fabulously.
Code:
~$ infobash -v2
Host/Kernel/OS  "tuxmeister" running Linux 2.6.18-mz-rt5 i686 [ KANOTIX 2006-01 ]
CPU Info        Pentium III (Coppermine) clocked at [ 863.812 MHz ]
Videocard       nVidia NV11DDR [GeForce2 MX 100 DDR/200 DDR]  X.Org 7.1.1  [ 1280x1024 @85hz ]
Network cards   Intel 82801BA/BAM/CA/CAM Ethernet Controller, at port: 1000
Processes 109 | Uptime 4:36 | Memory 364.91/375.812MB | HDD ST320414A,SanDisk Cruzer Mini Size 20GB (28%used) | GLX Renderer GeForce2 MX/AGP/SSE | GLX Version 1.5.6 NVIDIA 87.74 | Client Shell | Infobash v2.50rc21


So..........You no longer need to download the PAM module. Get the zip archive, unpack it and run the installation script:
Code:
mkdir kernel
cd kernel
wget http://www.gefechtsdienst.de/uman/files/glenn/files/kernel-2.6.18-mz-rt5.zip
unp kernel-2.6.18-mz-rt5.zip
./install-realtime-kernel.sh


Be sure to post any problems you might have.
slh - 09.10.2006, 21:53 Uhr
Titel:
mzilikazi, you might want to disable wlan and ISDN driver (and some others on a case by case basis) completely because both introduce long non interruptable latencies - one of the reasons why -rt kernels (besides their own problems) aren't usable for general purpose systems, just like -rt patched kernels with a generic configuration aren't useful for serious realtime tasks...
Oktyabr - 15.10.2006, 20:56 Uhr
Titel:
Anyone tried the 2.6.18-1-486 kernel from the Debian unstable repositories? I've got it running on my RC3 install right now and hitting 5.8msec latency with an onboard nForce4 sound chip and the only xruns I'm getting is when I open a new window (like Firefox to post this)!

Very nice, no hacked pam modules or anything.
mzilikazi - 15.10.2006, 23:32 Uhr
Titel:
Oktyabr hat folgendes geschrieben::
the only xruns I'm getting is when I open a new window (like Firefox to post this)!

Very nice, no hacked pam modules or anything.


That is completely unacceptable for music production and the PAM module is not 'hacked'.

Edit
libpam-modules-0.79-4 in Debian testing/sid is perfectly fine for realtime BUT
you must edit /etc/security/limits.conf.
Append the following to the end:

@audio - rtprio 99
@audio - nice -10
@audio - memlock 250000
Oktyabr - 16.10.2006, 00:12 Uhr
Titel:
mzilikazi hat folgendes geschrieben::
Oktyabr hat folgendes geschrieben::
the only xruns I'm getting is when I open a new window (like Firefox to post this)!

Very nice, no hacked pam modules or anything.


That is completely unacceptable for music production and the PAM module is not 'hacked'.


By "hacked" I simply mean a PAM module that is NOT included by default. It's easy to assume that there is a reason for this whether the source is from a fork or patched or whatever... hence "hacked".

As for performance I don't know about your hardware but on mine that is exceptional, especially considering it is using an onboard soundchip! Sure wish my M-Audio Delta 44 hadn't flaked out or I'm quite sure xruns would very likely be fewer...

As for acceptable for music production? When I'm recording my keyboards or my son's guitar work I rarely find the need to fire up a forum in firefox. Any windows that were currently open do not cause xruns... only new windows. Tested it today with Ardour recording from LMMS and a live track off one of my keyboards via the motherboard's line-in. No xruns. And that's running dual monitors (nvidia twinview) with a ton of eye candy and system monitors (superkaramba) up and running as well.

Now sure, a perfect RT enviroment would be zero xruns ever with the lowest latencies the hardware is capable of but 5.8msec on an onboard chip? That's quite acceptable for the sort of production work I do (although I do see a new Maudio or RME card in my future) and quite comparable to 64Studio, Musix, Demudi, and Ubuntustudio kernels and distros I've tried in the past.

Do I think it still has room for improvement?

Zitat:

overlord@biggun2:/boot$ cat /proc/asound/timers
G0: system timer : 4000.000us (10000000 ticks)
G1: RTC timer : 976.562us (100000000 ticks)
P0-0-0: PCM playback 0-0-0 : SLAVE
P0-0-1: PCM capture 0-0-1 : SLAVE
P0-1-1: PCM capture 0-1-1 : SLAVE
P0-2-0: PCM playback 0-2-0 : SLAVE


1000 Hz kernel timer would be nice for a start.
mzilikazi - 16.10.2006, 13:21 Uhr
Titel:
Oktyabr hat folgendes geschrieben::


1000 Hz kernel timer would be nice for a start.


Code:
$ cat /proc/asound/timers
G0: system timer : 1000.000us (10000000 ticks)
P0-0-0: PCM playback 0-0-0 : SLAVE
P0-0-1: PCM capture 0-0-1 : SLAVE
P1-0-1: PCM capture 1-0-1 : SLAVE
P1-1-1: PCM capture 1-1-1 : SLAVE
P2-0-0: PCM playback 2-0-0 : SLAVE
P2-0-1: PCM capture 2-0-1 : SLAVE
P2-1-1: PCM capture 2-1-1 : SLAVE
P2-2-0: PCM playback 2-2-0 : SLAVE


Hmm what kernel is that?
Code:
$ uname -a
Linux hestviken.mzilikazix.org 2.6.18-mz-rt5 #1 PREEMPT Thu Oct 5 20:17:40 MDT 2006 i686 GNU/Linux

Oktyabr - 16.10.2006, 14:26 Uhr
Titel:
Ok, ok... I downloaded your kernel last night and will give it a go today. Sehr glücklich

Any tips on getting nvidia to work with it or has there been no problems?
mzilikazi - 16.10.2006, 20:56 Uhr
Titel:
Oktyabr hat folgendes geschrieben::
Ok, ok... I downloaded your kernel last night and will give it a go today. Sehr glücklich

Any tips on getting nvidia to work with it or has there been no problems?


No troubles at all installing Nvidia using either Kano's script or doing it the Debian way. I'm using this kernel on 2 machines, one is just a desktop the other I use for recording. It's working just fine on both.

Let me know if you have any issues.
Oktyabr - 19.10.2006, 03:58 Uhr
Titel:
mzilikazi hat folgendes geschrieben::
Oktyabr hat folgendes geschrieben::
Ok, ok... I downloaded your kernel last night and will give it a go today. Sehr glücklich

Any tips on getting nvidia to work with it or has there been no problems?


No troubles at all installing Nvidia using either Kano's script or doing it the Debian way. I'm using this kernel on 2 machines, one is just a desktop the other I use for recording. It's working just fine on both.

Let me know if you have any issues.


Ok, finally had enough "free" time to give your kernel a whirl. It installed great, no problems there, but I did notice that Xorg, with nvidia disabled (just installed your kernel) was hitting CPU usage of up to 35% at an idle. Used kano's script to install some nvidia drivers and the excess cpu usage went away.

Performance seems much nicer than the 2.6.18 kernel I tried earlier. Down to 2.9ms with on board sound chip which is probably pushing it a bit. No xruns on a browser window but I did get a couple with LMMS, usually while it was loading a project or browsing the directory for files. Don't remember if I got many with LMMS and the other kernel or not (I know I had some while loading). Zyn, AMS, Rosegarden all work well Smilie

Will try a few more comparisons as time allows this week and will report my findings.

All in all seems like a pretty nice kernel! Thanks!
mzilikazi - 19.10.2006, 05:22 Uhr
Titel:
Don't forget to make some tweaks in qjackctl. I have 0 xruns while recording 3 audio tracks simultaneously. Perhaps I will fine tune the kernel config a bit more and build multiple kernels e.g. k7 & i686 flavors. Primarily I'm interested in getting audio apps to function together at the best possible performance and am willing to sacrifice some performance from other desktop apps not related to recording or multimedia. Afterall if it's an issue you can just boot the RT kernel when you need it and boot another kernel for standard desktop use. Eventually Ingo's patches are slated for complete addition into the main kernel so at some point in the future RT will simply be a configuration choice when building a new kernel just like any other - no patching required.
Oktyabr - 19.10.2006, 16:47 Uhr
Titel:
Yes, I'm looking forward to seeing RT incorporated too.

Your kernel works very well for what I need it for. Don't suppose you have any Ardour2 debs compiled anywhere? Winken
makke - 19.10.2006, 17:05 Uhr
Titel:
deb http://ftp.debian.org/debian experimental main contrib non-free in /etc/apt/sources.list
apt-get update
apt-get install ardour-gtk/experimental
mzilikazi - 22.10.2006, 18:03 Uhr
Titel:
Ardour2 in experimental is still the alpha. There have been at least 2 betas released since then. I would highly advise to build from source. Ardour2 uses scons to build so if you want to uninstall it simply issue scons install -c

To build Ardour2 from source:
Code:
# apt-get install alsa-base alsa-tools jackd
qjackctl alsa-tools-gui scons python2.4 gettext
pkg-config libtool autoconf libjack0.100.0-dev
libxml2 libxml2-dev raptor-utils liblrdf0
liblrdf0-dev libsamplerate0 libsamplerate0-dev
libglib2.0-0 libglib2.0-dev libgtk2.0-0
libgtk2.0-dev libsndfile1 libsndfile1-dev
libgnomecanvas2-0 libgnomecanvas2-dev liblo0
liblo0-dev libboost-dev libasound2-dev unp bzip2
unzip zip


Easiest way to get started:

Code:
$ wget http://ardour.org/files/releases/ardour-2.0beta6.2.tar.bz2
$ unp ardour-2.0beta6.2.tar.bz2
$ cd ardour-2.0beta6.2
$ scons
$ su
# scons install


No this doesn’t create an ardour2.deb for you but it’s easy to uninstall w/ scons:

Code:
$ cd ardour-2.0beta6.2
$ su
# scons -c install

dragonopolis - 10.11.2006, 22:26 Uhr
Titel:
Don't have any room on harddrive for a second Kanotix distro. Hmmm....... I have freespire. Isthis script good for any mostly pure debian or just for Kanotix. I do know that Freespire is Debian etch while Kanotix is Sid. I just don't like practicing on stable installs and besides I like to see if I can modernize Freespire. I need a rt kernernel because *spires like to lean toward jackd.
Do you recommend using this script or should I compile my own use freespires config?(haven't run your script so I not sure how it handles that are you using a generic config for kernel?
mzilikazi - 12.11.2006, 14:28 Uhr
Titel:
dragonopolis hat folgendes geschrieben::
Don't have any room on harddrive for a second Kanotix distro. Hmmm....... I have freespire. Isthis script good for any mostly pure debian or just for Kanotix. I do know that Freespire is Debian etch while Kanotix is Sid. I just don't like practicing on stable installs and besides I like to see if I can modernize Freespire. I need a rt kernernel because *spires like to lean toward jackd.
Do you recommend using this script or should I compile my own use freespires config?(haven't run your script so I not sure how it handles that are you using a generic config for kernel?


I don't know the first thing about Freespire. I've heard that it's Debian based but that's the extent of my knowledge. You can always just use dpkg -i <package>.deb and try the kernel. GRUB will get updated automatically - I dunno about other boot loaders. It might be required to edit your boot loader manually so that it sees the new kernel.
hifi25nl - 26.02.2007, 18:56 Uhr
Titel:
Mzilikazi, your site is down? It will be back or not? I have also some questions if you are always working on realtime kernels.

Piero
mzilikazi - 07.03.2007, 00:31 Uhr
Titel:
Well it's back up but I need to rewrite the realtime kernel docs - some things have changed for 2.6.20, well specifically the nvidia drivers (done the Debian way) do not build as nicely and require a small fix.
Alle Zeiten sind GMT + 1 Stunde
PNphpBB2 © 2003-2007