Interview Questions
  UNIX Shell Scripting

The following are the most likely basic interview questions that are asked by the interviewers. If you are going to be a UNIX Administrator, UNIX support personnel, Data Warehouse Developer on UNIX/LINUX platform, Oracle or Sybase Developer, or even a Database Administrator, You must know the answers to the following questions before appearing for an interview.


Interview Questions:

  1. Which Shells are available or installed on your system
  2. Which file gets executed first when a user logs in
  3. Display total number of users currently logged on. Do not display the list of users, Display the number only
  4. Write a shell script to print "High Load" if more than 100 user are logged on to the system.
  5. List the size of all files in /etc directory only of the size is more than 10MB
  6. List the owner and the name of all files in /tmp directory and its sub-directories if the file permission is 777
  7. Mention at least 2 differences between hard link and soft link
  8. How many Oracle databases are currently running on the server
  9. Which users have been assigned a bash as a login shell to them
  10. List of users who have more that 5 sessions opened.
  11. Move all files owned by user john under /home directory to /tmp. Move only those files whose size is more than 100MB
  12. Configure your account in such a way that your home directory is automatically backup-ed up to /backup directory every time you logout.
  13. Write a shell script to send an email to root if any filesystem is more than 80% full.
  14. List out a PID, owner and the name of the process which is taking the highest amount of CPU.
  15. List out a PID, owner and the name of the process which is taking the highest amount of RAM
  16. How to start a job in background
  17. How to bring a background job to foreground
  18. How do you assign an output of a command to a variable
  19. How to perform mathematical calculations in shell script usning bc
  20. How to debug a shell script
  21. How to read a file one line at a time
  22. How to read a file one word at a time
  23. How do you check if a command has been successfully completed or not
  24. Write a while loop to print odd numbers.
  25. How to automate the file transfer from one machine to another
  26. What is the difference between kill -9 and kill commands
  27. How to change your login shell
  28. How to display line 4 till 10 from a file
  29. How to change a word named "Bill" to "Bob" in a file. - vi not allowed
  30. How to remove blank lines from a file.
  31. Can you create a hard link across filesystems
  32. What is the purpose of /dev/null file
  33. If I run ls -z > /dev/null  Will anything be displayed on the terminal.
  34. How to capture stdout and stderr of a command to a same file
  35. What is the difference between  "wc -l /etc/passwd" and "wc -l < /etc/passwd
  36. How to find out the OS kernel you are running
  37. How to find out if your hardware supports 64 bit OS or not
  38. What command will delete all 0 byte files from your home directory
  39. What is the size of the internal hard-diskon your system
  40. How to schedule a specific command to run every 5 minutes on 1st day of every month of the first financial quarter of a year. Assume that the financial year starts on 1st of April.
Want to know details of the shell scripting course. Check this link out.
If you want to join our bash shell scripting course, just fill up this form and we will contact you with all the details.

Want to know details of the shell scripting course. Check this link out.

Home   |  Courses   |  Batch Info   |  Exam Dates   |  Contact Us  |
Copyright ©2013 Focus Training Services. All rights reserved