While trying to update a couple of my ubuntu servers to use the new metrics agent, I’m getting the following errors without any helpful logs to see:

$ curl -sSL https://insights.nyc3.cdn.digitaloceanspaces.com/install.sh | sudo bash
Cleaning up old sources…OK
Verifying machine compatability…OK
Verifying compatability with script…OK
Reading package lists… Done
Building dependency tree

Reading state information… Done
E: Unable to locate package do-agent
Installing apt repository…
Installing gpg key…OK
Selecting previously unselected package do-agent.
(Reading database … 119526 files and directories currently installed.)
Preparing to unpack …/do-agent2.1.3amd64.deb …
Creating do-agent user…
Stopping systemctl service…
Unpacking do-agent (2.1.3) …
Setting up do-agent (2.1.3) …
Detecting SELinux
SELinux not enforced
Creating /etc/systemd/system/do-agent.service…
Created symlink /etc/systemd/system/multi-user.target.wants/do-agent.service, pointing to /etc/systemd/system/do-agent.service.
Failed to start do-agent.service: Unknown unit: do-agent.service
See system logs and ‘systemctl status do-agent.service’ for details.
dpkg: error processing package do-agent (–configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
do-agent
E: Sub-process /usr/bin/dpkg returned an error code (1)

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
9 answers

I had this issue too. By their command is show up error.

Same problem here! I can not update to the new metrics with the same error. Any update?

I don’t get anywhere with the command - there is no response from the terminal at all. Anyone from DO out there listening?

Eventually I got this:

“Failed to connect to repos.insights.digitalocean.com port 443: Connection timed out”

I got it too. No solution so far.

Detecting SELinux
SELinux not enforced
useradd: user ‘do-agent’ already exists
Creating /etc/systemd/system/do-agent.service…
Created symlink /etc/systemd/system/multi-user.target.wants/do-agent.service, pointing to /etc/systemd/system/do-agent.service.
Failed to start do-agent.service: Unknown unit: do-agent.service
See system logs and 'systemctl status do-agent.service’ for details.
dpkg: error processing package do-agent (–configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
do-agent
E: Sub-process /usr/bin/dpkg returned an error code (1)

facing same error, is there any solution for it ?

Same problem here. Was able to update my others Droplet but I have a problem with one

E: Sub-process /usr/bin/dpkg returned an error code (1)

@digitalocean can we have hint for that please ?

TLDR: do reboot your system!

I fixed this problem just restarting my droplet.
Had the same error during installing package do-agent on ubuntu 16.04

Attempt to get service status

sudo systemctl status do-agent

brings me to error

Failed to get properties: No such interface '' in Ubuntu 16.04.3 LTS

I’ve tried restart systemd, reinstall systemd, uninstall upstart and update do-agent.service configuraion, moreover I’ve looked into do-agent.deb and researched all containing scripts - nothing of above helped.

Hope this solution helps for somebody else

edited by MattIPv4
Submit an Answer