WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Troubleshooting all git commands return 'Already loaded'  (Read 2136 times)

Offline xenodius

  • Newbie
  • *
  • Posts: 43
Troubleshooting all git commands return 'Already loaded'
« on: December 20, 2020, 10:36:48 PM »
Hello, I finished developing an app for piCore (EV dash with smart trip management and logging features) and I've been trying to get the dependencies I need to set it up, starting with scipy, and have had a lot of unexpected fundamental issues that I've been unable to find answers to in the Tinycore bible or elsewhere-- I'm a Linux noob and get the sense I'm just lacking really common Linux knowledge.

I got pip installed and backed up for persistence, kept getting SSL verification errors... found I could fix these by updating the system time. However, I've only been able to do this via the X GUI, trying to set the timezone by bootcode e.g. tz=GMT-5 causes boot to hang and getTime.sh gives me a time from years ago. Once set in the GUI the updated time doesn't persist after backup-- not sure where that's stored or if it's only retrieved on startup. I'd like to fix the time but for package issues, this seems like it might be irrelevant, as all the packages I want to use don't have the right wheels anyway and can't be installed by pip...

So I got compiletc.tcz, make.tcz, cmake.tcz, automake.tcz and git.tcz loaded. However, when I call any command from git e.g.
Code: [Select]
git clone https://github.com/scipy/scipy.git nothing happens, and it returns
Code: [Select]
Already loaded. Call from regular menu or terminal.
I can
Code: [Select]
wget https://www.github.com/scipy/scipy.git but I get scipy.git... which is a file and not a folder! No idea what to do with it, can't seem to unpack it.

I could work around this by downloading all the source on my PC and moving stuff around with winSCP. But I'm trying to learn how to use linux/tinyCore throughout this project and would like to work directly on the Pi as much as possible. My main holdup is that I can't get git to do anything, no matter what terminal commands I use it always returns 'Already loaded. Call from regular menu or terminal'. Any advice or resources I should look at? I found only one mention of Git on the whole forum...

PS: Since I'm going to have to compile a lot of packages for this project, should I start over in PiCore 12? Or is it so new I might have more problems?
« Last Edit: December 20, 2020, 10:39:23 PM by xenodius »

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11591
Re: Troubleshooting all git commands return 'Already loaded'
« Reply #1 on: December 20, 2020, 11:01:10 PM »
Hi xenodius
...
Code: [Select]
Already loaded. Call from regular menu or terminal. ...
Are you installing your extensions  OnDemand?  If that's the case, install them  OnBoot  instead.

Offline xenodius

  • Newbie
  • *
  • Posts: 43
Re: Troubleshooting all git commands return 'Already loaded'
« Reply #2 on: December 21, 2020, 09:20:46 AM »
Hi xenodius
...
Code: [Select]
Already loaded. Call from regular menu or terminal. ...
Are you installing your extensions  OnDemand?  If that's the case, install them  OnBoot  instead.

Huh, yes I did... I thought this was strictly a performance choice, and chose it in anticipation of optimizing my boot-time later. Git works fine as OnBoot-- thank you!!

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11591
Re: Troubleshooting all git commands return 'Already loaded'
« Reply #3 on: December 21, 2020, 09:58:09 AM »
Hi xenodius
... So I got compiletc.tcz, make.tcz, cmake.tcz, automake.tcz and git.tcz loaded. ...
make.tcz  is a dependency of  compiletc.tcz  and does not need to be loaded separately.

... and chose it in anticipation of optimizing my boot-time later. ...
Remove  compiletc.tcz, make.tcz, cmake.tcz, automake.tcz and git.tcz  from your  /etc/sysconfig/tcedir/onboot.lst  file.
Create a file called  ~/.local/bin/LoadTools  containing this:
Code: [Select]
#!/bin/sh
tce-load -i compiletc make cmake automake git
Then:
Code: [Select]
chmod 774 ~/.local/bin/LoadTools
If you need your toolchain loaded, just run:
Code: [Select]
LoadTools
If you want it to load in the background during startup, add this to your  /opt/bootlocal.sh  file:
Code: [Select]
/home/tc/.local/bin/LoadTools &

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: Troubleshooting all git commands return 'Already loaded'
« Reply #4 on: December 21, 2020, 12:46:20 PM »
Ah yes, command-line ondemand when in the same shell wasn't entirely seamless. IIRC you need to restart the shell or to run one of the hash commands so it doesn't use the cached path. Not workable around I think, sub-processes can't affect their parent shell.
The only barriers that can stop you are the ones you create yourself.

Offline dentonlt

  • Sr. Member
  • ****
  • Posts: 318
    • the trombone analog
Re: Troubleshooting all git commands return 'Already loaded'
« Reply #5 on: December 21, 2020, 09:06:36 PM »
... found I could fix these by updating the system time. However, I've only been able to do this via the X GUI, trying to set the timezone by bootcode e.g. tz=GMT-5 causes boot to hang and getTime.sh gives me a time from years ago. Once set in the GUI the updated time doesn't persist after backup-- not sure where that's stored or if it's only retrieved on startup. I'd like to fix the time but for package issues, this seems like it might be irrelevant, as all the packages I want to use don't have the right wheels anyway and can't be installed by pip...

Hmm ... re the time issues ... where did your boot hang?
Annnd ... are you using the tzdata extension?

Core handling of the tz bootcode looks fine/simple. I'm guessing the hang might be due to the startup script on tzdata.tcz. I'll check/test (EDIT: admittedly, I'm in x86_64 ... but I'll check what I can nonetheless!)
« Last Edit: December 21, 2020, 09:19:39 PM by dentonlt »

Offline xenodius

  • Newbie
  • *
  • Posts: 43
Re: Troubleshooting all git commands return 'Already loaded'
« Reply #6 on: December 21, 2020, 11:37:27 PM »
Wow above and beyond great information, thank you all!

RE: Rich, neat trick-- background loading I will for sure use! #1 priority is to get the python display running ASAP, so that'll let me divert some non-essential features to the background.

RE: Curaga, thanks for the explanation I found the git issue very confusing!

RE: Dentonlt, IIRC it was on a line timed timed at 1.2 seconds... one of the first displayed on boot... I regret not logging that detail, I'll have to backup image then try crash it again to find out. I am not using tzdata (tce-load -i tzdata.tcz -> tzdata is not installed) maybe that's the problem? Couldn't find it with tce-ab...

Offline dentonlt

  • Sr. Member
  • ****
  • Posts: 318
    • the trombone analog
Re: Troubleshooting all git commands return 'Already loaded'
« Reply #7 on: December 22, 2020, 12:03:18 AM »
I am not using tzdata (tce-load -i tzdata.tcz -> tzdata is not installed) maybe that's the problem? Couldn't find it with tce-ab...

At least you know that you're not crashing on boot because of tzdata. Sorry, I hadn't check the repo - no tzdata extension for TC12 on ARM, at least.

The stock bootcode handling should be harmless. If you're interested to have a looksy, check /etc/init.d/tc-config around line 160 or so. On x86, the startup scripts just set /etc/sysconfig/timezone. I expect ARM should do the same.

If you can recreate a persistent error, I'll look for another cause. Having any other log data would help, of course.