Translation(s): English - Italiano

(!) ?Discussion


Miscellaneous questions

How do I set the date and time?

There are several factors involved in how Debian keeps track of time. There's the hardware clock, the system clock, and time zones.

The hardware clock is either kept in UTC or in local time. If you're dual-booting with another OS, it's best to leave the hardware clock in local time. If you need to change this, edit /etc/default/rcS.

Next, you should set your time zone with the dpkg-reconfigure tzdata (Lenny) or tzconfig (Etch) commands.

Set the system clock with ntpdate(8) or date(1) or rdate(8). If you choose ntpdate, then you'll need to specify an NTP server. If you don't have one already (e.g. a local router that feeds NTP to your LAN) then use pool.ntp.org.

Finally, save the system clock to the hardware clock with hwclock --systohc.

How do I set the locale? I want errors in my native language.

dpkg-reconfigure locales (or install the locales package if you haven't already). The system-wide default locale is set in /etc/environment. You can override it in your personal dot-files.

How do I run commands at boot time?

At least 80% of the people reading this are trying to get hdparm(8) to run at boot time. Stop. Do not do this. If your disk drive isn't getting DMA mode enabled at boot time by your kernel, then you either have a misconfigured kernel, or your hardware is not capable of running DMA safely. (Perhaps your disk drive is even dying!) If you built a custom kernel, check to make sure that you enabled all of the DMA options, including "use DMA by default when possible". If you're using a Debian kernel, check the options in the /boot/config-$(uname -r) file; if you don't see the DMA options turned on there, get a newer kernel image. Also see the next question.

For the rest of you....

Read /etc/init.d/README and update-rc.d(8). Also note that run levels 2 to 5 are all identical in a default Debian installation. You are allowed to customize them for your own needs.

How do I stop services starting at boot time?

update-rc.d -f hdparm remove

This works until the next time you update the system.

update-rc.d hdparm stop 00 5 .

This will stop the next update from recreating the links by added stop links in runlevel 5. By default you boot to runlevel 2.

How do I check whether DMA is enabled on my IDE device?

apt-get install hdparm
hdparm /dev/hda

Replace hda with hdb, hdc or hdd as needed for whichever device you are checking. You can also look for the appropriate lines in dmesg(1).

How do I make MySQL listen on a port?

Edit /etc/mysql/my.cnf and comment out the skip-networking option. Then, restart MySQL:

/etc/init.d/mysql restart

If you wish to have it only listen on localhost, add

bind-address = 127.0.0.1

to the [mysqld] section of /etc/mysql/my.cnf.

What is the name of the debian font used in the logos?

Poppl Laudatio Condensed

How can I collect a list of all broken links?

apt-get install symlinks

How can I set num lock always on?

setleds(1) for console, numlockx (a separate Debian package) for X.

Where can I disable the ctrl+alt+backspace keys to kill the xserver?

Put Option "DontZap" "true" into the ServerFlags section of /etc/X11/XF86Config{-4} 

Ansi color codes don't work with less?

Yes they do, use less -r the.ans. This will translate all kind of control chars but has the disadvantage that less stops being able to track the cursor position properly, thus forcing you to press ctrl-l all the time (really annoying). This does not happen when you use less -R, but then it won't be able to translate all control characters.

How do I check the root file system for errors?

You can't fsck the root FS while the system is running, but you can force an fsck to occur at the next boot, thus:

touch /forcefsck

How do I get udev and 2.6 to work on my unstable machine?

I've put a brief paragraph on DevFAQ about this. Take a look if you're not getting a login prompt after installing udev on a 2.6 box.

How do I get Java applets to work under Mozilla?

First you try following the FAQ.

Then you might try this other FAQ.

The first problem is that in version 1.6-5 of the mozilla-browser package, at least, /usr/bin/mozilla is a shell script that directs errors to /dev/null. This is bug 178271.

To deal with this, make a copy of /usr/bin/mozilla and edit out the redirects of file descriptor 2 to /dev/null. Run the copy.

You may see something like this on Mozilla's standard error when it starts:

LoadPlugin: failed to initialize shared library /usr/lib/j2se/1.3/jre/plugin/i386/mozilla/javaplugin_oji.so [/usr/lib/j2se/1.3/jre/plugin/i386/mozilla/javaplugin_oji.so: undefined symbol: __vt_17nsGetServiceByCID]

This symptom indicates that your Java was compiled with an old version of gcc (2.95), but your Mozilla was compiled with a new version (typically 3.2), and the two are binary incompatible. This is the case for version 1.3.1.02b-2 of the j2re1.3 package from ftp.tux.org, at least.

If you're confronted with this symptom, the fix is to get a Java runtime that was compiled with a more recent gcc. There are several available; one is http://www.tux.org/pub/java/JDK-1.4.2/i386/rc1/j2re-1.4.2-rc1-linux-i586-gcc3.2.bin. Install that and change the libjavaplugin_oji.so link to point into the newly installed Java runtime.

If you wish to confirm the diagnosis before attempting the above treatment, you can do it as follows. Confirm that your Java was compiled with the old gcc by giving the command

and getting the result

To confirm that your mozilla was compiled with the new gcc, you can find its version of the symbol by giving the command

and you'll see a line like

Then you demangle that with the command

and get this eminently reasonable output:

The important thing is that the two calls to c++filt both succeeded but they were told to use different demangling rules, "gnu" for the first and "gnu-v3" for the second. If this all checks out, then you should fetch a newer Java runtime as described above.

An alternative to installing the upstream Java packages directly is to build a Debian policy-compliant Java .deb file using the mpkg-j2se package (sarge and later). You'll still need to know which upstream Java package to download, though. (Sarge uses the gcc 3.3 ABI for all of its packages including mozilla, so follow the directions above to make sure you get a gcc 3.3 Java package.)

How do I let users read my Windows file systems?

VFAT and NTFS file systems are not Unix file systems, so they don't have owners, groups, or standard Unix permissions. Therefore, when one of these is mounted, the kernel arbitrarily assigns a specific UID (user) and GID (group) as the owner of all the files in the file system. It also assigns a permissions mask (umask) which defines the access permissions that will appear on the files and directories in the file system.

When you mount a VFAT or NTFS file system in Debian, it has a default umask that disables reading and writing for normal users. If you want everyone to have read access to the file system, you should use a umask of 022 instead (which corresponds to permissions of 755, or rwxr-xr-x). You can also control which UID and GID are used as the "owner".

You do this by adding options in the fstab(5) file. For example:

/dev/partition /mount/point vfat defaults,uid=USERID,gid=GROUPID,umask=022 0 0