Advertisement
Guest User

Untitled

a guest
Nov 26th, 2014
174
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.47 KB | None | 0 0
  1. auto lo
  2. iface lo inet loopback
  3.  
  4. auto eth0
  5. allow-hotplug eth0
  6. iface eth0 inet static
  7. address 192.168.1.101
  8. netmask 255.255.255.0
  9. gateway 0.0.0.0
  10.  
  11. #auto wlan0
  12. allow-hotplug wlan0
  13. iface wlan0 inet manual
  14. wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
  15.  
  16. iface home inet static
  17. address 192.168.0.157
  18. netmask 255.255.255.0
  19. broadcast 192.168.0.255
  20. gateway 192.168.0.1
  21.  
  22. iface default inet dhcp
  23.  
  24. pi@raspberrypi ~ $ sudo cat /etc/wpa_supplicant/wpa_supplicant.conf
  25. ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
  26. update_config=1
  27.  
  28. network={
  29. ssid="****"
  30. scan_ssid=1
  31. proto=RSN
  32. key_mgmt=WPA-PSK
  33. pairwise=CCMP TKIP
  34. group=CCMP TKIP
  35. psk="****"
  36. id_str="home"
  37. priority=5
  38. }
  39.  
  40. pi@raspberrypi ~ $ sudo cat /etc/network/interfaces
  41. auto lo
  42. iface lo inet loopback
  43.  
  44. auto eth0
  45. allow-hotplug eth0
  46. iface eth0 inet static
  47. address 192.168.1.101
  48. netmask 255.255.255.0
  49.  
  50. auto wlan0
  51. allow-hotplug wlan0
  52. iface wlan0 inet static
  53. wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
  54. address 192.168.0.157
  55. netmask 255.255.255.0
  56. broadcast 192.168.0.255
  57. gateway 192.168.0.1
  58.  
  59. iface default inet dhcp
  60.  
  61. pi@raspberrypi ~ $ sudo cat /etc/default/ifplugd
  62. INTERFACES="eth0"
  63. HOTPLUG_INTERFACES="eth0"
  64. ARGS="-q -f -u0 -d10 -w -I"
  65. SUSPEND_ACTION="stop"
  66.  
  67. pi@raspberrypi ~ $ sudo cat /etc/rc.local
  68. #!/bin/sh -e
  69.  
  70. # Print the IP address
  71. _IP=$(hostname -I) || true
  72. if [ "$_IP" ]; then
  73. printf "My IP address is %sn" "$_IP"
  74. fi
  75.  
  76. # Disable the ifplugd eth0
  77. sudo ifplugd eth0 --kill
  78. sudo ifup wlan0
  79.  
  80. exit 0
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement