Converting "MPEG" files to ".avi" format

We can convert MPEG files to .avi format using mencoder (the in-built encoder in MPlayer).


#mencoder -o movie.avi -ovc xvid -xvidencopts pass=1 -oac mp3lame [MPEG filename]
#mencoder -o movie.avi -ovc xvid -xvidencopts pass=2:bitrate=1400 -oac mp3lame [MPEG filename]

Converting ".bin/.cue" files to ".iso" format

The utility to do so is "bchunk"

#bchunk [filename.bin] [filename.cue] filename

mkinitrd

In Red Hat kind of Linux this can be used to generate initrd image file to be used at the boot time... I used the following command in Yoper

#mkinitrd /boot/initrd-2.6.9.img 2.6.9


ACPI and Kernel 2.6.9

When Linux Kernel 2.6.9 was released I saw that the ACPI patches I used to apply (ACPI and custom DSDT patch) are already incorporated into the kernel.
There were 2 new MACROs in the [kernel source]/driver/acpi/osl.c
1) ACPI_CUSTOM_DSDT
2) ACPI_CUSTOM_DSDT_FILE

I made a PKGBUILD file for kernel compilation under Arch linux and compiled the kernel. But while setting the kenel parameters these options were not available. I compiled kernel 3 times with different options but these above mentioned options were not at all available.

I booted in Yoper and read the kernel code, Kconfig files and some scripts to find that these options will only be visible depending on some other options selection or non-selection. The culprit was STANDALONE macro which I had set under general driver options heading.

Afre de-selecting STANDALONE option, I was able to set
ACPI_CUSTOM_DSDT=y
ACPI_CUSTOM_DSDT_FILE=my-dsdt.hex

good lesson on kernel configuration files. phew!

Arch Linux

Sometime back I was going through www.distrowatch.com and searching internet to see if there is another distro which is as fast as Yoper or even faster than Yoper. As I was looking for some binary package system distro, Gentoo was not on the list.
After some search I found this gem. It is called Arch Linux. It is an i686 optimized distribution and according to Arch's home page
Arch Linux is an i686-optimized Linux distribution targeted at competent Linux users (read: not afraid of the commandline)
I read some reviews and most of them were positive about the performance. Though there were some points to be noted,
1) Arch has its on proprietary binary package format, so installing packages from other distros is not an option.
2) Arch is not meant to be "out of the box" distro unlike Yoper. Arch is what you make it.

But both of these problems are not that big, you see. Arch package repository has lots of packages and if you don't find something there, Arch has a port system similar to FreeBSD ports, therefore you can build your own optimized binary package from the source.
For second point mentioned above, ya, you have to put sometime in making Arch what you want but when you are done, you get a low-fat high-performance Linux distro with FreeBSD simplicity (specially the init scripts setup).

So, for last sometime I am experimenting with Arch, reading documents, wiki and forum. I am enjoying it.

As I am still making Arch what I want it to be, I keep changing it a lot now and then......

Yoper stays as primary desktop.

Ubuntu Linux

From Ubuntu Homepage:

"Ubuntu" is an ancient African word, meaning "humanity to others". The Ubuntu Linux distribution brings the spirit of Ubuntu to the software world.

I was reading a lot about this new distribution of Linux lately (on various sites including Slashdot). I found many people praising it.

It is a debian based distro with a 6 month release cycle. It has Gnome (2.8 at present) as its Desktop Environment. It actually didn't sound bad, so I thought of giving it a try.

Downloaded the installation CD and started. The installation program is text based GUI and is designed to for a straight forward installation.

But I did not opt for installing the boot-loader (I already have one) and then it gave me hard time (harder than FreeBSD and all others) to set it up properly. It might not be Ubuntu's problem because it is designed for enterprise workstations in mind and I was trying a strange installation setup (3 OS already residing in the same disk).

Well, after the setup, I logged to into a nice clean Gnome desktop with a very beautiful (or shall I say smooth) "Human" theme.

It is good as it is debian basically. Points to be noted are specially designed professional look, disabled root account (all system administration is done by "sudo" commands). I tried to install something from Ubuntu repository but it was not available showing the fact that Ubuntu repository is pretty small but good thing is (as it is debian basically :-) most of the debian packages work.

I think Ubuntu is very nice and if I had a faster computer I would have loved to use it but on the hardware I have it is slow for all my day-to-day work.


Yoper (Linux) stays as primary desktop.

FreeBSD

I read about freeBSD a lot lastly. Many people had praised it.
Read their documentation, and found the idea impressive.

My primary Desktop is Yoper and more or less I am happy with its performance, but I feel the network speed is slow when I do apt-get update etc. (this might just be my feeling or yoper servers might be slow)

FreeBSD is famous for network performance, so I thought I should give it a try.

Downloaded bleeding edge version at present (5.3-beta6) and started the installation. Installation is straight forward if anybody who is installing for the first time spares some time to read the BSD disk-layout and partitioning information. It is little different than Linux.

While installing you have to give freeBSD a "Primary" partition with enough free space. freeBSD calls it a "slice". Then inside this "slice" freeBSD makes room for mount points /, var, tmp, usr and swap.

The / (root) mount point is called "a". So in first IDE disk in third primary partition (slice), freeBSD / will be : ad0s3a

If partitioning is understood rest of the installation is easy.

I faced some problems in writing to the disk, so I chose the safe-mode for booting the installation disk.

I found freeBSD very good. It is fast, responsive and very robust.
feeBSD gives you 2 options for adding packages
  1. Binary (pre-compiled) packages :pkg_add "package-name"
  2. Source compilation using ports: cd "port-directory";make install;make clean
I tried both methods. Everything went clean without a single error. All dependencies were resolved automatically. As I said, robust.

Now I wanted to do some configuration to suit my taste and problem started. I know Linux methods which are more or less are the same on all the Linux distros, but freeBSD is totally different OS.

I like freeBSD very much and wanted to make it my default desktop but as somebody said in a forum once "freeBSD is a nice system, but the benefit you get for migrating from Linux to freeBSD are worth the effort of learning a totally new system only if you have lots of free time".

:-( I don't have that much free time at present.

Yoper (Linux) stays as primary desktop.

Quake on Linux

I always wanted to play Quake(2,3) on Linux. I like that game. I even bought a windows version of that game when I used to use windows earlier.

On, Yoper, DRI is working, so next obivious thing for me was to install quake(2, or 3). As I do not have that Windows quake2 game cd with me, I decided to install demo version of the game.

I downloaded quake2 demo, installed it and it complained about "default.cfg".

I thought when I just have to install a demo, why not try quake3 demo.

As I am totally new in Linux gaming. I started with a quake3 RPM package. Some rpm did not install because of unmet dependencies, while others were installed but gave some error starting. I think same "default.cfg" error. I was because I did not have pk0.pk3 file.

Then I searched some more and downloaded "linuxq3ademo-1.11-6.x86.gz.sh" which is 40+MB installation file for quake3 demo. After downloading the file, when I tried to run it, "Checksum Error".
UPDATE: check this post. He has something interesting to say aboout "checksum error"


I downloaded again(and again) from different servers (http://www.3dgamers.com/games/quake3arena/, http://www.bluesnews.com/files/idstuff/quake3/linux/linuxq3ademo.shtml etc.) using several download methods (ftp, http, wget, Kget ....), but all the files gave same error. I still wonder if all the linux demo available on the net for quake3 are corrupted files!!!

When I was just about to give up.
I thought of downloading windows version and running it with wine and guess what it worked :-)
Finding windows version of quake3 on the net was very easy. The command I used were as follows
#apt-get update
#apt-get install wine
#wine q3ademo.exe

wow Q3 installation started!!!!
After installation, to run quake3

#wine quake3


It works fine, without a flicker. Happy gaming.

"Thank-you"

Thank you
Alex (agd5f_NOSPAM@SPAMFREE_yahoo (d.o.t.) com)
and
Michaƫl (mgourlain_NOSPAM@SPAMFREE_carillion (d.o.t.) cica.fr)

for helping me out of libGL linking trap of glxinfo and glxgears...

# glxinfo
name of display: :0.0
display: :0 screen: 0
direct rendering: Yes
.......


# glxgears
1522 frames in 5.0 seconds = 304.400 FPS
1877 frames in 5.0 seconds = 375.400 FPS
1878 frames in 5.0 seconds = 375.600 FPS
1875 frames in 5.0 seconds = 375.000 FPS
1848 frames in 5.0 seconds = 369.600 FPS
1845 frames in 5.0 seconds = 369.000 FPS
......

its so nice to see things working.

gotta go. have to play some games ;)

Setting up ACPI (with Custom DSDT) on Yoper

As I mentioned earlier, the default Yoper desktop is good enough but I had to setup ACPI because I need to compile custom DSDT specific to my laptop (custom DSDT creation method is described in detail at www.azeemarif.co.nr).

I could install kernel source from Yoper web-site, but I had saved the kernel source from my debian box. It is because, on debian box kernel source I had already applied
1) acpi patch (http://acpi.sourceforge.net/download.html)
This patch provides proper acpi support in kernel
2) acpi custom patch (http://www.behnel.de/acpi/acpi-custom-DSDT.patch)
This patch enables you to provide your custom DSDT table (see www.azeemarif.co.nr)

Also had already copied the DSDT hex file prepared by me for my laptop (Sens S830).

After copying that kernel source to /usr/src, I started compilation (make bzImage, make modules, make modules_install).

I installed the kernel manually because I am using Grub as boot loader which is not supported properly under Yoper (Yoper's default boot loader is LILO, yet).

Also I installed acpid (apt-get install acpid) from Yoper repositories. But there is no acpi client script on Yoper servers, so I downloaded an i686 RPM for acpi client script using www.rpmfinder.net.

After rebooting with new kernel, everything, yes almost everything stopped working. My network card, sound card, nothing was working.

The reason. Well, it was because I compiled all these things as loadable modules in my kernel while Yoper default kernel comes with everything compiled into kernel. So, there was no entry in /etc/modprobe.conf for loadable modules.

I used generate-modprobe.conf script that comes with new module init tools, to auto-generate modprobe.conf file.
generate-modprobe.conf /etc/modprobe.conf

Rebooted again and things started working fine :-)

Happy ending....

A word about "Yoper"

Yoper!! as claimed by the creator of Yoper, is I suppose, the fastest Linux distro out of the box.
Ok, I have not tried all the distros in the world, so I can not say "The Fastest", but It would not stop me from saying that it is the fastest out of the box among all the distros I have seen.

I have already described very briefly Yoper installation. After installation, you are presented with a fast, real fast, KDE desktop with a custom theme.

First thing you must do is
apt-get update
apt-get upgrade

Gnome does not come pre-installed. If you want to install Gnome, type
apt-get install Ygnome

The kernel I got with Yoper was 2.6.8.1-3. For me, Network (e100 driver) and Sound (ESS maestro3 driver) was already setup.

Sax2 was automatically launched after installation for configuring X. So X was running fine.

So over all, its a very good desktop for a new Linux user. I think a new user will find most of her daily use utilities just some clicks away (and even those clicks are fast :-).

As for me, I wanted to make some changes to suit my laptop, highest priority being enabling ACPI support correctly. Though Yoper has ACPI enabled, my laptop's DSDT is broken. I have correct DSDT (as described at www.azeemarif.co.nr) but to incorporate this corrected DSDT in the system I have to compile the kernel again.


DRI installation file in Yoper does not work

in install.sh file set

DRV_NAME = savage
DRV_MODULE = savage
DRV_ARCH = i686

UPDATE:
You need not change install script if you uncompress

first common tarball
second savage tarball

because savage tarball overwites common tarball and is already perfect.

Yoper Installation

Yoper installer is still very immature. it is text based and above this if you forget to give some option correctly, you have no way to come back and correct the mistake.

I read that Yoper does not support Grub in V2 installer. When it asked me to chose the partition to install boot loader, I just skipped.

Later, when I came to know that Yoper team has added Grub as boot loader (still default is LILO but you have an option to choose Grub as well), I could not come back and select the boot partition.

But what I liked at this moment of installation that Yoper team is very fast in fixing things. The review I read was about Yoper V2, and in Version 2.1 they had already fixed the problems mentioned about the installer in the review (Ok, not all the problems but at least the most visible one).

I realised that installer is not the strongest point of Yoper. Afterall, when you have as nice a Distro as Yoper, who cares what little problem you faced at installation time :-)

Go Yoper.

Swiped debian

I was more or less happy with debian (which was libranet in the beginning). As I upgraded to debian "unstable", I missed something the process and GTAG and anything depending on gkt started crashing.

I knew, I can fix this but I wanted to try Yoper, said to be the fastest distro out of the box (i686 optimized).

./a.out : permission denied

Sometimes, you download source of a utility, decompress it and run
./configure

it returns error

./a.out : permission denied

you try it manually (creating a a.out file and try running it) and face the same problem!!!

might be your partition is mounted with "noexec" option.......... Check it in /etc/fstab

DRI on S3 Savage IX/MX

Finally, after searching the net for months earlier and again this time for information on S3 Savage IX/MX, I'll be able to play games on my Linux box.

Without DRI, it was impossible to play games like tux-racer. The frame rate was too slow. I tried to enable DRI support earlier but could not succeed. I almost lost hope of playing games in Linux on my notebook.

This time I came across this wonderful post at www.linuxquestions.org.
Here people were discussing same problem, i.e. making S3 Savage have DRI support. I followed the instructions in post #40 and things went well without any errors. But still, DRI did not work. I checked the X log (/var/log/XFree86-0) and found the error
(II) SAVAGE(0): 9348 kB of Videoram needed for 3D; 8192 kB ofVideoramavailable


(EE) SAVAGE(0): Insufficient Videoram available for 3D

(EE) SAVAGE(0): Try a lower color depth or smaller desktop




I changed, default color depth to 16bpp and Wow, glxgears shows a frame rate of 160fps (in comparison to 38fps without dir).



During this process, I came across a webpage on DuoView (DuoVue) feature of S3 Savage video card.



I exchanged some mail with the author Alex (who is a wonderful person to reply to all my mails with accurate information) and he helped me to confirm my solution to enable DRI.

Thank you Alex.





ALSA - advanced linux sound architecture

Alsa was not working....

But making ALSA work was easy because I already had my earlier experience listed at www.azeemarif.co.nr

but this time it was easier ... just install correct packages
alsa-base
alsa-utils

and run
#alsaconf

thats it.

Laptop almost burnt (ACPI not working)

Last night I left my notebook open (running debian).... by the morning it was too hot to event touch it.

I checked acpi function and realized that it is not working properly.

It was not a surprise as I had gone through all this before.

All I needed to do was to read my own instructions from www.azeemarif.co.nr


write permissions for mounted ext3 filesystem

In words of an experienced user at Suse forum

> The permissions aren't set to the user when it's mounted, that is
> correct. ext3 stores the user permissions internally. You need to
> change the permissions of the disk when it's mounted, the same way
> you would any other file or directory. So, when the disk is
> mounted, do
>
> chmod 777 /mnt/fwdisk1/
>
> Note that the disk *has* to be mounted when you run this, otherwise
> it won't work

Captive NTFS

wow!

captive ntfs is wonderful. When it works, it works great.

but remember, don't forget to install and configure lufs.

The external usb harddisk's NTFS partition was showing up as /dev/sda5 (/dev/sda2 for whole HDD, I think, and /dev/sda5 for the first partition).

not only captive-ntfs fount all the windows ntfs partitions but also modified /etc/fstab to make them usable.

TODO

Write access to external usb harddisk's NTFS partition : use captive-ntfs (Current Status: Done!)

Enable DRI support for graphics card (S3 Savage, yes, it very old one and is not properly supported) : read instructions at this post
(Current Status: Done!)

Module Init Tools for 2.6 series kernel

How can I forget new module init tools for 2.6 series kernel?!

I, myself, wrote about it on www.azeemarif.co.nr

Custom kernel (Kernel 2.6.8.1) on debian

Remember, on debian, it is better to make a kernel package (make-kpkg --append-to-version kernel_image) and then isntall this newly created package using

dpkg -i

if you forget
(reminder to myself) the procedure goto http://newbiedoc.sourceforge.net/system/kernel-pkg.html

and read it again thoroghly

Desktop running!!!

Wow,

KDE 3.3
Gnome 2.6
Latest IceWm

and kernel 2.6.8.1 (custom-built)

this is great

A thank you note

I am still busy in making my desktop (actually its a laptop) the best linux machine (I have) with all the latest software (and power of debian), but just stooped by to thank people who created package management software in general and apt and supporting utilities in particular.

Hope to come back soon with the good news about my desktop.


Start scripts for session managers

KDE
/usr/bin/startkde or /etc/kde3/debian/startkde

GNOME
/usr/bin/gnome-session

IceWm
/usr/bin/IceWm-session

Modified .xsession by hand

This is I did not want to take a chance, so I modified .xsession for root and another user as follows

KDE
#!/bin/sh

xhost +localhost
exec /etc/kde3/debian/startkde || exec xterm

GNOME
#!/bin/sh

xhost +localhost
exec /usr/bin/gnome-session || exec xterm



SessionTypes in kdmrc can be autogenerated !!!

In /etc/kde3/debian the script kdm-update-menu.sh is used to auto-generate SessionTypes value in kdmrc.

Whether to do it or not is controlled by kdm.options file in the same directory.

SessionTypes in kdmrc

As advised by KDE documentation I checked SessionTypes value in /etc/kde3/kdm/kdmrc.

It was
SessionTypes=default,metacity,gnome-session,failsafe

I made it
SessionTypes=default,kde,metacity,gnome-session,failsafe

(just for testing ;-)

Lets use kdm

Add kdm to init sequence

DareDevil:/# update-rc.d kdm start 99 2 3 4 5 . stop 01 1 6 S .
Adding system startup for /etc/init.d/kdm ...
/etc/rc1.d/K01kdm -> ../init.d/kdm
/etc/rc6.d/K01kdm -> ../init.d/kdm
/etc/rcS.d/K01kdm -> ../init.d/kdm
/etc/rc2.d/S99kdm -> ../init.d/kdm
/etc/rc3.d/S99kdm -> ../init.d/kdm
/etc/rc4.d/S99kdm -> ../init.d/kdm
/etc/rc5.d/S99kdm -> ../init.d/kdm

Meke it default login manager

DareDevil:/etc/X11# pwd
/etc/X11
DareDevil:/etc/X11# vi default-display-manager
/usr/bin/kdm


gdm: error in installation

gdm: error in installation

DareDevil:~# apt-get install gdm
Reading Package Lists... Done
Building Dependency Tree... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.

Since you only requested a single operation it is extremely likely that
the package is simply not installable and a bug report against
that package should be filed.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
gdm: Depends: libbonoboui2-0 (>= 2.4.3) but 2.4.2-1 is to be installed
Depends: librsvg2-2 (>= 2.5.0) but 2.4.0-3 is to be installed
Depends: gksu (>= 1.0.7) but 0.9.14 is to be installed
E: Broken packages

Paying for my mistake

After installing Libranet, I messed up apt-get config and ended up removing almost all the distribution packages (including adminmenu). Well, now I have installed everything latest using apt-get (after correcting the configuration) from debian "unstable" and from "libranet" site and I am struggling to make everything work.