Configuration 'quickscan'

Optimize your system for ultimate performance.

Moderators: MattKingUSA, khz

Post Reply
User avatar
raboof
Established Member
Posts: 1710
Joined: Tue Apr 08, 2008 11:58 am
Location: Deventer, NL
Contact:

Configuration 'quickscan'

Post by raboof »

Tuning a system, especially if you're not too familiar with what can be tuned and what it all means, can be quite a daunting task.

I think it would be useful to have a script that looks at the current configuration of your system, and suggests and explains possible improvements.

Does anyone know if such a script already exists?

brummer

Post by brummer »

do you mean something like rtirq:
http://www.rncbc.org/jack/
rtirq-20071012.tar.gz

description is here:
http://irc.esben-stien.name/mediawiki/i ... ux_Systems

User avatar
raboof
Established Member
Posts: 1710
Joined: Tue Apr 08, 2008 11:58 am
Location: Deventer, NL
Contact:

Post by raboof »

brummer wrote:do you mean something like rtirq
Not really: I mean a script that will look at your system, and tell you about ways to tune your system that you haven't applied yet.

For example, the script might run 'ps -Leo rtprio,cmd,pid', and verify that jack is running at a suitably high priority. If not, it would warn you about it and point you to more documentation like
http://irc.esben-stien.name/mediawiki/i ... ux_Systems .

User avatar
raboof
Established Member
Posts: 1710
Joined: Tue Apr 08, 2008 11:58 am
Location: Deventer, NL
Contact:

Post by raboof »

Jedee wrote:i wouldnt touch anything without proper documentation...
Of course, the tool should at the very least point to a website/wikipage explaining the details, and giving references to other documentation (i.e. for specific distro's).
tweaking on your own is asking for trouble. if it aint broke dont fix it!
At least such a tool could tell you if there's anything broken (with regards to realtime operation) in your configuration ;)

User avatar
raboof
Established Member
Posts: 1710
Joined: Tue Apr 08, 2008 11:58 am
Location: Deventer, NL
Contact:

Re: Configuration 'quickscan'

Post by raboof »

I created a quick first stab to better explain the idea:

http://arnout.engelen.eu/files/dev/linu ... ickScan.pl

When ran, it produces output like this:

Code: Select all

Finding current kernel config... found /boot/config-2.6.24-19-rt
Checking for Ingo Molnar's Real-Time Preemption... found - good.
Checking for tickless time support... not found - good.
Checking for 1000hz clock... found - good.
Checking for High Resolution Timers... found - good.
Checking filesystem types... 
** Warning: do not use /mnt/sda2 for audio files.
   fuseblk is not a good filesystem type for realtime use and large files.
   For more information, see http://wiki.linuxmusicians.com/doku.php?id=system_configuration#filesystems
Checking filesystem 'noatime' parameter... ok.
Checking the ability to prioritize processes with (re)nice... yes - good.
Checking whether you're in the 'audio' group... yes - good.
Checking sysctl settings:
- checking inotify max_user_watches... >= 524288 - good.

studio32
Established Member
Posts: 2415
Joined: Mon Apr 07, 2008 5:09 pm

Re: Configuration 'quickscan'

Post by studio32 »

@ Raboof, sorry for not checking your script earlier.. It's great and I think it CAN be USEFUL!

Code: Select all

$ sudo perl /home/jack/Desktop/realTimeConfigQuickScan.pl
Finding current kernel config... found /boot/config-2.6.24-21-rt
Checking for Ingo Molnar's Real-Time Preemption... found - good.
Checking for tickless time support... not found - good.
Checking for 1000hz clock... found - good.
Checking for High Resolution Timers... found - good.
Checking filesystem types... ok.
Checking tmpfs mounted on /tmp..  not found.
** Warning: no tmpfs partition mounted on /tmp
   For more information, see:
   - http://wiki.linuxmusicians.com/doku.php?id=system_configuration#tmpfs
   - http://lowlatency.linuxaudio.org
Checking filesystem 'noatime' parameter... 
** Warning: / does not have the 'noatime' parameter set
   For more information, see http://wiki.linuxmusicians.com/doku.php?id=system_configuration#filesystems
** Set $SOUND_CARD_IRQ to the IRQ of your soundcard to enable more checks
Checking the ability to prioritize processes with (re)nice... yes - good.
Checking whether you're in the 'audio' group... no.
** add yourself to the audio group with 'adduser $USER audio'
Checking for multiple 'audio' groups... no - good.
Checking sysctl settings:
- checking inotify max_user_watches... >= 524288 - good.
Checking for resource-intensive background processes... none found - good.
not in the audio group? I am in it!

Code: Select all

$ sudo adduser jack audio
The user `jack' is already a member of `audio'.
I doubt if relatime and noatime makes a lot of difference... (?)

I gonna read this: http://lowlatency.linuxaudio.org
Set $SOUND_CARD_IRQ to the IRQ of your soundcard to enable more checks
How? How can I find the IRQ of my soundcard?

User avatar
khz
Established Member
Posts: 1397
Joined: Thu Apr 17, 2008 6:29 am
Location: German

Re: Configuration 'quickscan'

Post by khz »

i did the same mistake like you studio32. i run the script as root, not as user :)

Code: Select all

daw@dawtux ~ $ /home/daw/Audio/realTimeConfigQuickScan.pl
...
Checking whether you're in the 'audio' group... yes - good.
..
studio32 wrote:How? How can I find the IRQ of my soundcard?

Code: Select all

lspci -v
maybe with

Code: Select all

|grep "your soundcard"

Code: Select all

cat /proc/interrupts
btw i dident have a RT patch and i think you dont need anymore since 2.6.26.xx.
is this right?

realTimeConfigQuickScan.pl

Code: Select all

daw # /home/daw/Audio/realTimeConfigQuickScan.pl
Finding current kernel config... found /proc/config.gz.
Checking for Ingo Molnar's Real-Time Preemption... not found.
** Kernel without real-time capabilities found
   For more information, see http://wiki.linuxmusicians.com/doku.php?id=system_configuration#installing_a_real-time_kernel
Checking for tickless time support... not found - good.
Checking for 1000hz clock... found - good.
Checking for High Resolution Timers... found - good.
Checking filesystem types... ok.
Checking filesystem 'noatime' parameter... ok.
Checking the ability to prioritize processes with (re)nice... yes - good.
Checking whether you're in the 'audio' group... no.
** add yourself to the audio group with 'adduser $USER audio'
Checking for multiple 'audio' groups... no - good.
Checking sysctl settings:
- checking inotify max_user_watches... >= 524288 - good.
Checking for resource-intensive background processes... none found - good.
uname -a

Code: Select all

Linux dawtux 2.6.27-gentoo-r3-k8_kif #1 SMP PREEMPT Fri Nov 21 18:04:53 CET 2008 i686 AMD Athlon(tm) X2 Dual Core Processor BE-2350 AuthenticAMD GNU/Linux
FZ - Does humor belongs in Music?
GNU/LINUX@AUDIO ~ /Wiki $ Howto.Info && GNU/Linux Debian installing >> Linux Audio Workstation LAW
  • I don't care about the freedom of speech because I have nothing to say.

studio32
Established Member
Posts: 2415
Joined: Mon Apr 07, 2008 5:09 pm

Re: Configuration 'quickscan'

Post by studio32 »

btw i dident have a RT patch and i think you dont need anymore since 2.6.26.xx.
is this right?
Dont know...

Is there also a scan script for checking how goed the system is working? E.g how much latency etc. to compare distro's or audio devices for example?

studio32
Established Member
Posts: 2415
Joined: Mon Apr 07, 2008 5:09 pm

Re:

Post by studio32 »

brummer wrote:do you mean something like rtirq:
http://www.rncbc.org/jack/
rtirq-20071012.tar.gz

description is here:
http://irc.esben-stien.name/mediawiki/i ... ux_Systems
The websit is hacked? What is rtirq?

brummer

Re: Configuration 'quickscan'

Post by brummer »

Startup scripts for tunning the realtime scheduling policy and priority
of relevant IRQ service threads, featured for a realtime-preempt enabled
kernel configuration.

User avatar
raboof
Established Member
Posts: 1710
Joined: Tue Apr 08, 2008 11:58 am
Location: Deventer, NL
Contact:

Re: Configuration 'quickscan'

Post by raboof »

studio32 wrote:

Code: Select all

$ sudo perl /home/jack/Desktop/realTimeConfigQuickScan.pl
...
Checking whether you're in the 'audio' group... no.
** add yourself to the audio group with 'adduser $USER audio'
Because you're running with 'sudo', it's checking whether 'root' is in the audio group :). I should find a solution for that.
Set $SOUND_CARD_IRQ to the IRQ of your soundcard to enable more checks
How? How can I find the IRQ of my soundcard?
You can see that in lspci - I should add that to the warning.

studio32
Established Member
Posts: 2415
Joined: Mon Apr 07, 2008 5:09 pm

Re: Configuration 'quickscan'

Post by studio32 »

lspci - I

are you sure? And how do I set it?

thorgal
Established Member
Posts: 739
Joined: Mon Apr 07, 2008 6:04 pm

Re: Configuration 'quickscan'

Post by thorgal »

Code: Select all

cat /proc/interrupts

studio32
Established Member
Posts: 2415
Joined: Mon Apr 07, 2008 5:09 pm

Re: Configuration 'quickscan'

Post by studio32 »

@thorgal thanks.
brummer wrote:Startup scripts for tunning the realtime scheduling policy and priority
of relevant IRQ service threads, featured for a realtime-preempt enabled
kernel configuration.
How do I use it on a Debian system?

Code: Select all

# rtirq.sh start
bash: rtirq.sh: command not found

thorgal
Established Member
Posts: 739
Joined: Mon Apr 07, 2008 6:04 pm

Re: Configuration 'quickscan'

Post by thorgal »

get the 64studio package :

http://www.mirrorservice.org/sites/64st ... -1_all.deb

then, in a terminal as root :
dpkg -i rtirq_20070101-1_all.deb

then, to tweak the setup, you can edit the text file /etc/default/rtirq
it really implies that you have an RT patched kernel because the patch will make the kernel kick off some processes that wouldn't exist without the patch. If you run a non RT patch kernel, the script does not make sense even if it's installed. It will just fail to do what it's supposed to.

Post Reply