LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 08-14-2022, 05:51 PM   #1
Skaperen
Senior Member
 
Registered: May 2009
Location: center of singularity
Distribution: Xubuntu, Ubuntu, Slackware, Amazon Linux, OpenBSD, LFS (on Sparc_32 and i386)
Posts: 2,684
Blog Entries: 31

Rep: Reputation: 176Reputation: 176
A 'wireless' setting is required if no AP path was given


i have been having a case where proper routing entries get lost in or around the access point i connect to. the wi-fi connection itself stays up, making this problem more aggravating (if it were to disconnect, i could just reconnect, again). i have found that by disconnecting and connecting back, the routes are re-established. so i have set up a script to do this. at first i had the script ping a remote host (one of mine) and detect when the routing loss happens. still, i wanted to avoid all that pinging, so i made a new script to run as a cron job and just disconnect and reconnect at certain times i have determined are before when it will lose routes.

the script executes this each time:
Code:
/usr/bin/nmcli device disconnect $interface
/usr/bin/nmcli device connect $interface
/usr/bin/ip route replace default via $ap_address dev $interface metric 600
this works most of the time. however, on occasion, the connect fails and i get this message from nmcli:
Code:
Failed to add/activate new connection: A 'wireless' setting is required if no AP path was given.
most times it connects OK with exactly these options. i'd like to know what additional "wireless setting" i could include, that it wants to have in these few cases so it would more likely succeed. is there some other issue like a weak signal that could be doing this? should i put the connection attempt in a sane loop to retry a few times and break out on success?

i do not own or administer this access point. the service is free, so i am not in the mood to complain about it if i can work around it (it's for those who live here, and their guests).
 
Old 08-20-2022, 07:37 AM   #2
upscalevalley
LQ Newbie
 
Registered: Aug 2022
Posts: 6

Rep: Reputation: 0
I think you must turn to the help desk for the help.
 
Old 08-20-2022, 07:54 PM   #3
dave67
Member
 
Registered: Apr 2007
Posts: 419

Rep: Reputation: 67
Hi

What is your host name on the computer? It cannot have spaces in it. Please use this command and post back the result.

ifconfig -a


You may want to disable IPv6 the wifi card see if that helps.
 
Old 08-21-2022, 02:36 PM   #4
Skaperen
Senior Member
 
Registered: May 2009
Location: center of singularity
Distribution: Xubuntu, Ubuntu, Slackware, Amazon Linux, OpenBSD, LFS (on Sparc_32 and i386)
Posts: 2,684

Original Poster
Blog Entries: 31

Rep: Reputation: 176Reputation: 176
i use the IPv6 though only through the tunnel.

Code:
lt1a/forums/3 /home/forums 8> hostname
lt1a
lt1a/forums/3 /home/forums 9> ifconfig -a
enp5s0f2: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether 00:90:f5:f7:55:14  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 294  bytes 28998 (28.9 KB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 294  bytes 28998 (28.9 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

tun2kepler: flags=4305<UP,POINTOPOINT,RUNNING,NOARP,MULTICAST>  mtu 1360
        inet 192.0.2.2  netmask 255.255.255.255  destination 192.0.2.1
        inet6 fe80::b667:a2a8:c614:1fca  prefixlen 64  scopeid 0x20<link>
        inet6 fdff::2  prefixlen 62  scopeid 0x0<global>
        unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00  txqueuelen 100  (UNSPEC)
        RX packets 590938  bytes 734803919 (734.8 MB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 379343  bytes 27718197 (27.7 MB)
        TX errors 0  dropped 657 overruns 0  carrier 0  collisions 0

wlp4s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 10.62.23.47  netmask 255.255.192.0  broadcast 10.62.63.255
        inet6 fe80::1821:878b:8e0d:f812  prefixlen 64  scopeid 0x20<link>
        ether fc:f8:ae:4a:ba:a5  txqueuelen 1000  (Ethernet)
        RX packets 622371  bytes 817115637 (817.1 MB)
        RX errors 0  dropped 1  overruns 0  frame 0
        TX packets 396288  bytes 69067370 (69.0 MB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lt1a/forums/3 /home/forums 10>
 
Old 08-21-2022, 05:54 PM   #5
dave67
Member
 
Registered: Apr 2007
Posts: 419

Rep: Reputation: 67
Did you recheck the script to make sure it was not doing this? I can see you host a server of some kind. I am no expert though the loopback is it not to be something like 127.0.0.1/8 or 127.0.0.1/24.
 
Old 08-21-2022, 06:47 PM   #6
Skaperen
Senior Member
 
Registered: May 2009
Location: center of singularity
Distribution: Xubuntu, Ubuntu, Slackware, Amazon Linux, OpenBSD, LFS (on Sparc_32 and i386)
Posts: 2,684

Original Poster
Blog Entries: 31

Rep: Reputation: 176Reputation: 176
there is a remote server host that the tunnel goes to. server processes for public access run there if i'm not ready to run it on AWS. server processes here (my laptop) are only for use here. from day to day the IP address i get could change and nothing cares. i do not understand your reference to a script. i have already verified that /usr/bin/nmcli is the source of this message.
 
Old 08-22-2022, 12:08 PM   #7
dave67
Member
 
Registered: Apr 2007
Posts: 419

Rep: Reputation: 67
I am wondering if this a guest access point your using has a data cap by the ISP provider. I never used tunneling but I had game servers in the past. but does tunneling have to be active on the access point?



Though this message below is suggesting that the routing is being replaced by the access point address device. Times for research for that message. Why is it stating the route is being replaced?


Code:
usr/bin/ip route replace default via $ap_address dev

Last edited by dave67; 08-30-2022 at 12:07 AM.
 
Old 08-23-2022, 06:41 PM   #8
Skaperen
Senior Member
 
Registered: May 2009
Location: center of singularity
Distribution: Xubuntu, Ubuntu, Slackware, Amazon Linux, OpenBSD, LFS (on Sparc_32 and i386)
Posts: 2,684

Original Poster
Blog Entries: 31

Rep: Reputation: 176Reputation: 176
if the route is absent, replace will just add it. so using replace means i do not need to test if the route is already there. it usually is not there since initially disconnecting discards all the associated routes. one way or the other, i get the route put in place.

i never have seen any data cap. i am likely the heaviest user. my reverse-incremental backups of my laptop to AWS have exceeded 10 GB many times. once i get connected, it works fine. i just run the connection script, again, and all is well.

Last edited by Skaperen; 08-23-2022 at 10:22 PM. Reason: one letter added and three words added
 
Old 08-30-2022, 12:36 AM   #9
dave67
Member
 
Registered: Apr 2007
Posts: 419

Rep: Reputation: 67
I been searching for this error your getting its been popping up and no one can find solutions. I may have a theory.

Are you using a bridge? This may be of help
https://unix.stackexchange.com/quest...d-ssid-is-requ



Error
Code:
Failed to add/activate new connection: A 'wireless' setting is required if no AP path was given
 
Old 09-04-2022, 12:39 PM   #10
Skaperen
Senior Member
 
Registered: May 2009
Location: center of singularity
Distribution: Xubuntu, Ubuntu, Slackware, Amazon Linux, OpenBSD, LFS (on Sparc_32 and i386)
Posts: 2,684

Original Poster
Blog Entries: 31

Rep: Reputation: 176Reputation: 176
i'm not using a bridge. but at least the referred code shows what could be needed. this might help evaluate some possible tests. at least the SSID i need to use is fixed, so if i can force that, it may get it every time. the odd thing is, more than 95% of the time it works just fine, so something works. maybe it tries get a lists of SSIDs and this one just gets lost in air (bad packet) and it goes on with the rest. the AP is several metal framed walls away though i have gotten some good bandwidth over it (20 parallel live video streams).
 
Old 09-04-2022, 05:53 PM   #11
dave67
Member
 
Registered: Apr 2007
Posts: 419

Rep: Reputation: 67
Its odd when I searched for that error code

Code:
Failed to add/activate new connection: A 'wireless' setting is required if no AP path was given
What I got was wifi connection issues listed no results for the errors you are experiencing. But it may be hard to fix the access point if you have no control over it.
 
Old 09-06-2022, 02:01 PM   #12
Skaperen
Senior Member
 
Registered: May 2009
Location: center of singularity
Distribution: Xubuntu, Ubuntu, Slackware, Amazon Linux, OpenBSD, LFS (on Sparc_32 and i386)
Posts: 2,684

Original Poster
Blog Entries: 31

Rep: Reputation: 176Reputation: 176
i'll just have to make the code retry the connection a sane number of times, assuming some noise is causing things to fail at some level that is not understood as just that.
 
Old 11-17-2023, 02:48 AM   #13
bula87
LQ Newbie
 
Registered: Nov 2023
Posts: 1

Rep: Reputation: 0
I know it is old post but maybe someone will have the same issue...
This error is poping out when you are trying to connect on disabled interface. Steps to reproduce:
nmcli r wifi off
nmcli d connect wlan0

So, if it is happening only sometimes I am guessing that NetworkManager was still initializing your interface or was not enabled on the first place.
 
Old 11-18-2023, 08:22 PM   #14
Skaperen
Senior Member
 
Registered: May 2009
Location: center of singularity
Distribution: Xubuntu, Ubuntu, Slackware, Amazon Linux, OpenBSD, LFS (on Sparc_32 and i386)
Posts: 2,684

Original Poster
Blog Entries: 31

Rep: Reputation: 176Reputation: 176
when the timed script takes the interface down, it goes to a disabled state then within 2 seconds (next line in the main script where it invokes another script to actually bring the interface up. most of the time the interface will come back up (success). sometimes it fails (about once every 2 or 3 days) in which case the interface stays down and disabled.

i have not yet added the loop to have it try again with a specified delay (maybe 1 second) for a maximum number of times (maybe 9) that it breaks out of on success (exit code 0). maybe i should add that.

lately, the failures have been less frequent, like maybe 1 per week.
 
Old 11-18-2023, 08:28 PM   #15
Skaperen
Senior Member
 
Registered: May 2009
Location: center of singularity
Distribution: Xubuntu, Ubuntu, Slackware, Amazon Linux, OpenBSD, LFS (on Sparc_32 and i386)
Posts: 2,684

Original Poster
Blog Entries: 31

Rep: Reputation: 176Reputation: 176
the time between restarts is a random number between about 18 minutes and 24 minutes.

when the restart is a success, the short downtime very rarely impacts a YouTube video. if the failure happens, of course the video freezes with the spinning circle.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
i tried using this code for deleting a user given character from a user given string mecrazyme1234 Linux - Newbie 2 06-04-2011 04:59 PM
i tried using this code for deleting a user given character from a user given string mecrazyme1234 Programming 7 06-04-2011 11:47 AM
Shell: tr can only be used when given full path (despite being in $PATH) chochem Programming 2 06-27-2008 08:37 AM
merge files, given its odd and even given timepassman Linux - Software 1 05-08-2008 01:17 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 09:41 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration