I’ve got some problem about bash.
Before today, my VPS (Ubuntu 12.04 LTS) was using kernel 2.x. (Because it was upgraded from 11.04 and the boot options did not get updated.)
Today I want to use kernel 3.2 as the default kernel.
After modifying the grub config, I’ve successfully booted the VPS up in kernel 3.2. Using uname -r will show 3.2.0-24-generic instead of 2.x.y-z-generic now.
However, something wonky happened and I don’t why.
Before the kernel change, if I type some unkown command, the shell will prompt me to use apt-get to install it. For example, I don’t have bind9 installed, and when I try to run named, I will be prompted like this:
wzyboy@vermilion:~$ named The program 'named' is currently not installed. You can install it by typing: sudo apt-get install bind9
Sometimes when I make a typo, I will be corrected (“did you mean”):
wzyboy@vermilion:~$ namedd No command 'namedd' found, did you mean: Command 'named' from package 'bind9' (main) namedd: command not found
However, after the kernel change, when I try to run named, the shell simply says:
wzyboy@natatio:/$ named -bash: named: command not found
I think it may be something wrong with bash, but I don’t know how to fix the problem. Can anybody help?
[SOLVED] Thanks! After installing command-not-found package, the problem is solved. However, I still don’t why the package got lost after changing the kernel…
To enable those auto suggestions you need to ensure that you have command-not-found installed. It is usually automatically enabled via /etc/bash.bashrc if installed correctly.