My android version is 6.0.1 and i make this work with WI-Fi Protected Setup (WPS) for that i followed some instruction. I was executed some commands before that i enabled the hotspot in my phone. The hotspot working fine. But, the commands are not executed properly.
root@sabresd_6dq:/ # **hostapd_cli** hostapd_cli v2.5-devel-6.0.1 Copyright (c) 2004-2015, Jouni Malinen <firstname.lastname@example.org> and contributors This software may be distributed under the terms of the BSD license. See README for more details. **Could not connect to hostapd – re-trying**