Send kea-dev mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
https://lists.isc.org/mailman/listinfo/kea-dev
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of kea-dev digest..."
Today's Topics:
1. Server hangs at startup - issue with lock file and NFS ?
(Chaigneau, Nicolas)
2. Re: Server hangs at startup - issue with lock file and NFS ?
(Jeremy C. Reed)
3. RE: Server hangs at startup - issue with lock file and NFS ?
(Chaigneau, Nicolas)
4. message dropped following "isRelayed" exception - log is not
explicit (Chaigneau, Nicolas)
5. Re: message dropped following "isRelayed" exception - log is
not explicit (Marcin Siodelski)
----------------------------------------------------------------------
Message: 1
Date: Tue, 2 Sep 2014 13:59:44 +0000
From: "Chaigneau, Nicolas" <[email protected]>
To: "[email protected]" <[email protected]>
Subject: Server hangs at startup - issue with lock file and NFS ?
Message-ID:
<ab94b0b675bdf14189cd5a861db36c8414181...@de-cm-mbx26.corp.capgemini.com>
Content-Type: text/plain; charset="us-ascii"
(trying again with correct address)
Hello,
First of all, I'm new on this list. If there are etiquette rules I'm not aware
of, feel free to enlighten me :)
That said. I'm trying to build and test the kea-0.9-beta1 version, but I'm
having trouble when starting kea-dhcp4.
I'm working on a Linux RHEL6 (2.6.32-358.6.2.el6.x86_64) VM.
My problem is the following:
The program seems to hang on the first call to the log API.
More specifically, on the following line in src\bin\dhcp4\main.cc:
LOG_DEBUG(dhcp4_logger, DBG_DHCP4_START, DHCP4_START_INFO)
.arg(getpid()).arg(port_number).arg(verbose_mode ? "yes" : "no");
(commenting out this line just make it hang on the subsequent line)
I've noticed the program creates a lock file (logger_lockfile) in the sources
directory.
Then it tries to do the following (strace output):
open("/home/admwpdhcp/src-kea/kea-0.9-beta1/logger_lockfile", O_RDWR|O_CREAT,
0660) = 3
umask(022) = 0111
fcntl(3, F_SETLKW, {type=F_WRLCK, whence=SEEK_SET, start=0, len=1}
Googling a bit, I found other people had similar issues with fcntl:
"fcntl system call hangs when using F_SETLK with NFS file"
(My sources are located on a NFS.)
I believe the lock file should not be created in the sources directory.
Apparently, it doesn't work with NFS.
And I guess it won't work when the server is deployed, since there won't be a
sources directory at all.
Thanks in advance for looking into this!
Regards,
Nicolas.
This message contains information that may be privileged or confidential and is
the property of the Capgemini Group. It is intended only for the person to whom
it is addressed. If you are not the intended recipient, you are not authorized
to read, print, retain, copy, disseminate, distribute, or use this message or
any part thereof. If you receive this message in error, please notify the
sender immediately and delete all copies of this message.
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<https://lists.isc.org/pipermail/kea-dev/attachments/20140902/de6d62f6/attachment-0001.html>
------------------------------
Message: 2
Date: Tue, 2 Sep 2014 09:41:32 -0500 (CDT)
From: "Jeremy C. Reed" <[email protected]>
To: "Chaigneau, Nicolas" <[email protected]>
Cc: "[email protected]" <[email protected]>
Subject: Re: Server hangs at startup - issue with lock file and NFS ?
Message-ID: <[email protected]>
Content-Type: TEXT/PLAIN; charset=US-ASCII
On Tue, 2 Sep 2014, Chaigneau, Nicolas wrote:
> I'm working on a Linux RHEL6 (2.6.32-358.6.2.el6.x86_64) VM.
> Googling a bit, I found other people had similar issues with fcntl:
>
> "fcntl system call hangs when using F_SETLK with NFS file"
I cannot find any recent issue reports with locking on NFS. Anyone have
recent links?
Anyways, we should be able to have the same functionality for this
without using the locking. In addition, maybe the routine is not needed
with newer log4cplus.
> I believe the lock file should not be created in the sources directory.
That should only be for testing purposes. How did you run kea? (which
should identify why it use the source directory)
------------------------------
Message: 3
Date: Tue, 2 Sep 2014 15:00:39 +0000
From: "Chaigneau, Nicolas" <[email protected]>
To: "Jeremy C. Reed" <[email protected]>
Cc: "[email protected]" <[email protected]>
Subject: RE: Server hangs at startup - issue with lock file and NFS ?
Message-ID:
<ab94b0b675bdf14189cd5a861db36c8414181...@de-cm-mbx26.corp.capgemini.com>
Content-Type: text/plain; charset="iso-8859-1"
I have followed the procedure described in
http://kea.isc.org/docs/kea-guide.html
I build as follows:
LOG4CPLUS_HOME=/opt/application/mwpdhcp/products/log4cplus/1.2.0-rc2
KEA_HOME=/opt/application/mwpdhcp/products/kea/0.9-beta1
./configure \
--with-openssl \
--prefix=$KEA_HOME \
--with-log4cplus=$LOG4CPLUS_HOME \
--with-dhcp-mysql
make
make install
Then I start the server with:
/opt/application/mwpdhcp/products/kea/0.9-beta1/sbin/kea-dhcp4 -c kea.conf -d
Shouldn't the lock file be in "prefix", rather than the build directory ?
Anyway, I've rebuilt with a local copy of the sources, instead of using a NFS.
The server now starts correctly (well almost - my configuration is incorrect;
but the server doesn't hang anymore).
Regards,
Nicolas.
-----Message d'origine-----
De?: Jeremy C. Reed [mailto:[email protected]]
Envoy??: mardi 2 septembre 2014 16:42
??: Chaigneau, Nicolas
Cc?: [email protected]
Objet?: Re: Server hangs at startup - issue with lock file and NFS ?
On Tue, 2 Sep 2014, Chaigneau, Nicolas wrote:
> I'm working on a Linux RHEL6 (2.6.32-358.6.2.el6.x86_64) VM.
> Googling a bit, I found other people had similar issues with fcntl:
>
> "fcntl system call hangs when using F_SETLK with NFS file"
I cannot find any recent issue reports with locking on NFS. Anyone have recent
links?
Anyways, we should be able to have the same functionality for this without
using the locking. In addition, maybe the routine is not needed with newer
log4cplus.
> I believe the lock file should not be created in the sources directory.
That should only be for testing purposes. How did you run kea? (which should
identify why it use the source directory)
This message contains information that may be privileged or confidential and is
the property of the Capgemini Group. It is intended only for the person to whom
it is addressed. If you are not the intended recipient, you are not authorized
to read, print, retain, copy, disseminate, distribute, or use this message or
any part thereof. If you receive this message in error, please notify the
sender immediately and delete all copies of this message.
------------------------------
Message: 4
Date: Wed, 3 Sep 2014 10:01:09 +0000
From: "Chaigneau, Nicolas" <[email protected]>
To: "[email protected]" <[email protected]>
Subject: message dropped following "isRelayed" exception - log is not
explicit
Message-ID:
<ab94b0b675bdf14189cd5a861db36c8414181...@de-cm-mbx26.corp.capgemini.com>
Content-Type: text/plain; charset="us-ascii"
Hello,
In case of a received message with "giaddr" but no "hops", function "isRelayed"
throws an exception (packet is considered malformed).
However, function "acceptDirectRequest" just catches the exception and returns
false. Nothing is done with the exception message.
Hence, in the log we only have:
2014-09-03 11:52:18.333 INFO [kea-dhcp4.dhcp4/5946]
DHCP4_NO_SUBNET_FOR_DIRECT_CLIENT no suitable subnet configured for a direct
client sending packet with transaction id 1234, on interface eth0.102, received
message is dropped
... which is not explicit at all.
>From the log I thought my configuration was incorrect. But the problem was
>with the message sent by client.
Only reading the code allowed me to figure out what was wrong.
Would it be possible to log the exception message ?
Regards,
Nicolas.
This message contains information that may be privileged or confidential and is
the property of the Capgemini Group. It is intended only for the person to whom
it is addressed. If you are not the intended recipient, you are not authorized
to read, print, retain, copy, disseminate, distribute, or use this message or
any part thereof. If you receive this message in error, please notify the
sender immediately and delete all copies of this message.
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<https://lists.isc.org/pipermail/kea-dev/attachments/20140903/c39ce01e/attachment-0001.html>
------------------------------
Message: 5
Date: Wed, 03 Sep 2014 13:59:32 +0200
From: Marcin Siodelski <[email protected]>
To: "Chaigneau, Nicolas" <[email protected]>,
"[email protected]" <[email protected]>
Subject: Re: message dropped following "isRelayed" exception - log is
not explicit
Message-ID: <[email protected]>
Content-Type: text/plain; charset=windows-1252
Hi Nicolas,
Thanks for reporting this. I submitted a ticket:
http://kea.isc.org/ticket/3537 to resolve this issue.
I tend to agree that this should be logged. We may consider whether it
should be a debug or info severity but something should be logged.
Marcin
On 03/09/14 12:01, Chaigneau, Nicolas wrote:
> Hello,
>
>
>
>
>
> In case of a received message with ?giaddr? but no ?hops?, function
> ?isRelayed? throws an exception (packet is considered malformed).
>
>
>
> However, function ?acceptDirectRequest? just catches the exception and
> returns false. Nothing is done with the exception message.
>
>
>
> Hence, in the log we only have:
>
> 2014-09-03 11:52:18.333 INFO [kea-dhcp4.dhcp4/5946]
> DHCP4_NO_SUBNET_FOR_DIRECT_CLIENT no suitable subnet configured for a
> direct client sending packet with transaction id 1234, on interface
> eth0.102, received message is dropped
>
>
>
> ? which is not explicit at all.
>
> From the log I thought my configuration was incorrect. But the problem
> was with the message sent by client.
>
> Only reading the code allowed me to figure out what was wrong.
>
>
>
>
>
> Would it be possible to log the exception message ?
>
>
>
>
>
> Regards,
>
> Nicolas.
>
>
>
>
>
> This message contains information that may be privileged or confidential
> and is the property of the Capgemini Group. It is intended only for the
> person to whom it is addressed. If you are not the intended recipient,
> you are not authorized to read, print, retain, copy, disseminate,
> distribute, or use this message or any part thereof. If you receive this
> message in error, please notify the sender immediately and delete all
> copies of this message.
>
>
> _______________________________________________
> kea-dev mailing list
> [email protected]
> https://lists.isc.org/mailman/listinfo/kea-dev
>
------------------------------
_______________________________________________
kea-dev mailing list
[email protected]
https://lists.isc.org/mailman/listinfo/kea-dev
End of kea-dev Digest, Vol 6, Issue 1
*************************************