From nobody@FreeBSD.org  Thu May  7 10:34:14 2009
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 AAC58106564A
	for <freebsd-gnats-submit@FreeBSD.org>; Thu,  7 May 2009 10:34:14 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id 989148FC13
	for <freebsd-gnats-submit@FreeBSD.org>; Thu,  7 May 2009 10:34:14 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.3/8.14.3) with ESMTP id n47AYDhG053918
	for <freebsd-gnats-submit@FreeBSD.org>; Thu, 7 May 2009 10:34:13 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id n47AYDBI053917;
	Thu, 7 May 2009 10:34:13 GMT
	(envelope-from nobody)
Message-Id: <200905071034.n47AYDBI053917@www.freebsd.org>
Date: Thu, 7 May 2009 10:34:13 GMT
From: Thomas Dreibholz <dreibh@iem.uni-due.de>
To: freebsd-gnats-submit@FreeBSD.org
Subject: PPP configuration problem in the rc.d scripts in combination with bash shell
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         134333
>Category:       conf
>Synopsis:       PPP configuration problem in the rc.d scripts in combination with bash shell
>Confidential:   no
>Severity:       non-critical
>Priority:       high
>Responsible:    freebsd-rc
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu May 07 10:40:01 UTC 2009
>Closed-Date:    
>Last-Modified:  Sat Jun  6 08:40:01 UTC 2009
>Originator:     Thomas Dreibholz
>Release:        7.1-RELEASE
>Organization:
University of Duisburg-Essen
>Environment:
FreeBSD essen 7.1-RELEASE-p5 FreeBSD 7.1-RELEASE-p5 #6: Tue May  5 11:43:31 CEST 2009     root@essen:/usr/src/sys/amd64/compile/SCTP  amd64
>Description:
I have set the shell for the root user to bash. The system has a PPPoE configuration to connect to Telekom DSL. In /etc/rc.conf, the following PPP configuration is entered:
ppp_enable="YES"
ppp_nat="NO"
ppp_profile="telekom"
ppp_mode="ddial"

On boot, the system does not activate this configuration. The ppp daemon is not started. Starting it manually works fine.


>How-To-Repeat:
Use bash (/usr/local/bin/bash) as shell for root. The Internet connection is not established on system boot after that.
>Fix:
In the Internet, I found a forum entry from 2005 describing the same problem (https://www.bsdforen.de/showthread.php?p=82530). The solution was to use /bin/csh as shell for root. After this change, the PPP configuration at system boot works as expected. I did no further debugging of this problem yet, but I assume that somewhere in the rc.d scripts /bin/csh is assumed to be the shell of the root user. This is clearly a bug which should be fixed.

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-rc 
Responsible-Changed-By: gavin 
Responsible-Changed-When: Thu May 7 14:46:29 UTC 2009 
Responsible-Changed-Why:  
Over to maintainer(s).  Be aware, however, that I'm not sure bash is supported 
as the default root shell, so other breakages similar to this may also occur. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=134333 

From: Jilles Tjoelker <jilles@stack.nl>
To: bug-followup@FreeBSD.org, dreibh@iem.uni-due.de
Cc:  
Subject: Re: conf/134333: PPP configuration problem in the rc.d scripts in
	combination with bash shell
Date: Sat, 6 Jun 2009 10:30:36 +0200

 The cause is probably that /etc/rc.d/ppp is using su -m, which uses the
 invoking user's shell from /etc/passwd. There doesn't seem a good
 alternative for su -m though, other than requiring the target user have
 /bin/sh as shell and using plain su or su -. A new option to su to
 execute a command using /bin/sh could be useful.
 
 -- 
 Jilles Tjoelker
>Unformatted:
