How to Install Wireshark on Fedora 40 or 39

Wireshark is a premier tool for network analysis, widely utilized for its ability to capture and dissect network traffic in real-time. It is essential for diagnosing network issues, performing security audits, and gaining insights into network protocols. Whether you’re managing a complex enterprise network or learning about network communications, Wireshark offers the versatility and depth needed to analyze packets down to the smallest details.

To install Wireshark on Fedora 40 or 39, you can use the DNF package manager through Fedora’s AppStream. This approach ensures that you get a stable, up-to-date version of Wireshark that integrates smoothly with your Fedora system. This guide will show you how to set up Wireshark on your system, enabling you to effectively monitor and troubleshoot network traffic.

Update Fedora Packages Before Wireshark Installation

To begin, update your Fedora system packages. This step is crucial for maintaining compatibility and avoiding conflicts, as Fedora frequently updates its packages.

Execute the command below in your terminal:

sudo dnf upgrade --refresh

Install Wireshark via DNF Command

Wireshark is readily available in Fedora’s repository. This accessibility simplifies installation and ensures easy updates.

Use the command below to install Wireshark:

sudo dnf install wireshark

For those needing additional features, the Wireshark developer (devel) package is also an option:

sudo dnf install wireshark-devel

After installation, verify its success and check the installed version of Wireshark with the following:

wireshark -v

Adding User to Wireshark Group

Add your username to the Wireshark group to run Wireshark without permission issues. Neglecting this step could result in errors, such as the inability to start recordings due to permission denials.

Initially, switch to the root account:

su

If you’ve forgotten or never set a root password, establish one with:

sudo passwd root

Then, reaccess the root account with the su command.

Now, execute this command to add your username to the Wireshark group, replacing _your_username_ with your actual username:

usermod -a -G wireshark _your_username_

For example, if your username is ‘joshua’:

usermod -a -G wireshark joshua

After completing this step, log back into your regular account:

su <account name>

For example:

su joshua

An alternative way is just using the following command.

sudo usermod -a -G wireshark _your_username_

Alternatively, you can add your username to the Wireshark group using a single command:

sudo usermod -a -G wireshark _your_username_

This approach ensures you have the necessary permissions to run Wireshark effectively on Fedora Linux.

Launch Wireshark

CLI Method to Launch Wireshark

Wireshark can be launched quickly using a simple command for users who prefer the command line or are already working within a terminal. This method is efficient for those who are comfortable with the terminal environment.

To open Wireshark, type the following command in your terminal:

wireshark

This command initiates Wireshark, allowing immediate access to its features from the command line.

GUI Method to Launch Wireshark

Wireshark can be opened without terminal commands for desktop users who prefer a graphical approach. This method is particularly convenient for those who primarily navigate their system using a graphical interface. To launch Wireshark through the GUI:

  1. Click on the “Activities” menu at the top left corner of your screen.
  2. Select “Show Applications” to view all installed applications.
  3. Find and click on the Wireshark icon.

Managing Wireshark

Update Wireshark

To keep Wireshark up-to-date on Fedora Linux, use Fedora’s package management system. Regular updates enhance security, introduce new features, and improve performance.

Execute the following command to update Wireshark along with other system packages:

sudo dnf upgrade --refresh

This command refreshes the repository metadata and upgrades all the packages to their latest versions, including Wireshark, ensuring you have the most recent enhancements and fixes.

Remove Wireshark

When Wireshark is no longer needed on your Fedora system, you can cleanly uninstall it using the package manager. This ensures that no unnecessary files are left behind.

Use the command below to remove Wireshark from your system:

sudo dnf remove wireshark

This command will safely uninstall Wireshark, freeing space and removing its functionalities from your system. Remove any unused dependencies installed with Wireshark to keep your system lean.

Conclusion

After setting up Wireshark on Fedora using the AppStream and DNF package manager, your system is now equipped with a robust tool for network analysis. This method provides a seamless installation and ensures that Wireshark is fully compatible with Fedora. To keep Wireshark operating at its best, it’s advisable to regularly check for updates through DNF, ensuring you have access to the latest features and security patches. With Wireshark in place, you’re well-prepared to dive deep into your network traffic and maintain a secure and efficient network environment.

Joshua James
Follow me
Latest posts by Joshua James (see all)

Leave a Comment