https://github.com/Fourdee/DietPi/issues/474#issuecomment-244546570
https://github.com/Fourdee/DietPi/commit/007b8ca96037b519e02cee5b1b5eb62a1afb85c5
New image should solve this. But i'll test.
Ready to go with my RPi B+, RPi Zero or RPi 3 for your new image. 😄
Please tell which device to use. 👍
@k-plan
Just did a test on RPi3 (haven't created the image yet, just a test), DHCP automation is fine, but static still fails to connect, same as reported 0.0.0.0 etc.
Weird.
I'll need to look into it, hoping it might be a kernel/firmware issue lol. 4.4.19
@k-plan
If you get a chance, would you be able to test RPi 1/2 with USB wifi dongle on v130. Not the automation side, just static IP on a completed installation?
If you get a chance, would you be able to test RPi 1/2 with USB wifi dongle on v130. Not the automation side, just static IP on a completed installation?
Static IP on Wifi dongle by RPI B+ did not work. (switching from DHCP)
Staitic IP on wire connection as well as DHCP wired work. (Both active WiFi=DHCP / Wired=static or DHCP)
But I will start from the scratch .... with v130 without any mod and first only with a wired connection.
@k-plan
Thanks 👍 , but no rush, will be tomorrow for me.
Just tried 4.4.21 on RPi 3. Same issue.
NETLINK: Error: Invalid argument
PS, i hate these new emotes. Bring back my yellow thumbs up! lol
@k-plan
Think i got it.
apt-get purge ifmetric
Remove metric 0
and metric 1
from /etc/network/interfaces
Now static IP works, on my RPi 3. Connection working ping google.com
v.130 on RPi B+ wired connection (DHCP) not touch dietpi.txt:
Welcome to DietPi-Software
[Info] Testing connection to http://mirrordirector.raspbian.org/raspbian/
[Info] Max duration of 20 seconds, please wait...
[Ok] Connection test | Completed
DietPi-Update
─────────────────────────────────────────────────────
Mode: Checking for DietPi updates
Please wait...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 5 100 5 0 0 26 0 --:--:-- --:--:-- --:--:-- 26
[Ok] No updates required, your DietPi installation is up to date.
[Info] Current Version : 130
[Info] Server Version : 130
DietPi-Set_Hardware
─────────────────────────────────────────────────────
Mode: preferipversion (auto)
Please wait...
[Ok] preferipversion auto | Completed
[Info] Testing connection to http://mirrordirector.raspbian.org/raspbian/
[Info] Max duration of 20 seconds, please wait...
[Ok] Connection test | Completed
DietPi
─────────────────────────────────────────────────────
Mode: Updating user data location
Please wait...
[Info] /mnt/dietpi_userdata is already symlinked to target directory.
[Ok] Completed
DietPi-Software
─────────────────────────────────────────────────────
Mode: Update & upgrade APT
Please wait...
Get:1 http://mirrordirector.raspbian.org jessie InRelease [14.9 kB]
Get:2 http://mirrordirector.raspbian.org jessie/main armhf Packages [8,981 kB]
Get:3 http://archive.raspberrypi.org jessie InRelease [13.2 kB]
Get:4 http://archive.raspberrypi.org jessie/main armhf Packages [146 kB]
Get:5 http://archive.raspberrypi.org jessie/ui armhf Packages [8,966 B]
Ign http://archive.raspberrypi.org jessie/main Translation-en_GB
Ign http://archive.raspberrypi.org jessie/main Translation-en
Ign http://archive.raspberrypi.org jessie/ui Translation-en_GB
Ign http://archive.raspberrypi.org jessie/ui Translation-en
Get:6 http://mirrordirector.raspbian.org jessie/contrib armhf Packages [37.5 kB]
Get:7 http://mirrordirector.raspbian.org jessie/non-free armhf Packages [70.3 kB]
Get:8 http://mirrordirector.raspbian.org jessie/rpi armhf Packages [1,356 B]
Ign http://mirrordirector.raspbian.org jessie/contrib Translation-en_GB
Ign http://mirrordirector.raspbian.org jessie/contrib Translation-en
Ign http://mirrordirector.raspbian.org jessie/main Translation-en_GB
Ign http://mirrordirector.raspbian.org jessie/main Translation-en
Ign http://mirrordirector.raspbian.org jessie/non-free Translation-en_GB
Ign http://mirrordirector.raspbian.org jessie/non-free Translation-en
Ign http://mirrordirector.raspbian.org jessie/rpi Translation-en_GB
Ign http://mirrordirector.raspbian.org jessie/rpi Translation-en
Fetched 9,274 kB in 29s (314 kB/s)
Reading package lists... Done
[Info] Running apt simulation to check for errors, please wait...
[Ok] Apt simulation | Completed
───────────────────────────────────────
DietPi | 19:51 | Sat 17/09/16
───────────────────────────────────────
V130 | RPi B+ (armv6l)
───────────────────────────────────────
IP Address | 192.168.100.89
───────────────────────────────────────
Welcome to DietPi-Software
DietPi-Software
─────────────────────────────────────────────────────
Mode: Update & upgrade APT
Please wait...
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages will be upgraded:
raspberrypi-sys-mods
1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 6,312 B of archives.
After this operation, 22.5 kB of additional disk space will be used.
Get:1 http://archive.raspberrypi.org/debian/ jessie/main raspberrypi-sys-mods all 20160916 [6,312 B]
Fetched 6,312 B in 0s (15.9 kB/s)
(Reading database ... 19454 files and directories currently installed.)
Preparing to unpack .../raspberrypi-sys-mods_20160916_all.deb ...
Removing old /etc/sysctl.d/98-rpi.conf...
Adjusting vm.swappiness and vm.min_free_kbytes...
Unpacking raspberrypi-sys-mods (20160916) over (20160426) ...
Setting up raspberrypi-sys-mods (20160916) ...
Removing old sysctl tweaks if present...
DietPi-Software
─────────────────────────────────────────────────────
Mode: Checking for prerequisite software
Please wait...
DietPi-Services
─────────────────────────────────────────────────────
Mode: stop
Please wait...
[Ok] cron
DietPi-Services
─────────────────────────────────────────────────────
Mode: stop
Please wait...
[Ok] cron
DietPi-Software
─────────────────────────────────────────────────────
Mode: Optimize and configure software
Please wait...
[Info] Applying DietPi optimizations and configurations for RPi B+ (armv6l)
[Info] Please wait...
# processing | D I E T P I #
DietPi-Services
─────────────────────────────────────────────────────
Mode: stop
Please wait...
[Ok] cron
DietPi-Services
─────────────────────────────────────────────────────
Mode: disable
Please wait...
[Ok] cron
DietPi-Software
─────────────────────────────────────────────────────
Mode: Installation completed
Please wait...
The system will now reboot.
This completes the DietPi-Software installation.
root@DietPi:~# processing | D I E T P I # processing
work! 👍
@Fourdee
Think i got it.
apt-get purge ifmetric
Remove metric 0 and metric 1 from /etc/network/interfacesNow it works, on my RPi 3.
oh, oh ... but no metric no https://github.com/Fourdee/DietPi/issues/265
@k-plan
oh, oh ... but no metric no #265
Yep 😞. I need to re-run the tests again to confirm. But looks like we might need to find another alternative to ifmetric
?
Now off to play Descent 2 (was Tron 2.0 last month) for 30 minutes before son goes bed, woop woop 😃
@Fourdee
ifmetric - An IPv4 route metrics manipulation tool
http://0pointer.de/lennart/projects/ifmetric/ifmetric.8.xml
http://metadata.ftp-master.debian.org/changelogs//main/i/ifmetric/ifmetric_0.3-3_changelog
But looks like we might need to find another alternative to ifmetric?
Hmm, no. It's time to use the "new" _primary network configuration tools_ 😱
root@DietPi:~# ip -V
ip utility, iproute2-ss140804
iproute2: https://wiki.linuxfoundation.org/networking/iproute2
Most network configuration manuals still refer to _ifconfig_ and _route_ as the _primary network configuration tools_, but ifconfig is known to behave inadequately in modern network environments. _They should be deprecated_, but most distros still include them. Most network configuration systems make use of ifconfig and thus provide a limited feature set. The /etc/net project aims to support most modern network technologies, as it doesn't use ifconfig and allows a system administrator to make use of all iproute2 features, including traffic control.
http://www.policyrouting.org/iproute2.doc.html
http://xmodulo.com/linux-tcpip-networking-net-tools-iproute2.html
http://baturin.org/docs/iproute2/
http://www.admin-magazine.com/Archive/2013/16/Network-management-with-the-IPRoute2-toolbox
@k-plan
For now, we will remove metric and ifmetric during patch. I'll reopen https://github.com/Fourdee/DietPi/issues/265 so we can "start again" lol 👍
Nearly forgot.
Fix automation needs new image: 🈯 http://dietpi.com/downloads/testing/DietPi_RPi-armv6-(Jessie).7z
@Fourdee
Testing:
ifmetric
and netplug
installed/etc/network/interfaces
#/etc/network/interfaces
#Please use DietPi-Config to modify network settings.
# Local
auto lo
iface lo inet loopback
# Ethernet
allow-hotplug eth0
iface eth0 inet static
## metric 0
address 192.168.0.100
netmask 255.255.255.0
network 192.168.0.0
broadcast 192.168.0.255
dns-nameservers 8.8.8.8 8.8.4.4
post-up ip route add default via 192.168.0.1 dev eth0 metric 1
pre-down ip route del default via 192.168.0.1 dev eth0
# Wifi
allow-hotplug wlan0
iface wlan0 inet static
## metric 1
address 192.168.0.200
netmask 255.255.255.0
network 192.168.0.0
broadcast 192.168.0.255
wireless-essid FuzonWifi
wireless-key abcde12345
wireless-mode Managed
wireless-power off
wpa-ssid FuzonWifi
wpa-psk abcde12345
#dns-nameservers 8.8.8.8 8.8.4.4
post-up ip route add default via 192.168.0.1 dev wlan0 metric 2
pre-down ip route del default via 192.168.0.1 dev wlan0
ip route show
👍 ping dietpi.com
and unplug/plug in ethernet cable 👍 dmesg
👍 now we must have a look in:
@Fourdee
Testing:
ifmetric
and netplug
installed/etc/network/interfaces
#/etc/network/interfaces
#Please use DietPi-Config to modify network settings.
# Local
auto lo
iface lo inet loopback
# Ethernet
allow-hotplug eth0
iface eth0 inet static
## metric 0
address 192.168.0.100
netmask 255.255.255.0
network 192.168.0.0
broadcast 192.168.0.255
dns-nameservers 8.8.8.8 8.8.4.4
post-up ip route add default via 192.168.0.1 dev eth0 metric 1
pre-down ip route del default via 192.168.0.1 dev eth0
# Wifi
allow-hotplug wlan0
iface wlan0 inet dhcp
## metric 1
address 192.168.0.200
netmask 255.255.255.0
network 192.168.0.0
broadcast 192.168.0.255
wireless-essid FuzonWifi
wireless-key abcde12345
wireless-mode Managed
wireless-power off
wpa-ssid FuzonWifi
wpa-psk abcde12345
#dns-nameservers 8.8.8.8 8.8.4.4
post-up ip route add default dev wlan0 metric 2
pre-down ip route del default dev wlan0
ip route show
👍ping dietpi.com
and unplug/plug in ethernet cable 👍dmesg
👍@Fourdee
Testing:
Yes, revert to v115 practice of either wired or wifi 😢
@k-plan
v131 image. Static IP WiFi automation should now work correctly:
http://dietpi.com/downloads/testing/DietPi_RPi-armv6-(Jessie).7z
@Fourdee
v131 image. Static IP WiFi automation should now work correctly:
Tested on RPi B+ with wifi adapter and non wired connection.
after reboot it is a DietPi v130
Hint: are you living now in USA?
Will you give it to "tohax" for testing? I think it will work.
But i have only tested installation with static ip on wifi, nothing more.
root@RPi-B_plus:~# uname -a
Linux RPi-B_plus 4.4.19+ #907 Tue Sep 6 13:45:45 BST 2016 armv6l GNU/Linux
[ 862.302016] ------------[ cut here ]------------
[ 862.302953] WARNING: CPU: 0 PID: 6 at net/wireless/sme.c:907 __cfg80211_disconnected+0x280/0x2c8 [cfg80211]()
[ 862.302979] Modules linked in: 8192cu cfg80211 evdev rfkill bcm2835_gpiomem bcm2835_wdt uio_pdrv_genirq uio fuse ipv6
[ 862.303036] CPU: 0 PID: 6 Comm: kworker/u2:0 Not tainted 4.4.19+ #907
[ 862.303047] Hardware name: BCM2708
[ 862.303731] Workqueue: cfg80211 cfg80211_event_work [cfg80211]
[ 862.303806] [<c0016cfc>] (unwind_backtrace) from [<c0013c20>] (show_stack+0x20/0x24)
[ 862.303843] [<c0013c20>] (show_stack) from [<c02e38fc>] (dump_stack+0x20/0x28)
[ 862.303874] [<c02e38fc>] (dump_stack) from [<c0021eb4>] (warn_slowpath_common+0x8c/0xc4)
[ 862.303898] [<c0021eb4>] (warn_slowpath_common) from [<c0021fa8>] (warn_slowpath_null+0x2c/0x34)
[ 862.304597] [<c0021fa8>] (warn_slowpath_null) from [<bf0edb84>] (__cfg80211_disconnected+0x280/0x2c8 [cfg80211])
[ 862.305845] [<bf0edb84>] (__cfg80211_disconnected [cfg80211]) from [<bf0c90ac>] (cfg80211_process_wdev_events+0x1a0/0x20c [cfg80211])
[ 862.307264] [<bf0c90ac>] (cfg80211_process_wdev_events [cfg80211]) from [<bf0c9154>] (cfg80211_process_rdev_events+0x3c/0x74 [cfg80211])
[ 862.308635] [<bf0c9154>] (cfg80211_process_rdev_events [cfg80211]) from [<bf0c4208>] (cfg80211_event_work+0x24/0x2c [cfg80211])
[ 862.309498] [<bf0c4208>] (cfg80211_event_work [cfg80211]) from [<c0037540>] (process_one_work+0x11c/0x39c)
[ 862.309543] [<c0037540>] (process_one_work) from [<c0037800>] (worker_thread+0x40/0x4d0)
[ 862.309576] [<c0037800>] (worker_thread) from [<c003d184>] (kthread+0xdc/0xf8)
[ 862.309614] [<c003d184>] (kthread) from [<c000f8a8>] (ret_from_fork+0x14/0x2c)
[ 862.309629] ---[ end trace 5bdaf355baab1b64 ]---
[ 862.848400] usbcore: registered new interface driver brcmfmac
@k-plan
Hint: are you living now in USA?
I wish, furthest I'am going is Skegness lol (daytona USA arcades!): http://www.skegness.net/
I'll redo the image with those removed. Not sure how they got there. Good spot 👍
Will you give it to "tohax" for testing? I think it will work.
I tested on RPi3 with onboard WiFi and static, worked for me. Was hoping to get v131 out today, but its most likely Monday/Tuesday now.
Pretty confidant we have resolved the issue. I'll get v131 wrapped up 1st, then we can let him know of the new image?
@Fourdee
I wonder, because noting set in dietpi.txt
#WiFi country code. 2 character value (eg GB US DE JP): https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2
wifi_country_code=
.. and it is set to GB
if it is boot up after installation.
[ 12.634275] cfg80211: Regulatory domain changed to country: GB
[ 12.634320] cfg80211: DFS Master region: ETSI
[ 12.634334] cfg80211: (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp), (dfs_cac_time)
[ 12.634356] cfg80211: (2402000 KHz - 2482000 KHz @ 40000 KHz), (N/A, 2000 mBm), (N/A)
[ 12.634375] cfg80211: (5170000 KHz - 5250000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (N/A)
[ 12.634394] cfg80211: (5250000 KHz - 5330000 KHz @ 80000 KHz, 160000 KHz AUTO), (N/A, 2000 mBm), (0 s)
[ 12.634411] cfg80211: (5490000 KHz - 5710000 KHz @ 160000 KHz), (N/A, 2700 mBm), (0 s)
[ 12.634427] cfg80211: (57000000 KHz - 66000000 KHz @ 2160000 KHz), (N/A, 4000 mBm), (N/A)
@k-plan
https://github.com/Fourdee/DietPi/blob/master/dietpi/finalise#L110-L111
Should be 00, i'll change that.
Note to self:
Bring up wifi to set this before finalize.
v131 image did not solve problem for me. Connection test failed again, but now there is a proper ip address in dietpi banner, there was emty field before.
@tohax
Connection test failed again
Raspbian mirror director was offline for me. I had to change to a static mirror.
Try:
cat << _EOF_ > /etc/apt/sources.list
deb http://mirror.ox.ac.uk/sites/archive.raspbian.org/archive/raspbian jessie main contrib non-free rpi
_EOF_
dietpi-software
i'll try and report tomorrow. need to sleep.
it's alive!!! Everything works fine. Thank you.
@Fourdee
Should be 00, i'll change that.
Hmm, I would say, locales, keyboard, time zone, country code =>> GB
what's consistent, because Fourdee + DietPi = 🇬🇧
😄
@k-plan
Hmm, I would say, locales, keyboard, time zone, country code =>> GB
Would be nice for me lol.
But, I can see people "kicking off" with the legality of a GB wifi region, in a country that its against the law to use. So, must really set 00 for WiFi.
@k-plan
But, I can see people "kicking off" with the legality of a GB wifi region, in a country that its against the law to use. So, must really set 00 for WiFi.
Although, I just checked the official Raspbian image, it has this set to GB by default. I'am game. We'll set to GB by default on all DietPi images.
@tohax
it's alive!!! Everything works fine. Thank you.
Excellent thanks for letting us know 👍
Marking this as closed.
Most helpful comment
it's alive!!! Everything works fine. Thank you.