chromebrew icon indicating copy to clipboard operation
chromebrew copied to clipboard

🐞 Bug fatal: not a git repository (or any parent up to mount point /usr)

Open AvacadoWizard120 opened this issue 1 year ago • 31 comments

Describe the bug Cannot update chromebrew can't install buildessential either!

To Reproduce Steps to reproduce the behavior:

  1. I executed this command:

    crew install buildessential
    

    Output:

    fatal: not a git repository (or any parent up to mount point /usr)
    Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
    buildessential: A collection of tools essential to compile and build software.
    SKIP
    Version: 1.28
    License: GPL-3+
    Performing pre-flight checks...
    The following packages also need to be installed: 
    py3_packaging py3_wheel rtmpdump unzip xxhash zip core glibc_dev235 glibc_dev isl mpfr mpc gcc_dev linuxheaders                   pkgconfig binutils mold findutils autoconf automake bison diffutils libtool perl_xml_parser intltool patch sed valgrind       compressdoc doxygen help2man xmlcatmgr docbook_xml412 docbook_xml42 docbook_xml43 docbook_xml44 docbook_xml45       docbook_xml50 docbook_xml51 docbook_xsl docbook_xsl_nons docbook_xml itstool gtk_doc perl_locale_messages       perl_text_unidecode perl_unicode_eastasianwidth texinfo gawk py3_codespell ruby_mdl ruby_rubocop ruby_yaml_lint shellcheck       linter ninja samurai mesonbuild libcap py3_pyelftools pax_utils gnu_time rdfind symlinks upx ruby_concurrent_ruby
    Do you agree? [Y/n] y
    Proceeding...
      py3_packaging: Packaging provides core utilities for Python packages
      Skipping source download...
      Preconfiguring package...
      /usr/local/lib64/ruby/3.3.0/json/common.rb:219:in `parse': unexpected token at '' (JSON::ParserError)
      from /usr/local/lib64/ruby/3.3.0/json/common.rb:219:in `parse'
      from /usr/local/lib/crew/lib/buildsystems/pip.rb:15:in `install'
      from /usr/local/bin/crew:1047:in `block in build_and_preconfigure'
      from /usr/local/bin/crew:1019:in `chdir'
      from /usr/local/bin/crew:1019:in `build_and_preconfigure'
      from /usr/local/bin/crew:1590:in `install'
      from /usr/local/bin/crew:1563:in `block in resolve_dependencies'
      from /usr/local/bin/crew:1560:in `each'
      from /usr/local/bin/crew:1560:in `resolve_dependencies'
      from /usr/local/bin/crew:1467:in `resolve_dependencies_and_install'
      from /usr/local/bin/crew:2091:in `block in install_command'
      from /usr/local/bin/crew:2083:in `each'
      from /usr/local/bin/crew:2083:in `install_command'
      from /usr/local/bin/crew:2230:in `<main>'
    

Expected behavior Expected buildessential to be installed

Screenshots If applicable, add screenshots to help explain your problem.

Environment: Paste the output of crew sysinfo -v between the two *** below


fatal: not a git repository (or any parent up to mount point /usr) Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set). fatal: not a git repository (or any parent up to mount point /usr) Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).

Expand
  • Architecture: x86_64 (x86_64)

  • Processor vendor: GenuineIntel

  • User space: 64-bit

  • Chromebrew Kernel version: 5.15

  • Chromebrew Running in Container: false

  • Chromebrew version: 1.43.1

  • Chromebrew prefix: /usr/local

  • Chromebrew libdir: /usr/local/lib64

  • Last update in local repository:

  • OS variant: Chrome OS

  • OS version: hatch-release/R121-15699.58.0

  • OS channel: stable-channel

Crew is exiting. ***

AvacadoWizard120 avatar Feb 10 '24 16:02 AvacadoWizard120

Does a crew update ; yes | crew upgrade help?

satmandu avatar Feb 10 '24 19:02 satmandu

Also, it looks like you may have a broken install. Can you try reinstalling?

satmandu avatar Feb 10 '24 19:02 satmandu

Hi, this also happened to me. A reinstall fixes it.

lavilao avatar Feb 10 '24 20:02 lavilao

Also, it looks like you may have a broken install. Can you try reinstalling?

Any specific way I should reinstall?

AvacadoWizard120 avatar Feb 13 '24 04:02 AvacadoWizard120

Just repeat the standard install instructions.

satmandu avatar Feb 13 '24 04:02 satmandu

Just repeat the standard install instructions.

I asked if there was any specific reinstall I should perform because I've already done it twice now and the same error keeps happening to me! I'm on the stable channel I'm updated to the latest update and I just keep getting the same thing happening to me.

I uninstall chromebrew, then I restart my Chromebook. Then I reinstall chromebrew (not with signed boot and set dev password) then I type crew update and I get the same errors and no update. The second time I reinstalled I restarted my chromebook before doing crew update and still no dice.

AvacadoWizard120 avatar Feb 14 '24 01:02 AvacadoWizard120

Sorry about that.

I would open crosh, and then do this. You shouldn't need to open VT-2 with M121.

cd /usr/local
exec bash --init-file <(curl -Ls git.io/vddgY)

satmandu avatar Feb 14 '24 02:02 satmandu

Also you might want to try this first, which will wipe away Chromebrew entirely, as well as anything else you have in /usr/local.

cd /usr/local
sudo rm -rf *

satmandu avatar Feb 14 '24 02:02 satmandu

Sorry about that.

I would open crosh, and then do this. You shouldn't need to open VT-2 with M121.

cd /usr/local
exec bash --init-file <(curl -Ls git.io/vddgY)

No worries! This stupid V2 shell crap is really messing me up. I used to play Halo on xemu on my Chromebook with a ps4 remote all the time it was awesome and now everything is broken!

I did everything you said and it still gave me the same output if anything now it's even worse even if I type crew it doesn't do shit.

AvacadoWizard120 avatar Feb 14 '24 18:02 AvacadoWizard120

@AvacadoWizard120: Try doing your crew update && crew upgrade in VT-2 and then switch back to crosh -> bash to run your apps and see if that makes any difference. Also, make sure Chrome OS is up to date. See https://www.thegeekstuff.com/2017/08/chrome-os-update-to-latest-version/.

uberhacker avatar Feb 14 '24 18:02 uberhacker

@AvacadoWizard120: Try doing your crew update && crew upgrade in VT-2 and then switch back to crosh -> bash to run your apps and see if that makes any difference. Also, make sure Chrome OS is up to date. See https://www.thegeekstuff.com/2017/08/chrome-os-update-to-latest-version/.

100% certain I'm running the latest stable update. I've only opened an issue because I've tried all of the basic things I could think of. Yes, I have indeed tried using both the V2 Shell and crosh and they both do the same thing. I've powerwashed twice now as well.

Google Chrome: Version 121.0.6167.159 (Official Build) (64-bit) Platform: 15699.58.0 (Official Build) stable-channel hatch Channel: stable-channel Firmware Version: Google_Kindred.12672.534.0 ARC Enabled: true ARC: 11380880 Enterprise Enrolled: false Developer Mode: true

AvacadoWizard120 avatar Feb 14 '24 19:02 AvacadoWizard120

I'm able to install into a hatch M121 container:

chronos@cheekon-x86_64 /usr/local/lib/crew/packages $ crew sysinfo
- Architecture: x86_64 (x86_64)
- Processor vendor: GenuineIntel
- User space: 64-bit
- Chromebrew Kernel version: 5.10
- Chromebrew Running in Container: true

- Chromebrew version: 1.43.5
- Chromebrew prefix: /usr/local
- Chromebrew libdir: /usr/local/lib64

- Last update in local repository: 3c82f75e6 Vivaldi 6.5.3206.61-1 => 6.5.3206.63-1 (#9338) (2 hours ago)

- OS variant: Chrome OS
- OS version: hatch-release/R121-15699.58.0
- OS channel: stable-channel
chronos@cheekon-x86_64 /usr/local/lib/crew/packages $ 

satmandu avatar Feb 14 '24 21:02 satmandu

(That's using the hatch kindred image I find here: https://chromiumdash.appspot.com/serving-builds?deviceCategory=Chrome%20OS )

satmandu avatar Feb 14 '24 21:02 satmandu

So are you telling me to reinstall chromeOS using the hatch kindred image?

AvacadoWizard120 avatar Feb 14 '24 21:02 AvacadoWizard120

So are you telling me to reinstall chromeOS using the hatch kindred image?

No. I tested an install of Chromebrew on top of the hatch recovery image in a container.

So that is working fine. 🤷🏼‍♀️

satmandu avatar Feb 14 '24 21:02 satmandu

So are you telling me to reinstall chromeOS using the hatch kindred image?

No. I tested an install of Chromebrew on top of the hatch recovery image in a container.

So that is working fine. 🤷🏼‍♀️

Well maybe I'll powerwash again and try it I have no idea what the issue is with my chromebook. Could it be a wifi thing like maybe my router settings blocking some sort of connection to GitHub servers?

AvacadoWizard120 avatar Feb 14 '24 22:02 AvacadoWizard120

Can you run this instead? It might give you more insight into what is failing.

cd /usr/local
exec bash --init-file <(curl -Ls git.io/vddgY | sed 's/set -e/set -x/')

satmandu avatar Feb 14 '24 22:02 satmandu

ok I'm trying this install in the container and I'm seeing breakage... debugging...

satmandu avatar Feb 15 '24 00:02 satmandu

Can you do a chown -R chronos /usr/local before trying an install?

satmandu avatar Feb 15 '24 01:02 satmandu

Also, please tell us what ls -aFl /usr/local gives you.

satmandu avatar Feb 15 '24 01:02 satmandu

Okay I ran chown -R chronos /usr/local

then I went to my V2 shell and did cd /usr/local exec bash --init-file <(curl -Ls git.io/vddgY | sed 's/set -e/set -x/')

then I ran crew install buildessential twice (once failed and second to show the failure point) and I got this

buildessential: A collection of tools essential to compile and build software.
SKIP
Version: 1.29
License: GPL-3+
Performing pre-flight checks...
The following packages also need to be installed: 
py3_codespell ruby_mdl xdg_base ruby_rubocop ruby_yaml_lint shellcheck linter llvm17_lib ninja samurai mesonbuild libcap py3_pyelftools pax_utils gnu_time rdfind symlinks upx ruby_concurrent_ruby
Do you agree? [Y/n] 
Proceeding...
py3_codespell: Fix common misspellings in text files.
Skipping source download...
Preconfiguring package...
/usr/local/lib64/ruby/3.3.0/json/common.rb:219:in `parse': unexpected token at '' (JSON::ParserError)
        from /usr/local/lib64/ruby/3.3.0/json/common.rb:219:in `parse'
        from /usr/local/lib/crew/lib/buildsystems/pip.rb:18:in `install'
        from /usr/local/bin/crew:1047:in `block in build_and_preconfigure'
        from /usr/local/bin/crew:1019:in `chdir'
        from /usr/local/bin/crew:1019:in `build_and_preconfigure'
        from /usr/local/bin/crew:1590:in `install'
        from /usr/local/bin/crew:1563:in `block in resolve_dependencies'
        from /usr/local/bin/crew:1560:in `each'
        from /usr/local/bin/crew:1560:in `resolve_dependencies'
        from /usr/local/bin/crew:1467:in `resolve_dependencies_and_install'
        from /usr/local/bin/crew:2094:in `block in install_command'
        from /usr/local/bin/crew:2086:in `each'
        from /usr/local/bin/crew:2086:in `install_command'
        from /usr/local/bin/crew:2233:in `<main>'

So now when I run ls -aFl /usr/local it gives me this:

total 116
drwxr-xr-x. 16 chronos chronos  4096 Feb 15 15:33 ./
drwxr-xr-x.  9 root    root     4096 Feb  5 00:10 ../
drwxr-xr-x.  2 chronos chronos 20480 Feb 15 15:38 bin/
drwxr-xr-x.  3 chronos chronos  4096 Feb 15 15:34 cache/
drwxr-xr-x.  2 chronos chronos  4096 Feb 15 15:33 doc/
drwxr-xr-x.  2 chronos chronos  4096 Feb 15 15:33 docbook/
drwxr-xr-x. 16 chronos chronos  4096 Feb 15 15:37 etc/
drwxr-xr-x. 85 chronos chronos 12288 Feb 15 15:38 include/
drwxr-xr-x.  9 chronos chronos  4096 Feb 15 15:35 lib/
drwxr-xr-x. 32 chronos chronos 28672 Feb 15 15:38 lib64/
drwxr-xr-x. 10 chronos chronos  4096 Feb 15 15:38 libexec/
drwxr-xr-x.  2 chronos chronos  4096 Feb 15 15:33 man/
drwxr-xr-x.  2 chronos chronos  4096 Feb 15 15:36 sbin/
drwxr-xr-x. 53 chronos chronos  4096 Feb 15 15:38 share/
drwxr-xr-x.  3 chronos chronos  4096 Feb 15 15:33 tmp/
drwxr-xr-x.  4 chronos chronos  4096 Feb 15 15:36 var/

AvacadoWizard120 avatar Feb 15 '24 21:02 AvacadoWizard120

The permissions look correct. What does git --version give you?

Also, what does cd /usr/local/lib/crew ; git rev-parse --show-toplevel give you?

satmandu avatar Feb 15 '24 23:02 satmandu

git version 2.43.1.GIT

/usr/local/lib/crew

AvacadoWizard120 avatar Feb 16 '24 01:02 AvacadoWizard120

Is this still an issue?

satmandu avatar Aug 18 '24 20:08 satmandu

Yea I can't even use V2 shell

AvacadoWizard120 avatar Aug 18 '24 20:08 AvacadoWizard120

I have a new issue too even if I power wash it doesn't solve. I think my whole OS is corrupted.

AvacadoWizard120 avatar Aug 18 '24 20:08 AvacadoWizard120

Has your Chromebook reached EOL? I noticed you are running hatch-release/R121-15699.58.0 which is several milestones behind the latest R126.

uberhacker avatar Aug 19 '24 00:08 uberhacker

I got it just about 3 years ago

AvacadoWizard120 avatar Aug 21 '24 00:08 AvacadoWizard120

Can you try a fresh install of Chromebrew to see if it solves your problem?

We just merged some changes that might help...

satmandu avatar Aug 21 '24 20:08 satmandu

But definitely update your machine to the latest version of ChromeOS it supports first...

satmandu avatar Aug 21 '24 20:08 satmandu