Hi there,
I want some help on scripting regarding file processing.
I have a scenario in which I have 10 files. (file1.txt, file2.txt....) and they are in paricular format.
I want to read these files and append some text lines at the begining of each file and write this updated contents of... (2 Replies)
Hi
I have a tab delimited file with 3 fields. I need to sort this file on the first field and remove all the records where the first field has dulplicates. For eg my file is
133|arrfdfdg|sdfdsg
234|asfsdgfs|aasdfs
133|affbfsde|dgfg
When this file gets sorted I need the result to be ... (2 Replies)
Hi,
Iam having the two files as follows:
file1:
ASQWEDFR09876543121234512
POIUYTREW09876512345676788
ZXCVBNMKS1209888888888888
file2:
ASQWEDFR09876543121234516 asdcvfgbtg@abc.com 0000000-90-1239--2008 8990----
CXADFGTU09876543121234789 asdcvfgbtg@abc.com ... (14 Replies)
hi All,
my query...
1.I Have to search for the files in the root directory.
2.i have to search for a pattern in all the files in the root directory and then replace them with a new pattern.
3.Rename the file
Explanation:
if ABC is the root folder and has 3 subfolders and there are 15... (9 Replies)
Hi,
I have a file with thousands of lines like this:
Chr1 477515 . ACCCC ACCC 17.7 . INDEL;DP=17;AF1=1;CI95=0.5,1;DP4=0,1,0,3;MQ=32;PV4=1,0.036,1,1
Chr1 481987 . A AAAT 62 . INDEL;DP=11;AF1=1;CI95=0.5,1;DP4=0,0,1,3;MQ=41
I want to make a file with... (2 Replies)
Hello all,
I am looking for a solution to the following problem. Perl or python solutions also welcome.
Given this input:
And this input:
I want to get this output.
The rule being that if the number in the first file is < 0.9, then the corresponding two columns on... (2 Replies)
Hi ,
I have a file myhost.txt which contains below,
127.0.0.1 localhost
1.17.1.5 atrpx958
11.17.10.11 atrpx958zone nsybhost
I need to append words only after "atrpx958" like 'myhost' and 'libhost' and not after atrpx958zone.
How to search the word atrpx958(which is hostname) only,... (5 Replies)
Hi,
does any one know the environmental parameter that I have to set so as to make sure the file operations run properly within the script.
right now when I am doing a cat from within the script nothing happens, same is the case when I do a grep. when I am doing awk '{print $0 }' its printing... (1 Reply)
i am reading and writing to a a file in C language. the input file is described as follows
111 aaa descr1
222 bbb descr2
333 ccc <SPACE> {6 spaces are left after ccc i.e in 3rd column}
444 ddd descr4
when i read and write to a file, the space is not coming in the output file.... (8 Replies)
Hi Folks,
Below is example of an Input data which is used, based on the last 2, 3 & 4 column, I want my first column data to be collated as shown in the output section.
a,ac,tc,ic
b,ac,tc,ic
c,ac,tc,ic
d,ac,tc,ic
b,bc,tc,ic
d,bc,tc,ic
e,bc,tc,ic
I want my output to be
... (2 Replies)
Discussion started by: nikhil jain
2 Replies
LEARN ABOUT REDHAT
du
DU(1) FSF DU(1)NAME
du - estimate file space usage
SYNOPSIS
du [OPTION]... [FILE]...
DESCRIPTION
Summarize disk usage of each FILE, recursively for directories.
Mandatory arguments to long options are mandatory for short options too.
-a, --all
write counts for all files, not just directories
-B, --block-size=SIZE use SIZE-byte blocks
-b, --bytes
print size in bytes
-c, --total
produce a grand total
-D, --dereference-args
dereference FILEs that are symbolic links
-h, --human-readable
print sizes in human readable format (e.g., 1K 234M 2G)
-H, --si
likewise, but use powers of 1000 not 1024
-k like --block-size=1K
-l, --count-links
count sizes many times if hard linked
-L, --dereference
dereference all symbolic links
-S, --separate-dirs
do not include size of subdirectories
-s, --summarize
display only a total for each argument
-x, --one-file-system
skip directories on different filesystems
-X FILE, --exclude-from=FILE
Exclude files that match any pattern in FILE.
--exclude=PATTERN Exclude files that match PATTERN.
--max-depth=N
print the total for a directory (or file, with --all) only if it is N or fewer levels below the command line argument;
--max-depth=0 is the same as --summarize
--help display this help and exit
--version
output version information and exit
SIZE may be (or may be an integer optionally followed by) one of following: kB 1000, K 1024, MB 1,000,000, M 1,048,576, and so on for G, T,
P, E, Z, Y.
PATTERNS
PATTERN is a shell pattern (not a regular expression). The pattern ? matches any one character, whereas * matches any string (composed of
zero, one or multiple characters). For example, *.o will match any files whose names end in .o. Therefore, the command
du --exclude='*.o'
will skip all files and subdirectories ending in .o (including the file .o itself).
AUTHOR
Written by Torbjorn Granlund, David MacKenzie, Larry McVoy, and Paul Eggert.
REPORTING BUGS
Report bugs to <bug-coreutils@gnu.org>.
COPYRIGHT
Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICU-
LAR PURPOSE.
SEE ALSO
The full documentation for du is maintained as a Texinfo manual. If the info and du programs are properly installed at your site, the com-
mand
info du
should give you access to the complete manual.
du (coreutils) 4.5.3 February 2003 DU(1)