Sponsored Content
Full Discussion: To check file size in hadoop
Top Forums Programming To check file size in hadoop Post 302987919 by RudiC on Sunday 18th of December 2016 07:57:53 AM
Old 12-18-2016
Does your hadoop fs allow for the -b option to output byte sizes?
If not: your problem has been solved umpteen times in these fora; try searching in here...
This User Gave Thanks to RudiC For This Post:
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Check file size

I need a unix script that will check the size of multiple files in the same directory or from a text file. (6 Replies)
Discussion started by: alnita
6 Replies

2. Shell Programming and Scripting

file size check

How can I perform size check of any character file(which switch)? For example: I have to perform certain actions if file size is not zero. How can I do that? Is this syntax fine? if test ! -z $filename then fi (2 Replies)
Discussion started by: malaymaru
2 Replies

3. Shell Programming and Scripting

To check file size

Hi All, I am in small problem.. i have one script which transfers some big files to my ftp usign normal command like put .... my problem is how to check whether my file have been transferred successfully on ftp or not... i know only inside ftp we have option like 'size' command which... (2 Replies)
Discussion started by: Shahul
2 Replies

4. Shell Programming and Scripting

Check for file size is zero or not.

I have following script on AIX/KSH if ] ; then echo "filename exists and is > 0 bytes" else echo "filename does not exist or is zero length" fi It is not working. What is wrong here??? (3 Replies)
Discussion started by: Hangman2
3 Replies

5. Shell Programming and Scripting

Check the file size - help

I want to write a batch job (ksh) with the following requirement we have file feeds coming to our system from other team, if the file size is greater than expected then we dont need to process the file for the day and need to archive the file and send email notification to the manager saying... (5 Replies)
Discussion started by: sithara
5 Replies

6. Shell Programming and Scripting

check the file size

if ; then cp /tmp/testfolder/*.* ~/new/logs/ else echo "No files today" exit fi The problem is this doen't work when there is more than 1 file. Please tell me how to take the latest file and check the size of the file in a directory (1 Reply)
Discussion started by: sandy1028
1 Replies

7. Shell Programming and Scripting

Check the presence of file >size?

Hi, Following script work fine: #!/bin/bash FILE=$1 if ; then echo Yay else echo Boo fi But I would like to add another condition that if FILE... (3 Replies)
Discussion started by: nrjrasaxena
3 Replies

8. Shell Programming and Scripting

Check a file size

I'm doing a script thats check if mylogfile.log is bigger then 5000 but i dont know how to write it. thanks in avance. (6 Replies)
Discussion started by: Froob
6 Replies

9. Shell Programming and Scripting

File size check

I am trying to check whether two files are empty or not using below if condition but its checking for only one file if ] Again I tried if && ] Need your assistance (2 Replies)
Discussion started by: Aditya_001
2 Replies
DF(1)							    BSD General Commands Manual 						     DF(1)

NAME
df -- display free disk space SYNOPSIS
df [-b | -h | -H | -k | -m | -g | -P] [-ailn] [-t] [-T type] [file | filesystem ...] LEGACY SYNOPSIS
df [-b | -h | -H | -k | -m | -P] [-ailn] [-t type] [-T type] [file | filesystem ...] DESCRIPTION
The df utility displays statistics about the amount of free disk space on the specified filesystem or on the filesystem of which file is a part. Values are displayed in 512-byte per block counts. If neither a file or a filesystem operand is specified, statistics for all mounted filesystems are displayed (subject to the -t option below). The following options are available: -a Show all mount points, including those that were mounted with the MNT_IGNORE flag. -b Use (the default) 512-byte blocks. This is only useful as a way to override an BLOCKSIZE specification from the environment. -g Use 1073741824-byte (1-Gbyte) blocks rather than the default. Note that this overrides the BLOCKSIZE specification from the environ- ment. -H "Human-readable" output. Use unit suffixes: Byte, Kilobyte, Megabyte, Gigabyte, Terabyte and Petabyte in order to reduce the number of digits to three or less using base 10 for sizes. -h "Human-readable" output. Use unit suffixes: Byte, Kilobyte, Megabyte, Gigabyte, Terabyte and Petabyte in order to reduce the number of digits to three or less using base 2 for sizes. -i Include statistics on the number of free inodes. This option is now the default to conform to Version 3 of the Single UNIX Specification (``SUSv3'') Use -P to suppress this output. -k Use 1024-byte (1-Kbyte) blocks, rather than the default. Note that this overrides the BLOCKSIZE specification from the environment. -l Only display information about locally-mounted filesystems. -m Use 1048576-byte (1-Mbyte) blocks rather than the default. Note that this overrides the BLOCKSIZE specification from the environ- ment. -n Print out the previously obtained statistics from the filesystems. This option should be used if it is possible that one or more filesystems are in a state such that they will not be able to provide statistics without a long delay. When this option is speci- fied, df will not request new statistics from the filesystems, but will respond with the possibly stale statistics that were previ- ously obtained. -P Use (the default) 512-byte blocks. This is only useful as a way to override an BLOCKSIZE specification from the environment. -T Only print out statistics for filesystems of the specified types. More than one type may be specified in a comma separated list. The list of filesystem types can be prefixed with ``no'' to specify the filesystem types for which action should not be taken. For example, the df command: df -T nonfs,mfs lists all filesystems except those of type NFS and MFS. The lsvfs(1) command can be used to find out the types of filesystems that are available on the system. -t If used with no arguments, this option is a no-op (Mac OS X already prints the total allocated-space figures). If used with an argu- ment, it acts like -T, but this usage is deprecated and should not be relied upon. ENVIRONMENT
BLOCKSIZE If the environment variable BLOCKSIZE is set, the block counts will be displayed in units of that size block. BUGS
The -n and -t flags are ignored if a file or filesystem is specified. LEGACY DESCRIPTION
The "capacity" percentage is normally rounded up to the next higher integer. In legacy mode, it is rounded down to the next lower integer. When the -P option and the -k option are used together, sizes are reported in 1024-blocks. In legacy mode, when the -P option and -k option are used together, the last option specified dictates the reported block size. The -t option is normally a no-op (Mac OS X already prints the total allocated-space figures). In legacy mode, it is equivalent to -T. For more information about legacy mode, see compat(5). SEE ALSO
lsvfs(1), quota(1), fstatfs(2), getfsstat(2), statfs(2), getmntinfo(3), compat(5), fstab(5), mount(8), quot(8) HISTORY
A df command appeared in Version 1 AT&T UNIX. BSD
May 8, 1995 BSD
All times are GMT -4. The time now is 07:58 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy