Archive for the 'MySQL5' Category

To access a USB storage device, (Christian web host) plug it

Sunday, February 24th, 2008

To access a USB storage device, plug it in, and Knoppix automatically adds an icon on your desktop for it! However, there s a caveat here. It mounts allfilesystemsas read-only so that you re going to have to change the USB driveto read-write first: 1.Click the terminal with the black screen icon on your panel. A terminal window appears. 2.Type su -to become the root (administrative) user. You re not prompted for a password. 3.Look at the new icon and see what was put in the brackets. For example, [sda1], which is the typical label for a USB drive. 4.Type mount -o remount,rw /mnt/driveto remount the drive asread-write. So, for example, mount -o remount,rw /mnt/sda15.Find where the files are that you want to copy off of your harddrive(s), using the GUI. If you have lots in lots of places, focus on one group for now and comeback and do another later. 6.Look in the Location bar for the folder the files are in. So, for example, if it says file:/mnt/hda1/web, the folder is /mnt/hda1/web. 7.Use the cdcommand to change to this directory in the command lineterminal. For example, cd /mnt/hda1/web8.Type lsto see the directory s contents. There they are! 9.Use the cpcommand to copy the file(s) you want to copy over. Some hints: To copy all files in this directory and all its subdirectories to/dev/sda1, type cp -r * /dev/sda1 To copy all the files in this directory but no subdirectories, type cp* /dev/sda1 To copy all files whose names begin with an a, type cp a* /dev/ sda1 You may want to bundle and compress the files first. In that case, use the program found in the main menu by choosing Utilities.Arkto do so and tell it to create the archive directly on the USB drive, which shows up on your desktop as Hard Disk Partition [sda1] (which refers to /dev/sda1 and /mnt/sda1). 380Part V:The Part of Tens

Sex offenders web site - Chapter 21Ten Cool Uses for KnoppixIn This Chapter

Saturday, February 23rd, 2008

Chapter 21Ten Cool Uses for KnoppixIn This Chapter Rescuing files off a dead machine Testing, testing! Carrying around a portable Linux desktop Installing KnoppixUntil you walk a mile in another man s moccasins you can t imagine thesmell. Robert ByrneLiveCDs are a great way to experiment with Linux in general, or a particu- lar distribution of Linux, because many of them offer a live version fordownload or purchase. Because Knoppix is recommended as the LiveCD touse for pre-installation tasks in this book, I thought I would make sure to giveyou some more fun things you can do with this CD-ROM so that you don t feellike you wasted your time burning it! I won t even do what my husband sug- gested and make one of the ten entries being to use the disk as a frisbee, because I d hate for you to feel cheated out of something truly cool. Rescuing Files off of a Machine that Won t BootOne cool use for Knoppix is to recover the important files that might be left ona messed up computer that otherwise won t boot. You can use Knoppix for thistask whether those files are in Linux or Windows (even on an NTFS partition!). Then you can either e-mail the files to yourself you can find a simple e-mailprogram in the main menu where you choose Internet.KMail or attach aUSB storage device to the machine and copy the data onto it.

If you re (Photo web hosting) working with a multiboot operating system

Saturday, February 23rd, 2008

If you re working with a multiboot operating system environment, besure that your /etc/grub.conffile contains entries for each of youroperating systems. Each operating system or Linux installation needs to be in separate entries. If your file contains entries to switch to a higher-resolution display andyou have boot problems, try reducing the video setting to simple VGA. Linux allows you to use spaces and other characters in filenames that you mayor may not be able to use in filenames on other operating systems. However, some Linux applications may stumble when they encounter file or directorynames containing spaces. Usually, a safe bet is to stick with alphanumericcharacters and avoid spaces and odd characters, such as question marks and exclamation points. Aaargh! I Forgot My Root Password! What Do I Do? Fear not. You have a way around this problem! You need to boot into singleuser mode, which you can accomplish by rebooting your machine and thendoing the following: Fedora:If you see a blue screen with the words Press any key to enterthe menu, press a key. At the GRUB boot screen, press E, which takesyou to a configuration file. Use the arrow keys to go to the line startingwith kernel, and press Eagain to edit that line. At the end of the line, add the word single, press Enter to put the change into place, and thenpress Bto boot the machine. Knoppix:You don t need to because you can just reboot the machineand start over. Linspire and SuSE:See Chapter 21 for how to use Knoppix to recoveryour root password. Even in single user/failsafe mode, you need the rootpassword for these distributions. Mandrake:Reboot the computer and at the boot menu, select theFailsafe option. Xandros:At the Xandros boot screen, select Configure (Expert). Whenyou reach the Give Root Password For Maintenance prompt, enter yourpassword. No matter what distribution you re using, now s your chance to change theroot password to one you can remember. Type passwdand then enter thenew password twice as directed. When you re done, type exitand then bootthe machine normally. 378Part V:The Part of Tens

If you re using a (Web hosting asp) keyboard without a number

Friday, February 22nd, 2008

If you re using a keyboard without a number pad as you will be if you reusing a laptop or your machine isn t set up to be able to change on the fly, you need to change your resolution through your display configuration pro- gram. You can find this option at: Fedora:Choose Applications.System Settings.Display. Knoppix:From the main menu, choose Settings.Control Center. Peripherals.Display. Linspire:From the main menu, choose Settings.Control Panel. Look & Feel.Display. Mandrake:From the main menu, choose System.Configuration. Configure Your Desktop.Peripherals.Display. SuSE:From the main menu, choose Control Center.Peripherals.Display. Xandros:Choose Launch.Control Center.Display.Settings. My GUI Is Hung, and I m Stuck! One quick solution to this problem is the key combination Ctrl+Alt+Backspace. If this doesn t do the trick, your system is in really bad shape! Try to switchto a virtual terminal by using Ctrl+Alt+F5. If this key combination also doesnothing, you need to reboot the machine. Help, My Machine Hangs During Boot! When configuring a Linux machine, you may encounter problems with the/etc/grub.conffile. This file indicates the operating system or systems towhich your system can boot, and the file also contains Linux startup settings. Linux can boot from any of your hard drives not just the master IDE driveon the primary IDE channel. Consider this list of potential solutions if the/etc/grub.conffile makes trouble: If you have altered or added hard drives, you may need to change thebootline in the /etc/grub.conffile. If you haven t made hardware changes, check to make sure that your/etc/grub.conffile is referring to the correct location of the Linuximage. (The program code that loads and executes at runtime and islocated in the /bootdirectory.) If the location under the /bootdirectory or the device for the root entryis incorrect, your system can t boot to Linux. In this situation, a rescueor emergency disk is helpful. Refer to Chapter 5 for instructions on usinga rescue disk. 377Chapter 20: Ten Troubleshooting Tips28_

This line appears near the top (Web server extensions) of the

Thursday, February 21st, 2008

This line appears near the top of the file. What you re interested in hereis the number. In most mainstream Linux distributions, the number 5tells Linux to boot into the GUI, and the number 3tells Linux to bootinto the command line. In the preceding example, therefore, I boot intothe GUI. 5.Change the number in this line. If it s a 5, change it to 3, and vice versa. Make sure that all colons andother items are left properly in place, or else your machine will haveproblems booting later. 6.Save and exit the file. The changes go into effect the next time you reboot the system. If you do end up having problems booting the system, in many current Linuxdistributions (including the one that comes with this book) your installationdisk can be used as an emergency boot disk. Check your documentation forinformation about the distribution you re using if it s not Red Hat 10. Changing your boot environment just for nowAt any time, you can have your Linux box switch between full command-linemode and full GUI mode. The instructions I give here assume that you re usingFedora, Mandrake, or SuSE. (Knoppix, Linspire, and Xandros don t give youthis option.) To switch between modes, do the following: To change from the GUI login to the command-line login, open a terminalwindow and type (as root) init 3. To change from the command line login to the GUI login, type (as root) init 5. I Want to Change Screen Resolutions Do you want or need to swap between resolutions in the GUI on the fly? Sup- pose that you want to use 1,024 x 768, but you work on Web pages and want tobe able to see how they look in a browser at 800 x 600 or even 640 x 480. Yourmachine is very likely already set up to do this, but you just need to know how! If your machine is set up for it, you can change resolutions by pressing thekey combination Ctrl+Alt+Plus, where Plus is the big plus (+) sign on yournumber pad you can t use the plus sign on the main keyboard for this one. 376Part V:The Part of Tens

I Don t Want (Web site developers) to Boot into This! Are

Wednesday, February 20th, 2008

I Don t Want to Boot into This! Are you booting into the command-line environment when you want to useonly the GUI? Or are you finding that you re already booting into the GUI andyou would rather boot to that nice, clean, black-and-white command-linescreen? You re not stuck with either of these options. You can change them at any time. You can press Ctrl-Alt-F# to change out of the GUI to a command line terminalat any time and then Alt-F7 or Alt-F8 to switch back. Changing your boot environment permanently The word permanentlyis in quotes in the heading because you can, of course, go back and change this setting later, if you want. Permanentlyjust refers tothe fact that after you have made this change, every time you boot the system, it automatically goes into the preferred environment until you change it. You can t make this change in Linspire or Xandros unless you want to bootinto single-user mode, which is basically safe mode and not much use. Well, okay, you can, but you would need a techie friend to set up a bunch of stufffor you. Linspire and Xandros assume that you don t want to do this. You can tdo this in Knoppix either, but then it s a Live CD so you won t be doing any- thing permanent to it. To make this change in Fedora, Mandrake, or SuSE, you need to edit what scalled a runlevel. Fortunately, all three of these distributions use the samerunlevel settings, so the instructions are the same for all of them: 1.In the GUI, open a command line terminal. If you re not sure how to do so, see Chapter 14. If you re not in the GUIand you re already logged in, type su -to become the root user. 2.Type cp /etc/inittab /etc/inittab.old to make a backup. Now, if something happens while you re editing the inittabfile, youcan always restart fresh with the old version. 3.Open the inittab file in your preferred text editor. Some Linux text editors are covered in Chapter 16.4.Scroll down until you find a line similar to the following: id:5:initdefault: 375Chapter 20: Ten Troubleshooting Tips28_

If you created only the root account, you (Cedant web hosting)

Wednesday, February 20th, 2008

If you created only the root account, you can log in there as root. After you enter the username and password, you find yourself at the screenshown in Figure 20-2, which just happens to be the second spot where peopleget worried. If you see this screen, you have not only booted properly intoLinux, but you re also logged in and using the machine! Give yourself a goodpat on the back. What do you do from here? Anything you want. Surf through this book forcommands you want to run. Type startxto start up the GUI. If you didn tinstall any GUI (which means you selected a minimal install option with nographical interface, or you actually unselected graphics), you may want toreinstall, or you ll have to add all the tools by hand (which is not a quick job!) Figure 20-2: Logged in at the Linux com- mand line. Figure 20-1: A Linuxcommand- line loginprompt. 374Part V:The Part of Tens

Web hosts - and test again. You can then try setting

Tuesday, February 19th, 2008

and test again. You can then try setting things back the way you want themafter the machine is fully installed and updated, when it hopefully will have afix for whatever the problem might be. The Installer Tested My Graphics Fine, but My GUI Won t Start If your Linux installation program showed you a GUI test screen saying thatyou were ready to proceed with the rest of the installation, you probablyexpected that the GUI would start with no problem. Unfortunately, that doesn t always happen. Each distribution has its own set of graphics configuration tools. If you bootyour machine for the first time and see error messages when you re trying toenter the GUI automatically or when you type startxto start the GUI manu- ally, use the following tools to fix the problem: In Fedora Core, use system-config-display. In Knoppix, you don t install. Use the options available when you boot itin order to tell it specifics about your display. In Linspire, use xf86config. In Mandrake, use drakconfand select the Display option. In SuSE, use sax2. In Xandros, use xf86config. Your last resort is xf86config. This fully text-based tool shouldbe available with most distributions. It may be called xf86config4. I Think I m in Linux, but I Don t Know What to Do! Two different screens tend to cause panic to folks new to Linux. The first ofthese screens, shown in Figure 20-1, is in fact a sign that you installed thesoftware and booted the machine successfully. Jump for joy! It s just thatyou re booting into the command-line environment rather than the GUI envi- ronment. If you reach a screen similar to the one shown in Figure 20-1, thecomputer is asking you to log in with the username for an account and a pass- word that you created during the installation process. 373Chapter 20: Ten Troubleshooting Tips28_

5.Tab to the OK button and press Enter (Email web hosting)

Monday, February 18th, 2008

5.Tab to the OK button and press Enter to proceed to the media examination. This step opens the Media Check dialog box. If you ve changed yourmind and just want to start the installation, use the Tab or arrow keys toselect Skip and then press Enter. 6.If you want to test the first CD-ROM or the DVD-ROM, tab to the Testbutton and press Enter. If you want to test another installation CD-ROM, tab to the Eject CD button and press Enter. If you chose the second option, remove the first CD-ROM from theCD-ROM drive and replace it with the CD-ROM you want to test. Closethe CD-ROM drive and make sure that Test is selected. 7.Press Enter to begin the media check. The Media Check status box opens and shows you the name assigned tothe DVD-ROM or CD-ROM and how much progress has been made. At theend of the inspection, the Media Check Result dialog box opens. 8.Look at the text after and the result is. If the result is PASS, nothing is wrong with the DVD-ROM or CD-ROM itself. Your installation woes are caused by something else. Return to the sec- tion The Linux Installer Froze, earlier in this chapter. If the result is FAIL, the DVD-ROM or CD-ROM you just tested is flawed. If you purchased this CD-ROM or DVD-ROM, you need to talk to the com- pany you purchased it from to see whether you can get a replacement. On the other hand, if you burned your own DVD-ROM or CD-ROM, I rec- ommend doing one of the following: Burn the DVD-ROM or CD-ROM again, at a speed of 4x or lower. Burn the DVD-ROM or CD-ROM again on a newer drive withBurnProof technology (www.burn-proof.com) or something similar. If the DVD-ROM that came with this book is defective, contact the technicalsupport address listed in this book, not Red Hat. However, remember that themedia checking routine does not give you a reliable PASS or FAIL for this par- ticular DVD-ROM. I Told the Installer to Test My Graphics, and They Failed The installer may have misguessed what hardware you have. Double-checkthe settings as best you can. If they look right, try choosing a lower resolu- tion for now and testing again, and if that fails try a lower number of colors372Part V:The Part of Tens

fails in (Web hosting companies) the same place there. If you

Monday, February 18th, 2008

fails in the same place there. If you purchased this disk with a Linux dis- tribution, contact the distribution s technical support team. If you gotthe disk with a book, contact the publisher s technical support team. Ifyou burned the disk yourself, try burning a new copy at a slower speed. If this problem happens repeatedly at exactly the same spot and youdon t have a bad installation disk, the trouble may be with one ofyour machine s hardware components.If you can, try trading hardwarebetween machines. If not, you may need to choose a different machineon which to install Linux or try another distribution. If the problem seems to happen randomly, your particular Linux dis- tribution may not be compatible with that particular machine.Again, you can try trading some hardware around, installing Linux on anothermachine, or using another distribution. If you re not sure whether your installer has frozen, try pressing various combinations of Alt+F#, where # corresponds to one of the function keys. Depending on the distribution, the installer has not completely frozen if you can see different screens when you try this technique. For Fedora Core Users with CD-ROMsWhen installing Red Hat Linux 7.3 or later (Fedora Core 3 is considered later ), a special solution is available to people who run into problems that seem tohave absolutely no explanation, such as the installer freezing. This solution doesn t work with the DVD provided with this book, because itcontains more than just the Fedora software, so continue with this sectiononly if you downloaded your own DVD or purchased it from a third party, or ifyou downloaded or otherwise acquired the Fedora CDs. If your installation keeps dying while Anaconda (the Red Hat installer program) is placing packages on your hard drive, follow these steps to try to fix it: 1.Place the DVD-ROM or the first Fedora Core CD-ROM into your drive. 2.Reboot the machine. 3.Wait until you reach the boot screen where you usually press Enter tostart the installation. If you reach a graphical installation screen, you missed the screen you relooking for. You need to reboot, repeat this step, and then proceed. 4.At the prompt, type linux mediacheckand then press Enter. Text scrolls by, and then you see a screen with a bright blue background. Then the CD Found dialog box appears. 371Chapter 20: Ten Troubleshooting Tips28_