cpanel/WHM Log rotate FIX

Fixing Log Rotation Problems

Since installing cpanel on some of our server, we noticed the logs in /usr/local/apache/logs/* growing out of control without ever being rotated. In /etc/logrotate.d the script called "httpd" is the reason why. Its totally wrong. Its looking for files located in /var/log/httpd/ and that is not where my log files are located. In fact, we dont even have files in this directory. Its completely empty.

Tags: Cpanel / WHM

Preventing Brute Force Attacks

source: http://www.webhostgear.com/240.html

Overview:
Blocking and preventing brute force attacks is one of the main things you want to do on your web server to add a layer of security. While someone might not be targeting your site or server specifically, they will have automated tools that will try to guess random usernames and passwords that are common against your system. They’re essentially forcing their way to user only authorized area’s of a system, such as FTP accounts, e-mail accounts, databases, script based administration areas and root or any shell access are most common attempts. They will try multiple login attempts, guessing usernames and passwords, trying to force their way onto your machine.

Tags: Linux

cPanel Resource Guide (servermatrix)

<p>source: <a href="http://forums.servermatrix.com/viewtopic.html?t=5572">http://forums.servermatrix.com/viewtopic.html?t=5572</a></p><p><span class="postbody"><font size="2">Hey guys, from the same people who brought you </font><a href="http://www.hostinglife.com/" target="_blank"><font color="#547293" size="2">www.HostingLife.com</font></a><font size="2"> we now bring you </font><a href="http://www.cpanelresources.com/&quo

HOW-TO: Install Turck MMCache

<p><font face="verdana, arial, helvetica" size="2"><b><font color="#333333">source: </font><a href="http://forum.ev1servers.net/showthread.php?s=c16323c6d2876f839cfbe7bd0932c0ba&threadid=23574"><font color="#333333">http://forum.ev1servers.net/showthread.php?s=c16323c6d2876f839cfbe7bd0932c0ba&amp;threadid=23574</font></a></b></font></p><p><font face="verdana, arial, helvetica" size="2"><b><font color="#ff0000">Up

Which ports should I open on my cPanel server?

<p>source: <a href="http://www.cpanelfaq.com/005/1.html">http://www.cpanelfaq.com/005/1.html</a></p><p>There are numerous ports that should be open on your cPanel server, this document will try to maintain and up to date record of all of these ports:<br /><br /></p><pre>port service protocol direction 20 ftp tcp inbound/outbound 21 ftp tcp,udp inbound/outbound 22 ssh tcp inbound 25 smtp tcp inbound/outbound 26 smtp tcp inbound/outbound [1]

PHP compile definitions

<strong><font size="1">Apache/PHP upgrade</font></strong> <p><font face="verdana, arial, helvetica" size="2"><font size="1">source: <a href="http://forums.cpanel.net/showthread.php?s=&threadid=16757">http://forums.cpanel.net/showthread.php?s=&amp;threadid=16757</a></font></font></p><p><font face="verdana, arial, helvetica" size="2"><font size="1">Can someone explain the different options in the WHM rebuild Apache scree

Introducing LAMP Tuning Techniques

Published on ONLamp.com (http://www.onlamp.com/)
 
http://www.onlamp.com/pub/a/onlamp/2004/02/05/lamp_tuning.html
 See this if you're having trouble printing code examples

by Adam Pedersen
02/05/2004

I'm getting to know far more about servers than I ever wanted to, after hundreds of hours of Google research trying to squeeze/beat performance out of Apache. I do have 15 years programming experience in other areas, and I've reached the conclusion that the only experts in Apache/Linux are the programmers who wrote (and poorly documented) all this stuff. So I've gathered everything I could learn after countless hours of frustration and I'm writing this up in return for the immense amount of help I've received from the documentation of others.

Tags: Linux

DNS setup (more info)

Hello,
This is a combination of posts I have used in the past and have adapted to provide an excellent DNS solutions.

The prerequisites for this are just Two Servers and in this implementation 4 IP's(2 per server) as it makes it more understandable. Also you will require a web accessible domain on each server.

Basically it will allow you to use a combination of two servers to do your DNS for you one being the primary and one the secondary. You could use this for every two sets of servers you own OR possibly adapt it so that all your servers use just the two sets.

It is my intention to eventually use this solution so that DJBDns is used instead of Bind because it is so flakey and buggy in my opinion.
DJB has a $500 reward for any exploits discovered thats how good it is!

Anyway enough chat lets get down to business....................

What we are aiming for is the following set up
NS1.JOELMOSS.COM PRIMARY NS FOR SERVER 1 ON SERVER 1
NS2.JOELMOSS.COM SECONDARY NS FOR SERVER 1 ON SERVER 2

NS3.JOELMOSS.COM PRIMARY NS FOR SERVER 2 ON SERVER 2
NS4.JOELMOSS.COM SECONDARY NS FOR SERVER 2 ON SERVER 1
 

Tags: Linux

How to setup DNS on Ensim

HOW-TO: Setting up Nameservers w/o Using Primary Server IP
There have been a number of threads with various bits and pieces of this process, but I haven't seen the entire thing in one place, so here goes. As always, modifying your server is done at your own risk and I accept no responsibility for anything that may happen.

Tags: Cpanel / WHM

Setting up Private Nameservers in Cpanel

This guide will show you the ropes in how to setup cpanel nameservers and configure them properly so you can run ns1 and ns2.yoursite.com. Once your nameservers are setup clients can then use your own private nameservers for their domains.

1. Regiser your domain
Register the domain name you would like to use, you can register a domain here if you need one.This domain will be used as your nameservers - eg ns1.yourdomain.com and ns2.yourdomain.com

2. Additional IPs
Have 2 available IP addresses for your server that aren't in use.You will need to contact you provider to obtain these IP addreses.

3. Registering the Nameservers  
Now login to your domain management page for the domain you registered and  register ns1.newdomain.com and ns2.newdomain.com as nameservers (registries normally have a special facility for doing that). The registry may also have a facility to propogate these nameservers around the foreign registries - if so, you should use this facility.

Tags: Cpanel / WHM

Properly Reject Invalid Email

Tired of seeing your mail queue fill up with bounce messages to non-existant spammer email addresses? By default, if an email comes into your server addressed to an invalid recipient, Exim will accept the message from the delivering agent, and then generate a return email to them explaining that the address is invalid. With this little tweak, you can make exim tell the delivering agent that that address is invalid at the time the message is being delivered, meaning no more spam returns cluttering up your queue! Can I get an Amen!? Read on!
Tags: Cpanel / WHM