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
Answer / sandeep jaiswal
how many shell supported by your system
check the file /etc/shells
Is This Answer Correct ? | 9 Yes | 1 No |
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 |
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 |
what are special characters and explain how does text varies by the usage of single quotes,double quotes and back quotes?
What is awk in shell script?
write a shell script to emulate the Id command of PRIMOS which lists files and directories. It list files first with a header FILES and then directories with a header DIRECTORIES. This command has several options. The main ones are. -file select files only -dir select directories only -reverse sort in reverse order -no_header put no header on the output -brief output the header only -size display the size of each file -help display Id´s syntax and options.
How many prompts are available in a UNIX system?
write a scwipt that a) takes exactly one argument, a directory name. b) if the number of argument is more or less than one,print a usage message c) if the argument is not adirectory, print another message d) for the given directory, print the five biggest files and the five files that were most recently modified. e) save the output to a file called q2output.
What is in a script?
write a shell script to generate a alert ? like when ur birthday came then generate a alert ur birthday is today like that ?
What is echo in shell?
There is a record with fields namely name,roll no.,salary,grade etc.Now,write a script to create a file with multiple records have same combination of fields but with unique roll numbers.The script should work for different names in the input file.
How many fields are present in a crontab file and what does each field specify?
What is another name for a bash shell script that you might see?
How to modify the PATH variable and make it executable?