Sign up ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

I'm going through a shell script coded by some old folks working on my current project. At the end of a file, it simple have the folder/file paths like,


at the end of file. When these lines are executing, it throws line 22: /home/udhay-dev/work/udhay/bin/rm-vhosts: Is a directory line 23: /home/udhay-dev/work/udhay/bin/vhosts: Permission denied line 24: /home/udhay-dev/work/udhay/bin/apache: Is a directory

But i don't have any idea on these since i'm almost new to both Ubuntu and Shell script. What would be the reason or purpose for simply having those lines in a shell script? Please help.

share|improve this question

1 Answer 1 line 22: /home/udhay-dev/work/udhay/bin/rm-vhosts: Is a directory

Shows there is directory named rm-vhosts inside /home/udhay-dev/work/udhay/bin directory. line 23: /home/udhay-dev/work/udhay/bin/vhosts: Permission denied

Shows there is file named vhosts inside /home/udhay-dev/work/udhay/bin directory. line 24: /home/udhay-dev/work/udhay/bin/apache: Is a directory

Shows there is directory named apache inside /home/udhay-dev/work/udhay/bin directory. is the script name.line xx means the line number in the script which throws the above message.

share|improve this answer
What would be the reason for simply having those lines? – Udhay May 7 '14 at 9:42
just to say, it's a directory. But there is no use of having these lines on the script. – Avinash Raj May 7 '14 at 9:46
My guess is that the developer put those lines there in order to easily copy-and-paste them, but forgot to remove them. – Jos May 7 '14 at 10:09
@Udhay typically that is the result of treating the directory as a command and then attempting to run it. Why did the script try to run a directory as a command is another question, usually that'd be due to a mistake in the script. – Mahn Dec 16 '14 at 21:46

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.