What does -f mean in tar?tar append to file in archiveHow can I filter the contents of a tar file, producing...
Does throwing a penny at a train stop the train?
Solve limit without L'Hospital's Rule
Single word for "refusing to move to next activity unless present one is completed."
Why does this potentiometer in an op-amp feedback path cause noise when adjusted?
Is there a strong legal guarantee that the U.S. can give to another country that it won't attack them?
When I press the space bar it deletes the letters after it
Why does wrapping aluminium foil around my food help it keep warm, even though aluminium is a good conductor?
Word meaning to destroy books
What is a "shilicashe?"
Is anyone advocating the promotion of homosexuality in UK schools?
Why would non-kinetic weapons be used for orbital bombardment?
Is there any word for "disobedience to God"?
If your plane is out-of-control, why does military training instruct releasing the joystick to neutralize controls?
Is English unusual in having no second person plural form?
Is there any reason why MCU changed the Snap to Blip
How to deal with moral/legal subjects in writing?
Is it possible to create a craft with specific bones, like the bones of a forgotten beast?
How can I get a player to accept that they should stop trying to pull stunts without thinking them through first?
Are there any sports for which the world's best player is female?
Would dual wielding daggers be a viable choice for a covert bodyguard?
Swapping "Good" and "Bad"
Why doesn't sea level show seasonality?
How do native German speakers usually express skepticism (using even) about a premise?
Some interesting calculation puzzle that I made
What does -f mean in tar?
tar append to file in archiveHow can I filter the contents of a tar file, producing another tar file in the pipe?Tar waiting a long time at end of block deviceHow to issue a tar command when you restore your systemTar exclusion list doesn't work anymore after upgrading to Debian stretchRemove the pathname when extracting and archiving files that end with .log from /var/logMove/transform everything from pwd into subdirectory while archiving with tartar doesn't find a file in an archive, depending on the command used to try to extract itWhat does cat of a tar archive show?Gzipped archives - Create using tar -czf and extract using only -xf?
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}
From man tar
:
-f, --file ARCHIVE
use archive file or device ARCHIVE
Please consider:
tar -zxvf myFile.tar.gz
AFAIU, z
means it's a gzipped tarball, x
means "extract!", v
means "give verbose output!" but about f
I am not sure.
If we already give the file name myFile.tar.gz
, why is the f
argument needed?
tar
add a comment |
From man tar
:
-f, --file ARCHIVE
use archive file or device ARCHIVE
Please consider:
tar -zxvf myFile.tar.gz
AFAIU, z
means it's a gzipped tarball, x
means "extract!", v
means "give verbose output!" but about f
I am not sure.
If we already give the file name myFile.tar.gz
, why is the f
argument needed?
tar
add a comment |
From man tar
:
-f, --file ARCHIVE
use archive file or device ARCHIVE
Please consider:
tar -zxvf myFile.tar.gz
AFAIU, z
means it's a gzipped tarball, x
means "extract!", v
means "give verbose output!" but about f
I am not sure.
If we already give the file name myFile.tar.gz
, why is the f
argument needed?
tar
From man tar
:
-f, --file ARCHIVE
use archive file or device ARCHIVE
Please consider:
tar -zxvf myFile.tar.gz
AFAIU, z
means it's a gzipped tarball, x
means "extract!", v
means "give verbose output!" but about f
I am not sure.
If we already give the file name myFile.tar.gz
, why is the f
argument needed?
tar
tar
asked 1 hour ago
JohnDoeaJohnDoea
441 gold badge11 silver badges42 bronze badges
441 gold badge11 silver badges42 bronze badges
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
So there are so many other situation where you need f switch.
-f Archive Uses the Archive variable as the archive to be read or written. When this flag is not specified, the tar command uses a system-dependent default file name of the form /dev/rmt0. If the Archive variable specified is - (minus sign), the tar command writes to standard output or reads from standard input. If you write to standard output, the -c flag must be used.
Examples:
To extract all files in the /tmp directory from the archive file on the /dev/rmt2 tape device and use the time of extraction as the modification time, enter:
tar -xm -f/dev/rmt2 /tmp
To create a new archive file that contains the file1 file and pass the archive file to the dd command to be written to the /dev/rmt1 device, enter:
tar -cvf - file1 | dd of=/dev/rmt1 conv=sync
To archive all directories and complete filenames listed in input list file infile into ar.tar, enter :
tar cvfL ar.tar infile
Where infile contains the pathnames of files that are to be archived.
To archive files within directories listed in the input list file infile into ar.tar, enter:
tar cvRfL ar.tar infile
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f529318%2fwhat-does-f-mean-in-tar%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
So there are so many other situation where you need f switch.
-f Archive Uses the Archive variable as the archive to be read or written. When this flag is not specified, the tar command uses a system-dependent default file name of the form /dev/rmt0. If the Archive variable specified is - (minus sign), the tar command writes to standard output or reads from standard input. If you write to standard output, the -c flag must be used.
Examples:
To extract all files in the /tmp directory from the archive file on the /dev/rmt2 tape device and use the time of extraction as the modification time, enter:
tar -xm -f/dev/rmt2 /tmp
To create a new archive file that contains the file1 file and pass the archive file to the dd command to be written to the /dev/rmt1 device, enter:
tar -cvf - file1 | dd of=/dev/rmt1 conv=sync
To archive all directories and complete filenames listed in input list file infile into ar.tar, enter :
tar cvfL ar.tar infile
Where infile contains the pathnames of files that are to be archived.
To archive files within directories listed in the input list file infile into ar.tar, enter:
tar cvRfL ar.tar infile
add a comment |
So there are so many other situation where you need f switch.
-f Archive Uses the Archive variable as the archive to be read or written. When this flag is not specified, the tar command uses a system-dependent default file name of the form /dev/rmt0. If the Archive variable specified is - (minus sign), the tar command writes to standard output or reads from standard input. If you write to standard output, the -c flag must be used.
Examples:
To extract all files in the /tmp directory from the archive file on the /dev/rmt2 tape device and use the time of extraction as the modification time, enter:
tar -xm -f/dev/rmt2 /tmp
To create a new archive file that contains the file1 file and pass the archive file to the dd command to be written to the /dev/rmt1 device, enter:
tar -cvf - file1 | dd of=/dev/rmt1 conv=sync
To archive all directories and complete filenames listed in input list file infile into ar.tar, enter :
tar cvfL ar.tar infile
Where infile contains the pathnames of files that are to be archived.
To archive files within directories listed in the input list file infile into ar.tar, enter:
tar cvRfL ar.tar infile
add a comment |
So there are so many other situation where you need f switch.
-f Archive Uses the Archive variable as the archive to be read or written. When this flag is not specified, the tar command uses a system-dependent default file name of the form /dev/rmt0. If the Archive variable specified is - (minus sign), the tar command writes to standard output or reads from standard input. If you write to standard output, the -c flag must be used.
Examples:
To extract all files in the /tmp directory from the archive file on the /dev/rmt2 tape device and use the time of extraction as the modification time, enter:
tar -xm -f/dev/rmt2 /tmp
To create a new archive file that contains the file1 file and pass the archive file to the dd command to be written to the /dev/rmt1 device, enter:
tar -cvf - file1 | dd of=/dev/rmt1 conv=sync
To archive all directories and complete filenames listed in input list file infile into ar.tar, enter :
tar cvfL ar.tar infile
Where infile contains the pathnames of files that are to be archived.
To archive files within directories listed in the input list file infile into ar.tar, enter:
tar cvRfL ar.tar infile
So there are so many other situation where you need f switch.
-f Archive Uses the Archive variable as the archive to be read or written. When this flag is not specified, the tar command uses a system-dependent default file name of the form /dev/rmt0. If the Archive variable specified is - (minus sign), the tar command writes to standard output or reads from standard input. If you write to standard output, the -c flag must be used.
Examples:
To extract all files in the /tmp directory from the archive file on the /dev/rmt2 tape device and use the time of extraction as the modification time, enter:
tar -xm -f/dev/rmt2 /tmp
To create a new archive file that contains the file1 file and pass the archive file to the dd command to be written to the /dev/rmt1 device, enter:
tar -cvf - file1 | dd of=/dev/rmt1 conv=sync
To archive all directories and complete filenames listed in input list file infile into ar.tar, enter :
tar cvfL ar.tar infile
Where infile contains the pathnames of files that are to be archived.
To archive files within directories listed in the input list file infile into ar.tar, enter:
tar cvRfL ar.tar infile
answered 30 mins ago
asktyagiasktyagi
6401 silver badge9 bronze badges
6401 silver badge9 bronze badges
add a comment |
add a comment |
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f529318%2fwhat-does-f-mean-in-tar%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown