From owner-freebsd-bugs@FreeBSD.ORG Sat Apr 12 07:40:01 2014 Return-Path: Delivered-To: freebsd-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 144AED9A for ; Sat, 12 Apr 2014 07:40:01 +0000 (UTC) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E50AE177D for ; Sat, 12 Apr 2014 07:40:00 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.8/8.14.8) with ESMTP id s3C7e0j1050392 for ; Sat, 12 Apr 2014 07:40:00 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.8/8.14.8/Submit) id s3C7e03N050391; Sat, 12 Apr 2014 07:40:00 GMT (envelope-from gnats) Resent-Date: Sat, 12 Apr 2014 07:40:00 GMT Resent-Message-Id: <201404120740.s3C7e03N050391@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Holger Freyther Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 7896EC70 for ; Sat, 12 Apr 2014 07:32:22 +0000 (UTC) Received: from cgiserv.freebsd.org (cgiserv.freebsd.org [IPv6:2001:1900:2254:206a::50:4]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 65722174D for ; Sat, 12 Apr 2014 07:32:22 +0000 (UTC) Received: from cgiserv.freebsd.org ([127.0.1.6]) by cgiserv.freebsd.org (8.14.8/8.14.8) with ESMTP id s3C7WLwk002414 for ; Sat, 12 Apr 2014 07:32:21 GMT (envelope-from nobody@cgiserv.freebsd.org) Received: (from nobody@localhost) by cgiserv.freebsd.org (8.14.8/8.14.8/Submit) id s3C7WL7w002401; Sat, 12 Apr 2014 07:32:21 GMT (envelope-from nobody) Message-Id: <201404120732.s3C7WL7w002401@cgiserv.freebsd.org> Date: Sat, 12 Apr 2014 07:32:21 GMT From: Holger Freyther To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Subject: misc/188495: /etc/rc.d/jail, ezjail and Linux jails don't work with FreeBSD 10.0 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Apr 2014 07:40:01 -0000 >Number: 188495 >Category: misc >Synopsis: /etc/rc.d/jail, ezjail and Linux jails don't work with FreeBSD 10.0 >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sat Apr 12 07:40:00 UTC 2014 >Closed-Date: >Last-Modified: >Originator: Holger Freyther >Release: 10.0 >Organization: >Environment: FreeBSD 10.0-RELEASE-p1 FreeBSD 10.0-RELEASE-p1 #14 5464d00(10-releng)-dirty: Sat Apr 12 05:49:26 UTC 2014 >Description: I am using ezjail and have a Linux/Debian/Squeeze jail. Starting with FreeBSD the jail can not be started. In the ezjail config I specify: export jail_osmocom_builder_debian_flags="-l -U root" When executing ezjail the following command will be executed: /usr/sbin/jail -l -u root -i -f /var/run/jail.osmocom_builder_debian.conf -c osmocom_builder_debian Passing -l (or -u root) and -f together will generate a non comprehensive error message of the jail command: usage: jail [-dhilqv] [-J jid_file] [-u username] [-U username] -[cmr] param=value ... [command=command ...] jail [-dqv] [-f file] -[cmr] [jail] jail [-qv] [-f file] -[rR] ['*' | jail ...] jail [-dhilqv] [-J jid_file] [-u username] [-U username] [-n jailname] [-s securelevel] path hostname [ip[,...]] command ... When removing the flags the jail command fails in determing the uid/id of root inside the jail. This is to be understood as the database used in FreeBSD does not exist in linux. The only way to get it started is to remove three lines generated by /etc/rc.d/jail echo " exec.clean;" echo " exec.system_user = \"root\";" echo " exec.jail_user = \"root\";" Otherwise the command will fail with: jail: osmocom_builder_debian: getpwnam: No such file or directory jail: osmocom_builder_debian: sleep 2: failed >How-To-Repeat: Attempt to start a non FreeBSD jail. >Fix: >Release-Note: >Audit-Trail: >Unformatted: