Category: Ubuntu

  • Tutorial Install WordPress on LAMP on Ubuntu 21.04

    Tutorial Install WordPress on LAMP on Ubuntu 21.04

    Content Management Systems are a group of software that allows users to produce, publish, organize, and organize content; Without the need to get involved in the complexities of programming. Web content management systems are built specifically for creating web pages, and you can use them to create your favorite web pages without even a single line of code. The most famous and popular web content management system is WordPress. So keep studying to learn how to install WordPress on LAMP on Ubuntu 21.04.

    Prerequisites

    To install WordPress on LAMP on Ubuntu you must first provide the prerequisites, which are:

    – A Linux VPS server with Ubuntu 21.04 operating server.

    – A non-root Sudo user

    – Install a LAMP stack

    – Secure your site with TLS/SSL technology.

    After providing all the prerequisites, you should now create a MySQL database. Because WordPress uses MySQL to manage and store site and user information.

    Install WordPress on LAMP on Ubuntu Linux

    To install WordPress on LAMP on Ubuntu, first, you should create a MySQL Database and user for WordPress.

    Use the following command to log in to a MySQL root account:

    mysql -u root -p

    In this step, you will be asked for the password that you set when installing MySQL root.

    If you do not have access to the MySQL database via root, you should update the root user password by logging in as a Sudo user:

    sudo mysql -u root

    After you receive the MySQL prompt, you should Put a strong password instead of new_password in the following command:

    ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'new_password';

    Now you need to enter “EXIT” and exit the database.

    Then log back into the database by entering your new password:

    mysql -u root -p

    In this step, you need to create an exclusive database to control WordPress. To do this, enter the following command:

    CREATE DATABASE wordpress DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;

    Note: there is a semi-colon (;) at the end of each MySQL statement.

    Now you should create a separate account for the MySQL database to support you in terms of management and security. You will use this account to operate with your new database.

    By typing the following command, you can create an account, set a password, and access the created database.

    CREATE USER 'wordpressuser'@'%' IDENTIFIED WITH mysql_native_password BY 'password';

    In this step, to inform a database that the WordPress user has full access to the setup database, run the following command:

    GRANT ALL ON wordpress.* TO 'wordpressuser'@'%';

    Now you should flush the privileges so that the current MySQL instance is aware of recent changes. To do this, enter the following command:

    FLUSH PRIVILEGES;

    To exit MySQL, run the following command:

    EXIT;

    Keep in mind that when setting up the LAMP stack, PHP needs a minimum set of extensions to communicate with MySQL, and WordPress uses the additional PHP extension.

    In this stage, you should Install additional PHP plugins. Before downloading PHP, you must update the system with the following command:

    sudo apt update

    You must download and install some PHP extensions by entering the following command:

    sudo apt install php-curl php-gd php-mbstring php-xml php-xmlrpc php-soap php-intl php-zip

    Remember to check your plugin documentation to discover its PHP requirements. If they are available, you must install them.

    In this step, you have to restart Apache again with the help of the following command. Because you make more configurations on Apache to download new extensions:

    sudo systemctl restart apache2

    Then you should configure Apache to allow overriding and rewriting .htaccess.

    Now you should create a configuration file for your site in the /etc/apache2/sites-available/ directory.

    In this tutorial, you should put the configuration file path instead of /etc/apache2/sites-available/WordPress.conf. Also, use the webroot specified in your configuration instead of /var/www/ WordPress as the WordPress installation root directory.

    Note that you may use the 000-default.conf configuration (with /var/www /html as your webroot). If you are just hosting a website on this virtual server, it would be fine. Otherwise, it is best to split the required configuration into logical sections, in one file per site.

    By identifying your paths, you can start working with .htaccess so that Apache can make configuration changes based on any directory.

    Now to Enable .htaccess overrides you should do the following methods. the use of .htaccess files is disabled. WordPress and many WordPress plugins use these files extensively for in-directory tricks on virtual web server behavior.

    You can open the Apache configuration file for your website by entering the following command:

    sudo nano /etc/apache2/sites-available/wordpress.conf

    You should allow .htaccess files, to do this you need to put the AllowOverride instruction in a directory block that points to the root of our document. To make sure you are using the correct web root directory, add the following text block inside the VirtualHost block:

    <Directory /var/www/wordpress/>
    AllowOverride All
    </Directory>

    When done, you should save and close the file. To do this in nano, press CTRL and X together, then Y, and ENTER.

    At this point, you should enable the rewrite module so you can use the permalink WordPress feature. To do this enter the following command. After doing this you will have more human-readable permalinks to your posts.

    sudo a2enmod rewrite

    The above command activates the specified module in the Apache configuration by calling the script. Now Enable changes. Before making the changes, check that you have not made any syntax errors by entering the following command:

    sudo apache2ctl configtest

    If you want to override the above line, just add a ServerName instruction to your main (global) Apache configuration file in /etc/apache2/apache2.conf. The server name can be the domain or IP address of your virtual server. However, this is only a message and does not affect the performance of your site. You can continue as long as the output contains Syntax OK.

    Now to make changes you need to restart Apache with the following command:

    sudo systemctl restart apache2

    After completing the above steps, you can now install WordPress.

    In this stage, you should Navigate to a writable directory and download the compressed version.

    cd /tmp
    
    curl -O https://wordpress.org/latest.tar.gz

    You should run the following command to extract the compressed file:

    tar xzvf latest.tar.gz

    You should add a bogus .htaccess file to make it available for later use in WordPress. To do this enter the following command:

    touch /tmp/wordpress/.htaccess

    Then you need to copy the sample configuration file with the name of the file that WordPress reads. To do this, enter the following command:

    cp /tmp/wordpress/wp-config-sample.php /tmp/wordpress/wp-config.php

    You can create an updated directory with the following command. By doing this, WordPress will not be licensed automatically after updating the software:

    mkdir /tmp/wordpress/wp-content/upgrade

    In this step, copy all the contents of the directory to the root of your document. The dot used at the end of the source directory indicates that everything in the directory, even hidden files, should be copied:

    sudo cp -a /tmp/wordpress/. /var/www/wordpress

    Remember to replace the /var/www/wordpress folder with the directory set on the virtual server.

    How to Configure WordPress on LAMP on Ubuntu 21.04

    You must first give ownership of all files to the user and the www-data group. This is the user as the Apache virtual web server runs, and Apache must be able to read and write WordPress files to serve the website and perform automatic updates.

    Now you should update ownership with the following command that allows you to change file ownership. Then you should refer to the relevant directory of your virtual server:

    sudo chown -R www-data:www-data /var/www/wordpress

    You can set the correct permissions in WordPress directories and files with the following commands:

    sudo find /var/www/wordpress/ -type d -exec chmod 750 {} \;
    
    sudo find /var/www/wordpress/ -type f -exec chmod 640 {} \;

    By opening the file, our first task will be to set some secret keys to provide a security level for your installation. WordPress provides a reliable generator for these values ​​so there is no need to try to achieve the right values ​​alone. These are only used indoors, so using sophisticated and safe amounts here will not be a problem.

    With the following command, you can get safe values from the WordPress secret key generator. You can add the output of the following command to the configuration file:

    curl -s https://api.wordpress.org/secret-key/1.1/salt/

    Now you need to open the WordPress configuration file. To do this, enter the following command:

    sudo nano /var/www/wordpress/wp-config.php

    Then you need to look for the section that has example values for those settings:

    define('AUTH_KEY', 'put your unique phrase here');
    define('SECURE_AUTH_KEY', 'put your unique phrase here');
    define('LOGGED_IN_KEY', 'put your unique phrase here');
    define('NONCE_KEY', 'put your unique phrase here');
    define('AUTH_SALT', 'put your unique phrase here');
    define('SECURE_AUTH_SALT', 'put your unique phrase here');
    define('LOGGED_IN_SALT', 'put your unique phrase here');
    define('NONCE_SALT', 'put your unique phrase here');

    After deleting those lines, you need to paste in the copied values from the command line:

    define('AUTH_KEY', 'VALUES COPIED FROM THE COMMAND LINE');
    define('SECURE_AUTH_KEY', 'VALUES COPIED FROM THE COMMAND LINE');
    define('LOGGED_IN_KEY', 'VALUES COPIED FROM THE COMMAND LINE');
    define('NONCE_KEY', 'VALUES COPIED FROM THE COMMAND LINE');
    define('AUTH_SALT', 'VALUES COPIED FROM THE COMMAND LINE');
    define('SECURE_AUTH_SALT', 'VALUES COPIED FROM THE COMMAND LINE');
    define('LOGGED_IN_SALT', 'VALUES COPIED FROM THE COMMAND LINE');
    define('NONCE_SALT', 'VALUES COPIED FROM THE COMMAND LINE');

    In this step, you must set the database name, database user, and associated password in MySQL to change some of the database connection settings at the beginning of the file.

    Then you need to setup a method that WordPress uses to write to the file system. Set the file system method to “Direct” because the webserver is allowed to write wherever needed. Failure to do so with your current settings will result in WordPress requesting FTP credentials when performing certain actions.

    You should add the above settings below the database connection settings. Note that you can add the file anywhere else:

    // ** MySQL settings - You can get this info from your web host ** //
    /** The name of the database for WordPress */
    define( 'DB_NAME', 'wordpress' );
    
    /** MySQL database username */
    define( 'DB_USER', 'wordpressuser' );
    
    /** MySQL database password */
    define( 'DB_PASSWORD', 'password' );
    
    /** MySQL hostname */
    define( 'DB_HOST', 'localhost' );
    
    /** Database Charset to use in creating database tables. */
    define( 'DB_CHARSET', 'utf8' );
    
    /** The Database Collate type. Don't change this if in doubt. */
    define( 'DB_COLLATE', '' );
    
    . . .
    
    define('FS_METHOD', 'direct');

    Finally, save it before closing the file.

    How to Setup WordPress on Ubuntu 21.01

    Once the server configuration is complete, install it via the web interface. To do this first go to the public IP address or domain name of your server from the web browser using the following command:

    https://server_domain_or_IP

    Then choose your language.

    At this stage, you will enter the main setup page.

    Then you need to choose a unique name for the WordPress site and a username. Then a strong password is automatically generated that you must save. Now you need to enter your email address and check the box of discouraging search engines from indexing this site.

    1-setup_installation ordpresson ubuntu

    After clicking on Install WordPress, you will be redirected to the following page that asks you to Log In:

    2-login_prompt to wordpress dashboard

    After clicking on login, you will enter the WordPress admin dashboard:

    3-wordpress dashboard panel

    Finally, you can start designing your WordPress website.

    Conclusion

    The WordPress platform is one of the most popular and widely used content management tools for creating great websites. In this tutorial, you have learned all the necessary things related to installing WordPress on Ubuntu. But note that you must have a MySQL database and install PHP for WordPress. After a successful installation, now you can log in to your WordPress admin dashboard and start customizing your website. We hope this guide was helpful enough.

  • Tutorial Install and Run MongoDB on Ubuntu 20.10

    Tutorial Install and Run MongoDB on Ubuntu 20.10

    Programmers use different databases in web and application development. SQL or NoSQL-based databases have different uses according to system requirements and programmers’ preferences. MongoDB is one of these databases. MongoDB is one of the most popular No SQL databases, which has a flexible structure and is mostly used in projects with large volumes of data. This article will teach you How to Install and run MongoDB on Ubuntu 20.10.

    Prerequisites

    – A Linux VPS with Ubuntu operating system

    – Root or sudo access

    – Sufficient system resources including disk space, RAM, and CPU.

    How to Install MongoDB on Ubuntu 20.10

    First, your Ubuntu 20.10 must have a non-root executable user and a UFW-configured firewall. You need to install the latest version of MongoDB software. To install and run MongoDB on Ubuntu, you should put the dedicated MongoDB package repository in your APT resources. You can now install MongoDB.

    Tutorial-Install-and-Run-MongoDB-on-Ubuntu-20.10

    Enter the following command to enter the public GPG key for the latest stable version of MongoDB:

    curl -fsSL https://www.mongodb.org/static/pgp/server-4.4.asc | sudo apt-key add -

    cURL is a command-line tool used in many operating systems to transfer data. cURL reads the data stored in the URL and prints the content to the system output. If the GPG server crashes or cURL is unable to connect to the GPG server, cURL will not add the resulting error code to your list of valid keys.

    If the key is added successfully, you will see the following command key:

    Output
    OK

    To double-check how to add the key correctly, you must enter the following command:

    apt-key list

    You can return the MongoDB key somewhere in the output by entering the following command:

    Output
    /etc/apt/trusted.gpg
    --------------------
    pub rsa4096 2019-05-28 [SC] [expires: 2024-05-26]
    2069 1EEC 3521 6C63 CAF6 6CE1 6564 08E3 90CF B1F5
    uid [ unknown] MongoDB 4.4 Release Signing Key <[email protected]>
    . . .

    The APT looks for online sources of packages for download and installation in either sources.list file or sources.list.d directory. The sources.list.d directory allows you to add sources.list them as separate files. sources.list Lists the active sources of APT data. So that your first preferred sources are at the top of the list and a source is mentioned in each line.

    Creates a file in the sources.list.d directory named mongodb-org-4.4.4 by running the following command:

    echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/4.4 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-4.4.list

    In this step, to find the mongodb-org package, enter the following command and then update the local server package index:

    sudo apt update

    After activating the repository, install the mongodb-org package by entering the following command:

    sudo apt install mongodb-org

    In this step, to confirm the installation of the package, you must select Y and then ENTER.

    How to Run MongoDB on Ubuntu 20.10

    MongoDB is now installed on your system but cannot be used. At this point, you start the MongoDB service and test the databases.

    Tutorial-Install-and-Run-MongoDB-on-Ubuntu-20.10-2

    You can manage MongoDB with various systemctl commands. Start Daemon MongoDB and activate it by entering the following command:

    sudo systemctl start mongod.service

    Now you should check the status of the service. Note that this command does not include .service in the service file definition. It is not necessary to enter systemctl in the following command. If it is not already present, it will automatically add to any argument you pass:

    sudo systemctl status mongod

    The output will look something like the following and indicate that the service is active:

    mongod.service - MongoDB Database Server
    Loaded: loaded (/lib/systemd/system/mongod.service; disabled; vendor preset: enabled)
    Active: active (running) since Tue 2020-06-09 12:57:06 UTC; 2s ago
    Docs: https://docs.mongodb.org/manual
    Main PID: 37128 (mongod)
    Memory: 64.8M
    CGroup: /system.slice/mongod.service
    └─37128 /usr/bin/mongod --config /etc/mongod.conf

    You must now confirm “the service is running as expected“.

    Activate the MongoDB service by entering the following command to start it at startup:

    sudo systemctl enable mongod

    To check if the installation is successful, use the following command to connect to the MongoDB database server and extract the current version, server address, and port:

    mongo --eval 'db.runCommand({ connectionStatus: 1 })'

    In the output below, the value of 1 for the ok field in the response indicates that the server is working as expected:

    Output
    MongoDB shell version v4.4.0
    connecting to: mongodb://127.0.0.1:27017/?compressors=disabled&gssapiServiceName=mongodb
    Implicit session: session { "id" : UUID("1dc7d67a-0af5-4394-b9c4-8a6db3ff7e64") }
    MongoDB server version: 4.4.0
    {
    "authInfo" : {
    "authenticatedUsers" : [ ],
    "authenticatedUserRoles" : [ ]
    },
    "ok" : 1
    }

    How to Configure MongoDB on Ubuntu 20.10

    Like other Ubuntu services, you can manage MongoDB using standard systemctl commands. The systemctl status command checks the status of the MongoDB service:

    sudo systemctl status mongod

    You can stop the service with the following command:

    sudo systemctl stop mongod

    Run the following command to start the service again:

    sudo systemctl start mongod

    You can restart the running server with the following command:

    sudo systemctl restart mongod

    To disable automatic startup, enter the following command:

    sudo systemctl disable mongod

    Now enter the following command to re-enable it to startup:

    sudo systemctl enable mongod

    If you wish, you can read The Ultimate Guide to Install MongoDB on Ubuntu 22.04.

    Conclusion

    In this guide, we walked you through the process of installing and running MongoDB on Ubuntu. By following these steps, you have successfully set up MongoDB on your Ubuntu machine and can now start leveraging its powerful features for handling large volumes of data. Remember to keep your installation updated by regularly checking for MongoDB updates and applying them as needed.

  • The Ultimate Guide to Install MongoDB on Ubuntu 22.04

    The Ultimate Guide to Install MongoDB on Ubuntu 22.04

    MongoDB is a popular open-source NoSQL database that offers high performance, scalability, and flexibility. To take advantage of its benefits and ensure the security of your data, it is essential to install and securing MongoDB on Ubuntu 22.04 system. In this guide, we will provide a step-by-step walkthrough to help you install MongoDB and implement necessary security measures.

    Prerequisites

    To install and securing MongoDB on Ubuntu, you need to satisfy the following requirements:

    – A Linux VPS with Ubuntu Operating System

    – Root access to Server

    – 4GB of RAM

    install and securing mongodb on ubuntu 22.04

    Installing MongoDB on Ubuntu 22.04

    Step.1: Update System

    Update your system by running the following command in the terminal:

    sudo apt update && sudo apt upgrade

    Step.2: Remove Existing MongoDB Packages (if any)

    If you had an older version of MongoDB installed, remove it using the following commands:

    sudo systemctl stop mongod
    sudo apt purge mongodb-org*

    Step.3: Set Up MongoDB Repository

    Add the MongoDB repository to your Ubuntu system using the following command:

    echo "deb [arch=amd64] https://repo.mongodb.org/apt/ubuntu $(lsb_release -cs)/mongodb-org/4.4 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-4.4.list

    Step.4: Import Public GPG Key

    Import the public GPG key used to sign the MongoDB packages by running the following command:

    wget -qO - https://www.mongodb.org/static/pgp/server-4.4.asc | sudo apt-key add -

    Step.5: Update Repository

    Update the repository by running the following command:

    sudo apt update

    Now you are ready to install MongoDB on Ubuntu 22.04. You can proceed with the installation by running the following command:

    sudo apt install -y mongodb-org

    Once the installation is complete, verify the version of MongoDB installed:

    mongod --version

    After the installation, MongoDB will be running as a service on your Ubuntu system. You can start and then enable MongoDB using the following command:

    sudo systemctl start mongod
    sudo systemctl enable mongod

    Then, you can confirm if the service is running:

    sudo systemctl status mongod

    How to Secure MongoDB on Ubuntu 22.04

    To secure MongoDB on Ubuntu 22.04, you can follow these steps:

    Step.1: Update MongoDB

    Start by updating your MongoDB installation to the latest version by running the following commands:

    sudo apt update
    sudo apt upgrade mongodb

    Step.2: Enable Authentication

    MongoDB does not enable authentication by default. So, you need to enable it for secure access. Open the MongoDB configuration file using a text editor:

    sudo nano /etc/mongodb.conf

    Add the following line at the end of the file:

    security:
    authorization: enabled

    Save and exit the file.

    Step.3: Create Administrative Use

    Switch to the MongoDB shell:

    mongo

    Switch to the admin database:

    use admin

    Create the administrative user with a username and password:

    db.createUser({ user: "admin-user", pwd: "admin-password", roles: ["root"] })

    Replace “admin-user” with your desired username and “admin-password” with your desired password.

    Step.4: Restart MongoDB

    Restart the MongoDB service to apply the changes:

    sudo systemctl restart mongodb

    Step.5: Verify Authentication

    Try accessing MongoDB with the newly created administrative user:

    mongo -u admin-user -p --authenticationDatabase admin

    You will be prompted for the password. If you can successfully log in, it means authentication is working.

    Step.6: Adjust Firewall Rules

    If you have a firewall enabled, allow access to the MongoDB port (default is 27017) to ensure network security.

    By following these steps, you can secure MongoDB on Ubuntu 22.04 by enabling authentication and creating an administrative user.

    Troubleshooting

    Here are some common issues that you may encounter when installing MongoDB on Ubuntu 22.04 and their corresponding troubleshooting steps:

    1. Repository not found:

    – Make sure you have added the MongoDB repository correctly. Check if the repository URL is correct and accessible.

    – Check if the package repository is enabled in the “/etc/apt/sources.list” file or “/etc/apt/sources.list.d/” directory.

    2. Dependency issues:

    – Run the following command to fix any dependency issues:

    sudo apt --fix-broken install

    – Ensure that you have installed the required dependencies for MongoDB.

    3. Unable to locate package:

    – Double-check if you have entered the correct package name.

    – Update the package lists:

    sudo apt update

    4. Permission issues:

    – Make sure you have proper permissions to install packages. Use “sudo” if necessary.

    – Check the ownership and permissions of relevant directories.

    5. MongoDB service not starting:

    – Check the MongoDB service status using the following command:

    sudo systemctl status mongod

    – Inspect the MongoDB logs in “/var/log/mongodb/” for any error messages.

    – Restart the MongoDB service:

    sudo systemctl restart mongod

    6. Port in use:

    – If MongoDB fails to start due to the port being already in use, identify the process using the port and terminate it.

    – Check for open ports using below command:

    sudo netstat -tuln | grep 

    – Kill the process:

    sudo kill

    Conclusion

    You have successfully installed and secured MongoDB on your Ubuntu 22.04 system. By following these steps, you have ensured that MongoDB is running on the local interface only and authentication is required to access the database. This will help protect your data and minimize the risk of unauthorized access. Remember to always keep your MongoDB installation up to date with security patches and follow best practices for securing your entire system.

  • The Ultimate Guide to Creating a Foolproof Backup on Ubuntu Server

    The Ultimate Guide to Creating a Foolproof Backup on Ubuntu Server

    Foolproof Backup refers to a backup system or strategy that is designed to be highly reliable and virtually error-free, making it almost impossible for data to be lost or corrupted. It typically involves the use of multiple backup techniques and redundant systems to ensure that data is securely stored and can be easily recovered in the event of hardware failures, human errors, or other disasters. This is a useful post that most Ubuntu users are looking for. Therefore, we suggest you not to waste time and start with the Creating a Foolproof Backup on Ubuntu Server guide.

    What is Foolproof Backup?

    A foolproof backup system often includes features such as automated backups that run on a regular basis, encryption to protect data from unauthorized access, off-site storage to guard against physical damage or theft, versioning to preserve different versions of files, and verification mechanisms to ensure the integrity and accuracy of the backups.

    foolproof backup on ubuntu server

    The goal of a foolproof backup is to provide users with peace of mind, knowing that their data is properly safeguarded and can be restored quickly and efficiently when needed. We also suggest you to choose and use one of the Linux VPS server plans with Ubuntu distribution provided on our website to back up your Ubuntu server.

    Step by Step Guide to Creating a Foolproof Backup on Ubuntu Server

    Creating a foolproof backup system is essential to protect your data and ensure business continuity. Here is a step-by-step guide to creating a foolproof backup on Ubuntu Server.

    Step1: Identify critical data:

    Begin by identifying the critical data you want to back up. This could include important documents, databases, configuration files, and any other data that is essential for your server’s operation.

    Step2: Choose a backup location:

    Decide where you want to store your backups. It is recommended to choose a separate physical location or external storage device to prevent data loss due to physical damage or system failures.

    Step3: Install backup software:

    Ubuntu Server offers various backup software options. One popular choice is rsync, a command-line utility that allows efficient syncing of files between servers.

    You can install rsync using the following command:

    sudo apt install rsync

    In order to launch rsync as a service on Ubuntu, you need to create the /etc/rsyncd.conf file and then copy /lib/systemd/system/rsync.service to /etc/systemd/system/rsync.service.

    After doing this, finally restart rsync using the following commands:

    sudo nano /etc/rsyncd.conf
    sudo cp /lib/systemd/system/rsync.service /etc/systemd/system/rsync.service
    sudo systemctl restart rsync

    Step4: Create a backup script:

    Create a shell script that automates the backup process. This script should include the necessary rsync commands to transfer data from the server to the backup location. For example, you could use the following script:

    #!/bin/bash
    rsync -avz --delete /path/to/source/ /path/to/backup/

    Replace “/path/to/source” with the directory or file you want to back up and “/path/to/backup” with the backup destination you prepared. The -avz options enable archive mode (preserving permissions, ownership, and timestamps), verbose output, and compression.

    Save this script as “backup.sh” in an easily accessible location, such as /usr/local/bin/.

    chmod +x backup.sh

    Test the backup script Before running the backup script:

    ./backup.sh

    Step5: Setup a cron job:

    Use cron to schedule regular backups automatically. Open the cron configuration file using the command:

    sudo crontab -e

    Add the following line to run the backup script daily at midnight:

    0 0 * * * /usr/local/bin/backup.sh

    Or, you can add a new line at the end of the file with the following syntax:

    * * * /path/to/backup.sh

    This example will run the backup script every minute.

    Save the file and exit the editor. The backup script will now be executed at the specified time.

    backup on ubuntu server

    Modify the backup script to redirect the output to a log file by adding the following line to the script:

    rsync -avz --delete /path/to/source /path/to/destination > /path/to/backup.log 2>&1

    Replace “/path/to/backup.log” with the file path where you want to save the log file

    Troubleshooting Common Issues of Backup on Ubuntu Server

    Here are some troubleshooting steps for backup issues on Ubuntu Server:

    1. Check the backup software or tool being used

    2. Verify backup settings

    3. Check for sufficient disk space

    4. Verify permissions

    5. Check for errors in backup logs

    6. Test backup and restore

    7. Check system resources

    8. Update packages and software

    9. Network connectivity

    10. Consider alternative backup solutions

    Conclusion

    In conclusion, creating a foolproof backup on Ubuntu Server is essential for ensuring data security and minimizing the risk of data loss. By following a systematic approach and utilizing appropriate backup tools, users can effectively backup their data and restore it when needed, enhancing the overall reliability of their server.

  • The Ultimate Guide to Installing Metasploit on Ubuntu

    The Ultimate Guide to Installing Metasploit on Ubuntu

    Metasploit is an open-source penetration testing framework designed to help cybersecurity professionals identify vulnerabilities, assess security measures, and simulate cyber attacks. It provides a wide range of tools and resources for executing various types of exploits, payloads, and post-exploitation activities. Metasploit contains a vast collection of known exploits, payloads, and modules that can be used to target and test the security of computer systems, networks, and applications. It offers a command-line interface as well as a graphical user interface (Metasploit Framework Community Edition) to facilitate the management and execution of its capabilities. In this guide, we will provide a step-by-step tutorial on installing Metasploit on an Ubuntu operating system.

    Requirements

    Before we proceed with the installation, ensure that you have the following:

    – A Linux VPS running Ubuntu (preferably the latest version)

    – An active internet connection

    – Sufficient storage space

    installing metasploit on ubuntu

    Step 1: Update and Upgrade Ubuntu

    To ensure that your system is up-to-date, open the terminal and execute the following commands:

    sudo apt update
    sudo apt upgrade

    Step 2: Install Necessary Dependencies

    Metasploit requires certain dependencies to function correctly. Install them by running the following command:

    sudo apt install build-essential libreadline-dev libssl-dev libpq5 libpq-dev libreadline5 libsqlite3-dev libpcap-dev git

    Step 3: Configure PostgreSQL Database

    Metasploit uses PostgreSQL as its database backend.

    First, you should run the following command to install PostgreSQL:

    sudo apt install postgresql postgresql-contrib

    Start PostgreSQL as follows:

    sudo service postgresql start

    Now you need to enable PostgreSQL by running the following command:

    sudo update-rc.d postgresql enable

    Finally, you need to configure PostgreSQL using the following two commands:

    sudo -u postgres createuser msf -P -S -R -D
    sudo -u postgres createdb -O msf msf

    Step 4: Install Ruby and RVM

    Metasploit Framework is written in Ruby and requires the Ruby Version Manager (RVM) to manage Ruby versions. Execute the following commands to install Ruby using RVM:

    gpg2 --keyserver hkp://pool.sks-keyservers.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
    curl -L https://get.rvm.io | bash -s stable
    source ~/.rvm/scripts/rvm
    echo "source ~/.rvm/scripts/rvm" >> ~/.bashrc
    source ~/.bashrc
    RUBYVERSION=$(wget https://raw.githubusercontent.com/rapid7/metasploit-framework/master/.ruby-version -q -O - )
    rvm install $RUBYVERSION
    rvm use $RUBYVERSION --default
    ruby -v

    Tip: Close and reopen the terminal to ensure RVM is loaded properly.

    Step 5: Install Metasploit Framework

    Now, you should run the following command to download the Metasploit stable version installer:

    wget http://downloads.metasploit.com/data/releases/metasploit-latest-linux-x64-installer.run

    Now you need to run the installer file by executing the command you see:

    ./metasploit-latest-linux-x64-installer.run

    By executing the above command, the Metasploit welcome window will be displayed for you. Click on Forward:

    metasploit framework install

    ***

    metasploit framework complete install

    Wait for the installation to complete successfully.

    Open one of your favorite browsers and access it using the following address.

    As you can see in the picture below, it is necessary to fill the necessary fields with the required information. Then click on Create Account:

    https://localhost:3790

    metasploit framework web ui

    Finally, to access the Metasploit console from the command line, you can run the following command:

    msfconsole
    run metasploit on ubuntu gui

    If the Metasploit console launches without any errors, congratulations! You have successfully installed Metasploit on Ubuntu.

    Conclusion

    In this guide, we covered the step-by-step process of installing Metasploit on an Ubuntu operating system. By following these instructions carefully, you can begin utilizing the powerful features of Metasploit to enhance your security testing capabilities. Remember to use Metasploit ethically and responsibly, respecting the privacy and security of others.

  • Mastering the Art of Changing Your IP Address on Ubuntu 22.04

    Mastering the Art of Changing Your IP Address on Ubuntu 22.04

    After successfully installing Ubuntu 22.04, your network interface will by default assign an IP address using a DHCP server. A wired network and Wi-Fi network are also activated. The network manager in Ubuntu is Netplan. You can also configure the network interface with IPv4 addresses. This article represents the way of changing your IP address on Ubuntu. You can use two methods to change your IP address. So, keep studying carefully.

    Two Simple Methods to Change the IP Address on Ubuntu 22.04

    This section will give you two different methods of configuring and changing IP addresses. Desktop users can use any one of these methods, but server users that have CLI can access and use only the second method to configure and make changes.

    Prerequisites

    • Installed and up-to-date Ubuntu 22.04 on Linux VPS or OS
    • Sudo admin rights

    Method 1: Change Static IP Address on Ubuntu Via GUI

    If you are using the desktop version of Ubuntu, you must know that there is a graphical interface for configuration. So you can follow the steps mentioned in this section above to easily change your IP address.

    First, Click on the Network Icon in the right corner of your. Choose the Wired connection menu and Click the Wired settings:

    network section on ubuntu

    You will encounter a dialog box. Click Network in the sidebar. You will see the Wired section. Click on the Gear Icon to open a new Wired dialog box:

    Wired setting on ubuntu

    Now, you will see the IPv4 tab. Set the method to Manual and input a valid IP address, Netmask, and Gateway. Now to confirm the changes click the Apply button:

    IPv4 section on ubuntu - Changing IP address on ubuntu

    At the final step, disable and again enable the Wired Icon to apply changes:

    Wired Icon on Ubuntu - Changing IP address on ubuntu

    That’s it! You successfully changed the Ubuntu 22.04 IP address.

    Method 2: Change Static IP Address Via CLI

    If you are using a server, you should know that server versions are installed without a graphical interface. So, you need to configure your IP address using the command line. The Ubuntu distribution uses Netplan as a network manager for this. To do this, follow the steps below.

    In the first step, you need to find the name of the network interface in the system. This name may vary based on the type of installation and system hardware. Use the following command:

    sudo ip a

    As a result of the executed command, you will see that the name of the system network interface is eth0. Of course, this name can be different from your system.

    Now, create or edit the network configuration file in the /etc/netplan folder. Use your favorite text editor and create the configuration file:

    sudo vi /etc/netplan/01-netcfg.yaml

    You must use the YAML template and configure the network as follows:

    network:
        version: 2
        renderer: networkd
        ethernets:
            eth0:
                addresses:
                    - 192.168.1.212/24
                nameservers:
                    addresses: [8.8.8.8, 8.8.4.4]
                routes:
                    - to: default
                      via: 192.168.1.2

    As you can see in the above configuration, the interpretation of the available items is as follows:

    – eth0: Network Interface Name

    – addresses: Use for configuring IPv4 address on the interface. You have to be sure to define CIDR. (Here you can add multiple addresses)

    – nameservers: Where you can set the nameserver. (8.8.8.8 and 8.8.4.4 are defaults Google nameservers)

    – routes: To set the Gateway on your system.

    Make sure that the IP gateway address is entered correctly and that v4 belongs to the system network.

    Finally, execute the following command to apply the changes:

    sudo netplan apply

    Well done! Passing these steps, you could change your static IP address on Ubuntu 22.04.

    Troubleshooting Some Issues about Changing Ubuntu IP address

    1- Changing the IP address may temporarily disrupt network connectivity.

    Solution:

    Ensure you have physical or remote access to the machine. Schedule the change during a maintenance window to minimize impact.

    2- Manually configuring the IP address with incorrect settings can lead to network issues.

    Solution:

    Double-check the configuration settings, including IP address, subnet mask, gateway, and DNS. Update the /etc/network/interfaces or /etc/netplan configuration files accordingly.

    3- Changing the IP address may affect existing firewall rules.

    Solution:

    Update firewall rules to reflect the new IP address. Adjust settings in UFW or other firewall management tools accordingly.

    Conclusion

    As you can see in the instructions of this tutorial, there are two different ways to change the IP address, both of which we have mentioned. Now you can safely and without confusion change your IP with the necessary configuration. Please send your queries or feedback in the comment section below.

  • The Ultimate Guide to Install VSCode on Ubuntu 20.04

    The Ultimate Guide to Install VSCode on Ubuntu 20.04

    This article is presented to review visual studio code or VSCode. This tool is a powerful open-source code editor created by Microsoft. Strong VSCode support includes built-in debugging, syntax highlighting, built-in git control, code completion, code refactoring and snippets, and an integrated terminal. This tool can be used on most important platforms such as Windows, Linux, and Mac. We will also try to teach you how to install VSCode on Ubuntu 20.04.

    Prerequisites

    Here are the requirements to install VSCode on Ubuntu 20.04

    • An up-to-date Ubuntu system on Linux VPS
    • A powerful network connection
    • A root account or sudo privileges

    3 Easy Methods to Install VSCode on Ubuntu 20.04

    There are different methods to install VSCode on Ubuntu. We will examine all of them for you, but you can choose the proper one according to your desire. Here are the methods:

    • Via Snap
    • Via APT
    • Via Graphical User Interface/GUI

    Method 1: Installing Visual Studio Code Via Snap

    Open the Ubuntu terminal and run the necessary command to install the snap package. This package contains VSCode with required dependencies. These snap packages are containerized applications.

    sudo snap install --classic code

    To check the program version, use the command below:

    code --version 

    Method 2: Installing Visual Studio Code Via APT

    You can use the apt package manager to install VSCode on your Ubuntu server, so follow the instructions below carefully.

    1- First you should update your system’s repository using the following command:

    sudo apt update

    2- For a successful operation, you should install the required package dependencies. Now execute the command below:

    sudo apt install software-properties-common apt-transport-https wget -y

    This command will install all the dependencies automatically.

    3- It is important to verify the package integrity, so import the GPG key provided by Microsoft. You should use the following command:

    wget -q https://packages.microsoft.com/keys/microsoft.asc -O- | sudo apt-key add -

    4- To add the Visual Studio Code repository to your system, you can execute the following command:

    sudo add-apt-repository "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main"

    5- It is time to install the VSCode after enabling the repository:

    sudo apt install code

    6- Run the following command to verify VSCode installation:

    code --version

    Tip: If you install the VSCode successfully, you will see the program version.

    Method 3: Installing VSCode Using the GUI

    In this section, we will give step-by-step instructions to install VSCode by Ubuntu software center.

    1- First of all open the Ubuntu software center. Click on the Show Applications button and open the software center application:

     Ubuntu software center

    Tip: The show application option opens the application drop-down menu and shows the installed application icons.

    2- Now you should press the search button and type VSCode. Now if you want to open the app page, select Code:

    search for VScode on ubuntu

    3- You can see the Visual Code app icon here. Click the Install button. It will be asked to insert an administrative password and start the installation process:

    install VS code

    Starting VSCode on Ubuntu

    After a successful installation, you can start the program. On the Ubuntu terminal click on the show applications icon and locate the Visual Studio code in your app list:

    VScode on Ubuntu terminal

    Click to open the program. Now you can customize the appearance of the program according to your taste. For example, program extensions you need for programming languages, etc.

    customize VScode

    Troubleshooting Issues Of VSCode on Ubuntu

    Here are some common problems with Visual Studio Code on Ubuntu:

    1- If you install VSCode using Snap, it might not have access to certain resources like USB devices.

    Solution:

    Install it using the .deb package or use the following command to enable the necessary permissions:

    sudo snap connect :removable-media

    2- Sometimes, you might encounter dependency issues when installing VSCode.

    Solution:

    Ensure that you have the required dependencies installed. Run the following commands:

    sudo apt update sudo apt install -y libx11-xcb1 libasound2

    3- If you’re getting a “404 Not Found” error when updating the package list, the repository might be deprecated.

    Solution:

    Check the official VSCode documentation for the latest instructions on adding the repository.

    Conclusion

    Visual Studio Code is one of the helpful editors to use on platforms like Linux and Windows. This article was prepared to show the way of installing VSCode via three different methods. Then you learned how to start it on your terminal. Install and enjoy the program. Happy coding!

  • The Art of Ubuntu Server Monitoring: Best Practices and Tools

    The Art of Ubuntu Server Monitoring: Best Practices and Tools

    A system monitoring tool, also known as monitoring software or system monitor, is a type of software or application used to observe, manage, and collect data about the performance and behaviour of a computer system or network. These tools are essential for IT professionals and system administrators to ensure that systems are running efficiently, identify and address issues, and gather data for analysis and reporting. Here we will introduce the best Ubuntu server monitoring tools, keep reading.

    The Best System Monitoring Tools for Ubuntu

    Whether you are a regular user or a system administrator, maintaining the smoothness of the computer and network infrastructure is very important. So to monitor your system, especially Linux OS or Linux VPS, you need to use a monitoring tool to monitor all system activities such as CPU performance, and memory code, Monitor the network, and track the status of other connected devices.

    7 Best Ubuntu Server Monitoring Tools

    Let’s find out the Ubuntu server monitoring tools

    Htop

    Htop is an interactive system monitoring tool for Linux operating systems. It is similar to the traditional top command but provides a more user-friendly and dynamic interface for monitoring system resources and processes.

    Htop allows you to view and manage system metrics in real-time, making it easier to identify and diagnose performance issues on your system. This is suitable for consoles and terminals, that’s why it supports text mode.

    Htop has many features that are used in FreeBSD, macOS, and OpenBSD Linux. This tool provides information such as working time, tasks, and load average. You can also change the color settings in the user interface to suit your needs. Htop supports real-time signals and custom scripts.

    Htop Monitoring Tool

    Stacer

    Stacer is an open-source tool used for system monitoring and optimization. System administrators can easily manage system resources and tasks with this tool. Its wonderful user interface and modern structure make you feel comfortable using it.

    Stacer has many tools that help manage start-up programs and clean essential package caches, program logs, crash logs, cache, and garbage in the system cleaner tab. You can start or stop high-speed services, also, remove programs that you no longer need.

    You can see the network activity for the last 60 seconds in the CPU, RAM, disk, and average CPU resource tab. It helps you have an apt repository that can be used to remove, enable, and disable any repository. Those using Ubuntu can take advantage of this to edit closed repositories.

    Stacer monitoring tool

    Glances

    Another monitoring tool for Ubuntu is Glances, which is written in Python and is cross-platform. This tool adjusts automatically depending on the size of the terminal and displays all the information in a single window. It shows all the necessary information as much as possible.

    You can use glances in client/server mode and monitor the system through the web or terminal. As a result, having all the necessary information at once is one of the positive points of this tool. Other features of Glances include the use of a web interface for remote monitoring.

    Tip: Using this tool for Linux running low-end programs may be a bit difficult because more CPU resources are required.

    glances

    BashTOP

    It can be said that another interesting and reliable tool for monitoring the Ubuntu system is Bashtop. This tool displays usage statistics of processors, disks, memory, network, and other resources. This tool is perfect for desktop and computer users. But it doesn’t work much for system administrators because it won’t satisfy their demands.

    Also if we want to compare it with Htop it is a bit slower. Bashtop is easy to use and has a beautiful and perfect user interface.

    bashtop

    Vtop

    Vtop is provided as a free and open-source tool that is responsible for monitoring the system of Ubuntu and other Linux distributions. This tool allows you to monitor and manage the system at the same time. It is especially useful for system administrators, developers, and anyone interested in monitoring system performance in a more user-friendly and interactive way.

    More specifically, Vtop is a command-line tool and interactive system monitoring tool that allows users to view real-time statistics and information about the performance of their computer or server. It’s similar to the popular top tool that provides a dynamic view of system processes and resource usage, but Vtop adds some extra features and a more user-friendly interface.

    Vtop monitoring tool - ubuntu server monitoring tools

    Atop

    If we want to introduce an advanced interactive system and process monitor for you, Atop is certainly one of the best that displays the load on Linux and Bubuntu systems. You can view the most important hardware resources such as CPU, disk, network, or memory. Or for a more detailed and longer review, record the use of resources permanently.

    In other words, It provides detailed insights into system resource usage and process-level information, making it a valuable tool for system administrators and those interested in monitoring and troubleshooting system performance.

    atop monitoring tool - ubuntu server monitoring tools

    Gotop

    Gotop is a system monitoring and resource usage visualization tool for the command line and is graphical. It is designed to provide real-time information about system resource consumption, such as CPU usage, memory usage, and processes, in an easy-to-read and interactive format.

    Gotop is typically used by system administrators and users who prefer command-line interfaces for monitoring their system’s performance. Unlike Atop and Vtop, Gotop doesn’t use node.js and is written in the Go language.

    Gotop - ubuntu server monitoring tools

    The Best Practices to Use Ubuntu Monitoring Tools

    Monitoring your Ubuntu system is crucial to ensure its performance, stability, and security. Ubuntu provides various tools and practices for effective system monitoring. Here are some best practices for using Ubuntu monitoring tools:

    1- For more comprehensive monitoring, you can also consider tools like Prometheus, Grafana, Zabbix, and Nagios. Choose the tools that best suit your monitoring needs.

    2- Ensure that your Ubuntu system is up-to-date. Regularly run sudo apt update and sudo apt upgrade to keep your system and monitoring tools current.

    3- Tools like Iftop and Nload can help you monitor network traffic and bandwidth usage. Consider netstat and ss for examining network connections.

    4- Use tools like df and du to monitor disk space. You can also set up alerts for low disk space using monitoring solutions like Nagios.

    5- If you’re running specific services or applications, setup monitoring for those using tools like Prometheus with exporters or application-specific monitoring agents.

    6- Employ tools like fail2ban to monitor and protect against unauthorized access attempts. Tools like Logwatch can also help you keep an eye on security-related events.

    7- Write custom scripts to monitor specific parameters or services and set up alerts through email, SMS, or other notification methods when thresholds are breached.

    8- Consider centralizing your logs using tools like the ELK stack or similar solutions. Centralized logs make it easier to search, analyze, and correlate information.

    9- Document your monitoring setup, including the tools you use, configurations, alert thresholds, and procedures to follow when alerts are triggered.

    10- Regularly review your monitoring configuration and make adjustments as necessary.

    Effective system monitoring is an ongoing process. Regularly assess your system’s performance, adjust your monitoring tools and practices as needed, and ensure that you are always ready to respond to potential issues.

    Conclusion

    The tools described in this section are the best Ubuntu server monitoring tools that can be used for Linux systems, especially Ubuntu. There are other tools available in this regard, but the mentioned items have been tested and as a result, the necessary reviews have been provided for you. We hope that the above information was useful for you and helped you make the right choice. Thanks for your cooperation.

  • Seamless Virtualization: Install Ubuntu on VirtualBox

    Seamless Virtualization: Install Ubuntu on VirtualBox

    The impact of the virtual machine in the system is such that it abstracts the computer hardware such as CPU, memory, disk drives, network interface card, etc. For example, consider a virtual machine. A virtual machine can be created for many purposes. This system will share the underlying hardware, but the operating environments or operating systems will be different and separate. After this brief explanation, let’s check how to install Ubuntu on a VirtualBox.

    How to Download and Install Ubuntu on VirtualBox

    To install Ubuntu on VirtualBox, you should have downloaded the ISO file for Ubuntu. You can find all the versions of Ubuntu on the Ubuntu Official Website.

    As you found the related Ubuntu file and Download it, you can install Ubuntu on your VirtualBox using the instructions below. It should be noted that you can use Linux VPS servers that are offered cheaply and with high performance on our website to use Ubuntu.

    20 Easy Steps to Install Ubuntu on VirtualBox

    1- Start by opening the VirtualBox and clicking on the New button:

    start virtualbox to install ubuntu

    2- Choose a name for VirtualBox and select the location for the installation file:

    choosing name for virtualbox

    3- Determine the RAM size for your Virtual Machine:

    determine RAM on virtualbox

    4- Now it’s time to create a Virtual hard disk to store files:

    virtual hard disk

    5- Choose the hard disk, VDI is recommended:

    choosing hard disk

    6- You can choose any of the physical storage types. It is better to choose a Dynamically allocated disk that is selected by default:

    choosing physical storage

    7- Determine your disk size and choose a destination folder to install:

    choosing name for virtualbox

    8- Now that you created the disk, boot your virtual machine and start the installation process:

    booting virtual machine

    9- If you can’t detect the installation disc automatically, browse to the file location and install the ISO file for Ubuntu:

    install Ubuntu ISO file

    10- Continue the installation file and wait for the next options:

    starting installation of Ubuntu

    11- Here you will see two options. Click on the Install Ubuntu option:

    Tip: This section might be different for other Ubuntu versions.

    install Ubuntu

    12- Check the defaults if they are compatible, click on the Continue button and proceed:

    keyboard layout on Ubuntu

    13- The default installation tab is Normal installation which is recommended, so select the type of installation. Note that if there is no need for all the features you can choose Minimal installation:

    Ubuntu installation type

    14- Now it is time to install Ubuntu, Click on the Install Now button and go on with the installation. Do not care about the Erase disk option. It is effective inside the virtual machine, these options will be intact outside the VirtualBox.

    Ubuntu installation type

    15- Now press the Continue button and carry on by writing changes on disk:

    setting time zone

    16- In this section, To setup the time zone, you should select the proper location:

    choosing location for Ubuntu

    17- It is time to select a name for your system and then a password to secure login:

    setting password for Ubuntu

    18- Wait to finish the installation process:

    finishing installation of Ubuntu - Install Ubuntu on VirtualBox

    19- Great! Now that you finished the installation, reboot the virtual machine:

    rebooting Ubuntu system - Install Ubuntu on VirtualBox

    Well done! Now that you have completed the installation successfully, you can use Ubuntu along with Windows:

    How to Run Ubuntu Along with Windows

    After the installation part, you are ready to run and use Ubuntu on your operating system.

    Note: If your operating system is not suitable for the full-screen mode of your Ubuntu and you can not fit the screen by maximizing, go through the settings below to solve this problem:

    – Click on the Devices button and then Insert Guest Addition CD image

    – Now you can see the Desk icon on the taskbar. Choose this icon and open the disk:

    running Ubuntu - Install Ubuntu on VirtualBox

    – You should Write Right-click inside the folder and choose open in the terminal. Run the command below:

    sudo apt update
    sudo apt upgrade

    – You will be prompted to insert the password. Enter it and wait for the completion:

    Authentication section

    – Now run the command below:

    ./autorun.sh

    – It’s time for the authentication. You will be asked for the password, and after checking the password, you will encounter a new terminal. Enter Yes.

    virtualbox guest

    Now you can start Ubuntu and run in full-screen mode.

    Ubuntu welcome page

    Troubleshooting Some Common Issues of Ubuntu on VirtualBox

    You may encounter various issues when setting up or using Ubuntu on VirtualBox. So, here are some common issues and their solutions:

    1- Ubuntu may not display the correct screen resolution.

    Solution:

    Install the VirtualBox Guest Additions. After booting your Ubuntu VM, go to “Devices” in the VirtualBox menu and select “Insert Guest Additions CD image.” This will allow for better integration and automatic adjustment of the screen resolution.

    2- The virtual machine can’t connect to the internet.

    Solution:

    Ensure that the VM network adapter is set to “NAT” or “Bridged” mode in the VirtualBox settings. Also, check if the network cable is connecting within the VM settings.

    3- Ubuntu runs slowly or lags in VirtualBox.

    Solution:

    • Increase the allocated RAM and CPU cores to the VM.
    • Enable 3D acceleration in the VM settings (if supported by your host system and VirtualBox version).
    • Use an SSD for your host machine if possible, as it can significantly improve performance.

    4- The sound doesn’t work in the VM.

    Solutions:

    Make sure you have installed the VirtualBox Guest Additions. You may also need to check sound settings within Ubuntu and VirtualBox.

    Conclusion

    Running Ubuntu in VirtualBox is a popular way to explore and use the Linux operating system within a virtualized environment. Studying this educational article, you now have Ubuntu installed on VirtualBox. You can use Ubuntu within the virtual machine just like you would on a physical computer. If you have any ideas about this issue please share. Happy coding!