Archive for the 'cPanel Tutorials' Category

Secure Remote FTP Backups in cPanel

Backing up the files on your computer is essential and the same holds true for the data on your website.  Sure, your web host probably makes a habit of backing up data but why put your fate in their hands?  After all, anything can go wrong including hardware failure, fire or even natural disasters.  Fortunately, there are options for backing up your own website data and storing a copy for a rainy day.  This tutorial will go over how you can perform secure backups to a remote FTP server with cPanel.

What Can You Backup?

cPanel’s backup tool is a real lifesaver and incredibly easy to use.  It allows you to download a zip file of databases, email configurations, databases and the entire contents of the site to your computer hard drive.  While you can’t automatically schedule backups like a client program, the tool is pretty efficient.

The backup utility and cPanel allows you to perform the following:

  • Full backups
  • Backups of your home directory
  • MySQL backups
  • Email filters and forwarders backup.

You can also instantly restore the same items with the exception of full backups.

Performing a Full Backup

If you want to be on the safe side then a full backup is the way to go.  This method will create an archive of your website files and configurations.  Keep in mind that full backups are designed for moving your content to another server or maintaining a copy on your local hard drive.  These type of backups cannot be restored through the control panel interface.

Following these steps to create a full backup of your site.

  • Select the “Backups” icon from the cPanel interface.
  • Next, click the “Download or Generate a Full Backup” tab.
  • For “Backup Destination”, you want to choose a location the backup copy will be saved to. Your choices include

- Home Directory

- Remote FTP Server

- Remote FTP Server (Passive mode transfer)

- Secure Copy (scp)

Since you want to securely backup your files on a remote FTP server, we will follow directions for the FTP/SCP Settings.

  • Enter Address - Enter the email address where you want cPanel to send confirmation letting you know when the full backup has been created.
  • Remote Server (FTP/SCP only) - Enter the host name or IP address of where you want to backup the file.
  • Remote User (FTP/SCP only) - Enter the user ID to the remote server where you want to the send the backup file.
  • Remote Password (FTP/SCP only) - Enter the password to the remote server where you want to send the backup file.
  • Port (FTP/SCP only) - Enter the port number to the remote server where you want to send the backup file
  • Remote Dir (FTP/SCP only) - Enter the directory name of the remote server where you want to send the backup file.
  • Click on the “Generate Backup” tab.

After clicking the tab, you should see a statement explaining that you will receive email notification to the provided email account after a full backup of has been completed.  Once you receive the message, click the “Go Back” link in the body of the email.  This will take you back to cPanel where you will find an entry that reads “Backups Available for Download”.  The backup has been sent to the remote server and you can now download it at any time.


Creating Cron Jobs in cPanel

As a webmaster, there may come a time in your life where you need to run automated tasks on preset schedules.  Perfect examples would be if you are running an auction on your site or would like to schedule automatic backups of your MySQL databases.  In this case, you need to set up a cron job.  This article will provide some beginner tips on setting up cron jobs from the cPanel control panel.

Getting Starting

First things first - log in to your cPanel account and find the “Cron Job” icon on the interface.  After clicking on the icon, you will be then be asked to choose an experience level.  Since this a beginner’s tutorial, click on “Standard”.

Setting Up a Cron Job

Once you are inside of the “Standard Cron Manager”, it’s time to set up your cron job.  You can either create it to execute at specific intervals or specific times.  To create the cron job, follow these simple steps:

  • Enter your preferred email address in the line that reads “Please enter an email address where the cron output will be sent”. By doing this, cPanel will automatically send you an email notification when the crob job is executed. If there were any problems, the message will let you know.
  • Enter the full path to the script you want to run in the “Command to run” field. If it’s a PHP script you want to run, the command will start with “PHP”.

Schedule the Cron Job

Setting a schedule for your cron job requires a few more steps but is just as easy.  Below are some of the options you have

  • Set the Minutes(s): Here you can set up a short interval or minutes on the hour. If you are not concerned about minutes, simply leave this field to the default setting of “0″. If you want to test out your cron job, set it to run at “Every Five Minutes”. This is an ideal interval for running a script. If lets you check your email for any errors and then come back and make the corrections before your inbox gets flooded with cron messages.
  • Set the Hour(s): There may be a few scripts you want to run each hour such as an RSS import. In this case, you would set the cron job for “Every Hour”. If you want to schedule a backup of your database, you may want to choose a late night hour or some weekend time when your site isn’t as busy.
  • Set Day(s): Depending on what you have got going on, you may want to leave this option set to “Everyday” You do however, have the choice of selection certain days of the month. Additional cron job options include “Set the Weekday(s)” and “Set the Month(s)”.

After creating the schedule and clicking the “Save Cron” button that’s it - your cron job is done.  If you set a brief interval for testing purposes, you should have a message waiting for you in your inbox within a couple of minutes.  The email will tell whether or not the job was successful.  In most cases, errors are the result of incorrect script paths.


cPanel Tutorial: Setting up Spam Assassin

Spam has become as common as the internet itself.  This annoying epidemic has resulted in the development of various tools to combat the issue from both the client and server side.  In this tutorial we will discuss the powerful Spam Assassin spam filter and how it can be set up in cPanel.

Description

Spam Assassin is one of the most efficient spam-fighting tools on the market, available with almost any hosting plan offering cPanel.  By default, this utility is disabled in your control panel but enabling it is fairly simple.

Enabling and Configuration

After logging into your control panel, you will notice “Spam Assassin” on the interface underneath the “Mail” tab.  When clicking the tab you will be taken to the main configuration page and presented with an array of options.  To start protecting your inbox right way, simply click “Enable Spam Assassin”.  This will activate the utility and filter spam on the default settings.

Spam Assassin’s default filter is set to level 5, a decent setting for the average end-user.  By setting the number higher, fewer messages will be tagged as spam, thus resulting in less false positives.  This number can always be adjusted in accordance to your level of false positives.  You can also make configurations to delete spam mail as soon it arrives.  This is useful in regard to easy management but you also stand the chance of losing legitimate emails.  Because of this, learning to properly adjust the level of your filter is critical.

Your Spam Box

After first enabling Spam Assassin, all suspected spam emails in your Spam Box will be tagged with “SPAM” in front of the subject field.  Of course, an exception would be if you have enabled the auto-spam delete function.  This setting gives you the ability to configure your mail client to filter out messages based on certain tags.  The Spam Box acts as your quarantine folder, performing on the server and preventing the messages from reaching the inbox on your desktop.  The Spam Box automatically creates an isolation folder as soon as a spam message is detected.

The major benefits of activating the Spam Box is avoiding all the unsolicited emails in the form of advertisements, viruses, scams and other potential threats.  It also allows you to access your webmail account on the server to find out if any legitimate messages were mistakenly tagged.  The disadvantage of this filtering method relates to inconvenience as you will have to login to your cPanel account on a regular basis to manage the Spam Box.  If not, the messages stored on the server will consume precious storage space.

Advanced Settings

Spam Assassin includes extra features that allow you to filter messages based on various criteria.  Configurations can be made to block out or allow mail based on a specific email address or an entire domain.  For instance, if you are constantly missing emails from a friend or company, you could add that name to a “Whitelist”, instructing Spam Assassin to allow the message to pass.  This method works the same way with a Blacklist which allows you to automatically block messages from a website that has been harassing you with spam.


cPanel Tutorial: Creating FTP Accounts

The FTP Accounts section of cPanel is where you can set up additional FTP accounts.  This is most often performed to grant someone temporary or partial access to your hosting account.  For instance, lets say you have a third-party web developer building your site on a sub-domain.  Instead of giving them access to the entire site, setting up an additional FTP account would only grant them access to that particular directory.  Once the job is done and they no longer require access, you may then delete the account.

Getting Started

After logging into cPanel and accessing the FTP section, enter a username for the FTP account.  Keep in mind that the final name will include your domain name.  For example, if the username is “designer”, your FTP username may read something like this: designer@mydomain.com Your base domain will also be appended to the username even if its an account for one of your parked domains.

From there you need to create a password to protect the FTP account and your web content.   This should be a secure password; a good mix of letters, numbers and symbols and at least eight characters in length.

With your FTP login credentials all squared away, you then need to choose a home directory for the account.  This is how you will grant someone access to a particular section of your site.

If you want to give them access to all the content in your public (public_html) directory, enter a slash (”/public_html”) in the “Home” directory input field.  If the field is left blank, cPanel will create a folder based on the username you entered.  This comes in handy when you want to grant access to all of your web content, without the username and password that will allow them to access your control panel and account information.

Creating FTP Accounts for Sub-domains and Parked Domains

As we mentioned above, creating FTP accounts for your extra domains is an easy way to grant access to others while keeping the core of your site private.  If you want to grant someone access to the files in your parked domain, enter something like “myparkeddomain” into the “Home” directory field.  This would make the full directory path to your FTP account something like “/home/designer/public_html/myparkedomain/”.

Creating FTP Accounts for Other Directories

Setting up an account for another directory on your account is useful for allowing someone to upload and download files from the site.  Lets say you have hired a web designer to help create the site.  They can use this FTP account to upload content and show you the work they have completed.  For example, if the designer’s name is Tom, you can enter “Tom” in the “Home” directory field which would create a directory called “/tom/”.  When the designer accesses this FTP account, they will automatically be taken to that directory.

Final Notes

All of the files dedicated to FTP accounts you created are made visible simply by typing the directory into a browser.  For instance, if you have uploaded files to the “/home/designer/public_html/myparkedomain/”, type http://mydomain/myparkeddomain/ into the browser.  Keep in mind that these files will not be displayed in search engine results unless they have been linked.


cPanel Tutorial: Installing Wordpress

The blog can no longer be called a fad, as it is more like a phenomenon.  Blogs have gone from small platforms to complete websites with all the works.  They are used by a range of demographics from teens and adults to freelance writers and well known online entities.  Many have used the blog as their vehicle to success.  Some have even gone on to say that no business should be without one.  Thanks to web hosting technology, blogs are no longer limited to their respective development community.

Control panels are powerful web hosting tools that enable users to build and administer their site with ease.  cPanel is regarded as one of the best and is currently the most widely installed.  This control panel is known for being user-friendly with a plethora of features.  cPanel allows you to manage your emails, set up domains, view web stats, backup data and much more right from the interface.  It also gives you the ability implement a variety of scripts to create message forums, chat rooms and even blogging software.

In this tutorial you learn how to install the popular Wordpress blogging software in cPanel by way of the Fantastico script installer.  If you make use of another control panel, we suggest referring to the Wordpress website for more details.

Getting Started

After logging into the cPanel account, click on the “Fantastico” icon.  When that window opens, open the “Full List” menu and click the “Wordpress” link in the “Blogs” category.  A separate page for Wordpress will open giving a short description on what the program is about.  After verifying that the server has adequate space, you will click on a link that reads “New Installation”.

Your next step is to make a few essential configurations, starting with the installation location.  Your options are “Install on Domain” and “Install in Directory”.  If you want to install Wordpress on your domain, access the drop-down menu and select the appropriate name.  If want to install it on the root of your domain, leave the “Install in Directory” section blank.  For example, if you want to access Wordpress in a different directory such as “blog”, you would type something like this into the field: http://mysite.com/blog.

After determining where to install the program, you will then need to assign a username and password, the credentials that will allow you to access the back-end of Wordpress.  Enter the following information into the main configuration section:

Administrative nickname: This is the name that will be display on your Wordpress administrative account

Administrative email: The email account where you want to receive administrative messages

Site name: The URL that represents your website

Description: A short description that describes your website

Once you have entered this information, click on the “install” button.  From there the installation will notify you of the updates that were made.  After clicking the “Finish Installation” button you’re done.  You then have the option of sending the details to a particular email account or returning to the overview section.


« Prev - Next »