Computers 'n Stuff: May 2007

I here share the resolutions for my Linux problems so they might safe somebody some time.

Tuesday, May 29, 2007 parmanent link to this post

Customizing Blogger "Post a comment" link and open it in a Popup Window


The "post a comment line" can not be customized using the classical layout in blogger unless you hack your template as described here. So if you like the "post a comment" form open in a new Window than this solution is ok. The option to open it in a popup window is not documented. Here I discribe how the customized link can be hacked to open the blogger comment form in a a popup window on click.
First you have to follow the instructions of bloger help and find out your Blog ID. If you want to open the post comment field in a new window you could use the code as suggested by blogger. It should look similar to this:
<a href="http://www.blogger.com/comment.g?blogID=1234567&postID=<$BlogItemNumber$>">You want to talk to me?</a>


where 1234567 should be replaced by you blog id and "You want to talk to me?" by the line you want to appear as the link to you comments form of you blog.
However, there is no way documented to open that form in a pop up window with a customized link. To do that you have to replace <$BlogItemCreate$> with the following code in your template:
<a class="comment-link" href="http://www.blogger.com/comment.g?blogID=1234567&postID=<$BlogItemNumber$>&amp;isPopup=true" onclick="window.open(this.href, 'bloggerPopup', 'toolbar=0,scrollbars=1,location=0,statusbar=1,menubar=0,resizable=1,width=400,height=450');return false;">You want to talk to me?</a>

Again, you have to edit 1234567 to match your blog ID and replace "You want to talk to me?" by the text you want to appear as the link to your comments input form.
Try yourself >> You want to talk to me?
Et voilá, if you now click on the link your comments form will open in a popup
window.

Labels: ,

Do you want to read on <<click

The Novell Microsoft deal


I have read about that windows Novell deal. Since I use OpenSuse I am a little concerned about that thing. What is all this Linux Novell Microsoft thing about. I understand that Microsoft and Novell siged an agreement, but I'm not positive about the reasons why. What will be the long term goal of Microsoft and Novell concerning open source, what would a scenario look like where Microsoft could achiever ther goals concerning the open source community.

To start this analysis we first have to collect a few thing we know about Microsoft:
  1. We now that Novell is sells server applications and systems that integrate into Windows architecture.
  2. We know that Microsoft is a hostile Company strieving to dominate the market. Microsoft has used its markt power to desroy competitors
  3. Microsoft trys to replace exisiting standards by their own standards or to establish their own proprietary standards on the market.
  4. Microsoft has never been innvoative, they have always been reactive in developping standards and software and they only distribute closed source code. Patents are usually based on innovations and coping copyrighted code usually needs knowledge of the source code its unlikely that open source is using windows copyrighted code.
  5. Microsoft is leader as a provider for desktop systems but is completely out of the loop when it comes to server systems.
  6. Xen Virtualisation is more suitable for server systems
  7. If you want to migrate from one opteration system to the other it might be helpful to be able to operate both systems on the same mashine the same time.
From the above mentioned facts I can not imagine that Microsoft is likely to cooperate with to open source communitiy. They are trying to gain momentum on the server market wich is at the moment dominated the open source community. Though it is understandable from the Novell history that they want to support micorsoft operating systemes and that it might be useful for them for marketing purposes right know. However, it is highly likely that Novell will become unwillingly the Trojan horse that Microsoft will unleash to destroy the Open Sorce community. Without beeing supported by the open source community I am pretty sure that microsoft would have disapeard from the surface of our earth but now things are different.
Microsofe states that it will cooperate with tha open source community on the development of cross platform solutions but in reality they are trying to sneak in proprietary code maintained by Novell Suse and my be OpenSuse which will be indespensible for the function. In parallel they will and promote it and market it untill it they have a market share their system becomes the standard and nobody can use untainted openssource any more.
In conclusion I think it might be the strategy of Microsoft to take over the open source and taint it with closed source and then continue to maintain the code by themselves. As a result Microsoft has taken over the Linux project ....

Have fear ....


Labels: ,

Do you want to read on <<click

Sunday, May 27, 2007 parmanent link to this post

Linux toolbox: useful basic console commands to start using Linux

LLinux features an extremely powerful command line interface with an amount of commands available that windows users can only dream of. Most of the time I think the command line is faster, more flexible and powerful than any grafical user interface (GUI), especially when it comes to system administration. However, for me as a beginner it was a struggle to find and understand the basic commands you need to maintain and configure a linux desktop. Thus, I decided to write down the commands I personally found to be most frequently used. Maybe this is a kick start for some users who start to use Linux.

General syntax remarks
First of all its important to know that linux commands usually accept options which come after the command itself. The short form of the option is usually preceded by a - (one hyphen) and the long form by -- (two hyphens). If you are not sure what a command does or what its syntax is type the command followed by -h ore --help. eg:

# man -h
# man --help

this will remind you of the syntax and options the command man accepts
man
man is a lifeline for linux. man brings up the manual or man page of any command available on your system instructing you how to use that command and what it is doing. So if you stumble upon a command and you don't now how its used or what its doing then type man in combination with the command you need the information about. For example if you want to know what - man - does or which options for - man - are available type:
# man man

cd
cd is use to change the current directory. If you want to change to the root directory type
# cd /

The prompt will show you the directory you're currently in. Typing cd followed by two dots (..) will bring you one level up in the directory tree.
# cd ..

Typing cd with out any options will bring you to your home directory.
the tab key
hitting the tab key in the console will expand your input depending on the context youre using it in. e.g. linux is trying to guess what you want to type. So if you type m and the tab key linux will list all available commands starting with m. The tab key is particularly useful if you're typing long directory path-names. just type the initial letters and then press the tab key to see if linux can already expand your input to full length.

tab tab
hitting the tab key twice will list you all posible input options in the context your just in.

CTRL + C
pressing ctrl and c at the same time breaks a programm you starte from the command line.

up-arrow and down-arrow key
the up-arrow will bring up your recent iput commands. the down-arrow does the oposite. this way you can browse your input history.

Shift page-up and shift page-down
use this to scroll up and down the console text.

CTRL Alt F1, CTRL Alt F2, CTRL Alt F3 ....CTRL Alt F7
pressing CTRL Alt and one of the function keys F1 - F7 lets you swich to other consoles. The GUI (X window) lives in consel F7


su
If you're working in a console you started from a Xwindow console and you need root access to you system you can use the su command: su will prompt you for the root password and than log you in to a root console.
# su -c "somecommand"

will ask you for your your root password to execute somecommand with root privileges and will exit right after the command has finished. This is useful if you need the root privileges for only a few commands.

ls

this will give you a short list of the directory your currently in. it will return only the directory names.

ll

this will give you a long list of the directory your currently in. it will retrurn the file and directory names including the respective owner and group.

l

will give a similar output like ll put will also list hidden files and directories which are usually preceded by a . (dot).

tar

this command comes in handy if you need to extract tar archives. A lot of software for linux is dirtributed as tar archives.
# tar xvzf somefile.tar.gz

This is the command you will usually have to use to extract an tar.gz archive of the name e.g. somefile. the option x means extract, v triggers the the output of all extracted filenames, z tells tar that is has to extract a zipped archive and the flag f inicates that the filname of the archive to be processed follows.
chown
this will set the owner of a file or directory e.g.
# chown me somefile

This will set the owner of somefile to be me. Test if successful with:
# l somefile


chgrp

this will set which group a file or directory belongs to e.g.
# chgrp users somefile
will set the group of somefile to be users.

chmod

chmod is used to set if a file is writeable (w) readable (r) or execuatable (x) by owner, member of the group and the world. look for example at the following line of the ll output:
-rw-r--r--   6 root root  4096 26. Mai 14:56 somefile 

The first is a hyphen since this is a file. d would indicate a directory and l a link. the first triplet rw- sets the rights for the owner of this file which is root as indicted by the first entry in the list which is the owner. Hes allowed to read and write this file but not to execute it. The second triplet r-- indicates that members of the group root can read and execute this file but not write to it. The same access ist granted to this file to all others which is set by the last triplet of letters r--. now we assume you want to make this file executable. to do this you could use e.g.
chmod a+x somefile

In addition you want to allow members of the group root to write to this file. this could be done by
chmod g+w somefile

In depth information about Linux permissions

md
This command is used to create a directory with the name somedir
# md somedir

rd
This command is used to remove somedir. this works only if the directory is empty
# rd somedir


If you want to remove a directory with all its contained files and subfolders you could use
# rm -r somedir

rm
This command is used to remove a file with the name somefile
# rm somefile

It can also be used to remove folders with all its contents:
# rm -r somedir

find
Find is useful if you know the name of a file or directory but can't remeber where that file lives. to search your complete directory tree for somefile type
find / -name somefile

To find all files of a certen kind e.g. jpg files which end in .jpg use the asterisk * e.g.
find / -name *.jpg

lsmod
Sometimes to install hardware and stuff you need to know which modules are loaded. typing lsmod will return you a list of loaded modules. this list can be rather long so if you're looking for a module you know the name of grep in combination with a pipe comes in handy
| (the pipe)
The commands you used so far read from the standard input and print the output to the standard output which is usually the console so you can read it. But sometimes you prefer to redirect the output form the standardout to the standard input of a second command to process it further. this can be done by a pipe. To commands are linked together by a pipe in this way, e.g.:
# onecommand | nextcommand

This will send the output of onecommand to the nextcommand wich will do some further processing and sends the output to the standard out which usually happens to be your console.
grep
grep will help you to find lines containig some letters or words your interested in. So if you want to know if somemodule is loaded in your mashine you could type:
# lsmod | grep somemodule

grep is also useful if you want to search your logfiles for messages your interested in if you use it in combination with cat.

cat

Cat will print the contents of a file to the standard output which is usually your console.e.g.
# cat /var/log/messages

Will print the content of your messages logfile.this can be quite long. So if you you are only interested in lines of your log file that contain somephrase you could use :
# cat /var/log/messages | grep somephrase

to filter the output of cat
tail
tail somefile outputs the last ten lines of somefile. The -f option will print updates to the file directly to the console so you can trace whats going on. e.g.
# tail -f /var/log/messages

head
head does pretty much the same as tail but outputs the first ten lines
dmesg
This prints out all your kernel messages. Checking kernel messages is good for debugging, e.g. if some modules failed to load. this is how the linux kernel talks to you and tells you what he has been seeing.

write standard output to file >

sometimes you may need to post parts of your logs to a newsgroup for debugging purposes. To do this you can write the output of cat piped through grep to a file e.g.
# cat /var/log/messages | grep somephrase > news.txt

and the post the output which you can find in news.txt

CTRL + Z
pressing ctrl and z at the same time will interupt a programm and fork it to background you started form the command line and that is still running. Use the command fg to bring it back to the foreground or bg to continue the program in the background.

shutdown
shutdown without options does pretty much what you expect. interesting options are:
# shutdown -h now does preety much the same as:
# halt
this asks all applications to gracefully exit and stops all processes in an ordered fashion.
# shutdown -r now
this will reboot the system. Does pretty much the same as
# init 6

init

this is useful for switching runlevels
# init 5
Initiates the runvlevel with everything, network firewoall GUI login and the like.

# init 3 swichtes to a lowere runlevel and stops Xserver and GUI. this is good for debugging of Xserver.
kill
Use kill to terminate a process.
kill -term pid

where pid has to be replaced by the process id. you can find out about the process id by typing:
ps aux

use in combination with grep to reduce output

Some Links to Guides to start with:
Linux Quickstart More absolute Basic you'll need for Linux
Network commands: list of commmands and short explaination
Console commands list of console commands and brief explaination.
start with linux If you are interested to operate Linux than this would be a good point to start.
system administrator guide This is a good guide to learn how to administrate your linux
the file system learn where Linux stores stuff

Labels: ,

Do you want to read on <<click

Saturday, May 26, 2007 parmanent link to this post

Installation and setup of the em28xx linux driver for analogue devices like the PCTV analog USB 2 (150e/55e) in opensuse 10.2


Ihave an old Pinnacle analog USB video grabber device which I bought some time ago for no particular reason. I tested It in windows but picture quality and software sucked. Channel switching took forever and nothing worked the way I wanted it to, so I stopped using it. But now I tried to install it in OpenSuse Linux just for the hack of it. Here I write my experiences with this device.

First I have to say that Linux actually supports this device and the picture quality of the linux driver and tv sofware is much better than that provided by pinnacle for windows. So if you want to use this PCTV analog usb its well worth switching to linux.

The PCTV analog USB is em2820 videodecoder chip based vido grabber with an LG TAPE series tuner. I once cracked it open to see the chips inside the PCTV analog USB 105e 55e

If you want to use the 150e/55e with OpenSuse 10.2 the em28xx driver which is a successor of the em2820 is the right choice. As far as I understand it, this driver is part of the v4l project and is maintained by Markus Rechberger, Mauro Carvalho Chehab, Aapo Tahkola, Ludovico Cavedon, Sascha Sommer, Aidan Thornton. Thanks to them we can now use this budged video grabber with a great quality driver.

The em28xx is loaded as a kernel module in OpenSuse 10.2 as soon as a PCTV analog USB is connected to a USB port. It then automatcally creates device nodes /dev/dsp (digital audion/pcm) and /dev/video (raw video).

You first have to update the em28xx driver that comes out of the box of OpenSuse 10.2, this means you have to compile them from source and install them. This sounds harder than it is, so don't get scared. The result is well worth the effort.

The updated drivers from may 2007 will allow you to use the following software in addition to mplayer which is also supported by the old Suse driver:

MythTV, TVtime, Kdetv, freevo. In addition the picture quality is markedly improved, setting the resolution of the grabbed video image and setting of the correct videonorm is now possible. Last but not least no VBI device is initialized any more which might also cause some strange errors.

To update the driver you will have to install gcc, kernel-sources, kernel-headers and mercurial packages using your favorite packet manager e.g. yast2 for OpenSuse. In addition you need SOX for the operation of the digital audio. Now you are prepped to download and build the drivers. This is quite easy since the PCTV analog USB 150e 55e doesen't need firmware or any kind of DVB support like DVB cards would require which are also supported by the em28xx. To dowload the sources and to build the driver type:
# hg clone http://mcentral.de/hg/~mrec/v4l-dvb-kernel
# cd v4l-dvb-kernel
# make
# make ./install
If this driver update doesen't solve your problem then you might consider to try the experimental tree of the driver:
# hg clone http://mcentral.de/hg/~mrec/v4l-dvb-experimental
# cd v4l-dvb-kernel
# make
# make ./install


Markus Rechberger also suggested somwhere (cant remember the link, though) to reinstall the media/lib to troubleshoot problems with using tvtime. This helped me too to get TVtime working. This could be done by:

# rm -rf  /lib/modules/`uname -r`/kernel/drivers/media

and then reinstalling the drivers. May be that will help if you are experiencing problems which can't be solved otherwise.

In OpenSuse the module (modprobe or insmod) options live in /etc/modprobe.d/tv. The driver has to be loaded to with the correct options so that It will support the PCTV correctly. My /etc/modprobe.d/tv looks like this:
alias char-major-81 videodev
alias char-major-81-0 off
alias char-major-81-1 em28xx
alias char-major-81-2 off
alias char-major-81-3 off
options em28xx card=8 tuner=47 disable_ir=0


All available valid insmod options for card= and tuner= for em28xx are listed here

Without the tuner=47 option I could not tune UHF channels with my device.

Testing video playback

If you have mplayer installed then you can use it to test for correct setup. An mplayer command which is successfully used to start mplayer for tv playback was:
# mplayer -tv device=/dev/video0:amode=0:input=0:norm=PAL:driver=v4l2:outfmt=yuy2 tv://E6
this should tune channel E6 and open a tv window. Use h and k to switch channels. Note that /dev/video0 has to be adjusted to match your PCTV videograbber. It might also be /dev/video1 or the like if you have multiple video input devices.

This one starts mplayer with audioplayback enabeled without the need of SOX
# mplayer -tv driver=v4l2:device=/dev/video0:amode=1:input=0:norm=PAL:adevice=/dev/dsp1:immediatemode=0:audiorate=48000 tv://
Note that /dev/dsp1 needs to match the Audioinput of your PCTV Videograber. It might be /dev/dsp0 or the like.

Audio setup
The PCTV analog USB features no analog output which you could plug into the line in input of your audio card. The PCTV features digital audio (PCM) which has to be piped to the digital sound input of you sound card. Of the software I have tested only mplayer and MythTV can read directly from the digital sound device of the PCTV analog USB and output it over your soundcard. Kdetv, xawtv, motv and freevo remain silent because they expect an analgo output to be connected to the line in of your sound card. For these tv viewers you'll need a workaround. You have to install and use sox to pipe the digtal audio from the tv card to your sound card.
these commands worked for me:
# sox -t ossdsp -r 48000 -b -c 2 /dev/dsp1 -t ossdsp /dev/dsp
# v4lctl -c /dev/video0 volume mute off

(/dev/dsp1 is the pcm device of the analog USB and /dev/dsp is the PCM in of you audiocard. /dev/video0 should be the PCTV analog USB) Change this if the names of the devices on your box differ) now you should hear the sound of the channel you just tuned to with your PCTV analog USB. If you hear only static then try to tune to another channel. Now you can fire up your TV-viewer software e.g kdetv to swich the channels.


Links:
em28xx driver FAQ A lot of problems get addressed here
em2820 driver FAQ this is the old version of the em28xx driver. All development is done on the em28xx now I guess, but you can find some troubleshooting hints for the PCTV analog USB 10e 55e since it is a em2820 based device.
Official em28xx Project Wiki

Labels: ,

Do you want to read on <<click

Wednesday, May 23, 2007 parmanent link to this post

How to install AppArmor and Dazuko in OpenSuse 10.2



So you want to run Dazuko on a OpenSuse 10.2 System. However, This will not work out of the box, since Dazuko and Apparmor are using the same Linux Security Module (LSM) API. If you try to load dazuko while apparmor is running you'll get:

dazuko: failed to register
modprobe: FATAL: Error inserting dazuko (/lib/modules/xxxxx/weak-updates/dazuko.ko): Invalid argument

But there are ways to get Dazuko up and running and Apparmor even at the same time.

To run dazuko in OpenSuse 10.2 you have basically three options:
  1. Unload the apparmor module before you load the dazuko module
  2. recompile the dazuko module with syscalls enabeled (this doesen't work for chroot directories
  3. recompile the kernel to export __d_path
Here I discribe all three of these options: How to do it and how to choose the right option.

Option 1:
This is the right option if you don't need AppArmor. You need to install Antivir using the ./install script that comes with the installation file which can be downloaded from avira. In addition you have to install the dazuko module using e.g. the Yast utility from the OpenSuse 10.2 distribution.
# modprobe -r apparmor
# modprobe dazuko
# avguard start

Use the Yast runtim configuration to make the changes permanent.

Since the default SuseLinux 10.2 default kernel is an SMP kernel for both single and multi CPU systems which does not export __d_path you there are only the following ways to get dazuko running together with AppArmor:

Option 2:
download the sources of the dazuko module and compile the module with syscalls enableled to circumvent the LSM API apparmor uses , local dpath disableled to avoid problems with the SMP kernel and disabbeled chroot support to get it running without __d_path. This is the right choice if you don't need chroot'd directories.
# ./configure --disable-local-dpath --disable-chroot-support --enable-syscalls --mapfile=/boot/System.map-`uname -r`
# make

now install and load the module

Option 3:
This assumes your in the folder wher the patch lives. Its in the extracted source folder of the dazuko moudIf you need support for chroot directories you have to patch kernel source e.g.

# patch /lib/modules/`uname -r`/build/fs/dcache.c patch_dpath.diff


and recompile the kernel in order to make him export __d_path. However this command seems not to work when you never build a kernel yourself. In this case use

# patch /usr/src/linux/fs/dcache.c patch_dpath.diff
# make clean
# make oldconfig
# make
# make modules_install
# make install

The dazuko module can only be compiled after compiling and loading the kernel so that the dazuko module will be compiled with the correct System.map. Else you get
dazuko: loaded, version=2.3.2
dazuko: no version for "__d_path" found: kernel tainted.
when loading the module

The Dazuko module can be configured and installed in this way to support chroot'd directories:
# cd /usr/lib/Antivir
# ./configure --disable-local-dpath --enable-syscalls --mapfile=/boot/System.map-`uname -r`
# mv /lib/modules/2.6.18.2-34-default/updates/dazuko.ko /lib/modules/2.6.18.2-34-default/updates/dazuko.ko.orig
# cp dazuko.ko /lib/modules/2.6.18.2-34-default/updates



everything is detailed in the Suse README of the AntiVir Distribution:

AntiVir README for users of the SUSE distribution
=================================================

There are issues with the on access scan feature on recent SUSE systems. More
thorough and up to date information is available at the www.dazuko.org site.
See the FAQ at http://www.dazuko.org/faq.shtml and the installation
instructions at http://www.dazuko.org/howto-install.shtml for more details.
The RELEASE_NOTES file that came with this installation package discusses the
issues with the latest Linux 2.6 kernels in more depth.


The on access scan feature of the AntiVir Server and AntiVir Workstation
products (commonly referred to as "Guard") runs on top of the Dazuko kernel
module. That's why it is essential that this module is available and fully
functional on a system where on access scans will be used.

By default Dazuko prefers the LSM API to interface with Linux 2.6 kernels to
capture file events. Unfortunately the AppArmor and SE Linux projects block
this API and prevent other modules from accessing it, which is why the
AppArmor and SE Linux features cannot be employed together with other LSM
using modules such as Dazuko.

In these setups it's necessary to switch to the so called syscall hooking
method to interface with a Linux 2.6 kernel. It's suggested to use at least
Dazuko version 2.3.1 and run the configure script with the --enable-syscalls
option. It's essential to specify a System.map file with the --mapfile=
option which exactly fits the kernel which the module gets built for.

Unfortunately there are System.map files which declare kernel data pages as
read only while they actually are not. Taking action at runtime based on this
information when it's incorrect leads to a kernel BUG() while not taking
action at runtime while the information is correct results in Oopses and
crashes. This situation cannot be detected by software without actually
running into the problem. Neither at build time nor at run time is it
possible to determine the correctness of this information.

At this point it's important that the administrator does know whether the
kernel data pages on this system actually are read only or whether they are
not and were wrongly declared so. With this information the Dazuko configure
script can be invoked with the appropriate options. Should this information
not be available, a test system should be used to try which approach works for
such a configuration (this is not suggested to be done on a production
system).

SUSE distributions usually do not have read only kernel data pages. Which is
why the Dazuko configure script assumes that the System.map information is not
correct and issues a warning message to this effect. Should loading a module
which was built this way result in a kernel BUG(), the module unfortunately
cannot be unloaded and the machine needs to be rebooted instead. The module
then needs to be built with the additional --sct-readonly flag passed to the
configure script.

and here:

==============================
README for Linux 2.6 kernels
==============================

In order to lookup full file paths (even in chroot environments), Dazuko
uses the kernel function __d_path(). Unfortunately this function is no
longer exported to kernel modules in the Linux 2.6 kernel.

Dazuko has its own copy of this function but unfortunately it is only safe
for UP (uni-processor or non-SMP) kernels. This is because the real __d_path()
function uses a kernel lock, which is not available to kernel modules.

If your kernel is not configured as SMP, then it is safe to use Dazuko's
copy of the __d_path() function. This is default.

If your kernel is SMP then you should _not_ use Dazuko's copy of __d_path().
You can disable Dazuko's local copy of __d_path() by configuring Dazuko with:

$ ./configure --disable-local-dpath

Since Dazuko requires __d_path(), your kernel will have to export it if you
disable the local copy. Some GNU/Linux distributions have a modified kernel
that does export this function. The "vanilla" Linux kernel does _not_ export
this function. You can check if your kernel exports this function with:

$ grep __d_path /proc/kallsyms

The results can be interpreted as:

xxxxx T __d_path <= exported xxxxx t __d_path <= not exported If you are running an SMP kernel and __d_path() is not exported, then you will have to modify your kernel source code to export the symbol and rebuild your kernel. The modification is very simply and can be made by using the included patch to modify the fs/dcache.c file. Here is an example: $ patch /lib/modules/`uname -r`/build/fs/dcache.c patch_dpath.diff The location of your Linux kernel source code may be different. Once you have patched the fs/dcache.c file, you can rebuild and install your kernel and kernel modules. If your GNU/Linux distribution doesn't export the __d_path() function, you may want to write them email suggesting that this function be exported in the next release. Note: As a workaround, Dazuko now offers the configuration option --disable-chroot-support. This will disable Dazuko from trying to resolve chroot'd filenames, thus making Dazuko safe for SMP kernels that do not export __d_path(). However, if this option is used, registered applications will only be able to work with chroot'd filenames if they resolve the filenames from within userland. If the application you plan to use with Dazuko requires handling chroot'd filenames (and you have an SMP kernel that cannot export __d_path()), then you should contact the application developer to make sure it supports this option.

Related Post:
Howto Install Dazuko (with AppArmor and AntiVir or ClamAV) with the default kernel in OpenSuse 10.2 64Bit version

Labels: , , ,

Do you want to read on <<click

Tuesday, May 22, 2007 parmanent link to this post

Azureus I2p Network plugin configuration Howto for Linux


So Azureus comes with a lot of nice plugins for download. Let's see which of them I'll install .... wait, what is this I2P network plug in... allows use of the I2P network ... Hm, no idea what I2p network really is, sounds useful though ok let's install the plugin and see what happens.

These were my first thoughts when I stumbled upon the I2P network and the corresponding Azureus plugin. Had I only known how much work i took to get it up and running I probably wouldn't have installed it. Here I write what It takes to set up the Azureus I2P Network plugin.

Outline:
  1. Install the i2prouter
  2. configure the server tunnel
  3. configure Azureus to send the i2pnetwork destination hash of the server tunnel to the tracker instead of the local ip adress.
  4. configure Azureus to listen on the target port of the server tunnel of the 12prouter
  5. configure Azureus and the i2p network plugin to communicate with each other via an proxy network relay port

Introduction:

Ok, what is the I2P network

The I2p network is a anonymous Network inside the Internet. It is a distributed network technology to make it harder to the the server to find out your IP address. I like to think of it as a Network layer on top of the Internet protocols. The Internet is usually not as anonymous as you might think since if you connect to e.g. a server over the Internet a connection is established such that the server knows your IP address. This IP address and the data transmitted from and to this address can be logged. Since ISPs (Internet service provider) log which IP address has been assigned to which user its no problem to trace back the person who established this connection. To cut long things short, your IP address usually reveals you real identity

Things get a little different if you connect to the internet through a proxy. In this case only the proxy knows your IP adress but the servers in the internet only know the IP address of the proxy. Every computer behind such a proxy appears to the internet as only one IP address. And heres what the I2P Netwokr does: It turns your computer into a proxy and all your internet communication has to go through that proxy and the peers are identified by hash keys to each other and not by their real IP address and treaffic is dynamically tunneled through multiple proxys. Since the traffic is encrypted and no single proxy knows all IP addresses of the proxys participating in the tunnel and from the outside its not clear if your only routing the tunnel or are the end of the tunnel it becoms extremely hard to trace which hash key belongs to which IP address.

Ok, what does the Azureus I2P Network Plugin do?

Well, I like to think the I2P Network plugin serves as some kind of proxy to which Azureus connects.In this way the plugin can trace all Azureus traffic and if it detects that Azureus is trying to connect to the I2P Network it redirects the traffic to the port of the I2P router/proxy which knows to handle the torrent protocol in the I2P network. (usually 7654 on your localhost). In other words the I2P network plugin redirects the outgoing I2P traffic of azureus to your I2P router that is if Azureus is trying to connect to some peer outside.

The Incomming traffic is not handeled by the plug in. To allow for incomming traffic you have to configure a server tunnel in your I2P-router and forward this tunnel to some port on the machine where azureus lives and listens. For this to work you have to instruct azureus to overwrite the address sent to the tracker with the hash key for that server tunnel

So, what's next?

Configuration and installation of the i2prouter:

Download the I2P proxy and install it to /usr/local/i2p and fire it up

# java -jar i2pinstall.exe
# cd /usr/local/i2p
# ./postinstall.sh
# ./i2prouter start

now fire up your browser and connect to the i2pconsole at:

http://localhost:7657/index.jsp

If you can see the the I2p proxy console now your i2p router should be up and running. Make sure you do the general I2P router configuration and itis working properly (configuring NAT and the like where applicable) Inbound TCP connection need to be enabeled if you want remote source to connct to Azureus (NAT OK)

Now do the Azureus specific I2P router configuration:

  • Click on "I2P tunnel" Or you can click here
  • Select add new server tunnel standard and click create.
  • Enter a Name e.g. Azureus and a Description e.g. Azureus server tunnel.
  • Check Auto Start (yes) so that the Server tunnel gets opened automatically when you fire up your i2p router.
  • enter the target host which is the IP address or name of the machine where Azureus lives. If your I2P router and Azureus running on the same box its usually ok to enter localhost here.
  • As Target host Port enter the port number your Azureus is listening on incoming TCP connections e.g. 57431
  • Enter a name for the Private key file e.g. AzureusPriv.dat.

The rest can remain unchanged.

  • Now click save and the I2P router will generate a local destination hash.
  • Copy the local destination hash to the clipboard that will appear in the status message window. The hash will be the address or identifier which will be announced to the tracker and wich peers from the i2p network will use to connect to you.
    If you lost this hash you can also copy it from the Local Server Tunnel entry. You will find a new entry und local server tunnels with the name you have chosen above e.g. Azureus. Click on the Name and a Tunnel configuration window will pop open. Now you can copy the hash from the local destination field . Make sure you get the whole thing its very long.

Now your finished with the I2P router configuration

Configuration of Azureus
  • go to Azureus/Tools/Ḱonfiguration/Tracker/Client
  • Click on overwrite announce ip address options and paste the local destination hash in here which you copied from the server tunnel you just created.
  • Move the curser to the end of the hash and append
.i2p
This is important. If you don't do this correctly it will render Azureus unresponsive when you open a torrent.

  • Now go to Connection and enter port 57431 in the incoming TCP field. The port should be the same as your entered as the target port field when you configured the server tunnel in your I2P router.
  • Now go to proxy settings and
  • activate use proxy for comunication with Tracker
  • activate have SOCKS proxy
  • enter localhost as host address
  • enter an unused port which azureus should use to communicate with the I2P network plugin (which serves as proxy) e.g. 15223
  • leave user and pass blank
  • (check) activate Proxying for source communication
  • uncheck (deactivate) imform tracker ..
  • select SOCKS Version V4a (do not use V4, this will not work)
  • check (activate) use the same Proxy setting for Tracker and Source communication.
  • Now go to Plugins/I2P Network Plugin and
Configuration of the I2P Network plugin
  • Check "enable" to activate the plugin
  • enter the path to the directory where you have installed the i2p router to e.g. /usr/local/i2prouter
  • if you don't do this correctly then you get
  • I2P install location not defind, plugin initialisation failed
  • Enter the Port you which the I2p Network plugin to listen on In Network relay port. This port must mach the port you entered as the port for tracker communication.

The rest can remain unchanged.

Configure the UPnP functionality if you which so that the i2p network plugin opens the i2p router ports for you.

  • Now restart Azureus

When lucky then you get: "i2p router connection succeeded" messge
Attantion: This only means that your i2p plugin works. Make sure that Azreus does not accept connections from outsinde i2p and that azureus does not attemt to connect to networks outside the 12p. this might compromise you ananymity since in this case you're in danger transmit your ip and your hasch to the same server.

Now go to tracker.postman.i2p

Troubleshooting:
If Azureus freezes after you opened a terrent then you dident copy the destination hash of your server tunnel to Azureus correctly. Check that .i2p is appended to the end of the hash.
If your NAT status light remains yellow this most likely means that you haven't configured the incomming connections properly. Then you have to check if you configured the server tunnel correctly. Check furthermore if the target port of the Azureus server tunnel of the i2prouter and the TCP port Azureus listens on do match each other. More over the i2prouter needs to be configured to accept incoming TCP connections.
Links:
Azureus I2p Plugin

Labels: , , , ,

Do you want to read on <<click

Monday, May 21, 2007 parmanent link to this post

MythTV: StartRecorder() -- timed out waiting for recorder to start


This problem occured after installation of MythTV under OpenSuse 10.2 using the PCTV analog USB video grabber. Here I write how I solved this issue.


This problem turned out to result from a driver problem for the analogeus USB TV grabber which comes with OpenSuse 10.2. This dirver is outdated. I guess the MythTV can't communicate with the driver. The v4l2 driver for the PCTV USB 150e/55e PAL/SECAM for Linux is the em28xx. The current version fixes this problem.

To install the current driver you need to install the kernel source and kernel headings and the mercurial package which will download the drvier source for you.
In addition its a good idea to a clean reinstall of the media library. I used the following commands which probably can do the trick for you too however don't do the "rm" stuff unless you know that the vf4l driver source compiles without problems:
# rm -rf  /lib/modules/`uname -r`/kernel/drivers/media
# hg clone http://mcentral.de/hg/~mrec/v4l-dvb-kernel
# cd v4l-dvb-kernel
# make
# make ./install

In fact I use the experimentel tree of the driver which also woks fine for me.(http://mcentral.de/hg/~mrec/v4l-dvb-experimental)

The experimental driver works for me with MythTV, Freevo, TVtime, mplayer, and kdetv so it can't get much better, I guess.
releated posts

Labels: , , ,

Do you want to read on <<click

Sunday, May 20, 2007 parmanent link to this post

PCTV analog USB2: "open /dev/vbi: Device or resource busy issue" solved

VBI means Vertical Blank interval of a TV signal in the US terminology. This is the interval between frames where no picture is displayed but information like teletext can be broadcasted. I guess the VBI device in linux is the interface to read out such data from the TV signal provided that you TV grabber can extract you the VBI data from the video signal. Here I write why many people report that the VBI device of the PCTV analog USB is always busy though no application is using it.

the 150e/55e has an em2820 on board which does not support teletext ( raw VBI capture, sliced VBI capture)!!!

Although the em28xx driver supports em2820 based tv grabbers quite well it initializes an vbi device although it probably shouldn't. This is likely to the reason for the erreor you get when starting scnatv:

#scantv

vbi: open failed [/dev/vbi]

open /dev/vbi: Device or resource busy

#dmesg

em28xx #0: this driver can be opened only once

This issue has been fixed in the new version of the em28xx driver. If you update the em28xx driver it wont initialize a vbi device any more. However, after update you are likely to get anoher error message after starting scantv:

open /dev/vbi: no such device or directory
obviously scantv refuses to work without a vbi device which is probably a bug?



But as a workaround you could now start kdetv or xaw tv and scan the channels. This will work and you can enter the addtitional imformation for the channels manually.











Technorati Tags: ,



Powered by ScribeFire.

Labels: , , ,

Do you want to read on <<click

Saturday, May 19, 2007 parmanent link to this post

Howto solve PCTV analog USB 2 (150e/55e) tuner issue: can't scan UHF

For me the em28xx detected tuner #37 which is probably wrong cause tuning UHF channels din't work. Here I explain how to solve this problem.

My tuner reads LG tape something so I use #47 for the tuner= insmod option instead. Now I can tune in UHF channels.

For Suse you have to edit /etc/modprobe.d/tv and enter the module options for the em28xx. Look for options and change tuner=37 to tuner=47. Now UHF works fine for me. Heres how my /etc/modprobe.d/tv looks like.

alias char-major-81 videodev
options em28xx card=8 disable_ir=0 tuner=47
alias char-major-81-0 off
alias char-major-81-1 em28xx
alias char-major-81-2 off
alias char-major-81-3 off
wiki discussing the em28xx UHF tuning issue for other cards

In addition I use card=8. Here is a list of valid choices for the card= insmod option:

em28xx #0:     card=0 -&gt; Generic EM2800 video grabber
em28xx #0: card=1 Generic EM2820 video grabber
em28xx #0: card=2 Generic EM2821 video grabber
em28xx #0: card=3 Generic EM2870 video grabber
em28xx #0: card=4 Generic EM2881 video grabber
em28xx #0: card=5 Generic EM2860 video grabber
em28xx #0: card=6 Generic EM2861 video grabber
em28xx #0: card=7 Terratec Cinergy 250 USB
em28xx #0: card=8 Pinnacle PCTV USB 2 (LG PAL TAPC)
em28xx #0: card=9 Hauppauge WinTV USB 2
em28xx #0: card=10 MSI VOX USB 2.0
em28xx #0: card=11 Terratec Cinergy 200 USB
em28xx #0: card=12 Leadtek Winfast USB II
em28xx #0: card=13 Kworld USB2800
em28xx #0: card=14 Pinnacle Dazzle DVC 90
em28xx #0: card=15 Hauppauge WinTV HVR 900
em28xx #0: card=16 Terratec Hybrid XS
em28xx #0: card=17 Terratec Hybrid XS Secam
em28xx #0: card=18 Kworld PVR TV 2800 RF
em28xx #0: card=19 Terratec Prodigy XS
em28xx #0: card=20 Videology 20K14XUSB USB2.0
em28xx #0: card=21 Usbgear VD204v9
em28xx #0: card=22 Terratec Cinergy T XS
em28xx #0: card=23 Pinnacle PCTV DVB-T
em28xx #0: card=24 DNT DA2 Hybrid
em28xx #0: card=25 Pinnacle Hybrid Pro
em28xx #0: card=26 Hercules Smart TV USB 2.0
em28xx #0: card=27 Compro, VideoMate U3
em28xx #0: card=28 KWorld DVB-T 310U
em28xx #0: card=29 SIIG AVTuner-PVR/Prolink PlayTV USB 2.0
em28xx #0: card=30 Terratec Cinergy T XS (MT2060)
em28xx #0: card=31 MSI DigiVox A/D
em28xx #0: card=32 D-Link DUB-T210 TV Tuner
em28xx #0: card=33 Gadmei UTV310
em28xx #0: card=34 Kworld 355 U DVB-T
em28xx #0: card=35 Supercomp USB 2.0 TV
em28xx #0: card=36 Hauppauge WinTV HVR Rev. 1.2
em28xx #0: card=37 Gadmei UTV330
em28xx #0: card=38 V-Gear PocketTV
em28xx #0: card=39 Kworld 350 U DVB-T
em28xx #0: card=40 Terratec Hybrid XS (em2882)
em28xx #0: card=41 Pinnacle Dazzle DVC 100
em28xx #0: card=42 Generic EM2750 video grabber
em28xx #0: card=43 Yakumo MovieMixer
em28xx #0: card=44 Huaqi DLCW-130
em28xx #0: card=45 Generic EM2883 video grabber
em28xx #0: card=46 Hauppauge WinTV HVR 950
em28xx #0: card=47 Pinnacle PCTV HD Pro
em28xx #0: card=48 Pinnacle Hybrid Pro (2)
em28xx #0: card=49 Hauppauge WinTV USB 2 (R2)
em28xx #0: card=50 NetGMBH Cam
em28xx #0: card=51 Leadtek Winfast USB II Deluxe
em28xx #0: card=52 MSI DigiVox A/D II
em28xx #0: card=53 Typhoon DVD Maker
em28xx #0: card=54 Pinnacle PCTV USB 2 (Philips FM1216ME)
Here is a list for valid options for the insmod tuner= option. I use tuner=47

tuner=0 - Temic PAL (4002 FH5)
tuner=1 - Philips PAL_I (FI1246 and compatibles)
tuner=2 - Philips NTSC (FI1236,FM1236 and compatibles)
tuner=3 - Philips (SECAM+PAL_BG) (FI1216MF, FM1216MF, FR1216MF)
tuner=4 - NoTuner
tuner=5 - Philips PAL_BG (FI1216 and compatibles)
tuner=6 - Temic NTSC (4032 FY5)
tuner=7 - Temic PAL_I (4062 FY5)
tuner=8 - Temic NTSC (4036 FY5)
tuner=9 - Alps HSBH1
tuner=10 - Alps TSBE1
tuner=11 - Alps TSBB5
tuner=12 - Alps TSBE5
tuner=13 - Alps TSBC5
tuner=14 - Temic PAL_BG (4006FH5)
tuner=15 - Alps TSCH6
tuner=16 - Temic PAL_DK (4016 FY5)
tuner=17 - Philips NTSC_M (MK2)
tuner=18 - Temic PAL_I (4066 FY5)
tuner=19 - Temic PAL* auto (4006 FN5)
tuner=20 - Temic PAL_BG (4009 FR5) or PAL_I (4069 FR5)
tuner=21 - Temic NTSC (4039 FR5)
tuner=22 - Temic PAL/SECAM multi (4046 FM5)
tuner=23 - Philips PAL_DK (FI1256 and compatibles)
tuner=24 - Philips PAL/SECAM multi (FQ1216ME)
tuner=25 - LG PAL_I+FM (TAPC-I001D)
tuner=26 - LG PAL_I (TAPC-I701D)
tuner=27 - LG NTSC+FM (TPI8NSR01F)
tuner=28 - LG PAL_BG+FM (TPI8PSB01D)
tuner=29 - LG PAL_BG (TPI8PSB11D)
tuner=30 - Temic PAL* auto + FM (4009 FN5)
tuner=31 - SHARP NTSC_JP (2U5JF5540)
tuner=32 - Samsung PAL TCPM9091PD27
tuner=33 - MT20xx universal
tuner=34 - Temic PAL_BG (4106 FH5)
tuner=35 - Temic PAL_DK/SECAM_L (4012 FY5)
tuner=36 - Temic NTSC (4136 FY5)
tuner=37 - LG PAL (newer TAPC series)
tuner=38 - Philips PAL/SECAM multi (FM1216ME MK3)
tuner=39 - LG NTSC (newer TAPC series)
tuner=40 - HITACHI V7-J180AT
tuner=41 - Philips PAL_MK (FI1216 MK)
tuner=42 - Philips 1236D ATSC/NTSC dual in
tuner=43 - Philips NTSC MK3 (FM1236MK3 or FM1236/F)
tuner=44 - Philips 4 in 1 (ATI TV Wonder Pro/Conexant)
tuner=45 - Microtune 4049 FM5
tuner=46 - Panasonic VP27s/ENGE4324D
tuner=47 - LG NTSC (TAPE series)
tuner=48 - Tenna TNF 8831 BGFF)
tuner=49 - Microtune 4042 FI5 ATSC/NTSC dual in
tuner=50 - TCL 2002N
tuner=51 - Philips PAL/SECAM_D (FM 1256 I-H3)
tuner=52 - Thomson DTT 7610 (ATSC/NTSC)
tuner=53 - Philips FQ1286
tuner=54 - tda8290+75
tuner=55 - TCL 2002MB
tuner=56 - Philips PAL/SECAM multi (FQ1216AME MK4)
tuner=57 - Philips FQ1236A MK4
tuner=58 - Ymec TVision TVF-8531MF/8831MF/8731MF
tuner=59 - Ymec TVision TVF-5533MF
tuner=60 - Thomson DTT 761X (ATSC/NTSC)
tuner=61 - Tena TNF9533-D/IF/TNF9533-B/DF
tuner=62 - Philips TEA5767HN FM Radio
tuner=63 - Philips FMD1216ME MK3 Hybrid Tuner
tuner=64 - LG TDVS-H06xF
tuner=65 - Ymec TVF66T5-B/DFF
tuner=66 - LG TALN series
tuner=67 - Philips TD1316 Hybrid Tuner
tuner=68 - Philips TUV1236D ATSC/NTSC dual in
tuner=69 - Tena TNF 5335 and similar models
tuner=70 - Samsung TCPN 2121P30A
tuner=71 - Xceive xc3028
tuner=72 - Thomson FE6600
tuner=73 - Samsung TCPG 6121P30A
tuner=75 - Philips TEA5761 FM Radio
the original list can be found here:

em28xx tuner insmod option list: I use no 47 for LG TAPE series
Related Posts can be found here


Labels: , , , ,

Do you want to read on <<click

Thursday, May 17, 2007 parmanent link to this post

Solved: nForce4 CK804 (Intel8x0) ALSA audiodriver uses only on two speakers for stereo playback when 5.1 6 channel speakers are connected

I have a 5.1 surround speaker set connected to my K8N ultra SLI mainboard with a CK804 sound on board. When playing MP3 I realized that Linux used only the front speaker for stereo playback, which is pretty annoying since the front speakers are not full range an desperately need the woofer to run for a nice sound. Here I write how I solved this issue.



It turned out that this issue is not a driver issue, however. This is due to a, in my opinion, odd behavior of the ALSA drivers. ALSA feeds the channel from the source to the corresponding speaker. Since you have only to two channels in stereo sound alsa sends only sound to the front (left and right) speaker. Although this behavior is very logical its verry confusing for a easyly confused noob like me and it took me quite a while to fix this problem.

First I had to make sure that the hardware is set up properly. Therefore I used a little helper applet that comes with the ALSA package:

# speaker-test -c 6 -r 48000


Now I heard sound (noise) on all speakers. If you hear something then the driver and ALSA should work.

Getting a driver update from nvidia is not necessary since they only distribute only sata and lan drivers for their nForce chip set. They included their driver sources for their on board sound to the ALSA project so it should be fine to use their driver. The CK804 is supported as as intel8x0. Anyway, here are the sites for the nvidia downloads:

http://www.nvidia.com/object/linux_nforce_1.21.html
http://http.download.nvidia.com/XFree86/nforce/1.0-0310/ReleaseNotes.html

But I did an ALSA driver update. However, this update is optional I guess.

---snip---

To do this you need to install autoconf, kernel-source, gnu make, kernel-headers with yast if not done yet.

To compile and install the latest drivers from source, first download the CVS
(Remark: devfs is depreciated in Suse 10.2 since it uses udev so we don't need to execute ./snddevices script here)

# rsync -avz --delete rsync://alsa.alsa-project.org/hg your_directory
# ./cvscompile --with-cards=intel8x0 --with-sequencer=yes
# make install
# modprobe snd-intel8x0;modprobe snd-pcm-oss;modprobe snd-mixer-oss;modprobe snd-seq-oss
---snip----

The most important step is to edit the .asoundrc. The .asoundrc is a configuration file which is read in by default and lives in your home directory.

# vi /home/xxx/.asoundrc
vi is an editor but you can use whichever you you prfer to perorm this task. xxx denotes the name of your home directory. Then add the the following code to your .asoundrc :

pcm.ch51dup {
type route
slave.pcm surround51
slave.channels 6
ttable.0.0 1
ttable.1.1 1
ttable.0.2 1
ttable.1.3 1
ttable.0.4 0.5
ttable.1.4 0.5
ttable.0.5 0.5
ttable.1.5 0.5
}


This will duplicate stereo channels to the sourround speakers but you have to use ch51dup as device for output of stereo files. In Amarok I use the configuration shown in the screenshot:

I used the following links as source:


Technorati Tags: , , , , , ,

Labels: , , , , , , ,

Do you want to read on <<click

Tuesday, May 15, 2007 parmanent link to this post

Installing MythTV on OpenSuse Linux 10.2 64 Bit w/ USB 2.0

Myth TV is a Media Center for Linux software. It fetches an electronic programm Guide for you, schedules recordings, seraches your favorite soaps in the electronic programm guide (EPG) and records them for you so you nerver miss a thing. In addition you can load a lot of modules for DVD CD Phosto Mp3 playback and stuff. Pretty neat.

I use MythTV 0.2 and kernel 2.6.18.8-0.3-default SMP with openSUSE patches. The em28xx driver needs to be updated though. Don't try MythTV 0.19 that won't work with the PCTV usb2. probably none of the em28xx devices will work with versions prior to 0.2.

Mythbackend is the server application of MythTV. it controles the TV grabber starts stop the recording and stores media data and stores and the Electronic Program Guide (EPG). All this data is stored in the MySQL database. The forntend is the client application. Its a remotecontrol for the backend. The backend will start stop recordings, swich channels on request of the frontend and stream the movie data to the frontend which will display it to you. The frontend also queries the MySQL datbase for EPG data, I guess. Here I write how I installed MythTV for OpenSuse 10.2

A precompiled *.rpm is provided by Packman

The Packman MythTV rpm v0.2 won't work with SuseLinux 10.2 with PCTV analog USB2 out of the box since the em28xx (driver for the 150e/55e) of OpenSuse 10.2 is outdated. You have to compile you own em28xx V4l2 from sources

follow the MythTV installation instructions for OpenSuse outlined here:

OpenSuse MythTV wiki

or here:

Installing MythTV


Some additional Notes:

Enter as root
# rcmysql start
(issue # chkconfig --level 35 mysql on
when mysql wount start at boot though enabled in the runleveleditor of Yast2 )
then initialize the database:
(Without mysql running mythtv-setup says it cant connect to the mysql server)

# mysql -u root < /usr/share/doc/packages/mythtv/database/mc.sql
List of packqges and dependencys is not complete in the Howto. You have to install xml-grabbers package!!!! this package contains the XML grabbers you need for the EPG channel list!!!! without you get tv_grab_de_tvtoday no such file or directory (or whichever the name of you grabber is)
you'll need to Alt + tab to the console and answer the questions of the grabber. It will ask you which Channels it should fetch for you. only check those channels you'll really need e.g which are available in your Cable netl.
You have to create directory where you want to save your digitally recorded tv programmes and make it world readable/writable before you start the mythtv-setup. you need to specifiy that directory during mythtv-setup. e.g.
# mkdir /home/video
# chmod a+rwx /home/video


start the setup from a console so you can see error messages on the console output!!!!
# mythtv-setup


The grabber is a pice of software which rips the Programm Guide from some website and outputs it in XML (extendable markup language, a flexible file format that mythtv can read)
during setup Mythtv will invoke the grabber
tv_grab_de_tvtoday --configure


This will only configure the grabber. Here you select wich Channels you want to grab from the electronic programm guide from the internet. Configuration will be saved to file
~/.xmltv/tv_grab_de_tvtoday.conf
here you can edit the file in case you made mistakes,
use as root
# rcmythtvbackend start

to start the mythtv backend
After the end of mythtv-setup you can do a
# mythfilldatabase --manual

to enter the frequency channel information for the respective station.
The
--manual
directive triggers an interactive mode where you can provide some information. MythTV needs to know to which channel it has to set the tuner of you tv Grabber (ur PCTV analog USB) if you want to watch a certen Broadcasting station. I will ask you on which channel it can find a Broadcasting station. The unique identifieer of the EPG data is the XMLTV.ID Thus MythTV needs to which XMLTV.ID is found on which channel. In additiont you can enter a lot of other informative stuff like long name and short name of the broadcasting station.
do the mythfilldatabase only for one day with the
--manual
directive else you have to go through all channel by for each day and grabbing takes forever (may be hours +).

use
# mythfilldatabase --update
to grab the following days instead. Once the channels are defined thy will be imported by mythfilldatabase automatically.

Mythfilldatabase takes forever. For me if was faster to run the grabber first for 1 dayThen improt EPG from *.xml file using:
# tv_grab_de_tvtoday --list-channels --output channels.xml
# mythfilldatabase --manual --preset --file 1 -1 channels.xml

have a channels list ready to assaign each station a channel from the channel freequncy list.
you can find this out by using mplayer
start mplayer from the console
mplayer -tv driver=v4l2:device=/dev/video0:amode=1:input=0:norm=PAL:adevice=/dev/dsp1:immediatemode=0:audiorate=48000:fps=30   tv://

and swich channels with h and k. this will require theat the PCTV USB is /dev/video0 and the audio device of the PCTV usb is /dev/dsp1. In the console (STD OUT) mplayer will print the current channel and you can see at the same time what si goin on.
Kdetv can also do a channal scan and you have to add the names manually. the em2820 of the PCTV USB2 150e/55e does not support Teletext/vbi. So dont bother.
then grab the rest
# tv_grab_de_tvtoday  --slow --output EPG.xml
and import
# mythfilldatabase -file 1 -1 EPG.xml --update
the 1 denotes the input source. If its not the first input source you want to grab then adjust this number accordingly -1 is ths offset which imports everything up to 7 day in advance from now on.
When lucky you can now start frontend to watch tv and do recordings and stuff.
to debug start frontend and backend from a console. 
the em28xx and V4l2 drivers which come with OpenSUSE 10.2 are outdated. They don't work for PCTV USB 2 PCTV analog USB2 150e/55e and MythTV
if you start the backend and start live TV you'll get a black screen and get a :

StartRecorder() -- timed out waiting for recorder to start


on the console you started the backend from.

Compile the recent stable version of em28xx

see here: em2880 wiki about mythtv

and here

repository ot the em28xx

you dont need to add any fimware to the source for analog devices like the 150e/55e. Firmware is only needed for digital devices.

To download the sources of the em28xx you will need a special programm which mnages sources. This is called mercurial (check if package is installed). It manages so called mercurial sources.

This is a package wich manages sources of large decentralized projects. It will download the sources you'll need and und update your sources automatically
enter:
You need to install kernel sources and kernel headlins before you can compile the em28xx driver
# hg clone http://mcentral.de/hg/~mrec/v4l-dvb-kernel
# cd v4l-dvb-kernel
# make
# make ./install

now reboot

after reboot MythTV should work.

Note. Kdetv also works only after driver update;)
link that download from v4linux domain is outdated ... can show up on old wiki or forum entries

some useful links:

forum
troubleshooting

Technorati Tags: , , , , ,

Labels: , , , , ,

Do you want to read on <<click

Sunday, May 13, 2007 parmanent link to this post

Azureus lives!


Azureus is a great torrent tool with a little blue frog as a mascot in the logo. I diden't now that those blue frogs really existed in the wild until recently. The frog is named dendrobates azureus and carries the color azureus in its scientific name.

Labels:

Do you want to read on <<click

Testing the SLI mode in Linux


If you have installed the Nvidia Drivers for Linux you want to know if the SLI mode is running. To do this you can enable the SLI Heads-Up-Display options Nvidia X Sever Settings GUI which can be installed by Yast. To do this start the utility select "OpenGL settings and check "enable sli heads up dispaly"

Now Select "X Server Display Configuration" and click on "Save to X Configuration File".

Now start an Application that should use SLI and on the left an HUD marked SLI should appear.

this should show you the overhead of you GPU but here you see no GPU load becaus the applicatiion does not put much strain on such a setup, however if you run DOOM3 or Quak4 which can both be installed on Linux you will the green bars filling up the white lines.

Labels: , , , , ,

Do you want to read on <<click

Install Nvidia 6800GS Grafics cards in SLI mode for OpenSuse

When I first installed OpenSuse on my System it didn't set up my graphics card properly. I use a Gigabyte K8N Ultra SLI with a Nforce4 Chipset with two 6800GS in SLI mode.
Here I wrie what I've done to get my Grafic cards running. This might be also helpful for others who want to use a NVIDIA driver.
To activate the SLI mode you first have to enable the SLI mode on your mainboard by putting the SLI selector card firmly into place. Some people complain that their SLI mode doesent work and the secoind GPU is not recognised although both are installed into the Mainboard. This happens because without the SLI selector module properly in place the mainboard falls back into normal mode and thus the second PCIe_16 slot with the second SLI device is not available. In addition the SLI cards should be connected using a SLI adaptor for optimal performance.

However the setup of the GPU by Yast/Sax was not succesful so a grafical login was not possible after installation. However, It was possible to fix the Xorg.conf written by Yast using the nvidia Confugration utitlity.

First you'll have to leave the XServer using CTRL + Alt + F2 since display is messy and you can't use it. The reason is probably that Yast/Sax is configuring an Xserver on each GPU with one display for each Xserver which doesent work for me. Switch to the text console. If this fails you have to boot in debug mode with GRUB or LILO in the boot menu. For the next steps you can use the text based yast utility to do the installations.

To enable SLI mode you have to install the Closed Source Nvidia driver for OpenSuse.

Download the 64Bit Nvidia Linux Driver for the 6800GS and follow the installation instructions for Suse.

In the README they tell you to use the Sax utility to configure the Xorg.conf but this doesen't work for SLI devices I guess.

Install the nvidia-xconfig utility using Yast. This can do the modification to the /etc/X11/xorg.conf for you. Type in a root console

# nvidia-xconfig --only-one-x-screen --no-twinview --logo --sli=auto

This configures the xorg.conf to use only one display and to turn on SLI whenever posiible.

If you followed the readme of Nvidia (shutting down Xserver with Init 3 and unloading grafic driver moduls with modprobe -r then adding the repository and instlling the rpm for Suse with yast) you should now be able to start the X server with

# X

or

# Init 5

Labels: , , , , , ,

Do you want to read on <<click

Saturday, May 12, 2007 parmanent link to this post

ScribeFire and : A FireFox plugin for Bloggers. Probably the best bloggin solution for Linux Users

I was interested in finding a blogging tool for Linux.

I checked the tools which came with the OpenSuse distro. Namely:

  • Gnome blog poster

  • kBlog
Whereas both are extremely basic Kblog has the advantage of integrating in the KDE (kicker) task bar which enables your to blog right from your desktop I missed a lot of features I like.
I heard of Flok which is a supposed to be a nice blogging tool but actually is a webbrowser on its own based on the Firefox engine.

Firefox? Hm, maybe there is a plug in which can do the same, so I don't need to install another browser. So I started to look for a blogging plug in for firefox. And then I found one: ScribeFire.

This is a pretty good bloggin tool. It supports technorati tags, del.icio.us bookmarking. track back URL and blogger categories. Scribfire Plugin can bet toggeld using the F8 key. So you can copy and past your Blogpost while surfing.

However, the support of categories is incomplete yet, since it doesn't lists the categories you have used up to now. this would be a nice feature though.

It also posts the pictures from you desktop to blogger for you. However, it tells you that blogger does not support upload of pictures via API. . For now you have to fall back to the URL method as a blogger user i guess. (publish as dreaft first and upload the picture using the HTML interface upload of blogger.

Since it is a Firfox plugin you can use the Firefox build in spell check which is good !

Another nice tool I found is the clipmarks plugin. With this tool you can use the clipmark webservice to clip a pice of a website and insert it directly to your blog as a citation and then add a comment. This is handy when you want to blog any online material.

Labels: , , , , ,

Do you want to read on <<click

Yet another quick search hack for Firefox

Finally a good way to search databases on Firefox. Although this firefox quick search plug in is really nice, however it gets a bit bulky from time to time. You need to nave a search plugin for each datablase and you need to activate it from the dropdown menu. That tends to be a little time consuming. This hack is great since you just need to enter an Keyword for you database and your search phrase. This is much quicker and more flexible when you want to search different databases than choosing it from the dropdown bar and you don't need a plugin
clipped from www.mozilla.org


Visit the page that has the search field that you search with. Right click on
the search field. Choose Add a Keyword for this Search...
The Add Bookmark dialog will appear. Give the bookmark a name, e.g.
"IMDB Search" and create a keyword e.g. "imdb" and file the Bookmark somewhere.
Firefox comes with a Quick Searches folder so you could use that. Click OK

Now enter imdb Matchstick Men into the Location bar and press
Enter.

 blog it
Do you want to read on <<click

Wednesday, May 09, 2007 parmanent link to this post

Linux compared to Windoze, a personal experience

Now That I use OpenSuse for a while I want to summarize what the advantages and disadvantages between OpenSuse and Windows are.

For the moment it boils down to these major points:

  1. Installation of OS: Linux might sometimes a bit more difficult

  2. Availability of drivers and setup of Hardware: Many manufacturers support only Windows (So choose your Hardware carefully :D)

  3. Availability- and Setup of Software: That depends on your needs.

  4. For server and network applications: Linux rules

  5. Productivity: Media player and Open Office should be fine for most users

  6. Security: Linux rules

Well, Installation: Basic insstallation is easy in the first place. Yast does pretty good job in detecting the hardware, repartitioning the hard drive to set up a dual boot system and configuring the hardware. However, for me installation went not completely smooth. I took a little hacking before eveything worked properly. Here write why I think Linux can be used by anyone and why I think its better than Windows as far as the above points are concerned.

A major issue was the set up of the graphics adapter. I'm using an odd SLI setup with two Nvidia 6800GS cards. Sax/Yast2 did detected my setup correctly but apperently were not prepared to write a working Xorg.conf. Since the grafical log in was configured automatically I could see nothing on my display at all after starting my mashine the first time. It took me quite a while to fix that problem.

Another major problem for Linux users arises from the fact that the manufacturers usualy do not provide drivers for Linux. Development of the drivers relays on the Open Source community in large parts. This usually causes a delay in availability of drivers and as a result can cause troubles during setup. (See e.g. bcm43xx, PCTV USB 2). Setup of my hardware for Windoze was easier in some instances, since all drivers were easy to set up by a GUI.

Some linux users say, well Linux is not Winodoze and Linux is not supposed to do everything for the user because its Open Source. Yet, in my opinion, Open Source and usability do not exclude each other. Automatic installation routines are helpful for the unexperienced and easily confused user and therefore should be further developed to include those users into the open source community. For the experienced user the existence of automatic installation tools (Yast and the like) usually doesn't mean a loss of freedom, flexibility or control since he still free to configure everything by hand, if he wishes.

However, you get a lot of help from the Linux community with this hacking stuff and if you are willing to Google around a little I'm confident that you can find a fix for almost any problem you have. I myself like this hacking a lot, so I have no problems with it.

Next thing is the installation and set up of the Software. As long as there is a binary available for your distro, the installation is no problem and I think it can't get any easier than this. The KDE desktop looks great and comes with a lot of goodies. To be honest with you, I like the KDE GUI much more the the Windows GUI. I would say its superior. If I think of the Beryl window manager for Linux (its beta but works great for me) I would say it far far far ahead of windows. If you havent seen it, that's well worth a try.

Thunderbird, Firefox, DigiCam and OpenOffice work out of the box. And I think the average Joe won't need much more than this in 99% of the cases. So I would say a preconfigured Linux system which circumvents the installation hassle might be a good choice for some users since it saves you the buck for your copy of Windoze.

However, things might look different in rare cases where you desire a software for which no binaries for your distro available and you have to do the installation by hand or compile the sources yourself. This is usually no problem with the right HowTo, though you have to spent more time on it. Only on rare occasions these installations things will cause you some headache and in the case of (installation of AntiVir) i head to do alot of reading.

I think some of these problems arise because there actually is no such thing as Linux. Instead there are so and so many Kernel versions, so and so many library versions and distributions that make it rather impossible for an manufacturer to provide the user with all rpm or binaries. In this respect the high flexibility of Linux might be a disadvantage.

The Availability of software is a difficult question. I guess If you insist on using Microsoft Office, Linx apparently is not the right choice for you. Also a lot of comercial software is not ported to Linux. However, depending on your demands there is an Open Source alternative for virtually any application you might think of. In addition, you get a lot of hight quality software you don't need to pay for which would cost you a fortune if you had to buy it for windows. I'm thinking of the great video processing software, the top notch server applications and the like. Thus, as far as applications are concerned, with Linux you might get not exactly what you are used to but may be you get much more than you are used to in the end.

A major issue of Windoze is security. The malware constantly targeting your Windoze machine is a nightmare. Linux comes with a firewall which is much mor powerful than the Windoze firewall, and what is more there is almost no malware targeting Linux. Moreover, theres is usually no chance for malware to execute commands with root privileges. This is in contrast to Windoze, where pretty much everything is executed as root. Windoze is a constant threat to your privacy cause you don't know which kind of data it sends back to Redmond during online updates (and who knows, may be Mr Gates opend some backdors in his Windoze on request of the NSA so they can spy on you .... Warning: joke :D)

In many respects Linux is far ahead of Windoze. The Linux 64Bit version is around for years now, whereas Windoze only begins to support 64Bit architecture. Windoze only recently implemented a Firewall whereas Firewalls are second nature to Linux for ages. The Beryl Winwos manager is for Linux is just great and there is nothing comparable for windows I would know of (correct me if you wihch). There are probalbly a lot of more examples to continue.

In conclusion I definitely think that Linux is the better operating system which gives more freedom and flexibility by far. In addition you get extremely powerful applications for free. However, Linux is not supported by a lot of software- and hardware manufacturers. Of course this is not a problem of Linux itself but might make life a little more difficult every now and then. Depending on your Hardware and Sofware requirements Linux might not be the right choice. Though, I believe that for the average user who is doing some Internet surfing, graphics processing. letter writing, multi media playing .... Linux can satisfy all his needs for a much better price and with more security.

So why not give it a try and get a copy of OpenSuse or any other distro you like and put it in your DVD drive. Linux will install a dual boot system for you on its own most likely without any trouble, so you can play around a little. Its no big deal any more.




Labels: , ,

Do you want to read on <<click