More Technical Help

Showing posts with label cPanel Troubleshooting. Show all posts
Showing posts with label cPanel Troubleshooting. Show all posts

Thursday, May 19, 2011

cPanel Installation

CPanel installation is quite easy:

1) Login to the server with root access

2) wget http://layer1.cpanel.net/latest

3)sh latest

After this slow down your back on chair comfortably as the installation will take 30-45 min. You can watach the installation if any error occured.

Sunday, May 8, 2011

Catching spammer on cpanel server

If mass mailing or spamming is going on cPanel server then you can trace the spammer with follwoing commands:

1 ) pidof exim

2) Belwo command will show you the no of emails sent by perticular domain:

exim -bp | exiqsumm | more
3)
exim -bpr | grep "<*@*>" | awk '{print $4}'|grep -v "<>" | sort | uniq -c | sort -n
That will show you the maximum no of email currently in the mail queue have from or to the email address in the mail queue with exact figure.


4)

exim -bpr | grep "<*@*>" | awk '{print $4}'|grep -v "<>" |awk -F "@" '{ print $2}' | sort | uniq -c | sort -n
That will show you the maximum no of email currently in the mail queue have for the domain or from the domain with number.


5)

Check if any php script is causing the mass mailing with
cd /var/spool/exim/input
egrep "X-PHP-Script" * -R
Just cat the ID that you get and you will be able to check which script is here causing problem for you.


Exim Server Commands

How to check emails in mail queue?

exim -bpc

How to check full status of exim server?

eximstats -nr -ne /var/log/exim_mainlog

How to check exim pids running?
pidof exim
 
How to check frozen emails?

 exim -bpr | grep frozen | wc -l


How to delete frozen emails?

exiqgrep -z -i | xargs exim -Mrm


How to check mails sent per domain?

exim -bp | exiqsumm | more


 
 
 

Tuesday, May 3, 2011

Your license could not be activated : License File Expired

I had a issue with cPanel license as I was getting the error "Your license could not be activated"

Solution >>

I tried
/usr/local/cpanel/cpkeyclt
but the issue didn't get resolve. then I cheked the date on the sever and found that very old date was set on the server. Simply I sync the date with the command :

rdate -s rdate.cpanel.net


The issue got resolved.

Sunday, March 20, 2011

Security Logs


Authentication attempts:
Location : /var/log/secure
Description : Logs all daemons which requires PAM Authentication.


Tracking all Bad Logins and Logouts:
Location : /var/log/btmp
Description : Log of all attempted bad logins to the system. Accessed via the lastb command..

Tracking all Logins and Logouts:
Location : /var/log/wtmp
Description : The wtmp file records all logins and logouts.


Last Logins:
Location : /var/log/lastlog
Description : Database times of previous user logins. The lastlog file is a database which contains info on the last login of each user.


WebDav or WebDisk Log :
Location : /usr/local/cpanel/logs/cpdavd_error_log
Description : The cpdavd daemon is "WebDav" (better known as "WebDisk") which was introduced in cPanel 11 to allow users to mount their home directory on their personal computer, always having access to the files and content...


Cphulkd Logs:
Location : /usr/local/cpanel/logs/cphulkd_errors.log
Description : cPHulk Brute Force Protection prevents malicious forces from trying to access your server's services by guessing the login password for that service....
It blacklists IPs that it thinks are trying to run a brute force attack.


Failure Logging:
Location : /var/log/faillog
Description : Faillog formats the contents of the failure log from /var/log/faillog database. It also can be used for maintains failure counters and limits. Run faillog without arguments display only list of user faillog records who have ever had a login failure.


Startup/Boot, Kernel & Hardware error messages :
Location : /var/log/dmesg
Description : dmesg is a "window" into the kernels ring-buffer. It's a message buffer of the kernel. The content of this file is referred to by the dmesg command. It shows bootlog and the hardware errors..

Mysql Logs


MySQL General Information and Errors :
Location : /var/lib/mysql/$(hostname).err
Description : This path could vary, but is generally located in /var/lib/mysql. Could also be located at /var/log/mysqld.log

Mysql Slow Queries:
Location : /var/log/mysql-slow.log
 Description : These logs are only available if slow logs queries are enabled in my.cnf as well this   path cold vary but generally located in /var/log/

FTP Logs


FTP Logins and General Errors:
Location : /var/log/messages
Description : General information and login attempts are logged here..


FTP Transactions logging:
Location : /var/log/xferlog or /var/log/messages
Description : Is a symbolic link in most cases to /usr/local/apache/domlogs/ftpxferlog, which contains a history of the transactions made by FTP users...

Monday, January 17, 2011

Enable Logging of Slow MySQL Queries

MySQL has a feature that allows you to log slow running queries to a file. To enable you just need to add some lines to your my.cnf file, and restart.
Insert the following into /etc/my.cnf:
Save my.cnf and do the following when you return to a shell:
log-slow-queries = /var/log/mysql/mysql-slow.log
long_query_time = 5


#touch /var/log/mysql/mysql-slow.log
#chown mysql:mysql /var/log/mysql/mysql-slow.log
#service mysql restart

Saturday, December 18, 2010

Webmail Access in cPanel

You can easily access your WebMail interface by just visiting: http://www.yourdomain.com/webmail, where 'yourdomain.com' is your actual domain name. If this is not working for you, it might be possible that your ISP is blocking the access to non-standard ports accessed through SSL connection. In this case, please use: http://webmail.servername.com, where 'servername.com' should be the name of your server

Important Please use the full e-mail account username to login to the webmail interface or when setting your e-mail client software. Example: user@yourdomain.com instead of user.
Once you login, you can choose between three webmail clients: Horde, SquirrelMail and RoundCube. It is up to you to choose which one you like better.
webmail
If you login to your webmail through the Webmail icon on your cPanel main page, you will be logged in with the default system email account.

Important Please do not use the default email account, because very often emails send from the system email accounts are going to the Junk folders.
In order to use your email you have to create another email account with the same or different username.
To login to one of your added accounts from your cPanel, you should go to Email Accounts and then click the Access Webmail icon next to the account you wish to access. Then you should type in the password corresponding to the account and click on [Login].

How to send e-mail messages via webmail?

You can easily send email messages via the webmail client you have chosen. Just find the [New message] button in Horde, the [Compose] button in Squirrelmail or the [Create a New Message] button in RoundCube and you will be able to start writing your message.

Important Make sure to SAVE your message if it is too long or you want to write it for a longer period of time. The web mail program may drop the connection and you might lose your email.

Email Functions in cPanle

The Mail area functions allow a user to do many different tasks with email accounts. This includes creating email accounts, removing accounts, forwarding email, etc. The following part of this documentation will familiarize you with the Email Manager features.

Mail

E-Mail Options in CPanel

  • Email Accounts - allows you to create e-mail accounts, define passwords and quotas for them. You can separately manage the e-mail accounts for a chosen domain.
  • WebMail - cPanel webmail allows you to access the webmail programs (Horde, Squirrelmail and RoundCube) included in cPanel. You can read your emails through a web browser.
  • SpamAssassin - is an automated email filtering system that attempts to identify spam messages based on the content of the email's headers and body.
  • Forwarders - using e-mail forwarders will allow you to send copies of all your messages from one e-mail account to another. You can also send the messages from all the accounts with one domain to the corresponding ones with another domain.
  • Auto Responders - setting auto responder emails.
  • Default Address - this feature will "catch" all the mails that are sent to an invalid email address for your domain.
  • User Level Filtering - here you can manage filters for each user. Each user's filter is processed after the main account filters.
  • Account Level Filtering - allows you to manage the filters for the main account. There you can also test the existing filters.
  • Import Addresses/Forwarders - allows you to import e-mail addresses or forwarders from Excel spreadsheet files (.xls) or comma-separated values sheet files (.csv).
  • MX Entry - you can change the MX records for your domain and define on which server to deliver the messages.

Creating Email Account in cPanel

cpanel hosting, create email in cpanel hosting, create email cpanel hosting, create email account in cpanel, create email cpanel, cpanel web hosting
Many friends ask me how to create email account (ex: myname@mydomain.com) in CPanel Hosting. To create email account in CPanel hosting is just as easy as 123, here is the tutorial for create email account in CPanel Hosting.
Just follow the steps below and you will be able to create your email account in CPanel Hosting:-

  1. Login into your CPanel with the username and password
  2. Click on Mailcpanel email, email account cpanel, cpanel hosting email
  3. Click Manage / Add / Remove Email Account
  4. Click on Add Account
  5. Enter your prefer email address, password and the Email Quota for this email account and click on Create.
  6. Done! You just create your email account in CPanel hosting
Update (4 Feb 2010):
If you are using CPanel 11, you need to follow this steps:-
  • Login into your CPanel with the username and password
  • Click on EMail Accounts
  • Fill in the email you want, password, and mailbox quota and click “Create Account”
  • Done! You just create your email account in CPanel hosting

Can't login to webmail

Sometines you can not login to webmail on cPanel server though you are using correct credentials, in order to get this issue resolved you need server root access. Once you logged into the server fire the command :

/scripts/resetimappasswds

It must be working now.