]>
Commit | Line | Data |
---|---|---|
1815bff5 | 1 | .\" |
83f6dbe8 | 2 | .\" Copyright (c) 2000-2003 Apple Computer, Inc. All rights reserved. |
1815bff5 | 3 | .\" |
83f6dbe8 | 4 | .TH nvram 8 "October 28, 2003" |
1815bff5 | 5 | .SH NAME |
4c00c0ae | 6 | nvram \- manipulate firmware NVRAM variables |
1815bff5 A |
7 | .SH SYNOPSIS |
8 | .B nvram | |
9 | [ | |
10 | .B -p | |
11 | ] [ | |
12 | .B -f | |
13 | .IR filename | |
14 | ] [ | |
83f6dbe8 | 15 | .B -d |
1815bff5 | 16 | .IR name |
83f6dbe8 | 17 | ] [ |
fc6d9e4b A |
18 | .B -c |
19 | ] [ | |
83f6dbe8 A |
20 | .IR name |
21 | [= | |
1815bff5 | 22 | .IR value |
83f6dbe8 | 23 | ]] ... |
1815bff5 A |
24 | .SH DESCRIPTION |
25 | The | |
26 | .I nvram | |
4c00c0ae | 27 | command allows manipulation of firmware NVRAM variables. It |
1815bff5 A |
28 | can be used to get or set a variable. It can also be used to print |
29 | all of the variables or set a list of variables from a file. | |
c3a08f59 | 30 | Changes to NVRAM variables are only saved by clean restart or shutdown. |
1815bff5 A |
31 | .LP |
32 | In principle, | |
33 | .IR name | |
34 | can be any string. In practice, not all strings will be accepted. | |
b51d5b5f A |
35 | New World machines can create new variables as desired. Some variables |
36 | require administrator privilege to get or set. | |
1815bff5 A |
37 | .LP |
38 | The given | |
39 | .IR value | |
40 | must match the data type required for | |
41 | .IR name . | |
42 | Binary data can be set using the %xx notation, where xx is the hex | |
43 | value of the byte. The type for new variables is always binary | |
44 | data. | |
1815bff5 | 45 | .SH OPTIONS |
34d340d7 | 46 | .\" ========== |
1815bff5 | 47 | .TP |
34d340d7 A |
48 | .BI \-d " name" |
49 | Deletes the named firmware variable. | |
50 | .\" ========== | |
1815bff5 A |
51 | .TP |
52 | .BI \-f " filename" | |
4c00c0ae | 53 | Set firmware variables from a text file. The file must be a |
34d340d7 A |
54 | list of "name value" statements. The first space on each line |
55 | is taken to be the separator between "name" and "value". If | |
56 | the last character of a line is \\, the value extends to the next line. | |
57 | .\" ========== | |
83f6dbe8 | 58 | .TP |
34d340d7 A |
59 | .B \-x |
60 | Use XML format for reading and writing variables. | |
61 | This option must be used before the | |
62 | .B \-p | |
63 | or | |
64 | .B \-f | |
65 | options, since arguments are processed in order. | |
66 | .TP | |
fc6d9e4b A |
67 | .B \-c |
68 | Delete all of the firmware variables. | |
69 | .TP | |
34d340d7 A |
70 | .B \-p |
71 | Print all of the firmware variables. | |
1815bff5 A |
72 | .SH EXAMPLES |
73 | .LP | |
74 | .RS | |
75 | example% nvram boot-args="-s rd=*hd:10" | |
76 | .RE | |
77 | .LP | |
b51d5b5f | 78 | Set the boot-args variable to "-s rd=*hd:10". This would specify |
1815bff5 A |
79 | single user mode with the root device in hard drive partition 10. |
80 | .LP | |
81 | .RS | |
82 | example% nvram my-variable="String One%00String Two%00%00" | |
83 | .RE | |
84 | .LP | |
b51d5b5f | 85 | Create a new variable, my-variable, containing a list of two |
1815bff5 | 86 | C-strings that is terminated by a NUL. |
83f6dbe8 A |
87 | .LP |
88 | .RS | |
89 | example% nvram -d my-variable | |
90 | .RE | |
91 | .LP | |
92 | Deletes the variable named my-variable. | |
1815bff5 | 93 | .PD |