# Auto check plugin is failed

**URL:** https://community.traefik.io/t/auto-check-plugin-is-failed/6991
**Category:** Traefik v2
**Tags:** middleware, plugin
**Created:** [July 20, 2020, 7:20am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991 "2020-07-20T07:20:23Z")
**Posts on this page:** 17
**Page:** 1

<div class="post-metadata">

### Author: ![negasus](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/negasus/32/255_2.png) [@negasus](https://community.traefik.io/u/negasus)
#### Post date: [July 20, 2020, 7:20am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/1 "2020-07-20T07:20:23Z")

</div>

Hi there!

I made the plugin [GitHub - negasus/traefik-plugin-ip2location: traefik-plugin-ip2location](https://github.com/negasus/traefik-plugin-ip2location)

but Traefik Bot cannot run it with error

> failed to run with Yaegi: plugin: failed to create a new plugin instance: error open database file, open IP2LOCATION-LITE-DB1.IPV6.BIN: no such file or directory

External database file is needed for this plugin. And i place it to the repository. How can I fix this error?

PS: Maybe add `plugin` tag?

---

<div class="post-metadata">

### Author: ![ldez](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/ldez/32/5_2.png) [@ldez](https://community.traefik.io/u/ldez)
#### Post date: [July 20, 2020, 7:48am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/2 "2020-07-20T07:48:56Z")

</div>

Hello,

Have you try to run the plugin in Traefik with the dev mode?

- [https://github.com/containous/plugindemo#dev-mode](https://github.com/containous/plugindemo#dev-mode)

```auto
# static configuration
# ...

experimental:
  pilot:
    token: xxxxxxx

  devPlugin:
    goPath: /your/go/path/
    moduleName: github.com/negasus/traefik-plugin-ip2location

```

```auto
# dynamic configuration
http:
  routers:
    my-router:
      rule: hostregexp(`{host:.+}`)
      service: service-foo
      entryPoints:
        - web
      middlewares:
        - my-plugin

  services:
    service-foo:
      loadBalancer:
        servers:
          - url: http://127.0.0.1:5000

  middlewares:
    my-plugin:
      plugin:
        dev:
          fromHeader: 'X-Custom-IP'
          filename: 'IP2LOCATION-LITE-DB1.IPV6.BIN'
          headers:
            CountryShort: X-GEO-CountryShort
            CountryLong: X-GEO-CountryLong
            Region: X-GEO-Region
            City: X-GEO-City
            Isp: X-GEO-Isp
            Latitude: X-GEO-Latitude
            Longitude: X-GEO-Longitude
            Domain: X-GEO-Domain
            Zipcode: X-GEO-Zipcode
            Timezone: X-GEO-Timezone
            Netspeed: X-GEO-Netspeed
            Iddcode: X-GEO-Iddcode
            Areacode: X-GEO-Areacode
            Weatherstationcode: X-GEO-Weatherstationcode
            Weatherstationname: X-GEO-Weatherstationname
            Mcc: X-GEO-Mcc
            Mnc: X-GEO-Mnc
            Mobilebrand: X-GEO-Mobilebrand
            Elevation: X-GEO-Elevation
            Usagetype: X-GEO-Usagetype

```

---

<div class="post-metadata">

### Author: ![negasus](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/negasus/32/255_2.png) [@negasus](https://community.traefik.io/u/negasus)
#### Post date: [July 20, 2020, 8:00am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/3 "2020-07-20T08:00:05Z")

</div>

Locally the plugin works fine

PS: I set absolute path for the database file

---

<div class="post-metadata">

### Author: ![ldez](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/ldez/32/5_2.png) [@ldez](https://community.traefik.io/u/ldez)
#### Post date: [July 20, 2020, 8:11am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/4 "2020-07-20T08:11:39Z")

</div>

Have you try with your test data configuration?

```auto
INFO[2020-07-20T10:11:56+02:00] Starting provider *traefik.Provider {}       
ERRO[2020-07-20T10:11:57+02:00] error open database file, open IP2LOCATION-LITE-DB1.IPV6.BIN: no such file or directory routerName=my-router@file entryPointName=web
ERRO[2020-07-20T10:11:57+02:00] error open database file, open IP2LOCATION-LITE-DB1.IPV6.BIN: no such file or directory routerName=my-router@file entryPointName=web

```

---

<div class="post-metadata">

### Author: ![negasus](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/negasus/32/255_2.png) [@negasus](https://community.traefik.io/u/negasus)
#### Post date: [July 20, 2020, 8:15am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/5 "2020-07-20T08:15:05Z")

</div>

I don't know how to specify the path for the file. I can't specify an absolute path, like `/Users/negasus/plugin/database.bin`

---

<div class="post-metadata">

### Author: ![negasus](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/negasus/32/255_2.png) [@negasus](https://community.traefik.io/u/negasus)
#### Post date: [July 20, 2020, 8:16am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/6 "2020-07-20T08:16:15Z")

</div>

The plugin user must specify the path to the file he needs

---

<div class="post-metadata">

### Author: ![ldez](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/ldez/32/5_2.png) [@ldez](https://community.traefik.io/u/ldez)
#### Post date: [July 20, 2020, 8:57am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/7 "2020-07-20T08:57:47Z")

</div>

the main problem is the path to the file, for now I made some improvements on the plugin validation to skip this.

Could you try to close the issue: [https://github.com/negasus/traefik-plugin-ip2location/issues/1](https://github.com/negasus/traefik-plugin-ip2location/issues/1)

---

<div class="post-metadata">

### Author: ![negasus](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/negasus/32/255_2.png) [@negasus](https://community.traefik.io/u/negasus)
#### Post date: [July 20, 2020, 9:13am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/8 "2020-07-20T09:13:27Z")

</div>

I closed it. Should i receive email about succesfull plugin check?

---

<div class="post-metadata">

### Author: ![ldez](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/ldez/32/5_2.png) [@ldez](https://community.traefik.io/u/ldez)
#### Post date: [July 20, 2020, 9:17am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/9 "2020-07-20T09:17:02Z")

</div>

no but you will see your plugin here: [https://pilot.traefik.io/plugins](https://pilot.traefik.io/plugins)

We check the plugins every 30min: [https://github.com/containous/plugindemo#traefik-pilot](https://github.com/containous/plugindemo#traefik-pilot)

But I modified to 10min temporary.

---

<div class="post-metadata">

### Author: ![negasus](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/negasus/32/255_2.png) [@negasus](https://community.traefik.io/u/negasus)
#### Post date: [July 20, 2020, 9:20am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/10 "2020-07-20T09:20:14Z")

</div>

I still not received email (if fails) and not see my plugin in common list.  
Issue closing is works for new check?

---

<div class="post-metadata">

### Author: ![ldez](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/ldez/32/5_2.png) [@ldez](https://community.traefik.io/u/ldez)
#### Post date: [July 20, 2020, 9:20am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/11 "2020-07-20T09:20:59Z")

</div>

the check fail for the same thing, I will fix that.

---

<div class="post-metadata">

### Author: ![negasus](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/negasus/32/255_2.png) [@negasus](https://community.traefik.io/u/negasus)
#### Post date: [July 20, 2020, 9:21am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/12 "2020-07-20T09:21:32Z")

</div>

Yes, i got email right now

---

<div class="post-metadata">

### Author: ![ldez](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/ldez/32/5_2.png) [@ldez](https://community.traefik.io/u/ldez)
#### Post date: [July 20, 2020, 9:26am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/13 "2020-07-20T09:26:48Z")

</div>

you can close the new issue [https://github.com/negasus/traefik-plugin-ip2location/issues/2](https://github.com/negasus/traefik-plugin-ip2location/issues/2)

---

<div class="post-metadata">

### Author: ![negasus](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/negasus/32/255_2.png) [@negasus](https://community.traefik.io/u/negasus)
#### Post date: [July 20, 2020, 9:27am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/14 "2020-07-20T09:27:53Z")

</div>

done (some text for 20 symbols limit 🙂 )

---

<div class="post-metadata">

### Author: ![ldez](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/ldez/32/5_2.png) [@ldez](https://community.traefik.io/u/ldez)
#### Post date: [July 20, 2020, 9:30am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/15 "2020-07-20T09:30:42Z")

</div>

Success: [https://pilot.traefik.io/plugins/271558701445284371/ip2location-plugin](https://pilot.traefik.io/plugins/271558701445284371/ip2location-plugin)

---

<div class="post-metadata">

### Author: ![negasus](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/negasus/32/255_2.png) [@negasus](https://community.traefik.io/u/negasus)
#### Post date: [July 20, 2020, 9:34am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/16 "2020-07-20T09:34:05Z")

</div>

Great! Thanks) I has new achievement)

---

<div class="post-metadata">

### Author: ![jiangwennn](https://avatars.discourse-cdn.com/v4/letter/j/7ab992/32.png) [@jiangwennn](https://community.traefik.io/u/jiangwennn)
#### Post date: [December 23, 2022, 3:30am UTC](https://community.traefik.io/t/auto-check-plugin-is-failed/6991/17 "2022-12-23T03:30:24Z")

</div>

Hi, I was inspired by negasus/traefik-plugin-ip2location, and made a plugin [https://github.com/jiangwennn/traefik-plugin-ip2location-redirect](https://github.com/jiangwennn/traefik-plugin-ip2location-redirect)

Now I got the same issue here, could you please help me with this 😅

Thanks a lot ！
