---
name: "minicoredumper.cfg.json"
section: "5"
platform: "linux"
package: "minicoredumper"
version: "2.0.7-4"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/minicoredumper.cfg.json"
---

# minicoredumper.cfg.json(5)

the main configuration file for minicoredumper(1)

## NAME

minicoredumper.cfg.json - the main configuration file for [**minicoredumper**(1)](/minicoredumper/1.md)

## DESCRIPTION

**minicoredumper.cfg.json** is the main configuration file for [**minicoredumper**(1)](/minicoredumper/1.md). It serves 2 purposes:

- 1\.

  define where dumped files should be located

- 2\.

  specify various [**minicoredumper**(1)](/minicoredumper/1.md) recepts for various conditions

## FILE FORMAT

The file uses the JSON format. The options are:

- **base\_dir**

  (string) The root directory where the dumped data will be stored. The dump files will be stored in a sub-directory using the template:\
   \<command\_basename\>.\<timestamp\>.\<pid\>

- **watch**

  (array) A set of conditions, where each condition can specify its own recept file. See **CONDITIONS** for configuration options for a condition.

## CONDITIONS

A condition can contain any combination of these options:

- **exe**

  (string) The full path to the binary being executed as returned by [**readlink**(2)](/readlink/2.md).

- **comm**

  (string) The basename of the command that was run (the 7th argument of the [**minicoredumper**(1)](/minicoredumper/1.md) call).

- **recept**

  (string) The full path to the recept file to use if this condition matches.

Both *exe* and *comm* can contain the \* character for wildcard matching.

The conditions are checked to find a match in the order specified. The first match will cause the minicoredumper to use the recept for that condition. If no conditions match, the minicoredumper will exit and no [**core**(5)](/core/5.md) dump will be generated.

If *exe* and/or *comm* are not specified for a condition, they will use a default value "\*".

If *recept* is not specified for a condition, the built-in minicoredumper defaults are used.

*exe* and *comm* have a "logical AND" relationship. A "logical OR" behavior can be achieved by specifying one condition with only *exe* and another condition with only *comm*.

## NOTES

The exact path where data is dumped is logged to [**syslog**(3)](/syslog/3.md).

If an 8th argument of [**minicoredumper**(1)](/minicoredumper/1.md) is provided, the name and location of this file will depend on that value.

## EXAMPLES

Here is an example configuration file:

```
{
    "base_dir": "/tmp",
    "watch": [
        {
            "exe": "*/my_example_app",
            "recept": "/etc/minicoredumper/example.recept.json"
        },
        {
            "comm": "example_app"
            "recept": "/etc/minicoredumper/example.recept.json"
        },
        {
            "exe": "/bin/*"
        },
        {
            "recept": "/etc/minicoredumper/generic.recept.json"
        }
    ]
}
```

In this example, dumped data will be stored in a directory named:\

/tmp/\<command\_basename\>.\<timestamp\>.\<pid\>

For example, if there is a symbolic link:

/usr/bin/example\_app -\> /opt/my\_apps/bin/my\_example\_app

and the user runs "example\_app" and it crashes, the newly created files could be found here:\

/tmp/example\_app.20151103.114054+0100.15143

The example above contains 4 conditions that will be checked in order.

The first condition will match if the binary "\*/my\_example\_app" caused the core dump. It will use the recept file:\

/etc/minicoredumper/example.recept.json

The second condition will match if the basename of the command is "example\_app". It will also use the recept file:\

/etc/minicoredumper/example.recept.json

The third condition will match for any binaries under "/bin/\*". It will use the built-in [**minicoredumper**(1)](/minicoredumper/1.md) defaults.

The fourth condition will match everything. It will use the recept file:\

/etc/minicoredumper/generic.recept.json

In the example where the user runs "example\_app", the first condition will match since example\_app is a symbolic link to /opt/my\_apps/bin/my\_example\_app.

A minimal (yet still useful) configuration file could look like this:

```
{
    "base_dir": "/tmp",
    "watch": [
        {
            "exe": "*"
        }
    ]
}
```

## FILES

/etc/minicoredumper/minicoredumper.cfg.json

## SEE ALSO

[**minicoredumper**(1)](/minicoredumper/1.md), [**libminicoredumper**(7)](/libminicoredumper/7.md), [**minicoredumper.recept.json**(5)](/minicoredumper.recept.json/5.md)

The DiaMon Workgroup: \<http://www.diamon.org\>
