Sponsored Content
Homework and Emergencies Emergency UNIX and Linux Support Command to calculate space for all subdirs under a dir Post 302618503 by vipinkumarr89 on Wednesday 4th of April 2012 05:32:46 AM
Old 04-04-2012
if you want to check the size of subdirectories under a directory, then it will be better to to check the size of parent directory, for parent directory run this command,
Code:
du -k /home/vipin/data

(data is the directory,that i want to check the size ).

Moderator's Comments:
Mod Comment Welcome to the UNIX and Linux Forums. Please use code tags. Video tutorial on how to use them

Last edited by Scrutinizer; 04-04-2012 at 06:42 AM.. Reason: Code tags
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

calculate the space

Hi everyone, I need to write a script to calculate the space for sub-folders under /home: Here is the scanrio: cd /home drwxr-xr-x 57 root root 8192 Jan 22 16:13 home_1 drwxrwxrwx 69 root root 8192 Jan 29 10:36 home_2 drwxr-xr-x 97 root root 8192 Nov... (8 Replies)
Discussion started by: za_7565
8 Replies

2. AIX

find command - no subdirs

I am looking to delete files that are of a certain age with something like the following... find /directory -type f -mtime +14 | xargs rm ....however, I would like to only execute this on the current directory and not subdirectories. Any ideas? (4 Replies)
Discussion started by: andrewsc
4 Replies

3. Shell Programming and Scripting

sftp how to deal with space in path to dir?

OK I am trying to use something similar to this: #!/bin/sh echo "OK, starting now..." sftp -b /dev/fd/0 user@remotehost <<EOF cd pub ascii put filename.txt bye EOF only difference is the dir I need to cd to has a space in it like this /Import/Server/Prospect File ,... (3 Replies)
Discussion started by: NewSolarisAdmin
3 Replies

4. Shell Programming and Scripting

substrings from all files incl subdirs into csv with dir names

Greetings! I have multiple files, one per subdirectory, all with the same file name. All subdirectories are one level deep from the main directory. The data in the files is tab delimited between fields and record delimited with a newline. The subdirectory names have the date in the... (5 Replies)
Discussion started by: vtischuk@yahoo.
5 Replies

5. Shell Programming and Scripting

Calculate total space, total used space and total free space in filesystem names matching keyword

Good afternoon! Im new at scripting and Im trying to write a script to calculate total space, total used space and total free space in filesystem names matching a keyword (in this one we will use keyword virginia). Please dont be mean or harsh, like I said Im new and trying my best. Scripting... (4 Replies)
Discussion started by: bigben1220
4 Replies

6. Shell Programming and Scripting

create dir in main &subdirs,perform action

Hi, I have one dir which has N subdirs.For ex: /home/user/Project_Src /home/user/Project_Src/Dir_A /home/user/Project_Src/Dir_A/subdir/sub_dir2 /home/user/Project_Src/Dir_A/subdir/sub_dir3 /home/user/Project_Src/Dir_B /home/user/Project_Src/Dir_B/Build i want to create a folder with... (2 Replies)
Discussion started by: dragon.1431
2 Replies

7. Shell Programming and Scripting

Copy files and subdirs from dir to a new dir

Hello Comunity I am trying to make a bash shell script that it copies files and subdirs(with files) to a new dir. I would like the dest_dir to contain only subdirectories with files not other subdirs inside. it called : cpflatdir src_dir dest_dir Pleaze help me! Thank you in... (2 Replies)
Discussion started by: BTKBaaMMM
2 Replies

8. UNIX for Dummies Questions & Answers

List files older that 7 days in a dir, excluding all subdirs

Hi, I would like to list all files, older than 7 days, in a directory, but exclude all subdirectories in the find command. If I use find . -type f -mtime +7 all files in the subdirs are also included. How can I exclude them? Regards, JW (6 Replies)
Discussion started by: jwbijl
6 Replies

9. UNIX for Dummies Questions & Answers

Cannot cd to dir with space

I have a script that I am trying to use. I need it to run from a certain directory. I have tried the following: SCRIPT_DIR=$PWD MYDIR="/filemount/files/Move Files" cd "$MYDIR" $SCRIPT_DIR/movefiles.bash I have tried to run it. but I always get "no such file or directory" from the script... (5 Replies)
Discussion started by: newbie2010
5 Replies

10. Solaris

Running a script in a sub dir with space in it

Hi I am trying to run a script in a sub-directory, that has one space on it: such as: /internaldisk1/Task Logs1, but my entry in cron is not working: 0,5,10,15,20,25,30,35,40,45,50,55 * * * * /internaldisk1/Task\ logs1/./remov_reject.sh > /var/tmp/interd_`date '+%Y%M%d'`.log 2>&1 Please can... (4 Replies)
Discussion started by: fretagi
4 Replies
WEBCHECKOUT(1)							    webcheckout 						    WEBCHECKOUT(1)

NAME
webcheckout - check out repositories referenced on a web page SYNOPSIS
webcheckout [options] url [destdir] DESCRIPTION
webcheckout downloads an url and parses it, looking for version control repositories referenced by the page. It checks out each repository into a subdirectory of the current directory, using whatever VCS program is appropriate for that repository (git, svn, etc). The information about the repositories is embedded in the web page using the rel=vcs-* microformat, which is documented at <http://kitenet.net/~joey/rfc/rel-vcs/>. If the optional destdir parameter is specified, VCS programs will be asked to check out repositories into that directory. If there are multiple repositories to check out, each will be checked out into a separate subdirectory of the destdir. OPTIONS
-a, --auth Prefer authenticated repositories. By default, webcheckout will use anonymous repositories when possible. If you have an account that allows you to use authenticated repositories, you might want to use this option. --no-act, -n Do not actually check anything out, just print out the commands that would be run to check out the repositories. --quiet, -q Quiet mode. Do not print out the commands being run. (The VCS commands may still be noisy however.) PREREQUISITES
To use this program you will need lots of VCS programs installed, obviously. It also depends on the perl LWP and HTML::Parser modules. If the perl URI module is installed, webcheckout can heuristically guess what you mean by partial URLs, such as "kitenet.net/~joey"' AUTHOR
Copyright 2009 Joey Hess <joey@kitenet.net> Licensed under the GNU GPL version 2 or higher. This program is included in mr <http://kitenet.net/~joey/code/mr/> perl v5.14.2 2011-09-25 WEBCHECKOUT(1)
All times are GMT -4. The time now is 08:29 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy