Thursday 25 October 2018

UNIX OBJECTIVE QUESTION FOR INTERVIEW AND PAPERS


1.       What command starts recording the users session activities?
a.       record
b.      script
c.       save
2.       What is the default prompt for Korn shell for root?
a.       #
b.      $
c.       %
3.       What command is used to change the priority of a process?
a.       nohup
b.      nice
c.       priority
4.        Which command changes the file permissions of files after their creation?
a.       chmod
b.      umask
c.       groups
5.       User secondary group’s information is stored in which file?
a.       /etc/shadow
b.      /etc/group
c.       /home/users
6.       A hard link cannot be made to a directory on different filesystem, but , you can make a hard link to a directory on the same filesystem.
a.       True
b.      False
7.       The cmp command is used to get information about what needs to be changed in files so that they become exactly same.
a.       True
b.      False

8.       Name the command used to eliminate duplicate rows from a file.
______________________________________
9.       The command cp f1 f2 f3 will copy the content of file f1 & f2 into file f3.
a.       True
b.      False
10.   Write a single command that will display all processes for user suresh.
_____________________________________
11.   Any user can change the system date
a.       True
b.      False
12.   The command to display and set terminal characteristics like intr and backspace key is
_____________________________________
13.   When you encrypt a file using crypt it encrypts the original file.
a.       False
b.      True
14.   User’s use this command to change their password.
a.       chgpass
b.      passwd
c.       newpass
15.   The command used to remove an empty directory is ______________
a.       rmdir
b.      rm –r
c.       deldir
16.   UNIX is a multiuser, but single tasking operating system
a.       true
b.      false
17.   UNIX is a multitasking, but single user operating system
a.       false
b.      true
18.   rm * would delete only a file named *, but would not delete any other file?
a.       true
b.      false
19.   Only file owners can move their files.
a.       true
b.      false
20.    When you move a file or rename a file using the mv command in the same filesystem, it will retain its inode number.
a.       true
b.      false
21.   Only the super user can encrypt a file using the crypt command?
a.       true
b.      false
22.   User’s are not allowed to work with multiple shells?
a.       false
b.      true
23.   The nice command is used to increase the priority of a process by ordinary users?
a.       true
b.      false
24.   The environment variable to display a users home directory is:
a.       $HOME
b.      $home
c.       home
25.   The default file used to record activities of a user session is _____________
26.   Which command will you use to look for a pattern in a file?
a.       wc
b.      grep
c.       find
27.   The encrypted passwords of users are stored here
a.       /etc/passwd
b.      /etc/password
c.       /etc/shadow
28.   The date command can be used by the system administrator to change the
a.       date
b.      time
c.       both
d.      none
29.    The default permissions for a directory after having a umask of 027 is
a.       rw-rw-rw
b.      rwxr-x---
c.       r-xr-xr-x
30.   The default permissions for a file with a umask of 022 is
a.       777
b.      644
c.       764

Friday 13 July 2018

UNIX objective question for beginner

1.       What command shows the current system time?
a.       Time
b.      date
c.       system
2.       What is the default prompt for Korn shell for ordinary users?
a.       $
b.      #
c.       %
3.       Which command determines the default permissions of files upon their creation time?
a.       chmod
b.      umask
c.       groups
4.       User login accounts are stored in which file?
a.       /etc/shadow
b.      /etc/passwd
c.       /home/users
5.       Two different files in the same file system can have same inode numbers.
a.       True
b.      False
6.       The cal command is used to calculate values of an arithmetic expression….
a.       True
b.      False
7.       Name the file used to customize your individual settings for vi.
________________________
8.       The command mv*.doc *.txt will rename all files ending in .doc to same filenames ending in .txt.
a.       True
b.      False
9.       Write a single command that will display the count of currently logged in users.
________________________
10.   Users can be members of multiple groups
a.       True
b.      False
11.   Which of the following commands displays the associated with your terminal?
a.       who
b.      tty
c.       ps
12.   User’s use this command to change their password.
a.       chgpass
b.      passwd
c.       newpass
13.   The command used to remove a directory including all files and subdirectories is _______
a.       rmdir
b.      rm  -r
c.       deldir
14.    UNIX is a multiuser operating system
a.       true
b.      false
15.   UNIX is a multitasking operating  system
a.       false
b.      true
16.   If an User forgets his password the superuser can lookup & give him his password back?
a.       true
b.      false
17.    Multiple Users can have the same common password
a.       true
b.      false
18.    rm * would delete all files in the current directory including hidden files?
a.       true
b.      false
19.   Only file owners can make a copy of their files.
a.       true
b.      false
20.   When you move a file or rename a file using the mv command the original file would no longer exist
a.       true
b.      false
21.   The login name of the super user is administrator
a.       true
b.      false


22.   UNIX does not support GUI environment?
a.       True
b.      False
23.   The command used to terminate a process is
a.       exit
b.      kill
c.       end
24.    User’s are not allowed to work with multiple shells?
a.       false
b.      true
25.   The command used to clear the terminal screen is
a.       cls
b.      erase
c.       clear
26.   Which command will you use to look for a pattern in a file?
a.       we
b.      grep
c.       find
27.   The encrypted passwords of users are stored here
a.       /etc/passwd
b.      /etc/password
c.       /etc/shadow
d.      /home/user/password
28.   The default permissions for a directory is
a.       rw-rw-rw-
b.      rwxrwxrwx
c.       r-xr-xr-x
29.   The default permissions for a file is
a.       777
b.      666
c.       764
30.   The command used to terminate a shell is
a.       exit
b.      kill
c.       end


UNIX OBJECTIVE QUESTION FOR INTERVIEW AND PAPERS

1.        What command starts recording the users session activities? a.        record b.       script c.        save 2.       ...