should not create /var/snap/telegraf/current

Bug #1962496 reported by Paul Collins
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Telegraf Charm
Confirmed
Undecided
Unassigned

Bug Description

If the snap is not already installed the charm can end up creating
/var/snap/telegraf/current as a directory. Then installing the snap yields:

ubuntu@juju-b22add-prod-assertions-sign-0:~$ sudo snap install --channel=stable --classic telegraf
error: cannot perform the following tasks:
- Copy snap "telegraf" data (failed to remove snap "telegraf" base directory: remove /var/snap/telegraf: directory not e
mpty)
- Make snap "telegraf" (405) available to the system (cannot cleanup failed attempt at making snap "telegraf" available
to the system: cannot remove snap current symlink: remove /var/snap/telegraf/current: directory not empty)
- Make snap "telegraf" (405) available to the system (symlink 405 /var/snap/telegraf/current: file exists)
ubuntu@juju-b22add-prod-assertions-sign-0:~$ ls -l /var/snap/telegraf/
total 4 drwxr-xr-x 3 root root 4096 Feb 28 22:09 current
ubuntu@juju-b22add-prod-assertions-sign-0:~$ ls -l /var/snap/telegraf/current/
total 4 drwxr-xr-x 2 root root 4096 Feb 28 22:09 telegraf.d

If /var/snap/telegraf/current does not exist, the charm should not create it.

Paul Collins (pjdc)
description: updated
Haw Loeung (hloeung)
Changed in charm-telegraf:
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.