-
-
Notifications
You must be signed in to change notification settings - Fork 2
Arch Linux Compression Tools
Mattscreative edited this page Dec 5, 2025
·
2 revisions
Complete beginner-friendly guide to compression tools on Arch Linux, including tar, zip, 7z, and compression utilities.
Create tar:
# Create tar
tar -cf archive.tar files/
# Create compressed tar
tar -czf archive.tar.gz files/
# Create bzip2
tar -cjf archive.tar.bz2 files/
# Create xz
tar -cJf archive.tar.xz files/Extract tar:
# Extract
tar -xf archive.tar
# Extract to directory
tar -xf archive.tar -C /path/to/directory
# List contents
tar -tf archive.tarCreate zip:
# Install zip
sudo pacman -S zip
# Create zip
zip archive.zip files/
# Recursive
zip -r archive.zip directory/Extract zip:
# Install unzip
sudo pacman -S unzip
# Extract
unzip archive.zip
# Extract to directory
unzip archive.zip -d /path/to/directoryInstall 7z:
# Install 7-Zip
sudo pacman -S p7zip
# Create archive
7z a archive.7z files/
# Extract
7z x archive.7zUse gzip:
# Compress
gzip file.txt
# Decompress
gunzip file.txt.gzUse bzip2:
# Compress
bzip2 file.txt
# Decompress
bunzip2 file.txt.bz2Use xz:
# Compress
xz file.txt
# Decompress
unxz file.txt.xzCheck archive:
# Test tar
tar -tf archive.tar
# Test zip
unzip -t archive.zipFix permissions:
# Extract with permissions
tar -xpf archive.tarThis guide covered tar, zip, 7-Zip, and other compression tools.
- Find Command Guide - File searching
- Arch Linux System Configuration - System setup
- ArchWiki Compression: https://wiki.archlinux.org/title/Compression
This guide is based on the ArchWiki. For the most up-to-date information, always refer to the official ArchWiki.