HowTo Configure a network card in Suse/openSUSE 11.x for LAN and Internet Access
(AKA "traditional method with ifup" & includes configuration of WIFI Wireless Security).
This is a story told in screenshots, about configuring network interfaces in Yast. It's for fixed networks where a Network manager is not appropriate e.g. SOHO LAN. If you frequently switch between networks you should use a Network Manager rather than the GUI in Yast.
Here are some of the focus areas:
↑↑↑↑About IP addresses
Your network interfaces will have either dynamic IP addresses or fixed IP addresses.
Dynamic IP addresses: the majority of Suse installations connect to the Internet through a cable modem or a DSL/ADSL modem, sometimes through a router. These devices are set to "serve" or allocate IP addresses from internal DHCP servers to workstations as they boot up and come on line. These are called dynamic IP addresses. They are the do-nothing default way of getting an IP address. Suse's default installation assumes your workstation has a network interface that's connected to a DHCP server (e.g. router or modem) and thus it will likely receive its first IP address dynamically.
Fixed IP addresses: If your workstation is also a Server that maintains a network-wide service like Print Server or File Server etc, you would be well advised to give it a fixed IP address. Indeed the Administrator of a network where all IP addresses are fixed is much advantaged.
Enable Networking with Yast's "Traditional Method with IFUP" Facility
If your computer has a static network environment you don't have to use the Network Manager applet to configure it.
You can use Yast's configurator. Go To Yast --> Network Devices --> Network Settings. The panel that opens has a tab labelled "Global Settings". Choose the option Traditional method with ifup rather than the option User controlled with NetworkManager.
Pic #0 illustrates typical settings.
↑↑↑↑The openSUSE default setup: A Dynamic IP is received from your DHCP Server
This is the do-nothing default configuration that you will get when you install openSUSE. I'm reproducing it here so you can repair it easily or if you change your interface hardware. Configuration begins when you open Yast --> Network Devices --> Network settings. The panel will open at the Overview Tab:
Overview Tab: Two network interface cards (NICs) are displayed in this screenshot, a wireless NIC and an on-board NIC. We'll focus on the wireless NIC in this tutorial.
The details for whichever NIC you highlight are displayed in the lower gray panel. Notice that the details state "IP address assigned using DHCP". To change the method to Fixed IP addressing, you would click the Edit Button.
For now, we stay with this default and examine some of the details under the other Tabs: Global Options, Hostname/DNS and Routing.
Global Options Tab: You choose between Traditional Method with ifup and User Controlled with NetworkManager. The NetworkManager method is for dynamic situations like those you get with a laptop computer, moving between networks. You should always use the "Traditional ifup Method" of this tutorial when the computer and the network are stationary.
The other settings, IPv6 and DHCP show their defaults and should generally be left alone.
Occasionally some people have very slow-loading web pages at some internet sites and their problem sometimes improves if they untick the "Enable IPv6" box; otherwise leave it alone.
Hostname/DNS Tab: The hostname and domain name are first set during openSUSE's installation. The hostname is written to the file /etc/hosts as a fundamental identifier of this workstation in Linux networking. The hostname is what appears in a terminal window as the prompt and in network browsers beside the icon identifying your computer. You should change the hostname now to the name you prefer for networking purposes.
The domain name can be a full domain name like "www.swerdna.org" just a marker like the default word "site" in the screenshot; leave it alone unless you understand it.
Pic #3 screenshot shows the default (mostly empty) settings for a NIC that has DHCP dynamic IP addressing.
Routing Tab: The panel under the Routing Tab is completely empty for the default settings in openSUSE for DHCP dynamic IP addressing -- so I won't display the empty panel here. It's on this link as a reference.
If your network card is a wired ethernet card, there's usually no need to proceed further with the DHCP Dynamic IP configuration. Just click the OK Button/s to save your settings and exit. On the other hand, if your NIC is a wireless interface, you should set the wifi security by proceeding to the next section before exiting the networking GUI.
Finally, if you obtain an IP address but you can't browse the internet with this setup, you should try adding Name Servers and a Gateway to your DHCP configuration: skip down two sections.
↑↑↑↑WIFI: joining your wireless network
Proceed from the previous GUI without closing. Otherwise, goto Yast --> Network Devices --> Network Settings. The panel will open at the Overview Tab (see Pic #1) and you will see your wifi card in the list of network interfaces. Highlight the card as in Pic #1 and click the bottom Edit Button. The GUI for Network Card Setup will open and there are three tabs. They aren't relevant here but I'll link in screenshots for the three tabs for those who are interested:
Three Tabs for interest (not relevant here): General Tab Address Tab Hardware Tab
To access the wifi setup, simply ignore the three tabs mentioned above and click the Next Button at bottom right to move on to the Wireless Network Card Configuration GUI:
The Operating Mode to set for the interface when the wifi is controlled from a router is "Managed". Select it from the drop-down list.
Your ESSID or SSID (same thing) is set in your router. You can type it in the slot or click the "Scan Network" button to auto-detect it and select from the list of replies that you see.
Authentication Mode: In my router I chose the strong form of security appropriate for a small office environment (good for home too), viz: WPA-PSK. I recommend it. I used a common-language passphrase in the router because it's too hard to remember and type a very long key. So I select passphrase as the Key Input Type and type my common-language string into the slot for Encryption Key. Then I click the Next Button to lock and load everything. The GUI will exit and the wifi channel will connect. End of story.
↑↑↑↑Setting up Fixed IP addressing
If your openSUSE workstation is also a server of some kind, you most likely will give it a fixed IP address for ease of administration and to make sure the clients that need the services can find your server. Fixed IP addressing is configured in Yast --> Network Devices --> Network Settings. Highlight your network interface and click the Button to Edit the settings. A GUI with triple Tabs will open like so:
Choose the Address Tab as in Pic #5. Type the IP address that you want for your Network Interface into the slot labelled "IP Addtress". You must also enter the subnet mask.
Unless you understand hostnames and the hosts file, leave the entry in Hostname alone. If you make an entry or change the entry in the Hostname slot, it will be written to the hosts file at /etc/hosts. [In most cases you'll see the same entry there as in Pic #3.]
When finished, click the Next Button and follow the bouncing ball to lock and load.
We don't use the other Tabs (General Tab and Hardware Tab) in this section. I've linked examples for those who are interested:
General Tab Hardware Tab
↑↑↑↑Adding Name Servers and a Gateway to your IP configuration
When an IP address is assigned automatically by your DHCP server, the openSUSE software remembers the IP address of the DHCP server and uses that IP address as a gateway to the internet. Further, the software expects the gateway to pipe through the location of the databases that couple addresses like www.swerdna.org to real digital IP addresses so the web pages you are seeking can be located and displayed. These databases are called Name Servers.
Mostly this fancy footwork works and your web browser can locate and load information from the Internet. But sometimes it can't locate the Gatway and the Name Services so you have to code those yourself. That's what this section is about.
If you're having trouble with your browser or perhaps you can't ping www.swerdna.org (or whatever), open the GUI Yast --> Network Devices --> Network Settings and select the Tab Hostname/DNS, see below:
Add the IP addresses of the Name Servers that are provided for you by your Internet Service Provider (ISP). [I use BigPond Australia's 61.9.211.1. and 61.9.211.33 but they only work for BigPond users]. You'll find your Name Server IP addresses on the help pages of your ISP. If you can't, then use Google's free servers [8.8.8.8 and 8.8.4.4] or OpenDNS's free servers [208.67.222.222 and 208.67.220.220].
It remains to set the Gateway manually in the Tab for "Routing". That's almost trivially simple once Pic #6 is completed. Just add the IP address of the router into the "Gateway" slot under the "Routing" Tab in Pic #6. Here's a linked screenshot for reference.
When finished, click the OK Button to save and exit.
↑↑↑↑Network interfaces and the openSUSE firewall
All interfaces that link your computer to the internet must be set in the so-called "external zone" of Suse's firewall. Go to Yast --> Security and Users --> Firewall --> Interfaces. You'll see a list of network devices/interfaces. Highlight any NICs that address the Internet or other outside LANs/WANs and if not in the External Zone, click the Change Button and change them to External interfaces. Click Next --> Finish to exit.
Take it easy.
Swerdna, 23 October 2007. Last updated 24 May 2010