10. Create Profile
Profiles allow you to customize groups of compute nodes with the same settings and create a custom kickstart file for them. Each imported Linux distribution automatically adds a base profile which can be used as a starting point. A profile can depend and inherit properties from a parent profile.
A typical example would be to have one profile for each hardware configuration on a cluster, each based on the CentOS 7 profile.
You can add a child profile by using cobbler profile add
and
specifying a parent profile.
[root@master ~]# cobbler profile add --name=centos7-compute --parent=centos7-x86_64
The output of cobbler profile report
shows that all values not
explicitly set on a child profile are inherited from its parent profile.
[root@master ~]# cobbler profile report --name=centos7-compute
Name : centos7-compute
TFTP Boot Files : <<inherit>>
Comment :
DHCP Tag : <<inherit>>
Distribution : <<inherit>>
Enable gPXE? : 0
Enable PXE Menu? : <<inherit>>
Fetchable Files : <<inherit>>
Kernel Options : <<inherit>>
Kernel Options (Post Install) : <<inherit>>
Kickstart : <<inherit>>
Kickstart Metadata : <<inherit>>
Management Classes : <<inherit>>
Management Parameters : <<inherit>>
Name Servers : []
Name Servers Search Path : []
Owners : ['admin']
Parent Profile : centos7-x86_64
Internal proxy : <<inherit>>
Red Hat Management Key : <<inherit>>
Red Hat Management Server : <<inherit>>
Repos : <<inherit>>
Server Override : <<inherit>>
Template Files : <<inherit>>
Virt Auto Boot : <<inherit>>
Virt Bridge : <<inherit>>
Virt CPUs : <<inherit>>
Virt Disk Driver Type : <<inherit>>
Virt File Size(GB) : <<inherit>>
Virt Path : <<inherit>>
Virt RAM (MB) : <<inherit>>
Virt Type : <<inherit>>
We can specify value we want to change either directly in the add
command, or later using edit
. E.g., if you want to use your own
kickstart template for a profile you can set the path to that file.
[root@master ~]# cobbler profile edit --name=centos7-compute --kickstart=/var/lib/cobbler/kickstarts/compute.ks