How do I enable the wireless network adapter on centos 7 minimal install?

I have just installed centos 7 over an old windows PC. The centos 7 image was of minimal install as I had only 4 GB of pendrive available.

The wifi driver named wlp18s0b1 shows in the list if I do ip link but it's configuration file is not there in the /etc/sysconfig/network-scritps/ so I can't enable this interface using ifup. ifup wlp18s0b1 says the following.

/sbin/ifup: configuration for wlp18s0b1 not found.

Usage: ifup <configuration>

the option nmcli d shows the wifi device wlp18s0b1 listed along with the ethernet card but when I do nmcli conn up it says the following .

Error: unknown connection wlp18s0b1

I am not sure how to bring this device up with nmcli and I don't have any extra network tools such as iw, iwconfig, ifconfig, dhclient available as it was a minimal install.

I only have access to wifi from here so can't use ethernet to install these as well.

2 Answers

The ifup command is the really old way of doing things and requires manual configuration. For wireless on CentOS 7 you almost certainly want to use NetworkManager directly either through GUI (Gnome/KDE settings or nm-applet and nm-connection-editor for lightweight WMs) or using nmcli.

The following example (as root) creates a connection configuration for your WiFi:

nmcli dev wifi connect my-wireless-ssid password my-secret-password

But next time you don't want to create it again but you rather want to work with connection profiles:

nmcli connection show
nmcli connection up my-connection

Once you are up and running on your WiFi network, you can learn more about the tools.

I've issued the same problem here after installing CentOS 7.9. I've made several CentOS 7.3 installations before and never had a problem until now that I'm checking this newer version.

During installation you can configure wifi to connect to your network, you can even get an IP address but, after finishing installation and rebooting, you can't connect agait to your network's wifi. Here are some of my checks.

If I type ip link I can see my driver like wlp6s0 ... state DOWN.

Also:

# nmcli
p4p2 ethernet unavailable
wlp6s0 wifi unmanaged

After some search I read somewhere that CentOS is intended to be used on servers not on laptops so you normally won't use wifi but cable, and becasue of this NetworkManager-wifi is not installed by default. The solution is to install it manually from a USB device. You can download de RPM package from RPMFind.net, copy the file to a USB disk, and after that

# mkdir /media/usb
# mount -t aut-/dev/sdb /media/usb
# cd /media/usb
# yum install NetworkManager-wifi-1.18.8-1.el7.x86_64.rpm <-- Replace with the name of your RPM File.
# reboot

and my wifi automatically connected to the network after rebooting.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

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

You Might Also Like