6

I am storing the data in the influx to create a dashboard with grafana.

But my influx database is getting crashed after 1 day due to large amount of data ingestion in influx.

No my centos file system(memory) got full. I am not able to restart the influx also.

I want to delete all the data that has been stored by influx to free up the space in centos.

I have deleted the below directories:

/var/lib/influxdb/data
/var/lib/influxdb/wal
/var/lib/influxdb/meta

Didn't find any proper documentation on internet to uninstall influx db.

Can anyone provide the details to uninstall influx db with all its data.

Vishal
  • 127
  • 1
  • 2
  • 16
  • 1
    How did you install it in the first place? If you installed it from a package (i.e., using `yum install`), then you can remove it the same way (`yum remove`). If you installed it from source, then removing it is entirely up to you. In either case, removing the data will probably be a manual step. – larsks Dec 15 '17 at 16:28
  • I have installed it using the sudo rpm -ivh influxdb-0.9.4_rc1-1.x86_64.rpm command – Vishal Dec 15 '17 at 19:15
  • 1
    So you can remove it with `yum remove influxdb`, or `rpm -e influxdb`, although you should in general not be using `rpm` by itself to install/remove packages (it won't hurt in this case). You will still probably need to remove any data yourself, although by removing `/var/lib/influxdb` you've probably taken care of that already. – larsks Dec 15 '17 at 19:21
  • Thanks i was able to uninstall using your command. – Vishal Dec 21 '17 at 13:53
  • 1
    I did install using 'sudo dpkg -i influxdb_1.7.9_amd64.deb' , wondering how to completely uninstall or remove it? – Ammad Aug 03 '22 at 20:36

2 Answers2

8
sudo apt-get purge --auto-remove influxdb  
4b0
  • 21,981
  • 30
  • 95
  • 142
ryan92
  • 81
  • 1
  • 2
0

Do the following in order:

pkill -f influx   [To kill any running influx Process]
sudo apt-get purge --auto-remove influxdb  [Remove all the files, data files generally stays]
go to /var/lib/influxdb/data directory and issue command rm -rf * command. 
Ammad
  • 4,031
  • 12
  • 39
  • 62