### Start the Debugger and the Remote Program

To remotely debug a program, follow these steps:

1. On the machine where the program to be debugged will run, issue the `irmtdbg` command.
2. On the machine where the debugger will run, issue the `idebug` command and provide the remote host name. Either specify the program you want to debug as the last argument of the command, or enter the program name in the Startup dialog that appears.

The `irmtdbg` command has the following syntax:

`irmtdbg [-qprotocol=tcpip [-qport=`port`]] [-qsession=single|multi]`

where:

`-qprotocol=tcpip`
  Specifies the communications protocol to use. Only the TCP/IP communications protocol is supported. This is the default protocol.
`-qport=`port
  Specifies the TCP/IP port used for the connection. If you specify `-qprotocol=tcpip` but you do not specify a port, or if you do not specify a protocol (so that TCP/IP becomes the default protocol), the default port is 8000.
`-qsession=single|multi`
  Specifies whether to support single session debugging or multiple session debugging. The default is single session.

The command for invoking the debugger has the following syntax when used for remote debugging:

`idebug [-qprotocol=tcpip [-qport=`port`]] -qhost=`remotehost`` remote-program`[`program-parameters`]`

where:

`-qhost=`remotehost
  Specifies the TCP/IP name or address of the host to connect to. This argument is required.
`remote-program`
  Is the name of the executable program on the remote machine (including an optional path)
`program-parameters`
  are any parameters you want to pass to the executable program

The communications options for the `idebug` command are the same (and have the same defaults) as those for the `irmtdbg` command. Note that you do not specify a host name on the `irmtdbg` command because the remote machine initiates the connection.