- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
I wan't to start a startup script. I followed http://http//stackoverflow.com/questions/12973777/how-to-run-a-shell-script-at-startup this tutorial:
- # !/bin/sh
- ifconfig wlp1s0 down
- rfkill unblock wlan
- iwconfig wlp1s0 mode ad-hoc
- iwconfig wlp1s0 essid GalileoNetwork
- iwconfig wlp1s0 channel 10
- ifconfig wlp1s0 192.168.1.2 netmask 255.255.255.0 up
When I execute it manually it doesn't work the first try.
root@galileo:/media/card# /media/card/startup.sh
[ 68.426461] iwlwifi 0000:01:00.0: L1 Disabled; Enabling L0S
[ 68.451440] iwlwifi 0000:01:00.0: Radio type=0x1-0x0-0x1
[ 68.912137] iwlwifi 0000:01:00.0: L1 Disabled; Enabling L0S
[ 68.927567] iwlwifi 0000:01:00.0: Radio type=0x1-0x0-0x1
[ 69.199921] IPv6: ADDRCONF(NETDEV_UP): wlp1s0: link is not ready
root@galileo:/media/card#
A second try:
root@galileo:/media/card# /media/card/startup.sh
[ 297.939952] iwlwifi 0000:01:00.0: L1 Disabled; Enabling L0S
[ 297.955403] iwlwifi 0000:01:00.0: Radio type=0x1-0x0-0x1
[ 298.244089] IPv6: ADDRCONF(NETDEV_UP): wlp1s0: link is not ready
root@galileo:/media/card# [ 301.365059] wlp1s0: Selected IBSS BSSID 66:62:25:65:ea:2d based on configured SSID
[ 301.407708] iwlwifi 0000:01:00.0: Unable to find TIM Element in beacon
[ 301.425525] iwlwifi 0000:01:00.0: Unable to find TIM Element in beacon
[ 301.451519] IPv6: ADDRCONF(NETDEV_CHANGE): wlp1s0: link becomes ready
How do I make sure I have a working connection on startup?
- Tags:
- WiFi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
I think that using some bash programming at startup, i.e. execute startup.sh until you have the connection "up and running"
HTH,
Fernando.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
I think that using some bash programming at startup, i.e. execute startup.sh until you have the connection "up and running"
HTH,
Fernando.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
How do I check if "wlp1s0" is "ready" in a shell script?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
You mean to check that wlp1s0 is enabled after running the startup script? Take a look at cat /sys/class/net/wlp1s0/operstate.
Sergio

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page