Linux wiki

Why Won't a Program Work in the Current Directory?

Because the current directory (i.e., .) is not in the search path, for security reasons, as well as to insure that the correct program versions are used. If an intruder is able to write a file to a world-writable directory, like /tmp, presumably he or she would be able to execute it if the directory were in the search path. The solution to this is to include the directory in the command; e.g., ./myprog, instead of myprog. Or add the current directory to your PATH environment variable; e.g., export PATH=".:"$PATH using bash, although this is discouraged for the reasons mentioned above.

How To Determine What Packages Are Installed on a System
How To Email Someone about Your Problem

 

 

 

See our index for more reviews

Write a review and win an Apple Ipod

Page

New
Edit
Rename
Attachments
Versions

Site

Changes
Index
Search

User

Log In

 
 

Last Modified 2004-07-03