Last call to make your voice heard! Our 2022 Developer Survey closes in less than a week. Take survey.

Questions tagged [tar]

GNU tar creates and manipulates archives which are actually collections of many other files; the program provides users with an organized and systematic method for controlling a large amount of data.

Filter by
Sorted by
Tagged with
0 votes
1 answer
46 views

Tar and 7z compression on Linux - what's the difference?

I have a problem! I have a backup script in python. It backups all the folders in /var/www/ into different .tar.7z for each folder inside /var/www/ The problem is that the compression time is very ...
user avatar
  • 329
1 vote
1 answer
26 views

What behavior has tar on TERM signal while doing incremental backup?

I've written a backup script in python using tar (via subprocess) to do incremental backups of my files. As some of the full backups are rather big (like my picture folder) and take multiple hours to ...
user avatar
  • 157
0 votes
1 answer
196 views

Can we use make tar multi-threaded without any sort of compression

I have to backup 500GB using the traditional tar -cvf command (without any compressions) However tar is adding each file one by one and this way it's taking a very long time Is there any way to make ...
user avatar
  • 148
1 vote
0 answers
488 views

tar -xvf error "Can't restore time" when trying to extract in certain directories on mac osx but works in others

Strangest thing. I downloaded the openjdk release here: https://jdk.java.net/16/ When running tar -xvf on the file in the ~/Downloads directory it works fine. But when running in /tmp or another ...
user avatar
3 votes
1 answer
79 views

Tar extracting from multi-volume tape whilst computing shasums

As part of our backup system, we replicate zfs datasets from a TrueNAS system to a couple of backup servers, one of which is running TrueNAS Scale and has a LTO-5 tape drive connected. We occasionally ...
user avatar
  • 41
0 votes
1 answer
41 views

Execute following steps after rsync is finished

First I thought that rsync isn't syncing everything described here Limitations of rsync? Not syncing everything Now after a day I found out that it was actually still working/ running and now all the ...
user avatar
  • 113
1 vote
1 answer
28 views

Validate tar extraction

I have a script that processes large tar.bz2 and tar.gz files. So the user doesn't think it has locked up they are piped in from pv: pv redacted.tar.bz2 | tar -xj pv redacted2.tar.gz | tar -xz ...
user avatar
5 votes
1 answer
329 views

Unable to compress 18GB file on Ubuntu Linux 18.04

It never happened to me before, but I'm unable to do a simple task such as compressing a 18.5 GB file on Ubuntu Linux 18.04 with any of the popular compressing tools such as gzip, bzip2 and 7z. All of ...
user avatar
  • 181
0 votes
1 answer
135 views

Renaming a tar file in unix script

cd /var/opt/sw/e4/data/dev/e4_dev/DEVL3/EW/EWD1/DATA/AED/INPUT for file in *;do tar -czf ../OUTPUT/"${file}".tar; done According to the above code the files in input path eg. aedlog, aaalog....
user avatar
0 votes
2 answers
5k views

Creating backups with tar.gz and rsync

I'm trying to use this bash script to create and send the tar.gz file to my backup server, some reason it doesn't seem to copy it, is there a better solution to what I'm trying to do? I'd rather have ...
user avatar
1 vote
1 answer
1k views

How do untar as the current user by default?

I have a batch of CentOS EC2 instances, which have an additional user added to them via ansible. Normally when unpacking a tarball, the owner is centos.centos (default login for EC2 Centos). When an ...
user avatar
  • 11
1 vote
2 answers
215 views

How can I transfer a dedicated bare metal server into a VM?

I have the following problem: We have a dedicated (bare metal) hardware server (Debian 10) on which we have no direct physical access. Now I want to transfer all data and applications that are on this ...
user avatar
  • 4,957
0 votes
0 answers
42 views

Diff a tarball on stdin against a directory hierarchy?

I have a multi-terabyte filesystem I want to diff against a multi-terabyte tar file. The tar file is only available from stdin - no seeking allowed. I do not have the disk space to write the tar on ...
user avatar
0 votes
1 answer
511 views

How to owerwrite directory with tar?

I want to extract files with tar so that the whole directory will be owerwritten. I added --overwrite-dir but still old files in test dir remains. For the test, I have /home/ubuntu/f1/test/first.log ...
user avatar
  • 151
2 votes
1 answer
188 views

Fastest way to tranfer data over the network between two servers

I have two storage servers at home - one is my workstation, which has a pair of 3TB disks in RAID1. At first, I stored all of my data there. Recently, I received a small SBC with four 1TB disks. I set ...
user avatar
  • 135
0 votes
2 answers
92 views

RHEL 7 security patch installation from tar

Novice Linux guy here I have a huge (5G) linux-security-patches tar. Upon extracting, I see its got loads of rpms. What is the most efficient way to install them all ? Also, is it same as installing ...
user avatar
1 vote
1 answer
115 views

How to take backups resilient to data corruption , fast and reliable on Linux? [closed]

I need a resilient backup solution. I was using tar with pigz, however I am afraid of tar.gz corruption and losing data. Projects are between 4TB - 25TB of data for each project folder. We are talking ...
user avatar
0 votes
1 answer
127 views

Tar directory is new error

I am trying to make a backup of two directories, /etc/httpd and /etc/letsencrypt I am using the command tar Pcfvg httpd_backup.tar /etc/httpd/ /etc/letsencrypt/ >/dev/null The redirect to /dev/...
user avatar
0 votes
1 answer
31 views

Does tar create point-in-time snapshots?

I know that tar can be used to create a backup. However I wonder if the operation creates point-in-time backups or not. Basically I wonder if it grants consistency if the directory and files are ...
user avatar
0 votes
0 answers
20 views

Error while trying to backup site files

# tar -czf /backup/backup.tar.gz /var/www/html tar: Removing leading `/' from member names tar: /var/www/html/wp-content/uploads/2020/02: file changed as we read it # ls -la total 17160456 drwxr-xr-x ...
user avatar
4 votes
2 answers
1k views

Hash files in tar file

I have two *.tar files with similar contents. I want to verify which files are the same. A lot of the files are big so I comparing hashes would require extracting every file from each tar and ...
user avatar
0 votes
0 answers
83 views

tar | pigz dies if run under cron

I run a kind of backup script using tar joint with pigz for compression. The problem is that tar -zcf /file.tar.gz /folder runs under cron. While tar -I pigz -cvf /file.tar.gz /folder nor tar ...
user avatar
  • 151
2 votes
1 answer
110 views

Best strategy for daily back up of terabytes of data with millions of files

Currently I create an NFS and mount it on a special server that does the actual backups and uploads it to s3. My main concern is I feel like overcomplicated this simple task. I schedule cron job to ...
user avatar
  • 164
1 vote
1 answer
1k views

Why tar flag --strip-components ignored sometimes?

I have an automated docker images build where I download elasticsearch archive and extract it via: tar zxf archive.tar.gz --strip-components=1 -C /path/to/dir And it always worked until the latest ...
user avatar
  • 223
0 votes
1 answer
744 views

How to exclude a folder by name recursively when making a tar archive?

I know it is possible to exclude a particular folder by a command like this: tar --exclude='/srv/www/project/node_modules' -zcvf /backup/project.tgz . My question how to exclude all folders named ...
user avatar
  • 204
2 votes
1 answer
2k views

Backup to remote server and create tar on the fly

I would like to backup a directory from my production server to a backup server using rsync. My current solution: tar directory on production server send to remote server via rsync My Problem with ...
user avatar
  • 123
2 votes
2 answers
508 views

Extracting single file from large tar.gz file

I have an incredibly large tarball. I'd extract several files out of many thousands within the archive. I'm on CentOS 6.10 running GPFS 4.2.3. I've seen from this answer that pigz is useful in ...
user avatar
0 votes
1 answer
30 views

Command/script to extract "sub-tarball" from tarball

I am aware of that I can extract single/multiple files from a tar archive, but is there a command that I can easily pass to immediately create a "sub-tarball" from an existing tar archive? This is ...
user avatar
0 votes
2 answers
431 views

How to untar a very large file with missing space

I have reinstalled my server and before that i did a backed up. My backup is a tar file without special compress option (meaning that the size of the tar file is approximately the same than the size ...
user avatar
0 votes
1 answer
318 views

abnormal very high CPU during lengthy write operations

I have a set of large files which I sometimes copy back and forth between a Linux box and a Windows box. The files are each about 2 GB, and there tend to be 10 or so of them (they're a VM image). ...
user avatar
  • 137
0 votes
1 answer
79 views

Uploading files using tar

Can you help me? I have this piece of code that I'm using on my Ubuntu 16.04 server tar -c /var/www/dxa/backup.zip | ssh <my-server-ip> -p 8000 'tar -xvf - -C /' But everytime I run this ...
user avatar
  • 23
0 votes
1 answer
892 views

ubuntu server tar -xvf failed for solr.tar.gz

I am trying to extract solr server downloaded from https://www.apache.org/dyn/closer.lua/lucene/solr/7.7.2/solr-7.7.2.tgz But am getting an error on ubuntu server. gzip: stdin: not in gzip format I ...
user avatar
  • 157
1 vote
1 answer
619 views

Backup a whole server over the network using tar

I have a server that is 80G total size and has no more space so i cannot backup on the server. I found this command ssh server2 "tar -zc -C /srcdir ./path" | tar -zx -C /destination but it is not ...
user avatar
  • 143
0 votes
0 answers
15 views

Tar is not Finishing When Running as Cronjob [duplicate]

My goal is to regularly pack the most important files on a server into a tar.gz file. In order to automate this I am using a cronjob to execute a script: $ crontab -l # blablabla * * * * * /home/...
user avatar
  • 101
0 votes
0 answers
89 views

resume tar command when nohup/screen is not possible

I have a dataset which is quite big - a few petabytes. Untarring it into a new filesystem takes a couple days. The problem is that the server does not allow me to have a process running over 24h - it ...
user avatar
3 votes
1 answer
3k views

NFS - Very slow performance with small files (Also with CIFS)

I am having very bad performance with NFS between two debian stretch machines, and I can't find a solution. I am using rsync at the server side in the exports file and tcp,hard,intr,rsize=32768,wsize=...
user avatar
  • 207
1 vote
1 answer
521 views

Tar archive error message

I am getting following error while archiving the user's homedirectory. (trying to migrate a user from one macbook to other since the user's keys are associated with AWS and other tools) tar cfv ...
user avatar
  • 125
0 votes
1 answer
835 views

how to create a tar file with checksums, but without compression

(note, this is not a duplicate of Creating a tar file with checksums included) I'm familiar with using tar + gzip to create a compressed tar file (tar cf - files | gzip > something.tar.gz), and ...
user avatar
  • 137
2 votes
1 answer
2k views

This does not look like a tar archive

I'm trying to fast copy some big directories from my remote Debian 9 server to my local Debian 9 on WSL (Windows Subsystem for linux; Windows 10 Pro) with ssh "tar" | tar pipe. ssh user@example.com "...
user avatar
  • 325
0 votes
1 answer
36 views

The write permission of files disappear after the files are copied between 2 remote system using FTP

I have setup FTP between 2 remote systems and scripts are set up on both the system to Archive and Extract the file. So the script in the source Archives(tar) file and the script on the destination (...
user avatar
-1 votes
1 answer
434 views

How to recover a TAR file from a partially overwritten XFS disk?

This is the scenario. The environment is Linux (Arch Linux actually). An uncompressed 1,3TB tar file has been written on a freshely XFS-formatted 2TB disk as a backup. Later on, a 586MB UEFI boot ...
user avatar
  • 282
1 vote
4 answers
2k views

How do i remove the path names from the files i have archived.. UBUNTU

I've been tasked to archive certain files into a new directory at /home/archive/. I used this command: mkdir /home/archive cd /home/archive tar -cvf log.tar \ /var/log/auth.log /var/log/...
user avatar
  • 11
0 votes
2 answers
1k views

Apache server causes tar.gz files to download as uncompressed tarballs still named .gz

We are hosting a number of .tar.gz files on our Apache server. When we download these files, the filename of the downloaded file is the same as on the server... something.tar.gz... but the file is ...
user avatar
1 vote
1 answer
155 views

Is GNU tar incremental backup reliable if ext4 is mounted with noatime?

My system is running on SSD on top of LVM logical volume, formatted to ext4. I'm using noatime option at my fstab for this partition. I'm going to do incremental backups of system partition using LVM ...
user avatar
-1 votes
1 answer
1k views

tar -z is very slow [closed]

I know this question has been asked before and I saw the recommendations on using pigz. Good recommendations, but I wanted to see if I really have a "problem". I have an esxi host. It's the free ...
user avatar
  • 3
0 votes
1 answer
125 views

Why tar is incapable of changing current directory?

The following command: tar -C "${HOME}/temp" -zcvf uber-bundle.tgz temp fail with the following error: tar: temp: Cannot stat: No such file or directory tar: Exiting with failure status due to ...
user avatar
  • 101
1 vote
1 answer
317 views

Create a zipped tar archive of a full centos filesystem, and open in Windows

I'm trying to create a zipped tar archive of all files on a centos 7 machine. I'm using this command: sudo tar -cvzp --exclude=backup --exclude=swapfile -f /backup/archive/full-backup-$today.tar.gz -...
user avatar
  • 161
-3 votes
3 answers
193 views

How to tar 30 Gigas of data on a 50 Giga server?

I need to send the content of a folder (full of JPEG pics) to a client. My server has 50 gigas and folder has 30 gigas. (Zipping JPEG is useless since JPEG is already compressed) Any idea/strategy ...
user avatar
  • 797
2 votes
1 answer
739 views

how do I extract a tar archive with larger block size?

I have a tar ball that has a huge number of very large files. The blocking factor is 10k. This is taking too long to extract because it does a lot of 10k writes. The filesystem will perform better if ...
user avatar
0 votes
2 answers
838 views

shasum of tar file different on os x / ubuntu although files are identical

I have a problem that brings me to despair and is plaguing me for the last days and I hope somebody can give me a hint what I have overlooked, since bash/sh is not a field I work in everyday: ...
user avatar
  • 171

1
2 3 4 5
7