Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I recently installed VMWare workstation on my computer. However due to some kernel compatibility issue, I had to patch my installation in the /usr/lib/vmware/modules/source/ directory. Funny thing is, all the files there are tar archives So to patch I had to decompress, patch, then compress again.
My question is, how exactly do programs use these files as tarballs? Do they dynamically compress and decompress during runtime? Are they read as is?
Almost no way usually to use a tar.(compressed) file for most uses.
In this case it does look like when you run the final vmware-modconfig --console --install-all it then can look into that file and get the new patched information.
Or maybe the file is never really un-compressed except in that the data is removed.
I suspect that is uncompressed in the same way as a compressed file is uncompressed when you click "View File" in a file manager--that is, it is extracted to RAM for viewing, but not extracted to disk. Nevertheless, it does seem to indicate that compressed files can be uncompressed and used in real time.
As I said, I don't know how it works. I just know it does.
I recently installed VMWare workstation on my computer. However due to some kernel compatibility issue, I had to patch my installation in the /usr/lib/vmware/modules/source/ directory. Funny thing is, all the files there are tar archives So to patch I had to decompress, patch, then compress again.
My question is, how exactly do programs use these files as tarballs? Do they dynamically compress and decompress during runtime? Are they read as is?
Thanks in advance.
Are you implying that it only works if you leave the tarballs there?
There's nothing wrong with receiving new code or a patch in a tarball, decompressing it, performing the update, and then in my experience, the tarball and usually the decompressed content are no longer relevant except to keep for future reference.
What frankbell says about man pages is true by my opinion as well.
Further, I have custom software which uses a .tar.bz2 file; however it extracts the files, performs a specific function, and then removes the original file. It's used for a product upgrade process and I wrote it to operate in a specific fashion. So it's really up to the coder, however for kernel patches, things are probably done in a near uniform manner due to the submission to a public repository.
Distribution: Mainly Devuan with some Tiny Core, Fatdog, Haiku, & BSD thrown in.
Posts: 5,012
Rep:
The utility tar can look into, & copy out of an archive without decompressing it.
(It can also add files into a compressed archive.)
As for .gz files there are utilities with a z prepended, (in /bin) that can operate on compressed file archives.
The utility tar can look into, & copy out of an archive without decompressing it.
(It can also add files into a compressed archive.)
As for .gz files there are utilities with a z prepended, (in /bin) that can operate on compressed file archives.
I say tar only makes an archive of files and directories and not individually compressing files. Zip does that.
You can pass an option for compression like -j or -J or -z but they compress the whole archive and decompress the whole archive.
Are you implying that it only works if you leave the tarballs there?
There's nothing wrong with receiving new code or a patch in a tarball, decompressing it, performing the update, and then in my experience, the tarball and usually the decompressed content are no longer relevant except to keep for future reference.
Not quite, I wasn't referring to the relevance of the tarballs. I was looking for an explanation as to why the tarballs are all there is. Even more interesting was that applying the patch actually required updating files in one of the tarballs.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.