-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docker driver: Persistent Volume data not restored after minikube new start #8458
Comments
The issue may be related to #7828 |
@dpolivaev do you mind sharing what addons do u have enabled? minikube addons list |
@afbjorklund could this be something about storage provisioner? |
|
I think it is more related to #8151, and storing the PV on tmpfs ? |
Looks you are right. The missing data is placed in directories under |
https://minikube.sigs.k8s.io/docs/handbook/persistent_volumes/ says them to be persisted |
Probably because it didn't default to the "docker" driver ? I don't think this has changed in KIC |
Unfortunately that only applies to the VM, it is not valid for the "none" driver or the "docker" driver. |
Sorry, I have not got it. |
An alternative solution is #7511, where the mount point is moved to the (persisted) |
Hmm, maybe that is the problem here then: 😄 minikube v1.11.0 on Ubuntu 18.04 You need to add But the volumes should be persisted also on the container-based version (KIC) of minikube. |
Anyway my intended use case is running minikube on AWS with |
Minikube v1.8.2 uses virtualbox driver by default. I would appreciate if you tell me what happens with --driver=none. |
I confirm that using |
thanks for confriming I will add this bug to v1.13.0 milestone, I am looking for help for this issue, if you are an expert in storage and mounts specailly for docker driver your help is wanted. |
You will have to set up the mounts yourself, otherwise the contents will disappear when the host machine is rebooted. You are supposed to provide the bind mounts for the persistent storage:
To some suitable place on the host, where the contents will be kept. For instance you could have a special data partition, that you mount. |
I didnt get this. Is this behaviour intentional or do we want to persist |
@Harkishen-Singh : It means that when you are using the "none" driver, it is up to you to set a permanent storage location and then bind mount this to the expected paths. When using the "docker" or "podman" drivers, then minikube should do it. The bug here is that the persistent storage is kept on tmpfs by default, due to #8151. It is a bug in the kic base image. When using the virtualbox VM, the files are persisted correctly... They are supposed to be stored on the disk image / volume. |
This issue is a duplicate of #8151 so it will be solved at the same time. |
With minikube versions v1.9.2 up to v1.11.0 data contained in persistent volumes created by persistent volume claim is not restored after minikube is stopped and started again.
To demonstrate it I install mysql helm template from https://github.com/helm/charts/tree/master/stable/mysql
I connect to mysql using CLI client and create a new user testuser and obtain a list of all users to check that the user was created.
After I stop and restart minikube, connec to mysql again and obtain the user list again, the created user is not available. It indicates that all mysql databases are reset to their original state.
Actually, no data is restored after minikube starts again, and all files are recreated.
Minikube v1.8.2 works as expected.
Please see the log below.
Steps to reproduce the issue:
The text was updated successfully, but these errors were encountered: