Here is a simple Azure troubleshooting technique that can save you a lot of time. Here's the scenario: You have a day of coding your scripts in Azure Automation, and before you go home, there is one slight change, and after you do it, you start getting the error This job does not have any output.
We can go to the Exception tab and see the error, especially if it is a code error. When it is a code error, you won’t see any error or data in either Output, Errors, Warnings and even All Logs tabs.
However, the issue started because I hadn’t tested my code using test pane, which would have informed me that there as an issue on my code, and it would have saved me a lot of time. In my case, I forgot a dash before the operator or.
Lesson learned! Even if you are super confident, to avoid a lot of time-killing back and forth, troubleshoot your Azure job with a simple test pane before publishing your script.
More Quick Tips articles
- Using location in a consistent way in your ARM template parameters
- Using environment as variables in your Azure DevOps pipelines
- Removing Log Analytics with the soft-delete option
- Using conditions in ARM templates when deploying infrastructure-as-code
- Monitor your Azure VM from your mobile device by scanning a QR code