Christopher Johnston wrote:
> I am running the latest cobbler 1.3.1. <http://1.3.1.>  I have 
> /etc/cobbler/settings setup to not allow duplicate mac addresses and 
> hostname.

For development versions, the latest version is best defined as a "when" 
not a number.  See the full output of "--version" if it's less than 5 
minutes old :)   This will also give me git information regarding any 
local modifications.

>
> [EMAIL PROTECTED] etc]# grep allow_dupl /etc/cobbler/settings
> allow_duplicate_hostnames: 0
> allow_duplicate_ips: 0
> allow_duplicate_macs: 0
>

Ok...

> If we are relying on cobbler to manage DHCP addresses this could be a 
> bad thing if you have duplicate entries (for ip mac, etc) within a 
> single system record.  Since I am currently using cobbler to stateless 
> boot initrd/vmlinuz to my systems in a large number of clusters I will 
> rely heavily on cobbler to maintain unique information for all my 
> systems which includes their network interfaces.  Using the copy 
> feature is convenient if we want to mimic one system record to 
> another, but sounds like its more suited for using it to copy a system 
> record as a template (minimal information in the record thats static, 
> ie kopts, profile, etc).  I noticed if I insert duplicate entries into 
> a system record it ends up overwriting other valid entries on my dhcp 
> server.
>

Not sure what you mean by "overwriting", you mean clobbering leases?  Yes.


> Could something like this be a configuration option that does stricter 
> checking, ie you do a copy of one system record to another and --mac 
> --ip --subnet --hostname (dns-name) is considered a mandatory field to 
> be entered?  Might even be something that gets checked when you run 
> cobbler sync.  Am I missing something here?
>

Sounds reasonable.  How about filing a bug in Trac about putting some 
more restrictions on the copy operation?

http://fedorahosted.org/cobbler

This will probably not make 1.4.X as it likely requires some extra 
handling in both the API and the web application.



> On Wed, Nov 26, 2008 at 5:11 AM, Michael DeHaan <[EMAIL PROTECTED] 
> <mailto:[EMAIL PROTECTED]>> wrote:
>
>     Christopher Johnston wrote:
>     > Should this be allowed?  Seems like this is not the appropriate
>     > behaviour given I could have multiple interfaces on a host, no?
>
>     Duplicate hostname prevention is a feature in 1.2.X Cobbler, it is
>     disabled/enabled at the top of your settings file.
>     I believe multiple hostnames on the same system are exempt from those
>     restrictions.
>
>     What version of cobbler are you running?  (rpm -q cobbler) ?
>
>     You mention a copy seems to be allowed.   Yes, it is.   This is one of
>     those things that is pretty much required to make the copy easy to
>     use,
>     since it's hard to copy everything and supply correct arguments on the
>     command line.    Enforcing the check at the copy time is one of the
>     limitations of the duplicate hostname supression feature.  It's
>     there as
>     a safeguard, but it's not flawless.   A good tactic is to name your
>     systems after your hostname parameters and make sure they match.  
>     (You
>     could probably even write some clever cobbler triggers to do more
>     checks
>     if you wanted)
>
>     Also, I should point out in 1.3, the hostname field per interface has
>     been renamed to "--dns-name" and there is a global --hostname
>     that will set the /etc/sysconfig/network hostname.    Configurations
>     will be migrated automatically so this is not something users will
>     need to worry about.
>
>     --Michael
>     >
>     > [EMAIL PROTECTED] dhcpd]# cobbler system edit --name=foo 
> --interface=eth0
>     > --hostname=foo
>     > [EMAIL PROTECTED] dhcpd]# cobbler system edit --name=foo 
> --interface=eth1
>     > --hostname=foo
>     > [EMAIL PROTECTED] dhcpd]# cobbler system edit --name=foo 
> --interface=eth2
>     > --hostname=foo
>     > [EMAIL PROTECTED] dhcpd]# cobbler sync
>     > [EMAIL PROTECTED] dhcpd]#
>     >
>     > [EMAIL PROTECTED] dhcpd]# cobbler system edit --name=foo 
> --interface=eth0
>     > --hostname=foo --ip=1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     --subnet=255.255.255.0 <http://255.255.255.0>
>     > <http://255.255.255.0>
>     > [EMAIL PROTECTED] dhcpd]# cobbler system edit --name=foo 
> --interface=eth1
>     > --hostname=foo --ip=1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     --subnet=255.255.255.0 <http://255.255.255.0>
>     > <http://255.255.255.0>
>     > [EMAIL PROTECTED] dhcpd]# cobbler system edit --name=foo 
> --interface=eth2
>     > --hostname=foo --ip=1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     --subnet=255.255.255.0 <http://255.255.255.0>
>     > <http://255.255.255.0>
>     > [EMAIL PROTECTED] dhcpd]# cobbler sync
>     >
>     > [EMAIL PROTECTED] dhcpd]# cobbler system report --name=foo
>     > system                : foo
>     > profile               : Legacy-Image-v1.0
>     > comment               :
>     > created               : Wed Nov 26 05:13:46 2008
>     > image                 :
>     > kernel options        : {}
>     > kernel options post   : {}
>     > kickstart             : <<inherit>>
>     > ks metadata           : {}
>     > mgmt classes          : []
>     > modified              : Wed Nov 26 05:18:03 2008
>     > netboot enabled?      : True
>     > owners                : ['admin']
>     > server                : <<inherit>>
>     > template files        : {}
>     > virt cpus             : <<inherit>>
>     > virt file size        : <<inherit>>
>     > virt path             : <<inherit>>
>     > virt ram              : <<inherit>>
>     > virt type             : <<inherit>>
>     > power type            : ipmitool
>     > power address         :
>     > power user            :
>     > power password        :
>     > power id              :
>     > interface        : eth0
>     >   bonding        :
>     >   bonding_master :
>     >   bonding_opts   :
>     >   dhcp tag       :
>     >   gateway        :
>     >   hostname       : foo
>     >   ip address     : 1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     >   is static?     : False
>     >   mac address    : 00:00:00:12:34:56
>     >   subnet         : 255.255.255.0 <http://255.255.255.0>
>     <http://255.255.255.0>
>     >   virt bridge    :
>     > interface        : eth1
>     >   bonding        :
>     >   bonding_master :
>     >   bonding_opts   :
>     >   dhcp tag       :
>     >   gateway        :
>     >   hostname       : foo
>     >   ip address     : 1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     >   is static?     : False
>     >   mac address    : 00:00:00:12:34:56
>     >   subnet         : 255.255.255.0 <http://255.255.255.0>
>     <http://255.255.255.0>
>     >   virt bridge    :
>     > interface        : eth2
>     >   bonding        :
>     >   bonding_master :
>     >   bonding_opts   :
>     >   dhcp tag       :
>     >   gateway        :
>     >   hostname       : foo
>     >   ip address     : 1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     >   is static?     : False
>     >   mac address    : 00:00:00:12:34:56
>     >   subnet         : 255.255.255.0 <http://255.255.255.0>
>     <http://255.255.255.0>
>     >   virt bridge    :
>     >
>     >
>     > [EMAIL PROTECTED] dhcpd]# grep duplicate /etc/cobbler/settings
>     > # if 1, cobbler will allow insertions of system records that
>     duplicate
>     > allow_duplicate_hostnames: 0
>     > # if 1, cobbler will allow insertions of system records that
>     duplicate
>     > allow_duplicate_ips: 0
>     > # if 1, cobbler will allow insertions of system records that
>     duplicate
>     > allow_duplicate_macs: 0
>     >
>     > Also a copy of a system record seems to be allowed, but not
>     forcing me
>     > to change any of the unique data in the record such as ip,
>     hostname or
>     > mac address.  See below.
>     >
>     > system                : foo
>     > profile               : Legacy-Image-v1.0
>     > comment               :
>     > created               : Wed Nov 26 05:13:46 2008
>     > image                 :
>     > kernel options        : {}
>     > kernel options post   : {}
>     > kickstart             : <<inherit>>
>     > ks metadata           : {}
>     > mgmt classes          : []
>     > modified              : Wed Nov 26 05:18:03 2008
>     > netboot enabled?      : True
>     > owners                : ['admin']
>     > server                : <<inherit>>
>     > template files        : {}
>     > virt cpus             : <<inherit>>
>     > virt file size        : <<inherit>>
>     > virt path             : <<inherit>>
>     > virt ram              : <<inherit>>
>     > virt type             : <<inherit>>
>     > power type            : ipmitool
>     > power address         :
>     > power user            :
>     > power password        :
>     > power id              :
>     > interface        : eth0
>     >   bonding        :
>     >   bonding_master :
>     >   bonding_opts   :
>     >   dhcp tag       :
>     >   gateway        :
>     >   hostname       : foo
>     >   ip address     : 1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     >   is static?     : False
>     >   mac address    : 00:00:00:12:34:56
>     >   subnet         : 255.255.255.0 <http://255.255.255.0>
>     <http://255.255.255.0>
>     >   virt bridge    :
>     > interface        : eth1
>     >   bonding        :
>     >   bonding_master :
>     >   bonding_opts   :
>     >   dhcp tag       :
>     >   gateway        :
>     >   hostname       : foo
>     >   ip address     : 1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     >   is static?     : False
>     >   mac address    : 00:00:00:12:34:56
>     >   subnet         : 255.255.255.0 <http://255.255.255.0>
>     <http://255.255.255.0>
>     >   virt bridge    :
>     > interface        : eth2
>     >   bonding        :
>     >   bonding_master :
>     >   bonding_opts   :
>     >   dhcp tag       :
>     >   gateway        :
>     >   hostname       : foo
>     >   ip address     : 1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     >   is static?     : False
>     >   mac address    : 00:00:00:12:34:56
>     >   subnet         : 255.255.255.0 <http://255.255.255.0>
>     <http://255.255.255.0>
>     >   virt bridge    :
>     >
>     > system                : foo1
>     > profile               : Legacy-Image-v1.0
>     > comment               :
>     > created               : Wed Nov 26 05:13:46 2008
>     > image                 :
>     > kernel options        : {}
>     > kernel options post   : {}
>     > kickstart             : <<inherit>>
>     > ks metadata           : {}
>     > mgmt classes          : []
>     > modified              : Wed Nov 26 05:22:00 2008
>     > netboot enabled?      : True
>     > owners                : ['admin']
>     > server                : <<inherit>>
>     > template files        : {}
>     > virt cpus             : <<inherit>>
>     > virt file size        : <<inherit>>
>     > virt path             : <<inherit>>
>     > virt ram              : <<inherit>>
>     > virt type             : <<inherit>>
>     > power type            : ipmitool
>     > power address         :
>     > power user            :
>     > power password        :
>     > power id              :
>     > interface        : eth0
>     >   bonding        :
>     >   bonding_master :
>     >   bonding_opts   :
>     >   dhcp tag       :
>     >   gateway        :
>     >   hostname       : foo
>     >   ip address     : 1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     >   is static?     : False
>     >   mac address    : 00:00:00:12:34:56
>     >   subnet         : 255.255.255.0 <http://255.255.255.0>
>     <http://255.255.255.0>
>     >   virt bridge    :
>     > interface        : eth1
>     >   bonding        :
>     >   bonding_master :
>     >   bonding_opts   :
>     >   dhcp tag       :
>     >   gateway        :
>     >   hostname       : foo
>     >   ip address     : 1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     >   is static?     : False
>     >   mac address    : 00:00:00:12:34:56
>     >   subnet         : 255.255.255.0 <http://255.255.255.0>
>     <http://255.255.255.0>
>     >   virt bridge    :
>     > interface        : eth2
>     >   bonding        :
>     >   bonding_master :
>     >   bonding_opts   :
>     >   dhcp tag       :
>     >   gateway        :
>     >   hostname       : foo
>     >   ip address     : 1.2.3.4 <http://1.2.3.4> <http://1.2.3.4>
>     >   is static?     : False
>     >   mac address    : 00:00:00:12:34:56
>     >   subnet         : 255.255.255.0 <http://255.255.255.0>
>     <http://255.255.255.0>
>     >   virt bridge    :
>     >
>     >
>     >
>     ------------------------------------------------------------------------
>     >
>     > _______________________________________________
>     > cobbler mailing list
>     > [email protected]
>     <mailto:[email protected]>
>     > https://fedorahosted.org/mailman/listinfo/cobbler
>     >
>
>     _______________________________________________
>     cobbler mailing list
>     [email protected] <mailto:[email protected]>
>     https://fedorahosted.org/mailman/listinfo/cobbler
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> cobbler mailing list
> [email protected]
> https://fedorahosted.org/mailman/listinfo/cobbler
>   

_______________________________________________
cobbler mailing list
[email protected]
https://fedorahosted.org/mailman/listinfo/cobbler

Reply via email to