Blog Post

Reading the log on SQL for Linux

,

The SQL Server errorlog is a really helpful place to find all sorts of fun facts about your SQL Server instance. As last checked today (6/29/2017) the latest CTP build seems to have problems reading the log.

This can be a problem when trying to diagnose an issue. Here’s what you currently see:

image

Thinking no problem, just use xp_readerrorlog? Nope!

image

Don’t worry. Microsoft already knows about this and these things are expected. It is a CTP after all… 

How to read the log

Reading the log from the Linux cmd prompt is an easy one line command. Assuming the logs are in the default install folder, simply run the following:

less /var/opt/mssql/log/errorlog

This simple command will display the errorlog in the command window and allow you to scroll up and down. Press CTRL-Z to exit less.

So in this case, LESS gives you more.

 

 

Be sure to follow me on Twitter and LinkedIn and check out my other blog posts.

Rate

You rated this post out of 5. Change rating

Share

Share

Rate

You rated this post out of 5. Change rating