April 30th, 2013 |
First use sync command update the super block. Then use the eject utility. It is used for those removable media devices that do not have a manual eject button, or for those that do, but are managed by Volume Management. 1) Type command sync to write superblock or data to device (for floppy disk): # [...]
April 30th, 2013 |
FreeBSD is a Unix-like free operating system. You can install to choose third party software on FreeBSD from the Ports Collection. Many services such as POP3 server daemons, IMAP, etc. could be started using the inetd. However, networking can be stop or started using special script located in /etc/rc.d/ directory. This directory includes script to [...]
April 29th, 2013 |
Following are the logs files on a cPanel server for different services: Apache Logs: /usr/local/apache/logs/access_log /usr/local/apache/logs/error_log Exim Logs: /var/log/exim_mainlog /var/log/exim_paniclog /var/log/exim_rejectlog Ftp Logs: /var/log/messages Mysql Logs: /var/lib/mysql/server.hostname.err ChkServd Logs: /var/log/chkservd.log Named (Bind) Logs: /var/log/messages Last logins to server: /var/log/wtmp (but to view the details, execute the command “last”) Domlogs of an Account: /usr/local/apache/domlogs/domainname.tld Mod [...]
April 29th, 2013 |
MySQL replication will stop if an error occurs when running a query on the slave. The reason is so you can resolve the problem, thus keeping the data consistent with the master. You can skip those errors if you know those queries and why they are failing. Skip one query mysql>SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1; START SLAVE; [...]
April 28th, 2013 |
Helper script to create users on all OpenVZ VEs simultaneously: #!/bin/bash # create_ve_users.sh # Usage: ./create_ve_users.sh <username> <password> <uid> <group1,group2> USERNAME=$1 PASSWORD=$2 USERID=$3 GROUP=$4 EXPECTED_ARGS=4 OUT_FILE=.create_users_$$ if [ $# -ne $EXPECTED_ARGS ] then echo “Usage: `basename $0` <username> <password> <uid> <group1,group2>” exit 65 fi VE_LIST=$(/usr/sbin/vzlist -H -o veid) for VE in ${VE_LIST} do vzctl [...]
April 28th, 2013 |
How to compile a kernel on a CentOS server? Compiling a kernel on a CentOS server is probably easy than other Operating Systems but still you should take care while selecting modules else the server won’t boot up on the new kernel. New System admins find it difficult to compile a kernel, however, the following [...]
April 27th, 2013 |
If you manage several OpenVZ containers, here is a simple bash script to keep the OpenVZ containers upto date. #!/bin/bash # vzyum_updates.sh # updates VEs VE_LIST=$(/usr/sbin/vzlist -H -o veid | grep -v Warning) for VE in ${VE_LIST} do /usr/bin/vzyum $VE update done exit 0
April 27th, 2013 |
By default Qmail allows a maximum of 10 local and 20 remote deliveries of emails simultaneously. In order to increase the number of concurrent local and remote email deliveries in Qmail, the values in the concurrencylocal and concurrencyremote files needed to be increased. Plesk control panel also offers Qmail and have the same default values [...]
April 26th, 2013 |
Some one posted about, “What is Modules in Linux and how to add it in apache,” on our forum. Therefore, I decided to create a small howto for adding new modules under Apache. The Apache HTTP Server is a modular program. So as a UNNIX/Linux administrator you can choose the functionality to include in the [...]
April 26th, 2013 |
#!/bin/bash # A simple shell to build and install suhosin as module for PHP under # CentOS, Fedora and RHEL / Redhat Enterprise Linux servers. # —————————————————————————- # Written by Vivek Gite <http://www.cyberciti.biz/> # (c) 2009 nixCraft under GNU GPL v2.0+ # —————————————————————————- # Home page: http://www.hardened-php.net # Last updated: 15/June/2010 # —————————————————————————- VERSION=”-${2:-0.9.31}” URL=”http://download.suhosin.org/suhosin${VERSION}.tgz” [...]