Changes

From SME Server
Jump to navigationJump to search
10 bytes added ,  09:38, 28 July 2015
Line 23: Line 23:  
  # - added "GMT" indicator to Expiration col head
 
  # - added "GMT" indicator to Expiration col head
 
  #
 
  #
  echo "Source        Host                 MAC Address      IP Address      Expiration (GMT)"
+
  echo "Source        Host                     MAC Address      IP Address      Expiration (GMT)"
  echo "============= ==================== ================= =============== ================"
+
  echo "============= ========================= ================= =============== ================"
 
  #
 
  #
 
  awk ' { out = ""} \
 
  awk ' { out = ""} \
Line 34: Line 34:  
   | grep active \
 
   | grep active \
 
   | sed -e s/'[{};" ]'/\ /g  \
 
   | sed -e s/'[{};" ]'/\ /g  \
   | awk '{ printf "%-13s %-20s %-17s %-15s %-10s %-5s\n", "dhcpd.leases", $6, $5, $1, $2, $3 }'
+
   | awk '{ printf "%-13s %-25s %-17s %-15s %-10s %-5s\n", "dhcpd.leases", $6, $5, $1, $2, $3 }'
 
   
 
   
 
  #
 
  #
Line 46: Line 46:  
   | grep : \
 
   | grep : \
 
   | sed -e  s/'[{};\" ]'/\ /g -e  s/\.`config get DomainName`// \
 
   | sed -e  s/'[{};\" ]'/\ /g -e  s/\.`config get DomainName`// \
   | awk  '{ printf "%-13s %-20s %-17s %-15s %-15s \n", "dhcpd.conf", $1, $2, $3, "reservation"}'
+
   | awk  '{ printf "%-13s %-25s %-17s %-15s %-15s \n", "dhcpd.conf", $1, $2, $3, "reservation"}'
 
  #
 
  #
 
  # Finally, grab the current arp table
 
  # Finally, grab the current arp table
Line 52: Line 52:  
  arp -a \
 
  arp -a \
 
   |  sed -e s/\\..*\(/\ / -e s/\)// \
 
   |  sed -e s/\\..*\(/\ / -e s/\)// \
   |  awk '{ printf "%-13s %-20s %-17s %-15s %-15s \n", "arp", $1, $4, $2, "n/a"}'
+
   |  awk '{ printf "%-13s %-25s %-17s %-15s %-15s \n", "arp", $1, $4, $2, "n/a"}'
    
==customize the lease duration==
 
==customize the lease duration==
67

edits

Navigation menu