(New user) Wifi not working, latest nixOS with Enlightenment DE on iMac (help asap appreciated)

Hello guys

Farely new linux user, have past experience with ubuntu and opensuse but obviously a lot of things are new with NixOS, I need some help setting up the wifi on my 2017 (I think) iMac, but to mention, ubuntu and opensuse have worked perfectly fine on my mac with wireless wifi working out of the box. Even nixOS worked with wireless wifi with no additional effort when I used the live Gnome image, but when after installing it with enlightenment, it’s not working and really need some help here.

When I try to connect to wifi through EConnMan on Enlightenment, it’s blank and I can’t see a single wifi network, kind of surprising to me as the live image had the wifi working perfectly.

Worth mentioning: When I was setting up NixOS Enlightenment after installing it, I had this note saying: “BlueZ bluetooth service not found” (enlightenment) while setting up, but that’s bluetooth, not wifi right? But I would appreciate a solution for this as well.

Additional information:
nixos-22.11

The live image has a number of drivers loaded, while a fresh install is pretty much a minimal system.

I don’t know much about this fruity machines, but two things to check:

  • driver added (broadcom_sta?)?
  • user added to networkmanager group?

see also here and here

Man, this is confusing me tbh, as a new user, I am not really technical at all, would appreciate any explanation like to a 5 year old.

Ah, never mind. The driver should have been detected and added by the installer.

In your configuration.nix you probably have something like

users.users.archits = {
    createHome = true;
    extraGroups = [ "dialout" "wheel" "video" "audio" "disk" "networkmanager" ];
    group = "users";
    isNormalUser = true;
    uid = 1000;
 };

Please check that "networkamanger" is listed there.

Yes, I have something like this: “extraGroups = [“networkmanager” “wheel”]” and then in the next lines bla bla @wamserma

Please post your configuration.nix and hardware-configuration.nix here. You may redact personal information (user names, hashed passwords, public keys, disk ids,…).

I’m not familiar with EConnMan on Enlightenment, but iirc Gnome is using networkmanager, not connman, which might also be a source of your issues. Some other comment I found on a similar problem suggests you need to ensure /etc/wpa_supplicant.conf is present.

Also not familiar with enlightenment, but I see from the source that EConnMan itself is just a wrapper for control, and its installation does not lead to the installation of anything as a dependency (including drivers). So I think that whatever EConnMan leverages is not there. If you know the wifi card that might help…

@wamserma
Here is configuration.nix: configuration.nix - Google Docs

Here is hardware-configuration.nix: hardware-configuration.nix - Google Docs

Some other comment I found on a similar problem suggests you need to ensure /etc/wpa_supplicant.conf is present

Any idea how or where I can see /etc/wpa_supplicant.conf?

And I also saw @Damage mention that knowing wifi card might help, but my mac has no wifi now and only nixOS, how do I see what wifi card do I have?

You do not have enabled networkmanager as already has been suggested.

https://search.nixos.org/options?channel=22.11&show=networking.networkmanager.enable&from=0&size=50&sort=relevance&type=packages&query=networking.networkmanager.enable

I see, but I need help on how/where to set it on the configuration.nix file.

Okay so here is some of the things I did.

As @NobbZ pointed out, I used sudoedit (and filename of configuration.nix which is /etc/nixos/configuration.nix) to edit through the terminal (GNU nano) and added:

# Enable networkmanager
networking.networkmanager.enable = true;

Unfortunately tried rebooting after making these changes to configuration.nix file but wifi still does not work.

You need to rebuild your system first:

sudo nixos-rebuild switch or sudo nixos-rebuild boot.

With NixOS changes to your configuration do not have an immediate effect. Instead, you set up your configuration, then tell Nix to build your NixOS system. Once that is done, the nixos-rebuild command simply flicks a switch to activate your new system. If something doesn’t work, you can simply flick the switch back and try again.

Edit: Have a look here for the basic ideas NixOS

I tried nixos-rebuild switch only and not the “boot” one yet but got an error later yesterday, I will share more details and update when I return home later today.