JackLab/3 Schritte zu JAD für Nerds

aus openSUSE, der freien Wissensdatenbank


Inhaltsverzeichnis

Drei Schritte um SUSE Linux zu einer "Digital Audio Workstation" zu machen

( UPDATE 14. June 06 ) JackLab Audio Distribution 0.4.9 beta preview (JAD powered by SUSE Linux)


Dieses Tutorial zielt auf den musikalischen Anwender mit guten Linux Kenntnissen, der volle Echtzeit Unterstützung braucht für Produktions oder Darbietungs Umgebungen. Dafür benutzen wir einen gepatchten "realtime preemt" Kernel. Für die erforderlichen Benutzerrechte wird PAM genutzt, und optional das Kernelmodul rt-lsm (zur Zeit nicht erhältlich für SL 10.1), was eine bessere Echtzeit Audio Performance ermöglicht als "audio rt-prio" mit PAM. Der Kernel Echtzeitpatch von Ingo Molnar kann andere Kerneltreiber zerbrechen, darum kann es mit mancher Hardware Probleme geben. Aber für einen schnellen Audiocomputer ist es empfohlen, den aktuellen JAD Kernel zu benutzen. Dieses Tutorial ist anwendbar auf SUSE Linux 10.0 und 10.1

Empfohlene Hardware

   * CPU ->1,5GHz
   * RAM ->512MB
   * Audio ->24bit/96khz
   * festplatte ->40GB
   * Audio Monitor,  Vorverstärker, Mikrophone
   * Midicontroller / Masterkeyboard
   * Breitband Internet Zugang
   * DualScreen (Xinerama) (Matrox g550 empfohlen)


1. SUSE Linux 10.0/10.1 installieren

Lade die CDs/DVD für SUSE Linux 10.0/10.1 auf deine Festplatte

International Mirrors - bitte nutze einen Mirror in deiner Umgebung Hier ein paar Beispiele:

5 CDs - SUSE 10.0 OSS

5 CDs - SUSE 10.1

Alternativ kannst du auch eine ftp-installalation machen.

Versichere dich das du mindestens 20GB Festplatte auf deiner Festplatte zur freien Verfügung hast, zehn für das Betriebssystem und zehn für dein home-Verzeichniss. Installiere dein /home-Verzeichniss auf einer seperaten Partition, für zukünftige Updates deines Systems.

Mache einfach eine KDE Installation oder wenn du es schlank benötigst, ein minimales graphisches System. Formatiere die Festplatten mit ext3 (SEHR WICHTIG). Sei schlau und füge den Benutzer (Du) gleich der Gruppe "audio" zu, in der abschliessenden Installation. Nach der Installation hast du ein optimales SUSE Linux, aber nicht mehr.

2. Extend your Software Installation Sources

With this step you can get access to the JAD Kernel and the audioapps like Ardour, Rosegarden, MusE etc.

Here is an overview of the various package manager to install jacklab software (or any other source, like packman) to your hd via internet.

I recommend to use the package manager "smart" with "smart-gui" -it's easy to use, fast and compatible to many install - protocols, like apt, yum, yast or plain rpm.


APT

Insert into /etc/sources.list for SuSE-10.0:

rpm ftp://ftp.gwdg.de/pub/linux/suse/apt/ SuSE/10.0-i386 jacklab

Insert into /etc/sources.list for SuSE-10.1:

rpm ftp://ftp.gwdg.de/pub/linux/suse/apt/ SuSE/10.1-i386 jacklab


With new APT (supporting repomd):

Insert into /etc/sources.list for SuSE-10.0:

repomd http://ftp.gwdg.de/pub/linux/misc/jacklab 10.0/RPMS/

Insert into /etc/sources.list for SuSE-10.1:

repomd http://ftp.gwdg.de/pub/linux/misc/jacklab 10.1/RPMS/


Download for the new APT:

SuSE-10.0:

wget http://ftp.gwdg.de/pub/opensuse/repositories/home:/rbos/SL-10.0_i586/i586/apt-0.5.15lorg3-17.3.i586.rpm
wget http://ftp.gwdg.de/pub/opensuse/repositories/home:/rbos/SL-10.0_i586/i586/apt-libs-0.5.15lorg3-17.3.i586.rpm

SuSE-10.1:

wget http://ftp.gwdg.de/pub/opensuse/repositories/home:/rbos/SL-10.1_i586/i586/apt-0.5.15lorg3-17.2.i586.rpm
wget http://ftp.gwdg.de/pub/opensuse/repositories/home:/rbos/SL-10.1_i586/i586/apt-libs-0.5.15lorg3-17.2.i586.rpm

Take this RPMs into a directory and install (as root) with:

# rpm -Uhv apt*.rpm

Smart

Channel-definition for SuSE-10.0:

[suse-100-apt-jacklab]
type = apt-rpm
name = SUSE Linux 10.0 APT JackLab Repository
baseurl = ftp://ftp.gwdg.de/pub/linux/suse/apt/SuSE/10.0-i386
components = jacklab
mirror = ftp://ftp4.gwdg.de/pub/linux/suse/apt/SuSE/10.0-i386
mirror = http://ftp.gwdg.de/pub/linux/suse/apt/SuSE/10.0-i386
[suse-100-yum-jacklab]
type = rpm-md
name = SUSE Linux 10.0 YUM JackLab Repository
baseurl = ftp://ftp.gwdg.de/pub/linux/misc/jacklab/10.0/RPMS
mirror = ftp://ftp4.gwdg.de/pub/linux/misc/jacklab/10.0/RPMS
mirror = http://ftp.gwdg.de/pub/linux/misc/jacklab/10.0/RPMS

Channel-definition for SuSE-10.1:

[suse-101-apt-jacklab]
type = apt-rpm
name = SUSE Linux 10.1 APT JackLab Repository
baseurl = ftp://ftp.gwdg.de/pub/linux/suse/apt/SuSE/10.1-i386
components = jacklab
mirror = ftp://ftp4.gwdg.de/pub/linux/suse/apt/SuSE/10.1-i386
mirror = http://ftp.gwdg.de/pub/linux/suse/apt/SuSE/10.1-i386
[suse-101-yum-jacklab]
type = rpm-md
name = SUSE Linux 10.1 YUM JackLab Repository
baseurl = ftp://ftp.gwdg.de/pub/linux/misc/jacklab/10.1/RPMS
mirror = ftp://ftp4.gwdg.de/pub/linux/misc/jacklab/10.1/RPMS
mirror = http://ftp.gwdg.de/pub/linux/misc/jacklab/10.1/RPMS


Insert this channel-definitions into the Smart-GUI or save as jacklab.channel. Import with:

# smart channel --add jacklab.channel

Some additional smart channels for SUSE 10.1:

yast2 | Extra Non OSS SL 10.1 | http://ftp.gwdg.de/pub/opensuse/distribution/SL-10.1/non-oss-inst-source/

yast2 | Guru 3rd party package repository | http://ftp.gwdg.de/pub/linux/misc/suser-guru/rpm/10.1/

yast2 | Packman 3rd party package repository | http://packman.inode.at/suse/10.1

yast2 | SUSE 10.1 BASE Repository | http://ftp.gwdg.de/pub/opensuse/distribution/SL-10.1/inst-source/

rpm-md | SUSE Linux Online Updates http://ftp.belnet.be/mirrors/ftp.suse.com/suse/i386/update/10.1/


YUM

- start YaST

- Software - cahnge installation source- insert new

- Protocol: HTTP

- Servername: ftp.gwdg.de

=> for SuSE-10.1

- Directory: pub/linux/misc/jacklab/10.1/RPMS

=> for SuSE-10.0

- Directory: pub/linux/misc/jacklab/10.0/RPMS


YAST

For SuSE-10.0 you can simply use the YaST-install-sources (broken in 10.1 because of changes in the install system):

(->Software>>change installation source>>add)

JackLab JackLab ProAudio software and audio realtime kernel for musicans and mediaproducer.

protocol    - FTP
            - HTTP
server name - ftp.gwdg.de
Directories - pub/linux/misc/jacklab/SUSE-10.0

Optional SUSE 10.0 YAST Sources from different other maintainers:

10.0 installation source Contains more software then the 5 installation CDs

protocol    - FTP
            - HTTP
server name - ftp.gwdg.de
Directories - pub/opensuse/distribution/SL-10.0-OSS/inst-source

Packman Packman offers ALSA updates, multimedia codecs and enlightenment (e17) for openSUSE Linux. Please use a mirror if possible.

protocol    - HTTP
              FTP
server name - ftp.gwdg.de
Directories - pub/linux/misc/packman/suse/10.0/

JAVA for openSUSE 10.0

protocol    - FTP
            - HTTP
server name - ftp.gwdg.de
Directories - pub/opensuse/distribution/SL-10.0-OSS/inst-source-java

Additional commercial applications

protocol    - FTP
            - HTTP
server name - ftp.gwdg.de
Directories - pub/linux/suse/ftp.suse.com/suse/i386/10.0/SUSE-Linux10.0-GM-Extra/

Update KDE 3.5

protocol    - FTP
            - HTTP
server name - ftp.gwdg.de
Directories - pub/suse/i386/supplementary/KDE/update_for_10.0/yast-source

Guru Guru's RPM site contains packages optimized for i686

protocol    - HTTP
            - FTP
server name - ftp.gwdg.de
Directories - pub/linux/misc/suser-guru/rpm/10.0

See also openSUSE Additional YAST Sources for more installation sources.

Install kernel and software

Install the recent JAD kernel and some proAudio software updates.

List of recommended software

(ToDo) Ardour, MusE, Rosegarden-4, Q etc.

(ToDo) Packman for various audio codecs and ALSA updates.


Dual Kernel Boot

If you want to be sure to have the option to boot with your standard kernel (skip this step if you want to delete the standard kernel)

Check which kernel runs:

# rpm -qa | egrep kernel
kernel-2.6.13-14-default

Erase default from the data base:

# rpm -e --justdb kernel-2.6.13-14-default

Install the jad-kernel, after (don't reboot now) editing /boot/grub/menu.list as root with any editor

Copy the SuSE 10.0 default section, paste it under there and make some changes:

First section: change the title(only for example)

title openSUSE JAD 0.4.0 beta preview
    root (hd2,0)
    kernel /boot/vmlinuz root=/dev/hdc1 vga=0x317 selinux=0    resume=/dev/hda6  splash=silent showopts
    initrd /boot/initrd

Second section: the kernel installer make a new symlinks named vmlinuz-previous, initrd-previous, change that and maybe the title (only for example)

title SUSE 10.0 default kernel
    root (hd2,0)
    kernel /boot/vmlinuz-previous root=/dev/hdc1 vga=0x317 selinux=0  splash=silent resume=/dev/hda6  showopts
    initrd /boot/initrd-previous

3. Boot into JAD

After the reboot you have to activate the audio realtime. This is nessesary, because the low-latency audio demon JACK is not able to start without a working audio realtime user management. (But JACK can start in "softmode" - but with a huge lack of realtime performance.) We have two ways of audio realtime user management, both need the group "audio":

Make sure that the user (you) is member of the group "audio" with yast (user administration).


User realtime with PAM for rt_prio

This is the recommended way of the "official" SUSE. For SUSE 10.0 rt_prio for audio failed with the SUSE distributed PAM, so there is a fixed PAM available in the jacklab repository.

PAM is finaly working for audio on SUSE 10.1 "out of the box" now. It will be fast as rt-lsm, but more secure for the system. It is possible to use PAM for rt prios with the SUSE 10.1 standard kernel, but with a lack of performance.

To activate PAM for audio realtime prio, edit your /etc/security/limits.conf (as root). Insert following lines at the end of the file:

@audio          -       rtprio          90
@audio          -       nice            -10
@audio          -       memlock         4000000
# End of file 

Then reboot, thats it.

Maybe you can use other values, like rtprio 99, nice -20 or something like that.(-20 is the highest, 20 the lowest nice priority for processes)

PAM stoping audioApps if they use more CPU then allowed (max.-> 99%). This can be very contra-productive in a session. Midest the synth solo the app quiting, cos there was a short high peak with 100% CPU. If you need more stability, try rt-lsm.

User realtime with rt-lsm

This is the radical way for "full user preemt". That means: you are free to freeze your system, but otherwise the realtime audio is more stable. rt-lsm dosn`t work for unknown reasons with the recent jad kernel for SUSE 10.1, so there is no kernel module "km-realtime-lsm" available. But with 10.0 it's working like a charme.

Determine ID users of the audio (as a user)

~> id
~> uid=1000(metasymbol) gid=100(users) Gruppen=16(dialout), 17(audio), 33(video), 100(users)

activate modules: (as root)

# insmod /lib/modules/2.6.15-jad2-default/extra/realtime.ko
# rmmod realtime
# depmod -ae
# modprobe realtime gid=17


Now the regular user is able to run audio realtime capabilities for jackd.

# lsmod | grep realtime
realtime               11280  0


if realtime is working OK, a:

# echo "modprobe realtime gid=17" >> /etc/init.d/boot.local

will automate the start of the real-time user module.



Go and make some music

After this our SUSE Linux being ready to work in a musical production studio. Now it is time to explore the new possibilities of JACK and an endless number of new programms.

To have the full JAD experience, you can install a slim windowmanger like "e17 - enlightenment" (available for SUSE 10.0 in the packman repositories), fluxbox (suse install source) or windowmaker (installed by default on SUSE Linux)

Please take a notice that JAD is in a beta state: that means: Most of the features are complete, but there can be bugs and other problems. Please join into the JackLab Support Community to share your experiences, posting bugs or get generaly support for JAD.

Todo: lists of components, proofreading