# ezjail: update unfinished?



## basbebe (Jan 28, 2016)

I'm keeping getting weird messages when I try to update my email managed jails:

I'm on FreeBSD 10.2-RELEASE-p11 and ezjail v3.4.2

The jails show the right version inside but the update progress doesn't seem to have finished.

This is what I'm getting:


```
ezjail-admin update -u
Looking up update.FreeBSD.org mirrors... 4 mirrors found.
Fetching metadata signature for 10.2-RELEASE from update6.freebsd.org... done.
Fetching metadata index... done.
Inspecting system... done.
Preparing to download files... done.

No updates needed to update system to 10.2-RELEASE-p11.
No updates are available to install.
Run '/usr/sbin/freebsd-update fetch' first.
Looking up update.FreeBSD.org mirrors... 4 mirrors found.
Fetching metadata signature for 10.2-RELEASE from update3.freebsd.org... done.
Fetching metadata index... done.
Inspecting system... done.
Preparing to download files... done.

The following files will be added as part of updating to 10.2-RELEASE-p11:
/usr/src/contrib/ntp/include/ntp_keyacc.h
/usr/src/contrib/ntp/include/rc_cmdlength.h
/usr/src/contrib/ntp/include/safecast.h
/usr/src/contrib/ntp/libntp/is_ip_address.c
/usr/src/contrib/ntp/sntp/m4/ntp_problemtests.m4
/usr/src/contrib/ntp/sntp/tests/fileHandlingTest.c
/usr/src/contrib/ntp/sntp/tests/run-t-log.c
/usr/src/contrib/ntp/sntp/tests/sntptest.c
/usr/src/contrib/ntp/sntp/tests/t-log.c
/usr/src/contrib/ntp/sntp/unity/auto/parseOutput.rb
/usr/src/contrib/ntp/sntp/unity/auto/type_sanitizer.rb
/usr/src/contrib/ntp/sntp/unity/auto/unity_test_summary.py
/usr/src/contrib/ntp/sntp/unity/unity_config.h
/usr/src/contrib/ntp/tests/libntp/lfptest.c
/usr/src/contrib/ntp/tests/libntp/sockaddrtest.c
/usr/src/contrib/ntp/tests/ntpd/leapsec.c
/usr/src/contrib/ntp/tests/ntpd/ntp_prio_q.c
/usr/src/contrib/ntp/tests/ntpd/ntp_restrict.c
/usr/src/contrib/ntp/tests/ntpd/rc_cmdlength.c
/usr/src/contrib/ntp/tests/ntpd/run-leapsec.c
/usr/src/contrib/ntp/tests/ntpd/run-ntp_prio_q.c
/usr/src/contrib/ntp/tests/ntpd/run-ntp_restrict.c
/usr/src/contrib/ntp/tests/ntpd/run-rc_cmdlength.c
/usr/src/contrib/ntp/tests/ntpd/run-t-ntp_scanner.c
/usr/src/contrib/ntp/tests/ntpd/run-t-ntp_signd.c
/usr/src/contrib/ntp/tests/ntpd/t-ntp_scanner.c
/usr/src/contrib/ntp/tests/ntpd/t-ntp_signd.c
/usr/src/contrib/ntp/tests/ntpq
/usr/src/contrib/ntp/tests/ntpq/Makefile.am
/usr/src/contrib/ntp/tests/ntpq/Makefile.in
/usr/src/contrib/ntp/tests/ntpq/run-t-ntpq.c
/usr/src/contrib/ntp/tests/ntpq/t-ntpq.c
Installing updates...mkdir: /usr/jails/newjail//boot: No such file or directory
mtree: /usr/jails/newjail//boot/kernel: No such file or directory
mtree: /usr/jails/newjail//boot/kernel.old: No such file or directory
touch: /usr/jails/newjail//boot/kernel.old/.freebsd-update: No such file or directory
Could not create kernel backup directory
```


----------



## SirDice (Jan 28, 2016)

Jails don't have a kernel so it really shouldn't try and update something that doesn't exist.


----------



## basbebe (Jan 28, 2016)

SirDice said:


> Jails don't have a kernel so it really shouldn't try and update something that doesn't exist.


So is this an ezjail(7) problem or is there anything I could do?
I also already did a `# ezjail-admin install`.
I'm thinking about switching to sysutils/qjail anyways. Would I avoid these problems by that?


----------



## basbebe (Feb 1, 2016)

getopt said:


> Post `ls -l /usr/jails/` and  `ls -l /usr/jails/newjail`
> Also post /usr/local/etc/ezjail.conf



`la /usr/jails`

```
total 103
drwxr-xr-x   9 root  wheel     9B 11 Mär  2015 basejail
drwxr-xr-x  12 root  wheel    22B 20 Mär  2015 cache
drwxr-xr-x  12 root  wheel    24B  5 Jan 14:23 cloud
drwxr-xr-x  12 root  wheel    23B 17 Dez 19:35 db
drwxr-xr-x   2 root  wheel     4B 28 Jan 17:16 ezjail_archives
drwxr-xr-x   4 root  wheel     4B 11 Mär  2015 flavours
drwxr-xr-x  12 root  wheel    23B  9 Dez 11:46 mail
drwxr-xr-x  12 root  wheel    22B 31 Jan 18:09 newjail
drwxr-xr-x  12 root  wheel    25B 25 Jan 10:28 push
drwxr-xr-x  12 root  wheel    23B 12 Jan 10:00 tools
drwxr-xr-x  12 root  wheel    22B 22 Mär  2015 vpn
drwxr-xr-x  12 root  wheel    22B 21 Mär  2015 web
drwxr-xr-x  12 root  wheel    23B 13 Mär  2015 www
```

`la /usr/jails/newjail`

```
total 46
-rw-r--r--   2 root  wheel   966B 12 Aug 17:27 .cshrc
-rw-r--r--   2 root  wheel   254B 12 Aug 17:27 .profile
-r--r--r--   1 root  wheel   6,1K 12 Aug 17:27 COPYRIGHT
drwxr-xr-x   2 root  wheel     2B 31 Jan 18:09 basejail
lrwxr-xr-x   1 root  wheel    13B 31 Jan 18:09 bin -> /basejail/bin
lrwxr-xr-x   1 root  wheel    14B 31 Jan 18:09 boot -> /basejail/boot
dr-xr-xr-x   2 root  wheel     2B 12 Aug 17:26 dev
drwxr-xr-x  23 root  wheel   101B 31 Jan 18:09 etc
lrwxr-xr-x   1 root  wheel    13B 31 Jan 18:09 lib -> /basejail/lib
lrwxr-xr-x   1 root  wheel    17B 31 Jan 18:09 libexec -> /basejail/libexec
drwxr-xr-x   2 root  wheel     2B 12 Aug 17:26 media
drwxr-xr-x   2 root  wheel     2B 12 Aug 17:26 mnt
dr-xr-xr-x   2 root  wheel     2B 12 Aug 17:26 proc
lrwxr-xr-x   1 root  wheel    16B 31 Jan 18:09 rescue -> /basejail/rescue
drwxr-xr-x   2 root  wheel     6B 12 Aug 17:27 root
lrwxr-xr-x   1 root  wheel    14B 31 Jan 18:09 sbin -> /basejail/sbin
lrwxr-xr-x   1 root  wheel    11B 12 Aug 17:27 sys -> usr/src/sys
drwxrwxrwt   2 root  wheel     2B 12 Aug 17:26 tmp
drwxr-xr-x   5 root  wheel    15B 31 Jan 18:09 usr
drwxr-xr-x  25 root  wheel    25B 31 Jan 18:09 var
```

`cat /usr/local/etc/ezjail.conf` (removed comments here)

```
ezjail_default_flavour="default"

ezjail_use_zfs="YES"

ezjail_use_zfs_for_jails="YES"

ezjail_jailzfs="zroot/ezjail"
```


----------



## basbebe (Feb 1, 2016)

getopt said:


> Looks good, what you have. In addition I have these lines in my ezjail.conf.
> 
> ```
> ezjail_jaildir=/jails
> ...



I'm sorry but you linked back to this thread…


----------



## basbebe (Feb 1, 2016)

getopt said:


> Sorry. I edited the link.


Thank you!

I already did that at the last update and it helped this time again. I had forgotten about it…
But after a reboot I have the same problem of course.
I know that I could add it to fstab but shouldn't ezjail handle these issues more elegantly by making better use of zfs mounts or null mounts?


----------

