We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
dbName
Trying to use as dbName in the DSN:
vcluster/dev
# ... syncer 2024-09-17 22:51:36 INFO commandwriter/commandwriter.go:126 Starting k3s v1.30.2+k3s1 (aa4794b3) {"component": "vcluster", "component": "k3s", "time": "2024-09-17T22:51:36Z", "level": "info"} syncer 2024-09-17 22:51:36 INFO commandwriter/commandwriter.go:126 starting kubernetes: preparing server: creating storage endpoint: building kine: invalid DSN: did you forget to escape a param value? {"component": "vcluster", "component": "k3s", "time": "2024-09-17T22:51:36Z", "level": "fatal"} syncer 2024-09-17 22:51:36 INFO setup/initialize.go:165 Error running k3s: exit status 1 {"component": "vcluster"}
vcluster%2Fdev
# ... syncer 2024-09-17 23:25:13 INFO commandwriter/commandwriter.go:126 Starting k3s v1.30.2+k3s1 (aa4794b3) {"component": "vcluster", "component": "k3s", "time": "2024-09-17T23:25:13Z", "level": "info"} syncer 2024-09-17 23:25:13 INFO commandwriter/commandwriter.go:126 failed to check existence of database vcluster%2Fdev, going to attempt create: Error 1049 (HY000): database not found: vcluster%2Fdev {"component": "vcluster", "component": "k3s", "time": "2024-09-17T23:25:13Z", "level": "warning"} syncer 2024-09-17 23:25:13 INFO commandwriter/commandwriter.go:126 starting kubernetes: preparing server: creating storage endpoint: building kine: Error 1105 (HY000): syntax error at position 40 near 'vcluster' {"component": "vcluster", "component": "k3s", "time": "2024-09-17T23:25:13Z", "level": "fatal"} syncer 2024-09-17 23:25:13 INFO setup/initialize.go:165 Error running k3s: exit status 1 {"component": "vcluster"}
I expected to see Vcluster creating and using the database/schema with a slash in its name.
docker run --rm -e MYSQL_ROOT_PASSWORD=root -p 3306:3306 mysql:8.0.33
controlPlane: distro: k3s: enabled: true backingStore: database: external: enabled: true dataSource: mysql://root:root@tcp(localhost:3306)/vcluster/dev # OR # dataSource: mysql://root:root@tcp(localhost:3306)/vcluster%2Fdev
-- PS: MySQL does support the following DDL:
create database `vcluster/dev`;
schema/branch
$ kubectl version Client Version: v1.31.0 Kustomize Version: v5.4.2 Server Version: v1.30.3-gke.1639000
$ vcluster --version vcluster version 0.20.0
The text was updated successfully, but these errors were encountered:
@lucasfcnunes I spent an afternoon trying to verify this issue, and try to change k3s.go but to no avail.
Finally I noticed that the version of go-sql-driver used by k3s is v1.17, go.mod but theschema/branch mode needs to use v1.8.0.
I tried to submit a pr to k3s to upgrade the go-sql-driver version, after which vcluster should be back to normal.
Sorry, something went wrong.
dbname
@mayooot, I noticed that operators in dbName weren't being scaped too so k3s-io/kine#322 seems to be needed too.
If those get fixed in k3s, let us know what version it's fixed in and then we can get the latest versions of k3s and kine and we can then update it.
Have you tried using the default vanilla k8s version? Or is there a specific reason why you must run k3s?
No branches or pull requests
What happened?
Trying to use as
dbName
in the DSN:vcluster/dev
vcluster%2Fdev
What did you expect to happen?
I expected to see Vcluster creating and using the database/schema with a slash in its name.
How can we reproduce it (as minimally and precisely as possible)?
docker run --rm -e MYSQL_ROOT_PASSWORD=root -p 3306:3306 mysql:8.0.33
--
PS: MySQL does support the following DDL:
Anything else we need to know?
schema/branch
.Host cluster Kubernetes version
vcluster version
VCluster Config
The text was updated successfully, but these errors were encountered: