[gutsy] command-not-found not found

Bug #135794 reported by wateenellende
12
Affects Status Importance Assigned to Milestone
command-not-found (Ubuntu)
Fix Released
High
Unassigned

Bug Description

Binary package hint: command-not-found

This is just too funny:

$ alien
bash: /usr/bin/command-not-found: No such file or directory
bash: alien: command not found

version:
$ dpkg -s bash
Package: bash
Essential: yes
Status: install ok installed
Priority: required
Section: shells
Installed-Size: 2028
Maintainer: Ubuntu Core developers <email address hidden>
Architecture: amd64
Version: 3.2-0ubuntu9
Replaces: bash-doc (<= 2.05-1), bash-completion
Depends: base-files (>= 2.1.12), debianutils (>= 2.15)
Pre-Depends: libc6 (>= 2.6-1), libncurses5 (>= 5.6)
Suggests: bash-doc
Conflicts: bash-completion
Conffiles:
 /etc/skel/.bashrc 52acca91b52f797661c89b181809b9f3
 /etc/skel/.profile 7d97942254c076a2ea5ea72180266420
 /etc/skel/.bash_logout 22bfb8c1dd94b5f3813a2b25da67463f
 /etc/bash.bashrc 0a22bcf91612bad30b41c04eaa8870df
 /etc/bash_completion c8bce25ea68fb0312579a421df99955c
Description: The GNU Bourne Again SHell
 Bash is an sh-compatible command language interpreter that executes
 commands read from the standard input or from a file. Bash also
 incorporates useful features from the Korn and C shells (ksh and csh).
 .
 Bash is ultimately intended to be a conformant implementation of the
 IEEE POSIX Shell and Tools specification (IEEE Working Group 1003.2).
 .
 Included in the bash package is the Programmable Completion Code, by
 Ian Macdonald.
Original-Maintainer: Matthias Klose <email address hidden>

$ dpkg -s command-not-found
Package: command-not-found
Status: install ok installed
Priority: optional
Section: admin
Installed-Size: 96
Maintainer: Michael Vogt <email address hidden>
Architecture: all
Version: 0.2.7
Depends: python, python-central (>= 0.5.8), command-not-found-data
Conffiles:
 /etc/zsh_command_not_found faf757f575b50bc3e4801899c68f272b
 /etc/bash_command_not_found e6f56e9685e3e979ebd3d3b8623f93d6 obsolete
Description: Suggest installation of packages in interactive bash sessions
 This package will install handler for command_not_found that lookups
 programs not currently installed but available from the repositiories.
Original-Maintainer: Zygmunt Krynicki <email address hidden>
Python-Version: current

Revision history for this message
topdog (andrew-topdog-software) wrote :

Bash expects the it to be at this location /usr/bin/command-not-found The new package is installing it in the wrong location /usr/lib/command-not-found.

root@andrew:~# dpkg -L command-not-found
/.
/usr
/usr/share
/usr/share/doc
/usr/share/doc/command-not-found
/usr/share/doc/command-not-found/README
/usr/share/doc/command-not-found/copyright
/usr/share/doc/command-not-found/changelog.gz
/usr/share/pycentral
/usr/share/pycentral/command-not-found
/usr/share/pycentral/command-not-found/site-packages
/usr/share/pycentral/command-not-found/site-packages/CommandNotFound
/usr/share/pycentral/command-not-found/site-packages/CommandNotFound/CommandNotFound.py
/usr/share/pycentral/command-not-found/site-packages/CommandNotFound/__init__.py
/usr/share/pycentral/command-not-found/site-packages/command_not_found-0.1.egg-info
/usr/lib
/usr/lib/command-not-found
/etc
/etc/zsh_command_not_found
/etc/bash_command_not_found

Either the /etc/bash.bashrc has to be fixed our possible a simlink between the two locations needs to be created.

Revision history for this message
wateenellende (fpbeekhof) wrote : Re: [Bug 135794] Re: [gutsy] command-not-found not found

topdog wrote:
> Bash expects the it to be at this location /usr/bin/command-not-found
> The new package is installing it in the wrong location /usr/lib/command-
> not-found.

It is, IMHO, not in the wrong location. AFAIK, binaries in /usr/bin/ are
meant for users and binaries in /usr/lib are for "internal" usage. So,
it is in the right place because users are not supposed to call
command-not-found themselves.

> Either the /etc/bash.bashrc has to be fixed our possible a simlink
> between the two locations needs to be created.

If my previous comment is indeed correct, fixing /etc/bash.bashrc seems
to be the right choice.

Revision history for this message
Zygmunt Krynicki (zyga) wrote :

Promoting to high as it makes c-n-f not usable with current releases.

This bug can be fixed by either patching bash: /etc/bash.bashrc to point to the new location of command-not-found OR by patching command-not-found to include a symlink that will be deprecated with future releases.

Changed in command-not-found:
importance: Undecided → High
status: New → Confirmed
Revision history for this message
Zygmunt Krynicki (zyga) wrote :

Changed package to bash

Revision history for this message
RW Penney (rwpenney) wrote :

Can this bug be marked as resolved?

Package bash-3.2-0ubuntu11, as used in xubuntu7.10, appears to correctly reference /usr/lib/command-not-found in /etc/bash.bashrc.

Revision history for this message
wateenellende (fpbeekhof) wrote :

Yes, we can mark it as resolved. I just don't know how to do that :-)

On Nov 17, 2007 10:20 PM, RW Penney <email address hidden> wrote:
> Can this bug be marked as resolved?
>
> Package bash-3.2-0ubuntu11, as used in xubuntu7.10, appears to correctly
> reference /usr/lib/command-not-found in /etc/bash.bashrc.
>
> --
> [gutsy] command-not-found not found
> https://bugs.launchpad.net/bugs/135794
> You received this bug notification because you are a direct subscriber
> of the bug.
>

Revision history for this message
Zygmunt Krynicki (zyga) wrote :

Seems to be fixed according to the comments

Changed in command-not-found:
status: Confirmed → Fix Released
Revision history for this message
Seth Hasani (sepheebear) wrote :

The README file needs to be updated for this package:

$ less /usr/share/doc/command-not-found/README
...
To use it in bash, please add the following line to your .bashrc file:
. /etc/bash_command_not_found
...

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.