I have openSUSE 13.2. My laptop connects to the internet through a WiFi network but I have an embedded device which I need to connect to it through the ethernet interface. It has an IP address of The problem is I set the IP address of the interface using this:

ifconfig enp3s0 netmask

This works fine but when the device disconnects or reboot, the connection I made is lost and the PC attempts to connect through the ethernet interface and my internet connection is lost. I have to unplug the cable, apply the command and reconnect the cable to connect to my device while not interrupting the internet connection. So is is possible to set a permanent IP so it should not interfere with other interfaces and connections ?

  • Are you using ifup or NetworkManager? You can check that in YaST -> Network Settings
    – myaut
    Apr 21, 2015 at 13:05

2 Answers 2


If it's connected to the router, many routers allow a permanent address to be assigned to a device based on its MAC address. Addresses will still be assigned by DHCP but the router will always give the device with that MAC address the IP address you specify.

  • It is not connected to a router. Direct connection to my PC
    – 3bdalla
    Apr 12, 2015 at 11:25

commands which you have to fire are : 1. Check your NIC


  1. Choose one and set it with ip which you want to give

    ifconfig enp0s8

  2. go to

    cd /etc/sysconfig/network-scripts/

  3. edit NIC file

    vim ifcfg-enp0s8

    do -->

'IPADDR' = 'NETMASK'= 'ONBOOT' = yes 'BOOTPROTO'= 'static' 5. done


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.