[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#10019: sort options -Mn are incompatible
From: |
Pádraig Brady |
Subject: |
bug#10019: sort options -Mn are incompatible |
Date: |
Fri, 11 Nov 2011 17:55:33 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:6.0) Gecko/20110816 Thunderbird/6.0 |
tag 10019 notabug
On 11/11/2011 01:55 PM, Lars Noodén wrote:
> Since the sort options -M and -n are incompatible, there appears to be no
> easy way to sort log files.
Here is a recipe I use for sorting access_log files,
which avoids numeric conversion as they're fixed width fields.
sort -b -k4.9,4.12 -k4.5b,4.7Mb -k4.2,4.3 -k4.14,4 access_log
Though one could use -M and -n on separate fields like `-k1,1M -k2,2n`
Note also the --debug option on recent versions of sort
which helps one figure this out, including subtleties like
needing the b after the M even though a global -b was specified.
cheers,
Pádraig.
- bug#10019: sort options -Mn are incompatible, Lars Noodén, 2011/11/11
- bug#10019: sort options -Mn are incompatible, Bob Proulx, 2011/11/11
- bug#10019: sort options -Mn are incompatible, Pádraig Brady, 2011/11/11
- bug#10019: sort options -Mn are incompatible,
Pádraig Brady <=
- bug#10019: sort options -Mn are incompatible, Eric Blake, 2011/11/11
- bug#10019: sort options -Mn are incompatible, Lars Noodén, 2011/11/11
- bug#10019: sort options -Mn are incompatible, Paul Eggert, 2011/11/11
- bug#10019: sort options -Mn are incompatible, Lars Noodén, 2011/11/12
- bug#10019: sort options -Mn are incompatible, Eric Blake, 2011/11/12
- bug#10019: sort options -Mn are incompatible, Paul Eggert, 2011/11/12
- bug#10019: sort options -Mn are incompatible, Eric Blake, 2011/11/16
- bug#10019: sort options -Mn are incompatible, Jim Meyering, 2011/11/16