Tem que reiniciar o NetworkManager para obter a autoconexão do wifi

1

Estou rodando o Antergos (Arch) com o Plasma do KDE, tudo funciona, mas nos últimos dias eu tenho um problema de rede: o Wi-Fi não é autoconectado.

Eu uso o NetworkManager.

Bem, na verdade, ele é autoconectado, mas somente após 5 minutos a partir da inicialização! (5 minutos mais ou menos).

Forçando o recarregamento com

systemctl restart NetworkManager

Autoconecta.

Usando journalctl, a saída (parcial) é:

dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0095] policy: auto-activating connection 'Wifi_Casa'
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0106] device (wlp2s0): Activation: starting connection 'Wifi_Casa' (8a912e7f-0989-4d91-b9ae-b42e85eb37c6)
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0109] device (wlp2s0): state change: disconnected -> prepare (reason 'none', sys-iface-state: 'managed')
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0110] manager: NetworkManager state is now CONNECTING
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0123] device (wlp2s0): set-hw-addr: reset MAC address to 10:02:B5:05:F0:EB (preserve)
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0174] device (wlp2s0): state change: prepare -> config (reason 'none', sys-iface-state: 'managed')
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0176] device (wlp2s0): Activation: (wifi) access point 'Wifi_Casa' has security, but secrets are required.
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0176] device (wlp2s0): state change: config -> need-auth (reason 'none', sys-iface-state: 'managed')
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <warn>  [1513624133.0185] device (wlp2s0): No agents were available for this request.
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0186] device (wlp2s0): state change: need-auth -> failed (reason 'no-secrets', sys-iface-state: 'managed')
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0187] manager: NetworkManager state is now DISCONNECTED
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <warn>  [1513624133.0189] device (wlp2s0): Activation: failed for connection 'Wifi_Casa'
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0194] device (wlp2s0): state change: failed -> disconnected (reason 'none', sys-iface-state: 'managed')
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0207] device (wlp2s0): set-hw-addr: set MAC address to 52:7C:11:E8:AA:36 (scanning)
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0506] device (wlp2s0): supplicant interface state: ready -> disconnected
dic 18 20:08:53 marco-E7450 NetworkManager[640]: <info>  [1513624133.0559] device (wlp2s0): supplicant interface state: disconnected -> inactive

Coisas estranhas são:

  1. Após 5 minutos (5 ou 6 tentativas de conexão, com a mesma mensagem de saída), ele funciona automaticamente.
  2. Se eu recarregar o NetworkManager, ele funcionará imediatamente.

O que posso fazer? (Eu tentei reinstalar o NetworkManager, nm-applet e tudo relacionado)

Obrigado antecipadamente

    
por rivamarco 18.12.2017 / 20:30

3 respostas

0

Resolvido o downgrade do networkmanager de 1.10.2-1 para 1.10.0-1

De qualquer forma, a versão 1.10.2-1 não será autoconectada somente com a rede protegida por senha WPA2, eu tentei com a rede aberta e ela é autoconectada.

Meu controlador de rede (Dell Latitude E7450):

Network controller: Intel Corporation Wireless 7265 (rev 59)
    
por 19.12.2017 / 15:09
1

Essas saídas de log são todas do mesmo segundo, o que acontece a cada minuto ou mais desde a inicialização até 5min quando finalmente se conecta por conta própria? Parece que alguns agentes de autenticação não estão sendo executados, mas reiniciar o NetworkManager o faz ...

...secrets are required.
...device (wlp2s0): state change: config -> need-auth (reason 'none', sys-iface-state: 'managed')
...device (wlp2s0): No agents were available for this request.
...device (wlp2s0): state change: need-auth -> failed (reason 'no-secrets', sys-iface-state: 'managed')

Eu não tenho um sistema semelhante para verificar, mas de acordo com Gerenciador de rede da archwiki: Conecte-se à rede com segredo na inicialização :

By default, NetworkManager will not connect to networks requiring a secret automatically on boot. This is because it locks such connections to the user who makes it by default, only connecting after they have logged in. To change this, do the following:

  1. Right click on the nm-applet icon in your panel and select Edit Connections and open the Wireless tab

  2. Select the connection you want to work with and click the Edit button

  3. Check the boxes “Connect Automatically” and “Available to all users”

Log out and log back in to complete.

6.6 O desbloqueio de chaveiro após o login também pode ser interessante se o acima não funcionar.

NetworkManager requires access to the login keyring to connect to networks requiring a secret. Under most circumstances, this keyring is unlocked automatically at login, but if it isn't, and NetworkManager isn't connecting on login, you can try the following.

GNOME

Note: The following method is dated and known not to work on at least one machine!

  • In /etc/pam.d/gdm (or your corresponding daemon in /etc/pam.d), add these lines at the end of the "auth" and "session" blocks if they do not exist already:

    auth            optional        pam_gnome_keyring.so
    session         optional        pam_gnome_keyring.so  auto_start
    
  • In /etc/pam.d/passwd, use this line for the 'password' block:

    password    optional    pam_gnome_keyring.so
    

    Next time you log in, you should be asked if you want the password to be unlocked automatically on login.

SLiM login manager

See SLiM#Gnome Keyring.

Troubleshooting

While you may type both values at connection time, kdeplasma-applets-plasma-nm[broken link: archived in aur-mirror] 0.9.3.2-1 and above are capable of retrieving OpenConnect username and password directly from KWallet.

Open "KDE Wallet Manager" and look up your OpenConnect VPN connection under "Network Management|Maps". Click "Show values" and enter your credentials in key "VpnSecrets" in this form (replace username and password accordingly):

form:main:username%SEP%username%SEP%form:main:password%SEP%password

Next time you connect, username and password should appear in the "VPN secrets" dialog box.

[FYI, descobriu que pesquisando agente de segredos do NetworkManager ]

    
por 18.12.2017 / 21:24
0

Tente definir "Armazenar senha para todos os usuários (não criptografados)" na guia Segurança de Wi-Fi. Eu sei que não é a solução ideal, mas funciona para mim.

    
por 21.02.2018 / 17:22