Linux and Unix System Administrator

20+ Linux and Unix System Administrator Interview Questions and Answers

Updated 31 Aug 2022

Q1. How to check that all port are connected to your computers and power supply or system configuration ?

Ans.

To check all connected ports and power supply, use commands like lsusb, lspci, lshw, and check power cables and system configuration.

  • Use lsusb command to list USB devices connected to the computer

  • Use lspci command to list PCI devices connected to the computer

  • Use lshw command to list detailed hardware information

  • Physically check power cables and connections

  • Verify system configuration settings

Q2. How to check data set & mount point information in human readable format ?

Ans.

To check data set & mount point info in human readable format, use the 'df' command.

  • Open the terminal and type 'df -h' to display the information in human-readable format.

  • The 'df' command shows the file system disk space usage, including the mount point and file system type.

  • The '-h' option displays the sizes in a human-readable format, such as 'K' for kilobytes, 'M' for megabytes, and 'G' for gigabytes.

  • You can also use the 'mount' command to display the mounted file systems a...read more

Q3. How recover a user file deleted or file /etc/passwd ?

Ans.

To recover a deleted user file or /etc/passwd, restore from backup or use data recovery tools.

  • Check if a backup of the file exists and restore it

  • If no backup is available, use data recovery tools like extundelete or scalpel

  • Stop writing to the disk immediately to prevent overwriting the deleted file

  • Consult with a professional if necessary

Q4. How to check a user password status for any users ?

Ans.

To check a user password status, use the 'passwd' command with the '-S' option followed by the username.

  • Open the terminal or command prompt.

  • Type 'passwd -S ' and press Enter.

  • The password status will be displayed, indicating if the password is locked, expired, or active.

Are these interview questions helpful?

Q5. How we can check groups lists & assinged users to them ?

Ans.

To check group lists and assigned users, we can use the 'getent' command in Linux and Unix systems.

  • Use the 'getent group' command to list all the groups and their details

  • To check the users assigned to a specific group, use 'getent group '

  • The output will display the group name, group ID, and a list of users assigned to the group

Q6. how can we create a mirror pool & what does it require for ?

Ans.

A mirror pool is a storage configuration that duplicates data across multiple drives for redundancy and improved performance.

  • A mirror pool is created using software RAID (Redundant Array of Independent Disks) technology.

  • It requires at least two drives to create a mirror pool.

  • The data written to one drive is automatically duplicated to the other drive in real-time.

  • If one drive fails, the data can still be accessed from the remaining drive.

  • Creating a mirror pool provides data r...read more

Share interview questions and help millions of jobseekers 🌟

man-with-laptop

Q7. How we can check all information destroy pool & get back them ?

Ans.

To check all information destroy pool & get back them, we can use ZFS snapshots and clones.

  • ZFS snapshots and clones can be used to recover data from a destroyed pool.

  • Snapshots capture the state of the pool at a specific point in time.

  • Clones can be created from snapshots and mounted as a separate file system.

  • Data can be copied from the clone to the new pool.

  • It is important to regularly create snapshots to ensure data can be recovered in case of a disaster.

Q8. How can we attach &detach disk from a normal and mirror pool ?

Ans.

To attach & detach disk from normal and mirror pool, use zpool attach and zpool detach commands.

  • To attach a disk to a normal pool, use 'zpool attach poolname existing_device new_device'

  • To detach a disk from a normal pool, use 'zpool detach poolname device'

  • To attach a disk to a mirror pool, use 'zpool attach poolname existing_device mirror_device'

  • To detach a disk from a mirror pool, use 'zpool detach poolname mirror_device'

Linux and Unix System Administrator Jobs

0

Q9. How to know that in which directory we are sitting presently ?

Ans.

To know the current directory in Linux/Unix, use the 'pwd' command.

  • Type 'pwd' in the terminal and press enter.

  • The output will show the full path of the current directory.

  • Alternatively, you can use 'echo $PWD' to display the current directory path.

  • The command 'ls' can also be used to list the contents of the current directory.

Q10. How we scan a LUN & check the wwn number ?

Ans.

To scan a LUN and check the wwn number, use the 'multipath' command.

  • Run 'multipath -ll' to list all the available LUNs and their wwn numbers.

  • To scan for new LUNs, run 'echo '- - -' > /sys/class/scsi_host/hostX/scan' (replace X with the appropriate host number).

  • Use 'multipath -v3' for verbose output and troubleshooting.

  • Ensure that the necessary drivers and modules are loaded for the storage device.

  • Check the system logs for any errors or warnings related to the LUN or storage d...read more

Q11. How to secure our system security user mangement ?

Ans.

To secure system security user management, follow best practices such as strong passwords, regular audits, limited privileges, and multi-factor authentication.

  • Enforce strong password policies

  • Regularly audit user accounts and access permissions

  • Implement least privilege principle

  • Enable multi-factor authentication

  • Disable unnecessary user accounts

  • Regularly update and patch the system

  • Implement intrusion detection and prevention systems

  • Encrypt sensitive data

  • Monitor system logs for ...read more

Q12. Can we modify user password and name ?

Ans.

Yes, as a Linux and Unix System Administrator, you can modify user passwords and names.

  • To modify a user's password, you can use the 'passwd' command followed by the username.

  • To modify a user's name, you can use the 'usermod' command followed by the username and the '-l' option to change the login name.

  • Make sure to have the necessary permissions to modify user information.

Q13. Tell all process of patch management by stepwise ?

Ans.

Patch management process involves identifying, testing, deploying, and verifying patches.

  • Identify vulnerabilities and available patches

  • Test patches in a non-production environment

  • Deploy patches to production systems

  • Verify successful patch installation and functionality

  • Monitor for any issues or new vulnerabilities

  • Repeat the process regularly

  • Use automation tools for efficiency

Q14. How to activate Boot Environment back up ?

Ans.

To activate Boot Environment back up, use the beadm command.

  • Use the beadm command with the activate option followed by the name of the Boot Environment.

  • For example, to activate the Boot Environment named 'BE1', use the command 'beadm activate BE1'.

  • This will make the Boot Environment the default one at the next system reboot.

Q15. How to switch a user ?

Ans.

To switch a user in Linux or Unix, use the 'su' command followed by the username.

  • Open the terminal

  • Type 'su' followed by the username of the user you want to switch to

  • Enter the password of the user when prompted

  • You will be switched to the specified user

Q16. How many run level are in Saloris and Linux

Ans.

Saloris does not exist. Linux has 7 run levels.

  • Saloris is not a known operating system

  • Linux has 7 run levels numbered from 0 to 6

  • Each run level has a specific set of services and daemons that are started or stopped

  • Run level 0 is used for system halt

  • Run level 1 is used for single user mode

  • Run level 2 is used for multi-user mode without networking

  • Run level 3 is used for multi-user mode with networking

  • Run level 4 is not used by default but can be customized

  • Run level 5 is used fo...read more

Q17. How can we check all disk information ?

Ans.

To check all disk information in Linux and Unix systems, you can use the 'df' command.

  • Use the 'df' command to display disk space usage information

  • Add the '-h' option to display sizes in a more human-readable format

  • Use the '-T' option to display the filesystem type

  • Use the '-i' option to display inode information

  • Combine options as needed to get the desired output

Q18. How to replace a disk from pool ?

Ans.

To replace a disk from a pool, you need to remove the faulty disk and add a new disk to the pool.

  • Identify the faulty disk using disk monitoring tools or error messages

  • Remove the faulty disk from the pool using the appropriate command or tool

  • Physically replace the faulty disk with a new disk

  • Add the new disk to the pool using the appropriate command or tool

  • Verify the disk replacement and ensure data integrity

Q19. How we check all zpool status ?

Ans.

To check all zpool status, use the 'zpool status' command.

  • Open the terminal or command prompt.

  • Type 'zpool status' and press Enter.

  • The command will display the status of all zpools on the system.

  • You can also use additional options like '-v' for more detailed information.

Q20. How to destroy a pool ?

Ans.

To destroy a pool in Linux or Unix, use the 'zpool destroy' command.

  • Open the terminal or command prompt.

  • Use the 'zpool destroy' command followed by the name of the pool to be destroyed.

  • Confirm the destruction by typing 'y' or 'yes' when prompted.

  • The pool and all its associated data will be permanently deleted.

Q21. How we reboot system ?

Ans.

To reboot a system, use the 'reboot' command or the 'shutdown' command with the '-r' option.

  • Use the 'reboot' command to immediately reboot the system

  • Use the 'shutdown -r' command to schedule a reboot at a specific time

  • Ensure you have the necessary permissions to reboot the system

Q22. #pwd for present working direcory.

Ans.

The command to display the present working directory in Linux/Unix is 'pwd'.

  • The 'pwd' command stands for 'print working directory'.

  • It displays the absolute path of the current working directory.

  • The output of 'pwd' does not contain any trailing slashes.

Interview Tips & Stories
Ace your next interview with expert advice and inspiring stories

Interview experiences of popular companies

4.0
 • 2.4k Interviews
View all

Calculate your in-hand salary

Confused about how your in-hand salary is calculated? Enter your annual salary (CTC) and get your in-hand salary

Linux and Unix System Administrator Interview Questions
Share an Interview
Stay ahead in your career. Get AmbitionBox app
qr-code
Helping over 1 Crore job seekers every month in choosing their right fit company
65 L+

Reviews

4 L+

Interviews

4 Cr+

Salaries

1 Cr+

Users/Month

Contribute to help millions

Made with ❤️ in India. Trademarks belong to their respective owners. All rights reserved © 2024 Info Edge (India) Ltd.

Follow us
  • Youtube
  • Instagram
  • LinkedIn
  • Facebook
  • Twitter