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

"fuse: panic in handler for Setattr" after copying file to mounted remote filer #1221

Closed
jonathonf opened this issue Mar 7, 2020 · 2 comments

Comments

@jonathonf
Copy link

I might be doing something wrong here, but here goes...

I have a weed server -ip="10.0.0.1" -ip.bind="10.0.0.1" (Debian Buster) with a complete security.conf (following https://github.com/chrislusf/seaweedfs/wiki/Security-Configuration) and set of keys and PEMs in $HOME/.seaweedfs. I have copied $HOME/.seaweedfs to a client machine (Manjaro) and mounted with weed mount -filer="10.0.0.1:8888".

Both are using the 1.58 binary release.

When I copy a file to the mounted FS, on completion the client process panics:

2020-03-07 19:57:11.035815 I | fuse: panic in handler for Setattr [ID=0xf6b Node=0x2 Uid=0 Gid=0 Pid=14879] mtime=2020-03-06 20:39:15.856436
726 +0000 UTC handle=INVALID-0x0: runtime error: invalid memory address or nil pointer dereference                                          
goroutine 4052 [running]:                                                                                              
github.com/seaweedfs/fuse/fs.(*Server).serve.func2(0x22abca0, 0xc0004b8180, 0xc000b77ec0, 0xc000b77daf)                                     
        /home/travis/gopath/pkg/mod/github.com/seaweedfs/fuse@v0.0.0-20190510212405-310228904eff/fs/serve.go:861 +0x1a2                     
panic(0x1b8ed20, 0x331a7a0)                                                                
        /home/travis/.gimme/versions/go1.13.8.linux.amd64/src/runtime/panic.go:679 +0x1b2                                                   
github.com/chrislusf/seaweedfs/weed/filesys.(*WFS).maybeLoadEntry.func1(0x22dc380, 0xc0001382f0, 0x6, 0xc0000adc70)                         
        /home/travis/gopath/src/github.com/chrislusf/seaweedfs/weed/filesys/xattr.go:129 +0x35a                                            
github.com/chrislusf/seaweedfs/weed/filesys.(*WFS).WithFilerClient.func1(0xc000478e00, 0xc000166060, 0xc0001df840)                          
        /home/travis/gopath/src/github.com/chrislusf/seaweedfs/weed/filesys/wfs.go:98 +0x6b                                                
github.com/chrislusf/seaweedfs/weed/util.WithCachedGrpcClient(0xc00043e798, 0xc0001df840, 0x10, 0xc00043e7a8, 0x1, 0x1, 0x18ed317, 0xc0000c2
dc0)                                                                                                                                       
        /home/travis/gopath/src/github.com/chrislusf/seaweedfs/weed/util/grpc_client_server.go:69 +0xc6                                     
github.com/chrislusf/seaweedfs/weed/filesys.(*WFS).WithFilerClient(0xc00015aa90, 0xc00043e820, 0x3a, 0x0)                                   
        /home/travis/gopath/src/github.com/chrislusf/seaweedfs/weed/filesys/wfs.go:96 +0x9c                                                
github.com/chrislusf/seaweedfs/weed/filesys.(*WFS).maybeLoadEntry(0xc00015aa90, 0x1eb2de6, 0x1, 0xc0000fe440, 0x39, 0x0, 0xc0007c5101, 0xc00
055b0c0)                                                                                                                                    
        /home/travis/gopath/src/github.com/chrislusf/seaweedfs/weed/filesys/xattr.go:120 +0x1c3                                            
github.com/chrislusf/seaweedfs/weed/filesys.(*File).maybeLoadEntry(0xc0004d6d70, 0x22b8ca0, 0xc0007de140, 0xc0000fe440, 0x39)               
        /home/travis/gopath/src/github.com/chrislusf/seaweedfs/weed/filesys/file.go:224 +0x6b                                               
github.com/chrislusf/seaweedfs/weed/filesys.(*File).Setattr(0xc0004d6d70, 0x22b8ca0, 0xc0007de140, 0xc0004b8180, 0xc00059d680, 0x1, 0x0)   
        /home/travis/gopath/src/github.com/chrislusf/seaweedfs/weed/filesys/file.go:101 +0x186                                             
github.com/seaweedfs/fuse/fs.(*Server).handleRequest(0xc000410000, 0x22b8ca0, 0xc0007de140, 0x2272120, 0xc0004d6d70, 0xc0004d8ac0, 0x22abca0
, 0xc0004b8180, 0xc000b77ec0, 0x0, ...)                                                                                                     
        /home/travis/gopath/pkg/mod/github.com/seaweedfs/fuse@v0.0.0-20190510212405-310228904eff/fs/serve.go:949 +0x27e3                   
github.com/seaweedfs/fuse/fs.(*Server).serve(0xc000410000, 0x22abca0, 0xc0004b8180)                                                         
        /home/travis/gopath/pkg/mod/github.com/seaweedfs/fuse@v0.0.0-20190510212405-310228904eff/fs/serve.go:882 +0x2fd                     
github.com/seaweedfs/fuse/fs.(*Server).Serve.func1(0xc000410000, 0x22abca0, 0xc0004b8180)                                                  
        /home/travis/gopath/pkg/mod/github.com/seaweedfs/fuse@v0.0.0-20190510212405-310228904eff/fs/serve.go:424 +0x7c                      
created by github.com/seaweedfs/fuse/fs.(*Server).Serve                                                                                     
        /home/travis/gopath/pkg/mod/github.com/seaweedfs/fuse@v0.0.0-20190510212405-310228904eff/fs/serve.go:422 +0x35e

Trying to access the file results in an IO error:

$ file file.txt
file.txt: cannot open `file.txt' (Input/output error)
@chrislusf
Copy link
Collaborator

Thanks for reporting! It is a code bug, not your fault. Fixed just now.

@chrislusf
Copy link
Collaborator

you can use 1.59 release now.

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

2 participants