LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 05-11-2016, 09:03 AM   #1
Kikela
LQ Newbie
 
Registered: Nov 2007
Posts: 9

Rep: Reputation: 0
tar archive in multiplateform use : linux, osx, windows


Hi,

I don't understand what's happen.

I use Debian Jessie x64 with utf8 fr locale

If I copy my files directly to an exfat usb stick, i have no problem with the filename like : hébétàç.txt

If I make a tar archive with a file like hébétàç.txt, and after I try to extract this file in an other plateform like Windows 8, instead of the original filename, it's replaced by strange caracters.

1)does Debian "translate" the filename in other encodage like iso when it copy to an allien filesystem on my usb stick ?
2)tar encode in an other encodage type make it unreadable ?

Off course if I make a tar archive of this file and extract on linux, no problem.

I apologize for my poor english...
 
Old 05-11-2016, 11:15 AM   #2
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian stable
Posts: 5,908

Rep: Reputation: 356Reputation: 356Reputation: 356Reputation: 356
Does the windows 8 system have the utf 8 fr locale installed?
 
Old 05-12-2016, 02:33 AM   #3
Syndacate
Member
 
Registered: Aug 2008
Location: Santa Clara, CA
Distribution: Ubuntu, mainly. Too much stuff works out of the box O.o
Posts: 71

Rep: Reputation: 52
Quote:
Originally Posted by bigrigdriver View Post
Does the windows 8 system have the utf 8 fr locale installed?
If it works fine with a regular text file than this cannot be the issue.

Quote:
Originally Posted by Kikela View Post
Hi,

I don't understand what's happen.

I use Debian Jessie x64 with utf8 fr locale

If I copy my files directly to an exfat usb stick, i have no problem with the filename like : hébétàç.txt

If I make a tar archive with a file like hébétàç.txt, and after I try to extract this file in an other plateform like Windows 8, instead of the original filename, it's replaced by strange caracters.

1)does Debian "translate" the filename in other encodage like iso when it copy to an allien filesystem on my usb stick ?
2)tar encode in an other encodage type make it unreadable ?

Off course if I make a tar archive of this file and extract on linux, no problem.

I apologize for my poor english...
I'd say it's either:
A. A problem with tar encode character support
B. A problem with the unzip utility that you're using in Windows.

Since you said you can run "untar" and it is readable, then the problem is likely in the decompression utility you're using in Windows. Though it could also be a problem with the tar utility if it has "bend" any encodings depending on what the TAR standard supports. I'd look at the Windows decompression utility you're using first.

Which utility are you using to decompress in Windows? Also, what happens if you compress that file in Windows and decompress it using the same utility?

I prefer 7zip myself, but I don't know much about its language support. Try the one which is built into Windows. I would think that supports all character of the encodings that the rest of the operating system does (and the operating system obviously does support that locale).

Last edited by Syndacate; 05-12-2016 at 02:36 AM.
 
Old 05-12-2016, 06:52 AM   #4
Kikela
LQ Newbie
 
Registered: Nov 2007
Posts: 9

Original Poster
Rep: Reputation: 0
Thumbs up

I found the solution.

It was an incomplete coverage of tar archive by 7z. This bug was reported on Source Forge 7z support.
I downloaded the up to date 7z v.16 (windows) and hopefully, the problem desapeared.
The name of the filename are correct.

You can archive with tar on Linux, and use this archive on Osx, Windows 8. I verified, it works.

Thanks for your's answaers.
 
Old 05-12-2016, 09:35 AM   #5
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
Good job and Well done!
 
Old 05-14-2016, 09:20 AM   #6
r37
LQ Newbie
 
Registered: Mar 2015
Distribution: in the past Mandrake, Debian, Knoppix, Antix, now Devuan
Posts: 21

Rep: Reputation: Disabled
I am not such an optimist ;)

Quote:
Originally Posted by Kikela View Post

You can archive with tar on Linux, and use this archive on Osx, Windows 8. I verified, it works.
Well, I am not intended to frighten anyone but especially when you are working with filesystems on different OSes (even different flavors of the same OS), I DO recommend to respect the POSIX standard for filenames. This is IMO the only way that is guaranteed.
Kikela, in the particular case you described, you had a good luck but you could have a bad luck, too. According to my experience, problems can appear during compressing / decompressing as well as during just copying. It is mostly possible to overcome the particular problem but in many cases it is really annoying (for example, two weeks ago I faced such a problem when transferring – not mine – 32 GBs of data /tarred/ from PC with Win XP to PC with Win 7: one hour of work).
And – do you REALLY need non-posix characters is your filenames? I am sorry but I doubt. I can, of course, understand it well when user has problems to understand and work with the latin alphabet because he/she speaks Russian, Chinese, Bengali etc. and he/she has a localized OS installation but it is hardly your case
 
Old 05-15-2016, 07:07 AM   #7
Kikela
LQ Newbie
 
Registered: Nov 2007
Posts: 9

Original Poster
Rep: Reputation: 0
Quote:
And – do you REALLY need non-posix characters is your filenames? I am sorry but I doubt
This is an interesting question and you can ask an another one : Do you really need a computer ? What I really need is eating, drinking and sleeping. Everything else is comfort.
My first computer was a Sinclair zx80. In this former time we have no choice but it was in 1983 and the length of the filename can be only something like 8 characters. We are now in 2016.
And what it's need 4U is not necessary need for me.
 
Old 05-15-2016, 08:19 AM   #8
r37
LQ Newbie
 
Registered: Mar 2015
Distribution: in the past Mandrake, Debian, Knoppix, Antix, now Devuan
Posts: 21

Rep: Reputation: Disabled
Quote:
Originally Posted by Kikela View Post
Do you really need a computer ? What I really need is eating, drinking and sleeping. Everything else is comfort.
I completely agree
And this is the core; perhaps I formulated my idea not in the most proper way:
Per my experience (in the last 15 years, roughly), the comfort that is obtained by usage of é,à,ç,č (etc.) characters in filenames is remarkably smaller than the discomfort induced by problems in file operations and transfer. (Valid on condition that you are perfectly able to understand latin alphabet.) Of course, your mileage may vary.

Yes, I also remember ZX 80

Quote:
Originally Posted by Kikela View Post
And what it's need 4U is not necessary need for me.
I am completely agreeing, again.

And I forgot to congratulate you to solving the problem
 
  


Reply

Tags
osx, tar, utf-8, win8



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Replacing OSX with Linux? No I do not wish to Triple boot OSX, Linux and Windows. Seph64 Linux - General 10 02-06-2011 02:35 PM
Error in TAR - tar: GNU features wanted on incompatible archive format. kuldeep.k Linux - General 3 08-14-2009 11:09 AM
Tar archive from windows to linux, binary file issue jblevins Linux - General 3 04-13-2009 11:50 PM
Piping tar bzcat to add a file to a tar.bz2 archive DaveQB Linux - Software 0 06-02-2008 08:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 01:08 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration