Question: Is there a way (plugin or tool) to export the data from the database (or database itself) ? I'm looking for this feature as I need to migrate a DB from present host to another one.

Answer: 
You could dump each table and load them through REST interface:

```
curl "http://hosta:8086/db/dbname/series?u=root&p=root&q=select%20*%20from%20series_name%3B" > series_name.json
curl -XPOST -d @series_name.json "http://hostb:8086/db/dbname/series?u=root&p=root"

```

Or, maybe you want to add new host to cluster? It's easy and you'll get master-master replica for free. [Cluster Setup](http://influxdb.com/docs/v0.8/clustering/setup.html)
From `1.5` onwards, the InfluxDB OSS backup utility provides a newer option which is much more convenient:

`-portable`: Generates backup files in the newer InfluxDB Enterprise-compatible format. Highly recommended for all InfluxDB OSS users

> 
> Export
> 
> 
> 

To back up everything:

```
influxd backup -portable <path-to-backup>

```

To backup only the myperf database:

```
influxd backup -portable -database myperf <path-to-backup>

```

> 
> Import
> 
> 
> 

To restore all databases found within the backup directory:

```
influxd restore -portable <path-to-backup>

```

To restore only the myperf database (myperf database must not exist):

```
influxd restore -portable -db myperf <path-to-backup>

```

Additional options include specifying `timestamp` , `shard` etc. See all the other supported options [here](https://docs.influxdata.com/influxdb/v1.7/administration/backup_and_restore/).