Klaus Knopper answers your Linux questions

Ask Klaus!


Klaus Knopper is the creator of Knoppix and co-founder of LinuxTag expo. He currently works as a teacher, programmer, and consultant. If you have a configuration problem, or if you just want to learn more about how Linux works, send your questions to: klaus@linux-magazine.com

DVD Install Error

Question:

Klaus: I was in Books-A-Million and saw your magazine. I loved it and read it cover to cover. I have an older computer and wanted to install Fedora 12 on it. Your magazine had a DVD, and I thought how easy it would be. The DVD won't install Fedora 12 on my computer. I keep getting an error message: Exiting Pxe rom, Pxe -e-53: No boot file name received. Did I do something wrong? Please help explain this to me. Thanks, Charles.

P.S., I am a student learning about the fun world of Linux.

Answer:

PXE means "Preboot Execution Environment," which is commonly used when computers are set up to boot over a network, instead of booting from local media such as hard disks or DVD. Apparently, your computer's BIOS has been set to try starting from the network first. If no boot server is present, or you are not even connected to a network, you get various "PXE" error messages like the one you mentioned.

Usually, the BIOS will then continue to check for hard disks and other bootable media, as set in the Boot Priority section in the BIOS setup. Some computers are also preset to try to boot from CD or DVD; for others, you have to enable this setting manually. Some older computer models, however, cannot boot from CD or DVD at all. So, there can be several reasons for the failure to boot from DVD:

  1. The computer simply can't. You might have to use an intermediate boot menu floppy disk or a boot record on hard disk to activate the DVD drive for booting.
  1. The computer can, but is not configured to do this. Please set the boot sequence in the BIOS to DVD/CDROM (sometimes called ATAPI) as first boot device.
  1. The computer is capable of booting from DVD, and the BIOS is set correctly, yet bootable DVDs are not recognized. In this case, the DVD-R or DVD+R media used for burning the ISO could be defective or incompatible with the DVD drive. However, this is seldom the case for DVDs that are delivered in magazines.

If the DVD does not boot, you will probably get a No operating system found message, or the computer will continue trying to boot from hard disk.

Some computers have a special hot key that you can press during the initial boot phase to select the boot medium without changing the default boot priority order. Keys often used for this feature are F12, F8, or Esc. The Knoppix DVD greets you with a 16-color graphical bootscreen and displays a short help message when you press F2 or F3 in the initial bootscreen. If you got that far, BIOS settings should be OK.

Switched Out

Question:

Hi Klaus: Some months ago, I wrote to you about changing the resolution on my PC. You very kindly gave a detailed reply, which I attempted to implement without success because I omitted a very relevant piece of information in my original question to you. I have since (through trial and error) discovered the root cause of my problem and would like to share it with you - I hope it will be a handy addition to your extensive knowledge base because it is (I think) a fairly rare occurrence.

The reason I couldn't get the correct resolution on my monitor is because I had two PCs connected to one keyboard, monitor, and mouse via a KVM switch. Apparently, the presence of the KVM switch impedes the detection of the monitor's optimum resolution, and a default setting is used. Best regards, Andre Duvenhage

Answer:

Thanks for adding that important detail. Indeed, when using a KVM switch, the feedback signal from the monitor telling Xorg which resolution(s) to use can be blocked; thus, the Xorg server won't detect and use the "best" (or "just working") settings. As a fallback, "common" frequencies are tried, although a manual setting might be required. For this, xrandr (the extension that queries and changes resolution and position settings on the fly) might have to be disabled or given a hint which resolutions to try. This is the /etc/X11/xorg.conf section for a manual set up (Xorg 7.4, 7.5). The frequencies and timings are those xrandr reported when the monitor was connected directly without the KVM switch in between:

Section "Monitor"
        Identifier "VGA"
        HorizSync 28.0 - 50.0
        VertRefresh 50.0 - 60.0
        Modeline "1280x768" 76.80 1280 1328 1440 1600 768 769 772 800 -hsync -vsync
        Modeline "1360x768" 84.75 1360 1432 1568 1776 768 771 781 798 -hsync +vsync
        Option "PreferredMode" "1280x786"
EndSection

The option "PreferredMode" tells Xorg which "favorite" resolution the monitor wants, and it will select the corresponding Modeline once the mode is also found in the Modes option line in the "Screen" section of /etc/X11/xorg.conf:

Section "Screen"
        Identifier "Screen0"
        Device     "Card0"
        Monitor    "VGA"
        DefaultDepth 16

        SubSection "Display"
              Depth     1 6
        Modes "1360x768" "1280x768"
        EndSubSection
EndSection

This method transfers the old (Xorg 7.3 and earlier) method without xrandr to newer Xorg versions. Note that in this setup, it is still possible to switch resolutions on the fly, except when using the legacy nv (Nvidia) drivers that don't support xrandr.

Windows Bluff

Question:

Hi Klaus: The company I work for only allows Windows machines to log in to the company network remotely. Is there a way to make a Linux machine report it is a Windows machine? The software the company runs checks your machine to see if it is a Windows machine and does not let any others through the web console. Thomas R Owskey

Answer:

Software can do a few things to find out which operating system is running on a networked client, including complicated things like network package sequence numbers or port scans of known services. Your "web console" application is probably checking the "User Agent" field of an HTTP request, which means that the application running on the web server checks your browser's signature for known strings.

The typical "Microsoft OS"-style browsers return something like

"Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1)"

whereas Linux-based browsers might report this to the web server:

"Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.8) Gecko/20100729 Iceweasel/3.6.7 (like Firefox/3.6.7)"

If the server-side application just checks for the presence of "Windows" or "Linux" in the user agent identification, this is a very weak and insecure check, but it will probably work in most cases of "default settings" in the operating system's default browser.

If this is how the web-based authentication server distinguishes between Windows- and Linux-based access, just trick the server by sending the "allowed" operating system's browser signature.

For Firefox, the "advanced" method does not require additional software, whereas the "comfortable" method requires installation of another plugin.

Advanced: Go to the Firefox internal settings editor by entering the URL about:config and set the filter line to useragent. The variable to look for is general.useragent.override (see Figure 1). If it is not displayed, you can create it by selecting a new variable of type string with the right mouse button. The value you set will become the identifier reported to the web server.

Figure 1: Setting the general.useragent.override variable.

If you enter "Windows"-like identification for Internet Explorer, as shown above, the web server will think your Firefox is actually Internet Explorer. The web server might display a different web content for this or allow you access to Windows-specific content. Also, you can set the value to arbitrary strings or to an empty value to hide your browser type - something like "Knopper's Browser". After I did this, my home proxy server reported Firefox as Knopper's Browser in useragent.log. (Webalizer on the web server will even add this "new" browser to its statistic if browser types are evaluated in the Apache web server's log.)

Comfortable: Install the User Agent Switcher add-on for Firefox [1], which adds an abbreviation for setting the general.useragent.override variable with an easy-to-use submenu in the Tools menu and already contains a few preconfigured and well-known browser signatures (Figure 2).

Figure 2: Setting the general.useragent.override variable with the Tools menu.

If your web-based company network login still finds out somehow that you are NOT using Windows, you might need to run some Windows-typical servers on your Linux box, like Samba for network and Windows domain bindings.

Speeding Up mutt

Question:

I'm using the "mutt" mail client to access my mailbox located on a Unix/Linux-based server via IMAP remotely, but my network connection is slow and my mailbox grows huge over time (currently about 10,000 in my inbox). Waiting for mutt to display the mail header index is tiresome. Is there a way to tell mutt to display only new mail via IMAP and keep a list of the old ones?

Answer:

If you're using mutt as your IMAP client, your .muttrc will contain something similar to this already:

set spoolfile=imap://username@mailserver-address/INBOX
set imap_user=username

Hint: If you have SSH access, you can use a tunnel command in mutt to use SSH as a secure transport layer with SSH public key authentication to avoid clear-text passwords.

set tunnel="ssh -x -q -C -t username@mailserver-address /usr/sbin/dovecot \ --exec-mail imap"

provided that dovecot is installed on the server as a local mail client. If dovecot is running as the mail server, chances are the clients are installed as well. Thus, a tunnel setup will likely work and even provide a better download rate because of ssh -C internal data/text compression.

Now for the real tuning of mutt: mutt versions 1.5.18 and above support two parameters for local mail caches. These have two functions: storing retrieved mail locally, so you don't have to download over and over again once a message has been read, and keeping a cache of mail headers in sync with the remote mail server.

set header_cache=~/.mutt-header_cache
set message_cachedir=~/.mutt-message_cache

Both directories, .mutt-header_cache and .mutt-message_cache, should exist in this example.

Mutt will retrieve headers once again during the next run and then remember which message headers have already been downloaded. On further starts of mutt, only new message headers are retrieved, and old ones are displayed from the local cache. This can be a big improvement in speed for the already very fast mutt terminal-based client.

INFO
[1] User Agent Switcher add-on: http://chrispederick.com/work/user-agent-switcher/