cloud-init fails strangely on oVirt and Fedora 30 with error "IsADirectoryError: [Errno 21] Is a directory: '/var/lib/cloud/instance'"
by tshikose from LinuxQuestions.org on (#4RH9G)
Hi,
I am using oVirt 4.2.
And I have problems working with cloud-init (cloud-init-17.1-9.fc30.noarch) with Fedora 30 based template.
The steps I used are as follow.
1. I successfully created, installed and configured a Fedora 30 VM
2. I customized, and then sealed the Fedora 30 VM
3. I successfully made the template from the Fedora 30 sealed VM
I have issues after setting up cloud-init and expecting its settings to take effect.
My cloud-init is essentially as follows below.
Code:Initial Run
Use Cloud-Init/Sysprep: Checked
Configure Time Zone
Time Zone: (GMT-10:00) Hawaiian Standard Time
Authentication
User Name: foobar
Password: password
Custom Script
#cloud-config
runcmd:
- [ date, >>, /var/cache/date.log ]For reasons that I do not understand cloud-init fails with the below error.
IsADirectoryError: [Errno 21] Is a directory: '/var/lib/cloud/instance'
I have attached some relevant log files: cloud-init.log, cloud-init-output.log and var-lib-cloud.txt (an archive of /var/lib/cloud folder, to be renamed as var-lib-cloud.tar.gz).
Thanks in advance for any help and hints.
Attached Files


I am using oVirt 4.2.
And I have problems working with cloud-init (cloud-init-17.1-9.fc30.noarch) with Fedora 30 based template.
The steps I used are as follow.
1. I successfully created, installed and configured a Fedora 30 VM
2. I customized, and then sealed the Fedora 30 VM
3. I successfully made the template from the Fedora 30 sealed VM
I have issues after setting up cloud-init and expecting its settings to take effect.
My cloud-init is essentially as follows below.
Code:Initial Run
Use Cloud-Init/Sysprep: Checked
Configure Time Zone
Time Zone: (GMT-10:00) Hawaiian Standard Time
Authentication
User Name: foobar
Password: password
Custom Script
#cloud-config
runcmd:
- [ date, >>, /var/cache/date.log ]For reasons that I do not understand cloud-init fails with the below error.
IsADirectoryError: [Errno 21] Is a directory: '/var/lib/cloud/instance'
I have attached some relevant log files: cloud-init.log, cloud-init-output.log and var-lib-cloud.txt (an archive of /var/lib/cloud folder, to be renamed as var-lib-cloud.tar.gz).
Thanks in advance for any help and hints.
Attached Files
![]() | cloud-init.log (118.0 KB) |
![]() | cloud-init-output.log (11.9 KB) |
![]() | var-lib-cloud.txt (1.3 KB) |

