running dhclient for more than one interface

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

running dhclient for more than one interface

Fatemeh Mehdizadeh
Hi all,
I installed isc-dhcp-client version 4.4.1 on my Freebsd system. I want to run dhclient for more than one interfaces, but only one interface get the ip and the other encountered an error.

This is the command:
dhclient -nw  em1 -lf /var/run/routing/dhclient.leases.em1
dhclient -nw  em2 -lf /var/run/routing/dhclient.leases.em2

for em2 I have error:
Listening on BPF/em2/00:90:28:01:aa:bb
Sending on   BPF/em2/00:90:28:01:aa:bb
Can't bind to dhcp address: Address already in use
Please make sure there is no other dhcp server
running and that there's no entry for dhcp or
bootp in /etc/inetd.conf.   Also make sure you
are not running HP JetAdmin software, which
includes a bootp server.

Is it possible to have more than one dhclient binary instance on my system?

Please help me to find the solution.


_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: running dhclient for more than one interface

Pavel Zhukov
Hello,
You can start several dhclient instances (one per interface) but
different pid files  (-pd) must be specified. You can find examples in
initscripts/NetworkManager code.


On Thu, May 7, 2020 at 7:11 PM Fatemeh Mehdizadeh
<[hidden email]> wrote:

>
> Hi all,
> I installed isc-dhcp-client version 4.4.1 on my Freebsd system. I want to run dhclient for more than one interfaces, but only one interface get the ip and the other encountered an error.
>
> This is the command:
> dhclient -nw  em1 -lf /var/run/routing/dhclient.leases.em1
> dhclient -nw  em2 -lf /var/run/routing/dhclient.leases.em2
>
> for em2 I have error:
> Listening on BPF/em2/00:90:28:01:aa:bb
> Sending on   BPF/em2/00:90:28:01:aa:bb
> Can't bind to dhcp address: Address already in use
> Please make sure there is no other dhcp server
> running and that there's no entry for dhcp or
> bootp in /etc/inetd.conf.   Also make sure you
> are not running HP JetAdmin software, which
> includes a bootp server.
>
> Is it possible to have more than one dhclient binary instance on my system?
>
> Please help me to find the solution.
>
> _______________________________________________
> dhcp-users mailing list
> [hidden email]
> https://lists.isc.org/mailman/listinfo/dhcp-users



--
Pavel Zhukov
Software Engineer
IRC: landgraf

_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: running dhclient for more than one interface

Fatemeh Mehdizadeh
Hi,
I used different pid file but it dosen't work.
dhclient -nw  em1 -pf /var/run/routing/dhclient.em1.pid -lf /var/run/routing/dhclient.leases.em1
dhclient -nw  em2 -pf /var/run/routing/dhclient.em2.pid -lf /var/run/routing/dhclient.leases.em2

Is it right command?
On Mon, May 11, 2020 at 1:27 PM Pavel Zhukov <[hidden email]> wrote:
Hello,
You can start several dhclient instances (one per interface) but
different pid files  (-pd) must be specified. You can find examples in
initscripts/NetworkManager code.


On Thu, May 7, 2020 at 7:11 PM Fatemeh Mehdizadeh
<[hidden email]> wrote:
>
> Hi all,
> I installed isc-dhcp-client version 4.4.1 on my Freebsd system. I want to run dhclient for more than one interfaces, but only one interface get the ip and the other encountered an error.
>
> This is the command:
> dhclient -nw  em1 -lf /var/run/routing/dhclient.leases.em1
> dhclient -nw  em2 -lf /var/run/routing/dhclient.leases.em2
>
> for em2 I have error:
> Listening on BPF/em2/00:90:28:01:aa:bb
> Sending on   BPF/em2/00:90:28:01:aa:bb
> Can't bind to dhcp address: Address already in use
> Please make sure there is no other dhcp server
> running and that there's no entry for dhcp or
> bootp in /etc/inetd.conf.   Also make sure you
> are not running HP JetAdmin software, which
> includes a bootp server.
>
> Is it possible to have more than one dhclient binary instance on my system?
>
> Please help me to find the solution.
>
> _______________________________________________
> dhcp-users mailing list
> [hidden email]
> https://lists.isc.org/mailman/listinfo/dhcp-users



--
Pavel Zhukov
Software Engineer
IRC: landgraf

_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users

_______________________________________________
ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information.

dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: running dhclient for more than one interface

Sten Carlsen

Thanks

Sten

On 16 May 2020, at 11.48, Fatemeh Mehdizadeh <[hidden email]> wrote:

Hi,
I used different pid file but it dosen't work.
dhclient -nw  em1 -pf /var/run/routing/dhclient.em1.pid -lf /var/run/routing/dhclient.leases.em1
dhclient -nw  em2 -pf /var/run/routing/dhclient.em2.pid -lf /var/run/routing/dhclient.leases.em2

Looking at the man page it seems the if should come last on the command lline:

dhclient -nw  -pf /var/run/routing/dhclient.em1.pid -lf /var/run/routing/dhclient.leases.em1 em1

I have not tried this, I don't know if it matters. It could be that anything after the if is ignored, might be worth trying.


Is it right command?


_______________________________________________
ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information.

dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: running dhclient for more than one interface

Simon Hobson
BST, Sten Carlsen <[hidden email]> wrote:

>Looking at the man page it seems the if should come last on the command
>lline:
>
>dhclient -nw  -pf /var/run/routing/dhclient.em1.pid -lf
>/var/run/routing/dhclient.leases.em1 em1

That would seem to be a likely candidate. I assume the clients shares some of the code base with the server - where (IIRC) interfaces to listen on are specified as zero or more listed after all other parameters.

Simon
_______________________________________________
ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information.

dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users