WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Getting started for a noob(ish)  (Read 155 times)

Offline richiec

  • Newbie
  • *
  • Posts: 2
Getting started for a noob(ish)
« on: January 18, 2025, 05:31:26 AM »
Hi all,

I recently got tiny core linux going on a pi zero w with ethernet and wireless networking. The learning curve was quite steep for someone who's basically a software engineer who doesn't think about the OS or hardware too much. I've documented how someone like me can go from "what to buy" to "thank goodness it now actually works".

https://medium.com/@crichiec/pi-zero-w-tinycore-linux-03966f17d2ec

happy for comments and feedback, or if people find it useful, please share. If there's anything I've screwed up / could make better, please let me know and I'll edit the article.

Best wishes,

Richard

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14875
Re: Getting started for a noob(ish)
« Reply #1 on: January 18, 2025, 06:39:09 AM »
When you download the extensions to the usb stick you need *.tcz, *.tcz.dep (not always present) and *.tcz.md5.txt.

To avoid having to type, for example, net-usb-6.6.47-piCore-v7.tcz, you can use net-usb-KERNEL.

If you have already copied the downloaded extensions to the SD card, you can load them with “tce-load -i”.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11755
Re: Getting started for a noob(ish)
« Reply #2 on: January 18, 2025, 01:16:03 PM »
Hi richiec
Welcome to the forum.

Just a few thoughts ...

Quote
... TinyCore Linux is well suited to this, but it is far from easy to get working beyond ls working at the command line. This isn’t a tutorial on TinyCore itself — there are many introductions out there ...
Speaking of which, there used to be 2 files (IMPORTANT and README) in
the releases section that never got carried forward after TC12:
http://tinycorelinux.net/12.x/armv6/releases/RPi/

Quote
... but as we’ll see the partition resize process is destructive. ...
I was under the impression resizing could be done non-destructively
using the instructions in README at the above link:
Quote
... 2) Delete second partition with 'd' than recreate it with 'n' command.
   Use the same starting sector as deleted had and provide end
   sectore or size greater than deleted had having enough free space
   for Mounted Mode. When finished, exit fdisk with 'w' command. Now
   partition size increased but file system size is not yet changed.

3) Reboot piCore. It is necessary to make Kernel aware of changes.

4) After reboot expand file system to the new partition boundaries with
   typing the following command as root:

   resize2fs /dev/mmcblk0p2

Now you are ready to use the bigger partition. ...

Quote
... sudo reboot ...
That should be:
Code: [Select]
exitcheck.sh rebootor if you want to shutdown (poweroff):
Code: [Select]
exitcheck.shexitcheck ensures an orderly shutdown/reboot sequence:
Code: [Select]
exitcheck.sh reboot -> /opt/shutdown.sh -> /sbin/reboot -> /etc/inittab -> /etc/init.d/rc.shutdown
Then /etc/init.d/rc.shutdown performs the following:
Code: [Select]
1. Sync filesystems
2. Disable swap space
3. Kill all processes
4. Unmount all extensions
5. Delete extensions being updated
6. Unmount tce directory
7. Unmount backup directory
8. Unmount everything else

If you are running command line only (no GUI) and want backups
run automatically when rebooting/shutting down, see here:
https://forum.tinycorelinux.net/index.php/topic,24013.msg151369.html#msg151369

Quote
... There’s in fact no easy way of determining what the actual device is other than trying to mount it and seeing if your files show up. Here’s one way I narrowed it down a bit:

dmesg | grep sda ...
Run:
Code: [Select]
dmesg | tailThen plug in your device and run:
Code: [Select]
dmesg | tailYour device will be the new dmesg entries. If there are no new
dmesg entries, your device was not recognized.

Quote
... What you’re looking for is an sda number (which might be none — my USB stick got mounted just as sda ). ...
The last couple of lines should look something like this:
Code: [Select]
tc@E310:~$ dmesg | tail
 ----- Snip -----
[18036149.154763]  sdg: sdg1 sdg2
[18036149.157639] sd 7:0:0:0: [sdg] Attached SCSI removable disk
tc@E310:~$
The device in this example is sdg and it has 2 partitions, sdg1 and sdg2.

Quote
... tce-load -i dhcpcd.tcz firmware-rpi-wifi.tcz net-usb-6.6.47-piCore-v7.tcz ...
You can also do it like this:
Code: [Select]
tce-load -i dhcpcd firmware-rpi-wifi net-usb-6.6.47-piCore-v7tce-load will work with or without the .tcz extension specified.

Typo:
Quote
... Edit the /etc/resolv.conf file and add a DNS server, which for me is simply my router of 192.168.1.1:

nameserver 193.168.1.1 ...
Should read:
Quote
... Edit the /etc/resolv.conf file and add a DNS server, which for me is simply my router of 192.168.1.1:

nameserver 192.168.1.1 ...

Quote
... ifconfig up eth0 ...
You need root permissions to run that
Code: [Select]
sudo ifconfig up eth0


Offline richiec

  • Newbie
  • *
  • Posts: 2
Re: Getting started for a noob(ish)
« Reply #3 on: January 18, 2025, 01:59:29 PM »
Thank you for the comprehensive evaluation (genuinely). I’ll edit these in some time iver the weekend which will obviously lift the quality of the article significantly and ease some folk’s first experiences,

Many thanks

Richard