Questions tagged [tar]

An archive file format (and the program that reads it) commonly used on Unix and Linux.

Filter by
Sorted by
Tagged with
5 votes
2 answers
826 views

How to list only tar files

I have a silly problem usr01@srvlnx01:~$ sudo ls /var/opt/gitlab/backups/ 1685014011_2023_05_25_13.2.3_gitlab_backup.tar 1685016443_2023_05_25_13.2.3_gitlab_backup.tar tmp but usr01@srvlnx01:~$ ...
0___________'s user avatar
0 votes
2 answers
54 views

Tar owner map when extracting

Tar has several options to affect how file and directory ownership will be stored in that tar file. For example --numeric-owner, or --owner-map. These options directly affect how the tar file will be ...
psznm's user avatar
  • 1
0 votes
0 answers
110 views

ZST Compression Error In LMDE5 (Debian 11) Breaks Apt

I recently installed WeChat via the deepin-wine install method described below: First, I ran this in terminal: wget -O- https://deepin-wine.i-m.dev/setup.sh | sh Then I used the Synaptic Package ...
mjones's user avatar
  • 267
1 vote
0 answers
58 views

Is it possible to open a TAR file without a header and metadata?

I am trying to open a TAR file without a header containing the file information and other metadata. I know for certain this is a TAR file. Running xxd and head on the tar gives me the following: ...
Rogue's user avatar
  • 53
1 vote
1 answer
36 views

What will happen if I run out of tape during backup?

For example: if I use tar to write on LTO-1 tape (200/100 gb) and during the backup tar hits the end of tape. Will I be able to restore such a corrupted archive? How to solve the possible problem? How ...
Ian2127's user avatar
  • 13
1 vote
2 answers
59 views

Why does changing a source file's name affect the size of its compressed version?

Using gzip on CentOS 7, I just compressed a source file into a .gz file, then I found I got the source file's name wrong, so I changed the source file's name and compressed it again, and interestingly ...
NoobAdmin's user avatar
0 votes
1 answer
89 views

Find log files under multiple directories and compress each file with its own name and date

I have multiple directories like below and I want to compress each file in place. /var/dir1/logs/logfile.log /var/dir2/logs/logfile.log /var/dir3/logs/logfile.log I want to use find and tar with ...
Tayfun Yuksel's user avatar
1 vote
1 answer
45 views

Getting an error when trying to create a tarball of my Redhat VM

I'd appreciate some assistance as to where I'm going wrong please. Ultimately my objective is to have Redhat available via Windows Subsystem for Linux. Reading the instructions on the following ...
user20960947's user avatar
0 votes
1 answer
98 views

How to verify a tar file in Windows?

In an effort to create more disk space I am trying to compress a bunch of my data into .tar.gz files. This takes a long time, so I'd like to automate the process in a .bat file. Ideally I would create ...
David K's user avatar
  • 311
1 vote
0 answers
480 views

tar error: Unexpected EOF in archive

I am trying to extract large tar folders, using the tar command tar -xvif v1-2-val.tar.gz but I get the error gzip: stdin: invalid compressed data--format violated tar: Unexpected EOF in archive tar:...
user787's user avatar
  • 11
0 votes
1 answer
108 views

Why graalvm is not appearing in update-alternatives --config java?

I downloaded the file graalvm-ce-java17-linux-amd64-22.3.0.tar.gz and extract to the location usr/lib/jvm. Then i set the environment path with command export PATH=/path/to/<graalvm>/bin:$PATH ...
Prakash Karkee's user avatar
0 votes
0 answers
358 views

tar: Error exit delayed from previous errors

i have completed the following steps. pip install sense2vec==1.0.2 wget https://github.com/explosion/sense2vec/releases/download/v1.0.0/s2v_reddit_2015_md.tar.gz for the third command it throws ...
Love Aggarwal's user avatar
0 votes
1 answer
92 views

tar: samtools-1.9.tar: cannot open: no such file or directory

I am trying to run the command to install samtools on ubuntu but I am facing a problem here whenever I try to use tar. Input : /c/Users/Hamza Bilal$ tar -xvf samtools-1.9.tar.bz2 The Output I get ...
Talia's user avatar
  • 3
1 vote
1 answer
30 views

How to apply to multiple filenames in Windows command line?

I'm using tar in Windows 10 command line to extract a specific file from a bunch of archives. I'm quite experienced in regex, but I have very little experience in Windows commands. I'm using this ...
Dan Chaltiel's user avatar
1 vote
1 answer
763 views

Very slow extraction of a tar file on an external drive

I am trying to unzip a tar file on an external hard drive which is taking way to long. The file is 100GB compressed and will be 500GB uncompressed. I am using the following commands on windows command ...
phdstudent's user avatar
1 vote
1 answer
55 views

tar lzma autocompression produces the error "This does not look like a tar archive"

The following script mkdir test && cd test mkdir files touch files/{1,2,3} tar --create --file "test.lzma" files/{1,2,3} --auto-compress mkdir extracted_files tar --extract --file &...
cppbest's user avatar
  • 33
-1 votes
1 answer
1k views

Cannot open: No such file or directory tar: Error is not recoverable: exiting now in Debian

burakkaymaz4444@penguin:~$ sudo apt update Hit:1 https://deb.debian.org/debian bullseye InRelease Hit:2 https://deb.debian.org/debian bullseye-updates InRelease Hit:3 https://deb.debian.org/debian-...
Burak Kaymaz's user avatar
0 votes
1 answer
514 views

7zip program infected with malwares and viruses [duplicate]

7zip program infected with malwares and viruses. Virus Total scanned the installer as good with malicious and suspecious relations. The 7-zip program 7-zip v22.01 - (may be infected) From the Virus ...
smith john's user avatar
0 votes
0 answers
592 views

The most complete backup of /dev/sdX with dd, tar, gz, xz

What is the most complete way to backup/restore entire /dev/sdX (to/from a file) including device partition table and partition flags, all possible metadata, owners, file permissions, ACLs, creation/...
Monerig's user avatar
  • 31
0 votes
2 answers
384 views

How to extract How uncompress .tar.lrz file in centos 8?

I have .tar.lrz file in mac which I have to decompress. I am trying decomprees file from https://github.com/lin-tan/CoCoNut-Artifact/releases/tag/training_data_1.0.0 I already tried: yum install lrzip ...
Exploring's user avatar
  • 109
0 votes
0 answers
601 views

Error extracting tar.xz files on Linux

I have a bunch of tar.xz files I need to extract. I tried using the following command, but get errors when it tries to extract individual files. tar -xJf file.tar.xz tar: Example_path/and_file_name....
David K's user avatar
  • 311
1 vote
2 answers
2k views

Error extracting tar.xz files in Windows using command line

I have a bunch of tar.xz files I need to extract. I tried using the following command, but get an error. tar -xJf "S:This_Is\the path\to_my_file.tar.xz" tar: Error opening archive: Can't ...
David K's user avatar
  • 311
0 votes
1 answer
48 views

preserve hidden attribute on directory when using tar

Here is the shell script I'm writing to automate the task of copying a specific Vue project to another location on a Windows 11 machine: # declare and initialize variables source="/z/files/...
knot22's user avatar
  • 103
0 votes
0 answers
263 views

Need faster archiving+compression of folders in .zip instead of .tar extension

I have a folder inside which are sub-folders and files. We currently use 7za to archive+compress in the .zip file extension. Specifically, following is the command that we use: /usr/libexec/p7zip/7za ...
Uchiha AJ's user avatar
0 votes
1 answer
469 views

How to make tar use constant memory?

I need to compress multiple files across multiple folders (>32GB) the way we compressed before via code used too much memory, so I used tar instead. I used tar with lz4 with tar -I lz4 -cf foo.tar....
Stack Overflow's user avatar
0 votes
0 answers
317 views

Windows tar compress command doesnt appear to include subdirectories

I am trying to compress all files and folders in the current folder (on my Windows 10 environment) so I can extract them on my Raspbian environment. Im using a Powershell script with the tar command ...
Jimbo's user avatar
  • 161
0 votes
1 answer
43 views

Can someone please explain how to loop the backup logic ( below mentioned script )

Could someone please explain how can i loop the below logic, This logic needs to run for every week. For eg : In 1st week in source folder i have a files and folder called stack.txt, webmethods, ...
Varun K M's user avatar
-1 votes
1 answer
115 views

Is there a way to browse inside .tar files in Windows, like you can with .zip files?

Windows can easily browse inside .zip files, add and remove files, open files inside .zip. Is there any optional Windows component I can install to do this with .tar files too?
Richard's user avatar
  • 420
0 votes
0 answers
203 views

Only one file is extracted from huge tar archive

I have a 124GB tar archive. When I run: tar xvf archive.tar I get only a 1.1GB file (which is one of the expected file). What happened to the rest of the files ? Is there a way to recover them? I ...
ma3oun's user avatar
  • 101
0 votes
0 answers
382 views

how to stream a large directory to a HTTP server via CURL put?

I have a large directory that I want to upload to a remote server using only tar and curl. I don't need any compression as the directory already contains compressed data. here is the command I am ...
user375868's user avatar
26 votes
2 answers
8k views

What does `tar: Cannot connect to …: resolve failed` mean?

I'm writing a practice bash script that saves a folder as a tar archive with a name date-foldername.bak The script fails when unformatted date is inserted as part of the filename, so 2022-05-09-work ...
user1143191's user avatar
0 votes
0 answers
851 views

Create tar with directory and only specific files

I have this directory structure /Foo A B C D I'd like to create a foo.tar with this structure /Foo A D where files A-B-C-D aren't related so I need to manually specify which one add and ...
Moia's user avatar
  • 101
0 votes
1 answer
246 views

How to compress the main folder which includes certain sub folder using tar

Assume we have a folder structure as below main_folder - sub_folder1 - sub_folder2 - sub_folder3 - valid_folder1 - valid_folder2 - junk_folder1 - junk_folder2 ...
Malaiselvan's user avatar
2 votes
0 answers
113 views

Extract files from tar directly into new tar

I have a large tar.gz of a whole system (basically tar czpf --one-file-system /mnt/usb/backup.tar.gz -C / .). I want to end up with a new tar.gz file that is just the contents of a subfolder (./home) ...
Cameron Tacklind's user avatar
2 votes
1 answer
231 views

How to compare huge sparse files efficiently?

There are two sparse files. They are proved identical by diff. But it took 20 minutes (too long time) to compare. I am thinking of taring them into tiny files to speed up the comparison. But they tar ...
midnite's user avatar
  • 511
1 vote
1 answer
1k views

Errors with tar/split backups

I am trying to create backups on an external exFAT disk, but I keep getting errors. I have to use FAT (exFAT or FAT32), so my options are very limited. I will need this to backup both macOS and ...
senseiwa's user avatar
  • 113
1 vote
1 answer
135 views

Create .tar back-up across two drives on Windows 10

My main drive (D:) has 500GB capacity. I also have two backup drives (both 250GB capacity). I want to back up the contents of the 500GB drive and spread it across the two 250GB drives. 7-zip allows to ...
degebine's user avatar
0 votes
0 answers
541 views

Is there a way to extract partial content from a tar.xz file?

I have a tar.xz file in a server. I would like to see what is inside and extract some of the content. The problem is that this file is 1.24TB large! My local PC can not hold it. Is there a way to ...
KansaiRobot's user avatar
2 votes
1 answer
396 views

tar delete file with pipe without extract: what is the correct syntax?

I am using GNU tar to process a tar(layer of a docker image) to modify some jars in that. I am doing: save image to disk as tar extract it, so I have each layer in a dir enter each layer, I have a ...
WesternGun's user avatar
0 votes
1 answer
398 views

I cannot seem to get GALFIT installed on my computer

I downloaded the code provided on the GALFIT website for debian/ubuntu 32. I then decompressed it, so it is just a folder with "galfit" being the only thing inside of it. When I look up &...
swansonalaina's user avatar
1 vote
0 answers
76 views

Compress a folder with internal complex folders tree and UTF-8 mixed languages files and formats for archive

I have a cloud folder on my hard-drive which I want to archive, in-order to do so I would like to compress it using best of choice compressor for that task : Complex sub-tree of internal folders with ...
James Roeiter's user avatar
0 votes
1 answer
2k views

tar command not working

I'm trying to figure out why is the following tar command not working - I've tried the following 2 versions & both don't work - Version 1 tar -c --use-compress-program=pigz -f /home/jhonst/...
usert4jju7's user avatar
2 votes
0 answers
1k views

No space left on device in Linux although enough disk space and inode available

I ran into this problem when copying a lot of files using tar -cf - * | (cd ../bar; tar -xf - ); I did search on the issue, and found the below suggestions, none of which worked for me. This problem ...
surfer21's user avatar
1 vote
1 answer
61 views

Trying to replicate tar output format on windows 10

I've been managing data at my work for over 20 years and we've always used tapes written with the unix command tar. The biproduct of this is a tar table of contents that I store for reference when ...
dinki's user avatar
  • 13
0 votes
2 answers
710 views

Can one extract the files in a .tar.gz and upload them individually onto cPanel?

I am in the process of migrating my website from Bluehost to a different hosting company. I downloaded the entire backup of the cPanel (61 GIG) successfully, but uploading files is incredibly much ...
user avatar
3 votes
2 answers
1k views

Decompress a tar.xz file using all cores

I have 37 GiB File which was created by tar + xz. I have a server with 6 cores, so for maximum compression speed I want to use all my 6 cores using this command XZ_OPT='-T0 -9 –memory=75%' tar -cJf ...
alanyalilar's user avatar
0 votes
1 answer
209 views

Explaining performance irregularities when unpacking .tar.gz archives

This question is about the performance of unpacking, not "how to" unpack. I notices this just a few days ago, when I started extracting several .tar.gz (will refer to them as archives now) ...
PKlumpp's user avatar
  • 103
0 votes
1 answer
184 views

How to fix tar/gzip files after change extension?

I am new in linux. Today I got issue.Then I run tar to zip multiple files(hundreds files) I got a.php.gz,b.php.gz,etc. After that I rename files via command line find /usr/local/var/www/html -depth -...
xanka's user avatar
  • 101
0 votes
0 answers
1k views

Error when tar a compressed file

I try to install krona tools, so I downloaded its archive first as follows: curl -LOk https://github.com/marbl/Krona/releases/download/v2.7/KronaTools-2.8.tar then #untar tar -xvf KronaTools-2.8.tar ...
Eman's user avatar
  • 1
4 votes
2 answers
413 views

How do you untar multiple files into multiple subdirectory based on filename

I have a single tar file containing about 19 million files (no folders) 0000107b869682826003b04a40e6394.txt 00029237482s8923789423ud8923892.txt 2c002y8378723887292377a79237649.txt ...
Algorithmatic's user avatar

1
2 3 4 5
16