My Oracle Support Banner

Temporary File Acquires Incorrect Size (Doc ID 744744.1)

Last updated on AUGUST 10, 2018

Applies to:

Oracle Server - Enterprise Edition - Version: to - Release: 8.1.5 to 11.1
Generic Linux
Generic UNIX


The ls command for listing the directory files has many options associated, i have listed down the most commonly used options.

Usage: ls [OPTION]... [FILE]...

  -h, --human-readable       with -l, print sizes in human readable format
                               (e.g., 1K 234M 2G)
      --si                   likewise, but use powers of 1000 not 1024
  -l                         use a long listing format
  -r, --reverse              reverse order while sorting
  -s, --size                 with -l, print size of each file, in blocks
  -t                         sort by modification time

All the above combination (ls -l, ls -ltr, ls -lt,..etc) seems to be familiar and very commonly used but when trying to list the files with (ls -ls) combination this command will show the size in two formats in column 1 will be the file size in Blocks (OS blocks) and in column 6 will be the size in Bytes.

When using ls -ls against temporary files we can clearly notice that the (Blocks * Block Size)is not equal to
the file size in Bytes, that sounds not normal and confusable.


[rmtdcsol3]/emea/bde/64bit/app/oracle/oradata/EMB102DV> ls -l|grep temp
-rw-------   1 embde    embde    4202496 Sep 22 10:04 temp01.dbf
[rmtdcsol3]/emea/bde/64bit/app/oracle/oradata/EMB102DV> ls -ls|grep temp
 152 -rw-------   1 embde    embde    4202496 Sep 22 10:04 temp01.dbf


To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!

In this Document

Platforms: 1-914CU;

This document is being delivered to you via Oracle Support's Rapid Visibility (RaV) process and therefore has not been subject to an independent technical review.

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.