]>
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 A |
5 | .SH NAME |
6 | nvram \- manipulate Open Firmware NVRAM variables | |
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 A |
17 | ] [ |
18 | .IR name | |
19 | [= | |
1815bff5 | 20 | .IR value |
83f6dbe8 | 21 | ]] ... |
1815bff5 A |
22 | .SH DESCRIPTION |
23 | The | |
24 | .I nvram | |
25 | command allows manipulation of Open Firmware NVRAM variables. It | |
26 | can be used to get or set a variable. It can also be used to print | |
27 | all of the variables or set a list of variables from a file. | |
c3a08f59 | 28 | Changes to NVRAM variables are only saved by clean restart or shutdown. |
1815bff5 A |
29 | .LP |
30 | In principle, | |
31 | .IR name | |
32 | can be any string. In practice, not all strings will be accepted. | |
b51d5b5f A |
33 | New World machines can create new variables as desired. Some variables |
34 | require administrator privilege to get or set. | |
1815bff5 A |
35 | .LP |
36 | The given | |
37 | .IR value | |
38 | must match the data type required for | |
39 | .IR name . | |
40 | Binary data can be set using the %xx notation, where xx is the hex | |
41 | value of the byte. The type for new variables is always binary | |
42 | data. | |
1815bff5 A |
43 | .SH OPTIONS |
44 | .TP | |
45 | .B \-p | |
46 | Print all of the Open Firmware variables. | |
47 | .TP | |
48 | .BI \-f " filename" | |
49 | Set Open Firmware variables from a text file. The file must be a | |
50 | list name=value statements. If the last character of a line is | |
51 | \\, the value will be continued to the next line. | |
83f6dbe8 A |
52 | .TP |
53 | .BI \-d " name" | |
54 | Deletes the named Open Firmware variable. | |
1815bff5 A |
55 | .SH EXAMPLES |
56 | .LP | |
57 | .RS | |
58 | example% nvram boot-args="-s rd=*hd:10" | |
59 | .RE | |
60 | .LP | |
b51d5b5f | 61 | Set the boot-args variable to "-s rd=*hd:10". This would specify |
1815bff5 A |
62 | single user mode with the root device in hard drive partition 10. |
63 | .LP | |
64 | .RS | |
65 | example% nvram my-variable="String One%00String Two%00%00" | |
66 | .RE | |
67 | .LP | |
b51d5b5f | 68 | Create a new variable, my-variable, containing a list of two |
1815bff5 | 69 | C-strings that is terminated by a NUL. |
83f6dbe8 A |
70 | .LP |
71 | .RS | |
72 | example% nvram -d my-variable | |
73 | .RE | |
74 | .LP | |
75 | Deletes the variable named my-variable. | |
1815bff5 | 76 | .PD |