SSH for LibreELEC on Raspberry Pi 3
#16
@millhouse
I understand it's a problem I'm having with my wireless setup and that my solution is to connect using an ethernet wire. I was just thinking outside the box for a moment there and thought about the 'pre-boot' possibility. I never used linux and that's why I don't know its limitations. Thank you for your input and help.

@nickr
I see. Thanks for your replies and feedback.
Reply
#17
I suspect very high packet loss, check with ping
Reply
#18
(2016-06-20, 17:23)kingleo Wrote: @millhouse
I understand it's a problem I'm having with my wireless setup and that my solution is to connect using an ethernet wire. I was just thinking outside the box for a moment there and thought about the 'pre-boot' possibility. I never used linux and that's why I don't know its limitations. Thank you for your input and help.

It's not really a limitation that prevents it from being added, it's just not the right solution. The textmode option is used only very rarely, because most users are able to connect with ssh. You can't connect with ssh because there's a problem with your network. Once you fix that problem, there's no need for a pre-boot option.

Have you ever considered Homeplug adapters instead of WiFi? They're cheap, and usually more reliable and with better performance than most WiFi connections.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
#19
(2016-06-20, 18:12)marantz Wrote: I suspect very high packet loss, check with ping

Checked with ping and everything looks normal and within acceptable limits.

(2016-06-20, 23:23)Milhouse Wrote: Have you ever considered Homeplug adapters instead of WiFi? They're cheap, and usually more reliable and with better performance than most WiFi connections.

I will look for that, although I suspect we don't have these products in my country (Egypt) or they are going to be very expensive. Anyway, thanks for the suggestion.
Reply
#20
(2016-06-22, 10:36)kingleo Wrote: I will look for that, although I suspect we don't have these products in my country (Egypt) or they are going to be very expensive. Anyway, thanks for the suggestion.

This type of thing: http://egypt.souq.com/eg-en/tp-link-tl-k...4221853/i/

That's a 200-AV model which should still - under ideal conditions - offer enough bandwidth (~65Mbps) to stream a high bitrate Bluray movie. If you have the choice, get the more recent 500-AV version (ideal conditions: 135Mbps bandwidth). Homeplug devices are also known as "Powerline" devices.

Obviously if you can resolve the WiFi issue that may mean you don't need any additional hardware at all. However diagnosing network and in particular WiFi faults remotely is rather hard, so you may be on your own for this, unfortunately.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
#21
I've been asking in several tech forums about my router's wireless settings and the inability to SSH, and it seems my router's firmware is too old. I've had that router for about 8 years now, so that's probably it. Might invest in a new one soon.

I've also been searching for other solutions, like the boot option, and was glad to find out that there's a Kodi version built on OSMC that actually supports that idea. Set it up and it's working. While it's booting, I can press ESC and that takes me to textmode. OSMC looks a bit weird but thankfully they provide the default Kodi skin, which I'm used to by now from OpenELEC/LibreELEC. It also doesn't have an issue with the time/date like I had with LibreELEC, but that was a trivial issue for me.

I'm learned so much new stuff since I bought my RPi3. It was a good investment. It was my first time with RPi, first time with Kodi, and first time with Linux. Thanks for the helpful community like this forum and others that got a beginner like me to actually setup a working home media center with minimum expenses.

@Milhouse
Thank you so much for the link provided. Didn't know that existed really, but as I guess it's a bit expensive for me. I think I'll wait and save money to get a new router instead. Thank you so much for you help and patience. I hope I didn't cause you any hassle.
Reply
#22
Glad you found a solution. Replacing your router longer term sounds like the best option. Smile
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
#23
[SOLVED]

I found the solution to my original problem. It turns out that it's a problem with the Broadcom BCM43438 WiFi chip firmware only on RPi3.

The solution:

edit " /etc/ssh/sshd_config " to connect to the RPi3 (and edit " /etc/ssh/ssh_config " to connect from the RPi3):
Code:
sudo nano /etc/ssh/sshd_config

Then add this line:
Code:
IPQoS cs0 cs0

Save and restart:
Code:
sudo service ssh restart

Done.
Now I can connect to my RPi3 using SSH wirelessly!
Reply
#24
That's great if that works. I'd not seen your particular error reported in relation to that problem before, but hopefully a fix will become available that makes the workaround unnecessary.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
#25
A similar-sounding issue has been reported affecting NTP, but both NTP and SSH work for me; there must be something different about your configuration - the router seems like a likely candidate. Broadcom are aware of the NTP problem, but they really need packet traces showing the problem and the workaround.

@kingleo Do you have a spare card and some time to investigate this? If so, please install the latest Raspbian release (https://www.raspberrypi.org/downloads/raspbian/) and wireshark (sudo apt-get install wireshark - you can answer "no" to the question about non-root users). Then run:
Code:
sudo wireshark -i wlan0 -p -k -f "tcp port 22"
(you will have to hit OK once or twice) and try to ssh in. Save the packet trace showing the failure, then add the workaround and repeat.

If you could do this and then upload the two packet traces somewhere - Dropbox, Google Drive, etc. or CloudShark - it would be much apprecatied.
Reply
#26
@PhilE
Interestingly I had problems with NTP when using OpenELEC and LibreELEC (incorrect date/time) but not when using OSMC, all on the same RPi3 before applying that solution.

I'd like to help, but I don't have another SD Card. Can I run this test on OSMC since it has a Debian base Linux (as I understand)?

If not, I'm not sure but I think it's possible to make an image of my SD Card using "ImageWriter", then format and install Rasbian to run the test, then format and write the image back. This is safe workable option, right?
Reply
#27
I've not tried installing packages on OSMC but it might work. My concern is that wireshark is GUI-based, and I don't know how that will work with OSMC. Since Wireshark used to be tcpdump you would think that it could be configured to use text mode output, but I've not found a way to do that.

Using ImageWriter to archive your card should be safe, but I can't give you a guarantee.
Reply
#28
Ah ha - install tshark as well:
Code:
sudo apt-get install tshark
sudo tshark -i wlan0 -p -f "tcp port 22" -w test.pcap
where test.pcap is the output file.
Reply
#29
On LibreELEC, it should be possible to install "tcpdump" from Addons > Install from repository > LibreELEC Add-ons > Program add-ons > Network Tools.

Once installed, reboot.

Then run the following command in the textmode console (or ssh over wired connection) - this command will capture the first 50 ssh packets on the wlan0 interface (assuming it already has an address assigned):
Code:
tcpdump -w mydumpfile.pcap -i wlan0 dst $(/sbin/ifconfig wlan0 | grep 'inet addr' | cut -d: -f2 | awk '{print $1}') and port 22 -c50

Then attempt to connect to your LE device with ssh over WiFi.

Once the capture is complete, upload the mydumpfile.pcap file somewhere for @PhilE to analyse.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
#30
Ok, I made an image of my SD Card and also made a backup for OSMC to be sure. I'll put the Raspbian image and run the code given by @PhilE then format and put LibreELEC and run the code given by @Milhouse and will upload the output files to google drive.

I have a question though (I'm new to linux):
For wireshark command line, shouldn't there be a file name to capture the result, like in the tshark and tcpdump command lines? If not, how do I upload the results? Screenshot?
Reply

Logout Mark Read Team Forum Stats Members Help
SSH for LibreELEC on Raspberry Pi 30