18 March,2021 by Tom Collins
Question: How can I view SQL Server Logging on Linux ?
Answer: SQL Server on Windows - logs details into SQL Server Error logs and Application Logs. Windows event viewer details are available in the Windows Event Logs via the event viewer or Powershell Get-EventLog
1) SQL Server logs details in the SQL Server error log file and the Linux log usually , /var/opt/mssql/log/
2) Use the journalctl command
--show all the log messages since last reboot
journalctl -b
--list by boot number, step 1 generate list of boot numbers. Use the index number (the first column) from command 1 as input parameter for command 2
journalctl --list-boots
0 0461cc4f0702412297c62e0b1834db02 Mon 2021-03-08 21:32:29 GMTâThu 2021-03-18 1
journalctl -b 0
The data is stored on different log files. If you want to view the data file locations of where the Linux source log files are stored read man systemd-journald on your Linux system
This is only a preview. Your comment has not yet been posted.
As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.
Having trouble reading this image? View an alternate.
Posted by: |