Navigation and service panel


Check log files on remote environments

By Kevin Brechb├╝hl on 6. February 2015, No comments

On local environments, looking into log files is easy. It's also possible for remote authoring servers where we have the Sitecore backend available. But how do we check the log files for remote delivery systems, where we don't have any access? This blog post introduces a new Shared Source Module which exactly solves this issue.

On local environments we use Log2Console (german blog) for analysing logs. On our internal development and testing systems I often get the log files with a Windows Share and have a look into them in Notepad. It's a bit more complicated to get the log files for remote systems where we don't have access (i.e. productive customer environments). Often we have access to the Sitecore backend and can consult the Log Viewer. But on delivery environments where we have enabled the Sitecore hardening (no Sitecore backend)? No chance. Take the phone, call the system administrator of the customer and ask him to send the log files via mail.

Once a year we have a so called Innovation Day at Unic where every employee can do something he ever wanted to do. Something like a little company Hackathon ;-) This year, I wanted to solve the issue with viewing log files on remote environments.

The idea I had is very simple: Make a simple interface, reading the content of the log file and send the content back to the client. It should also be possible to browse any available log file. To have a bit of fun, the output should be as easily as possible (text/plain). And so, there it is, a new Shared Source Module:

> Install-Package Unic.ScriptLogger

As shown in the command above, the ScriptLogger can easily be installed via NuGet. If you prefer to install it via a Sitecore Package you can download it from the Marketplace. Or go the hard way and build it on your own, the source can be cloned from GitHub.

After installing the module, you can browse the newest log file with the following request (you need to be logged in as administrator):

http://<your domain>/scriptlogger

For more information about what you can do with the module or additional installation/configuration information, please check the README on GitHub.

That's it :-) What do you think about this module? Is it useful? Are you missing something? How do you solve the issue with remote log files?

Categories  Modules  Sitecore Logging Tags  View  Log  GitHub

No comments

Add your comment

Your email address will not be published. Required fields are marked *