1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132 | 2016/10/26 14:11:52 Preparing external:ubuntu-core-16-arm-64:tests/main/ubuntu-core-reboot...
2016/10/26 14:12:23 Executing external:ubuntu-core-16-arm-64:tests/main/ubuntu-core-reboot...
2016/10/26 14:12:24 Rebooting external:ubuntu-core-16-arm-64 as requested...
2016/10/26 14:17:28 Reboot of external:ubuntu-core-16-arm-64 is taking a while...
2016/10/26 14:18:56 Error executing external:ubuntu-core-16-arm-64:tests/main/ubuntu-core-reboot :
-----
mesg: ttyname failed: Inappropriate ioctl for device
+ echo 'Ensure snaps are (still) there.'
Ensure snaps are (still) there.
+ snap list
+ grep test-snapd-tools
test-snapd-tools 1.0 x1 -
+ snap list
+ grep network-bind-consumer
network-bind-consumer 1.0 x1 -
+ echo 'Ensure the service is (still) running.'
Ensure the service is (still) running.
+ retries=10
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
active
+ echo 'Ensure apparmor profiles are (still) loaded.'
Ensure apparmor profiles are (still) loaded.
+ for app in success fail echo head env block cat
+ grep 'snap.test-snapd-tools.success (enforce)' /sys/kernel/security/apparmor/profiles
snap.test-snapd-tools.success (enforce)
+ for app in success fail echo head env block cat
+ grep 'snap.test-snapd-tools.fail (enforce)' /sys/kernel/security/apparmor/profiles
snap.test-snapd-tools.fail (enforce)
+ for app in success fail echo head env block cat
+ grep 'snap.test-snapd-tools.echo (enforce)' /sys/kernel/security/apparmor/profiles
snap.test-snapd-tools.echo (enforce)
+ for app in success fail echo head env block cat
+ grep 'snap.test-snapd-tools.head (enforce)' /sys/kernel/security/apparmor/profiles
snap.test-snapd-tools.head (enforce)
+ for app in success fail echo head env block cat
+ grep 'snap.test-snapd-tools.env (enforce)' /sys/kernel/security/apparmor/profiles
snap.test-snapd-tools.env (enforce)
+ for app in success fail echo head env block cat
+ grep 'snap.test-snapd-tools.block (enforce)' /sys/kernel/security/apparmor/profiles
snap.test-snapd-tools.block (enforce)
+ for app in success fail echo head env block cat
+ grep 'snap.test-snapd-tools.cat (enforce)' /sys/kernel/security/apparmor/profiles
snap.test-snapd-tools.cat (enforce)
+ '[' 0 = 0 ']'
+ REBOOT
<REBOOT>
+ echo 'Ensure snaps are (still) there.'
Ensure snaps are (still) there.
+ snap list
+ grep test-snapd-tools
test-snapd-tools 1.0 x1 -
+ snap list
+ grep network-bind-consumer
network-bind-consumer 1.0 x1 -
+ echo 'Ensure the service is (still) running.'
Ensure the service is (still) running.
+ retries=10
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 10 -eq 0 ']'
+ retries=9
+ sleep 1
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 9 -eq 0 ']'
+ retries=8
+ sleep 1
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 8 -eq 0 ']'
+ retries=7
+ sleep 1
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 7 -eq 0 ']'
+ retries=6
+ sleep 1
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 6 -eq 0 ']'
+ retries=5
+ sleep 1
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 5 -eq 0 ']'
+ retries=4
+ sleep 1
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 4 -eq 0 ']'
+ retries=3
+ sleep 1
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 3 -eq 0 ']'
+ retries=2
+ sleep 1
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 2 -eq 0 ']'
+ retries=1
+ sleep 1
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 1 -eq 0 ']'
+ retries=0
+ sleep 1
+ systemctl is-active snap.network-bind-consumer.network-consumer.service
inactive
+ '[' 0 -eq 0 ']'
+ echo 'Service did not activate.'
Service did not activate.
+ exit 1
-----
2016/10/26 14:18:56 Error debugging external:ubuntu-core-16-arm-64:tests/main/ubuntu-core-reboot :
-----
+ journalctl -u snapd
-- Logs begin at Wed 2016-10-26 11:44:46 UTC, end at Wed 2016-10-26 11:45:09 UTC. --
Oct 26 11:44:51 localhost.localdomain systemd[1]: Started Snappy daemon.
Oct 26 11:44:52 localhost.localdomain /usr/lib/snapd/snapd[1998]: daemon.go:209: DEBUG: init done in 3.33ms
Oct 26 11:44:53 localhost.localdomain /usr/lib/snapd/snapd[1998]: daemon.go:174: DEBUG: uid=0;@ GET /v2/system-info 1.108293s 200
Oct 26 11:44:59 localhost.localdomain /usr/lib/snapd/snapd[1998]: daemon.go:174: DEBUG: uid=0;@ GET /v2/snaps 23.187ms 200
Oct 26 11:44:59 localhost.localdomain /usr/lib/snapd/snapd[1998]: daemon.go:174: DEBUG: uid=0;@ GET /v2/snaps 4.967ms 200
+ dmesg
+ grep DENIED
-----
2016/10/26 14:18:56 Starting shell to debug...
external:ubuntu-core-16-arm-64 .../tests/main/ubuntu-core-reboot# systemctl is-active snap.network-bind-consumer.network-consumer.service
active
external:ubuntu-core-16-arm-64 .../tests/main/ubuntu-core-reboot# echo $?
0
|