Questions tagged [cpanel]

cPanel stands out as a user-friendly Linux-based web hosting control panel designed to streamline website and server management for both website owners and hosting providers. Loaded with an array of useful features including email and file management, backup options, security controls, and domain management tools. Please note that only questions related to programming are welcome here – general configuration queries will be off-topic.

Guide to hosting an expressjs application on shared cpanel hosting platform

I'm encountering an issue while attempting to deploy my basic express application on shared hosting cpanel. Whenever I try to access my app, it displays Cannot GET /apps/api/. Check out the screenshot of my setup below:- https://i.stack.imgur.com/cWYW ...

The cPanel Node.js application is experiencing difficulties connecting to the MongoDB Atlas cluster, yet it functions without any issues on

Having developed a website using Node.js with MongoDB Atlas as the database, I encountered no issues while testing it on Heroku. However, after purchasing my domain and switching to proper hosting, I faced challenges. I attempted to set up my website by c ...

The mysqli::real_connect() function encountered an error with the code (HY000/2002) while trying to

After successfully running on cpanel, I encountered an error when hosting my Codeignitor application on Plesk. The error message is shown in the following link: Here is a snippet of my databse.php configuration: $db['default'] = array( &apo ...

Guide on launching a NodeJS Express API using PM2 on a cPanel shared hosting server

I have set up an API using Express configured to run on PM2 instead of the node process. Currently, I am using ventraIP shared hosting with cPanel. The cPanel provides options to set up a NodeJS app, configure directories, perform npm installs, and use us ...

The proper way to add an addon domain using CPanel

After successfully deploying a laravel project named websiteA to the server using CPanel and transferring all public files to public_html, everything seems to be working fine. The directory structure now looks like this: /home/tuturu ->public_html ...

Executing a Codeigniter PHP function within a controller using Cron Jobs on cPanel every hour

Is it possible to run a PHP function in the controller every hour using cPanel Cron Jobs? During testing, I have decided to execute this function every minute. An example implementation is shown below: class Mycontroller extends CI_Controller { pu ...

The custom 404 error pages seem to be malfunctioning in subfolders - they are only working at the root level. Assistance is needed

Having trouble with custom 404 pages not working in subfolders? They seem to only work at the root level. Can anyone offer some assistance? For example, will display the custom 404 page as expected. However, won't show the custom 404 page, but rat ...

Having trouble uploading images to the public_html folder in my Laravel Project

After attempting to upload an image on my website, I noticed that it is stored in the storage folder but the symlink fails to save it in the public_html folder. Even after trying a custom symlink PHP file, the issue persists. Here is my symlinkcreate.php ...

Encountering 404 Errors while Attempting to Reach API Endpoint in an Express.js Application Hosted on cPanel

I have a Node.js application running on cPanel, and I'm facing 404 errors when trying to access an API endpoint within my app. Let me provide you with the setup details: Directory Structure: public_html/ server.mjs index.html node_modules ...

Installing a Node.js Application on HostGator VPS Using cPanel and PM2

After setting up a basic Node.js application and purchasing a HostGator VPS with WHM, I proceeded to install Node.js, Apache, and other necessary components on the VPS. In cPanel, I configured version 12 of Node.js and utilized PM2 to run the application. ...

What is causing the issue of my oversized images not showing up on GoDaddy?

I recently uploaded my website on GoDaddy and I am facing an issue where some of my small images (sizes: 872 × 546px) are displaying perfectly fine, but the large ones (banners with a size of 2700 × 900px) aren't showing up. Does anyone have ...

I am confused about why this error is appearing so unclear: npm ERR code Unknown system error -122npm ERR

My Next.js project runs perfectly on my local machine, but when I tried to run `npm install` on cpanel, I encountered some unclear errors: npm ERR! code Unknown system error -122npm ERR! syscall writenpm ERR! errno -122npm ERR! Unknown system error -122: U ...

The module 'express' is nowhere to be found according to the nodejs.log file

I am facing an issue with my React and Node.js project hosted on 'O2Switch'. While my React part is functioning properly, I am experiencing a white page on the URL due to my node not responding. However, it works fine on localhost. The error "C ...

Scripting method to transfer multiple subdirectories using a cpanel.yml file (excluding the use of the wildcard)

I have been referring to the documentation found at My current issue is that when I try to copy my subfolders, it doesn't work properly unless I use a workaround. The only way I am able to achieve the desired outcome is by utilizing the following co ...

Error: npm command is not recognized in the cPanel Terminal

When I attempt to write the following command: $ /usr/local/bin/node -v 14.17.3 I receive an error when using this command: $ node -v bash: node: command not found I tried the same approach with different commands, but it was unsuccessful: $ /usr/local/b ...

unable to deploy nestjs application on cpanel hosting

I encountered an issue while trying to deploy my Nestjs project to hosting. The error message I received was: returncode: 1 stdout: [email protected] start:prod /home/enebbvmz/server/dist node main.js stderr: /home/enebbvmz/nodevenv/server/dist/ ...

What is the most optimal method for deploying a Next.js App that incorporates Prisma with MySQL integration?

After successfully building a Nextjs App and validating the idea, I encountered difficulties when attempting to deploy it. Despite everything working fine on my local machine, the deployment process proved challenging. Can anyone recommend the most cost-e ...

Encountering an internal server error when using Next.js API routes with Nodemailer

Using cPanel to host my Next.js website, I encountered an issue with an API route that uses Nodemailer to send messages. While the route works perfectly fine on localhost and Vercel, every time I call it on the live server, I receive an internal server err ...

Encountering HTTP Status 404 - 502.shtml ErrorMessage indicating the desired resource is unavailable during the file upload process

Encountering an error while using a servlet that I've developed. The war file is deployed on Tomcat version 7.0.39 which is installed on cPanel. The servlet was compiled and tested on my local machine without any issues. Seems like there might be a co ...

Tips for creating a React JS static site on a cPanel hosting account

After creating my React JS app with create-react-app configurations, everything was running smoothly in the development build of React. I used the npm build command to generate a build folder for my static (server-less) webpage. Now, my question is how d ...

Leveraging PHP for transferring files from one cPanel account to another on the same server

Our server was recently upgraded to cPanel 78 and migrated from EA3 to EA4. With only two sites on the server, we were able to use PHP scripts for file manipulation prior to the upgrade. One specific functionality involved copying files between the two sit ...

Tips for launching a Next.js application on cPanel

These were the steps I took to successfully deploy my nextjs on cPanel: First, I added this line to package.json: "homepage": "http://afsanefadaei.ir" Next, I ran next build to generate the .next folder as my build directory I then navigated to cpa ...

The address :::3000 is already in use by NestJS

While attempting to deploy my NestJs server on a C-Panel hosting, I have encountered an issue. Despite properly installing all node_modules and ensuring every project file is in place, the server fails to start and continuously displays the following error ...

What is the process of sending an HTTP/HTTPS request from a Node.js server?

Currently diving into the world of Node.js, I am experimenting with using a Node.js Application on cPanel to generate a JSON response upon accessing its URL. Upon visiting the app's URL, it seems that the Node.js server is functioning correctly. Afte ...

Error with Cross-Origin Resource Sharing (CORS) on my website

During the development of a website, I disabled web security in order to bypass CORS using the command chrome.exe --disable-web-security --user-data-dir=/path/to/foo However, after successfully completing the website and uploading it to my domain, I enco ...

Discover the steps to redirect a www to a non-www Next.js app on a cPanel hosting account using an Apache

After successfully deploying my next.js app to cpanel as a standalone build, I encountered an issue where everything works properly when accessing my domain without the www prefix like this: example.com. However, if I try to access it with the www prefix l ...

Guide for adding Oracle Client library to cPanel

I have created a Python application via cPanel and configured the database to connect with Oracle DB on AWS. The application runs perfectly on localhost, but when hosted, I encountered an error stating that the Oracle Client library is missing: Oracle Cli ...

Error in CPanel: NextJS Static Export is failing to load due to missing JS chunks, CSS, and SVG files

Recently, I have discovered that when using VSCode Live server to host static files locally, everything seems to work perfectly. This led me to believe that the issue may lie in how CPanel deals with static files. Could it be causing the 404 not found erro ...

Guide to modifying WordPress version 4.5 with HTML pages

I am encountering issues with my Wordpress website. I have installed it on Softcald in cPanel and now I want to edit my Wordpress using HTML. However, I am having trouble finding the editing option. My Wordpress version is 4.5 and I have searched online ...

Production environment is triggering a 404 error on NodeJs routes, while the same routes are not

I am currently developing my first NodeJS application. After testing it in a local environment with success, I have decided to deploy it on my shared hosting. However, I am encountering an issue with a router that is returning a 404 error in the productio ...

Facing challenges in PHP with setting headers and sending emails via cPanel

For PHP, I'm struggling to set the header for the from address and have tried various options: The correct code is provided below, but it doesn't seem to be attached to the header. Although the code appears to be default from, it doesn't c ...

The Cpanel encounter a PHP Fatal error due to an unknown function `json_decode()`

Despite having the php 5.6 version, I am still encountering this error. While running a codeigniter project through Cpanel, the following error occurred: PHP Fatal error: Call to undefined function json_decode() in/home/ntn/public_html/application/cont ...

Error on the Php server: Access Denied - You Lack the Necessary Permissions to View this Page

Greetings everyone, I have dedicated a significant amount of time trying to resolve this issue but unfortunately, I have not been able to find a solution either online or on platforms like Stack Overflow. While there are numerous answers available regardin ...

Scrubbing the htaccess file for custom redirect rules in cPanel

I am looking to optimize my .htaccess file for the following purposes: Removing the .html extension Redirecting non-www URLs to www Forcing HTTP to HTTPS Changing .com/index.html to .com/ Implementing all redirects through cPanel's 'Redirects&a ...

Setting up NGINX (Engintron) for Node.js on a particular port to switch from HTTPS to HTTP

I am completely new to web server configurations and have been struggling to find a working setup for weeks. Any advice or comments would be greatly appreciated! I currently have a CentOS machine with cPanel (EasyApache running on ports 8080 and 8443) and ...

How does cPanel go about setting up user accounts?

Is there a way to programmatically create websites/accounts on a server without using cPanel, such as through node.js or PHP? How does cPanel handle this process? I understand that websites are typically generated by making changes to the Apache configura ...

Daday's Hosting CPanel encountered an error with the code: 'ER_ACCESS_DENIED_ERROR', error number: 1045, SQL state: '28000', and stack trace displaying: 'Error: Access denied for user 'UserName'@'IP address'

Important Note: Please read the full question before marking it as a duplicate. Error :- 'Access denied for user 'Test_UG'@'88.81.84.184' (using password: YES)', code: 'ER_ACCESS_DENIED_ERROR', errno: 1045, sqlStat ...

Navigating dynamic URLs with various URI segments in cPanel

<a href="www.mysite.com/index.php?information/adminpanel/<?php echo $id;?>" name="approve" id="approve" ">Approve >></a> After redirecting to the specified URL, the correct ID is displayed in the address bar but unfortunately, ...

The Python/Selenium-webdriver combination may encounter compatibility issues when used on cloudlinux x86 64bit with cPanel

My code is functioning perfectly on my local Windows 10 machine with Python 3.12. However, when I try to deploy it to a Linux server running Python 3.11.5, I encounter the following exception: Service /home/project/.cache/selenium/chromedriver/linux64/119 ...

Error: The host is experiencing an AttributeError because the 'Service' object does not have the attribute 'process' available

Looking to scrape a website using Python on a host without GUI. Unfortunately, the webpage I want to scrape ( ) does not allow scraping with the requests library, so I have to resort to using Selenium with a headless webdriver. (Apologies for any language ...

Setting up a Cron Job in cPanel to Automate Task Scheduling in Laravel

Just like the title suggests, I followed the documentation to set up a cron job but it's not working. There are no updates in the laravel.log file either, which could have provided some insight. Here is how I configured my cron job: https://i.stack.i ...

How to execute a PHP script with a cron job in CPanel

Can you confirm if the syntax below is correct for running a PHP script using a cron job in CPanel? /usr/bin/php -q /home/username/public_html/cron/cron.php >/dev/null I have not received any email notifications indicating that a cron job has been com ...

The URL you are trying to access cannot be found on this server. The issue seems to be with the cpanel while hosting the

Hello fellow Developers, I recently added a homepage to my package.json file and went through the process of building, zipping, uploading, and unzipping it in the public_html folder on cpanel. After removing all files except those in the build folder, my ...

Unable to construct with cPanel or SSH due to Laravel and Vue integration

Working on my cPanel server with ssh access, I downloaded new changes/files using Git and then executed npm run build. To my surprise, an error popped up. https://i.stack.imgur.com/JaUDG.png Any ideas on how to resolve this error? I double-checked the f ...

Error 503 on NameCheap during Python Setup - Can't Access Service

Hello, I recently joined NameCheap and I could use some assistance with deploying a Django application. I attempted to install Python on Namecheap's Cpanel using Python 3.7.12 along with the desired Application URL, but unfortunately, I encountered an ...

cPanel is incompatible with node version 12.16.0

I am facing a dilemma regarding hosting my node API, which was built using node version 12.16.0, on cPanel. The available version for node in cPanel is 12.9.0 (Most recent). How should I proceed? Is the node version really a critical factor in this case? ...

When attempting to host a Node.js application on a GoDaddy server, all ports experienced timeouts

I am having issues running my nodejs/expressjs application on my godaddy server as every port I try to use times out. Interestingly, the application works perfectly fine on my local device. Below is a snippet of my connection code: var app = express(); a ...

I am encountering difficulties accessing the cPanel URL following deployment on Vercel

Running into some challenges while hosting my Next.js 13 application on cPanel led me to an alternative solution I discovered online. The workaround involved deploying the application on Vercel and adjusting the DNS records in cPanel to direct traffic to ...

You may encounter an error in cpanel due to the include path being set to '.:/opt/cpanel/ea-php70/root/usr/share/pear'

While testing my PHP application on WampServer (localhost), everything worked perfectly. However, when I uploaded the same application to my web server, I encountered the following issue: PHP Fatal error: require_once(): Failed opening required 'util ...

Setting up a Node.js WebSocket server on a shared cPanel hosting environment

Recently, I obtained a shared hosting plan with cPanel support for nodejs applications. Through the "Setup Node.js App" feature, I am able to define and set up a node.js app on my server. My goal is to create a websocket, and fortunately, they have opened ...

What is the best way to prevent caching of pages that are using a local JSON file in Next.js static generation?

After deploying my Next.js app as static on my cPanel traditional hosting, I encountered an issue. Some pages are consuming a local JSON file that I fetch using getStaticProps, with the "revalidate" option set. However, when I make edits to the JSON file ...

503 Service Unavailable. Unfortunately, the server is currently occupied and unable to process your request. Please try again at a later time

I am encountering an issue while trying to deploy my next.js project on cPanel. I have developed a web application using Node.js and installed npm. However, when attempting to access my website, I am receiving a "503 Service Unavailable" error message. Th ...

Discovering and Monitoring Viruses on a WordPress Website

My dedicated server is set up with WHM/cPanel CentOS Apache. One of the accounts on cPanel is hosting a WordPress site that has been infected with a virus. This virus is being used to send emails and inject affiliate links without authorization. Despite ...

Guide to Setting up Next.js 13 Application with HTTPS on cPanel

I am facing an issue trying to host my nextjs app on https in cpanel, it doesn't seem to work! However, everything runs smoothly on http without any problems. The SSL certificate is installed on the domain in cPanel and is valid. Below is the server. ...

Is it possible to retrieve the overall size of all emails stored in a user's account using PHP and cPanel?

Is there a way in PHP to determine the amount of storage that email accounts occupy on a cPanel server? If not using PHP, is there another method to achieve this and display it on a website? I have code for calculating disk usage in a directory, but I&ap ...

Excessive CPU Usage Caused by MySQL

As a complete beginner in server administration, I must admit that I am quite puzzled by the high percentage of maximum CPU usage shown in my WHM daily process log (160%, equivalent to 1.6 fully utilized cores). /usr/sbin/mysqld --basedir/usr --datadir/va ...

Unable to acquire lock for the application "app" in cPanel for Node.js

I encountered an issue while trying to deploy my node.js app. I have created and installed modules using the cPanel interface, but when running the script, I received an error message stating: "Can't acquire lock for app: app." Does anyone have any su ...

What might be causing the 404 Error to appear on the mobile version of my website?

Currently, I am in the process of developing a static website using HTML, CSS, and Javascript. To add on-scroll animation effects, I have incorporated a plugin known as AOS. In addition, I have included Bootstrap in my project which was installed through n ...

What could be causing Node Mailer to struggle with sending emails on a private host when it performs perfectly on localhost and render?

I am encountering an issue with sending emails to my clients using nodemailer. I am on a shared hosting with cpanel and it is not able to send emails, whereas it works fine on other hosts. Below is the function responsible for sending emails in my code: c ...

I am attempting to upload my Next.js project, however,

When I uploaded my files to my domain and entered the domain in browsers, it only displayed the files. Now, I want to upload a Next.js project to Cpanel. Although I have created a Node.js server, I am unable to find any files for apps or server.js within ...

The file you have attempted to upload is too large and has exceeded the limit set by the upload_max_filesize

We recently switched our shared hosting from GoDaddy's Linux hosting to the new cPanel hosting. While trying to transfer my websites, I encountered an issue with uploading new media on Wordpress sites. Every time I attempt to upload new media, I rece ...

CPanel scheduled task (invalid command)

I'm attempting to schedule a cron job that runs a URL every 5 minutes with the following command: */5 * * * * curl http://ur-views.com/gramlater/queue_processor.php` However, I encountered an error while trying to execute it. Here's a screensho ...

Using Laravel on CPanel is successful, but running it on localhost without using Artisan is not

After installing Laravel 8 on my remote server using Softaculous, I set the document root in CPanel to the Laravel\public folder so that I could access the app directly without having to run 'php artisan serve' like I do on my local machine. ...

Error: The WebAssembly instantiation failed due to memory exhaustion in wasm allocation

Upon attempting to initiate my node js app in cpanel, I encountered the following error: RangeError: WebAssembly.instantiate(): Out of memory: wasm memory at internal/deps/cjs-module-lexer/dist/lexer.js:1:33573 Interestingly, when working on localhost, ev ...

cPanel Deployment: The exposed app.js code is now visible to all users

Recently, I created a small application on a hosted server using cPanel. The app was built with node js, express, and mysql. However, I realized that when the app is running through node or forever, it is only accessible if the port number is added to the ...

Unable to generate a database using coding, but can easily do so through cPanel

An issue has been encountered where the database test_new_1 can be created for the user testcom directly from the cpanel, but not through php. Interestingly, it works fine on another server with the only difference being that the username and database pref ...

NodeJS on Cloudlinux requires that the node modules for applications be stored in a distinct folder (virtual environment) designated by a symbolic link known as "node_modules"

I recently encountered an issue while trying to deploy my Nodejs/TypeScript web application on my cpanel shared hosting. The error I received stated: * Cloudlinux NodeJS Selector requires the node modules for the application to be stored in a separate f ...

Utilizing environmental variables with cPanel in Node.js

Currently, I am utilizing cPanel in combination with the Setup Node.js App plugin to run a Next.js application. (Please don't inquire about my choice of cPanel) During development, everything seems to be functioning correctly except for the handling ...

The hyperlink tag doesn't respond to clicks in Safari, yet functions properly in all other web browsers

I'm encountering an issue with my header drop-down menu in Safari—it works perfectly in Chrome, but when I try to open the drop-down menu in Safari, it's unresponsive. Clicking on it does nothing, preventing me from accessing other drop-downs. ...

Unlock the contents of a directory using a .htaccess file

My directory setup looks something like this: www.examplelink.com/angular/dist/my-app. I need to reach this directory when going to the link : www.examplelink.com/angular. What would be the best way to achieve this using htaccess? ...

When working with Codeigniter on localhost, everything runs smoothly. However, as soon as I upload the project to a live server, I encounter an error saying "database.php does not exist". I am using linux cPanel

I've scoured stackoverflow and searched all over Google for an answer to this issue, but I'm coming up empty-handed. While I suspect I know what the problem is, I'm at a loss for how to solve it. Here's a snippet of my codeigniter ind ...

None of the proposed solutions are successful in addressing the issue of "Class 'PDO' not being found."

Although there are questions with similar titles on this platform, none of them seem to provide a solution that works for me. That's why I'm creating a new question. Here's the issue: I have a website that functions perfectly on localhost w ...

The Express JS application is encountering a "cannot find" error after being deployed on cPanel, despite functioning properly on

After deploying my Express App on cPanel, I am facing an issue where it shows "cannot find" error. I have tried to troubleshoot this problem and noticed that when I use server.listen() it works perfectly fine. However, when I use app.listen() it gives me t ...

After deploying my next.js app on cPanel, it suddenly displays a blank screen

I recently deployed my Next.js app on cPanel and encountered a blank screen issue, although it works perfectly fine when tested locally. Here's the detailed process I followed: 1. To begin with, I created a custom server.js file in the root directory ...

Establish a connection between the MySql database in WHM (phpmyadmin) and a node.js application

Our team has been working on setting up the database connection with Mysql using node.js in Cpanel. Although I didn't create the database myself, I have all the necessary information such as the host, user, password, name of the database, and port nu ...