Posts

Showing posts from March, 2014

Running Multiple Instances of MySQL in CentOS/Fedora/RedHat Linux

              Running Multiple Instances of MySQL in CentOS/Fedora/RedHat Linux                        1. Make sure that you have installed mysql-server in your Linux , If not install it with yum install –y mysql-server               2 .  After installing MySQL-Server , Open your terminal and paste as                              mkdir /var/lib/mysql2 chown -R mysql.mysql /var/lib/mysql2 mkdir /var/log/mysql2           chown -R mysql.mysql /var/log/mysql2 Above code stands for creating two directories for MySQL 2 nd instance , There /var/lib/mysql2   for data directory and /var/log/mysql2 is for log directory. After that changing the owner as mysql for both.               3 . Make a dump of mycnf configuration file with      cp -R /etc/my.cnf /etc/my2.cnf                     Then Open it with nano /etc/my2.cnf   (or ) vim /etc/my2.cnf                      Make the changes as mentioned in the below file.                                      # change/add the following options       

CentOS - IP Setting - Static IP- Command Line

Image
Commands required to set a static IP in CentOS  are . In Terminal , turn into root user and type as vi /etc/sysconfig/network-scripts/ifcfg-eth0 There Place the content as There as you can see the parameter. Set similar in your PC.Then save & close it with <Shift> + <:> +<w> + <q> . Then In terminal type as vi /etc/sysconfig/network There give your Gateway as shown You can disable/Enable network from there. Then check your Gateway updated or not with route -n Then after that restart your network with service network restart Thats it. Now you can connect to your CentOS to Internet. Points to remember : Nothing much !! all you have to execute the commands as root user.