Project

General

Profile

Bug #5462

Relay servers keeps sending inventories of their managed nodes at every run

Added by Lionel Le Folgoc almost 6 years ago. Updated over 5 years ago.

Status:
Released
Priority:
1
Category:
Server components
Target version:
Severity:
User visibility:
Effort required:
Priority:

Description

Hi,

I'm testing node deletion as described in my previous bug report. Some deleted nodes keep coming back as pending for approval, probably because some files are remaining on the ldap/relaytop (they are not real nodes, so they can't submit new inventories).
When I reject them, they're back 5 minutes later (next cf-agent run)... :(

Any chance the node deletion could also trigger the purge of the corresponding inventory files on ldap/relays? Otherwise, there's no clear way to reject a current inventory with certainty (with real nodes, they'll resubmit possibly updated inventories the next day, so it's fine).

Thanks.


Related issues

Related to Rudder - Bug #4709: When a node is deleted, its generated promises are not removedReleasedBenoît PECCATTEActions
#1

Updated by Nicolas CHARLES over 5 years ago

  • Target version set to 2.10.6

Hi Lionel,

Thank you for the feedback. It does look like http://www.rudder-project.org/redmine/issues/4709
If we purge the promises, then the agent will fetch empty promises, and do nothing.

#2

Updated by Matthieu CERDA over 5 years ago

  • Target version changed from 2.10.6 to 2.10.7
#3

Updated by Nicolas CHARLES over 5 years ago

ha, actually, when a node is removed, they can't download anything anymore from the policy server ...

#4

Updated by Lionel Le Folgoc over 5 years ago

As discussed yesterday with Benoît, I think this is caused by a missing folder on the relaytop server (https://github.com/Normation/rudder-tools/blob/master/scripts/rudder-multiserver-setup/rudder-relay-top.sh#L34). The "received" folder is not created, so accepted inventories are not moved, which could explain why a removed system is readded (waiting for acceptance) immediately.

#5

Updated by François ARMAND over 5 years ago

Ho, thank you for pinning it down!

Have you tried to create the missing directories to see if the behaviour become ok ? "inventories" directory should contain the following sub-directories:
- accepted-nodes-updates
- debug
- failed
- historical
- incoming
- received

(well debug is not mandatory).
Could you create all of them and try to delete again node ?

Thanks !

#6

Updated by Vincent MEMBRÉ over 5 years ago

  • Category set to Server components
  • Status changed from New to 8
  • Assignee set to Matthieu CERDA
  • Priority changed from N/A to 1
  • Target version changed from 2.10.7 to 2.11.4

This is due to an error occuring in /var/rudder/tools/send-clean.sh

Directory /var/rudder/inventories/{received,failed) does not exist, so when send-clean success or fail, the files are not moved into those directories and stay in incoming/node-update dirrecoty

so even if the inventory was correctly sent, it will be sent again in the next 5 minutes

send-clean.sh should create the missing directories.

Matthieu can you look into this please ??

This in only happening on rudder-relay-top, 'normal' relays use curl to send inventory, not use send-clean.sh

#7

Updated by Matthieu CERDA over 5 years ago

  • Status changed from 8 to Pending technical review
  • Assignee changed from Matthieu CERDA to Jonathan CLARKE
  • Target version changed from 2.11.4 to 2.10.7
  • % Done changed from 0 to 100
  • Pull Request set to https://github.com/Normation/rudder-techniques/pull/547
#8

Updated by Matthieu CERDA over 5 years ago

  • Status changed from Pending technical review to Pending release

Applied in changeset policy-templates:commit:61f8944b8d0cfee340d173730bbbe44bd439a10b.

#9

Updated by Vincent MEMBRÉ over 5 years ago

  • Subject changed from Deleted nodes come back as pending to Relay servers keeps sending inventories of their managed nodes even if the node is deleted/does not exists anymore
#10

Updated by Vincent MEMBRÉ over 5 years ago

  • Subject changed from Relay servers keeps sending inventories of their managed nodes even if the node is deleted/does not exists anymore to Relay servers keeps sending inventories of their managed nodes at every run
#11

Updated by Vincent MEMBRÉ over 5 years ago

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 2.10.7 and 2.11.4, which were released today.

Also available in: Atom PDF