DHCP restart with bulk lease data
Sten Carlsen
stenc at s-carlsen.dk
Wed Oct 30 11:54:47 UTC 2019
On 30-10-2019 11.59, Surya Teja wrote:
> I was thinking that since it leaves the .<time> file present, it may
> have problems doing the file operations.
> I did some experimenting, whatever way I make the files write
> protected, dhcpd manages to change them back. The only thing I did not
> test is SELinux.
> -------> Sten, can you suggest few steps to cross check on how to
> confirm that would be file operations issues when it has bulk data
What I did was to deliberately write-protect the files in various
combinations including giving the /var/lib/dhcp a new owner and write
protect it, then restart dhcpd. In my setup the file operations always
finished with no visible delay or other hickups. I was a bit surprised
as I did not expect dhcpd to be able to touch a write-protected file
that it does not own.
>
> On Tue, Oct 29, 2019 at 7:11 PM Sten Carlsen <stenc at s-carlsen.dk
> <mailto:stenc at s-carlsen.dk>> wrote:
>
>
>
>
>> On 29 Oct 2019, at 13.49, Surya Teja <suryateja042 at gmail.com
>> <mailto:suryateja042 at gmail.com>> wrote:
>>
>> Could there be issues with file permissions?
>> My guess is that the temporary file written can not be renamed
>> because dhcpd does not have write permissions? ------>
>> Hi Sten, I don't think it is with permission because after few
>> minutes dhcpd is restarting and granting lease, the issue is it
>> is taking long time,
>
> I was thinking that since it leaves the .<time> file present, it
> may have problems doing the file operations.
> I did some experimenting, whatever way I make the files write
> protected, dhcpd manages to change them back. The only thing I did
> not test is SELinux.
>
>> In the isc dhcp forum I observed few options like dont-use-fsync
>> but it also suggest not recommended until thorough understanding OS
>> I have installed the dhcpd on centos7, does any one have used
>> this option? Any experience with it would be much helpful for me
>>
>> Thanks in advance
>>
>> On Tue, Oct 29, 2019 at 6:12 PM Surya Teja
>> <suryateja042 at gmail.com <mailto:suryateja042 at gmail.com>> wrote:
>>
>> you're doing something wrong. With a decent disk subsystem
>> this is expected to take a few *seconds* (5 - 10 seconds
>> would be my estimate ) ---->
>> Hi sthaug I don't see any disk subsystem issues, may be I am
>> missing the cases, can you please suggest the areas or
>> commands to cross check if possible?
>>
>>
>> Thanks Teja
>>
>> On Tue, Oct 29, 2019 at 5:13 PM Sten Carlsen
>> <stenc at s-carlsen.dk <mailto:stenc at s-carlsen.dk>> wrote:
>>
>>
>>
>> > On 29 Oct 2019, at 11.20, sthaug at nethelp.no
>> <mailto:sthaug at nethelp.no> wrote:
>> >
>> >> The main thing I am facing the issue is when the data
>> is too high like
>> >> 50-60k leases in the file, the dhcpd service restart
>> is taking more time
>> >> (nearly 5-6 minutes) some times nearly 10-11 mins
>> >
>> > If a dhcpd restart with 50 - 60k leases takes 5-6
>> minutes or more,
>> > you're doing something wrong. With a decent disk
>> subsystem this is
>> > expected to take a few *seconds* (5 - 10 seconds would
>> be my estimate
>> > based on what we see here with a larger leases file).
>>
>> Could there be issues with file permissions?
>>
>> My guess is that the temporary file written can not be
>> renamed because dhcpd does not have write permissions?
>>
>> >
>> > Steinar Haug, Nethelp consulting, sthaug at nethelp.no
>> <mailto:sthaug at nethelp.no>
>> > _______________________________________________
>> > dhcp-users mailing list
>> > dhcp-users at lists.isc.org <mailto:dhcp-users at lists.isc.org>
>> > https://lists.isc.org/mailman/listinfo/dhcp-users
>>
>
--
Best regards
Sten Carlsen
No improvements come from shouting:
"MALE BOVINE MANURE!!!"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.isc.org/pipermail/dhcp-users/attachments/20191030/965bdacb/attachment-0001.htm>
More information about the dhcp-users
mailing list