- These instructions are intended specifically for solving the error: No matching DirectoryIndex (index.html) found.
- I’ll be working from both Liquid Web Core Managed CentOS 6 and CentOS 7 servers, and I’ll be logged in as root.
Have you run into the cPanel error seen below in WHM where it prevents you from adding more cPanel accounts? It states that you have exceeded the total number of accounts allowed by your license. If so, this tutorial will demonstrate how you can increase the quantity of available accounts from within your Manage interface.Continue reading “How To Modify A cPanel License in Manage”
In this article, we will discuss how and why a dedicated server might block an IP address and how to resolve it.
When your company hosts a website or web app online, whether it’s an individual dedicated server or a whole server cluster, you naturally expect to have uninterrupted access at all times. However, it’s possible that in rare circumstances, your server could accidentally block your IP and prevent you from connecting and using the service.
If that has happened to you, this quick summary will provide you with all the essential information needed to verify the status of your IP. Additionally, we will offer some of the most common reasons for being blocked, as well as a few suggestions on how to unblock and whitelist your IP as quickly as possible.Continue reading “Why Did the Server Block My IP?”
Reading Time: 2 minutesThe EPEL repository is an additional package repository that provides easy access to install packages for commonly used software. This repo was created because Fedora contributors wanted to use Fedora packages they maintain on RHEL and other compatible distributions.
To put it simply the goal of this repo was to provide greater ease of access to software on Enterprise Linux compatible distributions.
What’s an ‘EPEL repository’?
The EPEL repository is managed by the EPEL group, which is a Special Interest Group within the Fedora Project. The ‘EPEL’ part is an abbreviation that stands for Extra Packages for Enterprise Linux. The EPEL group creates, maintains and manages a high-quality set of additional packages. These packages may be software not included in the core repository, or sometimes updates which haven’t been provided yet.
Continue reading “How to Enable an EPEL repository”
Reading Time: 2 minutesThere will be many times when you will need to optimize all images in a site media library. If you are familiar with using WP-CLI, then there is a very handy package which can be installed. The package is called “image-optimize” and it will simplify the process of getting your images ready for web hosting.
This package is not for “managed hosts” since the libraries needed will not be able to be installed having without root access and it can be CPU resource intensive.
Preparing to Run Commands
The package for WP-CLI is called image-optimize. To be able to use this package, you will need to login to your site’s server and update WP-CLI. You can update WP-CLI by running the following command:
wp cli update
Next, you will need to install a number of libraries that the package uses to optimizes jpeg, png and gif images with these commands:
sudo apt-get install jpegoptim
sudo apt-get install optipng
sudo apt-get install pngquant
sudo apt-get install gifsicle
Now you can install the stable version of the image-optimize package with this command:
wp package install typisttech/image-optimize-command:@stable
Optimizing Site Images
The following are examples of the commands to run after a WordPress core update:
wp image-optimize mu-plugins
wp image-optimize plugins
wp image-optimize themes
wp image-optimize wp-admin
wp image-optimize wp-includes
You can use this command to regenerate all thumbnails on a site.
wp media regenerate --yes
You may need to limit how many images that image-optimize will process in a single back. To limit the batch size, you just need to add the –limit flag to the end of the batch command and specify the amount, as shown in these examples:
wp image-optimize batch --limit=500
wp image-optimize batch --limit=1000
wp image-optimize batch --limit=2500
wp image-optimize batch --limit=5000
When using the image-optimize WP-CLI command, server CPU usage may be intensive, so run the batch commands in smaller sizes during the off hours times on your site. You can track CPU usage whilst running a batch optimize command by using htop. You can install and run htop using the following commands:
sudo apt-get install htop
To use htop to monitor server load, keep a terminal window open while the batch optimize command is running in another terminal window. In our testing, the CPU usage was not too high.
1.61GB/3.74GB Memory usage
180M - 3.86GB Swap
Restoring Optimized Images
Before images are optimized backup versions are created, which means that you can restore at any time to a backup file and replace out the optimized version.
For example, Attachment 123 was optimized using this command:
wp image-optimize attachment 123
To restore the attachment for 123 the command to run would be:
wp image-optimize restore 123
You can use the wp media regenerate command to regenerate a specific media file.
wp media regenerate 123
Being able to optimize the images in your WordPress sites media library will reduce the amount of storage needed for your site. Optimization will also improve the speed and performance of your site for visitors, improving user experience and satisfaction.
Reading Time: 3 minutesThe Mail Queue Manager feature in WHM allows you to view, delete, and attempt to deliver queued emails that have not yet left the server. It can be a handy tool for diagnosing a variety of issues with mail deliverability, such as spotting signs of a compromised account sending spam from the server.
Reading Time: 3 minutesAdding a user in CentOS is a common task for most Linux admins. Users have unique username’s and occasionally you may wonder if a username is in use or need other details about the user (like their group ID). We’ll show you how to see a list of users after logging into your Liquid Web CentOS 7 server. Once you’ve logged in via SSH, you’ll be able to run the commands below and get the information you need. Let’s get started!
Reading Time: 6 minutesWith the shortage of available address space in IPv4, IPs are becoming increasingly difficult to come by, and in some cases, increasingly expensive. However, in most instances, this is not a drawback. Servers are perfectly capable of hosting multiple websites on one IP address, as they have for years.
Reading Time: < 1 minuteEditing your \etc\hosts file is a common task for troubleshooting issues or for developing a site that you aren’t quite ready to launch. By editing this file, you’ll be able to bypass DNS to view a site at a declared IP address.
In Windows 10, your hosts’ file is located at: C:\Windows\System32\drivers\etc\hosts. You will need to edit the file with administrative privileges.
- Click the Windows button and type Notepad in the search bar.
- Right click on Notepad and then Run as Administrator.
- You’ll be asked, “Do you want to allow this app to make changes to your device?”.
- In Notepad, choose File then Open
- Navigate to C:\Windows\System32\drivers\etc\hosts or click the address bar at the top and paste in the path and choose Enter. If you don’t readily see the host file in the /etc directory then select All files from the File name: drop-down list, then click on the hosts file.
- Add the appropriate IP and hostname at the end of your hosts’ file, select save and close the file.
- Finally, you will want to flush your DNS cache for your computer to recognize changes to the file. Click the Windows button and search command prompt.
- Right-click on Notepad and then Run as Administrator.
- You’ll be asked, “Do you want to allow this app to make changes to your device?”.
- Type the following command in the terminal and press Enter
Reading Time: 2 minutesYou may find the “can’t resolve hostname” or “temporary failure in name resolution” error when using retrieval command like wget, cURL, ping or nslookup. There are many reasons why these commands can cause an error, including file corruption. For the sake of brevity, we look towards commonalities between these commands to solve the issue.
These commands connect to the Internet using gateways to communicate and provide information. If the connection from your local machine, in this case, a CentOS server, is disconnected you’ll likely run into issues trying to access the world wide web. In this troubleshooting tutorial, we’ll show you some common solutions to connectivity issues.
Step 1: Amongst many other configuration tasks, the resolv.conf file is used to resolve DNS requests. Manually editing the resolv.conf file to configure name resolution will only do so temporarily. The Network Manager controls this essential /etc/resolv.conf file to create permanent changes. So, we’ll first stop and disable the Network Manager:
chkconfig NetworkManager off; service NetworkManager stop
Step 2: The method for permanent changes is to edit the /etc/sysconfig/network-scripts/ifcfg-eth0 file instead of resolv.conf file. Open the file:
Next, we’ll set our DNS IP’s to use Google’s Public DNS (188.8.131.52 & 184.108.40.206).
Save and quit the file using ESC and :wq.
Step 3: Enable and restart your network, using the commands associated with your server version.
CentOS 6, CloudLinux 6, RHEL 6:
chkconfig network on
service network start
CentOS 7, CloudLinux 7, RHEL 7:
systemctl enable network.service
systemctl start network.service
Step 4: Test the reachability of a host by using ping, curl, wget or any testing tool of your choice. In our example, we’ve successfully ping’d Google!
PING google.com (220.127.116.11) 56(84) bytes of data.
64 bytes from lga15s46-in-f14.1e100.net (18.104.22.168): icmp_seq=1 ttl=57 time=6.65 ms
64 bytes from lga15s46-in-f14.1e100.net (22.214.171.124): icmp_seq=2 ttl=57 time=6.68 ms
64 bytes from lga15s46-in-f14.1e100.net (126.96.36.199): icmp_seq=3 ttl=57 time=6.68 ms
You don’t have to rack your brain over connectivity issues! Liquid Web customers enjoy 24/7 support for our Managed products. Our knowledgable team of support techs have experience with solving errors of this nature. Access our support team through a ticket, chat or phone call!