I'm currently in the process of creating a instance locally on kvm-qemu before uploading to OpenStack. The instance is Windows Server 2008R2 x86_64. The requirements are fairly simple so far and they are:
- Does not need to pull data from meta data server.
- Does not need to create users or set passwords.
- Does need to activate the instance with Microsoft.
- Does need to expand the partitions and file system to fill the disk size.
Right now, the logs show that we are querying the meta data server even though I have not specified any configuration options for it to do so. The instance is not being activated with Microsoft but it does have a valid MAK key (volume licensing) installed and if I click on activate, it activates fine. The partitions and file systems are not being extended to the size of the disks. The serial port does not seem to be displaying any data. I have verified that the "Cloud Initialization Service" is running.
The contents of "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-init\conf\cloudbase-init.conf" are:
[DEFAULT]
config_drive_raw_hhd=true
config_drive_cdrom=true
config_drive_vfat=true
bsdtar_path=C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\bin\bsdtar.exe
mtools_path=C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\bin\
verbose=true
debug=true
logdir=C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\log\
logfile=cloudbase-init.log
default_log_levels=comtypes=INFO,suds=INFO,iso8601=WARN
logging_serial_port_settings=COM1,115200,N,8
mtu_use_dhcp_config=true
ntp_use_dhcp_config=true
local_scripts_path=C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\LocalScripts\
plugins=cloudbaseinit.plugins.windows.sethostname.SetHostNamePlugin,cloudbaseinit.plugins.windows.networkconfig.NetworkConfigPlugin,cloudbaseinit.plugins.windows.extendvolumes.ExtendVolumesPlugin,cloudbaseinit.plugins.windows.licensing.WindowsLicensingPlugin,cloudbaseinit.plugins.windows.mtu.MTUPlugin
activate_windows=true
network_adapter=
mtu_use_dhcp_config=true
The contents of "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-init\log\cloudbase-init.log" are:
The contents of "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-init\log\cloudbase-init.log" are:
2015-04-01 14:22:54.907 1644 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.osutils.windows.WindowsUtils' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 14:22:56.622 1644 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.metadata.services.httpservice.HttpService' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 14:22:56.763 1644 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.osutils.windows.WindowsUtils' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 14:22:56.779 1644 DEBUG cloudbaseinit.utils.network [-] Testing url: http://169.254.169.254/ check_url C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\network.py:31
There is no cloudbase-init-unattend.log.
UPDATE:
I don't know if cloudbase-init-unattend.conf should have been used. These systems are sysprep'd with the generalize / OOBE. I'm pasting the cloudbase-init-unattend here as well but it's the default.
[DEFAULT]
username=Admin
groups=Administrators
inject_user_password=false
config_drive_raw_hhd=true
config_drive_cdrom=true
config_drive_vfat=true
bsdtar_path=C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\bin\bsdtar.exe
mtools_path=C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\bin\
verbose=true
debug=true
logdir=C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\log\
logfile=cloudbase-init-unattend.log
default_log_levels=comtypes=INFO,suds=INFO,iso8601=WARN
logging_serial_port_settings=COM1,115200,N,8
mtu_use_dhcp_config=true
ntp_use_dhcp_config=true
local_scripts_path=C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\LocalScripts\
metadata_services=cloudbaseinit.metadata.services.configdrive.ConfigDriveService,cloudbaseinit.metadata.services.httpservice.HttpService,cloudbaseinit.metadata.services.ec2service.EC2Service,cloudbaseinit.metadata.services.maasservice.MaaSHttpService
plugins=cloudbaseinit.plugins.common.mtu.MTUPlugin,cloudbaseinit.plugins.common.sethostname.SetHostNamePlugin
allow_reboot=false
stop_service_on_exit=false
Also I receive the same results regarding no logs on com1, no hdd extend and no activate whether it's on my local qemu-kvm build workstation or on OpenStack IceHouse.
UPDATE 2: The cloudbase-init.log above is from my local qemu-kvm instance on my workstation. I am re-uploading the image to the stack at the moment and will produce the logs from that however, I had done this previously and do know that the above mentioned results are the same on the stack. I'll update when I post the logs from the stack.
UPDATE 3: The serial/com1 logging now appears to be working. Perhaps I had overlooked something before or it may have been a fluke. I am not sure. The Windows Activation and HDD extend still do not work.
Here is the output from the serial/com1 log:
2015-04-01 19:58:30.161 1604 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.osutils.windows.WindowsUtils' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 19:58:32.927 1604 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.metadata.services.httpservice.HttpService' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 19:58:33.098 1604 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.osutils.windows.WindowsUtils' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 19:58:33.098 1604 DEBUG cloudbaseinit.utils.network [-] Testing url: http://169.254.169.254/ check_url C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\network.py:31
2015-04-01 19:58:54.193 1604 DEBUG cloudbaseinit.utils.network [-] Testing url: http://169.254.169.254/ check_url C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\network.py:31
2015-04-01 19:59:15.193 1604 DEBUG cloudbaseinit.utils.network [-] Testing url: http://169.254.169.254/ check_url C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\network.py:31
2015-04-01 19:59:36.240 1604 DEBUG cloudbaseinit.utils.network [-] Setting gateway for host: 169.254.169.254 check_metadata_ip_route C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\network.py:56
2015-04-01 19:59:36.802 1604 DEBUG cloudbaseinit.metadata.services.httpservice [-] Getting metadata from: http://169.254.169.254/openstack/latest/meta_data.json _get_data C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\metadata\services\httpservice.py:70
2015-04-01 19:59:37.177 1604 INFO cloudbaseinit.init [-] Metadata service loaded: 'HttpService'
2015-04-01 19:59:37.177 1604 DEBUG cloudbaseinit.metadata.services.base [-] Using cached copy of metadata: 'openstack/latest/meta_data.json' _get_cache_data C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\metadata\services\base.py:90
2015-04-01 19:59:37.193 1604 DEBUG cloudbaseinit.init [-] Instance id: 5d35ef22-df8c-4cb9-a713-fd9770852619 configure_host C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\init.py:105
2015-04-01 19:59:37.193 1604 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.plugins.windows.sethostname.SetHostNamePlugin' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 19:59:37.207 1604 CRITICAL cloudbaseinit [-] ImportError: No module named sethostname
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit Traceback (most recent call last):
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit File "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\Scripts\cloudbase-init-script.py", line 9, in <module>
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit load_entry_point('cloudbase-init==0.9.8.dev59', 'console_scripts', 'cloudbase-init')()
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit File "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\shell.py", line 29, in main
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit init.InitManager().configure_host()
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit File "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\init.py", line 107, in configure_host
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit plugins = plugins_factory.load_plugins()
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit File "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\plugins\common\factory.py", line 53, in load_plugins
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit plugins.append(cl.load_class(class_path)())
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit File "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py", line 28, in load_class
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit module = __import__(parts[0], fromlist=parts[1])
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit ImportError: No module named sethostname
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit
Here is the output from cloudbase-init.log:
2015-04-01 19:58:30.161 1604 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.osutils.windows.WindowsUtils' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 19:58:32.927 1604 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.metadata.services.httpservice.HttpService' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 19:58:33.098 1604 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.osutils.windows.WindowsUtils' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 19:58:33.098 1604 DEBUG cloudbaseinit.utils.network [-] Testing url: http://169.254.169.254/ check_url C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\network.py:31
2015-04-01 19:58:54.193 1604 DEBUG cloudbaseinit.utils.network [-] Testing url: http://169.254.169.254/ check_url C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\network.py:31
2015-04-01 19:59:15.193 1604 DEBUG cloudbaseinit.utils.network [-] Testing url: http://169.254.169.254/ check_url C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\network.py:31
2015-04-01 19:59:36.240 1604 DEBUG cloudbaseinit.utils.network [-] Setting gateway for host: 169.254.169.254 check_metadata_ip_route C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\network.py:56
2015-04-01 19:59:36.802 1604 DEBUG cloudbaseinit.metadata.services.httpservice [-] Getting metadata from: http://169.254.169.254/openstack/latest/meta_data.json _get_data C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\metadata\services\httpservice.py:70
2015-04-01 19:59:37.177 1604 INFO cloudbaseinit.init [-] Metadata service loaded: 'HttpService'
2015-04-01 19:59:37.177 1604 DEBUG cloudbaseinit.metadata.services.base [-] Using cached copy of metadata: 'openstack/latest/meta_data.json' _get_cache_data C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\metadata\services\base.py:90
2015-04-01 19:59:37.193 1604 DEBUG cloudbaseinit.init [-] Instance id: 5d35ef22-df8c-4cb9-a713-fd9770852619 configure_host C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\init.py:105
2015-04-01 19:59:37.193 1604 DEBUG cloudbaseinit.utils.classloader [-] Loading class 'cloudbaseinit.plugins.windows.sethostname.SetHostNamePlugin' load_class C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py:26
2015-04-01 19:59:37.207 1604 CRITICAL cloudbaseinit [-] ImportError: No module named sethostname
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit Traceback (most recent call last):
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit File "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\Scripts\cloudbase-init-script.py", line 9, in <module>
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit load_entry_point('cloudbase-init==0.9.8.dev59', 'console_scripts', 'cloudbase-init')()
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit File "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\shell.py", line 29, in main
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit init.InitManager().configure_host()
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit File "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\init.py", line 107, in configure_host
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit plugins = plugins_factory.load_plugins()
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit File "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\plugins\common\factory.py", line 53, in load_plugins
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit plugins.append(cl.load_class(class_path)())
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit File "C:\Program Files (x86)\Cloudbase Solutions\Cloudbase-Init\Python27\lib\site-packages\cloudbaseinit\utils\classloader.py", line 28, in load_class
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit module = __import__(parts[0], fromlist=parts[1])
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit ImportError: No module named sethostname
2015-04-01 19:59:37.207 1604 TRACE cloudbaseinit
There is still no cloudbase-init-unattend.log.