From nobody@FreeBSD.org  Tue May 15 09:35:50 2012
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 663DD1065672
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 15 May 2012 09:35:50 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22])
	by mx1.freebsd.org (Postfix) with ESMTP id 386B88FC0C
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 15 May 2012 09:35:50 +0000 (UTC)
Received: from red.freebsd.org (localhost [127.0.0.1])
	by red.freebsd.org (8.14.4/8.14.4) with ESMTP id q4F9ZoFT067400
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 15 May 2012 09:35:50 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.4/8.14.4/Submit) id q4F9ZnDl067399;
	Tue, 15 May 2012 09:35:49 GMT
	(envelope-from nobody)
Message-Id: <201205150935.q4F9ZnDl067399@red.freebsd.org>
Date: Tue, 15 May 2012 09:35:49 GMT
From: Oleg Ginzburg <olevole@olevole.ru>
To: freebsd-gnats-submit@FreeBSD.org
Subject: new jail(8) problem with removal, ifconfg -alias and kqueue error
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         167911
>Category:       bin
>Synopsis:       new jail(8) problem with removal, ifconfg -alias and kqueue error
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-jail
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue May 15 09:40:03 UTC 2012
>Closed-Date:    
>Last-Modified:  Thu May 17 07:14:00 UTC 2012
>Originator:     Oleg Ginzburg
>Release:        
>Organization:
>Environment:
FreeBSD gizmo.my.domain 10.0-CURRENT FreeBSD 10.0-CURRENT #2 r235426: Mon May 14 15:40:12 MSK 2012     root@:/usr/obj/usr/src/sys/GENERIC  amd64
>Description:
Ive got a multiple problem with new jail and removal from the first with kqueue
error, device busy for devfs and jail(8) doesn't do ifconfig -alias.


>How-To-Repeat:
root@netsnap:/usr/jails/var # cat jail1.conf
jail1 {
exec.start = "/bin/sh /etc/rc";
exec.stop = "/bin/sh /etc/rc.shutdown";
exec.clean;
mount.devfs;
host.hostname = "jail1.my.domain";
path = "/usr/jails/jails/jail1";
allow.raw_sockets;
allow.socket_af;
allow.chflags;
allow.sysvipc;
ip4.addr = 192.168.1.67/24;
interface="em0";
devfs_ruleset="4";
}


root@netsnap:/usr/jails/var # ifconfig em0
em0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 9000
       options=98<VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM>
       ether 08:00:27:d3:9a:a9
       inet6 2a01:4f8:61:50c2::13 prefixlen 64 duplicated
       inet6 fe80::a00:27ff:fed3:9aa9%em0 prefixlen 64 scopeid 0x1
       inet 192.168.1.101 netmask 0xffffff00 broadcast 192.168.1.255
       nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
       media: Ethernet autoselect (1000baseT <full-duplex>)
       status: active


root@netsnap:/usr/jails/var # jail -f jail1.conf -c jail1
jail1: created
/etc/rc: WARNING: $hostname is not set -- see rc.conf(5).
Creating and/or trimming log files.
ln: /dev/log: Operation not permitted
Starting syslogd.
ELF ldconfig path: /lib /usr/lib /usr/lib/compat
32-bit compatibility ldconfig path: /usr/lib32
Clearing /tmp (X related).
Updating motd:.
Starting cron.

Mon May 14 18:56:27 UTC 2012

Ok, all fine on this moment:

root@netsnap:/usr/jails/var # ifconfig em0
em0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 9000
       options=98<VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM>
       ether 08:00:27:d3:9a:a9
       inet6 2a01:4f8:61:50c2::13 prefixlen 64 duplicated
       inet6 fe80::a00:27ff:fed3:9aa9%em0 prefixlen 64 scopeid 0x1
       inet 192.168.1.101 netmask 0xffffff00 broadcast 192.168.1.255
       inet 192.168.1.67 netmask 0xffffff00 broadcast 192.168.1.255
       nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
       media: Ethernet autoselect (1000baseT <full-duplex>)
       status: active


Now dancing with stopping:

root@netsnap:/usr/jails/var # jail -f jail1.conf -r jail1
Stopping cron.
Terminated
>Fix:
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-jail 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Thu May 17 07:13:45 UTC 2012 
Responsible-Changed-Why:  
Over to maintainer(s). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=167911 
>Unformatted:
