An array of C#, PHP, and HTML programming articles, tutorials, and resources

Posts Tagged ‘ Linux ’

In the process of installing Red Hat Enterprise Linux 5 (RHEL 5) on a brand new Dell Optiplex 755, I came across the following error:

Unable to find any devices of the type needed for this installation type. Would you like to manually select your driver or use a driver disk?

Another symptom to this problem is the installation continuing in Text mode despite the command to install in GUI mode. You know you are in Text mode if you have no mouse control.

A quick workaround to the device request problem is to switch the SATA operation to “AHCI” mode in the BIOS. AHCI (stands for Advanced Host Controller Interface) allows communcation to SATA devices. With this setting, I started the installation without any other parameters. The installation went smoothly and took about six minutes to complete. Boot up to RHEL5 was error free as well.

Note that many sites recommend and alternative solution of switching the BIOS to “legacy” mode. I initially tried this method and found it greatly extended the installation time to over twenty minutes. It seems that switching to legacy mode has a major performance hit. Additionally, after the switch to legacy mode, a post installation problem occurred where the initial boot up resulted in a {}.

If you are still having challenges installing RHEL 5, refer to this great reference: http://www.linuxtopia.org/online_books/rhel5/installation_guide/index.html

To mount a USB External Hard Drive to a Linux Box, first make sure the unit is plugged in and powered on. Depending on your linux distribution, the hard drive may automatically mount. If this is not the case, mounting the external hard drive is not a very complicated tasks.

To begin, you will need to know where the hard drive is located. In most cases, the location is /dev/sda1 (though this is not always the case). However, if this isn’t the case, you can run the df command into you console. This will return a list of devices where you will most likely be able to find your drive by means of the hard drive max capacity.

Now, assuming the external hard drive is found at /dev/sda1. A great default place to mount the drive is in the /mnt/usbdrive. You will first need to make sure the folder already exists. If the folder does not exist, it can be created by using the command mkdir ‘/mnt/usbdrive‘. Then, use the below command into your terminal:

mount /dev/sda1 /mnt/usbdrive ext3 default 0 0

In the above example, mount is the command, /dev/sda1 is where the hard drive is currently located and /mnt/usbdrive is the folder in which you want the mount the hard drive. The next ext3 is the hard drive file system (Click here for information on Linux File Systems). The next input ‘default’ tells the default settings to be used. The first zero means to back up the file system using the dump utility and the second zero tells the OS whether to process the hard drive if fsck is run.

To have the Linux distribution automatically mount the drive on boot, you will need to add an entry (line) to the /etc/fstab file. In this case, it will be exactly the same as the mount command, except you will not need the mount command:

/dev/sda1 /mnt/usbdrive ext3 default 0 0

Now you have your external that is mounted when the Linux operating system boots up.

The standard Run Level for a linux machine booting up in full GUI mode is Run Level 5. In my experience, the most common Run Level (other than 5 for standard boot up) is Run Level 3. The most common need for Run Level 3 is for debugging problems and installing graphic drivers.

If you want to specify a default Run Level other than 5, the option can be changed in your /etc/inittab as defined by the initdefault directive. Below is a table specifying the other various Run Levels and State properties. Note that it is important never to set your initdefault directive to Run Level 0 or 6.

Run Level State
0 halt (shutdown) system
1 single user mode
2 multi user with no network exported
3 default full multi user console (text) only
4 reserved for local use (and X-window)
5 X-window full GUI mode
6 reboot system

Change Run Level After Boot Up

The easiest way to change the Run Level after the system has already been booted up is to open up the console and use init. There is an example below on how to change the Run Level to 3.

init 3

In addition, teleinit is an alternative to init and works in exactly the same manner.

telinit 3 

Change Run Level on System Boot Up

If however your Linux machine is currently powered off and you would like to boot directly into an alternative Run Level, you can change the Run Level by accessing the linux startup boot menu (GRUB). Simply choose the desired kernel and add init 3 into the kernel string.