Ce contenu n'est pas disponible dans la langue sélectionnée.

Chapter 3. Using the command-line assistant powered by RHEL Lightspeed on RHEL systems


The command-line assistant powered by RHEL Lightspeed is designed to assist both less experienced and experienced users to interact with RHEL by using the command-line interface. The command-line assistant can help you with tasks such as: answering RHEL related questions, assisting with troubleshooting, assisting with deciphering log entries, and many other tasks.

Warning

Do not rely on the results from AI tools without human review. Always check the AI and LLM-generated responses for accuracy before using the generated suggestions.

3.1. Asking questions to the command-line assistant

To use the command-line assistant powered by RHEL Lightspeed, use the “c” command followed by your questions in quotation marks. For example:

  • Ask a question by using the following syntax: c + “question". For example:

    $ c “What is RHEL"
Warning

Do not enter the following types of data when using the command-line assistant, because the assistant is not intended to process data such as:

  • Personal information
  • Business sensitive information
  • Confidential information
  • System data information

The following are examples of prompts that you can use to interact with the command-line assistant when using your RHEL systems:

Request information on how to troubleshooting a problem:

$ c “how to troubleshoot sshd failing to start"
$ c “how do I find all the files in the /ect that have been modified in the last hour"

You can attach a file to the command-line assistant powered by RHEL Lightspeed. By doing so, the assistant can provide a tailored response based on that file.

For example, if you want to replicate the volume group, logical volumes, and file systems on another system, you can create a file with the storage information, and run the command-line assistant to get information about the required steps to replicate that specific storage partition in another system. For example:

$ c --attachment <storage_info>

Optionally, use the short version of the attachment command. For example:

# $ c -a <storage_info>

You can also combine the attachment with a question:

# $ c --attachment <storage_info> "how can I replicate the storage configuration in another system

Access your conversation history with the command-line assistant powered by RHEL Lightspeed.

  • Fetch all user history. For example:

    $ c history --all
  • Access the first conversation from history. For example:

    $ c history --first
  • Access the last conversation from history. For example:

    $ c history --last
  • Filter your history conversation to search for a term to retrieve all questions and answers related to that word. For example:

    $ c history --filter “podman"
  • Clear all the user history:

    $ c history --clear

Use the log file that contains information that you want to understand by redirecting that log file output to command-line assistant powered by RHEL Lightspeed.

$ cat <log_file.log> | c

If the error or log that you have provided to the command-line assistant does not provide enough information, you can combine the redirect output with a question, for example:

$ cat <log_file_error.log> | c "how do I solve this?"

You can also redirect a question:

$ echo "how do I solve this?" | c -a <log_file_error.log>"

The command-line assistant powered by RHEL Lightspeed has an optional feature that enables you to reference commands that you previously ran.

Warning

If you add terminal context in a request and there are no previously captured commands, the command will fail. You can only add context from the terminal while the capture mode is enabled.

  1. Enable the terminal capture for your current terminal session. For example:

    $ c shell --enable-capture
  2. Run at least one command before you reference previous commands.

    After you enable the capture, you can reference the previous output of a command that you ran. For example, to reference the last command, run:

    $ c -w 1 "what_is_this"

    To reference the second to last command, run:

    $ c -w 2 "what_is_this"
  3. To stop terminal capture, press the following keys on your keyboard:

    $ Press Ctrl + D

You can submit feedback about the responses that you receive when you interact with the command-line assistant powered by RHEL Lightspeed:

$ c feedback
Red Hat logoGithubredditYoutubeTwitter

Apprendre

Essayez, achetez et vendez

Communautés

À propos de Red Hat

Nous proposons des solutions renforcées qui facilitent le travail des entreprises sur plusieurs plates-formes et environnements, du centre de données central à la périphérie du réseau.

Rendre l’open source plus inclusif

Red Hat s'engage à remplacer le langage problématique dans notre code, notre documentation et nos propriétés Web. Pour plus de détails, consultez le Blog Red Hat.

À propos de la documentation Red Hat

Legal Notice

Theme

© 2026 Red Hat
Retour au début