<term><option>--char-signedness=<replaceable class="parameter">option</replaceable></option></term>
<listitem>
<para>
Manually set the default char signedness. Possible values are
<literal>signed</literal> and <literal>unsigned</literal>.
</para>
<para>
For a database cluster that <command>pg_upgrade</command> upgraded from
a <productname>PostgreSQL</productname> version before 18, the safe
value would be the default <type>char</type> signedness of the platform
that ran the cluster before that upgrade. For all other
clusters, <literal>signed</literal> would be the safe value. However,
this option is exclusively for use with <command>pg_upgrade</command>
and should not normally be used manually.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><option>--wal-segsize=<replaceable class="parameter">wal_segment_size</replaceable></option></term>
<listitem>
<para>
Set the new WAL segment size, in megabytes. The value must be set to a
power of 2 between 1 and 1024 (megabytes). See the same option of <xref
linkend="app-initdb"/> for more information.
</para>
<para>
This option can also be used to change the WAL segment size of an
existing database cluster, avoiding the need to
re-<command>initdb</command>.
</para>
<note>
<para>
While <command>pg_resetwal</command> will set the WAL starting address
beyond the latest existing WAL segment file, some segment size changes
can cause previous WAL file names to be reused. It is recommended to
use <option>-l</option> together with this option to manually set the
WAL starting address if WAL file name overlap will cause problems with
your archiving strategy.
</para>
</note>
</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1>
<title>Environment</title>
<variablelist>
<varlistentry>
<term><envar>PG_COLOR</envar></term>
<listitem>
<para>
Specifies whether to use color in diagnostic messages. Possible values
are <literal>always</literal>, <literal>auto</literal> and
<literal>never</literal>.
</para>
</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1>
<title>Notes</title>
<para>
This command must not be used when the server is
running. <command>pg_resetwal</command> will refuse to start up if
it finds a server lock file in the data directory. If the
server crashed then a lock file might have been left
behind; in that case you can remove the lock file to allow
<command>pg_resetwal</command> to run. But before you do
so, make doubly certain that there is no server process still alive.
</para>
<para>
<command>pg_resetwal</command> works only with servers of the same
major version.
</para>
</refsect1>
<refsect1>
<title>See Also</title>
<simplelist type="inline">
<member><xref linkend="app-pgcontroldata"/></member>
</simplelist>
</refsect1>
</refentry>