Tiny Core Linux

Tiny Core Base => Raspberry Pi => Topic started by: jamas on November 05, 2024, 03:03:01 PM

Title: piCore 15.0.0 on Pi4 Problems
Post by: jamas on November 05, 2024, 03:03:01 PM
I installed piCore 15.0.0 http://tinycorelinux.net/15.x/armhf/releases/RPi/ (http://tinycorelinux.net/15.x/armhf/releases/RPi/) on a raspberry pi 4 Model B.
I am able to login over ethernet and also extended the partition. Pretty much followed this tutorial: https://gist.github.com/BillyNate/13732d02c41378f1c630fa914fe63378 (https://gist.github.com/BillyNate/13732d02c41378f1c630fa914fe63378)

Architecture:
6.6.47-piCore-v8 aarch64

And getting my tcz files from here: http://ftp.nluug.nl/os/Linux/distr/tinycorelinux/15.x/aarch64/tcz/ (http://ftp.nluug.nl/os/Linux/distr/tinycorelinux/15.x/aarch64/tcz/)


But i encounter the following problems.

Problem 1:
Whenever i reboot more than once i cannot login to my rpi via ssh anymore, because of the following error:
Code: [Select]
ssh tc@192.168.0.203
ssh: connect to host 192.168.0.203 port 22: Connection refused


Deleting the ssh key from my pc does not help.

Problem 2:
wifi is not able to find any devices.

Code: [Select]
sudo wifi.sh
No wifi devices found!


Problem 3:
When installing nano it says, that its already installed but cannot find the file:

Code: [Select]
tc@box:/$ tce-load -wi nano
nano is already installed!
tc@box:/$ nano
-sh: nano: not found


Am i downloading the wrong tcz files? Because i downloaded the rpi image with armhf but using the tcz files of aarch64.
But then uname returns: 6.6.47-piCore-v8 aarch64

But confused here.

Thanks a lot in advance  :)
Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: Paul_123 on November 05, 2024, 03:13:45 PM
Don't manually download things unless you really have to.   Use `tce` to manually search and load extensions.   It will get you the correct files.  The armhf is a 32 bit user space image, you need to download any extension from the armhf folder on the repo.   But yes, the pi4 is running a 64bit kernel in the 32 bit user space.

tce-load -wi nano tries to download nano, but likely you have already done that, so it fails.  tce-load -i nano will likely work.
Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: jamas on November 05, 2024, 03:34:52 PM
Wow. Works so much easier. Thanks.

I got nano working. But with wifi i still get the following message even tough i am right next to the router. Maybe i need to check with raspbian if the wifi really works.

Code: [Select]
tc@box:~$ sudo wifi.sh
No wifi devices found!


Also after rebooting for the second (right after doing the the resizing), i still get a connection refused error, when using ssh.
Is everything fine with the output:

Code: [Select]
tc@box:~$ sudo resize2fs /dev/mmcblk0p2
resize2fs 1.47.0 (5-Feb-2023)
Filesystem at /dev/mmcblk0p2 is mounted on /mnt/mmcblk0p2; on-line resizing required
old_desc_blocks = 1, new_desc_blocks = 4
The filesystem on /dev/mmcblk0p2 is now 8170752 (4k) blocks long.
Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: Paul_123 on November 05, 2024, 07:03:32 PM
What is your ssh client.  Likely, you are using an outdated client using an outdated cipher.

Here is some info that may help.  https://forum.tinycorelinux.net/index.php/topic,26302.0.html

As for WiFi, have you loaded firmware-rpi-wifi.tcz?
Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: patrikg on November 06, 2024, 03:50:12 AM
Have you run the script filetool, to make a backup of your settings and profile?

Code: [Select]
filetool.sh -bv
Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: jamas on November 06, 2024, 01:27:05 PM
my ssh client is:
OpenSSH_8.9p1 Ubuntu-3ubuntu0.10, OpenSSL 3.0.2 15 Mar 2022


And on tinyCore:
OpenSSH_9.7p1, OpenSSL 3.2.1 30 Jan 2024

Both should be the newest. Tried to update but not newest is installed.



Without resizing the parition i can reboot as many times as i want without getting the permission denied ssh error.
But when deleting the second paritition and creating a new one. After booting for the second time i cannot login anymore. Even if i dont perform sudo resize2fs /dev/mmcblk0p2.

When performing the reboot step 5.iv for two times i cannot login anymore https://gist.github.com/BillyNate/13732d02c41378f1c630fa914fe63378 (https://gist.github.com/BillyNate/13732d02c41378f1c630fa914fe63378).

Could there be a problem with how i do the partition expanding?


Running the script filetool command has no effect:
Code: [Select]
filetool.sh -bv
Btw. what is the difference to backup command?
Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: jamas on November 06, 2024, 01:31:38 PM
Have you run the script filetool, to make a backup of your settings and profile?

Code: [Select]
filetool.sh -bv

Thanks. That was the missing step. Wifi works now :)
Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: jamas on November 06, 2024, 03:27:19 PM
Solved the issue.

The problem was a fake SDcard which claimed to be larger than it actually is.
When extending the partition and setting the Last Cylinder value to a small value, everything works
Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: patrikg on November 06, 2024, 05:39:15 PM
Sorry to hear that was the size problem.
We have discussed a lot in this forum of bogus sd card's and flash memory's.

But very smart workaround you doing.

Please take this bogus sd card's not in production, just use them in your playground.
Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: gadget42 on November 07, 2024, 03:38:06 AM
truthfully this earlier forum thread(and the other threads referenced within) should be a sticky, a la _front_and_center_ so more visitors see it "posted-on-the-door" so to speak:

https://forum.tinycorelinux.net/index.php/topic,26762.0.html

especially going forward, with so many boards(and other devices like tablets and phones) using these types of storage media, keeping it in the forefront is paramount.
Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: jamas on November 07, 2024, 12:58:40 PM
Would it somehow be possible to validate the partition after resizing?
Like the imager's who first write everything and then validate after? Or is it not possible because we dont know, what we write, we just make space available?

Title: Re: piCore 15.0.0 on Pi4 Problems
Post by: Paul_123 on November 07, 2024, 02:36:04 PM
Imager is only going to validate what it wrote.  You would have to fill up the filesystem to be able to validate it.

Best thing to do is run a SDcard validator program.