Home|Cudeso|Linux|*NIX / BSD|Misc|
 

Tweaky Misc

This page is a summary of hints and tricks that I have used to configure my GNU/Linux-machines. Some of these may be useful, some may not, some could screw up your machine!

Kernel-config

1. unterminated call to function `wildcard': missing `)'

RedHat-specific

1. lstat() of directory /var/cache/man/X11R6/cat? failed

Misc

1. Search files with specified content

2. Adjust system-date

3. Configure doesn't accept new values

4. Clock skew detected

5. Install zlib-from source

6. Use wheelmouse with X

7. Mount iso-images like ordinary drives

8. SSH Key-gen

9. Export X-display to another host

10. Convert ext2 filesystem to ext3

11. SSH not available as root (host key verification failed)

User Applications

1. Install plug-ins for Mozilla

2. Mytharchive only creating small iso files (cdrom)



1. unterminated call to function `wildcard': missing `)'

Sometimes when you've interrupted the compilation of a new kernel (for whatever reason) it's impossible to restart the 'make' process. Even  make clean  won't work. You can solve this (at least...it worked for me) by removing the file  /usr/src/linux/.hdepend 

1. lstat() of directory /var/cache/man/X11R6/cat? failed

After the latest upgrades from the manpages I was receiving this error (resulating from the cron.daily/tmpwatch script) :
error: lstat() of directory /var/cache/man/X11R6/cat? failed: No such file or directory
This is easily fixed by creating the missing directory with
mkdir -p /var/cache/man/X11R6/cat

1. Search files with specified content

It's possible to search for specified content in several files. One remark, this works (obvious) only for plain-text files.
find . -name '*.txt' | xargs grep -l findthisthing
This will search in the current directory for all files with extension *.txt for the string findthisthing.

2. Adjust system-date

Changing the system date is very easy.
date MMDDhhmm
Where MM is the month, DD is the day, hh are the hours and mm are the minutes.

3. Configure doesn't accept new values

Sometimes when you run configure with different settings you will notice that it seems that your settings are not reflected in the configure script. By removing the file config.cache before running the configure script you're certain that you always use the latest settings.

4. Clock skew detected

This message can pop up when you try to build something from source. The problem here is the fact thay your software-clock is not in sync with the hardware clock. Try adjusting both of them with date and hwclock

5. Install zlib-from source

When you try to install the new zlib from source on a machine where there's already a zlib installed from RPM you can fail! Standard configure, make, make install doesn't work. When you read the Makefile you'll notice a line that says that you need to run ./configure -s for shared libraries. When you use this option, it will install fine.

6. Use wheelmouse with X

When you want to use your precious wheel mouse with X-applications (for example with KDE) you can configure it in /etc/X11/XF86Config-4. Just look for the section InputDevice and there for the setting Option "protocol". When you're using a PS/2-mouse, you can replace the existing protocol ("PS/2") with ImPS/2. Restart your X-server and you should be ready to go.

7. Mount iso-images like ordinary drives

Tired of burning countless iso-images that you've never used again? There's a way you can easily mount the iso-images just like an ordinary cd-rom. Become root and create your mount-point. Then issue
mount -o loop,unhide -t iso9660 -r myiso.iso /path/to/mountpoint

8. SSH Key-gen

Enter ssh-key-gen -t dsa.

Upload the pub-file to the other host and place it in .ssh.

9. Export X-display to another host

First of all, you need to remove the .Xauthority files in your home-directory. I'm not sure why but when I used it, my login just stalled after accepting the password. Removing these files (both at the local computer and remote computer) solved the problem.
Next, on your local computer, start the X-server with
xinit
Now, in the X-terminal window start your ssh-connection to the remote host. Make sure X-forwarding is enabled on both remote (sshd_config) and local (ssh_config) side.
Once you're logged in you can start all kinds of applications, even startkde should work.

10. Convert ext2 filesystem to ext3

Make sure your kernel supports ext3!!
First, create the journal with
tune2fs -j /dev/hdxx
After the conversion, adjust the file /etc/fstab so that it mounts with ext3.

11. SSH not available as root (host key verification failed)

Sometimes it is not possible to start SSH-sessions as a 'regular' user. The root-user doesn't have this problem. You can solve this by adding your regular user to the 'tty'-group.

1. Install plug-ins for Mozilla

When you arrive on a webpage that needs a special plug-in, chances are high that Mozilla will offer you to download the Netscape plugin. When the plugin is correctly written, it will install itself in both Netscape and Mozilla. Unfortunately, sometimes this is NOT true. For example the Real Audio Player plugin only appears in Netscape. To use this plugin with Mozilla, you need to place a symbolic link in the Mozilla-library to the plugin library of Netscape. Do this with :

 ln -s /usr/lib/netscape/plugins/rpnp.so

This works in the same manner for all other plugins.

2. Mytharchive only creating small iso files (cdrom)

After a recent upgrade on ffmpeg the '-b' setting changed from accepting kilobytes to bytes. As a result whenever I tried to create ISO files from my recording I had files that where varying in size between 450 and 550 MB. Clearly not a DVD-style ISO. This can be changed by altering the file /usr/share/mythtv/mytharchive/encoder_profiles/ffmpeg_dvd_pal.xml and setting the correct (*1024) values for the -b parameter.
Copyleft 2002-2007 - cudeso.bewebmaster@cudeso.betop