You are not logged in.

#1 2010-04-18 20:01:12

MrE
Member
From: London
Registered: 2009-01-13
Posts: 18

netcfg-wpa_actiond ambiguous redirect error

I've recently switched from networkmanager to netcfg and now wish I had taken the time to look into it earlier, as I love the speed and simplicity of netcfg!

I do run into a peculiar problem however when trying to use net-auto-wireless. I have installed netcfg, ifplugd, wpa_actiond and wpa_supplicant, as well as netcfgGUI (I like to see that I'm connected and to which network).

During the boot procedure I get the message "/usr/bin/netcfg-wpa_actiond: line 64: $WPA_CONF: ambiguous redirect"

In rc.conf I have the relevant lines:

# NETWORKING
#eth0="dhcp"
#wlan0="dhcp"
#INTERFACES=(!eth0 !wlan0)
WIRELESS_INTERFACE=(wlan0)
WIRED_INTERFACE=(eth0)

DAEMONS=(syslog-ng hal net-auto-wireless net-auto-wired !network !networkmanager ...

The computer is an Eee PC 901, using the rt2860sta module. The rt2800pci and rt2x00pci modules are blacklisted.

netcfg itself works just fine when trying to connect manually via the command line or netcfgGUI, but for completeness sake here's a copy of one of my profiles (all profiles are the same, except for the ESSID):

CONNECTION='wireless'
DESCRIPTION='A simple WPA encrypted wireless connection'
INTERFACE='wlan0'
IP='dhcp'
ESSID='USR'
SECURITY='wpa'
KEY='secret wpa passphrase'

The strange thing is that on my girlfriend's Eee PC (also a 901), net-auto-wireless works just fine. It's configured exactly the same, the only difference being that she runs KDE 4.4 whereas I run Openbox 3.4

What am I missing?

EDIT: corrected error message

Last edited by MrE (2010-04-18 20:40:00)


My new username is now Aerion in order to match my username on the AUR, Wiki and Bug Reports.

Offline

#2 2010-04-23 06:58:25

MrE
Member
From: London
Registered: 2009-01-13
Posts: 18

Re: netcfg-wpa_actiond ambiguous redirect error

A gentle bump, in the hope some new people get to read this post...

I've compared the netcfg-wpa_actiond on both netbooks but they're identical. I'm not a programmer and don't know enough about bash to understand what causes the ambiguous redirect.

Would someone be able to point me in the right direction?


My new username is now Aerion in order to match my username on the AUR, Wiki and Bug Reports.

Offline

#3 2010-04-23 09:28:00

skanky
Member
From: WAIS
Registered: 2009-10-23
Posts: 1,841

Re: netcfg-wpa_actiond ambiguous redirect error

What do you get if you type the following?

echo $TMPDIR

If it's a blank, can you list your /tmp directory?

Also, I *think* that net-auto-wireless is supposed to support the profile file as described in /etc/network.d/examples/wireless-wpa-configsection


"...one cannot be angry when one looks at a penguin."  - John Ruskin
"Life in general is a bit shit, and so too is the internet. And that's all there is." - scepticisle

Offline

#4 2010-04-23 10:16:15

MrE
Member
From: London
Registered: 2009-01-13
Posts: 18

Re: netcfg-wpa_actiond ambiguous redirect error

Thanks for your reply.

It is indeed blank so here is my /tmp listingz

ls -la /tmp

total 40k
drwxrwxrwt 11 root   root   4.0K Apr 23 09:37 .
drwxr-xr-x 19 root   root   4.0K Apr  5 13:18 ..
-rw-r--r--  1 aerion aerion    6 Apr 22 08:18 blueman-applet-1000
srwxr-xr-x  1 aerion aerion    0 Apr 23 09:36 claws-mail-1000
drwxr-xr-x  2 root   root      1 Apr 23 10:19 cron.e6gt04
-rw-------  1 aerion aerion 2.9K Apr 22 10:27 huginpto_tKEr0k
drwxrwxrwt  2 root   root      1 Apr 22 08:18 .ICE-unix
drwx------  2 root   root     40 Apr 22 08:18 libgksu-HS61nH
drwx------  2 aerion aerion 4.0K Apr 23 10:57 orbit-aerion
drwx------  2 gdm    gdm       1 Apr 22 08:18 orbit-gdm
drwx------  2 root   root     16 Apr 22 08:18 orbit-root
drwx------  2 aerion aerion    8 Apr 22 08:18 ssh-nlzkUB3438
drwx------  2 root   root      8 Apr 22 08:19 wpa.wlan0
-r--r--r--  1 root   root     11 Apr 22 08:18 .X0-lock
drwxrwxrwt  2 root   root      8 Apr 22 08:18 .X11-unix

As for the wireless-wpa-configsection, it was my understanding that this is for WPA Enterprise. Since I'm using WPA Personal,  I used the wireless-wpa profile example. The wiki section on net-auto-wireless did not mention anything about needing wireless-wpa-configsection style profiles.


My new username is now Aerion in order to match my username on the AUR, Wiki and Bug Reports.

Offline

#5 2010-04-23 10:55:42

skanky
Member
From: WAIS
Registered: 2009-10-23
Posts: 1,841

Re: netcfg-wpa_actiond ambiguous redirect error

Re configsection, see this thread: http://bbs.archlinux.org/viewtopic.php?id=91439

I'm using configsection with no issues. Incidentally, I'm also using a 901.

The ambiguous redirect message is on a line of code that redirects output to $WPA_CONF which should be (in mine and your case) should be

/tmp/wpa.wlan0/wpa.conf

The redirect error normally occurs when a wildcard is used or spaces exist in the filename and it hasn't been surrounded by quotes. I note that the line involved doesn't wrap $WPA_CONF so if it has spaces it might cause an issue. You should check the contents of the /tmp/wpa-wlan0 folder and see whether a spurious characters are in there. The function that creates it should remove spaces, but there's a comment in it pointing out that quotes should still be used.

You could insert a line into /usr/bin/netcfg-wpa_actiond (back it up first) to echo $WPA_CONF to a file:

echo "$WPA_CONF" > /tmp/wpafilepath

And see if there's an obvious error there.

If there's nothing obvious, you could try three things:

1) Edit /usr/bin/netcfg-wpa_actiond (back it up first) and change line 64 from:

echo -e "network={ \n$config \nid_str=\"$profile\" \n}" >> $WPA_CONF

to

echo -e "network={ \n$config \nid_str=\"$profile\" \n}" >> "$WPA_CONF"

If that works, report it as a bug and submit the suggested fix.

2) Try config section.

3) Try wpa-config which involves using wpa_suplicant.conf. This will avoid that line of code altogether.

It might be worth reporting it as a bug as netcfg set-up the file, so it should be able to write to it.

Have to rush off, so unable to proof-read the above. Apologies there are any errors.

Last edited by skanky (2010-04-23 10:56:25)


"...one cannot be angry when one looks at a penguin."  - John Ruskin
"Life in general is a bit shit, and so too is the internet. And that's all there is." - scepticisle

Offline

#6 2012-10-06 14:05:54

dezza
Member
From: Denmark
Registered: 2007-04-05
Posts: 126

Re: netcfg-wpa_actiond ambiguous redirect error

Sorry for reviving the old thread, but I got the exact same problem.

The  $WPA_CONF variable is empty for me in this particular case using suggestions by skanky above.

Offline

Board footer

Powered by FluxBB