Make sure fuel_agent builds IBP images in a proper directory
Use /var/lib/fuel/ibp as the image build directory. This directory will be backed by a volume in the mcollective container which reduces IO overhead and makes image build time reasonable. fuel_agent (which builds Ubuntu images) runs in the mcollective container. A container filesystem is backed by dm-snapshot which is known to have a poor write performance, especially for large files (like OS images). By default docker storage is a loopback file residing in /var/lib/docker. Thus the data written to the OS image being built goes through a number of layers: ext4 -> loop -> dm-snapshot (/var/lib/docker-> loop -> -> ext4 (/var/lib/docker) -> dm-linear (os-varlibdocker) -> -> hard drive If the master node runs on a VM rather than a physcial hardware the above chain gets even more complicated: ext4 -> loop -> dm-snapshot (/var/lib/docker-> loop -> -> ext4 (/var/lib/docker) -> dm-linear (os-varlibdocker) -> -> virtual hard drive (qemu) -> qcow2 -> ext4 (host) Using the volume makes it possible to eliminate the extra layers, so the written data goes through ext4 -> loop -> ext4 -> dm-linear (os-var) -> hard drive Note: this patch can be merged before the ones which actually make /var/lib/fuel/ibp a host volume (obviously there won't be any performance gain until fuel-library/fuel-main bits get merged). Merge-After: https://review.openstack.org/201947 Related-Bug: #1457643 Change-Id: Ic4d258523aa13b3879a730edb2d910522ec24c93
This commit is contained in:
parent
d1d8f61f24
commit
8712ac1fdf
|
@ -334,6 +334,10 @@ def config(update_path, admin_password):
|
|||
('/var/lib/fuel/keys', {'bind': '/var/lib/fuel/keys',
|
||||
'ro': False})],
|
||||
|
||||
'volume_fuel_ibp': [
|
||||
('/var/lib/fuel/ibp', {'bind': '/var/lib/fuel/ipb',
|
||||
'ro': False})],
|
||||
|
||||
'volume_postgres_data': [
|
||||
('{0}/postgres'.format(container_data_path), {
|
||||
'bind': '/var/lib/pgsql',
|
||||
|
@ -429,6 +433,7 @@ def config(update_path, admin_password):
|
|||
'volume_ssh_keys',
|
||||
'volume_dump',
|
||||
'volume_fuel_configs',
|
||||
'volume_fuel_ibp',
|
||||
'volume_keys']},
|
||||
|
||||
{'id': 'rsync',
|
||||
|
|
Loading…
Reference in New Issue