# Manage UEFI environment variables using the `efivar` tool

The `efivar` tool manages unified extensible firmware interface (UEFI) environment variables stored in the non-volatile firmware storage. Use these variables to configure the UEFI firmware and its environment.

The `efivars` are key-value pairs stored in the UEFI firmware. They hold settings for boot configuration, system state, and other essential parameters. The efivars manage boot entries and firmware settings, ensuring the system boots correctly and maintains its configuration.

To interact with the UEFI environment variables, use the following command:

efivar [-n name] [-f file] [-p] [-w]
    Copy to clipboard

Command options:

- `-n name`: Specify the name of the UEFI variable.
- `-f file`: Load or save variable contents from a file.
- `-p`: Print the value of the specified UEFI variable.
- `-w`: Write to the specified UEFI variable.

## Update the `OsIndications` variable

To update the `OsIndications` variable and verify the value of the EFI variable, do the following:

1. Create a `data.hex` file containing a specific byte sequence `04 00 00 00 00 00 00 00`.

echo -e -n "\x4\x0\x0\x0\x0\x0\x0\x0" > data.hex
        Copy to clipboard
2. Write the contents of `data.hex` to the EFI variable `8be4df61-93ca-11d2-aa0d-00e098032b8c-OsIndications`.

efivar -n 8be4df61-93ca-11d2-aa0d-00e098032b8c-OsIndications -f data.hex -w
        Copy to clipboard
3. To verify the value of the EFI variable `8be4df61-93ca-11d2-aa0d-00e098032b8c-OsIndications`, run the following command:

efivar -n 8be4df61-93ca-11d2-aa0d-00e098032b8c-OsIndications -p
        Copy to clipboard

    Output of the previous command:

GUID: 8be4df61-93ca-11d2-aa0d-00e098032b8c
        Name: "OsIndications"
        Attributes:
              Non-Volatile
              Boot Service Access
              Runtime Service Access
        Value:
        00000000  04 00 00 00 00 00 00 00
        Copy to clipboard

## Update the `VendorDtbOverlays` variable

To update the `VendorDtbOverlays` variable and verify the value of the EFI variable, do the following:

1. Create a `/var/data` file containing data `camx`.

echo -n "camx" > /var/data
        Copy to clipboard
2. Write the contents of `/var/data` to the EFI variable `882f8c2b-9646-435f-8de5-f208ff80c1bd-VendorDtbOverlays`.

efivar -n 882f8c2b-9646-435f-8de5-f208ff80c1bd-VendorDtbOverlays -f /var/data -w
        Copy to clipboard
3. To verify the value of the EFI variable `882f8c2b-9646-435f-8de5-f208ff80c1bd-VendorDtbOverlays`, run the following command:

efivar -n 882f8c2b-9646-435f-8de5-f208ff80c1bd-VendorDtbOverlays -p
        Copy to clipboard

    Output of the previous command:

GUID: 882f8c2b-9646-435f-8de5-f208ff80c1bd
        Name: "VendorDtbOverlays"
        Attributes:
              Non-Volatile
              Boot Service Access
              Runtime Service Access
        Value:
        00000000  63 61 6d 78                                       |camx            |
        Copy to clipboard

## Next steps

For more information, see [efivars Manual](https://man.freebsd.org/cgi/man.cgi?query=efivar&amp;sektion=8).

Last Published: May 10, 2026

[Previous Topic
Boot Linux operating system from the SD card](https://docs.qualcomm.com/bundle/publicresource/80-80022-27/topics/boot_linux_operating_system_from_sdcard.md) [Next Topic
Customize Qualcomm Linux](https://docs.qualcomm.com/bundle/publicresource/80-80022-27/topics/customize_qualcomm_linux.md)