Agent Configuration
A reference for the configuration file, CLI options, and file locations used by both TFE variants.
1. TFE Local Directory — tfe-config.yaml
Location: /etc/takakrypt/fte/tfe-config.yaml. It's readable only by root, and it's the only configuration file that isn't encrypted.
environment: prod
gateway:
agent_id: ""
access_token: "<api-key>"
user_key: "uk_..."
tenant: "default"
endpoint: "https://<gateway-domain>"
pull_interval: "5m"
ldt:
max_workers: 2
rate_limit_mbps: 10
max_queue_size: 100
scan_interval: "1h"
auto_migrate: true
sync_block_interval: 100
qos:
cpu_percent: 0
cap_cpu: false
iowait_ms: 0
schedule: "anytime"
encryption:
mode: "aes-cbc-cs1"
metrics:
enabled: true
port: 9090
audit:
enabled: true
path: "/var/log/takakrypt-audit.log"
max_size_mb: 0
max_backups: 0
An unrecognized setting isn't an error. The agent logs "ignoring ... setting(s) this build does not read" and keeps running with the settings it does understand.
encryption.mode only accepts aes-cbc-cs1 for TFE Local Directory. Setting it to aes-gcm here is rejected and the agent refuses to start. (TFE Object Storage is different: it switches to aes-gcm automatically for large files, as a storage-level detail you don't configure, see Encryption Method by File Size below.)
CLI flags always override the values in this file. This is also why the default systemd service runs without extra flags, so that this file remains the single source of truth.
Setting ldt.rate_limit_mbps disables qos.cpu_percent and qos.iowait_ms. Rate limiting and CPU/I-O-wait-based throttling are two different approaches, and mixing them doesn't make sense.
LDT Tuning Guide
| Scenario | Workers | Rate limit | Scan interval |
|---|---|---|---|
| Production: minimal impact | 1 | 5–10 Mbps | 2 hours |
| Production: balanced | 2 | 10–20 Mbps | 1 hour |
| Development: fast | 2–4 | 20–50 Mbps | 30 minutes |
| Limited server resources | 1 | 5 Mbps | 4 hours |
2. TFE Object Storage — fos-config.yaml
Location: /etc/takakrypt/fos/fos-config.yaml.
environment: prod
gateway:
agent_id: ""
access_token: "<api-key>"
user_key: "uk_..."
tenant: "default"
endpoint: "https://<gateway-domain>"
pull_interval: "5m"
encryption:
mode: "aes-cbc-cs1"
s3proxy:
enabled: true
listen_addr: "127.0.0.1:9000"
client_access_key: ""
client_secret_key: ""
allow_anonymous: false
# tls_cert_file: "" # agent 0.2.7+, required if listen_addr isn't 127.0.0.1
# tls_key_file: "" # agent 0.2.7+, required if listen_addr isn't 127.0.0.1
guard_point_id: "gp-default"
backend:
type: "local" # local | minio | s3
endpoint: "http://minio:9000"
region: "us-east-1"
access_key: ""
secret_key: ""
use_ssl: false
use_path_style: true # must be true for MinIO
local_path: "/var/lib/takakrypt/fos/storage" # only used when type is local
metrics:
enabled: true
port: 9091
- The
backendsection (object storage type, endpoint, access key, secret key) is normally filled in automatically from the dashboard, not edited by hand. - If
fos-config.yamlis missing, the agent falls back to readingtfe-config.yamlin the same folder. That's legacy behavior, so don't rely on it. Keepfos-config.yamlpresent. - TFE Object Storage's metrics port (9091) differs from TFE Local Directory's (9090), so both can run on the same server without conflict.
s3proxy.encrypt_patterns and s3proxy.passthrough_patterns are accepted by the file format but never take effect. Only the policy configured in the dashboard controls whether a bucket is encrypted.
Encryption Method by File Size
| File size | Method |
|---|---|
| ≤10 MB | aes-cbc-cs1 |
| >10 MB | aes-gcm (selected automatically) |
Encryption Metadata Stored per File
Each stored file carries metadata with the x-takakrypt- prefix: x-takakrypt-encrypted, x-takakrypt-cipher-mode, x-takakrypt-guard-point, x-takakrypt-original-size, x-takakrypt-base-iv.
If this metadata is lost (say, a copy tool strips custom metadata), the file cannot be recovered by any means.
Supported Operations
| Category | Operations |
|---|---|
| Bucket | list, list-contents, create, delete, check |
| File | store, retrieve, check, delete, copy, bulk-delete |
| Multipart upload | start, upload-part, complete, abort, list |
Applications must use AWS Signature V4. Presigned URLs are not supported.
3. CLI Options
| Option | Default | Notes |
|---|---|---|
--config | /etc/takakrypt/fte (or /etc/takakrypt/fos) | Configuration folder location |
--log-level | info | Log detail level |
--log-file | /var/log/takakrypt-fte.log (or -fos.log) | Log file location |
--env | detected automatically | Running environment |
--metrics-addr | local address only | Monitoring data access address |
--sync-once | — | Synchronize with the gateway once, then exit |
--enable-pprof | off | Performance profiling, off by default |
--require-binary-signatures | off | Requires the agent binary to be digitally signed |
--access-token, --user-key | — | Do not use. Values passed this way are visible to all local users via ps or /proc/PID/cmdline, and cannot be hidden again except by rotating the credentials |
For host-specific settings, use sudo systemctl edit takakrypt-fte (or takakrypt-fos) to create a drop-in file. Never edit the default service file directly, since changes to it are lost when the agent package is updated.
4. Agent File Locations (TFE Local Directory)
/etc/takakrypt/fte/
├── tfe-config.yaml
├── host-settings.conf
└── .sec/
├── conf/secfs.key
├── conf/machine-sources
├── conf/agent-config.po
├── conf/<guard points>.po
├── keys/agent-keypair.key
├── keys/dek-cache.key
├── policies/<ID>.po
└── agent-id
/var/lib/takakrypt/fte/metadata/migrating/
/var/run/takakrypt-fte.sock
Copying the .sec/ folder to another server won't work. The master key is derived from the server's hardware identity, and it's never stored anywhere. The agent recalculates it on every start. A reprovisioned server or one with replaced hardware has to re-enroll as a new agent.
5. Log and Monitoring Locations (TFE Object Storage)
| Source | Location |
|---|---|
| Monitoring metrics | http://localhost:9091/metrics |
| Service log | sudo journalctl -u takakrypt-fos |
| Log file | /var/log/takakrypt-fos.log |
| Audit log | /var/log/takakrypt-audit.log (shared with TFE Local Directory if both are installed on the same server) |
If the agent doesn't behave as expected after you've configured it, check Installation Troubleshooting.