Try echoing the line to see exactly what command the shell is trying to run:
echo rpm -ihv $RPMS/caching-nameserver*
It looks to me like the RPMS variable is turning up as empty. Note how the error message doesn't have a prefix attached.
When the shell does globbing, it first tries to match the given pattern with any existing filenames and, if any are found, replaces the string with them. If it doesn't find anything, then it passes the string literally to the command.
In this case, the string "/caching-nameserver*" means the shell is looking for filenames beginning with that string, like "/caching-nameserver-foo", isn't finding anything like that, and giving the literal string to rpm, which errors out on it.
This is probably mostly because the variable isn't being set properly. But also, is "caching-nameserver" part of the filenames you want to match, or is it a directory name? Perhaps you want to use "cashing-nameserver/*" instead?
It may help more if you can give us some more background on what you're trying to accomplish.
Can you show us the exact series of commands you're trying to run here? And the commands you actually want it to run? It should be something like this:
rpm -ihv $RPMS/caching-nameserver/*
(Notice, I made an error in my last post, which I've corrected above.)
Finally, please use [code][/code] tags around any code you post, to preserve formatting and to improve readability.
Edit: actually, I'm wondering now--I doubt very much that you can do globbing like this. Globbing is done by the shell, which only does local file-tree matching and string substitution. The ftp lookup is done by rpm, after the globbing is completed. So trying to use "*" to match multiple files is probably no good, unless rpm has it's own ability to glob over ftp.