LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-02-2017, 10:27 AM   #1
viveksikarwar
LQ Newbie
 
Registered: Sep 2017
Posts: 2

Rep: Reputation: Disabled
Backup and restoration of directory in pen/external drive


Hi,
I want to create bash shell scripts to backup and restore specific directories ( given as command line arguments) recursively without explicitly using a backup utility. The backup is to be done to a pen/external drive attached to system via USB port. First check that the USB drive has enough disk space and then backup the directory tree structure given in the form of argument to the script. Both during backup and restoring the existing file permissions should be maintained. Also, allow compression and verbose options that allow you to create compressed files for backup and restoration and print out incrementally the status of the back up process (without using rsync and tar commands).
 
Old 09-02-2017, 07:40 PM   #2
!!!
Member
 
Registered: Jan 2017
Location: Fremont, CA, USA
Distribution: Trying any&ALL on old/minimal
Posts: 759

Rep: Reputation: 330Reputation: 330Reputation: 330Reputation: 330
Refer to LQrules: (would also apply similarly to projects that aren't homework)
Quote:
Do not post homework assignments verbatim. We're happy to assist if you have specific questions or have hit a stumbling point, however. Let us know what you've already tried and what references you have used (including class notes, books, and searches) and we'll do our best to help.
 
1 members found this post helpful.
Old 09-04-2017, 02:55 AM   #3
viveksikarwar
LQ Newbie
 
Registered: Sep 2017
Posts: 2

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by viveksikarwar View Post
Hi,
I want to create bash shell scripts to backup and restore specific directories ( given as command line arguments) recursively without explicitly using a backup utility. The backup is to be done to a pen/external drive attached to system via USB port. First check that the USB drive has enough disk space and then backup the directory tree structure given in the form of argument to the script. Both during backup and restoring the existing file permissions should be maintained. Also, allow compression and verbose options that allow you to create compressed files for backup and restoration and print out incrementally the status of the back up process (without using rsync and tar commands).
I found the solution using cpio, but cpio is unable to preserve file permission even I used --no-preserve-owner with cpio.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Including external data (network/external drive) in website directory thealmightyos Linux - Server 2 08-19-2014 12:14 PM
[SOLVED] Backup Application with pen drive as data carrier between 2 computers. s.verma Linux - Software 6 02-14-2014 04:12 AM
Boot iso on pen drive by grub installed on pen drive jena Linux - Hardware 2 11-01-2008 09:09 AM
Need tips on creating scripts for daily backup (tar) a directory to an external drive Joejr4u Linux - Server 2 06-07-2007 07:46 AM
Whole system backup and restoration newbie_adm Linux - Newbie 7 01-09-2007 09:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:40 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration