Category Archives: Shell Scripting Interview Questions

What is local variable? | Shell Scripting Questions

A local variable is a variable that is present within the current instance of the shell. It is not available to programs that are started by the shell. The variables that you looked at previously have all been local variables.

Posted in Shell Scripting Interview Questions | Leave a comment

What is noninteractive mode? | Shell Scripting Questions

In this mode, the shell does not interact with you; instead it reads commands stored in a file and executes them. When it reaches the end of the file, the shell exits.

Posted in Shell Scripting Interview Questions | Leave a comment

What is Interactive mode? | Shell Scripting Questions

Interactive mode means that the shell expects to read input from you and execute the commands that you specify. This mode is called interactive because the shell is interacting with a user. This is usually the mode of the shell … Continue reading

Posted in Shell Scripting Interview Questions | Leave a comment

What are the two files used by the shell to initialize itself? | Shell Scripting Questions

/etc/profile profile

Posted in Shell Scripting Interview Questions | Leave a comment

Explain “read” command ? | Shell Scripting Questions

The read command is one of the most important ways to get information into a shell program: $ x=abc ; printf “x is now ‘%s’. Enter new value: ” $x ; read x x is now ‘abc’. Enter new value: … Continue reading

Posted in Shell Scripting Interview Questions | Leave a comment

Name a new feature introduced with PHP 5. | Shell Scripting Questions

PHP 5 introduces (among other things) SQLite support, improved XML support, and a significantly improved object model.

Posted in Shell Scripting Interview Questions | Leave a comment

What is “grep” programe ? | Shell Scripting Questions

The grep program is the primary tool for extracting interesting lines of text from input datafiles. POSIX mandates a single version with different options to provide the behavior traditionally obtained from the three grep variants: grep, egrep, and fgrep.

Posted in Shell Scripting Interview Questions | Leave a comment

What is awk ? | Shell Scripting Questions

An awk invocation can define variables, supply the program, and name the input files.

Posted in Shell Scripting Interview Questions | Leave a comment

What is ” eval” command ? | Shell Scripting Questions

The eval command exists to supersede the normal command-line substitution and evaluation order, making it possible for a shell script to build up commands dynamically. This is a powerful facility, but it must be used carefully. Because the shell does … Continue reading

Posted in Shell Scripting Interview Questions | Leave a comment

What is “Command Substitution” ? | Shell Scripting Questions

Command substitution is the process by which the shell runs a command and replaces the command substitution with the output of the executed command. That sounds like a mouthful, but it’s pretty straightforward in practice.

Posted in Shell Scripting Interview Questions | Leave a comment