Sponsored Content
Top Forums Shell Programming and Scripting Find the sum of files created 5 days before Post 302594806 by bang_dba on Wednesday 1st of February 2012 08:42:44 AM
Old 02-01-2012
Find the sum of files created 5 days before

Hi,

I want to find the sum of all the files created 5 days ago and store it in a variable. (os is HP-UX)

can this be extracted from ls -l

Is there any other way of getting the sum of all the files created
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Deleting files created before two days ago

Dear All: I want to build a shell that delete files created two or more days ago ... I think it could be built using a special command with ls or grep, I'd apreciate any help from you guys I have a lot of log files from november, december, january and this tool will help me a lot The files... (3 Replies)
Discussion started by: josecollantes
3 Replies

2. Shell Programming and Scripting

Find files older than 20 days & not use find

I need to find files that have the ending of .out and that are older than 20 days. However, I cannot use find as I do not want to search in the directories that are underneath the directory that I am searching in. How can this be done?? Find returns files that I do not want. (2 Replies)
Discussion started by: halo98
2 Replies

3. Shell Programming and Scripting

List files created before Noon 2 days prior

Our nightly updates run in the evening and finish around 8am. My boss wants the current log files kept on the server for 2 days, but wants anything created before noon, 2 days prior archived. I was thinking of using touch to set a temporary file with a date of today-2 and a time of noon, then... (3 Replies)
Discussion started by: prismtx
3 Replies

4. Shell Programming and Scripting

Remove files which created date before 10 days on HP-UX

Hi All, Could you please let me know if there is any one can help to create a shell script to remove some files which is the created date for them greate than 10 days (sysdate-10) Please try to email me on email removed Thanks in advance, Murad (1 Reply)
Discussion started by: murad_fayez
1 Replies

5. Shell Programming and Scripting

Find the directory modified/created before 4 days

Hi, I have an application which creates some directories while running. I want to delete these directories which are 4 days older. i tried find . type d -mtime +1 -print And it is working fine.. but find . type d -mtime +4 -print is not giving any results which are 4 days... (6 Replies)
Discussion started by: Tuxidow
6 Replies

6. Shell Programming and Scripting

find files created within 30 minutes

find . -name *.txt -mmin -30 This is working in Redhat but not in Solaris.. What is the equivalent option in Solaris? (1 Reply)
Discussion started by: tene
1 Replies

7. Shell Programming and Scripting

Find directories only and delete them created 3 days before

Hello I have some directories and files created under /export/local/user I would like to delete directories only under /export/local/user, created before 3 days Can someone help me with command to do this task? Thanks (4 Replies)
Discussion started by: needyourhelp10
4 Replies

8. UNIX for Dummies Questions & Answers

How to find files created some days before?

HI, I have 2 questions. 1> Is there any code to see files that created some day or some time before in a directory??? 2> how or where i will find the last exit status of a process?? thanks (6 Replies)
Discussion started by: jyotidas
6 Replies

9. Shell Programming and Scripting

Find unix file created how many days ago?

i want to find unix file created how many days ago? (4 Replies)
Discussion started by: utoptas
4 Replies

10. Shell Programming and Scripting

what is the find to command to find the files created last 30 days

what is the find to command to find the files created last 30 days (5 Replies)
Discussion started by: rajkumar_g
5 Replies
sum(n)							     Cyclic Redundancy Checks							    sum(n)

__________________________________________________________________________________________________________________________________________________

NAME
sum - Calculate a sum(1) compatible checksum SYNOPSIS
package require Tcl 8.2 package require sum ?1.1.0? ::crc::sum ?-bsd | -sysv? ?-format fmt? ?-chunksize size? [ -filename file | -channel chan | string ] _________________________________________________________________ DESCRIPTION
This package provides a Tcl-only implementation of the sum(1) command which calculates a 16 bit checksum value from the input data. The BSD sum algorithm is used by default but the SysV algorithm is also available. COMMANDS
::crc::sum ?-bsd | -sysv? ?-format fmt? ?-chunksize size? [ -filename file | -channel chan | string ] The command takes string data or a file name or a channel and returns a checksum value calculated using the sum(1) algorithm. The result is formatted using the format(n) specifier provided or as an unsigned integer (%u) by default. OPTIONS
-sysv The SysV algorithm is fairly naive. The byte values are summed and any overflow is discarded. The lowest 16 bits are returned as the checksum. Input with the same content but different ordering will give the same result. -bsd This algorithm is similar to the SysV version but includes a bit rotation step which provides a dependency on the order of the data values. -filename name Return a checksum for the file contents instead of for parameter data. -channel chan Return a checksum for the contents of the specified channel. The channel must be open for reading and should be configured for binary translation. The channel will no be closed on completion. -chunksize size Set the block size used when reading data from either files or channels. This value defaults to 4096. -format string Return the checksum using an alternative format template. EXAMPLES
% crc::sum "Hello, World!" 37287 % crc::sum -format 0x%X "Hello, World!" 0x91A7 % crc::sum -file sum.tcl 13392 AUTHORS
Pat Thoyts BUGS, IDEAS, FEEDBACK This document, and the package it describes, will undoubtedly contain bugs and other problems. Please report such in the category crc of the Tcllib SF Trackers [http://sourceforge.net/tracker/?group_id=12883]. Please also report any ideas for enhancements you may have for either package and/or documentation. SEE ALSO
cksum(n), crc32(n), sum(1) KEYWORDS
checksum, cksum, crc, crc32, cyclic redundancy check, data integrity, security, sum COPYRIGHT
Copyright (c) 2002, Pat Thoyts <patthoyts@users.sourceforge.net> crc 1.1.0 sum(n)
All times are GMT -4. The time now is 07:54 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy