How To Install Fastfetch on CentOS Stream 10
In this tutorial, we will show you how to install Fastfetch on CentOS Stream 10. Fastfetch has quickly become a popular system information tool among Linux enthusiasts who want a modern, efficient alternative to legacy tools like Neofetch. If you’re running CentOS Stream 10 and want to display your system information with style and speed, Fastfetch offers a compelling solution with its C-based architecture and extensive customization options. In this comprehensive guide, we’ll explore multiple methods for installing Fastfetch on CentOS Stream 10, along with configuration options, troubleshooting tips, and usage examples to help you get the most out of this powerful utility.
What is Fastfetch?
Fastfetch is a modern system information display tool designed as a faster, more efficient alternative to traditional utilities like Neofetch. Written in C rather than shell script or Python, Fastfetch delivers significantly improved performance while providing detailed system information in an aesthetically pleasing format.
Key Features and Advantages
Fastfetch stands out from other system information tools due to several distinctive features:
- Lightning-fast execution compared to Python-based alternatives like Neofetch
- Written in C for optimal performance and resource efficiency
- Extensive customization options through JSON configuration files
- Cross-platform compatibility (Linux, macOS, Windows, Android)
- Active development and community support
- Low memory footprint making it ideal for resource-constrained environments
Fastfetch displays a comprehensive set of system information including operating system details, kernel version, CPU specifications, GPU information, memory usage, disk space, network configuration, and much more. It presents this information alongside a colorful ASCII art logo representing your distribution, creating an attractive terminal display that many Linux users appreciate.
Prerequisites for Installing Fastfetch
Before proceeding with the installation of Fastfetch on your CentOS Stream 10 system, ensure you have the following prerequisites in place:
- A working CentOS Stream 10 installation with internet connectivity
- Administrative (sudo) privileges on your system
- Terminal access
- Basic familiarity with command-line operations
- Up-to-date system packages
It’s always a good practice to update your system before installing new software. Run the following command to ensure your CentOS Stream 10 system is up to date:
sudo dnf upgrade --refresh -y
This command refreshes your package lists and updates all installed packages to their latest versions. The -y
flag automatically confirms the installation of updates without requiring manual confirmation.
Method 1: Installing Fastfetch Using DNF Package Manager
The most straightforward way to install Fastfetch on CentOS Stream 10 is using the DNF package manager. DNF (Dandified Yum) is the default package manager for CentOS Stream and provides a simple, reliable method for installing software packages.
Updating System Repositories
Before installing Fastfetch, ensure your system repositories are up to date with the latest package information:
sudo dnf update
This command updates your package lists so that DNF can find and install the most recent version of Fastfetch available in the repositories.
Installation Command and Syntax
Once your repositories are updated, install Fastfetch using the following command:
sudo dnf install fastfetch
DNF will automatically resolve any dependencies required by Fastfetch and prompt you to confirm the installation. Type ‘y’ and press Enter to proceed.
If the standard repositories don’t include Fastfetch, you may need to enable additional repositories like EPEL (Extra Packages for Enterprise Linux). Install EPEL with:
sudo dnf install epel-release
sudo dnf update
sudo dnf install fastfetch
Verification Steps
After completing the installation, verify that Fastfetch was installed correctly by checking its version:
fastfetch --version
This command should display the installed version of Fastfetch, confirming a successful installation. You can also run Fastfetch with the following command to see it in action:
fastfetch
This will display your system information alongside the CentOS logo.
Troubleshooting Common Issues
If you encounter issues during installation, try these troubleshooting steps:
Package Not Found Error:
If DNF cannot find the Fastfetch package, ensure that your repositories are properly configured. You might need to enable additional repositories like EPEL.
Dependency Resolution Problems:
If dependency issues occur, try running:
sudo dnf install -y fastfetch
The -y
flag automatically resolves dependencies.
Repository Configuration Issues:
If repository errors occur, check your repository configuration files in /etc/yum.repos.d/
and ensure they’re properly configured.
Method 2: Building Fastfetch from Source
Building Fastfetch from source provides access to the latest features and allows for custom compilation options. This method is ideal for users who want the most recent version of Fastfetch or need specific customizations.
Advantages of Building from Source
Building from source offers several benefits:
- Access to the latest features and bug fixes
- Ability to customize compilation options
- Optimization for your specific hardware
- Installation of development versions with new capabilities
Installing Build Dependencies
First, install the necessary build dependencies:
sudo dnf install git cmake gcc gcc-c++ make pciutils-devel libX11-devel wayland-devel libXrandr-devel libXinerama-devel libXcursor-devel libXi-devel mesa-libGL-devel
This command installs the compiler tools and development libraries needed to build Fastfetch from source.
Cloning the Repository
Clone the Fastfetch repository from GitHub:
git clone https://github.com/fastfetch-cli/fastfetch.git
This downloads the latest Fastfetch source code to your local machine.
Compilation Steps
Navigate to the cloned repository directory:
cd fastfetch
Create a build directory and navigate into it:
mkdir build
cd build
Configure the build using CMake:
cmake ..
Compile the source code:
make
This process compiles Fastfetch for your system.
Installation Process
Install Fastfetch to your system:
sudo make install
This command installs the compiled Fastfetch executable to your system, typically in /usr/local/bin/
.
Verification
Verify the installation by checking the Fastfetch version:
fastfetch --version
Run Fastfetch to display your system information:
fastfetch
If both commands execute successfully, you’ve successfully built and installed Fastfetch from source.
Method 3: Using RPM Packages for Installation
Another method for installing Fastfetch on CentOS Stream 10 is using RPM packages. This approach combines the convenience of package management with the ability to install specific versions.
Finding the Latest RPM Packages
First, you’ll need to find the appropriate RPM package for Fastfetch. Visit the Fastfetch GitHub releases page or use the following commands to programmatically get the latest version:
FASTFETCH_VERSION=$(curl -s https://api.github.com/repos/fastfetch-cli/fastfetch/releases/latest | jq -r '.name')
echo "Latest Fastfetch version is: $FASTFETCH_VERSION"
This uses curl
and jq
to fetch and parse the latest version information. If you don’t have jq
installed, you can install it with:
sudo dnf install jq
Downloading RPM Packages
Once you have the version information, download the appropriate RPM package for your system architecture:
For x86_64 systems:
wget https://github.com/fastfetch-cli/fastfetch/releases/download/$FASTFETCH_VERSION/fastfetch-$FASTFETCH_VERSION-1.el8.x86_64.rpm
For ARM64 systems:
wget https://github.com/fastfetch-cli/fastfetch/releases/download/$FASTFETCH_VERSION/fastfetch-$FASTFETCH_VERSION-1.el8.aarch64.rpm
Installation Process
Install the downloaded RPM package using DNF:
sudo dnf install ./fastfetch-*.rpm
DNF will automatically handle dependencies and install Fastfetch on your system.
Verification Steps
Verify the installation by checking the Fastfetch version:
fastfetch --version
Run Fastfetch to display your system information:
fastfetch
These commands confirm that Fastfetch is correctly installed and functioning properly.
Basic Usage of Fastfetch
After successfully installing Fastfetch, you’ll want to understand how to use it effectively to display and customize your system information.
Running Fastfetch for the First Time
Simply run the command:
fastfetch
This command displays your system information using the default configuration. You’ll see a colorful CentOS logo alongside details about your operating system, kernel, CPU, GPU, memory, and more.
Common Command-line Options
Fastfetch offers numerous command-line options for customizing its output:
--help
: Display help information--version
: Show version information--config-file PATH
: Use a specific configuration file--logo NAME
: Use a specific ASCII art logo--no-logo
: Display information without a logo--color SCHEME
: Use a specific color scheme--list-logos
: Show available logo options--modules-file PATH
: Specify a custom modules file--preset NAME
: Use a predefined preset (like ‘small’ or ‘minimal’)
For example, to use a minimal preset:
fastfetch --preset small
This displays a condensed version of your system information.
Viewing Specific System Information
You can display specific information modules using the --structure
option:
fastfetch --structure title:os:kernel:memory
This command shows only the title, operating system, kernel, and memory information.
Configuration and Customization
One of Fastfetch’s greatest strengths is its extensive customization capabilities. You can tailor its appearance and information display to suit your preferences.
Understanding Configuration Files
Fastfetch uses a JSON with comments (JSONC) configuration file located at ~/.config/fastfetch/config.jsonc
. This file controls all aspects of Fastfetch’s behavior and appearance.
Creating Custom Configuration
Generate a default configuration file with:
fastfetch --gen-config
This creates a default configuration file that you can modify. Open it with your favorite text editor:
nano ~/.config/fastfetch/config.jsonc
The configuration file is extensively commented, making it easy to understand and modify each option.
Logo Customization
Fastfetch includes numerous built-in ASCII art logos. List available logos with:
fastfetch --list-logos
Specify a logo in your configuration file or on the command line:
fastfetch --logo centos
You can also create custom logos by adding them to your configuration file or using external ASCII art files.
Module Selection and Arrangement
Customize which information modules are displayed and their order in the configuration file. For example:
{
"modules": [
"title",
"os",
"kernel",
"uptime",
"packages",
"shell",
"resolution",
"de",
"wm",
"theme",
"terminal",
"cpu",
"gpu",
"memory",
"disk",
"battery"
]
}
You can add, remove, or rearrange modules according to your preferences.
Appearance Customization
Customize colors, formatting, and layout in the configuration file. For example:
{
"colors": {
"title": "magenta",
"keys": "blue",
"separator": "white"
},
"separators": " :",
"margin": 4
}
These settings control the colors of different elements, the separator between keys and values, and the margin between the logo and information.
Advanced Fastfetch Features
Beyond basic configuration, Fastfetch offers advanced features for power users who want to optimize their experience.
Performance Optimization
Fastfetch includes caching options to improve performance:
{
"display": {
"caching": {
"enable": true,
"timeout": 60
}
}
}
This caches information for 60 seconds, reducing execution time for subsequent runs.
Integration with Shell Startup
To run Fastfetch automatically when opening a terminal, add the following line to your shell configuration file (e.g., ~/.bashrc
for Bash):
fastfetch
For conditional execution, you might add:
if [ -x "$(command -v fastfetch)" ]; then
fastfetch
fi
This runs Fastfetch only if it’s installed and executable.
Advanced Display Options
Fastfetch supports various display protocols and options:
{
"display": {
"logo": {
"type": "sixel",
"width": 40
},
"detect": {
"kitty": true,
"sixel": true
}
}
}
These settings enable Sixel image rendering in terminals that support it, providing high-quality graphics instead of ASCII art.
Module Formatting
Customize the display format of individual modules:
{
"modules": {
"cpu": {
"format": "{name} ({cores}C/{threads}T) @ {frequency}GHz"
},
"memory": {
"format": "{used}/{total} ({percentage}%)"
}
}
}
These format strings control how information is displayed for each module.
Troubleshooting Common Issues
Even with careful installation and configuration, you might encounter issues with Fastfetch. Here are solutions to common problems.
Installation Problems
Dependency Conflicts:
If you encounter dependency conflicts, try installing with the --allowerasing
flag:
sudo dnf install --allowerasing fastfetch
This allows DNF to remove conflicting packages if necessary.
Permission Issues:
If you encounter permission errors, ensure you’re using sudo
for installation commands. For source installations, check that you have write permissions to the destination directories.
Display Errors
Terminal Compatibility Issues:
If Fastfetch doesn’t display correctly, your terminal might not support certain features. Try a simpler display configuration:
fastfetch --logo-type ascii --color-scheme default
Missing Modules or Information:
If certain information is missing, you might need to install additional dependencies. For example, for GPU information:
sudo dnf install vulkan-tools
Performance Problems
Slow Execution:
If Fastfetch runs slowly, enable caching in your configuration:
{
"display": {
"caching": {
"enable": true,
"timeout": 300
}
}
}
Memory Usage Optimization:
To reduce memory usage, disable unused modules:
{
"modules": {
"unused_module": {
"enable": false
}
}
}
Maintaining and Updating Fastfetch
Keeping Fastfetch up to date ensures you have access to the latest features and bug fixes.
Updating via DNF
If you installed Fastfetch using DNF, update it with:
sudo dnf update fastfetch
This updates Fastfetch to the latest version available in the repositories.
Updating Source Installations
If you built Fastfetch from source, update it by pulling the latest changes and recompiling:
cd fastfetch
git pull
cd build
cmake ..
make
sudo make install
This fetches the latest source code, rebuilds Fastfetch, and installs the updated version.
Managing Configurations Across Updates
Configuration files are typically preserved during updates. However, it’s good practice to back up your configuration before updating:
cp ~/.config/fastfetch/config.jsonc ~/.config/fastfetch/config.jsonc.backup
After updating, you might want to check for new configuration options:
fastfetch --gen-config new-config.jsonc
diff ~/.config/fastfetch/config.jsonc new-config.jsonc
This shows differences between your current configuration and the latest default configuration, helping you identify new options to incorporate.
Congratulations! You have successfully installed Fastfetch. Thanks for using this tutorial for installing the Fastfetch on CentOS Stream 10 system. For additional help or useful information, we recommend you check the official Fastfetch website.