I don’t think that was it. I started the new instance with a clean volume each time. I did try deleting content.test and public after the last run and I saw that the HDD was pegged based on how I had it configured.
With the last test I did (results below), I sized up the instance to an i2.4xlarge (16 vCPU and 122 GB RAM) and attached a 200GB Provisioned IOPS volume with the IOPS set to 6000. Here are the results:
./bin/hugo-lorem /home/ec2-user/testsite/content/post/
18:23:27.002 [main] INFO HugoLorem - processed 50000
18:23:32.682 [main] INFO HugoLorem - processed 100000
18:23:38.358 [main] INFO HugoLorem - processed 150000
18:23:44.053 [main] INFO HugoLorem - processed 200000
18:23:49.668 [main] INFO HugoLorem - processed 250000
18:24:00.167 [main] INFO HugoLorem - processed 300000
18:24:07.847 [main] INFO HugoLorem - processed 350000
18:24:13.504 [main] INFO HugoLorem - processed 400000
18:24:19.438 [main] INFO HugoLorem - processed 450000
18:24:26.414 [main] INFO HugoLorem - processed 500000
18:24:31.812 [main] INFO HugoLorem - processed 550000
18:24:37.303 [main] INFO HugoLorem - processed 600000
18:24:37.305 [main] INFO HugoLorem - 0:01:16.430
time cp -r content content.test
real 0m16.882s
user 0m1.164s
sys 0m15.188s
hugo --theme=hyde --buildDrafts=true -v --stepAnalysis=true
INFO: 2015/06/18 Using config file: /home/ec2-user/testsite/config.toml
INFO: 2015/06/18 syncing from /home/ec2-user/testsite/themes/hyde/static to /home/ec2-user/testsite/public/
INFO: 2015/06/18 syncing from /home/ec2-user/testsite/static/ to /home/ec2-user/testsite/public/
initialize & template prep:
351.394703ms (354.057907ms) 0.54 MB 5644 Allocs
load data:
792.468µs (354.951988ms) 0.01 MB 106 Allocs
import pages:
1m31.199485719s (1m31.582473998s) 74427.64 MB 238142156 Allocs
INFO: 2015/06/18 found taxonomies: map[string]string{"tag":"tags", "category":"categories"}
build taxonomies:
1.734869883s (1m33.37217586s) 166.93 MB 5400106 Allocs
render and write aliases:
14.78402ms (1m33.441452075s) 0.00 MB 0 Allocs
render and write taxonomies:
85.644µs (1m33.496067107s) 0.00 MB 29 Allocs
render & write taxonomy lists:
231.986µs (1m33.550878275s) 0.02 MB 386 Allocs
ERROR: 2015/06/18 Site's .BaseUrl is deprecated and will be removed in Hugo 0.15. Use .BaseURL instead.
render and write lists:
33.474794023s (2m7.078339867s) 4363.44 MB 89405706 Allocs
render and write pages:
1m11.194554477s (3m18.333621207s) 18254.64 MB 362400190 Allocs
WARN: 2015/06/18 Unable to locate layout for 404 page: [404.html theme/404.html]
render and write homepage:
50.939685961s (4m9.344074395s) 26227.58 MB 97805016 Allocs
render and write Sitemap:
39.851999698s (4m49.264834561s) 4477.36 MB 106800359 Allocs
600000 of 600000 drafts rendered
0 future content
600000 pages created
0 paginator pages created
0 tags created
0 categories created
in 288956 ms
time rm -rf content.test/
real 0m8.698s
user 0m0.312s
sys 0m7.976s
time rm -rf public/
real 0m38.465s
user 0m2.204s
sys 0m28.280s
time cp -r content content.test
real 0m16.820s
user 0m1.128s
sys 0m15.144s
hugo --theme=hyde --buildDrafts=true -v --stepAnalysis=true
INFO: 2015/06/18 Using config file: /home/ec2-user/testsite/config.toml
INFO: 2015/06/18 syncing from /home/ec2-user/testsite/themes/hyde/static to /home/ec2-user/testsite/public/
INFO: 2015/06/18 syncing from /home/ec2-user/testsite/static/ to /home/ec2-user/testsite/public/
initialize & template prep:
7.747208ms (8.303872ms) 0.54 MB 5646 Allocs
load data:
73.204µs (8.489458ms) 0.01 MB 106 Allocs
import pages:
1m33.815698001s (1m33.851815309s) 74427.55 MB 238142041 Allocs
INFO: 2015/06/18 found taxonomies: map[string]string{"tag":"tags", "category":"categories"}
build taxonomies:
1.725997747s (1m35.63226383s) 166.93 MB 5400106 Allocs
render and write aliases:
14.627662ms (1m35.701348611s) 0.00 MB 0 Allocs
render and write taxonomies:
81.151µs (1m35.755811919s) 0.00 MB 32 Allocs
render & write taxonomy lists:
234.993µs (1m35.810481172s) 0.02 MB 386 Allocs
ERROR: 2015/06/18 Site's .BaseUrl is deprecated and will be removed in Hugo 0.15. Use .BaseURL instead.
render and write lists:
33.295439543s (2m9.158478923s) 4363.44 MB 89405708 Allocs
render and write pages:
1m9.4628844s (3m18.681787678s) 18254.63 MB 362400291 Allocs
WARN: 2015/06/18 Unable to locate layout for 404 page: [404.html theme/404.html]
render and write homepage:
51.041658401s (4m9.792705514s) 24447.66 MB 97805023 Allocs
render and write Sitemap:
41.13710261s (4m50.997916102s) 4477.36 MB 106800359 Allocs
600000 of 600000 drafts rendered
0 future content
600000 pages created
0 paginator pages created
0 tags created
0 categories created
in 291029 ms
du -sh content
4.6G content
du -sh public
9.7G public
time cp -r public public.test
real 1m27.495s
user 0m3.104s
sys 0m39.152s
One thing I noticed on both hugo runs is that top was reporting total memory used up around 80GB and the hugo process was showing reserved memory at ~55GB. With the previous instance, we only had 60GB of RAM, so we were probably swapping.
It looks like throwing hardware at this helps a lot. I’ve got a couple of other tweaks I can try on the volume, but based on the volume monitoring during the runs, I don’t think it will make much difference because we weren’t hitting any caps during these runs.