Something Different In Linux

    Previous Next

      You can use the following script to auto restart the nginx on the server. The following script check the status and if it is down then it restart. You can set cron  “* * * * * /bin/sh /root/” ========================== #! /bin/sh set -e PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin DESC=”nginx daemon” NAME=nginx DAEMON= /usr/sbin/$NAME SCRIPTNAME=/etc/init.d/$NAME test -x $DAEMON || exit  [ Read More ]

      daily mysql databases backup on cpanel server

      Posted by Rishikesh Vispute Categories: cpanel, mysql, Uncategorized

      Question: How to back up MySQL databases using cron jobs on cpanel server ? Ans: You can take the mysql backup of all databases for last 10 days and keep on the server.  You need to add the cron to create the daily mysql backup of all the databases. The backup is stored in the folder  [ Read More ]

      restart Apache automatically when high load

      Posted by Rishikesh Vispute Categories: Uncategorized

      Question: How to set Cron to restart Apache automatically ? Ans: You can add the following cron to restart  Apache automatically when it was down for any reason or if the server load is 20. vi /var/spool/cron/root */2 * * * * /bin/sh /root/ > /dev/null 2>&1 #!/bin/bash #You can set the Load limit as  [ Read More ]

      Question: How to install R1 soft cdp agent on the Linux server? Ans : You can install the Latest R1 soft cdp agent on Linux server by using following steps 1) Create the yum repository for the r1soft vi /etc/yum.repos.d/r1soft.repo [r1soft] name=R1Soft Repository Server baseurl=$basearch/ enabled=1 gpgcheck=0 2) Install the cdp agent by using following  [ Read More ]

      Question : How to terminate old suspended accounts on cpanel server ? Ans:  You can terminate the 90 days old suspended accounts by using the following script. 1) vi /root/ ================== for i in `find /var/cpanel/suspended/ -mtime +90 | cut -d’/’ -f5 | sed ‘1 d’` do y | /scripts/killacct $i –killdns n; done; ==================  [ Read More ]

      First post on vmware

      Posted by Rishikesh Vispute Categories: vmware

      This is my first post on VMware, actually I have just started VMware classes  and so right now I know only about the some features of VMware. Today we have setup the  VMware  LAB and checked all the features on VMware. In future I will add some more posts and try to add some interesting  [ Read More ]

      scan FTP uploaded files on cpanel servers

      Posted by Rishikesh Vispute Categories: cpanel, security

      This Howto will help you virus can all uploaded via FTP to make sure all files are virus free: First lets install clamAV , it has been now been included in Cpanel/WHM you can do so from your WHM interface as root by clicking on : Cpanel —> Manage Plugins —> on clamavconnector Check the  [ Read More ]

      Reseller account migration by using script

      Posted by Rishikesh Vispute Categories: cpanel

      For migrating Reseller and/or Bulk accounts between cpanel servers:: *On source server =========================== cd /home mkdir /home/Migration cat /etc/trueuserowners |grep reseller_username | awk ‘{print $1}’ | cut -d: -f 1 > Migration.txt for i in `cat Migration.txt`;do /scripts/pkgacct $i; mv /home/cpmove-$i.tar.gz /home/Migration/;done =========================== *On Destination server =========================== vi Migration.txt ( add all username which you  [ Read More ]

      Important cpanel/whm files

      Posted by Rishikesh Vispute Categories: cpanel

      Important cpanel/whm files ==================== /etc/httpd/conf/httpd.conf – apache configuration file /etc/exim.conf – mail server configuration file /etc/named.conf – name server (named) configuration file /etc/proftpd.conf – proftpd server configuration file /etc/pure-ftpd.conf – pure-ftpd server configuration file /etc/valiases/domainname – catchall and forwarders are set here /etc/vfilters/domainname – email filters are set here /etc/userdomains – all domains are listed  [ Read More ]

      common issues in wordpress

      Posted by Rishikesh Vispute Categories: Wordpress

      **Common Issues in WordPress** 1. Lost Admin Password & Email Retrieval Is Not Functioning The problem: You lost your WordPress admin password, and have tried to enter your username or email address in the “Lost your password?” page but failed to receive any link to create a new password via email. Here are 2 simple  [ Read More ]

      Stop spamming using iptables

      Posted by Rishikesh Vispute Categories: cpanel, security

      You can stop the number of spammer  ip address to known spam ip addresses from spamhaus . org vi /root/ ========================= #!/bin/bash IPTABLES=/sbin/iptables FILE=”/tmp/drop.lasso” URL=”” #echo “” #echo -n “Applying DROP list to existing firewall…” $IPTABLES -D INPUT -j Spamhaus $IPTABLES -D OUTPUT -j Spamhaus $IPTABLES -D FORWARD -j Spamhaus $IPTABLES -F Spamhaus $IPTABLES -X  [ Read More ]

      How to Stop Spamming on cpanel server

      Posted by Rishikesh Vispute Categories: cpanel, Email problems

      Q. How to Stop Spamming on cpanel server ? Ans : There are number of steps but you must enable/disable some Tweaks on cpanel server. Setting in “Exim Configuration Manager” 1. Login to WHM control panel by using root user 2. Goto Main >> Service Configuration >> Exim Configuration Manager 3. Enable RBL filtering by  [ Read More ]

      Error : You do not have sufficient permissions to access this page When try to activate the plugin in wordpress and then some time it shows the error “You do not have sufficient permissions to access this page” then you need to made some changes under that account. Solution : Open wp-config.php file  and Replace  [ Read More ]

      Error : Apache error : Too many open files: could not open transfer ……..Unable to open logs Solutions: When apache is not started and the error log shows above error then you need to follow the steps 1) Open file /etc/init.d/httpd or /usr/sbin/apachectl Add `ulimit -n 65536` This is because of the low number of  [ Read More ]

      upgrade mysql version on linux server

      Posted by Rishikesh Vispute Categories: How to, mysql

      You can upgrade your mysql version from 5.0 to 5.5 by using following steps 1. Enable remi repository for yum wget wget sudo rpm -Uvh remi-release-5*.rpm epel-release-5*.rpm 2. Run mysqldump to export data out from MySQL 5.0 mysqldump -uroot -p –all-databases > mysqlbackup.sql 3. Run ‘yum –enablerepo=remi install mysql mysql-server mysqlclient’ 4. Run  [ Read More ]

      Account modification aborted

      Posted by Rishikesh Vispute Categories: cpanel, Error and solution

      Error : Account modification aborted, there was a problem changing the user name. When you go to Account Functions >> Modify an Account and try to change the username of domain, sometimes you may get the following error.  There is currently a configuration error in the Apache configuration file. User name change aborted. Account modification  [ Read More ]

      Popular Posts

      remove index.php fro

      How to remove index.php from url in magento Ans : If you ...

      PHP-Java bridge on p

        What is php-java bridge? The php-java bridge is the php ...

      Set expiration for y

      If you want to set the expiration to your site ...

      Warning: Parameter 1

      Error: Warning: Parameter 1 to modMainMenuHelper::buildXML() expected to be a ...

      domain pointing to e

      If you domain uses external MX record and it is ...