What is the command for " how many shell is running in your
system or how many shell supported by your system " ?.

Answers were Sorted based on User's Feedback



What is the command for " how many shell is running in your system or how many shell supporte..

Answer / sandeep jaiswal

how many shell supported by your system

check the file /etc/shells

Is This Answer Correct ?    9 Yes 1 No

What is the command for " how many shell is running in your system or how many shell supporte..

Answer / joker

> ps -a |grep -E 'sh$' |wc -l

-a is for to list process of all users
-E extended grep to filter the shells (since they end with sh like bash, tcsh, ksh, sh
-$ to match only at the end of the line where the process is printed

Is This Answer Correct ?    0 Yes 1 No

What is the command for " how many shell is running in your system or how many shell supporte..

Answer / nayakss

ps| grep -E "*shh*" | wc -l

This gives the no of shell currently running.
Though this answer is correct but I don't think this is the
right approach.

Is This Answer Correct ?    0 Yes 3 No

Post New Answer

More Shell Script Interview Questions

Print a given number, in reverse order using a shell script such that the input is provided using command line argument only.

0 Answers  


How to calculate the number of passed arguments?

0 Answers  


How do you debug a script?

0 Answers  


Hi Friends, I am currently Undergoing Course On Testing.I am Planning To Keep Fake Resume.Can any One tell me the ways to Prepare i.e, Real Time experience For Manual Testing. With Regards, Vikram

1 Answers  


How can the contents of a file inside jar be read without extracting in a shell script?

0 Answers  






What is path variable bash?

0 Answers  


Differentiate between ‘ and ” quotes.

0 Answers  


How to rename all the files in a folder having specific extension? Example: I have some files with extension (.txt) in a folder name 'Test'. I have to rename all the .txt files in a test and its subdirectories to .my extension.

15 Answers   Interra IT,


What is Path variable?What is its use?

1 Answers  


What is the command to find out users on the system?

0 Answers  


What does $@ mean bash?

0 Answers  


What is shell and shell script?

0 Answers  


Categories