";
$dhcphlpcont = $host['dhcphlpcont'];
$dhcpmaxlease = $host['dhcpoptmax-lease-time'];
$dhcpdefaultlease = $host['dhcpoptdefault-lease-time'];
$objectDN = $dhcphlpcont;
$rbsDN = $host['hlprbservice'];
$rbs_dhcpopt = "";
$host_dhcpopt = "";
$dhcp_selectbox = "";
##########################################################
# DHCP Setup
# DHCP Daten
if ($dhcphlpcont == ""){
$objecttype = "nodhcp";
# DHCP Selectbox
$altdhcp = alternative_dhcpobjects($objecttype,$objectDN,$hostip[0]);
$dhcp_selectbox .= "
| ";
$dhcp = "Eingebunden in DHCP Dienst: |
Rechner ist in keinem DHCP Dienst angemeldet
|
DHCP Dienst auswählen:
| ".$dhcp_selectbox;
$rbs = "
Sie müssen den Rechner zuerst in einem DHCP Dienst anmelden, bevor Sie ihn
einem Remote Boot Dienst zuordnen können (DHCP Optionen!!).
|
";
}else{
# Host in Service oder Subnet?
$objecttype = "service";
$dhcp = "";
/*$ocarray = get_node_data($dhcphlpcont,array("objectclass","dhcphlpcont"));
#print_r($ocarray); echo "
";
$sub = array_search('dhcpSubnet', $ocarray['objectclass']);
#print_r($sub);
if ($sub !== false ){
$objecttype = "subnet";
$exp0 = explode(',',$dhcphlpcont);
$expsub = explode('=',$exp0[0]); $dhcpsub = $expsub[1];
$dhcp .= "Subnet ".$dhcpsub." / ";
$dhcphlpcont = $ocarray['dhcphlpcont'];
}*/
$exp1 = explode(',',$dhcphlpcont);
$expdhcp = explode('=',$exp1[0]); $dhcpserv = $expdhcp[1];
$expdhcpau = explode('=',$exp1[2]); $dhcpau = $expdhcpau[1];
# DHCP Selectbox
$altdhcp = alternative_dhcpobjects($objecttype,$objectDN,$hostip[0]);
$dhcp_selectbox .= "
| ";
$dhcp .= "Eingebunden in DHCP Dienst: |
Service ".$dhcpserv." / AU ".$dhcpau."
|
DHCP Dienst ändern:
| ".$dhcp_selectbox;
$fixedaddselopt = "";
switch ( $host['dhcpoptfixed-address'] ){
case "":
$fixedaddress = " -
(dynamische Vergabe)";
if ( $hostip[0] != "" ){
$fixedaddselopt .= "";
}
$fixedaddselopt .= "";
break;
case "ip":
$fixedaddress = "".$hostip[0]."
(Fixe IP Adresse)";
$fixedaddselopt .= "
";
break;
case "hostname":
$fixedaddress = "".$host['hostname']."
(Fixe IP Adresse über DNS aufgelöst)";
if ( $hostip[0] != "" ){
$fixedaddselopt .= "";
}
$fixedaddselopt .= "";
break;
}
$host_dhcpopt = "
DHCP Optionen: |
hardware ethernet: |
".$host['hwaddress']." |
|
fixed-address: |
".$fixedaddress." |
|
";
}
$template->assign(array("HOSTDN" => $hostDN,
"HOSTNAME" => $host['hostname'],
"DOMAINNAME" => $host['domainname'],
"HWADDRESS" => $host['hwaddress'],
"IPADDRESS" => $hostip[0],
"DESCRIPTION" => $host['description'],
"OLDDHCP" => $objectDN,
"OLDFIXADD" => $host['dhcpoptfixed-address'],
"OLDRBS" => $rbsDN,
"DHCPCONT" => $dhcp,
"HOST_DHCPOPT" => $host_dhcpopt,
"NEXTSERVER" => $host['dhcpoptnext-server'],
"FILENAME" => $host['dhcpoptfilename'],
"DEFAULTLEASE" => $dhcpdefaultlease,
"MAXLEASE" => $dhcpmaxlease,
"HOSTLINK" => "
| ";*/
###########################################################
# RBS Setup
/*$altrbs = alternative_rbservices($rbsDN);
#print_r($altrbs); echo "
";
$template->assign(array("ALTRBSDN" => "",
"ALTRBSCN" => "",
"ALTRBSAU" => ""));
if (count($altrbs) != 0){
$template->define_dynamic("Altrbs", "Webseite");
foreach ($altrbs as $item){
$template->assign(array("ALTRBSDN" => $item['dn'],
"ALTRBSCN" => $item['cn'],
"ALTRBSAU" => $item['au'],));
$template->parse("ALTRBS_LIST", ".Altrbs");
}
}*/
###################################################################################
include("computers_footer.inc.php");
/*
DHCP Option hardware ethernet: |
{HWADDRESS}
|
DHCP Option fixed-address: |
{IPADDRESS}
|
|
TFTP Server DHCP Option next-server: |
{NEXTSERVER}
|
PXE initiale Bootdatei DHCP Option filename: |
{FILENAME}
|
*/
?>