2つの出力を結合してマージします。

2つの出力を結合してマージします。

サーバーからデータを取得し、日付、時刻、およびドメイン名に基づいて出力1に出力2をソートしようとしています。希望の出力を得るためにcentos6を使用しています。 sedとawkを介して試しましたが、必要な出力を取得できませんでした。

出力1:

2017-04-15
Account: abcdef Domain: bytes.co    CPU: 7.22   Mem: 0.31   MySQL: 2.5
%CPU 52.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 46.5 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 42.0 - /usr/bin/php /home/abcdef/public_html/wp-login.php
Account: uvwxyz Domain: ppao.com    CPU: 27.93  Mem: 0.46   MySQL: 1.1
%CPU 84.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 79.2 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 79.1 - [php] <defunct>
Account: lmnopp Domain: nebu.org    CPU: 10.38  Mem: 0.08   MySQL: 0.5
%CPU 57.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 56.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 54.0 - /usr/bin/php /home/lmnopp/public_html/index.php
2017-04-14
Account: abcdef Domain: bytes.co    CPU: 4.19   Mem: 0.14   MySQL: 1.2
%CPU 83.0 - /usr/bin/php /home/abcdef/public_html/wp-admin/admin.php
%CPU 81.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 69.0 - /usr/bin/php /home/abcdef/public_html/wp-login.php
Account: uvwxyz Domain: ppao.com    CPU: 39.03  Mem: 0.48   MySQL: 1.1
%CPU 132 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 118 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 114 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 16.39  Mem: 0.12   MySQL: 0.8
%CPU 119 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 80.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 77.0 - /usr/bin/php /home/lmnopp/public_html/index.php
2017-04-13
Account: abcdef Domain: bytes.co    CPU: 4.15   Mem: 0.02   MySQL: 0.1
%CPU 70.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 67.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 66.0 - /usr/bin/php /home/abcdef/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 28.23  Mem: 0.50   MySQL: 2.1
%CPU 93.1 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 92.2 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 90.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 19.90  Mem: 0.12   MySQL: 0.9
%CPU 61.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 60.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 52.0 - /usr/bin/php /home/lmnopp/public_html/index.php
2017-04-12
Account: uvwxyz Domain: ppao.com    CPU: 26.27  Mem: 0.36   MySQL: 0.7
%CPU 96.5 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 89.7 - [php] <defunct>
%CPU 89.5 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 25.94  Mem: 0.18   MySQL: 1.2
%CPU 75.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 66.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 65.0 - /usr/bin/php /home/lmnopp/public_html/index.php
Account: abcdef Domain: bytes.co    CPU: 2.14   Mem: 0.02   MySQL: 0.1
%CPU 46.5 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 44.5 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 42.5 - /usr/bin/php /home/abcdef/public_html/index.php
2017-04-11
Account: abcdef Domain: bytes.co    CPU: 3.95   Mem: 0.04   MySQL: 0.2
%CPU 57.5 - /usr/bin/php /home/abcdef/public_html/wp-admin/admin.php
%CPU 42.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 39.5 - /usr/bin/php /home/abcdef/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 23.49  Mem: 0.20   MySQL: 1.2
%CPU 73.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 72.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 66.0 - /usr/bin/php /home/lmnopp/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 18.50  Mem: 0.26   MySQL: 0.6
%CPU 89.5 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 89.2 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 88.5 - /usr/bin/php /home/uvwxyz/public_html/index.php
2017-04-10
Account: abcdef Domain: bytes.co    CPU: 5.82   Mem: 0.03   MySQL: 0.2
%CPU 94.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 78.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 76.0 - /usr/bin/php /home/abcdef/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 22.57  Mem: 0.17   MySQL: 1.2
%CPU 110 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 102 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 85.0 - /usr/bin/php /home/lmnopp/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 19.63  Mem: 0.36   MySQL: 0.9
%CPU 66.9 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 65.3 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 59.6 - /usr/bin/php /home/uvwxyz/public_html/index.php
2017-04-09
Account: abcdef Domain: bytes.co    CPU: 6.19   Mem: 0.04   MySQL: 0.2
%CPU 83.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 72.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 67.0 - /usr/bin/php /home/abcdef/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 27.66  Mem: 0.21   MySQL: 1.4
%CPU 82.3 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 71.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 66.0 - /usr/bin/php /home/lmnopp/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 22.91  Mem: 0.41   MySQL: 1.1
%CPU 69.7 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 69.3 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 65.7 - /usr/bin/php /home/uvwxyz/public_html/index.php
2017-04-08
Account: abcdef Domain: bytes.co    CPU: 3.77   Mem: 0.03   MySQL: 0.2
%CPU 74.0 - /usr/bin/php /home/abcdef/public_html/wp-admin/admin.php
%CPU 71.0 - /usr/bin/php /home/abcdef/public_html/wp-cron.php
%CPU 68.0 - /usr/bin/php /home/abcdef/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 22.04  Mem: 0.18   MySQL: 1.4
%CPU 74.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 73.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 72.0 - /usr/bin/php /home/lmnopp/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 19.45  Mem: 0.33   MySQL: 0.8
%CPU 68.4 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 66.9 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 62.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
2017-04-07
Account: abcdef Domain: bytes.co    CPU: 6.92   Mem: 0.03   MySQL: 0.2
%CPU 109 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 103 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 90.0 - /usr/bin/php /home/abcdef/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 25.65  Mem: 0.16   MySQL: 1.1
%CPU 84.5 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 82.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 77.0 - /usr/bin/php /home/lmnopp/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 20.79  Mem: 0.35   MySQL: 0.9
%CPU 63.3 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 62.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 60.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
2017-04-06
Account: abcdef Domain: bytes.co    CPU: 4.03   Mem: 0.02   MySQL: 0.2
%CPU 80.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 72.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 30.0 - /usr/bin/php /home/abcdef/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 24.64  Mem: 0.14   MySQL: 1.0
%CPU 74.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 63.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 62.0 - /usr/bin/php /home/lmnopp/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 16.87  Mem: 0.28   MySQL: 0.7
%CPU 79.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 74.6 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 65.5 - /usr/bin/php /home/uvwxyz/public_html/index.php
2017-04-05
Account: abcdef Domain: bytes.co    CPU: 5.78   Mem: 0.04   MySQL: 0.2
%CPU 71.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 70.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 66.0 - /usr/bin/php /home/abcdef/public_html/wp-cron.php
Account: uvwxyz Domain: ppao.com    CPU: 33.90  Mem: 0.64   MySQL: 1.6
%CPU 102 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 98.3 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 96.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 21.48  Mem: 0.14   MySQL: 0.9
%CPU 121 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 83.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 76.0 - /usr/bin/php /home/lmnopp/public_html/index.php
2017-04-04
Account: abcdef Domain: bytes.co    CPU: 3.93   Mem: 0.09   MySQL: 0.9
%CPU 80.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 78.0 - /usr/bin/php /home/abcdef/public_html/wp-cron.php
%CPU 72.0 - /usr/bin/php /home/abcdef/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 19.44  Mem: 0.22   MySQL: 0.5
%CPU 103 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 99.6 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 95.8 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 18.80  Mem: 0.13   MySQL: 0.9
%CPU 120 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 65.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 64.0 - /usr/bin/php /home/lmnopp/public_html/index.php
2017-04-03
Account: abcdef Domain: bytes.co    CPU: 5.71   Mem: 0.04   MySQL: 0.2
%CPU 97.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 60.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 58.0 - /usr/bin/php /home/abcdef/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 46.17  Mem: 0.69   MySQL: 1.3
%CPU 95.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 94.5 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 94.4 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 27.79  Mem: 0.16   MySQL: 1.2
%CPU 81.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 77.0 - [php]
%CPU 73.0 - /usr/bin/php /home/lmnopp/public_html/index.php
2017-04-02
Account: abcdef Domain: bytes.co    CPU: 7.65   Mem: 0.09   MySQL: 0.7
%CPU 92.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 78.0 - /usr/bin/php /home/abcdef/public_html/wp-cron.php
%CPU 70.0 - /usr/bin/php /home/abcdef/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 28.99  Mem: 0.61   MySQL: 1.5
%CPU 61.4 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 59.4 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 57.3 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 27.57  Mem: 0.16   MySQL: 1.1
%CPU 79.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 78.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 73.0 - /usr/bin/php /home/lmnopp/public_html/index.php
2017-04-01
Account: abcdef Domain: bytes.co    CPU: 6.68   Mem: 0.05   MySQL: 0.4
%CPU 93.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 79.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 69.0 - /usr/bin/php /home/abcdef/public_html/index.php
Account: uvwxyz Domain: ppao.com    CPU: 29.80  Mem: 0.49   MySQL: 1.0
%CPU 87.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 86.5 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 85.8 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 24.78  Mem: 0.14   MySQL: 1.0
%CPU 79.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 72.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 68.0 - /usr/bin/php /home/lmnopp/public_html/index.php

出力2:

/root/testing/parsing/01-04-2017.txt:bytes.co 3291
/root/testing/parsing/01-04-2017.txt:nebu.org 1607
/root/testing/parsing/01-04-2017.txt:ppao.com 1765
/root/testing/parsing/02-04-2017.txt:bytes.co 4216
/root/testing/parsing/02-04-2017.txt:nebu.org 1539
/root/testing/parsing/02-04-2017.txt:ppao.com 2122
/root/testing/parsing/03-04-2017.txt:bytes.co 3405
/root/testing/parsing/03-04-2017.txt:nebu.org 1526
/root/testing/parsing/03-04-2017.txt:ppao.com 1436
/root/testing/parsing/04-04-2017.txt:ppao.com 1683
/root/testing/parsing/04-04-2017.txt:bytes.co 5557
/root/testing/parsing/04-04-2017.txt:nebu.org 1809
/root/testing/parsing/05-04-2017.txt:ppao.com 2690
/root/testing/parsing/05-04-2017.txt:bytes.co 5973
/root/testing/parsing/05-04-2017.txt:nebu.org 3526
/root/testing/parsing/06-04-2017.txt:ppao.com 2572
/root/testing/parsing/06-04-2017.txt:bytes.co 4653
/root/testing/parsing/06-04-2017.txt:nebu.org 2171
/root/testing/parsing/07-04-2017.txt:ppao.com 1983
/root/testing/parsing/07-04-2017.txt:bytes.co 5329
/root/testing/parsing/07-04-2017.txt:nebu.org 2288
/root/testing/parsing/08-04-2017.txt:ppao.com 2682
/root/testing/parsing/08-04-2017.txt:bytes.co 2951
/root/testing/parsing/08-04-2017.txt:nebu.org 3030
/root/testing/parsing/09-04-2017.txt:ppao.com 1354
/root/testing/parsing/09-04-2017.txt:bytes.co 3709
/root/testing/parsing/09-04-2017.txt:nebu.org 2053
/root/testing/parsing/10-04-2017.txt:ppao.com 2085
/root/testing/parsing/10-04-2017.txt:bytes.co 6577
/root/testing/parsing/10-04-2017.txt:nebu.org 2234
/root/testing/parsing/11-04-2017.txt:ppao.com 1822
/root/testing/parsing/11-04-2017.txt:bytes.co 5656
/root/testing/parsing/11-04-2017.txt:nebu.org 1853
/root/testing/parsing/12-04-2017.txt:ppao.com 1961
/root/testing/parsing/12-04-2017.txt:bytes.co 3365
/root/testing/parsing/12-04-2017.txt:nebu.org 1917
/root/testing/parsing/13-04-2017.txt:ppao.com 2297
/root/testing/parsing/13-04-2017.txt:bytes.co 4325
/root/testing/parsing/13-04-2017.txt:nebu.org 3202
/root/testing/parsing/14-04-2017.txt:ppao.com 2021
/root/testing/parsing/14-04-2017.txt:bytes.co 3873
/root/testing/parsing/14-04-2017.txt:nebu.org 2544
/root/testing/parsing/15-04-2017.txt:ppao.com 2262
/root/testing/parsing/15-04-2017.txt:bytes.co 3549
/root/testing/parsing/15-04-2017.txt:nebu.org 2157

希望の出力:

2017-04-02
Account: abcdef Domain: bytes.co    CPU: 7.65   Mem: 0.09   MySQL: 0.7    Hits: 4216
%CPU 92.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 78.0 - /usr/bin/php /home/abcdef/public_html/wp-cron.php
%CPU 70.0 - /usr/bin/php /home/abcdef/public_html/index.php
--
Account: uvwxyz Domain: ppao.com    CPU: 28.99  Mem: 0.61   MySQL: 1.5    Hits: 2122
%CPU 61.4 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 59.4 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 57.3 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 27.57  Mem: 0.16   MySQL: 1.1    Hits: 1539
%CPU 79.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 78.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 73.0 - /usr/bin/php /home/lmnopp/public_html/index.php
2017-04-01
Account: abcdef Domain: bytes.co    CPU: 6.68   Mem: 0.05   MySQL: 0.4    Hits: 3291
%CPU 93.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 79.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 69.0 - /usr/bin/php /home/abcdef/public_html/index.php
--
Account: uvwxyz Domain: ppao.com    CPU: 29.80  Mem: 0.49   MySQL: 1.0    Hits: 1765
%CPU 87.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 86.5 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 85.8 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 24.78  Mem: 0.14   MySQL: 1.0    Hits: 1607
%CPU 79.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 72.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 68.0 - /usr/bin/php /home/lmnopp/public_html/index.php

答え1

アッ方法:

awk 'NR==FNR{ split($5, data, "-"); a[data[3]"-"data[2]"-"data[1],$6]=$7; next}
    /[0-9]{4}-[0-9]{2}-[0-9]{2}/{ d=$0 }{ if ($0~/^Account/) { 
    if ((d,$4) in a) { $0=$0"\tHints:" FS a[d,$4] }} print}'
    FS=" |.txt:|/" output2.txt  FS=" " output1.txt

出力:

2017-04-02
Account: abcdef Domain: bytes.co    CPU: 7.65   Mem: 0.09   MySQL: 0.7  Hints: 4216
%CPU 92.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 78.0 - /usr/bin/php /home/abcdef/public_html/wp-cron.php
%CPU 70.0 - /usr/bin/php /home/abcdef/public_html/index.php
--
Account: uvwxyz Domain: ppao.com    CPU: 28.99  Mem: 0.61   MySQL: 1.5  Hints: 2122
%CPU 61.4 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 59.4 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 57.3 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 27.57  Mem: 0.16   MySQL: 1.1  Hints: 1539
%CPU 79.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 78.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 73.0 - /usr/bin/php /home/lmnopp/public_html/index.php
2017-04-01
Account: abcdef Domain: bytes.co    CPU: 6.68   Mem: 0.05   MySQL: 0.4  Hints: 3291
%CPU 93.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 79.0 - /usr/bin/php /home/abcdef/public_html/index.php
%CPU 69.0 - /usr/bin/php /home/abcdef/public_html/index.php
--
Account: uvwxyz Domain: ppao.com    CPU: 29.80  Mem: 0.49   MySQL: 1.0  Hints: 1765
%CPU 87.0 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 86.5 - /usr/bin/php /home/uvwxyz/public_html/index.php
%CPU 85.8 - /usr/bin/php /home/uvwxyz/public_html/index.php
Account: lmnopp Domain: nebu.org    CPU: 24.78  Mem: 0.14   MySQL: 1.0  Hints: 1607
%CPU 79.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 72.0 - /usr/bin/php /home/lmnopp/public_html/index.php
%CPU 68.0 - /usr/bin/php /home/lmnopp/public_html/index.php

  • FS=" |.txt:|/" output2.txtoutput2.txt- ファイルのカスタムフィールド区切り記号

  • split($5, data, "-")-01-04-2017ファイル処理時に各日付値を分割します(例:)output2.txt

  • data[3]"-"data[2]"-"data[1]- 2つのファイル間の一致を提供するために日付部分を並べ替えます。

  • a[data[3]"-"data[2]"-"data[1],$6]=$7- 蓄積するヒント複雑な文字列インデックスの使用

  • /[0-9]{4}-[0-9]{2}-[0-9]{2}/{ d=$0 }- 処理中の日付値の取得output1.txt

関連情報