Sample Header Ad - 728x90

tar can't extract the archive - tar: "Failed to set default locale"

1 vote
0 answers
42 views
I have set LANG to **en_GB.utf8**. I received a tar archive, which I can list fine with tar tf FILENAME, but when I want to extract it with tar xf FILENAME, no file is extracted, and I get the error message tar: Failed to set default locale Therefore I tried a LANG=C tar tf FILENAME and this managed to extract the tarball. I guess _tar_ somehow knows that the archive was created under the C locale, and needs the C-locale to properly create the extracted filenames, but why can't it set this by itself? Running under zsh on Monterey.
Asked by user1934428 (1458 rep)
Jun 26, 2023, 11:33 AM
Last activity: Jun 28, 2023, 08:11 PM