LinHES Forums
http://forum.linhes.org/

How to assign static ip address in R6
http://forum.linhes.org/viewtopic.php?f=11&t=20893
Page 1 of 1

Author:  Ozdemon [ Sun Mar 07, 2010 2:36 pm ]
Post subject:  How to assign static ip address in R6

I have tried to do this using Linhes service menu/Network settings, but it does not work. Keep getting dhcp address.

From other posts it seems that there has to be a change in the one of the /etc/runit/ files.

Could someone please post an example of the code to get a fixed ip for the Linhes box?

Tks.

BTW is the /24 that appears before the subnet mask the port number?

Author:  tjc [ Sun Mar 07, 2010 6:20 pm ]
Post subject: 

No. Number of leading bits. 255.255.255.255 is 32, 255.255.255.0 is 24, 255.255.0.0 is 16, ... Typically used to specify a subnet, for example 192.168.1.0/28 would be the range 192.168.1.0 -:192.168.1.15 and 10.1.0.0/16 would be the range 10.1.0.0 - 10.1.255.255.

Author:  mihanson [ Fri Mar 12, 2010 8:56 pm ]
Post subject: 

Well, I'm not sure why the service menu is not doing it for you, but here's how to do this manually assuming eth0 is your network interface...

Code:
$ sudo nano /etc/net/ifaces/eth0/ipv4address

Change it to your desired static ip/netmask.
i.e. 192.168.1.2/24

Code:
$ sudo nano /etc/net/ifaces/eth0/ipv4route

Change it to your default gateway, usually your router's ip.
i.e. default via 192.168.1.1

Code:
$ sudo nano /etc/net/ifaces/default/options

ensure the following:
Code:
DISABLED=no
BOOTPROTO=static
ONBOOT=yes
...
CONFIG_IPV4=yes
...

There are other options in there, but they should be ok.

Finally, execute the following:
Code:
sudo /etc/net/scripts/network.init restart

If you then issue
Code:
$ sudo ifconfig
you should see your static address associated with your eth0 interface.

Author:  Girkers [ Sat Mar 13, 2010 1:41 am ]
Post subject: 

I think I had found a bug in that window (have reported it on flyspray), what you might need to do is try and change the interface and then you will see the details come up. Then you should be able to set the details.

I had to do this when I was installing 6.02 the other night.

Author:  Ozdemon [ Sat Mar 13, 2010 7:13 pm ]
Post subject:  Static IP woes

Girkers wrote:
I think I had found a bug in that window (have reported it on flyspray), what you might need to do is try and change the interface and then you will see the details come up. Then you should be able to set the details.


Girkers, what do you mean by "change the interface"?

I tried the above steps but they did not work for me (thanks anyway Mihanson). It may be the bug you mentioned.

Author:  Girkers [ Sun Mar 14, 2010 7:22 pm ]
Post subject: 

What I mean is in navigate to the field where you can pick the interface to use and then try and change the selection. In my case I used the up and down arrow keys to navigate to the field and then used the right arrow to change the option, whilst the option did not change the screen underneath did.

I hope that clears it up.

Author:  nmcaullay [ Tue Dec 14, 2010 9:31 am ]
Post subject: 

Tricks for young players.... i could set the static IP, but couldnt get outside my network (ie into the internet).

Turns out that the /etc/resolve.conf file had a default nameserver, which was not correct. I set it to my gateway address, and rebooted, and all was ok.

This was after configuring static IP in the mythfrontend GUI.

Cheers,
NAthan

Page 1 of 1 All times are UTC - 6 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/