Public bug reported:

While trying to install a snap, the configure hook failed:

$ snap install /home/ubuntu/cdk-addons_1.5.2_amd64.snap --dangerous
error: cannot perform the following tasks:
- Run configure hook of "cdk-addons" snap if present (run hook "configure": 
error: cannot communicate with server: Post http://localhost/v2/snapctl: EOF)

In the snapd journal, I see a panic:

2017/03/06 22:03:25 http: panic serving @: runtime error: invalid memory 
address or nil pointer dereference
goroutine 90 [running]:
net/http.(*conn).serve.func1(0xc820074900)
        /usr/lib/go-1.6/src/net/http/server.go:1389 +0xc3
panic(0x55e6e53aa9e0, 0xc82000a090)
        /usr/lib/go-1.6/src/runtime/panic.go:443 +0x4ed
github.com/snapcore/snapd/overlord/configstate.getFromPristine(0xc820166e50, 
0xa, 0xc820472020, 0x1, 0x1, 0x0, 0xc820478510, 0x55e6e524a280, 0xc820472000, 
0x0, ...)
        
/build/snapd-uAIKtO/snapd-2.22.7/_build/src/github.com/snapcore/snapd/overlord/configstate/transaction.go:162
 +0x23a
github.com/snapcore/snapd/overlord/configstate.(*Transaction).Get(0xc820164700, 
0xc820166e50, 0xa, 0xc820511c14, 0x6, 0x55e6e524a280, 0xc820472000, 0x0, 0x0)
        
/build/snapd-uAIKtO/snapd-2.22.7/_build/src/github.com/snapcore/snapd/overlord/configstate/transaction.go:138
 +0x2cc
github.com/snapcore/snapd/overlord/hookstate/ctlcmd.(*getCommand).Execute(0xc8200c6780,
 0xc8204586c0, 0x0, 0x2, 0x0, 0x0)
        
/build/snapd-uAIKtO/snapd-2.22.7/_build/src/github.com/snapcore/snapd/overlord/hookstate/ctlcmd/get.go:83
 +0x2a5
github.com/snapcore/snapd/vendor/github.com/jessevdk/go-flags.(*Parser).ParseArgs(0xc8200c6730,
 0xc82045ce80, 0x2, 0x4, 0x0, 0x0, 0x0, 0x0, 0x0)
        
/build/snapd-uAIKtO/snapd-2.22.7/_build/src/github.com/snapcore/snapd/vendor/github.com/jessevdk/go-flags/parser.go:301
 +0xa12
github.com/snapcore/snapd/overlord/hookstate/ctlcmd.Run(0xc820294480, 
0xc82045ce80, 0x2, 0x4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
        
/build/snapd-uAIKtO/snapd-2.22.7/_build/src/github.com/snapcore/snapd/overlord/hookstate/ctlcmd/ctlcmd.go:113
 +0x4d1
github.com/snapcore/snapd/daemon.runSnapctl(0x55e6e57f02c0, 0xc8201687e0, 0x0, 
0x0, 0x0)
        
/build/snapd-uAIKtO/snapd-2.22.7/_build/src/github.com/snapcore/snapd/daemon/api.go:2153
 +0x349
github.com/snapcore/snapd/daemon.(*Command).ServeHTTP(0x55e6e57f02c0, 
0x7f6aeb54d738, 0xc8204584e0, 0xc8201687e0)
        
/build/snapd-uAIKtO/snapd-2.22.7/_build/src/github.com/snapcore/snapd/daemon/daemon.go:144
 +0x33c
github.com/snapcore/snapd/vendor/github.com/gorilla/mux.(*Router).ServeHTTP(0xc8202963c0,
 0x7f6aeb54d738, 0xc8204584e0, 0xc8201687e0)
        
/build/snapd-uAIKtO/snapd-2.22.7/_build/src/github.com/snapcore/snapd/vendor/github.com/gorilla/mux/mux.go:100
 +0x2a0
github.com/snapcore/snapd/daemon.logit.func1(0x7f6aeb54d700, 0xc8200509c0, 
0xc8201687e0)
        
/build/snapd-uAIKtO/snapd-2.22.7/_build/src/github.com/snapcore/snapd/daemon/daemon.go:172
 +0x10b
net/http.HandlerFunc.ServeHTTP(0xc8203aa7e0, 0x7f6aeb54d700, 0xc8200509c0, 
0xc8201687e0)
        /usr/lib/go-1.6/src/net/http/server.go:1618 +0x3c
net/http.serverHandler.ServeHTTP(0xc8202cc600, 0x7f6aeb54d700, 0xc8200509c0, 
0xc8201687e0)
        /usr/lib/go-1.6/src/net/http/server.go:2081 +0x1a0
net/http.(*conn).serve(0xc820074900)
        /usr/lib/go-1.6/src/net/http/server.go:1472 +0xf30
created by net/http.(*Server).Serve
        /usr/lib/go-1.6/src/net/http/server.go:2137 +0x450

** Affects: snapd (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1670501

Title:
  invalid memory address or nil pointer dereference in transaction.go

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/snapd/+bug/1670501/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to