Gerald Waugh wrote:
> 
> On Sunday 10 March 2002 10:23 pm, you wrote:
> > Hey everyone, this question is probably very simple to answer but as
> > a newbie it's not easy. =)
> >
> > As root I must enter "./" (dot-slash) in front of any command or app
> > i want to execute from the shell. However, as a "regular" user, I don't
> > have to. I looked into my .bashrc but I cannot see a line of script that
> > does that. I'd like to know where that line is so i can set it up for
> > my root account too.
> >
> 
> You have to use ./ only when you are trying to execute an executable file in
> the current directory,
> And it is for everyone, root and user.
> 
> --
> Gerald Waugh
> 
>   --------------------------------------------------------------------------------
> Want to buy your Pack or Services from MandrakeSoft?
> Go to http://www.mandrakestore.com

The need to do this is dependant on your PATH variable. You may find the PATH
for root is set different to the PATH for users.

Check it out with "echo $PATH". All the various path options are separated by a
colon (:). If there is a single period, full stop, dot or whatever ya call it
(.) then you do not need to run a program like so "./runme".

The bad news is this is a security risk and is frowned upon in linux circles.
Lets say someone gets your password and writes a script called ls that reads "rm
-fr *". you come along and innocently run ls and zap everything in your
directory. As root the script could read "rm -fr /*". Then Femme AKA Heather
would be instructing you on reinstalling ;o)

The option may have been set by the "sec" level you are running. But you can
also alter it in your ".bashrc" file. I do recommend gettting used to using
dot-slash both as root AND user.

Hope that helps.
Michael

-- 
An authority is a person who can tell you more about something than you
really care to know.

Want to buy your Pack or Services from MandrakeSoft? 
Go to http://www.mandrakestore.com

Reply via email to