xref: /onnv-gate/usr/src/cmd/boot/bootadm/message.h (revision 0:68f95e015346)
1*0Sstevel@tonic-gate /*
2*0Sstevel@tonic-gate  * CDDL HEADER START
3*0Sstevel@tonic-gate  *
4*0Sstevel@tonic-gate  * The contents of this file are subject to the terms of the
5*0Sstevel@tonic-gate  * Common Development and Distribution License, Version 1.0 only
6*0Sstevel@tonic-gate  * (the "License").  You may not use this file except in compliance
7*0Sstevel@tonic-gate  * with the License.
8*0Sstevel@tonic-gate  *
9*0Sstevel@tonic-gate  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10*0Sstevel@tonic-gate  * or http://www.opensolaris.org/os/licensing.
11*0Sstevel@tonic-gate  * See the License for the specific language governing permissions
12*0Sstevel@tonic-gate  * and limitations under the License.
13*0Sstevel@tonic-gate  *
14*0Sstevel@tonic-gate  * When distributing Covered Code, include this CDDL HEADER in each
15*0Sstevel@tonic-gate  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16*0Sstevel@tonic-gate  * If applicable, add the following below this CDDL HEADER, with the
17*0Sstevel@tonic-gate  * fields enclosed by brackets "[]" replaced with your own identifying
18*0Sstevel@tonic-gate  * information: Portions Copyright [yyyy] [name of copyright owner]
19*0Sstevel@tonic-gate  *
20*0Sstevel@tonic-gate  * CDDL HEADER END
21*0Sstevel@tonic-gate  */
22*0Sstevel@tonic-gate /*
23*0Sstevel@tonic-gate  * Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
24*0Sstevel@tonic-gate  * Use is subject to license terms.
25*0Sstevel@tonic-gate  */
26*0Sstevel@tonic-gate 
27*0Sstevel@tonic-gate #ifndef	_MESSAGE_H
28*0Sstevel@tonic-gate #define	_MESSAGE_H
29*0Sstevel@tonic-gate 
30*0Sstevel@tonic-gate #pragma ident	"%Z%%M%	%I%	%E% SMI"
31*0Sstevel@tonic-gate 
32*0Sstevel@tonic-gate #ifdef	__cplusplus
33*0Sstevel@tonic-gate extern "C" {
34*0Sstevel@tonic-gate #endif
35*0Sstevel@tonic-gate 
36*0Sstevel@tonic-gate #define	FILE_MISS gettext("file not found: %s\n")
37*0Sstevel@tonic-gate 
38*0Sstevel@tonic-gate #define	ARCH_EXEC_MISS gettext("archive creation file not found: %s: %s\n")
39*0Sstevel@tonic-gate 
40*0Sstevel@tonic-gate #define	DIR_MISS gettext("directory not found: %s\n")
41*0Sstevel@tonic-gate 
42*0Sstevel@tonic-gate #define	MUST_BE_ROOT gettext("you must be root to run this program\n")
43*0Sstevel@tonic-gate 
44*0Sstevel@tonic-gate #define	NOT_NEWBOOT gettext("not a Newboot OS\n")
45*0Sstevel@tonic-gate 
46*0Sstevel@tonic-gate #define	MULT_CMDS gettext("multiple commands specified: -%c\n")
47*0Sstevel@tonic-gate 
48*0Sstevel@tonic-gate #define	INVALID_SUBCMD gettext("invalid sub-command specified: %s\n")
49*0Sstevel@tonic-gate 
50*0Sstevel@tonic-gate #define	NEED_SUBCMD gettext("this command requires a sub-command\n")
51*0Sstevel@tonic-gate 
52*0Sstevel@tonic-gate #define	NEED_CMD gettext("a command option must be specified\n")
53*0Sstevel@tonic-gate 
54*0Sstevel@tonic-gate #define	CMD_ERR gettext("command failed with errors: %s\n")
55*0Sstevel@tonic-gate 
56*0Sstevel@tonic-gate #define	DUP_OPT gettext("duplicate options specified: -%c\n")
57*0Sstevel@tonic-gate 
58*0Sstevel@tonic-gate #define	BAD_OPT gettext("invalid option or missing option argument: -%c\n")
59*0Sstevel@tonic-gate 
60*0Sstevel@tonic-gate #define	NO_ARG gettext("missing or too many command argument(s)\n")
61*0Sstevel@tonic-gate 
62*0Sstevel@tonic-gate #define	NO_OPT_REQ gettext("this sub-command (%s) does not take options\n")
63*0Sstevel@tonic-gate 
64*0Sstevel@tonic-gate #define	MISS_OPT gettext("an option is required for this sub-command: %s\n")
65*0Sstevel@tonic-gate 
66*0Sstevel@tonic-gate #define	ABS_PATH_REQ gettext("path is not absolute: %s\n")
67*0Sstevel@tonic-gate 
68*0Sstevel@tonic-gate #define	TOO_LONG gettext("the following line is too long (> %d chars)\n\t%s\n")
69*0Sstevel@tonic-gate 
70*0Sstevel@tonic-gate #define	NOT_ON_SPARC gettext("this operation is not supported on sparc\n")
71*0Sstevel@tonic-gate 
72*0Sstevel@tonic-gate #define	NEED_ALT_ROOT gettext("an alternate root must be specified\n")
73*0Sstevel@tonic-gate 
74*0Sstevel@tonic-gate #define	NO_FILE_ENTRY gettext("file not in list: %s\n")
75*0Sstevel@tonic-gate 
76*0Sstevel@tonic-gate #define	DUP_FILE_ENTRY gettext("file already in list: %s\n")
77*0Sstevel@tonic-gate 
78*0Sstevel@tonic-gate #define	NO_ENTRY gettext("no %s entry found\n")
79*0Sstevel@tonic-gate 
80*0Sstevel@tonic-gate #define	NO_MATCH_ENTRY gettext("no matching entry found\n")
81*0Sstevel@tonic-gate 
82*0Sstevel@tonic-gate #define	NO_BOOTADM_MATCH gettext("no matching bootadm entry found\n")
83*0Sstevel@tonic-gate 
84*0Sstevel@tonic-gate #define	NO_MEM gettext("could not allocate memory: size = %u\n")
85*0Sstevel@tonic-gate 
86*0Sstevel@tonic-gate #define	NO_CMD gettext("no command at line %d\n")
87*0Sstevel@tonic-gate 
88*0Sstevel@tonic-gate #define	DUP_CMD \
89*0Sstevel@tonic-gate     gettext("duplicate command %s at line %d of %sboot/grub/menu.lst\n")
90*0Sstevel@tonic-gate 
91*0Sstevel@tonic-gate #define	INVALID_TIMEOUT gettext("invalid timeout value: %s\n")
92*0Sstevel@tonic-gate 
93*0Sstevel@tonic-gate #define	NO_MENU gettext("menu file not found: %s\n")
94*0Sstevel@tonic-gate 
95*0Sstevel@tonic-gate #define	LIST_TITLE gettext("%d %s\n")
96*0Sstevel@tonic-gate 
97*0Sstevel@tonic-gate #define	GLOBAL_CMD gettext("%s %s\n")
98*0Sstevel@tonic-gate 
99*0Sstevel@tonic-gate #define	REGCOMP_FAIL gettext("regular expression failed to compile\n")
100*0Sstevel@tonic-gate 
101*0Sstevel@tonic-gate #define	INVALID_ENTRY gettext("invalid boot entry number: %s\n")
102*0Sstevel@tonic-gate 
103*0Sstevel@tonic-gate #define	DUP_ENTRY gettext("a boot entry with this title already exists: %s\n")
104*0Sstevel@tonic-gate 
105*0Sstevel@tonic-gate #define	LIST_ENTRY gettext("%s\n")
106*0Sstevel@tonic-gate 
107*0Sstevel@tonic-gate #define	SUBOPT_VALUE gettext("suboption %s requires a value\n")
108*0Sstevel@tonic-gate 
109*0Sstevel@tonic-gate #define	INVALID_SUBOPT gettext("invalid suboption: %s\n")
110*0Sstevel@tonic-gate 
111*0Sstevel@tonic-gate #define	SUBOPT_MISS gettext("missing suboption: %s\n")
112*0Sstevel@tonic-gate 
113*0Sstevel@tonic-gate #define	INVALID_HDR gettext("invalid entry header: %s\n")
114*0Sstevel@tonic-gate 
115*0Sstevel@tonic-gate #define	INVALID_TITLE gettext("invalid title entry: %s\n")
116*0Sstevel@tonic-gate 
117*0Sstevel@tonic-gate #define	INVALID_ROOT gettext("invalid root entry: %s\n")
118*0Sstevel@tonic-gate 
119*0Sstevel@tonic-gate #define	INVALID_KERNEL gettext("invalid kernel entry: %s\n")
120*0Sstevel@tonic-gate 
121*0Sstevel@tonic-gate #define	INVALID_MODULE gettext("invalid module entry: %s\n")
122*0Sstevel@tonic-gate 
123*0Sstevel@tonic-gate #define	INVALID_FOOTER gettext("invalid entry footer: %s\n")
124*0Sstevel@tonic-gate 
125*0Sstevel@tonic-gate #define	EMPTY_FILE gettext("file is missing or empty: %s\n")
126*0Sstevel@tonic-gate 
127*0Sstevel@tonic-gate #define	UNLINK_EMPTY gettext("file is empty, deleting file: %s\n")
128*0Sstevel@tonic-gate 
129*0Sstevel@tonic-gate #define	UNLINK_FAIL gettext("failed to unlink file: %s: %s\n")
130*0Sstevel@tonic-gate 
131*0Sstevel@tonic-gate #define	NOT_CHR gettext("not a character device: %s\n")
132*0Sstevel@tonic-gate 
133*0Sstevel@tonic-gate #define	NO_DIR gettext("directory not found: %s\n")
134*0Sstevel@tonic-gate 
135*0Sstevel@tonic-gate #define	NOT_DIR gettext("not a directory: %s\n")
136*0Sstevel@tonic-gate 
137*0Sstevel@tonic-gate #define	NO_MATCH gettext("no matching entry found: %s\n")
138*0Sstevel@tonic-gate 
139*0Sstevel@tonic-gate #define	INVALID_OPT gettext("invalid option: %s\n")
140*0Sstevel@tonic-gate 
141*0Sstevel@tonic-gate #define	FAILED_SIG gettext("Cannot set SIGCHLD disposition: %s\n")
142*0Sstevel@tonic-gate 
143*0Sstevel@tonic-gate #define	CANT_UNBLOCK_SIGCHLD gettext("Cannot unblock SIGCHLD: %s\n")
144*0Sstevel@tonic-gate 
145*0Sstevel@tonic-gate #define	BLOCKED_SIG gettext("SIGCHLD signal blocked. Cannot exec: %s\n")
146*0Sstevel@tonic-gate 
147*0Sstevel@tonic-gate #define	POPEN_FAIL gettext("popen failed: %s\n")
148*0Sstevel@tonic-gate 
149*0Sstevel@tonic-gate #define	PCLOSE_FAIL gettext("pclose failed: %s\n")
150*0Sstevel@tonic-gate 
151*0Sstevel@tonic-gate #define	EXEC_FAIL gettext("command terminated abnormally: %s: %d\n")
152*0Sstevel@tonic-gate 
153*0Sstevel@tonic-gate #define	INVALID_ARCH_FS \
154*0Sstevel@tonic-gate 	gettext("invalid or unsupported archive filesystem: %s\n")
155*0Sstevel@tonic-gate 
156*0Sstevel@tonic-gate #define	NEED_FORCE \
157*0Sstevel@tonic-gate 	gettext("This operation is only supported with the force flag (-f)\n")
158*0Sstevel@tonic-gate 
159*0Sstevel@tonic-gate #define	REL_PATH_REQ \
160*0Sstevel@tonic-gate 	gettext("path (%s) must be relative to root. For example: etc/foo\n")
161*0Sstevel@tonic-gate 
162*0Sstevel@tonic-gate #define	OPEN_FAIL gettext("failed to open file: %s: %s\n")
163*0Sstevel@tonic-gate 
164*0Sstevel@tonic-gate #define	LOCK_FAIL gettext("failed to lock file: %s: %s\n")
165*0Sstevel@tonic-gate 
166*0Sstevel@tonic-gate #define	UNLOCK_FAIL gettext("failed to unlock file: %s: %s\n")
167*0Sstevel@tonic-gate 
168*0Sstevel@tonic-gate #define	FILE_LOCKED gettext("Another instance of bootadm (pid %u) is running\n")
169*0Sstevel@tonic-gate 
170*0Sstevel@tonic-gate #define	FLIST_FAIL \
171*0Sstevel@tonic-gate 	gettext("failed to open archive filelist: %s: %s\n")
172*0Sstevel@tonic-gate 
173*0Sstevel@tonic-gate #define	NO_FLIST gettext("archive filelist is empty\n")
174*0Sstevel@tonic-gate 
175*0Sstevel@tonic-gate #define	CLOSE_FAIL gettext("failed to close file: %s: %s\n")
176*0Sstevel@tonic-gate 
177*0Sstevel@tonic-gate #define	RENAME_FAIL gettext("rename to file failed: %s: %s\n")
178*0Sstevel@tonic-gate 
179*0Sstevel@tonic-gate #define	NOT_IN_MNTTAB gettext("alternate root %s not in mnttab\n")
180*0Sstevel@tonic-gate 
181*0Sstevel@tonic-gate #define	CANT_RESOLVE gettext("cannot resolve path %s: %s\n")
182*0Sstevel@tonic-gate 
183*0Sstevel@tonic-gate #define	ROOT_ABS gettext("this sub-command doesn't take root arguments: %s\n")
184*0Sstevel@tonic-gate 
185*0Sstevel@tonic-gate #define	RDONLY_FS gettext("read-only filesystem: %s\n")
186*0Sstevel@tonic-gate 
187*0Sstevel@tonic-gate #define	ARCHIVE_FAIL gettext("failed to create boot archive: %s\n")
188*0Sstevel@tonic-gate 
189*0Sstevel@tonic-gate #define	ARCHIVE_NOT_CREATED gettext("couldn't create boot archive: %s\n")
190*0Sstevel@tonic-gate 
191*0Sstevel@tonic-gate #define	WRITE_FAIL gettext("write to file failed: %s: %s\n")
192*0Sstevel@tonic-gate 
193*0Sstevel@tonic-gate #define	STAT_FAIL gettext("stat of file failed: %s: %s\n")
194*0Sstevel@tonic-gate 
195*0Sstevel@tonic-gate #define	PACK_FAIL gettext("failed to pack stat data: %s\n")
196*0Sstevel@tonic-gate 
197*0Sstevel@tonic-gate #define	NVALLOC_FAIL gettext("failed to create stat data: %s\n")
198*0Sstevel@tonic-gate 
199*0Sstevel@tonic-gate #define	NVADD_FAIL gettext("failed to update stat data for: %s: %s\n")
200*0Sstevel@tonic-gate 
201*0Sstevel@tonic-gate #define	NOT_NV gettext("option is not a name=value pair: %s\n")
202*0Sstevel@tonic-gate 
203*0Sstevel@tonic-gate #define	DISKMAP_FAIL gettext("cannot map disk %s to grub name\n")
204*0Sstevel@tonic-gate 
205*0Sstevel@tonic-gate #define	DISKMAP_FAIL_NONFATAL \
206*0Sstevel@tonic-gate     gettext("cannot map disk %s to grub name, assume disk 0.\n")
207*0Sstevel@tonic-gate 
208*0Sstevel@tonic-gate #define	WARN_BOOT \
209*0Sstevel@tonic-gate gettext("WARNING: Incorrect use of this command may make \
210*0Sstevel@tonic-gate the system unbootable\n")
211*0Sstevel@tonic-gate 
212*0Sstevel@tonic-gate #define	WARN_FAILSAFE_BOOT \
213*0Sstevel@tonic-gate gettext("WARNING: Incorrect use of this command may make \
214*0Sstevel@tonic-gate the failsafe archive unbootable\n")
215*0Sstevel@tonic-gate 
216*0Sstevel@tonic-gate #define	UPDATE_NO_STAT \
217*0Sstevel@tonic-gate 	gettext("%s state file %s not found.\n")
218*0Sstevel@tonic-gate 
219*0Sstevel@tonic-gate #define	CHECK_NOT_SUPPORTED \
220*0Sstevel@tonic-gate 	gettext("the check option is not supported with subcmd: %s\n")
221*0Sstevel@tonic-gate 
222*0Sstevel@tonic-gate #define	PARSEABLE_NEW_FILE	gettext("    new     %s\n")
223*0Sstevel@tonic-gate 
224*0Sstevel@tonic-gate #define	PARSEABLE_OUT_DATE	gettext("    changed %s\n")
225*0Sstevel@tonic-gate 
226*0Sstevel@tonic-gate #define	UPDATE_FORCE gettext("forced update of archive requested\n")
227*0Sstevel@tonic-gate 
228*0Sstevel@tonic-gate #define	NO_NEW_STAT gettext("cannot create new stat data\n")
229*0Sstevel@tonic-gate 
230*0Sstevel@tonic-gate #define	UPDATE_ARCH_MISS gettext("archive not found: %s\n")
231*0Sstevel@tonic-gate 
232*0Sstevel@tonic-gate #define	READ_FAIL gettext("read failed for file: %s: %s\n")
233*0Sstevel@tonic-gate 
234*0Sstevel@tonic-gate #define	UNPACK_FAIL gettext("failed to unpack stat data: %s: %s\n")
235*0Sstevel@tonic-gate 
236*0Sstevel@tonic-gate #define	NFTW_FAIL gettext("cannot find: %s: %s\n")
237*0Sstevel@tonic-gate 
238*0Sstevel@tonic-gate #define	NVL_ALLOC_FAIL gettext("failed to alloc nvlist: %s\n")
239*0Sstevel@tonic-gate 
240*0Sstevel@tonic-gate #define	STATVFS_FAIL gettext("statvfs failed for %s: %s\n")
241*0Sstevel@tonic-gate 
242*0Sstevel@tonic-gate #define	IS_RAMDISK gettext("%s is on a ramdisk device\n")
243*0Sstevel@tonic-gate 
244*0Sstevel@tonic-gate #define	SKIP_RAMDISK gettext("Skipping archive creation\n")
245*0Sstevel@tonic-gate 
246*0Sstevel@tonic-gate #define	PRINT gettext("%s\n")
247*0Sstevel@tonic-gate 
248*0Sstevel@tonic-gate #define	PRINT_NO_NEWLINE gettext("%s")
249*0Sstevel@tonic-gate 
250*0Sstevel@tonic-gate #define	PRINT_TITLE gettext("%d %s\n")
251*0Sstevel@tonic-gate 
252*0Sstevel@tonic-gate #define	INT_ERROR gettext("Internal error: %s\n")
253*0Sstevel@tonic-gate 
254*0Sstevel@tonic-gate #define	CANT_FIND_USER \
255*0Sstevel@tonic-gate 	gettext("getpwnam: uid for %s failed, defaulting to %d\n")
256*0Sstevel@tonic-gate 
257*0Sstevel@tonic-gate #define	CANT_FIND_GROUP \
258*0Sstevel@tonic-gate 	gettext("getgrnam: gid for %s failed, defaulting to %d\n")
259*0Sstevel@tonic-gate 
260*0Sstevel@tonic-gate #define	CHMOD_FAIL gettext("chmod operation on %s failed - %s\n")
261*0Sstevel@tonic-gate 
262*0Sstevel@tonic-gate #define	CHOWN_FAIL gettext("chgrp operation on %s failed - %s\n")
263*0Sstevel@tonic-gate 
264*0Sstevel@tonic-gate #ifdef	__cplusplus
265*0Sstevel@tonic-gate }
266*0Sstevel@tonic-gate #endif
267*0Sstevel@tonic-gate 
268*0Sstevel@tonic-gate #endif /* _MESSAGE_H */
269