[BUG] Claude Code does not work well on AmazonLinux2

Status Fixed / completed
Maintainer reply ✓ Yes — ant-kurt
Activity 7 comments · opened Aug 7, 2025 · closed Aug 19, 2025
💡 Likely answer: A maintainer (ant-kurt, collaborator) responded on this thread — see the highlighted reply below.

Environment

  • Platform (select one):
  • [ ] Anthropic API
  • [ x] AWS Bedrock
  • [ ] Google Vertex AI
  • [ ] Other: <!-- specify -->
  • Claude CLI version: 1.0.70
  • Operating System: Amazon Linux 2
  • Terminal: Iterm2

Bug Description

Several key features don't seem to work on AmazonLinux2. Most notably that I've noticed

  • Automatic file completion
  • Custom sub agents
  • Custom slash commands

Steps to Reproduce

Install ClaudeCode on AmazonLinux 2

Observed Behavior

  • Automatic file completion

When typing a file name and pressing tab, I expect it to do a file search in my active directory. This works on Mac but not on AL2.

  • Custom sub agents

When creating a custom sub-agent (either project or local), it is created successfully and persisted to the correct directory. However /agents command does not show them and they cannot be summed with the @ symbol.

  • Custom clash commands

Similarly, commands put in ~/.claude/commands are not recognized or loaded.

Additional Context

I've tried with various versions of node up to 22.17.1 with no success. I've also tried the native binary installation with no success.

Are there log files that claude code produces for internal errors it might be facing that suppresses this functionality? If so, where might I find those logs?

View original on GitHub ↗

7 Comments

github-actions[bot] · 1 year ago

Found 3 possible duplicate issues:

  1. https://github.com/anthropics/claude-code/issues/3507
  2. https://github.com/anthropics/claude-code/issues/4632
  3. https://github.com/anthropics/claude-code/issues/2910

If your issue is a duplicate, please close it and 👍 the existing issue instead.

<sub>This issue will be automatically closed as a duplicate in 3 days if there are no additional comments. To prevent auto-closure, please 👎 this comment.</sub>

🤖 Generated with Claude Code

shorea · 1 year ago

Good bot, this comment was able to resolve it for me. https://github.com/anthropics/claude-code/issues/2910#issuecomment-3049944606

I install RG and now all functionality is working as expected. It would be really great to document this dependency in the installation guide. It's not at all obvious that it's required and just fails these features silently.

Would be even better to check for system dependencies via the doctor command.

ant-kurt collaborator · 1 year ago

Thanks for flagging this issue - we actually bundle rg, but it looks like that's not working properly on Amazon Linux 2. We'll look into this.

Can you share what version of glibc you have, as well as what the results of claude !rg --version are?

shorea · 1 year ago

This is the version I had on my system path before it was working.

rg --version                                                                                                                    ✘ INT
ripgrep 12.1.1
-SIMD -AVX (compiled)
+SIMD +AVX (runtime)

And this is the version I installed that got it working

rg --version
ripgrep 14.1.1

features:+pcre2
simd(compile):+SSE2,-SSSE3,-AVX2
simd(runtime):+SSE2,+SSSE3,+AVX2

PCRE2 10.43 is available (JIT is available)

glibc version

> ldd --version

ldd (GNU libc) 2.26
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Roland McGrath and Ulrich Drepper.


> /lib/libc.so.6

GNU C Library (GNU libc) stable release version 2.26, by Roland McGrath et al.
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Compiled by GNU CC version 7.3.1 20180712 (Red Hat 7.3.1-17).
Available extensions:
	crypt add-on version 2.1 by Michael Glad and others
	GNU Libidn by Simon Josefsson
	Native POSIX Threads Library by Ulrich Drepper et al
	BIND-8.2.3-T5B
libc ABIs: UNIQUE IFUNC
For bug reporting instructions, please see:
<http://www.gnu.org/software/libc/bugs.html>.
ant-kurt collaborator · 1 year ago

We shipped some improvements in 1.0.84 that should help diagnose / mitigate this:

  1. claude /doctor now shows the status of Search related functionality (which includes custom slash command discovery)
  2. Claude Code now prefers built-in rg over system-installed rg (see https://docs.anthropic.com/en/docs/claude-code/troubleshooting#search-and-discovery-issues)
  3. You can also run with --debug to see if there are rg related errors

We also fixed some aarch-related Linux issues. Note that if you're using the native executable (as opposed to npm), you will need to explicitly install rg and set USE_BUILTIN_RIPGREP=0.

shorea · 1 year ago

Was able to verify this is working on an older desktop I didn't upgrade rg on. Thanks so much! The new debug feature is going to be awesome for troubleshooting system issues like this!

github-actions[bot] · 1 year ago

This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.