nvram MacOS Command Guide
The MacOS nvram command allows users to interact with the system’s Non-Volatile Random-Access Memory (NVRAM) variables. NVRAM is a small amount of memory that stores system settings even when the computer is turned off. With the nvram command, you can view, set, and delete these variables, which can be useful for troubleshooting system issues, changing startup disk preferences, or modifying system configurations. By using the nvram command in the Terminal, you can access and manipulate these NVRAM variables to customize your MacOS operating system.
nvram Syntax:
Options:
Option | Description |
---|---|
-c | Clear all settings in NVRAM |
-d | Delete a variable from NVRAM |
-p | Print all variables in NVRAM |
-x | Print all variables in XML format |
Parameters:
Parameter | Description |
---|---|
variable | Name of the variable to delete or view |
name=value | Set the value of the specified variable |
nvram Command Samples:
Display all NVRAM variables
This command displays all NVRAM variables currently set on the system.
Set a specific NVRAM variable
This command sets a specific NVRAM variable with the value “example value”.
Delete a specific NVRAM variable
This command deletes a specific NVRAM variable named “my_variable”.
Reset NVRAM to default settings
This command resets the NVRAM to its default settings.
View a specific NVRAM variable value
This command displays the value of a specific NVRAM variable named “my_variable”.
Clear all NVRAM variables
This command clears all NVRAM variables currently set on the system.
Enable verbose mode for NVRAM operation
This command enables verbose mode for NVRAM operation, providing more detailed information.
How can I display all the NVRAM variables set in MacOS?
To display all the NVRAM variables set in MacOS, you can use the following command:
How do I set a new variable with a value using nvram in MacOS?
To set a new variable with a value using nvram in MacOS, you can execute the following command:
How can I delete a specific NVRAM variable in MacOS using nvram?
To delete a specific NVRAM variable in MacOS using nvram, you can run the following command:
How can I reset the entire NVRAM to default values in MacOS?
To reset the entire NVRAM to default values in MacOS, you can use the following command:
How do I set the boot-args variable in MacOS using nvram?
To set the boot-args variable in MacOS using nvram, you can run the following command:
How can I enable verbose mode during boot using nvram in MacOS?
To enable verbose mode during boot using nvram in MacOS, enter the following command:
Applications of the nvram command
- Storing non-volatile random-access memory variables.
- Reading firmware variables.
- Setting firmware variables.
- Inspecting firmware variables.
- Modifying firmware variables.
- Resetting firmware variables to default values.