Skip to content
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

"invalid memory address or nil pointer dereference" error when trying to mount a mysql volume #32

Open
sergeycherepanov opened this issue Sep 19, 2023 · 1 comment

Comments

@sergeycherepanov
Copy link

sergeycherepanov commented Sep 19, 2023

Hi, I trying to use juicefs with mysql to store several config files, all works fine via fuse but fails when I try to mount existing JuiceFS volume to docker volume.

The command to a create docker volume with an exists JuiceFS volume.

docker volume create -d juicedata/juicefs:latest -o name=devserversh-rundeck-ssh -o storage=mysql -o metaurl=mysql://rundeck:rundeck@(192.168.26.1:3306)/devserversh_rundeck_ssh jfsvolume

The journal log

Sep 19 13:13:41 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:41Z" level=error msg="2023/09/19 13:13:41 Entering go-plugins-helpers createPath" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:41 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:41Z" level=error msg="time=\"2023-09-19T13:13:41Z\" level=debug msg=\"&volume.CreateRequest{Name:\\\"jfsvolume\\\", Options:map[string]string{\\\"metaurl\\\":\\\"mysql://rundeck:rundeck@(192.168.26.1:3306)/devserversh_rundeck_ssh\\\", \\\"name\\\":\\\"devserversh-rundeck-ssh\\\"}}\" method=create" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:41 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:41Z" level=error msg="time=\"2023-09-19T13:13:41Z\" level=debug msg=\"/bin/juicefs format --no-update mysql://rundeck:rundeck@(192.168.26.1:3306)/devserversh_rundeck_ssh devserversh-rundeck-ssh\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:41 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:41Z" level=error msg="time=\"2023-09-19T13:13:41Z\" level=debug msg=\"/bin/juicefs mount mysql://rundeck:rundeck@(192.168.26.1:3306)/devserversh_rundeck_ssh /jfs/volumes/devserversh-rundeck-ssh\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:41 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:41Z" level=error msg="time=\"2023-09-19T13:13:41Z\" level=debug msg=\"Error in attempt 1: <nil>\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:41 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:41Z" level=error msg="time=\"2023-09-19T13:13:41Z\" level=debug msg=\"[50 48 50 51 47 48 57 47 49 57 32 49 51 58 49 51 58 52 49 46 49 57 57 56 48 50 32 106 117 105 99 101 102 115 91 50 50 93 32 60 73 78 70 79 62 58 32 77 101 116 97 32 97 100 100 114 101 115 115 58 32 109 121 115 113 108 58 47 47 114 117 110 100 101 99 107 58 42 42 42 42 64 40 49 57 50 46 49 54 56 46 50 54 46 49 58 51 51 48 54 41 47 100 101 118 115 101 114 118 101 114 115 104 95 114 117 110 100 101 99 107 95 115 115 104 32 91 105 110 116 101 114 102 97 99 101 46 103 111 58 52 48 49 93 10 50 48 50 51 47 48 57 47 49 57 32 49 51 58 49 51 58 52 49 46 50 48 49 49 53 57 32 106 117 105 99 101 102 115 91 50 50 93 32 60 70 65 84 65 76 62 58 32 108 111 97 100 32 115 101 116 116 105 110 103 58 32 99 104 101 99 107 32 118 101 114 115 105 111 110 58 32 97 108 108 111 119 101 100 32 109 105 110 105 109 117 109 32 118 101 114 115 105 111 110 58 32 49 46 49 46 48 45 65 59 32 112 108 101 97 115 101 32 117 112 103 114 97 100 101 32 116 104 101 32 99 108 105 101 110 116 32 91 109 97 105 110 46 103 111 58 51 49 93 10]\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:42 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:42Z" level=error msg="time=\"2023-09-19T13:13:42Z\" level=debug msg=\"Error in attempt 2: <nil>\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:43 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:43Z" level=error msg="time=\"2023-09-19T13:13:43Z\" level=debug msg=\"Error in attempt 3: <nil>\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:44 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:44Z" level=error msg="time=\"2023-09-19T13:13:44Z\" level=debug msg=\"Error in attempt 4: <nil>\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:45 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:45Z" level=error msg="time=\"2023-09-19T13:13:45Z\" level=debug msg=\"Error in attempt 5: <nil>\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:46 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:46Z" level=error msg="time=\"2023-09-19T13:13:46Z\" level=debug msg=\"Error in attempt 6: <nil>\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:47 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:47Z" level=error msg="time=\"2023-09-19T13:13:47Z\" level=debug msg=\"Error in attempt 7: <nil>\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:48 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:48Z" level=error msg="time=\"2023-09-19T13:13:48Z\" level=debug msg=\"Error in attempt 8: <nil>\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:49 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:49Z" level=error msg="time=\"2023-09-19T13:13:49Z\" level=debug msg=\"Error in attempt 9: <nil>\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:50 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:50Z" level=error msg="time=\"2023-09-19T13:13:50Z\" level=debug msg=\"Error in attempt 10: <nil>\"" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="2023/09/19 13:13:51 http: panic serving @: runtime error: invalid memory address or nil pointer dereference" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="goroutine 5 [running]:" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="net/http.(*conn).serve.func1()" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/usr/local/go/src/net/http/server.go:1802 +0xb9" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="panic({0x652f00, 0x83caa0})" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/usr/local/go/src/runtime/panic.go:1047 +0x266" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="main.ceMount(0xc000052300)" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51.167836366Z" level=warning msg="Unable to connect to plugin: plugin.moby.localhost/VolumeDriver.Create: Post \"http://plugin.moby.localhost/VolumeDriver.Create\": EOF, retrying in 1s"
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/docker-volume-juicefs/main.go:158 +0x1035" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="main.mountVolume(0xc000052300)" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/docker-volume-juicefs/main.go:265 +0x105" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="main.(*jfsDriver).Create(0xc0000d21c0, 0xc00000e168)" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/docker-volume-juicefs/main.go:313 +0x3ff" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="github.com/docker/go-plugins-helpers/volume.(*Handler).initMux.func1({0x6ec2d0, 0xc0000720e0}, 0x0)" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/go/pkg/mod/github.com/docker/[email protected]/volume/api.go:138 +0xc5" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="net/http.HandlerFunc.ServeHTTP(0x4ad086, {0x6ec2d0, 0xc0000720e0}, 0xc0000720e0)" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/usr/local/go/src/net/http/server.go:2047 +0x2f" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="net/http.(*ServeMux).ServeHTTP(0x0, {0x6ec2d0, 0xc0000720e0}, 0xc000066500)" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/usr/local/go/src/net/http/server.go:2425 +0x149" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="net/http.serverHandler.ServeHTTP({0x6eb7f0}, {0x6ec2d0, 0xc0000720e0}, 0xc000066500)" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/usr/local/go/src/net/http/server.go:2879 +0x43b" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="net/http.(*conn).serve(0xc000062000, {0x6ed200, 0xc000094f90})" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/usr/local/go/src/net/http/server.go:1930 +0xb08" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="created by net/http.(*Server).Serve" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:51 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:51Z" level=error msg="\t/usr/local/go/src/net/http/server.go:3034 +0x4e8" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:52 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:52Z" level=error msg="2023/09/19 13:13:52 Entering go-plugins-helpers createPath" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:52 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:52Z" level=error msg="2023/09/19 13:13:52 Entering go-plugins-helpers capabilitiesPath" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:52 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:52Z" level=error msg="time=\"2023-09-19T13:13:52Z\" level=debug method=capabilities" plugin=a794f8f1c25f8348edacc4ce046377f20c9ea564c176961ea7b393b14b3819e4
Sep 19 13:13:52 rundeck.devserver.local dockerd[2321]: time="2023-09-19T13:13:52.168805647Z" level=error msg="Handler for POST /v1.43/volumes/create returned error: create jfsvolume: VolumeDriver.Create: EOF\n"

The decode of the error:

2023/09/19 13:13:41.199802 juicefs[22] <INFO>: Meta address: mysql://rundeck:****@(192.168.26.1:3306)/devserversh_rundeck_ssh [interface.go:401]
2023/09/19 13:13:41.201159 juicefs[22] <FATAL>: load setting: check version: allowed minimum version: 1.1.0-A; please upgrade the client [main.go:31]

JuiceFS Version

juicefs version 1.1.0+2023-09-04.08c4ae6
@sergeycherepanov sergeycherepanov changed the title "invalid memory address or nil pointer dereference" error when trying to mount the mysql volume "invalid memory address or nil pointer dereference" error when trying to mount the a volume Sep 19, 2023
@sergeycherepanov sergeycherepanov changed the title "invalid memory address or nil pointer dereference" error when trying to mount the a volume "invalid memory address or nil pointer dereference" error when trying to mount a mysql volume Sep 19, 2023
@sergeycherepanov
Copy link
Author

sergeycherepanov commented Sep 19, 2023

Looks like the plugin needs to be rebuilt using the latest version of JuiceFS.

A temporary solution is to build the plugin from the source code:

git clone https://github.com/juicedata/docker-volume-juicefs.git
cd docker-volume-juicefs
make
make enable

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant