RHEL BasedRocky Linux

How To Install Development Tools on Rocky Linux 9

Install Development Tools on Rocky Linux 9

Rocky Linux 9 has emerged as a reliable operating system for developers, providing a stable environment for building applications. Installing development tools is essential for compiling and building software effectively. This guide will walk you through the process of installing development tools on Rocky Linux 9, ensuring you have everything needed to kickstart your development projects.

Understanding Development Tools

Development tools are a set of programs that assist developers in creating, testing, and maintaining software applications. These tools encompass a variety of functionalities, including compiling code, debugging applications, and managing version control. Key components typically included in development tools are:

  • Compilers: Such as GCC (GNU Compiler Collection), which translates code written in programming languages into executable files.
  • Debuggers: Tools like GDB (GNU Debugger) allow developers to test and debug their programs effectively.
  • Build Automation Tools: Tools like Make automate the process of compiling code and managing dependencies.
  • Version Control Systems: Git is widely used for tracking changes in source code during software development.

Pre-requisites for Installation

Before diving into the installation process, ensure your system meets the following requirements:

  • A running instance of Rocky Linux 9.
  • A stable internet connection to download packages and updates.
  • Sudo access to install software packages.

Start by updating your system to ensure all existing packages are current. Open your terminal and run the following command:

sudo dnf update -y

Step-by-Step Installation Guide

Step 1: Accessing the Terminal

If you’re using a graphical interface, you can find the terminal application in your application menu. For remote access, use SSH to connect to your server:

ssh username@your_server_ip

Step 2: Updating Package Manager

The next step is to update the DNF package manager. This ensures that you have access to the latest package information. Execute the following command:

sudo dnf update

Step 3: Installing Development Tools Group

Rocky Linux provides a convenient way to install all essential development tools through group installations. To install the “Development Tools” group, use the following command:

sudo dnf group install "Development Tools"

This command installs a comprehensive set of packages required for software development, including:

  • GCC: The GNU Compiler Collection for C and C++ programming.
  • Make: A build automation tool that helps manage dependencies.
  • GDB: The GNU Debugger for debugging applications.
  • Git: A version control system that tracks changes in source code.
  • Other Utilities: Various utilities that facilitate software development.

Step 4: Installing Additional Tools (Optional)

If your development work requires specific programming languages or additional tools, you can install them individually. Here are some common installations:

    • Java Development Kit (JDK):
sudo dnf install java-devel
    • Python Development Tools:
sudo dnf install python3-devel
    • Node.js Development Tools:
sudo dnf install nodejs
    • Pip (Python package manager):
sudo dnf install python3-pip
    • Docker (for containerized applications):
sudo dnf install docker-ce docker-ce-cli containerd.io docker-compose-plugin

Step 5: Verifying Installation

A successful installation can be verified by checking the version of key tools. Run the following commands to confirm their installation:

gcc --version
make --version
git --version
java -version
python3 --version
node -v

If these commands return version numbers without errors, your installation was successful!

Troubleshooting Common Issues

If you encounter any issues during installation, consider the following troubleshooting tips:

  • Error: Package not found: Ensure that you have enabled all necessary repositories. You may need to enable the CodeReady Linux Builder (CRB) repository by running:
    sudo dnf config-manager --set-enabled crb
  • Error: Dependency issues: Sometimes, missing dependencies can cause installation failures. Use:
    sudo dnf install package_name --best --allowerasing

    This command attempts to resolve conflicts by allowing DNF to remove conflicting packages.

  • Error: Network issues: Ensure your internet connection is stable. You can test connectivity with:
    wget google.com

    If this fails, troubleshoot your network settings.

  • Error: Permission denied: Make sure you’re using sudo for installations that require administrative privileges.

Uninstallation of Development Tools (Optional)

If you no longer need the development tools or wish to free up space on your system, you can remove them with the following command:

sudo dnf group remove "Development Tools"

This command will uninstall all packages associated with the “Development Tools” group. If you installed additional tools individually, you would need to remove them separately using commands like:

sudo dnf remove package_name

Congratulations! You have successfully installed Development Tools. Thanks for using this tutorial for installing Development Tools on Rocky Linux 9 system. For additional help or useful information, we recommend you check the official Ubuntu website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!

r00t

r00t is an experienced Linux enthusiast and technical writer with a passion for open-source software. With years of hands-on experience in various Linux distributions, r00t has developed a deep understanding of the Linux ecosystem and its powerful tools. He holds certifications in SCE and has contributed to several open-source projects. r00t is dedicated to sharing her knowledge and expertise through well-researched and informative articles, helping others navigate the world of Linux with confidence.
Back to top button