---
name: "rancid.types.conf"
section: "5"
platform: "linux"
package: "rancid"
version: "3.14-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/rancid.types.conf"
---

# rancid.types.conf(5)

rancid device type configuration file

## NAME

rancid.types.conf - rancid device type configuration file

## DESCRIPTION

**rancid.types.conf** contains formatted configuration lines that define the device types that are available for use in the \<device\_type\> field of the [**router.db**(5)](/router.db/5.md) configuration file.

The **rancid.types.base** configuration file follows the same format, but defines the base types described in *[router.db(5)](/router.db/5.md).*

Users are **STRONGLY** discouraged from altering this file or overriding the base types in **rancid.types.conf.** Instead, copy the type definition to be altered from **rancid.types.base** to **rancid.types.conf** using a different \<device\_type\>.

## SYNTAX

One directive is listed per-line, where the syntax is one of:

```
<device_type>;alias;<alternate_device_type>
<device_type>;command;<filter_function>;<device_command_string>
<device_type>;inloop;<input_loop_function>
<device_type>;login;<login_program>
<device_type>;module;<perl_module_name>
<device_type>;prescript;<rancid_script> XXX temporary knob?  add this?
<device_type>;postscript;<rancid_script> XXX temporary knob?  add this?
<device_type>;script;<rancid_script>
<device_type>;timeout;<login_program_timeout>
```

For example:

```
cisco;login;clogin
cisco;timeout;120
cisco;module;rancid::ios
cisco;inloop;ios::inloop
cisco;command;ShowVersion;show version
juniper;login;/usr/local/bin/jlogin
juniper;module;rancid::junos
juniper;inloop;junos::inloop
juniper;command;ShowVersion;show version
srx;alias;juniper
```

\<device\_type\> is a lower case name used in the *[router.db(5)](/router.db/5.md)* file. Its case is forced to lower case when reading the configuration files.

Each \<device\_type\> may have the following directives defined. The login and script directives are required, unless it is an alias.

- **alias**

  Defines an alias for another \<device\_type\>, it does NOT augment it. The \<device\_type\> target may be defined in either device type configuration file.

- **command**

  Defines commands to run for the \<device\_type\> and the function that will process the input.

- **inloop**

  Intended for *[rancid(1)](/rancid/1.md),* **inloop** defines a function to loop over the input from the device. It must have the calling signature f($INPUT, $OUTPUT).

- **login**

  Defines the login script used for the \<device\_type\>, which does not need to be an FQPN, but then must be found in the path.

- **module**

  Loads a rancid perl module to supply functions used in the **command** directives for the \<device\_type\>. Multiple module lines may exist for a device type, they are loaded in the order they appear.

- **script**

  Defines the rancid script used for the \<device\_type\>, which does not need to be an FQPN, but then must be found in the process' path.

- **timeout**

  Defines the rancid login script timeout in seconds. In general, the default 90 seconds, but some modules themselves alter this.

## FILES

- **/etc/rancid/rancid.types.conf**

  Configuration file described here.

- **/etc/rancid/rancid.types.base**

  Configuration file described here.

## SEE ALSO

[**control\_rancid**(1)](/control_rancid/1.md), [**rancid**(1)](/rancid/1.md), [**rancid-run**(1)](/rancid-run/1.md), [**router.db**(5)](/router.db/5.md), [**rancid**(3)](/rancid/3.md)
