Can you tell me differences between the following sysvinit /sbin/service command:
service httpd restart
service httpd condrestart
service httpd reload
Can you tell me differences between the following sysvinit /sbin/service command:
service httpd restart
service httpd condrestart
service httpd reload
Q. I’m running application called Urchin or Google Analytics under FreeBSD and I’m getting the error that read as follows:
ERROR: (8011-323-1057) Failed to allocate memory
How do I fix this error?
[continue reading…]
Q. I’m using Debian Linux and CentOS operating system. My question is what do I do if my server refused to boot? How do I troubleshoot the problem?
A. Usually most Linux distribution provides rescue mode. It allows to access to disk partition and you are allowed to solve the problem.
To use the rescue mode of the install CD, follow these steps:
a) Boot from 1st CD / DVD media
b) Enter rescue at the prompt. (use ‘dd rescue‘ if you need to load the SCSI driver)
c) You will get at a shell prompt. Now you can reinstall boot loader or check disk for errors and so on.
Please note that Linux distributions such as Mandriva or Ubuntu Linux offers menu based troubleshooting options. See our previous articles for detailed instructions:
Q. I’m using OpenBSD as VPS os (guest os) under VMWARE server. However OpenBSD pauses for a few seconds to give me a chance to provide parameters to the kernel at boot> prompt. I’d like to force boot loader to wait for 30 seconds instead of default timeout. How do I setup bootloader timeout?
A. OpenBSD uses boot program. The main purpose of this program is to load the system kernel while dealing with the downfalls of the PC BIOS architecture. This program acts as an enhanced boot monitor for PC systems, pro viding a common interface for the kernel to start from. By default, boot attempts to load the kernel executable /bsd. If it fails to find the kernel and no alternative kernel image has been specified, the system will be unable to boot.
/etc/boot.conf is configuration file for bootloader. Open file using text editor:
$ sudo vi /etc/boot.conf
Append / modify timeout parameter as follows:
set timeout 30
Save and close the file. Above line set the 30 second pause at boot-time.
Q. How do I uninstall GRUB? I need to uninstall everything before sending this hard disk to someone including GRUB. All I need to keep is windows XP.
A. GNU GRUB (“GRUB” for short) is a boot loader package from the GNU Project. GRUB is the reference implementation of the Multiboot Specification, which allows a user to have several different operating systems on their computer at once, and to choose which one to run when the computer starts.
You can overwrite MBR with standard dd command. You can also use old good MS-DOS fdisk command to overwrite MBR.
In order to remove the GRUB bootloader from a Linux and Windows XP machine, boot with a Windows 9x startup disk or CD and execute the MS-DOS command:
fdisk /mbr
Boot computer using Windows XP (Windows 2000) setup disc / CD / DVD. Next, type the following commands:
# fixmbr
# exit
You can also use dd command from Linux itself (it removes partition table):
# dd if=/dev/null of=/dev/sdX bs=512 count=1
Just remove MBR, without the partition table (see comment below):
# dd if=/dev/null of=/dev/sdX bs=446 count=1
Replace /dev/hdX with your actual device name such as /dev/hda. Use fdisk -l command to find out device name:
# fdisk -l
Output:
Disk /dev/sda: 251.0 GB, 251000193024 bytes 255 heads, 63 sectors/track, 30515 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System /dev/sda1 * 1 13 104391 83 Linux /dev/sda2 14 30384 243955057+ 83 Linux /dev/sda3 30385 30515 1052257+ 82 Linux swap
Q. I forgot my root password, how can I get into my system?
A. You can reset forgotten root password under Linux by booting system into single user mode or emergency mode (also known as rescue mode).
)Following is the procedure to reset root password if you are using GRUB as a boot loader:
You need to mount at least / and other partitions:
# mount -t proc proc /proc
# mount -o remount,rw /
Change the root password, enter:
# passwd
Finally reboot system:
# sync
# reboot
At LILO boot loader type linux single and press [ENTER] key:
Boot: linux single
When you get the # prompt you will need to type passwd root to reset password:
# passwd
Reboot system:
# sync
# reboot