Yearly Archive February 22, 2019

ByJUJU-dev

What is SSH?

What is SSH?

What is SSH?

Secure Shell or SSH is a network protocol that allows data to be exchanged using a secure channel between two networked devices. The two major versions of the protocol are SSH-1 and SSH-2.

Shell is a program to log into another computer over a network to execute commands on a remote machine and to move files from one machine to another. It provides strong authentication and secure communications over insecure channels.

SSH was designed as a replacement for Telnet and other insecure remote shells (rlogin, rsh, rcp, and rdist), which send information, notably passwords, in plain text, rendering them susceptible to packet analysis. The encryption used by SSH is intended to provide confidentiality and integrity of data over an unsecured network, such as the Internet.

ByJUJU-dev

How to create and maintain MySQL Databases in cPanel

cPanel is a popular web hosting control panel that provides an intuitive interface for managing various aspects of your website, including MySQL databases. Here’s a step-by-step guide on how to create and maintain MySQL databases in cPanel:

Creating a MySQL Database:

  1. Log in to your cPanel account.
  2. In the “Databases” section, click on the “MySQL Databases” icon.
  3. Click on the “Create a New Database” button.
  4. Enter a name for your database in the “Database Name” field.
  5. Choose a prefix for the database (optional, but recommended for organization).
  6. Set a password for the database (or choose to use a randomly generated one).
  7. Click the “Create Database” button.

Managing Existing Databases:

  1. In the “Databases” section, click on the “MySQL Databases” icon.
  2. You will see a list of existing databases on your account.
  3. Click on the name of the database you want to manage.
  4. You can view detailed information about the database, including its size, owner, and creation date.
  5. Use the buttons at the top of the page to perform actions such as:
    • “Edit Privileges”: Change the database user password or add/remove users.
    • “Backup”: Create a backup of the database.
    • “Drop”: Delete the database.

Managing Users and Privileges:

  1. In the “Databases” section, click on the “MySQL Users” icon.
  2. You will see a list of existing MySQL users on your account.
  3. Click on the name of the user you want to manage.
  4. Use the buttons at the top of the page to perform actions such as:
    • “Reset Password”: Change the user’s password.
    • “Grant Privileges”: Grant or revoke privileges for specific databases or tables.
    • “Revoke Privileges”: Revoke all privileges for the user.

Backing Up and Restoring Databases:

  1. In the “Databases” section, click on the “Backups” icon.
  2. Click on the “Download” button next to your desired backup date to download a copy of your database.
  3. To restore a backup, click on the “Restore” button and select the backup file you want to restore.

Additional Tips:

  • cPanel provides a built-in tool called phpMyAdmin, which allows you to manage your databases using a web-based interface. You can access phpMyAdmin by clicking on the “phpMyAdmin” icon in your cPanel dashboard.
  • It’s essential to regularly back up your databases to prevent data loss in case of unexpected issues or security breaches.
  • Be cautious when granting privileges to MySQL users, as this can compromise your database security.

By following these steps, you should be able to create and manage your MySQL databases efficiently using cPanel.

ByJUJU-dev

How to access a hosting account via SSH

How to access a hosting account via SSH

To access your hosting account via SSH, you should:

1. Enable SSH access for your account in your web hosting panel.

2. Open your SSH client, put your domain name or the IP address of the server into the Host Name field (you can also use server name here, you can check it using this tutorial), enter 21098 into the Port field (22 for a VPS/Dedicated server), choose SSH as your connection type and press the Open button:

How to access a hosting account via SSH

3. You will receive the Putty Security Alert. Press OK:

How to access a hosting account via SSH

4. When prompted, enter your cPanel username and password (when you enter the password, it is automatically hidden for the security purposes):

That’s it!

ByJUJU-dev

How to use Manage Shell in cPanel

How to use Manage Shell in cPanel

Secure Shell (SSH) is a cryptographic network protocol that is used to log into the system via a secure channel. With the help of SSH, you can safely exchange data between two devices. For more detailed information, visit here.

Enabling SSH access allows for:

  • Remote hosting control
  • The ability to add, remove, edit, backup and restore hosting files and directories
  • The easy import and export of your database
  • An established connection between 2 different servers

However, there are some downsides with enabling SSH:

  • More difficult to use than a web interface
  • Increased security risks

 

The Manage Shell plugin provided by Namecheap allows you to enable or disable SSH access for your respective hosting accounts with just a few clicks.

For cPanel Basic Theme:

Firstly, locate the Manage Shell plugin from your cPanel:
cPanel >> the Exclusive for Namecheap Customers section >> Manage Shell:

How to use Manage Shell in cPanel - Cheap VPS

By default, SSH access is disabled for hosting accounts.

How to use Manage Shell in cPanel - Cheap VPS

There are 3 options related to enabling SSH keys:

  • Managing SSH keys
  • Generating a new key
  • Importing a key

All these options will take you to the SSH Access menu in your cPanel. Detailed instructions can be found in this guide.

To enable SSH, turn the toggle button on. After it has been enabled, you will then see how you can manage your SSH.

How to use Manage Shell in cPanel - Cheap VPS

Feel free to explore more about SSH clients here.

For cPanel Retro Theme:

Firstly, locate the Manage Shell plugin from your cPanel:
cPanel >> the Exclusive for Namecheap Customers section >> Manage Shell:

How to use Manage Shell in cPanel - Cheap VPS

By default, SSH access is disabled for hosting accounts.

How to use Manage Shell in cPanel - Cheap VPS

There are 3 options related to enabling SSH keys:

  • Managing SSH keys
  • Generating a new key
  • Importing a key

All these options will take you to the SSH Access menu in your cPanel. Detailed instructions can be found in this guide.

To enable SSH, turn the toggle button on. After it has been enabled, you will then see how you can manage your SSH.

How to use Manage Shell in cPanel - Cheap VPS

Feel free to explore more about SSH clients here.
ByJUJU-dev

How to import and export a database via phpMyAdmin (‘Access denied create database db_name’ error)

How to import and export a database via phpMyAdmin (‘Access denied create database db_name’ error)

In cPanel you can import and export databases using the phpMyAdmin menu which you can find in the Databases section. Note, that only databases of 50MB maximum can be imported/exported in phpMyAdmin. Larger databases have to be imported/exported via SSH. To do this, follow the instructions here or simply submit a ticket to our HelpDesk.

Database import

1. Log into your cPanel
2. Navigate to phpMyAdmin menu:

3. Select the database that you will need import to:

4. In the upper bar, click the tab Import:

5. Click Browse and locate the .sql file from your computer. Once done, click Go:

6. And you will see a notification that your database was successfully imported:

Database export

1. Log into your cPanel
2. Navigate to phpMyAdmin menu:

3. Select the database that you will need import to:

4. Choose the tables that you need to export or click Check All. Click Export to proceed:

5. Select the required file from the drop-down menu in Format and click the Go button:

Access denied create database db_name error. How to fix it?

If you received this error message, you can resolve the issue by following the next steps:

1. Open the dump of your database using any text editor on your computer (for instance, Notepad or WordPad).
2. Find the line: CREATE DATABASE db_name (it can usually be found at the beginning) and remove it.
*db_name – your database name:

how_to_import_and_export_database_in_cpanel_access_denied_create_database_db_name_error_and_how_to_fix it(10).jpg

3. Save it and import it using the instructions provided above.

That’s it!