*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->HP-UX 11i man pages -> sum (1)              


 sum(1)                                                               sum(1)

 NAME    [Toc]    [Back]
      sum - print checksum and block or byte count of file(s)

 SYNOPSIS    [Toc]    [Back]
      sum [-r] [-p] [file ...]

    Remarks    [Toc]    [Back]
      sum is obsolescent and should not be used in new applications that are
      intended to be portable between systems.  Use cksum instead (see

 DESCRIPTION    [Toc]    [Back]
      sum calculates and prints to standard output a checksum for each named
      file, and also prints the size of the file in 512 byte blocks, rounded

      The default algorithm is a 16-bit sum of the bytes in which overflow
      is ignored.  Alternate algorithms can be selected with the -r and -p

      Standard input is used if no file names are given.

      sum is typically used to verify data integrity when copying files
      between systems.

    Options    [Toc]    [Back]
      sum recognizes the following options:

           -r        Use an alternate algorithm in which the 16-bit sum is
                     right rotated with each byte in computing the checksum.

           -p        Use the 32-bit cyclical redundancy check (CRC)
                     algorithm used by cksum.

 RETURN VALUE    [Toc]    [Back]
      sum returns the following values upon completion:

            0        All files were processed successfully.

           >0        One or more files could not be read or some other error

      If an inaccessible file is encountered, sum continues processing any
      remaining files, but the final exit status is affected.

 DIAGNOSTICS    [Toc]    [Back]
      Read error conditions are indistinguishable from end of file on most
      devices; check the block or byte count.

 WARNINGS    [Toc]    [Back]
      This command is likely to be withdrawn from X/Open standards.

 Hewlett-Packard Company            - 1 -   HP-UX 11i Version 2: August 2003

 sum(1)                                                               sum(1)

      Applications using this command might not be portable to other
      vendors' platforms. The usage of cksum(1) is recommended.

 SEE ALSO    [Toc]    [Back]
      cksum(1), wc(1).

      sum: SVID2, SVID3, XPG2, XPG3

 Hewlett-Packard Company            - 2 -   HP-UX 11i Version 2: August 2003
[ Back ]
 Similar pages
Name OS Title
sum IRIX print checksum and block count of a file
sum Tru64 Displays the checksum and byte count in block-size (1024) units of a file
cksum Tru64 Displays the checksum and byte count of a file
xlate_pro_disk_header IRIX get translation byte stream block count
sum Linux checksum and count the blocks in a file
cksum Linux checksum and count the bytes in a file
cksum HP-UX print file checksum and sizes
xfs_bmap IRIX print block mapping for an XFS file
wc IRIX word, line and byte or character count
wc FreeBSD word, line, character, and byte count
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service