Tar exclude | Unix Linux Forums | SCO

  Go Back    


SCO Santa Cruz Operation (SCO) was a software company based in Santa Cruz, California which was best known for selling three UNIX variants for Intel x86.

Tar exclude

SCO


Tags
unix sco tar

Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 01-26-2010
haezeban haezeban is offline
Registered User
 
Join Date: Sep 2009
Last Activity: 11 August 2011, 7:13 AM EDT
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Tar exclude

Hi,

We work on a UNIX SCO SCO_SV Release = 3.2v5.0.5.
I have a folowing structure

Code:
/u/usr/lpp
/u/usr/lpp/SQL
/u/usr/lpp/DIR2

I use following tar to backup the /u/usr/lpp directory


Code:
cd /u/usr/lpp
tar cvf /u/usr/backup/backup.tar .

Now I want to exclude the subdirectory SQL.
I tried everything but nothing works
examples

Code:
tar cvf /u/usr/backup/backup.tar --exclude=./SQL .
tar cvf /u/usr/backup/backup.tar --exclude='./SQL' . 
tar cvf /u/usr/backup/backup.tar --exclude=.u/usr/lpp/SQL .
tar cvf /u/usr/backup/backup.tar --exclude=./SQL /* .
tar cvf /u/usr/backup/backup.tar . --exclude=./SQL

Can somebody point me out.
Thanks a lot.

Last edited by pludi; 01-26-2010 at 06:34 AM.. Reason: code tags, please...
Sponsored Links
    #2  
Old 01-26-2010
jgt's Avatar
jgt jgt is offline Forum Advisor  
Registered User
 
Join Date: Apr 2007
Last Activity: 1 December 2014, 3:41 PM EST
Location: 44.21.48N 80.50.15W
Posts: 1,564
Thanks: 1
Thanked 160 Times in 152 Posts
The exclude option is Linux option, not SCO.



Code:
list=`ls  |grep -v SQL`
tar cvf backup.tar $list


Last edited by jgt; 01-26-2010 at 10:09 AM..
Sponsored Links
    #3  
Old 01-26-2010
edfair edfair is offline
Registered User
 
Join Date: May 2008
Last Activity: 17 December 2014, 9:06 AM EST
Location: Tucker GA
Posts: 168
Thanks: 0
Thanked 14 Times in 14 Posts
I'll make the suggestion that you use the backup package "microlite edge" for a more reliable backup solution with the ability to exclude files and directories. And it has the ability to verify the backups.
Sponsored Links
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Exclude list decamposem UNIX for Dummies Questions & Answers 3 12-02-2008 12:56 PM
tar exclude list Tirmazi Solaris 2 09-20-2008 12:53 PM
du (exclude files) the_learner UNIX for Advanced & Expert Users 1 07-17-2007 03:06 PM
Exclude & Zip dreams5617 Shell Programming and Scripting 1 02-11-2007 08:01 PM
tar: how to exclude subdirectories? kymberm Filesystems, Disks and Memory 7 10-15-2002 04:53 PM



All times are GMT -4. The time now is 11:58 PM.