Configure Impala Daemon to spill to Ozone
You can use Ozone as a scratch space for writing intermediate files during large sorts, joins, aggregations, or analytic function operations.
Before you begin
- Identify the Ozone scratch directory where you want your new Impala to write the temporary data.
- Identify the IP address, host name, or service identifier of Ozone.
- Identify the port number of the Ozone Manager (if not-default).
Configuring the Start-up Option in Impala daemon
You can use the Impalad start option
scratch_dirs to specify the locations of the
--scratch_dirs="ofs://authority/path(:max_bytes), local_buffer_dir (,local_dir…)"
ofs://authority/pathis the remote directory.
Using the above format:
- You can specify only one remote directory. When you configure a remote directory, you must specify a local buffer directory as the buffer. However you can use multiple local directories with the remote directory. If you specify multiple local directories, the first local directory would be used as the local buffer directory.
- If you configure both remote and local directories, the remote directory is only used when the local directories are fully utilized.
- The size of a remote intermediate file could affect the query performance, and the
value can be set by
--remote_tmp_file_size=sizein the start-up option. The default size of a remote intermediate file is 16MB while the maximum is 512MB.
- An Ozone scratch dir with one local buffer dir, file size 64MB. The space of Ozone
scratch dir is limited to 300G.
- An Ozone scratch dir with one local buffer dir limited to 512MB, and one local dir
limited to 10GB. The space of Ozone scratch dir is limited to 300G. The Ozone Manager
uses its default port (9862).
- An Ozone scratch dir with one local buffer dir, and multiple prioritized local dirs. The
space of Ozone scratch dir is unlimited. The Ozone service identifier is
Even though max_bytes is optional, it is highly recommended to configure for spilling to Ozone because the Ozone cluster space is limited.