Explore topic-wise InterviewSolutions in .

This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.

1.

What Command Should You Use To Check The Number Of Files And Disk Space Used By Each User’s Defined Quotas?

Answer»

The command ‘repquota’ comes to rescue here. Command repquota summaries quotas for a FILE SYSTEM.

That’s all for now. Provide your VALUABLE Feedback in our comment section. Stay TUNED for more LINUX and Foss posts.

The command ‘repquota’ comes to rescue here. Command repquota summaries quotas for a file system.

That’s all for now. Provide your valuable Feedback in our comment section. Stay tuned for more Linux and Foss posts.

2.

How To Know A Command Summary And Usability In Linux? Assume You Came Across A Command In /bin Directory, Which You Are Completely Unaware Of, And Have No Idea What It Does. What Will You Do To Know Its Usability?

Answer»

he COMMAND ‘whats’ display a summary of it's usability from the MAN page. For EXAMPLE, you would like to see a summary of ‘zcat’ command which you don’t KNOW previously.

[root@localhost ~]# whats zcat

zcat [gzip] (1) - COMPRESS or expand files

he command ‘whats’ display a summary of it's usability from the man page. For example, you would like to see a summary of ‘zcat’ command which you don’t know previously.

[root@localhost ~]# whats zcat

zcat [gzip] (1) - compress or expand files

3.

Who Own The Data Dictionary?

Answer»

The user's ‘SYS’ owns the data dictionary. USERS ‘SYS’ and 'SYSTEM' are CREATED by default, AUTOMATICALLY.

The user's ‘SYS’ owns the data dictionary. Users ‘SYS’ and 'SYSTEM' are created by default, automatically.

4.

You Have A Large Text File, And You Need To See One Page At A Time. What Will You Do?

Answer»

You can ACHIEVE the above RESULT by PIPELINE the output of ‘cat file_name.txt’ with ‘more’ COMMAND.

[ROOT@localhost ~]# cat file_name.txt | more

You can achieve the above result by pipeline the output of ‘cat file_name.txt’ with ‘more’ command.

[root@localhost ~]# cat file_name.txt | more

5.

Which Builtin Linux Command Performs Arithmetic Operation Of Integers In Bash?

Answer»

The ‘LET’ command that performs arithmetic OPERATION of INTEGER in bash SHELL.

#! /bin/bash

...

...

let c=a+b

...

...

The ‘let’ command that performs arithmetic operation of integer in bash shell.

#! /bin/bash

...

...

let c=a+b

...

...

6.

What Does The Command ‘hash’ Is Used For In Bash Shell?

Answer»

Linux command ‘hash’ manages internal hash table, FINS and remember FULL PATH of the specified command, Display used command NAMES and number of times the command is used.

[root@localhost ~]# hash

HITS command

2 /bin/ls

2 /bin/su

Linux command ‘hash’ manages internal hash table, fins and remember full path of the specified command, Display used command names and number of times the command is used.

[root@localhost ~]# hash

hits command

2 /bin/ls

2 /bin/su

7.

You Have Lots Of Running Jobs, How Would You Remove All The Running Processes, Without Restarting The Machine?

Answer»

The LINUX command ‘DISOWN -R’ will remove all the running Processes.

The Linux command ‘disown -r’ will remove all the running Processes.

8.

Your Assistant Needs To Print Directory Stack, What Would You Suggest?

Answer»

The LINUX command ‘DIRS’ will print the DIRECTORY stack.

[ROOT@localhost ~]# dirs

/usr/share/X11

The Linux command ‘dirs’ will print the directory stack.

[root@localhost ~]# dirs

/usr/share/X11

9.

A User Is New To Linux And He Wants To Know Full List Of Available Commands, What Would You Suggest Him?

Answer»

A command ‘compgen ­c’ will show a FULL LIST of AVAILABLE commands.

[root@localhost ~]$ Compgen -c

l.

ll

ls

which

if

then

else

elif

fi

case

esac

for

SELECT

while

until

do

done

...

A command ‘compgen ­c’ will show a full list of available commands.

[root@localhost ~]$ Compgen -c

l.

ll

ls

which

if

then

else

elif

fi

case

esac

for

select

while

until

do

done

...

10.

You Need To Define A Macro, A Key Binding For The Existing Command. How Would You Do It?

Answer»

There is a command called BIND, in bash shell which is CAPABLE of defining macro, or binding a KEY. In order to bind a key with an existing command, we need to generate Character Sequence emitted by the key. Press Ctrl+v and then key F12, I got ^ [[24~

[root@localhost ~]# bind '"e[24~":"date"'

DIFFERENT types of TERMINALS or terminal emulators can emit different codes for the same key.

There is a command called bind, in bash shell which is capable of defining macro, or binding a key. In order to bind a key with an existing command, we need to generate Character Sequence emitted by the key. Press Ctrl+v and then key F12, I got ^ [[24~

[root@localhost ~]# bind '"e[24~":"date"'

Different types of terminals or terminal emulators can emit different codes for the same key.