On Fri, Aug 03, 2007 at 04:32:10PM +0200, J?r?my Herv? wrote: > - version : 3.1.17(2)-release (i486-slackware-linux-gnu) > - description : Strange behaviour ; second time I have it. I removed > an old apache package (1.3, /usr/sbin/httpd) and make;make-installed a > new one (/usr/bin/httpd). Here is the transcript of what appened then. > > [EMAIL PROTECTED]:/usr/bin# env | grep PATH > MANPATH=/usr/local/man:/usr/man:/usr/X11R6/man:/usr/lib/java/man:/usr/share/texmf/man > PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games:/opt/www/htdig/bin:/usr/lib/java/bin:/usr/lib/java/jre/bin:/usr/share/texmf/bin > PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:/usr/lib/pkgconfig:/opt/kde/lib/pkgconfig > [EMAIL PROTECTED]:/usr/bin# ls -l httpd > -rwxr-xr-x 1 root root 643348 2007-08-03 15:49 httpd* > [EMAIL PROTECTED]:/usr/bin# ls -l /usr/sbin/httpd > /bin/ls: /usr/sbin/httpd: No such file or directory > [EMAIL PROTECTED]:/usr/bin# whereis httpd > httpd: /usr/bin/httpd /usr/include/httpd.h /usr/man/man8/httpd.8 > /usr/share/man/man8/httpd.8 > [EMAIL PROTECTED]:/usr/bin# httpd -v > -bash: /usr/sbin/httpd: No such file or directory > [EMAIL PROTECTED]:/usr/bin# ./httpd -v > Server version: Apache/2.2.4 (Unix) > Server built: Aug 3 2007 15:46:58 > [EMAIL PROTECTED]:/usr/bin# sh > [EMAIL PROTECTED]:/usr/bin# httpd -v > Server version: Apache/2.2.4 (Unix) > Server built: Aug 3 2007 15:46:58 > [EMAIL PROTECTED]:/usr/bin# ls -l /usr/sbin/httpd > ls: /usr/sbin/httpd: No such file or directory > [EMAIL PROTECTED]:/usr/bin# env | grep SHELL > SHELL=/bin/bash > [EMAIL PROTECTED]:/usr/bin# /bin/bash --version > GNU bash, version 3.1.17(2)-release (i486-slackware-linux-gnu) > Copyright (C) 2005 Free Software Foundation, Inc. > [EMAIL PROTECTED]:/usr/bin#
Well, that's expected behaviour. bash remembers the full path name for commands executed. In this case it has remembered the location /usr/sbin/httpd for the httpd command. You're update has removed it, but bash doesn't know it's gone. The new shell you executed starts with an empty hash. You can use hash -r to force bash to forget it. Sven -- Sven Wegener Gentoo Developer http://www.gentoo.org/ _______________________________________________ Bug-bash mailing list Bug-bash@gnu.org http://lists.gnu.org/mailman/listinfo/bug-bash