<?xml version="1.0" encoding="latin1" ?>
<!DOCTYPE fileref SYSTEM "fileref.dtd">

<fileref>
  <header>
    <copyright>
      <year>1997</year>
      <year>2011</year>
      <holder>Ericsson AB, All Rights Reserved</holder>
    </copyright>
    <legalnotice>
  The contents of this file are subject to the Erlang Public License,
  Version 1.1, (the "License"); you may not use this file except in
  compliance with the License. You should have received a copy of the
  Erlang Public License along with this software. If not, it can be
  retrieved online at http://www.erlang.org/.

  Software distributed under the License is distributed on an "AS IS"
  basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
  the License for the specific language governing rights and limitations
  under the License.

  The Initial Developer of the Original Code is Ericsson AB.
    </legalnotice>

    <title>relup</title>
    <prepared></prepared>
    <docno></docno>
    <date></date>
    <rev></rev>
  </header>
  <file>relup</file>
  <filesummary>Release upgrade file</filesummary>
  <description>
    <p>The <em>release upgrade file</em> describes how a release is
      upgraded in a running system.</p>
    <p>This file is automatically generated by
      <c>systools:make_relup/3,4</c>, using a release resource file
      (<c>.rel</c>), application resource files (<c>.app</c>) and
      application upgrade files (<c>.appup</c>) as input.</p>
  </description>

  <section>
    <title>FILE SYNTAX</title>
    <p>In a target system, the release upgrade file should be located in
      the <c>OTP_ROOT/erts-EVsn/Vsn</c> directory.</p>
    <p>The <c>relup</c> file contains one single Erlang term, which
      defines the instructions used to upgrade the release. The file has
      the following syntax:</p>
    <code type="none">
{Vsn,
  [{UpFromVsn, Descr, Instructions}, ...],
  [{DownToVsn, Descr, Instructions}, ...]}.
    </code>
    <list type="bulleted">
      <item>
        <p><c>Vsn = string()</c> is the current version of the release.</p>
      </item>
      <item>
        <p><c>UpFromVsn = string()</c> is an earlier version of the release
          to upgrade from.</p>
      </item>
      <item>
        <p><c>Descr = term()</c> is a user defined parameter passed
          from the <c>systools:make_relup/3,4</c> function. It will
          be used in the return value of
          <c>release_handler:install_release/1,2</c>.</p>
      </item>
      <item>
        <p><c>Instructions</c> is a list of low-level release upgrade
          instructions, see <c>appup(4)</c>.</p>
        <p>It consists of the release upgrade instructions from
          the respective application upgrade files (high-level instructions
          are translated to low-level instructions), in the same order
          as in the start script.</p>
      </item>
      <item>
        <p><c>DownToVsn = string()</c> is an earlier version of the release
          to downgrade to.</p>
      </item>
    </list>
    <p>When upgrading from <c>UpFromVsn</c> with
      <c>release_handler:install_release/1,2</c>, there does not have to be
      an exact match of versions, but <c>UpFromVsn</c> can be a sub-string
      of the current release version.</p>
  </section>

  <section>
    <title>SEE ALSO</title>
    <p>app(4), appup(4), rel(4), release_handler(3), systools(3)</p>
  </section>
</fileref>

