# Log Sorting

If you select "ToolsSort by Date", your log will be sorted by date and time. Log sorting assumes that the whole log is created with the same locale. Also, the log date should have the format "dd mmm yyyy" in your locale, e.g. "01 May 2004" in English, "01 mai 2004" in French, etc. You can check the correct month name for your language settings by using the command:

> $ date -date='01 May'

The time should be formatted as "HHMM", e.g. "1423". The sorted log will be marked as changed. It is recommended to save the log under some other name, so the original log will be safe. You should check this log for correct dates and times before overwriting the original log. If the log is not correctly sorted, start xlog from a terminal to see if sorting produces any errors.