- History starts when you turn it on. Lines written while hosted logs are off are never sent later.
- Your own log store comes first. While a log source of your own is connected to the cluster, log history searches that store instead.
- Live logs need none of this. Live reads the running containers through the cluster’s agent, with or without hosted logs.
Ankra turns hosted logs on platform by platform. Where they are not offered yet, you can still turn them on for a cluster, and nothing is sent until they are. The cluster’s settings and
ankra cluster logs-ship status say which applies to yours.Before you start
- The cluster’s agent must follow the switch. An agent that is too old, or that has log shipping turned off in its own Helm values (
logs_ship.enabled), sends nothing whatever the switch says. Upgrade it withankra cluster agent upgrade --cluster <cluster>, or turn on automatic agent upgrades in the cluster’s settings. - Your role needs
clusters.writeon the cluster. Anyone else is told which roles can turn hosted logs on. See Roles and access.
Turn it on from an application
1
Open the application's logs
In the new Ankra portal, open the application, choose Health, then Logs.
2
Choose History
When the cluster keeps no logs, History says so instead of showing an empty list: Ankra hosted logs are off for this cluster., or No log store is connected to this cluster.
3
Choose Turn on Ankra hosted logs
A dialog says what is sent, how long it is kept, that it is included during the pilot, and that lines written while it is off are never sent later.
4
Confirm
Choose Turn on hosted logs. History then reads Waiting for the first logs from <cluster>. and checks again every few seconds. The agent starts sending within a minute or two.
Turn it on from the cluster’s settings
In the new Ankra portal, open the cluster, choose Settings and find Ankra hosted logs. It says in one sentence whether the cluster sends its logs to Ankra, and when that was last changed. Choose Turn on hosted logs, read the dialog, and confirm with Turn on hosted logs. The same section turns hosted logs off: see Turn it off.Turn it on with the CLI
Check the cluster first:enable says what is sent and asks before it turns anything on. --yes answers the question for scripts.
What History tells you
When History has nothing to show, it says why, with the next step:Turn it off
In the cluster’s Settings, under Ankra hosted logs, choose Turn off hosted logs and confirm. With the CLI:Related
Logs
Stream live logs from any workload through the cluster’s agent.
Log sources
Connect Loki, Elasticsearch or OpenSearch instead.
Usage
The hosted logs bytes and lines Ankra accepted, per cluster and period.
Cluster settings
The agent version, automatic upgrades and other per-cluster settings.