Hostapd start error - unix

make wthis this manual
http://wireless.kernel.org/en/users/Documentation/hostapd
with this config file
interface=wlan2
bridge=br0
driver=nl80211
ssid=SupaAP
country_code=RU
hw_mode=g
channel=5
preamble=1
macaddr_acl=0
auth_algs=1
logger_syslog=-1
logger_syslog_level=3
logger_stdout=-1
logger_stdout_level=2
ignore_broadcast_ssid=0
ieee80211n=1
ht_capab=[SHORT-GI-20][RX-STBC1]
wmm_enabled=1
and i have error
oot#Cubian:/home/cubie/wif/hostapd-2.1/hostapd# ./hostapd /etc/hostapd/hostapd.conf
Configuration file: /etc/hostapd/hostapd.conf
Line 16: unknown configuration item 'ieee80211n'
Line 17: unknown configuration item 'ht_capab'
2 errors found in configuration file '/etc/hostapd/hostapd.conf'
Failed to set up interface with /etc/hostapd/hostapd.conf
Failed to initialize interfac
in old version i dont have thsi error

It appears that the problem is that hostapd 2.1 is now treating an error it had differently.
This is reproducible on Ubuntu desktop versions, as the resource (WLAN) is busy.
If one turns off the programs that are accessing the resource, hostapd has a chance to grab it and work.
In Ubuntu desktop 14.04 beta, a solution is to turn off the programs that are using the wlan in question.
This worked for me:
sudo nmcli nm wifi off
sudo rfkill unblock wlan
then hostapd can start normally from command line. Of course, if you want hostapd to start on boot you must insure that the network manager is not grabbing the resource ahead of time.

SOLVED
in compile conf i uncomment string
CONFIG_IEEE80211N=y

I have found this link explaining the cause of the error and how to solve it.
https://bugs.archlinux.org/task/20269
Also I have found this other link http://blog.mirjamali.com/en/IT/Linux/hostapd which I followed and it is working with me check the configuration part.
My OS is ubuntu 12.4

start your hostapd with
hostapd -dd /etc/hostapd/hostapd.conf
you will get more information for diagnostics. In which old version you did not get the error? Did you update hostapd? Or changed your wifi adapter? which distri you are using?
http://hostap.epitest.fi/cgit/hostap/plain/hostapd/hostapd.conf
there is written how the ieee80211n settings are. for me i cant see an error.
if you remove the both lines, the ap is starting correctly?

Related

mpirun error of oneAPI with Slurm (and PBS) in old cluster

Recently I installed Intel OneAPI including c compiler, FORTRAN compiler and mpi library and complied VASP with it.
Before presenting the question, there are some tricks I need to clarify during the installation of VASP:
GLIBC2.14: the cluster is an old machine with a glibc version of 2.12, where OneAPI needs a version of 2.14. So I compile the GLIBC2.14 and export the ld_path: export LD_LIBRARY_PATH="~/mysoft/glibc214/lib:$LD_LIBRARY_PATH"
ld 2.24: The ld version is 2.20 in the cluster, while a higher version is needed. So I installed binutils 2.24.
There is one master computer connected with 30 calculating nodes in the cluster. The calculation is executed with 3 ways:
When I do the calculation in the master, it's totally OK.
When I login the nodes manually with rsh command, the calculation in the logged node is also no problem.
But usually I submit the calculation script from the master (with slurm or pbs), and then do the calculation in the node. In that case, I met following error message:
[mpiexec#node3.alineos.net] poll_for_event (../../../../../src/pm/i_hydra/libhydra/demux/hydra_demux_poll.c:159): check exit codes error
[mpiexec#node3.alineos.net] HYD_dmx_poll_wait_for_proxy_event (../../../../../src/pm/i_hydra/libhydra/demux/hydra_demux_poll.c:212): poll for event error
[mpiexec#node3.alineos.net] HYD_bstrap_setup (../../../../../src/pm/i_hydra/libhydra/bstrap/src/intel/i_hydra_bstrap.c:1062): error waiting for event
[mpiexec#node3.alineos.net] HYD_print_bstrap_setup_error_message (../../../../../src/pm/i_hydra/mpiexec/intel/i_mpiexec.c:1015): error setting up the bootstrap proxies
[mpiexec#node3.alineos.net] Possible reasons:
[mpiexec#node3.alineos.net] 1. Host is unavailable. Please check that all hosts are available.
[mpiexec#node3.alineos.net] 2. Cannot launch hydra_bstrap_proxy or it crashed on one of the hosts. Make sure hydra_bstrap_proxy is available on all hosts and it has right permissions.
[mpiexec#node3.alineos.net] 3. Firewall refused connection. Check that enough ports are allowed in the firewall and specify them with the I_MPI_PORT_RANGE variable.
[mpiexec#node3.alineos.net] 4. pbs bootstrap cannot launch processes on remote host. You may try using -bootstrap option to select alternative launcher.
I only met this error with oneAPI compiled codes but Intel® Parallel Studio XE compiled. Do you have any idea of this error? Your response will be highly appreciated.
Best,
Léon
Could it be a permissions error with the Slurm agent not having the correct permissions or library path?

HCI_UART on NRF52840, attaching the device on a Yocto based Linux SBC errors out saying "Can't init device hci0: Cannot assign requested address (99)"

I am trying to Interface a BLE module based on Nordic's nrf52840 to a Yocto based SBC, to which all the BlueZ related packages have been added.
I have flashed Zephyr's sample hci_uart program onto the module. The module seems to run perfectly on my Linux PC (BlueZ version 5.48), whereas on the SBC(BlueZ version 5.54) it fails to get inited. Here's the error that comes when I use
root#rb-imx6:~# hciconfig hci0 up
root#rb-imx6:~# Can't init device hci0: Cannot assign requested address (99)
Can anyone please help me out on this?
Thanks in advance.
The error of assigning an address is caused by missing Linux kernel configuration options:
CONFIG_CRYPTO_USER
CONFIG_CRYPTO_USER_API
CONFIG_CRYPTO_USER_API_AEAD
CONFIG_CRYPTO_USER_API_HASH
CONFIG_CRYPTO_AES
CONFIG_CRYPTO_CCM
CONFIG_CRYPTO_AEAD
CONFIG_CRYPTO_CMAC
This is likely to happen with a self-built Buildroot or Yocto Embedded Linux system. If you run into this error, you should enable above options and recompile the kernel.
See the BlueZ requirements here: https://git.kernel.org/pub/scm/bluetooth/bluez.git/tree/README#n64
To see detailed debug output from BlueZ, run it with -d option:
bluetoothd -d

Chrome debugging port not open after 10 seconds

I am using following code: It works good on local system and one unix server, but fails on another server. Any idea what I might need to do
> library(chromote)
> set_default_chromote_object(
Chromote$new(browser = Chrome$new(args = "--no-sandbox"))
and I am getting following error:
Chrome debugging port not open after 10 seconds.
Two things you can check:
On the server in question, start chrome and go to chrome://version/ . Search the Command Line: section and make sure --enable-logging is in there.
Strat R on the server in question, and do:
library(chromote)
debug(chromote:::launch_chrome)
Now run that R-code in as normal and when it stops and waits for input, hit n and then enter and repeat hitting enter until you get to the lines you link to on github. After line 87 when output gets defined, type output on the terinal and hit enter. Inspect the output and make sure that it actually conatins the lines DevTools listening on ws:// . If it does not, see if there are other ways that logging text identifies the port it listens to. If so, I would git clone that package, go in and change the way it discovers the port number and modify the package that runs for that server.
Running Chrome without X server
There are two viable options here:
vnc
X.org dummy driver
Here is the VNC recipe:
1: VNC
a. sudo dnf install tigervnc-server (for centos 8), sudo yum install tigervnc-server (for centos 7)
b. vncserver :1 (or some other suitable number)
c. DISPLAY=:1 R # and run R code to launch chrome etc.
Now you can connect from your client and see that chrome runs as it should:
vncviewer centos.ip.address:1
2: X.org dummy
I have never done this myself, but in theory it should be straight forward if you read docs and follow a tutorial.

Fail to Run Openvswitch 2.5.0

I've removed the openvswitch version I had, and I downlaoded version (2.5.0) following the same steps in this link (https://github.com/mininet/mininet/wiki/Installing-new-version-of-Open-vSwitch) and instead of (OpenVSwitch 1.10) I used (OpenVSwitch 2.5.0). The installation went smoothly without error, but when I try to run mininent and got the following error. I've tried some suggestions I found online but none of them works.
ovs-vsctl: unix:/usr/local/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
ovs-vsctl exited with code 1
*** Error connecting to ovs-db with ovs-vsctl
Make sure that Open vSwitch is installed, that ovsdb-server is running, and that
"ovs-vsctl show" works correctly.
You may wish to try "service openvswitch-switch start".
Could you please advise me what to do ?
Cheers,
Tom
We need 2 processes for that.
ovsdb-server
ovs-vswitchd
These 2 will be started with following command.
/usr/local/share/openvswitch/scripts/ovs-ctl start
In my case, /usr/local/share/openvswitch/scripts is the default location for ovs-ctl scriot,
Hope that helps.

OpenCPU - Failed to set rlimit. ENOSYS

I already installed OpenCPU on a Ubuntu Server - Ubuntu 14.04.1 LTS (GNU/Linux 3.13.0-32-generic x86_64) - and everything worked perfectly without any problems.
Here I want to say that I really like this API and I am very thankful for all the effort from the people (I think mostly Jeroen Ooms) working on it.
Now I installed it again, but on another Server hosted at another provider. It is also a Ubuntu Server - Ubuntu 14.04.1 LTS (GNU/Linux 3.13.0-042stab093.4 x86_64) - and therefore I expected it to work as smoothly as before.
But now I have a problem. After the installation and starting the service, I wanted to check through my browser if everything is OK.
So I just opened http://xxx.xxx.xxx.xxx/ocpu like it worked on my other server. This time my browser doesn't show the OpenCPU API Explorer, but the following message:
Failed to set rlimit. ENOSYS
In call:
rlimit_wrapper("rlimit_as", hardlim, softlim, pid, verbose)
The server only has 1GB of physical memory, so I thought changing the "rlimit.as" to 1e9 instead of the standrd 2e9 would fix the problem (I also tried 750000000 and 500000000), but nothing helped (of course I restarted the service opencpu again after each change).
I also think that this is not the problem, because I guess the server would use virtual memory when an operation uses more than one GB.
I think the problem has to do with RAppArmor. So I tried to disable it and restart opencpu, but the problem didn't vanish:
$ sudo aa-disable usr.bin.r
Disabling /etc/apparmor.d/usr.bin.r.
Traceback (most recent call last):
File "/usr/sbin/aa-disable", line 30, in
tool.cmd_disable()
File "/usr/lib/python3/dist-packages/apparmor/tools.py", line 148, in cmd_disable
raise apparmor.AppArmorException(cmd_info[1])
apparmor.common.AppArmorException: 'Warning: unable to find a suitable fs in /proc/mounts, is it mounted?\nUse --subdomainfs to override.\n'
So does anyone know what the problem here could be or has any suggestions where to look for a solution (I tried to google already, but didn't find anything helpful)?
I don't think anything of the following is the cause of the problem, but since I'm not sure, I add these warnings anyways:
The only strange thing I encountered during the OpenCPU installation was this message (which appeared 4 times):
iptables v1.4.21: can't initialize iptables table `nat': Table does not exist (do you need to insmod?)
Perhaps iptables or your kernel needs to be upgraded.
But afterwards it said:
* Reloading nginx configuration nginx [ OK ]
OK
Setting up opencpu (1.4.4-trusty15) ...
Also when I tried to install RAppArmor separately, I got the following warning:
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LC_CTYPE = "UTF-8",
LANG = (unset)
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
Selecting previously unselected package r-cran-rapparmor.
And also this one:
Warning: unable to find a suitable fs in /proc/mounts, is it mounted?\nUse --subdomainfs to override.\n
Thanks in advance!
It looks like your new hosting provider uses some sort of virtualization system that has a shared kernel which limits all kind of linux functionality, including rlimit, iptables and probably apparmor. Is an actual cloud host, or something you setup yourself?
It would be helpful to debug this in R (outside of opencpu). On your server, start R in the console and type:
library(RAppArmor, lib="/usr/lib/opencpu/library")
rlimit_as(1e9)
rlimit_fsize(1e9)
rlimit_cpu(1e5)

Resources