test.warという7zaコマンドを使用してこのファイルを作成しました。
# file test.war
test.war: 7-zip archive data, version 0.4
次のコマンドを使用して、他のRHELシステムからこのファイルを抽出しようとします。
# unzip test.war
Archive: test.war
End-of-central-directory signature not found. Either this file is not
a zipfile, or it constitutes one disk of a multi-part archive. In the
latter case the central directory and zipfile comment will be found on
the last disk(s) of this archive.
unzip: cannot find zipfile directory in one of test.war or
test.war.zip, and cannot find test.war.ZIP, period.
これは7zipで生成されたファイルを解凍できないという意味ですか?
ベストアンサー1
unzip
この特別な場合は、;を使用してファイルを抽出することはできません。7za
抽出して使用する必要があります。
デフォルトで7za
作成7z形式ファイル。 ;を使用して抽出できるzip形式のアーカイブを作成することもできますunzip
。これを行うには、.zip
拡張子を使用してアーカイブを指定するか、次のようにタイプを指定します-tzip
。
7za a -tzip test.war ...
それからtest.war
。unzip
JavaEE WARファイルを作成する場合は、.NET Frameworkjar
ではなくこのツール(またはビルドツール用のプラグイン)を使用する必要があります。zip
7za