How do I manually set up eth0 without yast or NetworkManager

Hi.
I have disabled NetworkManager, but I know that ‘network’ script is still running at boot.
My eth0 is configured to address:
192.168.1.20 255.255.255.0
When I use the commands like that:

ifdown eth0
ifconfig eth0 192.168.1.30 netmask 255.255.255.0
ifup eth0

The address is changed to 192.168.1.30 and all programs run perfectly.

When I reboot the system, the ‘network’ script returns the old address to the eth0 interface, in other words, the address comes to 192.168.1.20.

What I need to do to disable this?

Thanks in advance.

Fernando

I have forgot some informations.
I´m using OpenSuSE 11.1 KDE.

Why don’t you want to use YaST? You can set a static IP in YaST and not use Networkmanager. It only has to be done once and afterwards it will come up at boot.

Yes, I know that I can use Yast to do this.
I´m doing a configuration web pannel to this server and I need to configure the eth0 device with script.
As I know, is not possible to configure eth0 with script through Yast.

Get your script to write to /etc/sysconfig/network/ifcfg-eth0. Then run ifdown eth0 and ifup eth0.

Configure it once with YaST and you will see what the variables in the file mean.

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Or you can actually make calls to ‘ifconfig’, ‘route’ and modify
/etc/resolv.conf manually, but you’ll need to have ‘root’ privileges to
do this which is not recommended unless you are very confident about
your coding skills so you don’t inadvertently let somebody do anything
they want with your box. Also have you tried Webmin to see if it has
some samples?

Good luck.

ken yap wrote:
> Get your script to write to /etc/sysconfig/network/ifcfg-eth0. Then run
> ifdown eth0 and ifup eth0.
>
> Configure it once with YaST and you will see what the variables in the
> file mean.
>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJgL1j3s42bA80+9kRAoABAJ9HHIrwjNF3BCecex27ERvjUw2sFACdEs8P
ZDNhK1ptb2xLAVmsWNUghe8=
=GM+v
-----END PGP SIGNATURE-----