07-17-2007
du (exclude files)
Hi,
I want to get the disk usage of a directory. But I want it to ignore a particular directory within it.
Lets say I want disk usage of all files/dirs within dir1 except those that are named .snapshot
Does du have the option of excluding a particular directory.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
If I execute the command "ls -l /export/home/abcde/dev/proj/code/* | awk -F' ' '{print $9}' | cut -d'/' -f6-8" it will list all the files in /export/home/abcde/dev/proj/code/ directory as well as the files in subdirectories also
proj/code/test.sh
proj/code/test1.c
proj/code/unix... (8 Replies)
Discussion started by: shyjuezy
8 Replies
2. AIX
HI,
I have upgraded nim master and client to TL8,SP6. Now when the mksysb backup ran from master,it is not excluding directories specified in /etc/exclude.rootvg in the client.Instead,mksysb is getting created for all the file systems in the rootvg. This problem only appeared after the TL... (3 Replies)
Discussion started by: to_bsr
3 Replies
3. Shell Programming and Scripting
I have a DB folder which sizes to 60GB approx. It has logs which size from 500MB - 1GB. I have an Installation which would update the DB. I need to backup this DB folder, just incase my Installation FAILS. But I do not need the logs in my backup. How do I exclude them during compression (tar)?
... (2 Replies)
Discussion started by: DevendraG
2 Replies
4. Ubuntu
I am familiar with using tar and exclude/include files:
tar zcf backup.dirs.tgz --files-from=include.mydirs --exclude-from=exclude.mydirs --no-recursion
but was wondering if I could use find in the same way. I know that you can just specify the directories to exclude but my list is... (2 Replies)
Discussion started by: metallica1973
2 Replies
5. Shell Programming and Scripting
I wrote this korn script and ran into a hole. I can use find to exclude all the hidden directories and to use my include file/exclude files for running a full backup
find / -depth -ipath '/home/testuser/.*' -prune -o -print| grep -f include.mydirs | grep -v -f exclude.mydirs
but when I... (8 Replies)
Discussion started by: metallica1973
8 Replies
6. Shell Programming and Scripting
I am new to Shell Scripting and need some help.
The following batch job has been failing for me due to the .nfsxxx files in use. I need to know how to modify the following script to exclude the .nfsxxx files so this batch job will not fail on me. I have done lots of googling and keep coming back... (2 Replies)
Discussion started by: kimberlyg2007
2 Replies
7. Shell Programming and Scripting
Hi All,
I am bit puzzled with this requirement where I need to list the files in a directory. However, files are being continuously written to this folder through FTP. Hence I need to exclude the file which is being written at the time of listing the directory. I thought of using file time... (5 Replies)
Discussion started by: angshuman
5 Replies
8. Shell Programming and Scripting
hi,
I would like to exlcude certain files which starts with AUS from a directory while gzip the files but i need it in gzip command only
direct:
AUS1.tx
AUS2.txt
NZ1.txt
i want to gzip only NZ1.txt to NZ1.gz files starting with AUS should not be gzipped and i need it in gzip... (23 Replies)
Discussion started by: rohit_shinez
23 Replies
9. Shell Programming and Scripting
Hi,
I need to exlucde the files which are present in exclude.txt from a directory
exlcude.txt
AUZ.txt
AUZ.chk
NZ.txt
NZ.chk
tried with below code but not working
ls -ltr | grep -v `cat exclude.lst` (9 Replies)
Discussion started by: rohit_shinez
9 Replies
10. Shell Programming and Scripting
Hi.
I want to schedule a job at some directory will several files in it.
But there maybe a situation whereby some of the files at the point of the schedule are still transferring during that time.
So I want to skip those files from being processed.
Two method that come to my mind:
1.... (5 Replies)
Discussion started by: aimy
5 Replies
LEARN ABOUT DEBIAN
btrfsctl
BTRFSCTL(8) System Manager's Manual BTRFSCTL(8)
NAME
btrfsctl - control a btrfs filesystem
SYNOPSIS
btrfsctl [ -d file|directory ] [ -s snapshot-name directory ] [ -S subvolume-name directory ] [ -r [+-]size ] [ -A device ] [ -a ] [
-c ]
DESCRIPTION
btrfsctl is used to control the filesystem and the files and directories stored. It is the tool to create a new snapshot for the filesys-
tem.
OPTIONS
-d file|directory
Defragment a file or a directory. If the argument is a directory, the entire b-tree under the directory is defragged.
-s snapshot-name directory
Creates a new snapshot of the directory specified.
-S subvolume-name directory
Creates a new subvolume.
-r [+|-]size
Resizes the filesystem with the size specified. If the value is preceded with a signed symbol, the filesystem is resized with
respect to the current filesystem size. size can be suffixed by k,m or g to represent kilobytes, megabytes, or gigabytes respec-
tively.
-A device
Scans the device for btrfs filesystem.
-a Scans all devices present in the system for btrfs filesystem.
-c Forces a filesystem sync.
AVAILABILITY
btrfsctl is part of btrfs-progs. Btrfs is currently under heavy development, and not suitable for any uses other than benchmarking and
review. Please refer to the btrfs wiki http://btrfs.wiki.kernel.org for further details.
SEE ALSO
mkfs.btrfs(8)
BTRFSCTL(8)