# Unable to Start pf9-kube Service Due to Package Hold

## Problem

The ***pf9-kube*** service does not start on one of the nodes due to hold present on the *docker-ce* package with the following errors observed in the *nodelet* and *kube* logs.

{% tabs %}
{% tab title="None" %}

```none
pf9@host:/var/log/pf9$ less nodelet.log
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
docker-ce*
The following held packages will be changed:
docker-ce
0 upgraded, 0 newly installed, 1 to remove and 1 not upgraded.

E: Held packages were changed and -y was used without --allow-change-held-packages.
" func=main.startKubeService file="/pf9/nodelet/nodeletd.go:210"time="XXXX-XX-XXTXX:XX:XX-XX:XX" level=warning msg="Trying to start pf9-kube 66. Failed task on the last run was: Configure Docker" func=main.writeExtensionData file="/pf9/nodelet/nodeletd.go:261"time="XXXX-XX-XXTXX:XX:XX-XX:XX" level=warning msg="pf9-kube restarted due to failure of status check: Check if start operation in progress" func=main.writeExtensionData file="/pf9/nodelet/nodeletd.go:269"
```

{% endtab %}
{% endtabs %}

{% tabs %}
{% tab title="None" %}

```none
pf9@host:/var/log/pf9/kube$ less kube.log
The following packages have unmet dependencies:
docker-ce : Depends: docker-ce-cli but it is not going to be installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
```

{% endtab %}
{% endtabs %}

## Environment

* Platform9 Managed Kubernetes - All Versions
* Docker

## Cause

1. Hold is present on the packages and can be verified using the following command.

{% tabs %}
{% tab title="None" %}

```none
pf9@host:/var/log/pf9$ apt-mark showhold
docker-ce
docker-ce-cli
```

{% endtab %}
{% endtabs %}

## Resolution

1. Remove the hold on the packages.

{% tabs %}
{% tab title="None" %}

```none
$ apt-mark unhold [PackageName]
```

{% endtab %}
{% endtabs %}

2. Once the hold is removed, the ***pf9-kube*** service starts successfully.

{% tabs %}
{% tab title="None" %}

```none
pf9@host:/var/log/pf9$ less nodelet.log
time="XXXX-XX-XXTXX:XX:XX-XX:XX" level=info msg="pf9-kube is already running..." func=main.handleKubeServiceStartState file="/pf9/nodelet/nodeletd.go:341"
time="XXXX-XX-XXTXX:XX:XX-XX:XX" level=info msg="Expected service state: &{ClusterRole:master ClusterID:UUID ServiceState:true}" func=main.handleExpectedServiceState file="/pf9/nodelet/nodeletd.go:172"
time="XXXX-XX-XXTXX:XX:XX-XX:XX" level=info msg="pf9-kube is already running..." func=main.handleKubeServiceStartState file="/pf9/nodelet/nodeletd.go:341"
time="XXXX-XX-XXTXX:XX:XX-XX:XX" level=info msg="Expected service state: &{ClusterRole:master ClusterID:UUID ServiceState:true}" func=main.handleExpectedServiceState file="/pf9/nodelet/nodeletd.go:172"
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://platform9.com/kb/pmk/solutions/unable-to-start-pf9-kube-service-due-to-package-hold.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
