Struggling to update or remove InfluxDB

Currently using Grafana, InfluxDB and Telegraf to collect, store and present monitoring data from across my home lab.

This specifically relates to running InfluxDB on my central monitoring host.

Having previously installed and configured InfluxDB and enjoyed it working, when I try and update it I am running into errors.

Having followed a number of guides to try and force remove the package, update it, force install the latest version etc I have decided to come to the elders for some advice or things to try.

Hopefully it's a simple fix but I've not found it yet - I am running Ubuntu 18.04.5 LTS

Anyway - when I run

sudo apt-get install influxdb

I get this

Reading package lists... Done
Building dependency tree
Reading state information... Done
influxdb is already the newest version (1.8.5-1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up influxdb (1.8.5-1) ...
Synchronizing state of influxdb.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable influxdb
Failed to enable unit: Unit file /etc/systemd/system/influxdb.service is masked.
dpkg: error processing package influxdb (--configure): installed influxdb package post-installation script subprocess returned error exit status 1
Errors were encountered while processing: influxdb
E: Sub-process /usr/bin/dpkg returned an error code (1)

I have backed up my config so any tips on force removing the package and allowing me to reinstall would be great. Thanks.

1

2 Answers

The error states that your influxdb service is masked (completely disabled). If there is not a reason to have this service disabled, you can unmask the service by running the following command:

sudo systemctl unmask influxdb

Then, you should be able to install successfully:

sudo apt update
sudo apt install --reinstall influxdb
1

To reinstall a package, run sudo apt-get install --reinstall influxdb

That way, your package will reinstall. It should also install it fully, if you do not turn off or stop the installation.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like