0

I created .tgz archive via Total Commander on Windows, can I later open it on Ubuntu? And is it the same as .tar.gz? Thanks

2
  • The extension name does not matter in Linux. That is just for us humans to see what the file represents. If you have a program that can view a compressed tar file (ie. that would be with the "tar tvfz" command) software can open it. They tend to hook into the command itself.
    – Rinzwind
    Dec 1, 2014 at 12:50
  • -1 for asking hypothetical questions: askubuntu.com/help/dont-ask
    – MadMike
    Dec 1, 2014 at 12:51

2 Answers 2

1

Yes you can.

.tgz is the same as .tar.gz, just like .jpg and .jpeg represent the same file extension.

1

Actually, a file extension has no meaning in Ubuntu. Ubuntu determines (at least should) a file's content by its MIME type, not by its extension. But .tgz and .tar.gz are used for the same purpose: To describe a gzip-compressed TAR archive.

As TAR is an open archive format, it can be read without problems on any system that supports it. Ubuntu does so - every .deb package is compressed as a gzipped TAR.

So unless you didn't apply any encryption etc., you shouldn't have any problems. If you're still not sure, boot Ubuntu into a live environment and find out.


Example: I copied a driver packed into a file ending in .tar.gz into two other ones ending in .tgz and .foo:

$ file DPO_RT3290_LinuxSTA_V2600_20120508.tar.gz
DPO_RT3290_LinuxSTA_V2600_20120508.tar.gz: gzip compressed data, from Unix, last modified: Sat Oct 12 00:22:20 2013
$ cp DPO_RT3290_LinuxSTA_V2600_20120508.tar.gz DPO_RT3290_LinuxSTA_V2600_20120508.tgz && file DPO*tgz
DPO_RT3290_LinuxSTA_V2600_20120508.tgz: gzip compressed data, from Unix, last modified: Sat Oct 12 00:22:20 2013
$ cp DPO_RT3290_LinuxSTA_V2600_20120508.tar.gz DPO_RT3290_LinuxSTA_V2600_20120508.foo && file DPO*foo
DPO_RT3290_LinuxSTA_V2600_20120508.foo: gzip compressed data, from Unix, last modified: Sat Oct 12 00:22:20 2013

So as Shakespeare already wrote:

What's in a name? That which we call a rose
By any other name would smell as sweet.
    - Romeo and Juliet, II,2:1f

Name doesn't matter, at least as long as you're not using Windows.

3
  • Stealing my comment are we? >:-D
    – Rinzwind
    Dec 1, 2014 at 12:52
  • I assume you wrote your comment while I was writing my answer... Why stealing?
    – s3lph
    Dec 1, 2014 at 12:53
  • Mind the >:-D :-)
    – Rinzwind
    Dec 1, 2014 at 12:54

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .