Joseph Matino
  • Servers
  • Web Dev
  • Gaming
    • PC Gaming
  • Guides
  • Security
Font ResizerAa
Joseph MatinoJoseph Matino
Font ResizerAa
Search
  • Servers
  • Web Dev
  • Gaming
    • PC Gaming
  • Guides
  • Security
Almalinux Server Unreachable After Cpanel Install And Reboot

AlmaLinux Server Unreachable After cPanel install and Reboot

Joseph Matino Joseph Matino 8 months ago
FacebookLike
InstagramFollow
YoutubeSubscribe
TiktokFollow
Follow US
  • Terms & Conditions
  • Privacy Policy
  • Contact
© Joseph Matino. All Rights Reserved.

Home – Blog – Security

Setting Up An Apache Reverse Proxy For cPanel And WHM – Worthy?

Joseph Matino
Last updated: July 6, 2024 8:39 am
By Joseph Matino
Setting Up An Apache Reverse Proxy For Cpanel And Whm - Worthy?

I’ve been exploring the effectiveness of the Apache Reverse Proxy for cPanel and WHM for a while now. After experimenting with various setups, I’m ready to share my findings and address the real question: Is it truly worth it?

But before we decide on its value, we first need to understand how an Apache Reverse Proxy works with these platforms.

Article Content
How Apache Reverse Proxy Works with WHM And cPanelHow To Set Up Apache Reverse Proxy For cPanel And WHM AccessStep 5: Restart ApacheStep 6: Verify the ConfigurationSo is Apache Reverse Proxy for cpanel and whm worthy?

How Apache Reverse Proxy Works with WHM And cPanel

Apache Reverse Proxy acts as an intermediary for requests from clients seeking resources from servers that host platforms like cPanel and WHM. It takes requests from users and forwards them to the server that runs your website or management tools.

Here are four key advantages of using a reverse proxy:

1. Easier to Remember and Use

Normally, to use cPanel or WHM, you need to remember and type in port numbers and the website address. A reverse proxy lets you skip the port numbers. For WHM, don’t type something complicated like “example.com:2087”. Just type “example.com/whm”. It’s much simpler and easier to remember.

2. Better Security

When you visit websites, there is a technology called SSL/TLS. It helps keep your information safe. SSL/TLS turns “http” into “https” in your browser’s address bar.

This change shows that your connection is secure. A reverse proxy can make cPanel and WHM use this security technology better. It acts like a shield, adding extra protection. This makes it harder for unwanted visitors to see the data between your computer and your server.

3. Faster and Smoother Experience

A reverse proxy can make your cPanel and WHM run smoother and faster. It can save (or “cache”) parts of your sites that don’t change often. This means when someone visits your site, the reverse proxy can show these saved parts.

It won’t have to ask the server again, which can speed things up. Also, it can handle the SSL/TLS security stuff itself, taking some work off your server’s shoulders. This can speed up everything. It will make loading your website and accessing your cPanel or WHM faster.

How To Set Up Apache Reverse Proxy For cPanel And WHM Access

Step 1: Log into WHM

Apache Reverse Proxy For Cpanel And Whm

To access your WHM interface, go to https://yourserver.example.com:2087 in your web browser. Replace yourserver.example.com with your actual server’s domain or IP address.

Step 2: Open Apache Include Editor

Apache Reverse Proxy For Cpanel And Whm

In WHM, find the “Service Configuration” section. Click on “Apache Configuration” and select “Include Editor.” This tool lets you safely change your Apache setup.

Step 3: Edit Pre VirtualHost Include

Apache Reverse Proxy For Cpanel And Whm

Choose to edit the “Pre VirtualHost Include” for Apache 2.4. This section lets you add directives. They apply globally. They affect all virtual hosts on your server.

Step 4: Add Reverse Proxy Configuration

In the editor, paste the following configuration, customizing domain names and paths as necessary:

SSLProxyEngine On
SSLProxyVerify none
SSLProxyCheckPeerCN off
SSLProxyCheckPeerName off
SSLProxyCheckPeerExpire off

# Reverse proxy setup for WHM
ProxyPass /whm https://yourdomain.com:2087/
ProxyPassReverse /whm https://yourdomain.com:2087/

# Reverse proxy setup for cPanel
ProxyPass /cpanel https://yourdomain.com:2083/
ProxyPassReverse /cpanel https://yourdomain.com:2083/

This configuration directs traffic from yourdomain.com/ whm to WHM and yourdomain.com/cpanel to cPanel, without exposing port numbers.

Once you’ve entered all the necessary settings, make sure to save your changes. You’ll then see a prompt from WHM asking you to restart Apache. This is to make sure the new settings take effect.

Step 5: Restart Apache

When WHM asks you to confirm, go ahead and restart Apache. This is a crucial step to ensure that your Apache server is now running with the new reverse proxy configuration.

Step 6: Verify the Configuration

To make sure everything is set up correctly, visit yourdomain.com/cpanel and yourdomain.com/whm. Both pages should open properly, showing their respective interfaces without including port numbers in the URLs.

So is Apache Reverse Proxy for cpanel and whm worthy?

Considering the advantages Apache Reverse Proxy offers, such as simplified access, enhanced security, improved performance, and effective load balancing, using an Apache Reverse Proxy with cPanel and WHM seems worthwhile for many scenarios.

However, it’s important to note some limitations. In practical terms, while I found the proxy exceptionally useful for general web management, it struggled with specific tasks like accessing email through cPanel’s default port 2096. This indicates that not all server functions are ideally suited for this setup.

cPanel and WHM also support NGINX as a reverse proxy, which can similarly improve traffic redirection and server efficiency. Both systems have their strengths, and choosing between them might depend on your particular needs and the specific challenges you face in your server environment.

Have you experimented with reverse proxies and faced challenges with certain ports or found effective solutions? Please share your experiences in the comments below.

Share This Article
Facebook Twitter Whatsapp Whatsapp Reddit Copy Link
Joseph Matino
By Joseph Matino
Follow:
I'm a full-stack web developer from Nairobi, Kenya, with over six years of experience. My expertise lies in WordPress development, server management, and web security, with a focus on optimizing WordPress site performance and transforming them into apps. I also write about tech topics in web development, server management, and PC gaming. Outside of work, you’ll find me immersed in gaming.
2 Comments 2 Comments
Subscribe
Notify of
guest
guest
2 Comments
Most Voted
Newest Oldest
Inline Feedbacks
View all comments

What's New

10 Common Cloud-init Issues On Ubuntu: How To Fix

Servers 8 months ago

Top 14 Best Game Development Frameworks in 2024

Gaming 8 months ago

How to forward Calls and Messages On Safaricom Effectively

Networking 9 months ago

You Might also Like

How To Protect Cyberpanel From Syn Flood And Crypto Mining Attacks

How To Secure CyberPanel From Recent Cyber Attacks

Recently, over 22,000 CyberPanel servers faced serious attacks. This guide shows how to protect your…

Joseph Matino 6 months ago
How To Secure Your Php Website From Hackers

How To Secure Your PHP Website from Hackers: 7 Best Ways

Before launching your PHP project, whether you have purchased a PHP script or developed your…

Joseph Matino 8 months ago
Best 2Fa App

10 Best Two-Factor Authentication Apps Of 2024: Updated

Security breaches are increasingly common in 2024, making it more important than ever to protect…

Joseph Matino 8 months ago
joseph matino logo

As a passionate full-stack developer, I bring my A++ game to WordPress, server management, web optimization, and converting websites to apps, ensuring your sites are secure and shine online. Outside of work, I enjoy gaming, where every level beaten is a new skill learned.

Quicklinks

  • Terms & Conditions
  • Privacy Policy
  • Cookie Policy
  • Contact
  • About
Hire Me

Connect

Follow Me
wpDiscuz
Joseph Matino
Manage your privacy

To provide the best experiences, we and our partners use technologies like cookies to store and/or access device information. Consenting to these technologies will allow us and our partners to process personal data such as browsing behavior or unique IDs on this site and show (non-) personalized ads. Not consenting or withdrawing consent, may adversely affect certain features and functions.

Click below to consent to the above or make granular choices. Your choices will be applied to this site only. You can change your settings at any time, including withdrawing your consent, by using the toggles on the Cookie Policy, or by clicking on the manage consent button at the bottom of the screen.

Functional Always active
The technical storage or access is strictly necessary for the legitimate purpose of enabling the use of a specific service explicitly requested by the subscriber or user, or for the sole purpose of carrying out the transmission of a communication over an electronic communications network.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
The technical storage or access that is used exclusively for statistical purposes. The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
The technical storage or access is required to create user profiles to send advertising, or to track the user on a website or across several websites for similar marketing purposes.
Statistics

Marketing

Features
Always active

Always active
Manage options Manage services Manage {vendor_count} vendors Read more about these purposes
Manage options
{title} {title} {title}
Joseph Matino
Manage your privacy

I use cookies and similar technologies to enhance your experience on this site. By consenting, you allow me to process data like your browsing behavior and unique IDs. If you choose not to consent or later withdraw your consent, some features of the site may not function properly.

Functional Always active
The technical storage or access is strictly necessary for the legitimate purpose of enabling the use of a specific service explicitly requested by the subscriber or user, or for the sole purpose of carrying out the transmission of a communication over an electronic communications network.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
The technical storage or access that is used exclusively for statistical purposes. The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
The technical storage or access is required to create user profiles to send advertising, or to track the user on a website or across several websites for similar marketing purposes.
Statistics

Marketing

Features
Always active

Always active
Manage options Manage services Manage {vendor_count} vendors Read more about these purposes
Manage options
{title} {title} {title}