Vidyalelo
Computer Science · all questions

Linux
practice.

Practice every MCQ with options. Use Show answers when you want the correct option and solution.

996

Questions

28/50

Page

Pick an option on a question to see the right answer and solution.

The comparison expression "x ~ y" will true if

Select an option to see the answer and solution.

Which system call is used to create a hard link?

Select an option to see the answer and solution.

In Linux, the static libraries can be created by

Select an option to see the answer and solution.

Which command brings a background job into the foreground?

Select an option to see the answer and solution.

Which option of GCC compiler provides the linking with shared libraries?

Select an option to see the answer and solution.

Which is true with regards to the shell prompt

Select an option to see the answer and solution.

What is the length of of the queue for pending connections in this program?
#include<stdio.h>
#include<sys/types.h>
#include<sys/un.h>
#include<sys/socket.h>
 
int main()
{
    struct sockaddr_un add_server;
    int fd_server;
    fd_server = socket(AF_UNIX,SOCK_STREAM,0);
    if(fd_server == -1)
        perror("socket");
    add_server.sun_family = AF_UNIX;
    strcpy(add_server.sun_path,"server_sock2");
    if( bind(fd_server,(struct sockaddr*)&add_server,sizeof(add_server)) != 0)
        perror("bind");
    if( listen(fd_server,3) != 0)
        perror("listen");
    return 0;
}

Select an option to see the answer and solution.

Under UNIX the key board is the default input device and the monitor is the default output device

Select an option to see the answer and solution.

If our makefile is named as "example", then which one of the following command will compile the code with this makefile

Select an option to see the answer and solution.

Each device in the device driver model is represented by a . . . . . . . . object.

Select an option to see the answer and solution.

What is the output of this program?
#!/bin/bash
var1=10
$var1=20
echo $var1
exit 0

Select an option to see the answer and solution.

Command used to check shared memory is

Select an option to see the answer and solution.

If the umask value is 0002. what will be the permissions of new directory

Select an option to see the answer and solution.

Which of the following values for STAT column of ps command is not true:

Select an option to see the answer and solution.

Which of the following statement is FALSE ?

Select an option to see the answer and solution.

The structure which keeps the information about shared memory in the kernel is

Select an option to see the answer and solution.

The file /proc/swaps contains the

Select an option to see the answer and solution.

Preprocessed files are given the file extension . . . . . . . . for c++ programs.

Select an option to see the answer and solution.

Which one of the following is not true?

Select an option to see the answer and solution.

The redirection 2> abc implies

Select an option to see the answer and solution.