Cannot set static ip on my server [solved]

Hi, i've tried to setup my servers ip to be static instead of the default dhcp one. Since it's a webserver it feels like a generally good idea. However, i have edited the interfaces file like below...

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0

iface eth0 inet static
adress 192.168.1.245
gateway 192.168.1.1
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255

...and when i do a restart on the network i get an error saying something like "Don't seem to have all the variables for eth0/inet".

What's the matter? I've searched the entire Internet and i've seen lots of example interfaces-files that looksjust like mine. What is causing this error?

Regards Fredrik

0

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Re: Cannot set static ip on my server

Quote:
iface eth0 inet static
adress 192.168.1.245

It looks like there's a typo in the word "address"; if that's the case in /etc/network/interfaces, that's enough to break it.

I'm glad I never make typos like that... :-)

Cannot set static ip on my

Very well, don't know if i'm to be crying or laughing at myself. I'm from Sweden, thats my only excuse.
Thanks for the help. That was it.

Regards Fredrik

Syndicate content