tar zcvf all.tar.gz 1.txt 2.txt
tar tf all.tar.gz
[root@wql wql]
1.txt
2.txt
tar xf all.tar.gz
[root@wql wql]
1.txt
2.txt
[root@wql w]
[root@wql w]
total 8
-rw-r--r-- 1 root root 4 Apr 9 17:12 1.txt
-rw-r--r-- 1 root root 4 Apr 9 17:12 2.txt
[root@wql w]
[root@wql w]
[root@wql w]
total 8
-rw-r--r-- 1 root root 4 Apr 9 17:12 1.txt
-rw-r--r-- 1 root root 4 Apr 9 17:12 2.txt
drwx------ 3 root root 17 Apr 9 17:42 systemd-private-28ea6870a00d4b5291fd927f0f8d7809-nginx.service-voYC72
[root@wql w]
[root@wql wql]
adding: 1.txt (stored 0%)
adding: 2.txt (stored 0%)
[root@wql wql]
[root@wql w]
Archive: ../all.zip
extracting: 1.txt
extracting: 2.txt
[root@wql w]
total 8
-rw-r--r-- 1 root root 4 Apr 9 17:12 1.txt
-rw-r--r-- 1 root root 4 Apr 9 17:12 2.txt
[root@wql w]
total 0
drwx------ 3 root root 17 Apr 9 17:42 systemd-private-28ea6870a00d4b5291fd927f0f8d7809-nginx.service-voYC72
[root@wql w]
Archive: ../all.zip
extracting: /tmp/1.txt
extracting: /tmp/2.txt
[root@wql w]
total 8
-rw-r--r-- 1 root root 4 Apr 9 17:12 1.txt
-rw-r--r-- 1 root root 4 Apr 9 17:12 2.txt
drwx------ 3 root root 17 Apr 9 17:42 systemd-private-28ea6870a00d4b5291fd927f0f8d7809-nginx.service-voYC72
[root@wql w]