Что такое TAR? Полное руководство по формату TAR

Узнайте, что такое файлы TAR, как они работают и когда их использовать. Полное руководство по формату TAR без загрузки и регистрации. Бесплатный онлайн-инструмент, без загрузки и регистрации. Работает в браузере, мгновенно и безопасно. Поддерживает множество форматов.

Бесплатный онлайн-конвертер файлов. Работает в Chrome, Firefox, Safari, Edge, Opera и других современных браузерах на Windows, macOS, Linux, Android и iOS. Не требует установки ПО или регистрации. Все преобразования выполняются прямо в браузере, поэтому ваши файлы не покидают устройство. Бесплатно и без учётной записи.

TAR

Что такое TAR? Полное руководство по формату TAR

Полное руководство по файлам TAR - технические детали, плюсы и минусы, примеры использования и часто задаваемые вопросы

Последнее обновление:

Year1979
TypeArchive
UsageUnix file packaging

What is it?

TAR (Tape Archive) is a file packaging format originating from Unix in the late 1970s. The name refers to its original purpose: archiving files to magnetic tape drives for backup. TAR bundles multiple files and directories into a single archive file while preserving file system metadata including file permissions, ownership, timestamps, hard links, and symbolic links - attributes that are essential in Unix and Linux environments but which ZIP archives do not reliably preserve.

A plain TAR file does not compress data - it only bundles files together, similar to how you might rubber-band a stack of papers. Compression is applied on top of the TAR archive using separate tools: gzip creates.tar.gz, bzip2 creates.tar.bz2, and xz creates.tar.xz. This separation of concerns (packaging vs. compression) is a Unix design philosophy. TAR archives are the universal distribution format for Linux software source code and system backups.

Technical Specifications

OriginUnix, AT&T Bell Labs, late 1970s
File Extension.tar
MIME Typeapplication/x-tar
CompressionNone (packaging only)
Metadata PreservedPermissions, ownership, timestamps, symlinks, hard links
Common Variants.tar.gz,.tgz,.tar.bz2,.tar.xz
Toolstar command, GNU tar, 7-Zip, WinRAR

Pros & Cons

Advantages

Сохранение метаданных Unix

Preserves file permissions, ownership, and symbolic links that are lost in ZIP and other Windows-centric formats.

Универсальный на Unix/Linux

The tar command is installed on every Unix, Linux, and macOS system by default.

Поддержка потоковой передачи

TAR archives can be streamed directly through pipes, enabling network backup and compression without temporary files.

Гибкое сочетание сжатия

Pair with any compression tool (gzip, bzip2, xz, zstd) to get the exact speed-to-compression trade-off you need.

Disadvantages

Нет встроенного сжатия

A plain.tar file is often larger than the original files because it adds header overhead without reducing data size.

Нет произвольного доступа

Extracting a single file from a TAR archive requires reading through the entire archive sequentially.

Ограниченная поддержка Windows

TAR is not natively supported on Windows outside of WSL and PowerShell, requiring third-party tools like 7-Zip.

Поведение конкатенации

Appending to a TAR archive adds duplicate entries for updated files rather than replacing them, which can cause confusion.

When to Use It

Here are the most common situations where TAR is the right choice:

Распределение программного обеспечения для Linux

Open-source software releases are distributed as tar.gz or tar.xz source packages for compilation.

Резервное копирование системы

Use tar to create complete backups of Linux filesystem directories including all permissions and ownership metadata.

Экспорт образов Docker

Docker exports container images as TAR archives using docker save.

Передача данных между системами Unix

TAR is the standard way to package files for transfer between Unix/Linux systems without losing filesystem attributes.

How to open a TAR file

TAR files, commonly used in Unix and Linux environments, can be handled by a variety of software tools ranging from professional applications to free and open-source options. Professional tools often provide advanced features for managing large archives, while free and open-source solutions cater to users looking for straightforward extraction and viewing capabilities. Browser-based tools offer convenience for quick access without installation, while built-in system utilities provide basic functionality for users who prefer not to use third-party software.

When choosing software for TAR files, key decision factors include the fidelity of file handling, whether the tool supports editing or is limited to viewing, and the overall cost model. Platform compatibility is also crucial, as some tools are restricted to specific operating systems. Additionally, users should consider their export needs, as some applications allow for conversion to other formats, which can be beneficial when sharing files with users who may not have TAR support.

WinRAR 6.20

Windows, macOS, LinuxOne-time $29.00

WinRAR is a powerful archive manager that supports TAR files among various other formats. It allows users to create, manage, and extract TAR archives with high fidelity, ensuring that file permissions and metadata are preserved during the process.

Ключевые функции
  • Create and extract TAR archives
  • Preserve file permissions and metadata
  • Multi-volume archive support
  • Strong AES-256 encryption
  • Integrated file repair tool
Преимущества
  • Robust compression algorithms
  • User-friendly interface
  • Comprehensive format support
Ограничения
  • Paid software after trial period
  • Limited editing capabilities

Экспортирует в: ZIP, RAR, 7Z, ISO

Лучше всего для: Choose WinRAR for a comprehensive and user-friendly solution for managing TAR files with advanced features.

Перейти WinRAR →

7-Zip 22.01

Windows, macOS (via unofficial ports), LinuxFree (GPL)

7-Zip is a free and open-source file archiver that excels in handling TAR files. It offers a high compression ratio and supports extraction and creation of TAR archives, making it a versatile tool for users who need to manage various archive formats.

Ключевые функции
  • Create and extract TAR files
  • High compression ratio
  • Support for multi-format archives
  • Command line interface for automation
  • File integrity check
Преимущества
  • Completely free and open-source
  • Lightweight and efficient
  • Strong community support
Ограничения
  • Limited GUI compared to competitors
  • Less intuitive for beginners

Экспортирует в: ZIP, GZ, TAR.GZ, WIM

Лучше всего для: 7-Zip is ideal for users seeking a free, powerful tool for managing TAR files without the need for extensive features.

Перейти 7-Zip →

The Unarchiver 4.3.0

macOSFree

The Unarchiver is a simple and effective tool for macOS users to extract TAR files and other archive formats. It focuses on ease of use, allowing users to quickly access the contents of TAR archives without complex settings or configurations.

Ключевые функции
  • Extract TAR and other archive formats
  • Support for various compression methods
  • Integration with Finder for easy access
  • Automatic file association
  • Preserves original file structure
Преимущества
  • User-friendly interface
  • Quick extraction process
  • Lightweight and efficient
Ограничения
  • No archive creation capabilities
  • Limited to macOS platform

Экспортирует в: N/A

Лучше всего для: The Unarchiver is perfect for macOS users who need a straightforward tool for extracting TAR files without additional features.

Перейти The Unarchiver →

PeaZip 9.2.0

Windows, LinuxFree (GPL)

PeaZip is a free file archiver that supports TAR file management among many other formats. It provides a graphical interface for creating and extracting TAR files, along with advanced features like file encryption and batch processing.

Ключевые функции
  • Create and extract TAR files
  • File encryption and secure deletion
  • Batch processing for multiple files
  • Customizable user interface
  • Portable version available
Преимущества
  • Feature-rich with encryption options
  • Cross-platform compatibility
  • Open-source with active development
Ограничения
  • More complex interface for beginners
  • Performance can vary with large files

Экспортирует в: ZIP, 7Z, ARC, GZ

Лучше всего для: PeaZip is suitable for users who need a versatile and feature-rich tool for handling TAR files, especially those who value security.

Перейти PeaZip →

Convert TAR Files

Need to convert your TAR files? Use our free online converter.

Convert TAR Files

Источники

  1. TAR archive format - Library of Congress
  2. GNU tar Manual - GNU Project
  3. tar (computing) - Wikipedia