Wednesday, October 24, 2007

Install GNU/Linux without any CD, floppy, USB-key, nor any other removable media

Install GNU/Linux without any CD, floppy, USB-key, nor any other removable media

I have a server running CentOS 4 with internet on it. This server is without any CD Drive, floppy Drive, USB-key, nor any other removable media and its Remote server.

How do i install CentOS 5 on it? I have searched in various forums, posted in various forums.
After a long hour I have came to solution.

I am writting here what excataly I have done.

Since, I have net connection on current system,

1. I have downloaded ISO image of centos 5 (1 CD only)
2. mkdir /mnt/tmp
3. mount -o loop CentOS-5.0-x86_64-bin-1of7.iso /mnt/tmp
4. cp -a /mnt/tmp/isolinux/vmlinuz /boot/vmlinuzMy
5. cp -a /mnt/tmp/isolinux/initrd.img /boot/initrdMy.img
6. umount /mnt/tmp
7. Add entry to your /etc/grub.conf
title Fedora Core 2 Installation
root (hd0,0) kernel /boot/vmlinuzMy
initrd /boot/initrdMy.img
8. Reboot system
9. Now your is booted and ready for new installation.
10. Select installation method you want (FTP, HTTP or NFS probably). I have selected http
11. Give your Name server and ipdetails.
12. Give site & Dir (I have given)
mirror.stanford.edu
/yum/pub/centos/5/os/x86_64/

I think its ok to install now :)

Thursday, October 18, 2007

System Security Monitor root access

Security of the server always come first , especially web server which access by the worldwide and hackers always keep eyes on those server's.
So, its good if you have system which automatically send a email notification via email whenever someone logs in as root on your system.
To configure the automatic email alert notification to a email address on each incident of root log on on the server, use the following guide.
Login to the server via SSH using as root ID.
  • Ensure that you’re at home directory of root. The open up the .bash_profile for editing using pico or vi by typing one of the following commands at linux command shell:
    pico .bash_profilevi .bash_profile
  • Scroll down to the end of the file and add the following line:
    echo 'ALERT - Root Shell Access on:' `date` `who` mail -s "Alert: Root Access from `who cut -d"(" -f2 cut -d")" -f1`" user@example.com
    Replace user@email.com with the actual email account address that you want to the root access alert notification been sent to. Note that you can change the text contains in the email alert too. The text starting with first ALERT is written as email body, and you can add in other info such as host name or change the wordings. The second Alert is the email title which you can change to your own too.

Note that you can change the text contains in the email alert too. The text starting with first ALERT is written as email body, and you can add in other info such as host name or change the wordings. The second Alert is the email title which you can change to your own too.

Now logout and login again as root, you should receive an email alert at your inbox. The security trick should works on most popular flavor of Linux such as RedHat, CentOS, Ubuntu, FreeBSD and etc.

SHOW ENGINE INNODB STATUS

  The SHOW ENGINE INNODB STATUS command in MySQL provides detailed information about the internal state of the InnoDB storage engine. This ...