Breaking News
Loading...
Wednesday, August 7, 2013

How to Zip and Unzip Files on CentOS 6/ Redhat 6

8:52 AM

Step 1. Creates the archive folder.zip and puts all the files in the current directory in it in compressed form as below :
[root@howtolinux ~]# touch document1
[root@howtolinux ~]# touch document2
[root@howtolinux ~]#ls
document1  document2
[root@howtolinux ~]# zip folder *
  adding: anaconda-ks.cfg (deflated 40%)
  adding: document1 (stored 0%)
  adding: document2 (stored 0%)
  adding: howtolinux/ (stored 0%)
  adding: install.log (deflated 75%)
  adding: install.log.syslog (deflated 85%)
[root@howtolinux ~]# ls
anaconda-ks.cfg  document2   howtolinux   install.log.syslog
document1        folder.zip  install.log

Step 2. To unzip folder.zip into /var/www/html/test folder :
[root@howtolinux ~]# unzip folder.zip -d /var/www/html/test
Archive:  folder.zip
  inflating: /var/www/html/test/anaconda-ks.cfg
 extracting: /var/www/html/test/document1
 extracting: /var/www/html/test/document2
   creating: /var/www/html/test/howtolinux/
  inflating: /var/www/html/test/install.log
  inflating: /var/www/html/test/install.log.syslog

2 comments:

  1. Sweet blog! I found іt whіle browsiոg on Yahoօ News.

    Do yoou havbe anү tips ߋn how to get listed in Yahoo News?

    I've beeո tryinց for a while bսt Ι never seem tto gget there!
    Thaոkѕ

    Also visit my homepage - 7 zip darkx dll.dll download

    ReplyDelete
  2. Astrologie personnalisee gratuite voyance strasbourg

    my blog :: voyance par telephone

    ReplyDelete

 
Toggle Footer