Visit Our UNIX and Linux User Community


Cd


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Cd
# 1  
Old 10-02-2001
Error Cd

why is 'cd' a shell built in and not an executable?

Last edited by clickonline1; 10-02-2001 at 05:31 PM..
# 2  
Old 10-02-2001
It IS and executable - /usr/bin/cd

Why did you think it was a shell built-in?
# 3  
Old 10-02-2001
cd doesnt exist in the bin

It doesnt exist in the bin....

Unix gives a message....

"cd is a shell built in"
# 4  
Old 10-02-2001
What exactly gives you that message?
What flavor/version of UNIX?
Are you looking in /usr/bin ?
What shell are you using?

What does "man cd" say?
What does "which cd" say?
What does "whereis cd" say?
What does "find / -name cd -print" say?
# 5  
Old 10-02-2001
Red Hat Linux 7.1

I used the command:

type -all cd

Smilie
# 6  
Old 10-02-2001
What answers do you have for the other 6 questions?
# 7  
Old 10-03-2001
In many modern shells (bash, ksh), cd is actually a builtin. I believe that the reason for this, is that it executed much faster that calling an outside application for such a simple command. Some systems may have the binary available, although I'm not sure if that's for backwards-compatibility or not...
 

Previous Thread | Next Thread
Test Your Knowledge in Computers #282
Difficulty: Easy
Time-sharing operating systems schedule tasks for efficient use of the system and may also include accounting software for cost allocation of processor time, mass storage, printing, and other resources.
True or False?

Featured Tech Videos