RE: NetReg: PHPNetReg?

New Message Reply Date view Thread view Subject view Author view Attachment view

From: Justin Turner (idolo3@yahoo.com)
Date: Mon Jul 28 2003 - 14:38:06 CDT


Thanks for the info.

"King, Michael" <MKing@bridgew.edu> wrote:just as an FYI,
 
There is an include command in ISC DHCP, so you conceivable have your dhcpd.conf file, that would also have in include statement to include the file that you are writing dynamically.
 
Not sure if this helps at all, since your just doing straight copies of your .base file, but it would prevent you from having to rewrite the same information every time.

-----Original Message-----
From: Justin Turner [mailto:idolo3@yahoo.com]
Sent: Sunday, July 27, 2003 6:22 PM
To: netreg@southwestern.edu
Subject: Re: NetReg: PHPNetReg?

Thank you for the logic behind your MySQL database implemenation - it has helped me a great deal. :-)

David Meuleman <dmeuleman@defiance.edu> wrote: On Fri, 25 Jul 2003 08:56:28 -0700 (PDT), Justin Turner
wrote:

> Thank you for the replys, the advice, and the link to phpreg.
> One observation I noticed was those who replied (and I'm sure those using
> the orignial Perl version) are using a mySQL backend. I would like to do
> the same. But I'm confused on how mySQL fits in with Netreg?
> Are you...
> 1. Writing to the dhcpd.conf.new file and then populating your dB so
> anytime you write to the dhcpd.conf.new file you update the dB?

New registrations are added to the MySQL table. This allows easier
checking for duplicate MACs and Usernames (don't have to parse a text file,
just search the database for them).

> 2. Using the db to create the dhcpd.conf.new file? a. By inserting (or
> using a template which contains) the sub! net declarations, pools, domain-
> name-servers, etc) and then converting your dB info into dhcpd.conf.new
> likable host records?
> b. Or perhaps reading in the dhcpd.conf.new file until ##
> line and then enter your host information from the dB?
> c. Does it matter how the file is written as long as it's written?
> I plunged into the archives for an answer to this question, but saw that
> others are using a dB to write the dhcpd.conf.new. Not neccessarily how
> they are using it.

I have a dhcpd.conf.base file which contains all the subnet declarations,
pools, etc. When a new MAC is registered (or deleted), a php script copies
the .base file to dhcpd.conf and appends all the host declarations
according to the records in the MySQL table. It then restarts dhcpd
immediately (no waiting for the cron job).

I hope that helps.

Dave

> Sorry so lengthly.
> Justin
>
>
>
>
>
>
> "Ciesinski, Nicholas Arthur" wrote:
> I re-wrote it in PHP and added a mySQL backend to it. I just never said
> anything :)
>
> Nick Ciesinski
> University of Wisconsin - Whitewater
>
> -----Original Message----- From: Justin Turner [mailto:idolo3@yahoo.com]
> Sent: Thu 7/24/2003 4:03 PM To: netreg@southwestern.edu Cc: Subject:
> NetReg: PHPNetReg?
>
>
> Hello,
>
> I have a quick question for the group...
>
> I looked through the archives and noticed no one has mentioned or
> attempted to re-write the netreg protocol in PHP and was just wondering
> why?
>
> Perhaps it's becasuse...
> 1. Pearl is better at flat file manipulation than PHP.
> 2. If it ain't broke don't fix it.
> 3. Pearl is familar, a native programming language to most people.
>> I was thinking about undertaking this endeavor for the following reasons
>
> 1. I understand PHP better than Pearl. PHP is my native tongue so to
> speak.
> 2. Faster?
> 3. Better intergration with databases such as mySQL and postSQL (in my
> opinion).
>
> Before I start on this (potentially foolish) journey, can any see any
> cavaets to using PHP than I am overlooking?
>
> Thanks for your time
> Justin
>
>
>
>
> _____
>
> Do you Yahoo!?
> The New Yahoo! Search - Faster. Easier. Bingo.
>
> **********************************************************************
> To unsubscribe from this list, send an e-mail message to
> majordomo@southwestern.edu containing a single line with the words:
> unsubscribe netreg
> Send requests for assistance to: owner-netreg@southwestern.edu
> **********************************************************************
>
>
> ---------------------------------
> Do you Yahoo!?
> The New Yahoo! Search - Faster. Easier. Bingo.

-- 

********************************************************************** To unsubscribe from this list, send an e-mail message to majordomo@southwestern.edu containing a single line with the words: unsubscribe netreg Send requests for assistance to: owner-netreg@southwestern.edu **********************************************************************

--------------------------------- Do you Yahoo!? The New Yahoo! Search - Faster. Easier. Bingo.

--------------------------------- Do you Yahoo!? The New Yahoo! Search - Faster. Easier. Bingo. ********************************************************************** To unsubscribe from this list, send an e-mail message to majordomo@southwestern.edu containing a single line with the words: unsubscribe netreg Send requests for assistance to: owner-netreg@southwestern.edu **********************************************************************


New Message Reply Date view Thread view Subject view Author view Attachment view

This archive was generated by hypermail 2.1.4 : Thu Aug 12 2004 - 12:01:40 CDT