View previous topic :: View next topic |
Author |
Message |
acid_kewpie n00b

Joined: 14 Apr 2003 Posts: 39
|
Posted: Sat Aug 30, 2003 2:06 pm Post subject: assigning IP to eth0:1 over DHCP |
|
|
Hi, i want to be able to assign two IP's to my eth0 interface running on a pxe booted diskless system. as pxe obtains the first ip from dhcp it doesn't transfer a hostname than my dns can use, so on boot i want to get a second ip on eth0:1 using conventional dhcpcd so it will pass a correct hostname...
now i can achieve this manually.... "dhcpd -D -h animal eth0:1" but setting the equivalent options causes syntax errors in the file, obviosuly because of the ":".... so what can i do other than just adding the manual command.... surely this is easy for gentoo!
[or of course if anyone knows if it is possible to achieve what i originally want via pxe...] |
|
Back to top |
|
 |
Diorf n00b

Joined: 05 Jun 2003 Posts: 52 Location: Paris
|
Posted: Sat Aug 30, 2003 2:29 pm Post subject: |
|
|
if you just want to have an hostname pointing to your ip and just want this hostname to be automatically passed to the dhcp/dns at boot on eth0 you just have to look in /etc/conf.d/net for the line:
then just uncomment it and add:
Code: | dchpcd_eth0="-h yourhostname" |
Hope this help |
|
Back to top |
|
 |
acid_kewpie n00b

Joined: 14 Apr 2003 Posts: 39
|
Posted: Sat Aug 30, 2003 8:48 pm Post subject: |
|
|
yes but this then replaces the first IP, not assigning a second. replacing the first IP means that the nfs mount is incorrect, and the system dies instantly, what with no longer having any filesystem at all and all that. |
|
Back to top |
|
 |
acid_kewpie n00b

Joined: 14 Apr 2003 Posts: 39
|
Posted: Mon Sep 01, 2003 12:13 pm Post subject: |
|
|
so have I stumbled on something that gentoo actually isn't able to do? |
|
Back to top |
|
 |
really Guru


Joined: 27 Aug 2002 Posts: 430 Location: nowhere
|
Posted: Mon Sep 01, 2003 1:43 pm Post subject: |
|
|
you could add dhcpd -D -h animal eth0:1 to your /etc/conf.d/local.start  _________________ NoManNoProblem
Get lost before you get shot. |
|
Back to top |
|
 |
acid_kewpie n00b

Joined: 14 Apr 2003 Posts: 39
|
Posted: Mon Sep 01, 2003 3:25 pm Post subject: |
|
|
well that's what I am doing... but it *should* be possible to do it the gentoo way.... |
|
Back to top |
|
 |
really Guru


Joined: 27 Aug 2002 Posts: 430 Location: nowhere
|
Posted: Mon Sep 01, 2003 7:11 pm Post subject: |
|
|
if it bails out on the : in net.eth0 then you could try \: or something.. or net.eth0:1  _________________ NoManNoProblem
Get lost before you get shot. |
|
Back to top |
|
 |
|