Where did my 7zip archive go?

I tried to use 7zip to create an archive for a folder. It compressed all the files and said everything was ok. but I could not find the archive inside the directory containing the folder. Here are my command and part of the output:

$p7zip folder/
...
Creating archive: folder/.7z
Items to compress: 786
...
Files read from disk: 653
Archive size: 3155722 bytes (3082 KiB)
Everything is Ok

I assumed 7zip created an archive but I could not find it anywhere. Does anyone know where 7zip output the archive?

3

1 Answer

Your 7zip file is in folder/.7z. The output of the command tells you: Creating archive: folder/.7z. You didn't specify a filename so it made the file without one. Just an extension. I'd recommend using the command find if you have problems locating files. Take a look at my example, I've recreated your scenario below.

root@myputer:~/test# mkdir folder/
root@myputer:~/test# p7zip folder/
7-Zip (a) [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21 p7zip Version 16.02 (locale=en_US.UTF-8,Utf16=on,HugeFiles=on,64 bits,4 CPUs Intel(R) Core(TM) i5-4590 CPU @ 3.30GHz (306C3),ASM,AES-NI)
Scanning the drive: 1 folder, 0 files, 0 bytes
Creating archive: folder/.7z
Items to compress: 1 Files read from disk: 0 Archive size: 90 bytes (1 KiB) Everything is Ok
root@myputer:~/test# find folder
folder folder/.7z
root@myputer:~/test# cd folder/
root@myputer:~/test/folder# ll
total 12
drwxr-xr-x 2 root root 4096 Oct 16 16:34 ./
drwxrwxr-x 3 me me 4096 Oct 16 16:33 ../
-rw-r--r-- 1 root root 90 Oct 16 16:34 .7z

There is your file .7z.

3

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like