Mantieni tutto organizzato con le raccolte
Salva e classifica i contenuti in base alle tue preferenze.
Segui questi passaggi per risolvere i vari problemi che possono verificarsi durante l'esecuzione di Kf.
Errori durante l'installazione di Kf
Errore del server (Richiesta non valida): carattere non valido
Se visualizzi questo errore durante l'impostazione dei valori predefiniti della configurazione, è probabile che il valore della variabile di ambiente ${DOMAIN} utilizzata nel comando includa un carattere "$" con codice di escape. Utilizza le virgolette singole per definire un dominio con un nome con spazi o un'altra sostituzione:
Error from server (BadRequest): invalid character '$' in string escape code
Errori con gli oggetti Kubernetes di Kf
Segui queste istruzioni per risolvere i problemi relativi agli oggetti Kubernetes di Kf.
Trova il nome del tipo di risorsa Kubernetes di cui vuoi risolvere il problema elencando tutte le risorse Kf:
Ottieni l'istanza della risorsa di cui vuoi risolvere i problemi utilizzando kubectl.
Se l'oggetto non si trova in uno spazio dei nomi, ometti il flag -n:
kubectl get apps.kf.dev my-app -n my-space -o yaml
Seleziona il tuo problema dalle schede di seguito:
L'oggetto non è in fase di riconciliazione
Controlla il valore di metadata.generation. Questo numero viene incrementato ogni volta che l'oggetto viene aggiornato. Se il numero è estremamente elevato, è probabile che due controller Kubernetes stiano litigando per l'oggetto. Controlla
il tuo cluster per verificare se all'oggetto vengono applicati criteri
che potrebbero modificarlo dallo stato desiderato.
Controlla se lo spazio dei nomi a cui appartiene l'oggetto è in fase di eliminazione. In questo caso, l'oggetto potrebbe non essere riconciliato.
Verifica che il campo status.observedGeneration esista. In caso contrario, il controller potrebbe non essere ancora stato eseguito sull'oggetto. Verifica
che il cluster e i controller siano in stato integro utilizzando kf doctor.
Verifica che il campo metadata.generation corrisponda al
status.observedGeneration. In caso contrario, verifica che il cluster e i controller siano operativi utilizzando kf doctor.
Controlla la presenza di errori nell'elenco status.conditions rispetto a questo elenco di
motivi di errore comuni:
NotOwned: nel cluster o nello spazio dei nomi esiste un'altra risorsa come quella che questo oggetto sta tentando di creare. Leggi il messaggio
per trovare il nome duplicato e rinomina la risorsa in conflitto
o l'oggetto Kf.
TemplateError: è presente una configurazione errata nella specifica della risorsa Kf o nella configurazione di Kf che causa la riconciliazione errata della risorsa secondaria. Convalida le impostazioni dell'oggetto Kf e dello spazio Kf.
CacheOutdated: il controller Kf non riceve aggiornamenti da Kubernetes abbastanza rapidamente. Controlla l'integrità del
cluster Kubernetes.
ReconciliationError: il controller Kf non riesce a creare la risorsa secondaria necessaria. Verifica che il cluster sia in stato di salute, che Kf sia in esecuzione e che non siano applicati criteri che impediscano a Kf di creare l'oggetto a cui fa riferimento il messaggio.
L'oggetto non viene eliminato
Verifica che metadata.deletionTimestamp dell'oggetto sia impostato. Se non è stato impostato, l'eliminazione richiesta non è andata a buon fine.
Verifica che il metadata.deletionTimestamp dell'oggetto sia nel passato. Se è nel futuro, l'oggetto potrebbe non essere eliminato.
Verifica se nell'oggetto esiste un elenco metadata.finalizers. Se sono presenti metodi di finalizzazione, l'oggetto deve attendere che vengano rimossi prima di essere eliminato. Se vuoi forzare un'eliminazione senza attendere i finalizer, modifica l'oggetto per rimuoverli.
Potrebbero essere presenti oggetti secondari che impediscono l'eliminazione dell'oggetto. Chiedi a un amministratore di controllare tutti gli oggetti nello spazio dei nomi e nel
cluster per verificare se uno di questi deve prima essere eliminato manualmente.
[[["Facile da capire","easyToUnderstand","thumb-up"],["Il problema è stato risolto","solvedMyProblem","thumb-up"],["Altra","otherUp","thumb-up"]],[["Difficile da capire","hardToUnderstand","thumb-down"],["Informazioni o codice di esempio errati","incorrectInformationOrSampleCode","thumb-down"],["Mancano le informazioni o gli esempi di cui ho bisogno","missingTheInformationSamplesINeed","thumb-down"],["Problema di traduzione","translationIssue","thumb-down"],["Altra","otherDown","thumb-down"]],["Ultimo aggiornamento 2025-09-04 UTC."],[],[],null,["# Troubleshoot Kf\n\nUse these steps to troubleshoot various issues that can occur when running Kf.\n\n\u003cbr /\u003e\n\nFailures when installing Kf\n---------------------------\n\n### Error from server (Bad Request): Invalid character\n\nIf you see this error when setting config defaults, it is likely the value of the `${DOMAIN}` env var used in the command includes an escaped '$'. Use single quotes to define a domain with a space name or other substitution: \n\n Error from server (BadRequest): invalid character '$' in string escape code\n\nErrors with Kf Kubernetes objects\n---------------------------------\n\nFollow these instructions to troubleshoot Kf Kubernetes\nobjects.\n\n1. Find the name of the Kubernetes resource type you want to troubleshoot by\n listing all Kf resources:\n\n kubectl api-resources --api-group=kf.dev\n\n Example output: \n\n NAME SHORTNAMES APIGROUP NAMESPACED KIND\n apps kf.dev true App\n builds kf.dev true Build\n clusterservicebrokers kf.dev false ClusterServiceBroker\n routes kf.dev true Route\n servicebrokers kf.dev true ServiceBroker\n serviceinstancebindings kf.dev true ServiceInstanceBinding\n serviceinstances kf.dev true ServiceInstance\n spaces kf.dev false Space\n\n2. Get the instance of the resource you want to troubleshoot using `kubectl`.\n If the object isn't in a namespace, omit the `-n` flag:\n\n kubectl get \u003cvar translate=\"no\"\u003eapi-resource-name\u003c/var\u003e.kf.dev \u003cvar translate=\"no\"\u003eobject-name\u003c/var\u003e -n \u003cvar translate=\"no\"\u003espace-name\u003c/var\u003e -o yaml\n\n For example: \n\n kubectl get apps.kf.dev my-app -n my-space -o yaml\n\n3. Select your problem from the tabs below:\n\n ### Object isn't reconciling\n\n 1. Check the value of `metadata.generation`. This number is incremented each time the object is updated. If the number is extremely high it's likely two Kubernetes controllers are fighting over the object. Check your cluster to see if any policies are being applied to the object which might be changing it from the desired state.\n 2. Check to see if the namespace the object belongs to is deleting. If it is, the object may not be reconciled.\n 3. Check that the `status.observedGeneration` field exists. If it doesn't, the controller might not have executed against the object yet. Validate that the cluster and controllers are healthy using `kf doctor`.\n 4. Check that the `metadata.generation` field matches the `status.observedGeneration` field. If it doesn't, validate that the cluster and controllers are healthy using `kf doctor`.\n 5. Check for failures in the `status.conditions` list against this list of common error reasons:\n\n - `NotOwned`: There is another resource that exists in the cluster or namespace as the one this object is trying to create. Read the message to find the duplicate name and either rename the conflicting resource or the Kf object.\n - `TemplateError`: There is a misconfiguration in the Kf resource spec or Kf configuration causing the child resource to be incorrectly reconciled. Validate the settings of the Kf object and the Kf space.\n - `CacheOutdated`: The Kf controller isn't receiving updates from Kubernetes fast enough. Check the health of the Kubernetes cluster.\n - `ReconciliationError`: The Kf controller can't create the necessary child resource. Check to make sure your cluster is healthy, Kf is running, and that there are no policies being enforced that are preventing Kf from creating the object referenced in the message.\n\n ### Object isn't deleting\n\n 1. Check that the `metadata.deletionTimestamp` of the object was set. If it wasn't set, then the requested deletion didn't work.\n 2. Check that the `metadata.deletionTimestamp` of the object is in the past. If it's in the future, the object may not delete.\n 3. Check if a `metadata.finalizers` list exists on the object. If finalizers are present, the object must wait for them to be removed before it is deleted. If you want to force a deletion without waiting for the finalizers, edit the object to remove them.\n 4. Child objects may exist that are preventing the object from being deleted. Have an administrator check all objects in the namespace and cluster to see if one of them needs to be manually deleted first."]]