Debugging

In the very old days of computer technology, the initial problems with computers were due to real insects. Due to this, fault finding was later called as finding a bug. Therefore, the process of finding and fixing the problems in computers was called debugging.

The process of debugging involves the following:

  • Finding out what has gone wrong
  • Fixing the problem

In the actual debugging process, you will need to do the following:

  • Understand the error message and find out what is the problem with the script.
  • Find the error location in the script.
  • Locate the line number from the error message. The following are a few error messages:
    • debug_sp: line 11: [7: command not found]
    • file: line 6: unexpected EOF while looking for matching `"'

    These messages inform ...

Get Learning Linux Shell Scripting now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.