<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN" [
  <!ENTITY package "norton">
  <!ENTITY date    "April 2004">
]>

<refentry>
<refentryinfo>
    <address><email>coda@cs.cmu.edu</email></address>
    <copyright>
	<year>1995-2004</year>
	<holder>Carnegie Mellon University</holder>
    </copyright>
    <date>&date;</date>
</refentryinfo>

<refmeta>
    <refentrytitle>&package;</refentrytitle>
    <manvolnum>8</manvolnum>
    <refmiscinfo>Coda Distributed File System</refmiscinfo>
</refmeta>

<refnamediv>
    <refname>&package;</refname>
    <refpurpose>Coda File System RVM debugger</refpurpose>
</refnamediv>

<refsynopsisdiv>
    <cmdsynopsis>
	<command>norton</command>
	<arg choice=req><replaceable>RVM_log</replaceable></arg>
	<arg choice=req><replaceable>RVM_data</replaceable></arg>
	<arg choice=req><replaceable>RVM_data_length</replaceable></arg>
    </cmdsynopsis>
</refsynopsisdiv>

<refsect1>
    <title>DESCRIPTION</title>
    <para><command>norton</command> is a utility program that allows you
    to display Coda file server structures that are stored in
    <emphasis>RVM</emphasis>.  Eventually, <command>norton</command>
    will be a full special purpose debugger that allows you to
    manipulate the structures as well.  <command>norton</command>s
    command interface uses the gnu <emphasis>readline</emphasis> library
    which features Emacs style command editting as well as maintaining a
    command history.  Command completion is also supported by using
    <emphasis>&lt;tab&gt;</emphasis> and <emphasis>&lt;esc&gt;-?</emphasis>.
    </para>
    <para>The available commands are:</para>

    <variablelist>
	<varlistentry>
	<term><command>show directory</command>
	<replaceable>volid</replaceable>
	<replaceable>vnum</replaceable>
	<replaceable>uniqifier</replaceable>
	</term>
	<listitem>
	    <para>Lists the contents of the directory indicated by
	    <replaceable>volid.vnum.uniqifier</replaceable>. Each entries
	    vnode number and uniquifier are also listed.</para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>delete name</command>
	<replaceable>volid</replaceable>
	<replaceable>vnum</replaceable>
	<replaceable>uniqifier</replaceable>
	<replaceable>file</replaceable>
	<replaceable>flag</replaceable>
	</term>
	<listitem>
	    <para>Remove <replaceable>file</replaceable> from the
	    directory specified by
	    <replaceable>volid.vnode.uniqifier</replaceable>. If flag is
	    nonzero the linkcount of the directory is reduced by one.
	    </para>
	    <para><emphasis>NOTE: delete name does not do anything to
	    the vnodes associated with <replaceable>file</replaceable>,
	    you must remove the vnodes by hand or update their link
	    count.</emphasis></para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>delete volume</command>
	<replaceable>volid</replaceable>
	</term>
	<listitem>
	    <para>Mark a volume with a "destroyme" flag, so that the
	    salvager will destroy it on the next server startup.</para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>examine</command>
	<replaceable>addr</replaceable>
	<replaceable>len</replaceable>
	</term>
	<listitem>
	    <para>Print <replaceable>len</replaceable> bytes starting
	    from <replaceable>addr</replaceable> in hex and ascii.</para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>list volumes</command></term>
	<listitem>
	    <para>Display a list of all the volumes on the server. This
	    list includes the volume index, name, number, and type.</para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>show free</command>
	<option>large | small</option>
	</term>
	<listitem>
	    <para>Display all of the vnodes on either the large or small
	    free vnode list.</para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>show heap</command></term>
	<listitem>
	    <para>Display RVM heap usage.</para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>show index</command>
	<replaceable>volname | volid</replaceable>
	</term>
	<listitem>
	    <para>Display the RVM index of the given volume name or
	    number.</para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>show vnode</command>
	<replaceable>volid</replaceable>
	<replaceable>vnode | ?</replaceable>
	<replaceable>uniqifier</replaceable>
	</term>
	<listitem>
	    <para>Show the specified vnode.  If an <option>?</option> is
	    given rather than a vnode number, all of the volumes vnode
	    lists are searched for a vnode with a matching uniquifier.
	    </para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>show volume</command>
	<replaceable>volname | volid</replaceable>
	</term>
	<listitem>
	    <para>Show a summary of the specified volume.</para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>show volumedetails</command>
	<replaceable>volname | volid</replaceable>
	</term>
	<listitem>
	    <para>Show all of the RVM state of the specified
	    volume.</para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>create name</command>
	<replaceable>parent_volid</replaceable>
	<replaceable>parent_vnode</replaceable>
	<replaceable>parent_uniqifier</replaceable>
	<replaceable>name</replaceable>
	<replaceable>child_vnode</replaceable>
	<replaceable>child_uniqifier</replaceable>
	</term>
	<listitem>
	    <para>Insert a vnode in a directory. The parent fid gives
	    the directory in which name is to be inserted. The child fid
	    refers to the child vnode. The link count of the directory
	    is increased if the child is a directory vnode.  
	    </para>
	</listitem>
	</varlistentry>

	<varlistentry>
	<term><command>x</command>
	<replaceable>addr</replaceable>
	<replaceable>len</replaceable>
	</term>
	<listitem>
	    <para>Print <replaceable>len</replaceable> bytes starting
	    from <replaceable>addr</replaceable> in hex and ascii. An
	    alias for <command>examine</command>.
	    </para>
	</listitem>
	</varlistentry>
    </variablelist>
</refsect1>

<refsect1>
    <title>AUTHORS</title>
    <para>
    <itemizedlist>
    <listitem><para>Joshua Raiff, 1995, Created</para>
    </listitem>
    <listitem><para>Peter Braam, 1997, new features</para>
    </listitem>
    <listitem><para>Jan Harkes, 2004, converted to DocBook 4.1</para>
    </listitem>
    </itemizedlist>
    </para>
</refsect1>
</refentry>

