Skip to content

Krill cannot remove child if child-parent handshake was never completed #1330

@Koenvh1

Description

@Koenvh1

If a parent adds a child (e.g. krillc children add --ca testbed --child koen --request test-request.xml --ipv6 2001:db8::/32) and then tries to remove it (e.g. krillc children remove --ca testbed --child koen), it returns an error:

Error response from URI: https://localhost:3000/api/v1/cas/testbed/children/koen, Status: 400 Bad Request, ErrorResponse: {"label":"sys-kv","msg":"Key/Value error: Store error: failed to delete file '/var/lib/krill/data/status/testbed/children-koen.json': No such file or directory (os error 2)","args":{"cause":"Store error: failed to delete file '/var/lib/krill/data/status/testbed/children-koen.json': No such file or directory (os error 2)"}}

Adding it again is not possible either:

Error response from URI: https://localhost:3000/api/v1/cas/testbed/children, Status: 400 Bad Request, ErrorResponse: {"label":"ca-child-duplicate","msg":"CA 'testbed' already has a child named 'koen'","args":{"child":"koen","ca":"testbed"}}

Updating works just fine.

This only happens when the child did not complete the handshake, i.e. added the parent's response. If the child does complete it, the file will exist, and deleting works just fine.

(relates to #1191 (comment))

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions