[ Prev ][ Table of Contents ][ Front Page ][ Talkback ][ FAQ ][ Next ]
...making Linux just a little more fun!
More 2¢ Tips!
By The Readers of Linux Gazette

See also: The Answer Gang's Knowledge Base and the LG Search Engine

make in future? I'm confused *now*

Tue, 28 Jan 2003 00:35:59 -0600
Mike Orr (Linux Gazette Editor)
Question by Subramanian Varadarajan (hi_subri from hotmail.com)


I am subbu and I encounterd this problem when i ran

make - filename.

How to fix this problem?Can you help me.

make: *** Warning: File `makefile.machine' has modification time in
the future (2003-01-28 07:07:00 > 2003-01-28 00:09:19)
make: Nothing to be done for `all'.
make: warning:  Clock skew detected.  Your build may be incomplete.

I guess that my real-time clock has set incorrectly. how to correct it.

I appreciate your time.


Ugly HTML had to be beaten up and reformatted. Please send messages to The Answer Gang in text format. -- Heather
[Mike] The message means what it says: 'make' found a file that "was" modified in the future. That may or may not be a problem, and if it is, it may or may not be significant. Do you know by other means whether 'makefile.machine' should have been updated? I.e., did you modify any file related to it?
How did that file get on your machine in the first place? Did you copy or untar it from another computer in a way that would have preserved the foreign timestamp? If so, then the clock on the other computer may be wrong.
To check your own computer's clock, see the 'date' and 'hwclock' commands. 'date' shows and sets Linux's time; 'hwclock' shows and sets the real-time clock. First set Linux's time correctly, then use 'hwclock --utc --systohc' to reset the hardware clock.
If your hardware clock is pretty unreliable (as many are), you can use 'hwclock --adjust' periodically (see "man hwclock"), run ntp or chrony to synchronize your time with an Internet time server, or put the kernel in "eleven-minute mode" where it resets the hardware clock every eleven minutes. (Answer Gang, how do you activate eleven-minute mode anyway?)
[Ben] In the "hwclock" man page:
This mode (we'll call it "11 minute mode") is off until something turns it on. The ntp daemon xntpd is one thing that turns it on. You can turn it off by running anything, including hwclock --hctosys, that sets the System Time the oldfashioned way.
Also, see the "kernel" option under "man ntpd".

H/W detection in Debian ?

Sun, 02 Feb 2003 02:49:05 +0000
Jimmy O'Regan (jimregan from dol.ie)
In reference to: Issue87, help wanted #1 -- Heather

You could try installing libdetect, and then running /usr/sbin/detect (detect is also used by Mandrake). Aside from that, the only thing I can suggest is filing bugs with Debian.

ppp over nullmodem cable - Linux client, win2k RAS server

Sun, 02 Feb 2003 03:13:36 +0000
Jimmy O'Regan (jimregan from dol.ie)
In reference to: Issue87, help wanted #2 -- Heather

The problem is the authentication on the Win2K side. Check out http://msdn.microsoft.com/library/default.asp?url=/library/en-us/apcguide/htm/appdevisv_8.asp Basically, since I assume the RAS server is running etc, you just need to enter this command on NT:

netsh ras set authmode NODCC

Last month Linux Magazine (UK - http://www.linux-magazine.com/issue/26/index_html) ran an article on setting up Direct Cable Connections with NT. I'll send on the details when I find where I left the magazine. You may try searching http://linux-magazin.de since Linux Magazine is a translated version of that.


This page may also be of use.

kernels? make your own!

Thu, 6 Feb 2003 02:08:18 -0800 (PST)
j l (cs25x from yahoo.com)
In reference to: Issue87, help wanted #1 -- Heather

Solution: stop using redhat, debian, mandrake kernels, download a fresh kernel from kernel.org and build with that.

The other answer, is to look in you Makefile, and check the line beginning with "EXTRAVERSION=" If you add your own name to that line, and run make, you brand the kernel and modules with that name. Hope that fixes your problem.

"Sean Shannon" <sean@dolphins.org>
Tue, 4 Feb 2003 10:48:20 -0500

The hardest part in compiling a kernel is making the ".config" file. Some things to check:

  1. modify the Makefile changing EXTRA VERSION variable (looks like you did this since the 2.4.18custom directory is made)
  2. make sure when you configure ( I use make menuconfig) that you select "enable module support"
  3. make sure to run "make dep" after "make menuconfig"

[Thomas Adams] Yep -- good idea.

  1. Are you sure that "make modules" and "make bzImage" completed successfully?

[Thomas Adams]
Well, I usually do something like:
alias beep='echo -e "\a"'

make modules && for i in $(seq 10); do beep; done &&
make bzImage && for i in $(seq 10); do beep; done

  1. here is the install procedure I use (System.map is a symbolic link, RedHat 7.0, I use raid 1 disk device /dev/md0, you'll probably use /dev/hda )

[Thomas Adams] or /dev/sda if s/he has a SCSI

To install the new kernel:

Copy the new kernel and system map to the “boot” directory

cp  /usr/src/linux/arch/i386/boot/bzImage   /boot/vmlinuz-2.2.16-22-custom
cp  /usr/src/linux/System.map  /boot/System.map-2.2.16-22-custom

Edit file: “/etc/lilo.conf”. Add a new “image” section (add everything below )

See attached customkernel.lilo.conf.txt

[Thomas Adams] Often called a "stanza". Be careful though. I'd be more inclined to "label" this as "linux-test" so that it doesn't infringe on the "old" version of the kernel. Remember that up until this point, you're still testing (a trial run) the new kernel.

Activate the change as of next re-boot


Install new System.map

rm  /boot/System.map
ln -s  /boot/System.map-2.2.16-22-custom  /boot/System.map

Reboot the system to build module.dep file

shutdown -r now
[Thomas Adams] Hmmm, deprecated. "Init 6" is a better way.

Reboot the system after the login prompt appears Enter “alt-ctrl-del” key combination

Reboot performed because modules.dep is created on first boot (if not, try running the "depmod" command manually then reboot)

[Thomas Adam] Not necessary. "depmod" is ran through all of the init levels on a modern Linux system......

Good luck. Sean Shannon

[Jim Dennis] Most of this can be automated down to just two lines:
make menuconfig
make clean dep bzImage modules modules_install install
... note the list of multiple targets all on one line. Make install will look for an executable (usually a shell script) named /sbin/installkernel (or even ~/bin/installkernel) and call that with a set of arguments as documented in ... (/usr/src/linux) arch/i386/boot/install.sh
Here's a relevant excerpt:
# Copyright (C) 1995 by Linus Torvalds
# Adapted from code in arch/i386/boot/Makefile by H. Peter Anvin
# "make install" script for i386 architecture
# Arguments:
#   $1 - kernel version
#   $2 - kernel image file
#   $3 - kernel map file
#   $4 - default install path (blank if root directory)
# User may have a custom install script

if [ -x ~/bin/installkernel ]; then exec ~/bin/installkernel "$@"; fi
if [ -x /sbin/installkernel ]; then exec /sbin/installkernel "$@"; fi
So this can put the approprite files into the appropriate places and run /sbin/lilo or whatever is necessary on your system.
I like to copy .config into /boot/config-$KERNELVERSION Also, in my case the script as to mount -o remount,rw /boot since I normally keep /boot mounted in read-only mode. The script remounts it back to ro mode after running /sbin/lilo.
For new kernels you can save some time in menuconfig by preceding that make with:
 	cp /boot/config-$RECENTKERNELVERSION ./.config.old
	make oldconfig
... which will set all the new config options to match any corresponding settings in the old config. Then you can focus on the new stuff in menuconfig.
Another useful tweak for some people is to edit ... (/usr/src/linux) .../scripts/Menuconfig and find the single_menu_mode variable:
# Change this to TRUE if you prefer all kernel options listed
# in a single menu rather than the standard menu hierarchy.
... for those that don't like to have to expend extra keystrokes popping in and out of subsections of the menuconfig dialogs.
Sadly this particular featuer as changed (at least by 2.5.59) with the inclusion of a new kconfig system (instead of menuconfig).
You can get a collapsible try of menu options in the new system using: make menuconfig MENUCONFIG=single_menu (However, it it starts with all branches collapsed. <grump!> ;)

Ipchains vs. Iptables

Fri, 14 Feb 2003 11:06:01 +0100
De Groote, Patrick (Patrick.DeGroote from NETnet.be)
In reference to: Issue87, help wanted #6 -- Heather

if you use ipchains, then you should look at masquerading and port-forwarding.

following command

ipmasqadm portfw -a -P tcp -L $4 4662 -R 4662

should do the trick.

rgds Patrick De Groote

Bruce Ferrell <bferrell@baywinds.org>
Sat, 22 Feb 2003 17:30:34 -0800

if you're using ipchains you need something like this:

/usr/sbin/ipmasqadm portfw -a -P tcp -L <EXTERNAL ADDRESS> 11900 -R <INTERNAL ADDRESS> 11900
The point is, whether you use a variable or hardwire in an address, you need to specify both sides of the forwarding connection. Also note that the two examples selected a different port to play on, but the principle is the same. I hope that leaving both examples in makes it all clearer to readers. -- Heather

Jim Kielman <jimk@midbc.com>
05 Feb 2003 23:30:27 -0800

I ran into a similar problem with a client that had to have PCAnywhere access to one of the computers on his network. My solution was to use "ipmasqadm portfw" to forward the ports PCAnywhere needed to access. The server is running Debian potato with a stock 2.2.20 kernel. Here is what I use:

ipmasqadm portfw -a -P tcp -L <internet IP> 4162 -R <mldonkey IP> 4162
ipmasqadm portfw -a -P udp -L <internet IP> 4162 -R <mldonkey IP> 4162
ipmasqadm portfw -a -P tcp -L <internet IP> 4161 -R <mldonkey IP> 4161
ipmasqadm portfw -a -P udp -L <internet IP> 4161 -R <mldonkey IP> 4161

internet IP = the IP address of the computer connected to the internet.

mldonkey IP = the IP address of the computer running mldonkey.

I don't know if you need both udp and tcp, but it works for me. Hope this helps.

Jim Kielman

a new language

Mon, 10 Feb 2003 00:16:49 -0800
Rick Moen (the LG Answer Gang)
In reference to: Issue 86, 2c Tips #3 -- Heather

John Karns:

Cool - thnks for the pointer. I think I'll check it out. I knew that some IDE's exist for Linux, but never really took the time to look at one.

Why look at only one when you can look at over a hundred?

Note we're pointing to his gathered list of numerous "integrated development ennvironments" - the previous entry pointed to his description answering that (1) yes we have them, lots and lots; and (2) that if you think you're seeking one, you should make sure you are solving the right problem first. -- Heather

Key Remapping....

Thu, 30 Jan 2003 13:37:20 -0800
Mike Orr (Linux Gazette Editor)
Question by James Scott (jscott from sangoma.com)

Is it possible to remap the <tab> key to another key on the keyboard?? One of my co-workers has a broken left pinky and is going insane not being able to use the tab key to complete commands.

I done a fair amount of searching to no avail... any help would be greatly appreciated.

[Mike] Grr, I just read yesterday about somebody turning Scroll Lock into another Escape key, now where was it...?
You can remap any key using the "loadkeys", "showkey" (singular) and "dumpkeys" commands. That's on the console. You have to do additional steps for X. See the Keyboard and Console HOWTO

Thanks for the quick reply. Helps a lot.


Palm magic

Sun, 2 Feb 2003 10:21:46 +0100
Ben Okopnik (the LG Answer Gang)
Question by Huibert Alblas (huibert_alblas from web.de)

I was desperatly trying to use my palm with the evolution mailer, recompiled everything but the kitchen sink to get Gnome2 and Gnome1.4 capplets and applets totlaly mixed up in the end, it was working, but gnome was broken, so now I'm repairing Gnome2, and then try to write the apropriate spells for my Paml connetion

Halb uses the Sorceror distro, which refers to compiling its scripts and packages as "casting spells". -- Heather
[Ben] I've found the "appropriate spells" for the Palm - for my M-125 with the USB cable, at least - to be "jpilot" and "coldsync". "jpilot" is really well done, except for the selection interface in the "Install" menu (select a file, click "Add". Select next file, click "Add". And so on for, say, 50 files.) "coldsync" works at a lower level - it's great for reinitializing user info, a quick install with or without synching, and generally tweaking Palm comms. As an example, among the files that I carry on the Palm, I have The Moby Shakespeare collection (all of The Bard in one file) and Gibbon's "Decline and Fall of the Roman Empire", volumes 1-6; both rather large (~5MB). "jpilot" refused to load them (segfaulted). So did my brother's Wind*ws Palm desktop. "coldsync", however, when used with the "slow sync" option, managed it just fine. KDE's palm app, though, is severely broken (to its credit, it mentions that in the initial screens); it hosed my Palm so hard that I had to do a hard reset, and re-init the user (another thing that "jpilot" couldn't handle.)

Yes, well thanks for the info, Jpilot and stuff works like a charm (Palm M105 the small one), but I wanted to Sync my mailadresses in evolution........ wich is based upon gnome 1.4 (c)applets, which are horible to get to play nice with the Gonme2.0 install.

Good to know about the big files though...

Initial thoughts on ratpoison

Mon, 24 Feb 2003 09:40:55 -0700
Jason Creighton (androflux from softhome.net)

For those of you who don't know, ratpoison is a light (very light) window manager. (http://ratpoison.sourceforge.net). The basic scheme is to have all apps fullscreen, using screen-like key bindings to switch between windows. I've been using it for about an hour or so now (Hint: Look at the sample.ratpoisonrc in the doc directory. Don't end up hacking the source code to change the prefix key like I did.), and I'm liking it. The best thing, of course, is the tons of screen real estate you get without any window title bars, borders, etc.

If you like doing everything with the keyboard or you want tons of screen real estates, give ratpoison a whirl.

Also see this article on freshmeat: http://freshmeat.net/articles/view/581

rc.local in debian

Sun, 9 Feb 2003 15:42:07 +0530
Rick Moen (the LG Answer Gang)
Question by Joydeep Bakshi (joy12 from vsnl.net)

If you aren't using RHL, simply edit /etc/rc.d/rc.local


but there is no such file in debian . what file should I edit in debian ?

thanks in advanced.

The Linux Oracle has pondered your question deeply.
And in response, thus spake the Oracle:
echo '#!/bin/sh' > /etc/rc.local
chmod 744 /etc/rc.local
RL=`grep ':initdefault:' /etc/inittab | cut -d: -f2`
echo "LO:$RL:once:/etc/rc.local" >> /etc/inittab
killall -HUP init
You owe the Oracle a better understanding of why subverting the SysVInit architecture is fundamentally a bad idea in the first place.

recording sounds on linux for windows

Wed, 19 Feb 2003 02:19:49 +0800
Huibert Alblas (huibert_alblas from web.de)
Question by 50258246 (50258246 from student.cityu.edu.hk)

Hi!i'm rayho, i would like to ask how to receive sound from the microphone and then transmit the sound from the linux os to the window os system.Also,I'm not understand where the sound source is stored in which file in the linux os and what hardware and software do i need to do this transmition.Thankyou for your help!!

[Halb] Hi there,
This may sound a bit simple but I would do it like this:
needed Hardware:
needed software:
On the other hand, you might not want to transport single files, but want to do some kind of Internet audio broadcasting or something. You might want to look into
What did you have in mind?

Secure Password Authorization - NTCR ?

Fri, 14 Feb 2003 01:18:41 +0000
Jimmy O'Regan (jimregan from dol.ie)
Question by Neil Belsky (ursine90 from msn.com)

Neil Belsky wrote:

Were you ever able to solve this problem?

NTCR is another name for NTLM, which is supported by fetchmail.

Fwd: Terminating Misbehaving Programs

Wed, 12 Feb 2003 22:48:50 -0800 (PST)
Raj Shekhar (lunatech3007 from yahoo.com)

I receieved this tip for inclusion in my HOWTO


However as it a bit advanced for a newbie's howto I did not include it. i am forwarding it to you.


[C.R. Bryan III] Subject: Doing Things in GNU/Linux
Good stuff :) Something I can put on a firewall machine when I put it onsite (since I leave Apache in for a status.cgi page anyway)
In the section "Terminating Misbehaving Programs":
If the afflicted machine is on a network with another Linux machine, or a Windows machine with PuTTY, there are additional steps that can be taken before hitting the Big Red Two-by-Four switch. (My network runs RHL 6.2 on older boxes, old as in P133, so I get practice in this every time Netscape walks into a Java site and freezes.)
  1. Shell into the afflicted machine. Use ssh if you've got it, telnet otherwise. If VNC is installed at both ends, maybe you can use that. Just because the local desktop is frozen doesn't always mean that all desktop functioning is frozen. If the machine won't log you in, obviously it's game-over, so at that point you have to reset the box. Often, though, especially on older boxen, it's just X that's either frozen or in a really deep thrashing session, and you can get a shell prompt. Root-to-root ssh is most convenient.
  2. Get root on the afflicted box with su.
  3. Try to kill off just the program that's freezing things, and try to do it nicely.
    a. If you can get X apps to forward, or you can get a VNC window open, you can bring up kpm (the KDE process manager), which, with all the information presented, allows you to pinpoint just the app to kill with a right-click. Try several times to get it to go away, starting with Hangup, then Terminate, then Kill. The more of a chance you give the program to clean up its exit, the less garbage you'll leave lying around in the system.
    b. If you know the name of the program that has gotten hung, and only one instance of it is running, use killall. Let's assume for example that it's netscape:
    # killall -HUP netscape
    # killall -TERM netscape
    # killall -KILL netscape

    Killall does just that, kills off every instance of a program that it finds. That's appropriate for netscape, since it has a session-manager core which is usually the part that's locked up. If you've got a dozen xterms open, and ytree running in half of them, though, killing off every ytree might not be what you want; often, it's the helper-app that ytree launched that's frozen up (lynx, for instance) and you can killall that.
    c. Use top and other shell tools to zero in on which process to kill, then use kill. (Here I don't have that much experience: when I need to use top and kill, it's on a firewall without X, where all the running processes fit in an xterm/ssh window, so it's simple to fish out the pid to kill.)
  4. If it won't kill, or you can't figure out who to kill, or things just seem hosed at the X level, as long as you can get root on a shell command-line, you can tell it:
    # init 3;init 5
    ...and that'll do what ctrl-alt-bs would do, restart X to a graphic login. Your underlying filesystem will have cores and DEADJOEs left lying around from the X-level programs that had to abort, but you won't have to fsck everything on a dirty boot.
  5. If you think you might have stuck ports and locks from the killed X-level processes, and the machine doesn't have duties that would prevent it, or if X won't come back up, you can do a clean reboot to put things back in order, probably in less time than it'd take to find and free the stuck resources...
    # shutdown -r now
    That'll take down the X level, giving the X programs a chance to clean up after themselves, then the rest of the machine, and your filesystem will be unmounted and rebooted cleanly.
Bottom line: if you can shell or VNC into the frozen machine, there are things you can do to avoid losing data in the innocent processes you're running in X or corrupting your filesystem. You can even do some of these things from Windows if you have the right tools (telnet, ssh, PuTTY, VNC), as long as you have two or more machines on the same network.
How much of this you think might be appropriate to a newbie-help, I don't know, but that's my experience, anyway :)

Two sound cards

Wed, 5 Feb 2003 11:52:43 +0100
Dean Buhrmann (d.buhrmann from chello.nl)
In reference to: Issue 87, 2c Tips #1 -- Heather


Great how you tackled this problem. I have a simple Sounblaster 16 card. This card (with this chipset) appeared to be multichannel.

I play online games on the internet (Tribes2) and we use for communication a voice communication program (Teamspeak2). I also want to hear the sound of the game. Teamspeak2 is able to use a different channel (dsp0/dsp1).

So i adress the gamesound to dev/dsp1 and the voice communication to /dev/dsp0. I couldn't get it working with alsa drivers, but others with different soundcards can. So i used the OSS driver. It works great with only one soundcard.

If a program only wants to adress the default /dev/dsp (dsp0) and you want to let it use /dev/dsp1 you can change the link /dev/dsp --> /dev/dsp1

More information on http://www.teamspeak.org

Linux is a very stable platform for games and there is now a (free) voicecommunication program too.

This page edited and maintained by the Editors of Linux Gazette
HTML script maintained by Heather Stern of Starshine Technical Services, http://www.starshine.org/
Copyright © 2003
Copying license http://www.linuxgazette.net/copying.html
Published in Issue 88 of Linux Gazette, March 2003

[ Prev ][ Table of Contents ][ Front Page ][ Talkback ][ FAQ ][ Next ]