Hi,
I have setup Cobbler to use DHCP and the cobbler itself resides on multiple VLANs (over a Bond).
My intention is to get the ks=http://<server>/cblr/svc.. to point at the interface if of the Cobbler server for that VLAN.
When adding a system, --server-override=string can be used but I don't want this to be put on the cobbler users -- or additional code for fixing that.
My understanding is that the /etc/cobbler/dhcp.template file can be updated to provide the correct installation server. Is this correct?
My /etc/cobbler/dhcp.template today contains network definitions, such as (masked):
subnet aa.bb.cc.dd netmask 255.255.254.0 { option routers aa.bb.cc.1; option domain-name-servers xxx,yyy; option subnet-mask 255.255.254.0; filename "/pxelinux.0"; default-lease-time 21600; max-lease-time 43200; next-server aa.bb.cc.YY; (the IP of the cobbler server for that VLAN) }
EVERYTHING below: #for dhcp_tag in $dhcp_tags.keys(): ... ... IS unmodified.
I would appreciate the simpliest and cleanest way to keep the traffic within the VLAN without user intervention.
Best Regards,
Daniel
In my previous email, we specify the 'option routers xxxxx' per each network. When we get the /etc/dhcp/dhcpd.conf file generated from Cobbler, no 'option routers' is included. Where does Cobbler find the router info per VLAN?
If we can get the 'option routers' included per each host, the kickstart server setup (ks=) in the grub config file can use the same ip for all VLANs, even if this isn't the ideal solution.
/Daniel
On Wed, May 4, 2011 at 5:08 PM, Daniel Kertby kertby@gmail.com wrote:
Hi,
I have setup Cobbler to use DHCP and the cobbler itself resides on multiple VLANs (over a Bond).
My intention is to get the ks=http://<server>/cblr/svc.. to point at the interface if of the Cobbler server for that VLAN.
When adding a system, --server-override=string can be used but I don't want this to be put on the cobbler users -- or additional code for fixing that.
My understanding is that the /etc/cobbler/dhcp.template file can be updated to provide the correct installation server. Is this correct?
My /etc/cobbler/dhcp.template today contains network definitions, such as (masked):
subnet aa.bb.cc.dd netmask 255.255.254.0 { option routers aa.bb.cc.1; option domain-name-servers xxx,yyy; option subnet-mask 255.255.254.0; filename "/pxelinux.0"; default-lease-time 21600; max-lease-time 43200; next-server aa.bb.cc.YY; (the IP of the cobbler server for that VLAN) }
EVERYTHING below: #for dhcp_tag in $dhcp_tags.keys(): ... ... IS unmodified.
I would appreciate the simpliest and cleanest way to keep the traffic within the VLAN without user intervention.
Best Regards,
Daniel
On Wed, May 4, 2011 at 11:08 AM, Daniel Kertby kertby@gmail.com wrote:
Hi,
I have setup Cobbler to use DHCP and the cobbler itself resides on multiple VLANs (over a Bond).
My intention is to get the ks=http://<server>/cblr/svc.. to point at the interface if of the Cobbler server for that VLAN.
When adding a system, --server-override=string can be used but I don't want this to be put on the cobbler users -- or additional code for fixing that.
My understanding is that the /etc/cobbler/dhcp.template file can be updated to provide the correct installation server. Is this correct?
Yes. Use the --dhcp-tag system parameter to assign different values to $next_server. For example, let's say you have 3 VLANs. You could assign to --dhcp_tag arbitrary values like "VLAN1", "VLAN2", and "VLAN3". Then, you could add this Cheetah markup to redefine $next_server before the :#for dhcp_tag" loop begins:
#if $dhcp_tag == "VLAN1" #set global next_server = <vlan1 IP> #else if $dhcp_tag == "VLAN2" #set global next_server = <vlan2 IP> #else if $dhcp_tag == "VLAN3" #set global next_server = <vlan3 IP> #end if
At least, I assume this should work. It all depends on whether or not Cobbler allows you to change its built-in variables.
More information here: https://fedorahosted.org/cobbler/wiki/KickstartTemplating and here: https://fedorahosted.org/cobbler/wiki/KickstartSnippets.
Thanks for quick response!
So, if I add the lines below, where does the VLAN1,VLAN2 and VLAN3 labels come from? - Are they from a another place in the dhcp-template file? - Labels setup per each network interface in Linux? - Elsewhere?
/Daniel
On Wed, May 4, 2011 at 5:54 PM, Greg Chavez greg.chavez@gmail.com wrote:
On Wed, May 4, 2011 at 11:08 AM, Daniel Kertby kertby@gmail.com wrote:
Hi,
I have setup Cobbler to use DHCP and the cobbler itself resides on
multiple
VLANs (over a Bond).
My intention is to get the ks=http://<server>/cblr/svc.. to point at the interface if of the Cobbler server for that VLAN.
When adding a system, --server-override=string can be used but I don't
want
this to be put on the cobbler users -- or additional code for fixing that.
My understanding is that the /etc/cobbler/dhcp.template file can be
updated
to provide the correct installation server. Is this correct?
Yes. Use the --dhcp-tag system parameter to assign different values to $next_server. For example, let's say you have 3 VLANs. You could assign to --dhcp_tag arbitrary values like "VLAN1", "VLAN2", and "VLAN3". Then, you could add this Cheetah markup to redefine $next_server before the :#for dhcp_tag" loop begins:
#if $dhcp_tag == "VLAN1" #set global next_server = <vlan1 IP> #else if $dhcp_tag == "VLAN2" #set global next_server = <vlan2 IP> #else if $dhcp_tag == "VLAN3" #set global next_server = <vlan3 IP> #end if
At least, I assume this should work. It all depends on whether or not Cobbler allows you to change its built-in variables.
More information here: https://fedorahosted.org/cobbler/wiki/KickstartTemplating and here: https://fedorahosted.org/cobbler/wiki/KickstartSnippets.
--
--Greg Chavez
cobbler mailing list cobbler@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/cobbler
So, if I add the lines below, where does the VLAN1,VLAN2 and VLAN3 labels come from? - Are they from a another place in the dhcp-template file? - Labels setup per each network interface in Linux? - Elsewhere?
No, you set them in the system object. This can be found under Networking in the web console, or by running "cobbler system edit --name=<system name> --dhcp_tag=<arbitrary value>".
If you do a search for "dhcp_tag" in the cobbler list archives, you should find a thread on how we use it to manage replicated cobbler instances on different subnets.
On Wed, May 4, 2011 at 5:54 PM, Greg Chavez greg.chavez@gmail.com wrote:
On Wed, May 4, 2011 at 11:08 AM, Daniel Kertby kertby@gmail.com wrote:
Hi,
I have setup Cobbler to use DHCP and the cobbler itself resides on multiple VLANs (over a Bond).
My intention is to get the ks=http://<server>/cblr/svc.. to point at the interface if of the Cobbler server for that VLAN.
When adding a system, --server-override=string can be used but I don't want this to be put on the cobbler users -- or additional code for fixing that.
My understanding is that the /etc/cobbler/dhcp.template file can be updated to provide the correct installation server. Is this correct?
Yes. Use the --dhcp-tag system parameter to assign different values to $next_server. For example, let's say you have 3 VLANs. You could assign to --dhcp_tag arbitrary values like "VLAN1", "VLAN2", and "VLAN3". Then, you could add this Cheetah markup to redefine $next_server before the :#for dhcp_tag" loop begins:
#if $dhcp_tag == "VLAN1" #set global next_server = <vlan1 IP> #else if $dhcp_tag == "VLAN2" #set global next_server = <vlan2 IP> #else if $dhcp_tag == "VLAN3" #set global next_server = <vlan3 IP> #end if
At least, I assume this should work. It all depends on whether or not Cobbler allows you to change its built-in variables.
More information here: https://fedorahosted.org/cobbler/wiki/KickstartTemplating and here: https://fedorahosted.org/cobbler/wiki/KickstartSnippets.
--
--Greg Chavez
cobbler mailing list cobbler@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/cobbler
cobbler mailing list cobbler@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/cobbler
And come to think of it, I think you'd want to place that Cheetah code *after* the loop begins, so:
#for dhcp_tag in $dhcp_tags.keys(): #if $dhcp_tag == "VLAN1" #set global next_server = <vlan1 IP> #else if $dhcp_tag == "VLAN2" #set global next_server = <vlan2 IP> #else if $dhcp_tag == "VLAN3" #set global next_server = <vlan3 IP> #end if ...<group block> .. #end for
Also, I'm not sure you need the "global" parameter. Frankly, I know very little about Cheetah; I usually get it to work through a trial-and-error process :(
On Wed, May 4, 2011 at 12:25 PM, Greg Chavez greg.chavez@gmail.com wrote:
So, if I add the lines below, where does the VLAN1,VLAN2 and VLAN3 labels come from? - Are they from a another place in the dhcp-template file? - Labels setup per each network interface in Linux? - Elsewhere?
No, you set them in the system object. This can be found under Networking in the web console, or by running "cobbler system edit --name=<system name> --dhcp_tag=<arbitrary value>".
If you do a search for "dhcp_tag" in the cobbler list archives, you should find a thread on how we use it to manage replicated cobbler instances on different subnets.
On Wed, May 4, 2011 at 5:54 PM, Greg Chavez greg.chavez@gmail.com wrote:
On Wed, May 4, 2011 at 11:08 AM, Daniel Kertby kertby@gmail.com wrote:
Hi,
I have setup Cobbler to use DHCP and the cobbler itself resides on multiple VLANs (over a Bond).
My intention is to get the ks=http://<server>/cblr/svc.. to point at the interface if of the Cobbler server for that VLAN.
When adding a system, --server-override=string can be used but I don't want this to be put on the cobbler users -- or additional code for fixing that.
My understanding is that the /etc/cobbler/dhcp.template file can be updated to provide the correct installation server. Is this correct?
Yes. Use the --dhcp-tag system parameter to assign different values to $next_server. For example, let's say you have 3 VLANs. You could assign to --dhcp_tag arbitrary values like "VLAN1", "VLAN2", and "VLAN3". Then, you could add this Cheetah markup to redefine $next_server before the :#for dhcp_tag" loop begins:
#if $dhcp_tag == "VLAN1" #set global next_server = <vlan1 IP> #else if $dhcp_tag == "VLAN2" #set global next_server = <vlan2 IP> #else if $dhcp_tag == "VLAN3" #set global next_server = <vlan3 IP> #end if
At least, I assume this should work. It all depends on whether or not Cobbler allows you to change its built-in variables.
More information here: https://fedorahosted.org/cobbler/wiki/KickstartTemplating and here: https://fedorahosted.org/cobbler/wiki/KickstartSnippets.
--
--Greg Chavez
cobbler mailing list cobbler@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/cobbler
cobbler mailing list cobbler@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/cobbler
--
--Greg Chavez
Thanks alot Greg,
If ANYONE know how to use linux network details or dhcp provided info to auto-populate the grub menu with correct ks-server info it would be really appreciated.
I still don't know why the default routes for the different networks(VLANs) aren't picked up when the dhcpd.conf file is generated by cbbler If someone have a clue it would be appreciated.
Else, I will do a script wrapper for the "cobbler system add " command which will pickup the cobbler server VLAN interface ip from a matrix file. I was hoping that the cobbler framework could fix this since I can't hand that decision/choice to the end users and hoped that I could avoid unnecessary workarounds...
Regards, Daniel
On Wed, May 4, 2011 at 6:37 PM, Greg Chavez greg.chavez@gmail.com wrote:
And come to think of it, I think you'd want to place that Cheetah code *after* the loop begins, so:
#for dhcp_tag in $dhcp_tags.keys(): #if $dhcp_tag == "VLAN1" #set global next_server = <vlan1 IP> #else if $dhcp_tag == "VLAN2" #set global next_server = <vlan2 IP> #else if $dhcp_tag == "VLAN3" #set global next_server = <vlan3 IP> #end if ...<group block> .. #end for
Also, I'm not sure you need the "global" parameter. Frankly, I know very little about Cheetah; I usually get it to work through a trial-and-error process :(
On Wed, May 4, 2011 at 12:25 PM, Greg Chavez greg.chavez@gmail.com wrote:
So, if I add the lines below, where does the VLAN1,VLAN2 and VLAN3
labels
come from?
- Are they from a another place in the dhcp-template file?
- Labels setup per each network interface in Linux?
- Elsewhere?
No, you set them in the system object. This can be found under Networking in the web console, or by running "cobbler system edit --name=<system name> --dhcp_tag=<arbitrary value>".
If you do a search for "dhcp_tag" in the cobbler list archives, you should find a thread on how we use it to manage replicated cobbler instances on different subnets.
On Wed, May 4, 2011 at 5:54 PM, Greg Chavez greg.chavez@gmail.com
wrote:
On Wed, May 4, 2011 at 11:08 AM, Daniel Kertby kertby@gmail.com
wrote:
Hi,
I have setup Cobbler to use DHCP and the cobbler itself resides on multiple VLANs (over a Bond).
My intention is to get the ks=http://<server>/cblr/svc.. to point at
the
interface if of the Cobbler server for that VLAN.
When adding a system, --server-override=string can be used but I
don't
want this to be put on the cobbler users -- or additional code for fixing that.
My understanding is that the /etc/cobbler/dhcp.template file can be updated to provide the correct installation server. Is this correct?
Yes. Use the --dhcp-tag system parameter to assign different values to $next_server. For example, let's say you have 3 VLANs. You could assign to --dhcp_tag arbitrary values like "VLAN1", "VLAN2", and "VLAN3". Then, you could add this Cheetah markup to redefine $next_server before the :#for dhcp_tag" loop begins:
#if $dhcp_tag == "VLAN1" #set global next_server = <vlan1 IP> #else if $dhcp_tag == "VLAN2" #set global next_server = <vlan2 IP> #else if $dhcp_tag == "VLAN3" #set global next_server = <vlan3 IP> #end if
At least, I assume this should work. It all depends on whether or not Cobbler allows you to change its built-in variables.
More information here: https://fedorahosted.org/cobbler/wiki/KickstartTemplating and here: https://fedorahosted.org/cobbler/wiki/KickstartSnippets.
--
--Greg Chavez
cobbler mailing list cobbler@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/cobbler
cobbler mailing list cobbler@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/cobbler
--
--Greg Chavez
--
--Greg Chavez
cobbler mailing list cobbler@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/cobbler
Daniel,
You could create another profile and set the server override option to the appropriate cobbler server IP. This will update the pxe-boot files utilized.
-Tim
--- On Wed, 5/4/11, Daniel Kertby kertby@gmail.com wrote:
From: Daniel Kertby kertby@gmail.com Subject: Re: Confused, multiple vlans and http_server ip per each VLAN To: "cobbler mailing list" cobbler@lists.fedorahosted.org Date: Wednesday, May 4, 2011, 2:30 PM
Thanks alot Greg,
If ANYONE know how to use linux network details or dhcp provided info to auto-populate the grub menu with correct ks-server info it would be really appreciated.
I still don't know why the default routes for the different networks(VLANs) aren't picked up
when the dhcpd.conf file is generated by cbbler If someone have a clue it would be appreciated.
Else, I will do a script wrapper for the "cobbler system add " command which will pickup the cobbler server VLAN interface ip from a matrix file. I was hoping that the cobbler framework could fix this since I can't hand that decision/choice to the end users and hoped that I could avoid unnecessary workarounds...
Regards, Daniel
On Wed, May 4, 2011 at 6:37 PM, Greg Chavez greg.chavez@gmail.com wrote:
And come to think of it, I think you'd want to place that Cheetah code
*after* the loop begins, so:
#for dhcp_tag in $dhcp_tags.keys():
#if $dhcp_tag == "VLAN1"
#set global next_server = <vlan1 IP>
#else if $dhcp_tag == "VLAN2"
#set global next_server = <vlan2 IP>
#else if $dhcp_tag == "VLAN3"
#set global next_server = <vlan3 IP>
#end if
...<group block> ..
#end for
Also, I'm not sure you need the "global" parameter. Frankly, I know
very little about Cheetah; I usually get it to work through a
trial-and-error process :(
On Wed, May 4, 2011 at 12:25 PM, Greg Chavez greg.chavez@gmail.com wrote:
So, if I add the lines below, where does the VLAN1,VLAN2 and VLAN3 labels
come from?
- Are they from a another place in the dhcp-template file?
- Labels setup per each network interface in Linux?
- Elsewhere?
No, you set them in the system object. This can be found under
Networking in the web console, or by running "cobbler system edit
--name=<system name> --dhcp_tag=<arbitrary value>".
If you do a search for "dhcp_tag" in the cobbler list archives, you
should find a thread on how we use it to manage replicated cobbler
instances on different subnets.
On Wed, May 4, 2011 at 5:54 PM, Greg Chavez greg.chavez@gmail.com wrote:
On Wed, May 4, 2011 at 11:08 AM, Daniel Kertby kertby@gmail.com wrote:
Hi,
I have setup Cobbler to use DHCP and the cobbler itself resides on
multiple
VLANs (over a Bond).
My intention is to get the ks=http://<server>/cblr/svc.. to point at the
interface if of the Cobbler server
for that VLAN.
When adding a system, --server-override=string can be used but I don't
want
this to be put on the
cobbler users -- or additional code for fixing that.
My understanding is that the /etc/cobbler/dhcp.template file can be
updated
to provide the correct
installation server. Is this correct?
Yes. Use the --dhcp-tag system parameter to assign different values
to $next_server. For example, let's say you have 3 VLANs. You could
assign to --dhcp_tag arbitrary values like "VLAN1", "VLAN2", and
"VLAN3". Then, you could add this Cheetah markup to redefine
$next_server before the :#for dhcp_tag" loop begins:
#if $dhcp_tag == "VLAN1"
#set global next_server = <vlan1 IP>
#else if $dhcp_tag == "VLAN2"
#set global next_server = <vlan2 IP>
#else if $dhcp_tag == "VLAN3"
#set global next_server = <vlan3 IP>
#end if
At least, I assume this should work. It all depends on whether or
not Cobbler allows you to change its built-in variables.
More information here:
https://fedorahosted.org/cobbler/wiki/KickstartTemplating and here:
--
--Greg Chavez
--
cobbler mailing list
cobbler@lists.fedorahosted.org
cobbler mailing list
cobbler@lists.fedorahosted.org
--
--Greg Chavez
--
--
--Greg Chavez
--
_______________________________________________
cobbler mailing list
cobbler@lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/cobbler
-----Inline Attachment Follows-----
_______________________________________________ cobbler mailing list cobbler@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/cobbler
cobbler@lists.fedorahosted.org