WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Commercial Support For PiCore  (Read 2905 times)

Offline onelife

  • Full Member
  • ***
  • Posts: 141
Commercial Support For PiCore
« on: October 12, 2021, 05:13:45 AM »
Hi there Forum,

I have been posting questions here on various topics for a while and to be honest I feel rather dumb with many of my questions seemingly "simple" to resolve - But I seem to be battling.

I am using PiCore for a commercial solution and am looking for someone or a company that can assist with various setup tasks on TC 13.0.3. Example.

- network setup for GSM modems.
- auto tcz creation as part of "snap shot" of system.
- fdisk / fsck check solution on boot that can assist with SD card maintenance.
- static IP settings.

Is there anyone on this forum that is perhaps able to suggest what way I go - Again, it is a commercial solution and I want to pay for this help as me trying to Google my way through the tasks as a none dev user is proving very difficult and too time consuming :( - I'm keen to learn but I need a working solution.

Please feel free to post a direct message to me or reply here as I don't believe I can be the only user looking for help in the way of a commercial solution.

Chat soon.

Kind Regards.

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14799
Re: Commercial Support For PiCore
« Reply #1 on: October 12, 2021, 07:25:15 AM »
- fdisk / fsck check solution on boot that can assist with SD card maintenance.
If you boot using the "base" boot code or set the copy2fs flag, you can un-mount mmcblk0p2 and run fsck.

Quote
- static IP settings.
Have you tried using the gui cpanel applet for this?

Offline onelife

  • Full Member
  • ***
  • Posts: 141
Re: Commercial Support For PiCore
« Reply #2 on: October 12, 2021, 08:13:14 AM »
Thank you for your reply Juanito - Appreciated!

Regarding the fsck I am needing this to be 100% unattended - so a type of bash script that would do that process?

I'm also not running the GUI at all, so no, I haven't used the GUI tools :(

The requirement is to keep the OS as small and robust as possible so GUI isn't really an option.

As I say, I really feel a "guru" could tackle our needs and I will make it worth their time.

I am happy to know what and how - but some initial expert help and the option of even a few video calls to discuss the challenges would be hugely helpful.

Perhaps you would be interested?

Kind Regards.

Online Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11594
Re: Commercial Support For PiCore
« Reply #3 on: October 12, 2021, 08:29:20 AM »
Hi onelife
...
Quote
- static IP settings.
Have you tried using the gui cpanel applet for this?
Or you can set up a script in  /opt  that gets called by  /opt/bootlocal.sh.

An example script is attached. Here is a line by line description:
1. Defines where to find the interpreter that will execute the script. No need to change this.
2. Kills the daemon that automatically assigns IP addresses.
3. Assigns the IP address. Leave the  mask  as is. Change the first 3 numbers of  broadcast  to match the IP address.
4. This points to the device that connects you to the outside world, typically your router (modem).
5. Primary nameserver to contact for DNS lookups.
5. Secondary nameserver to contact for DNS lookups.

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14799
Re: Commercial Support For PiCore
« Reply #4 on: October 12, 2021, 08:48:26 AM »
Regarding the fsck I am needing this to be 100% unattended - so a type of bash script that would do that process?

If you only use a few small extensions, you can set the copy2fs flag and then at any point after boot, use a script to un-mount mmcblk0p2 and run fsck.
« Last Edit: October 12, 2021, 08:54:56 AM by Juanito »

Offline patrikg

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 711
Re: Commercial Support For PiCore
« Reply #5 on: October 12, 2021, 01:03:54 PM »
Remove the kill command in the script and add nodhcp to the command line to the kernel in the cmdline.txt file like this.

Code: (bash) [Select]
mount /mnt/mmcblk0p1/
nano -w /mnt/mmcblk0p1/cmdline.txt


Hi onelife
...
Quote
- static IP settings.
Have you tried using the gui cpanel applet for this?
Or you can set up a script in  /opt  that gets called by  /opt/bootlocal.sh.

An example script is attached. Here is a line by line description:
1. Defines where to find the interpreter that will execute the script. No need to change this.
2. Kills the daemon that automatically assigns IP addresses.
3. Assigns the IP address. Leave the  mask  as is. Change the first 3 numbers of  broadcast  to match the IP address.
4. This points to the device that connects you to the outside world, typically your router (modem).
5. Primary nameserver to contact for DNS lookups.
5. Secondary nameserver to contact for DNS lookups.

Offline onelife

  • Full Member
  • ***
  • Posts: 141
Re: Commercial Support For PiCore
« Reply #6 on: October 12, 2021, 03:11:27 PM »
Thank you - Really appreciate the replies.

I don't want to disable the dhcp so for now I have added an interface eth0:1 as the static. This I am calling from a script I added to bootlocal.sh.

So, maybe this is the only way and I will try post all my challenges to this thread ;)

One of the bigger challenges I believe must be possible is a fail safe mount of partitions. Essentially what I want to do is have a clone of each partition. My current SD card has 3 partitions :

- Boot = the default boot partition core creates
- TCE / SYSTEM = the persisted TCZ store and My Data etc
- DATA = The partition I store mp3 files in.

What I would like to achieve is a method that I have 5 partitions and during the boot process IF TCE / SYSTEM has any issues, it will switch to the 2nd backup TCE / SYSTEM and then the same on DATA.

IOW, a 2nd copy that I will keep in sync / check with md5sum - the moment anything doesn't pass md5 on boot, the system swaps to the other partition so then I can repair / replace the damaged files 100% remotely.

Sound doable as an option for an almost 99% guarantee of file structure etc? And where do I even start for this?

Thank you!



Offline patrikg

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 711
Re: Commercial Support For PiCore
« Reply #7 on: October 12, 2021, 03:20:52 PM »
You may also need to think about how picore sets the time when booting up.
That you may have to add this line on the last line of the script.

/usr/bin/getTime.sh

So the picore set the date/time correctly.

Offline onelife

  • Full Member
  • ***
  • Posts: 141
Re: Commercial Support For PiCore
« Reply #8 on: October 13, 2021, 12:51:13 PM »
post as per attached note as keep getting server error :(

Offline rull_orion

  • Newbie
  • *
  • Posts: 5
Re: Commercial Support For PiCore
« Reply #9 on: November 23, 2021, 05:17:22 PM »
One of the bigger challenges I believe must be possible is a fail safe mount of partitions. Essentially what I want to do is have a clone of each partition. My current SD card has 3 partitions :

- Boot = the default boot partition core creates
- TCE / SYSTEM = the persisted TCZ store and My Data etc
- DATA = The partition I store mp3 files in.

What I would like to achieve is a method that I have 5 partitions and during the boot process IF TCE / SYSTEM has any issues, it will switch to the 2nd backup TCE / SYSTEM and then the same on DATA.

IOW, a 2nd copy that I will keep in sync / check with md5sum - the moment anything doesn't pass md5 on boot, the system swaps to the other partition so then I can repair / replace the damaged files 100% remotely.

I will share my solution, you can check and adopt to your requirements.
Copy of partitions will not always works properly. For example, partition is not fully corrupted but some modules are corrupted.
What I do:
1. Repack corefs, so my failsafe script is located in boot partition (first and almost untouched)
2. Check integrity in that script.
  - Check if required TCE modules loaded.
  - If not, then automatically load minimum apps for connectivity to be able for remote fix, and send error event to my server.
  - Also I use http (not https) endpoint for getting time (otherwise other connectivity will not work because https certs is not working with bad time ). NTP is often blocked in my envs
3. 99% of cases my system get corrupted only with power fault on boot. Boot partition usually not corrupted, so that's why it quite safe..