unixdev.net


Switch to SpeakEasy.net DSL

The Modular Manual Browser

Home Page
Manual: (SunOS-4.1.3)
Page:
Section:
Apropos / Subsearch:
optional field

SUM(1V)                                                                SUM(1V)



NAME
       sum - calculate a checksum for a file

SYNOPSIS
       sum filename

SYSTEM V SYNOPSIS
       /usr/5bin/sum [ -r ] filename

AVAILABILITY
       The  System  V  version  of this command is available with the System V
       software installation option.  Refer  to  for  information  on  how  to
       install optional software.

DESCRIPTION
       sum  calculates  and displays a 16-bit checksum for the named file, and
       also displays the size of the file in kilobytes.  It is typically  used
       to  look  for  bad  spots, or to validate a file communicated over some
       transmission line.  The checksum is calculated by  an  algorithm  which
       may  yield  different results on machines with 16-bit ints and machines
       with 32-bit ints, so it cannot always be used to validate that  a  file
       has been transferred between machines with different-sized ints.

SYSTEM V DESCRIPTION
       sum  calculates  and  prints  a 16-bit checksum for the named file, and
       also prints the number of 512-byte blocks in the file.  It is typically
       used  to  look  for  bad spots, or to validate a file communicated over
       some transmission line.  This algorithm is independent of the  size  of
       ints on the machine.

SYSTEM V OPTIONS
       The option -r causes the (machine-dependent) algorithm used by the non-
       System V sum to be used in computing the checksum.

SEE ALSO
       wc(1)

DIAGNOSTICS
       Read error is indistinguishable from EOF on  most  devices;  check  the
       block count.



                               9 September 1987                        SUM(1V)