This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
user:cforman:portfolio:project3 [2011/10/23 01:39] – [References] cforman | user:cforman:portfolio:project3 [2011/10/25 19:06] (current) – [Procedure] cforman | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ======Project: | ||
+ | A project for CSCS1730 UNIX/Linux Fundamentals by YOUR NAME OR GROUPMEMBER NAMES during the SEMESTER YEAR. | ||
+ | |||
+ | This project was begun on DATE and is anticipated to take X AMOUNT OF TIME. (Upon completion you can correct this with the actual length). | ||
+ | |||
+ | =====Objectives===== | ||
+ | To demonstrate familiarity with archiving and compression tools. | ||
+ | |||
+ | =====Prerequisites===== | ||
+ | In order to successfully accomplish/ | ||
+ | |||
+ | * ability to use the command-line | ||
+ | * familiarity with looking up information and documentation | ||
+ | * understanding what files are | ||
+ | |||
+ | =====Background===== | ||
+ | The purpose of this project is to allow me to explore archiving. I will explore it in the fact of zip archives. I will learn how to zip and unzip files. | ||
+ | I had to look up information to check and see if the command was obvious to zip and unzip a file. | ||
+ | http:// | ||
+ | Unzip was easy to guess but zipping a file took some time to figure out. I used " | ||
+ | http:// | ||
+ | This site described the gzip commands and The file we are dealing with is a tar.gzip file and this page describes how to expand it. After expanding them they go to a designated archive file and that using the informantion from man can then be zipped into an archive. | ||
+ | |||
+ | |||
+ | =====Scope===== | ||
+ | In **/ | ||
+ | |||
+ | Your mission is to: | ||
+ | |||
+ | * make a copy of them to your home directory | ||
+ | * figure out how to properly extract each one | ||
+ | * view the contents | ||
+ | * create a new archive containing the contents of both extracted original archives | ||
+ | * compress your new archive in bzip2 format | ||
+ | * document the entire process to clearly demonstrate this (ie showing command-lines) on your project document | ||
+ | |||
+ | =====Attributes===== | ||
+ | State and justify the attributes you'd like to receive upon successful approval and completion of this project. | ||
+ | |||
+ | * commands: using various archiving and compression commands | ||
+ | * files & directories: | ||
+ | |||
+ | =====Procedure===== | ||
+ | Describe the process you took to accomplish this project here, | ||
+ | <cli> | ||
+ | lab46:~$ cp -r / | ||
+ | lab46:~$ ls | ||
+ | Maildir | ||
+ | archive1.tar.gz | ||
+ | bin data public_html | ||
+ | lab46:~$ cp -r / | ||
+ | lab46:~$ ls | ||
+ | Maildir | ||
+ | archive1.tar.gz | ||
+ | archive2.zip | ||
+ | lab46:~$ archive2.zip -Z | ||
+ | -bash: archive2.zip: | ||
+ | lab46:~$ -Z archive2.zip | ||
+ | -bash: -Z: command not found | ||
+ | lab46:~$ man -Z | ||
+ | What manual page do you want? | ||
+ | lab46:~$ -Z | ||
+ | -bash: -Z: command not found | ||
+ | lab46:~$ unzip archive2.zip | ||
+ | Archive: | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | lab46:~$ ls | ||
+ | Maildir | ||
+ | archive1.tar.gz | ||
+ | archive2.zip | ||
+ | lab46:~$ cd archives | ||
+ | lab46: | ||
+ | dir1 filea filez | ||
+ | lab46: | ||
+ | This contains text. | ||
+ | lab46: | ||
+ | lab46: | ||
+ | dir1 filea filez | ||
+ | lab46: | ||
+ | lab46: | ||
+ | lab46: | ||
+ | lab46: | ||
+ | lab46: | ||
+ | lab46: | ||
+ | lab46: | ||
+ | lab46:~$ unzip archive1.tar.gz | ||
+ | Archive: | ||
+ | End-of-central-directory signature not found. | ||
+ | a zipfile, or it constitutes one disk of a multi-part archive. | ||
+ | latter case the central directory and zipfile comment will be found on | ||
+ | the last disk(s) of this archive. | ||
+ | unzip: | ||
+ | archive1.tar.gz.zip, | ||
+ | lab46:~$ tar -xzf archive1.tar.gz | ||
+ | lab46:~$ ls | ||
+ | Maildir | ||
+ | archive1.tar.gz | ||
+ | archive2.zip | ||
+ | lab46:~$ cd archives | ||
+ | lab46: | ||
+ | abc.txt | ||
+ | lab46: | ||
+ | This is an example file for use in CT173. | ||
+ | lab46: | ||
+ | lab46: | ||
+ | cat: file: No such file or directory | ||
+ | cat: c: No such file or directory | ||
+ | lab46: | ||
+ | lab46: | ||
+ | abc.txt | ||
+ | lab46: | ||
+ | lab46: | ||
+ | lab46: | ||
+ | lab46: | ||
+ | lab46:~$ ls | ||
+ | Maildir | ||
+ | archive1.tar.gz | ||
+ | archive2.zip | ||
+ | archivecompilationfile | ||
+ | lab46:~$ tar -cvf archives.tar archives | ||
+ | archives/ | ||
+ | archives/ | ||
+ | archives/ | ||
+ | archives/ | ||
+ | archives/ | ||
+ | archives/ | ||
+ | archives/ | ||
+ | lab46:~$ ls | ||
+ | Maildir | ||
+ | archive1.tar.gz | ||
+ | archive2.zip | ||
+ | archivecompilationfile | ||
+ | lab46:~$ bzip2 archives.tar | ||
+ | lab46:~$ ls | ||
+ | Maildir | ||
+ | archive1.tar.gz | ||
+ | archive2.zip | ||
+ | archivecompilationfile | ||
+ | lab46: | ||
+ | |||
+ | </ | ||
+ | |||
+ | I first looked up how to properly copy files from directories and moved the zipped files to my home directory. After that i played around to figure out what was in each file after unzipping it using the unzip command then file name. I looked up the man for zip and found out how to send all the data in the directory into the zip file after some prompting from my teacher i remembered the -r argument from the website that i found to copy allowing me to send all the contents of the directory to a zip folder called archives.zip. | ||
+ | < | ||
+ | =====Reflection===== | ||
+ | Archiving makes it easy to move extremely large files. Its kind of a waste to archive small files but this project was a great example in unzipping and zipping files. The archive doesn' | ||
+ | < | ||
+ | =====References===== | ||
+ | In performing this project, the following resources were referenced: | ||
+ | |||
+ | * http:// | ||
+ | * http:// | ||
+ | * http:// | ||
+ | * http:// |