This is normal behavior. Look in your environment ("env") for a variable
called PATH. It sets the order of directories that the bash shell will
search ehen looking for an executable. Normally, the directory you are in
(designated ./) is not part of that search PATH (at least for root; user
accounts don't seem to follow a standard in this respect).

It's more or less a security feature. If you are root, go into someone's
home directory, and execute (say) "ls", you want to be sure that what will
execute is the real /bin/ls program, not the script ./ls that does (to
choose a particularly nasty example) "rm -r /".

BTW, it's bad practice to convert directories, program names, etc., to upper
case. For example, I doubt you "have an executable in /USR/LOCAL/SBIN called
TCPDUMP". You are much more likely to have an executable in /usr/local/bin
called tcpdump .

In this instance, it didn't actually confuse. But since Unix/Linux commands
(unlike MSDOS commands) are case sensitive, it's a good habit not to change
the case of commands, directory names, and so on, when you are asking
questions about them. 

Had you, for example, merely reported that the command "TCPDUMP" didn't work
and asked why, without mentioning that "./TCPDUMP" did work, I would have
explained that the correct command is "tcpdump".

At 02:10 PM 7/10/00 -0500, Brian Burns wrote:
>Thanks to all who contribute to this list for us "newbies" to Linux.
Hopefully I can contribute back one day.
>
>Here is the scenario:
>
>I have an executable in /USR/LOCAL/SBIN called TCPDUMP.
>
>When I am in the dir in a shell logged in as ROOT, I can only execute the
program by typing ./TCPDUMP instead of just TCPDUMP. The same goes for perl
scripts.
>
>Am I missing something here or is this normal behavior?
[html repeat deleted]


--
------------------------------------"Never tell me the odds!"---
Ray Olszewski                                        -- Han Solo
Palo Alto, CA                                    [EMAIL PROTECTED]        
----------------------------------------------------------------


-
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.linux-learn.org/faqs

Reply via email to