I’m new to Kopia, so please pardon my lack of knowledge as I’m just starting to explore and test it. I must say, it’s an impressive tool. My intention is to run Kopia in server mode within our Kubernetes environment, and I’ve created a Helm chart using the official Docker image, which seems to be working well.
I’ve also added a few of our clients using the following commands, and that seems to be working fine too, as it successfully created snapshots in our self-hosted MinIO.
I have updated the global policy on the server to meet my requirements, and the snapshot schedule works fine when I create it for the local node (kopia server node). However, the schedule doesn’t seem to work for the clients as seen in the below image.
The only way to create a snapshot for the clients (remote nodes) is by running the kopia snapshot create command on the them. Is this intended behavior? If so, are there any ways to manage the snapshot schedule for clients directly from the server UI? Thanks
I went through some previous posts, and it seems that scheduling and policy management need to be configured and managed from the clients themselves, without an option to centralize this from the server. This seems a bit odd.
I attempted to create a policy with a cron schedule from the client using the following command:
kopia policy set --compression=pgzip --snapshot-time-crontab="0 * * * *" /opt/osquery
The command worked, and I assume this should create a policy with a cron schedule to take snapshots for /opt/osquery. However, while the policy gets added, the snapshots don’t seem to be created automatically via cron. The only way to create a snapshot is by manually issuing the kopia snapshot create /opt/osquery command from the CLI, which seems unusual. As I’m a beginner, I might have missed some steps. I would appreciate it if someone could shed some light on this. Thanks in advance
Thanks so much for the response, @kapitainsky. Does this mean that the CLI doesn’t honor the policies at all and functions like an on-demand snapshot without options to specify features like compression?
I don’t have the Kopia UI available on the clients. Are there any methods by which I can add a policy and schedule for the clients from the Kopia server?
What would you recommend in this case? I can always go with a cron job approach and have a cron schedule to trigger kopia snapshot create /opt/osquery command at the desired intervals, but I need features like encryption, compression, etc. Is there a way to have a minimal UI on the clients that can be used just to create schedules, while we monitor the rest from the server? Thanks!
Policies are not stored on any server but in repositories - so you can add them from any computer with access to this repo. You have to make sure that you apply them for specific user/host - see docs:
target Select a particular policy (‘user@host’,’@host’,‘user@host:path’ or a local path). Use –global to target the global policy.
all features will work - only what you have to do is to trigger snapshot manually (or via cron/systemd)
I have never needed it so not sure but I remember people talking about it on the forum. I think you have to run kopia server on your headless machine and then you can access it via web browser.