Unable to track error
up vote
1
down vote
favorite
While running my program I found the following errors
today.ksh[36]: test: 0403-004 Specify a parameter with this command.
sed: 0602-419 Cannot find or open file /home/tmp/filename.
today.ksh[37]: test: 0403-004 Specify a parameter with this command.
today.ksh[24]: test: 0403-021 A ] character is missing.
but I am unable to understand meaning of following:
- sed:0602-419 what means by 0602-419 ?
today.ksh[37] what is 37 indicates ? and test: 0403-004 what it means?
In short the numbers range like 'test: 0403-004' that is getting displayed what they mean ? how it can be useful while debugging in ksh?
bash shell-script ksh
add a comment |
up vote
1
down vote
favorite
While running my program I found the following errors
today.ksh[36]: test: 0403-004 Specify a parameter with this command.
sed: 0602-419 Cannot find or open file /home/tmp/filename.
today.ksh[37]: test: 0403-004 Specify a parameter with this command.
today.ksh[24]: test: 0403-021 A ] character is missing.
but I am unable to understand meaning of following:
- sed:0602-419 what means by 0602-419 ?
today.ksh[37] what is 37 indicates ? and test: 0403-004 what it means?
In short the numbers range like 'test: 0403-004' that is getting displayed what they mean ? how it can be useful while debugging in ksh?
bash shell-script ksh
number between bracket represent line number of script file, in that case today.ksh[37] open file today.ksh at line 37. (vi +37 today.ksh)
– Archemar
Apr 2 '15 at 11:41
@Archemar At line 37 in Ksh I have declared a variable which is not related to it.
– Aman
Apr 2 '15 at 11:45
you can useksh -x
to have debugging, I guess from missing operand that you set a variable namefoobar
, then later use$fobar
. Also, look first on line 24, it is often best to search earliest error.
– Archemar
Apr 2 '15 at 11:54
@Arhemar suppose my ksh file name is today.ksh then should i run as ksh -x today.ksh on terminal
– Aman
Apr 2 '15 at 12:17
add a comment |
up vote
1
down vote
favorite
up vote
1
down vote
favorite
While running my program I found the following errors
today.ksh[36]: test: 0403-004 Specify a parameter with this command.
sed: 0602-419 Cannot find or open file /home/tmp/filename.
today.ksh[37]: test: 0403-004 Specify a parameter with this command.
today.ksh[24]: test: 0403-021 A ] character is missing.
but I am unable to understand meaning of following:
- sed:0602-419 what means by 0602-419 ?
today.ksh[37] what is 37 indicates ? and test: 0403-004 what it means?
In short the numbers range like 'test: 0403-004' that is getting displayed what they mean ? how it can be useful while debugging in ksh?
bash shell-script ksh
While running my program I found the following errors
today.ksh[36]: test: 0403-004 Specify a parameter with this command.
sed: 0602-419 Cannot find or open file /home/tmp/filename.
today.ksh[37]: test: 0403-004 Specify a parameter with this command.
today.ksh[24]: test: 0403-021 A ] character is missing.
but I am unable to understand meaning of following:
- sed:0602-419 what means by 0602-419 ?
today.ksh[37] what is 37 indicates ? and test: 0403-004 what it means?
In short the numbers range like 'test: 0403-004' that is getting displayed what they mean ? how it can be useful while debugging in ksh?
bash shell-script ksh
bash shell-script ksh
edited Nov 25 at 23:13
Rui F Ribeiro
38.3k1477127
38.3k1477127
asked Apr 2 '15 at 11:24
Aman
1611215
1611215
number between bracket represent line number of script file, in that case today.ksh[37] open file today.ksh at line 37. (vi +37 today.ksh)
– Archemar
Apr 2 '15 at 11:41
@Archemar At line 37 in Ksh I have declared a variable which is not related to it.
– Aman
Apr 2 '15 at 11:45
you can useksh -x
to have debugging, I guess from missing operand that you set a variable namefoobar
, then later use$fobar
. Also, look first on line 24, it is often best to search earliest error.
– Archemar
Apr 2 '15 at 11:54
@Arhemar suppose my ksh file name is today.ksh then should i run as ksh -x today.ksh on terminal
– Aman
Apr 2 '15 at 12:17
add a comment |
number between bracket represent line number of script file, in that case today.ksh[37] open file today.ksh at line 37. (vi +37 today.ksh)
– Archemar
Apr 2 '15 at 11:41
@Archemar At line 37 in Ksh I have declared a variable which is not related to it.
– Aman
Apr 2 '15 at 11:45
you can useksh -x
to have debugging, I guess from missing operand that you set a variable namefoobar
, then later use$fobar
. Also, look first on line 24, it is often best to search earliest error.
– Archemar
Apr 2 '15 at 11:54
@Arhemar suppose my ksh file name is today.ksh then should i run as ksh -x today.ksh on terminal
– Aman
Apr 2 '15 at 12:17
number between bracket represent line number of script file, in that case today.ksh[37] open file today.ksh at line 37. (vi +37 today.ksh)
– Archemar
Apr 2 '15 at 11:41
number between bracket represent line number of script file, in that case today.ksh[37] open file today.ksh at line 37. (vi +37 today.ksh)
– Archemar
Apr 2 '15 at 11:41
@Archemar At line 37 in Ksh I have declared a variable which is not related to it.
– Aman
Apr 2 '15 at 11:45
@Archemar At line 37 in Ksh I have declared a variable which is not related to it.
– Aman
Apr 2 '15 at 11:45
you can use
ksh -x
to have debugging, I guess from missing operand that you set a variable name foobar
, then later use $fobar
. Also, look first on line 24, it is often best to search earliest error.– Archemar
Apr 2 '15 at 11:54
you can use
ksh -x
to have debugging, I guess from missing operand that you set a variable name foobar
, then later use $fobar
. Also, look first on line 24, it is often best to search earliest error.– Archemar
Apr 2 '15 at 11:54
@Arhemar suppose my ksh file name is today.ksh then should i run as ksh -x today.ksh on terminal
– Aman
Apr 2 '15 at 12:17
@Arhemar suppose my ksh file name is today.ksh then should i run as ksh -x today.ksh on terminal
– Aman
Apr 2 '15 at 12:17
add a comment |
1 Answer
1
active
oldest
votes
up vote
1
down vote
accepted
Welcome to AIX.
On of the things that is ubiquitous in IBM operating systems is the idea that system messages all have identifying alphanumeric codes. The messages may be translated into different languages, but the codes stay the same. And there is usually, as part of IBM's documentation, a reference manual where one can go and look up these messages by their code.
On OS/2 and OS/400, codes take the form of a three-letter facility designator and a four-digit message number. (OS/2 users will remember things such as SYS0002
, and the ability to look these codes up at the command line with the help
and helpmsg
commands.) On AIX they take the form of a four-digit operating system component number and a three-digit message number.
So 0403-004 is not a "range". It's a message code, for component number 0403 message number 004. Component 0403 is the Korn Shell. Component 0602 is the group of UNIX text editing tools: vi
, ex
, ed
, sed
, and awk
.
And, yes, AIX has a big reference manual listing all of these codes.
However, it isn't exactly detailed in its treatment of the messages. (In comparison, the OS/2 help facility has a detailed description and action for most SYS
messages seen at the command line.) Therefore:
- 0403-004: You've most likely forgotten to put quotes around a variable expansion, resulting in it expanding to nothing when the variable is unset and hence a syntax error for the
test
command. - 0403-021: When invoked as
[
, the command requires that the final argument be a]
. Commonly, this error is the result of forgetting to make the final]
character a separate word on its own.
Further reading
"Appendix A. Error Message Index". AIX Version 4.3 Messages Guide and Reference. IBM Corporation. 1997-10.
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
accepted
Welcome to AIX.
On of the things that is ubiquitous in IBM operating systems is the idea that system messages all have identifying alphanumeric codes. The messages may be translated into different languages, but the codes stay the same. And there is usually, as part of IBM's documentation, a reference manual where one can go and look up these messages by their code.
On OS/2 and OS/400, codes take the form of a three-letter facility designator and a four-digit message number. (OS/2 users will remember things such as SYS0002
, and the ability to look these codes up at the command line with the help
and helpmsg
commands.) On AIX they take the form of a four-digit operating system component number and a three-digit message number.
So 0403-004 is not a "range". It's a message code, for component number 0403 message number 004. Component 0403 is the Korn Shell. Component 0602 is the group of UNIX text editing tools: vi
, ex
, ed
, sed
, and awk
.
And, yes, AIX has a big reference manual listing all of these codes.
However, it isn't exactly detailed in its treatment of the messages. (In comparison, the OS/2 help facility has a detailed description and action for most SYS
messages seen at the command line.) Therefore:
- 0403-004: You've most likely forgotten to put quotes around a variable expansion, resulting in it expanding to nothing when the variable is unset and hence a syntax error for the
test
command. - 0403-021: When invoked as
[
, the command requires that the final argument be a]
. Commonly, this error is the result of forgetting to make the final]
character a separate word on its own.
Further reading
"Appendix A. Error Message Index". AIX Version 4.3 Messages Guide and Reference. IBM Corporation. 1997-10.
add a comment |
up vote
1
down vote
accepted
Welcome to AIX.
On of the things that is ubiquitous in IBM operating systems is the idea that system messages all have identifying alphanumeric codes. The messages may be translated into different languages, but the codes stay the same. And there is usually, as part of IBM's documentation, a reference manual where one can go and look up these messages by their code.
On OS/2 and OS/400, codes take the form of a three-letter facility designator and a four-digit message number. (OS/2 users will remember things such as SYS0002
, and the ability to look these codes up at the command line with the help
and helpmsg
commands.) On AIX they take the form of a four-digit operating system component number and a three-digit message number.
So 0403-004 is not a "range". It's a message code, for component number 0403 message number 004. Component 0403 is the Korn Shell. Component 0602 is the group of UNIX text editing tools: vi
, ex
, ed
, sed
, and awk
.
And, yes, AIX has a big reference manual listing all of these codes.
However, it isn't exactly detailed in its treatment of the messages. (In comparison, the OS/2 help facility has a detailed description and action for most SYS
messages seen at the command line.) Therefore:
- 0403-004: You've most likely forgotten to put quotes around a variable expansion, resulting in it expanding to nothing when the variable is unset and hence a syntax error for the
test
command. - 0403-021: When invoked as
[
, the command requires that the final argument be a]
. Commonly, this error is the result of forgetting to make the final]
character a separate word on its own.
Further reading
"Appendix A. Error Message Index". AIX Version 4.3 Messages Guide and Reference. IBM Corporation. 1997-10.
add a comment |
up vote
1
down vote
accepted
up vote
1
down vote
accepted
Welcome to AIX.
On of the things that is ubiquitous in IBM operating systems is the idea that system messages all have identifying alphanumeric codes. The messages may be translated into different languages, but the codes stay the same. And there is usually, as part of IBM's documentation, a reference manual where one can go and look up these messages by their code.
On OS/2 and OS/400, codes take the form of a three-letter facility designator and a four-digit message number. (OS/2 users will remember things such as SYS0002
, and the ability to look these codes up at the command line with the help
and helpmsg
commands.) On AIX they take the form of a four-digit operating system component number and a three-digit message number.
So 0403-004 is not a "range". It's a message code, for component number 0403 message number 004. Component 0403 is the Korn Shell. Component 0602 is the group of UNIX text editing tools: vi
, ex
, ed
, sed
, and awk
.
And, yes, AIX has a big reference manual listing all of these codes.
However, it isn't exactly detailed in its treatment of the messages. (In comparison, the OS/2 help facility has a detailed description and action for most SYS
messages seen at the command line.) Therefore:
- 0403-004: You've most likely forgotten to put quotes around a variable expansion, resulting in it expanding to nothing when the variable is unset and hence a syntax error for the
test
command. - 0403-021: When invoked as
[
, the command requires that the final argument be a]
. Commonly, this error is the result of forgetting to make the final]
character a separate word on its own.
Further reading
"Appendix A. Error Message Index". AIX Version 4.3 Messages Guide and Reference. IBM Corporation. 1997-10.
Welcome to AIX.
On of the things that is ubiquitous in IBM operating systems is the idea that system messages all have identifying alphanumeric codes. The messages may be translated into different languages, but the codes stay the same. And there is usually, as part of IBM's documentation, a reference manual where one can go and look up these messages by their code.
On OS/2 and OS/400, codes take the form of a three-letter facility designator and a four-digit message number. (OS/2 users will remember things such as SYS0002
, and the ability to look these codes up at the command line with the help
and helpmsg
commands.) On AIX they take the form of a four-digit operating system component number and a three-digit message number.
So 0403-004 is not a "range". It's a message code, for component number 0403 message number 004. Component 0403 is the Korn Shell. Component 0602 is the group of UNIX text editing tools: vi
, ex
, ed
, sed
, and awk
.
And, yes, AIX has a big reference manual listing all of these codes.
However, it isn't exactly detailed in its treatment of the messages. (In comparison, the OS/2 help facility has a detailed description and action for most SYS
messages seen at the command line.) Therefore:
- 0403-004: You've most likely forgotten to put quotes around a variable expansion, resulting in it expanding to nothing when the variable is unset and hence a syntax error for the
test
command. - 0403-021: When invoked as
[
, the command requires that the final argument be a]
. Commonly, this error is the result of forgetting to make the final]
character a separate word on its own.
Further reading
"Appendix A. Error Message Index". AIX Version 4.3 Messages Guide and Reference. IBM Corporation. 1997-10.
answered Apr 4 '15 at 21:57
JdeBP
32.3k468152
32.3k468152
add a comment |
add a comment |
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f194006%2funable-to-track-error%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
number between bracket represent line number of script file, in that case today.ksh[37] open file today.ksh at line 37. (vi +37 today.ksh)
– Archemar
Apr 2 '15 at 11:41
@Archemar At line 37 in Ksh I have declared a variable which is not related to it.
– Aman
Apr 2 '15 at 11:45
you can use
ksh -x
to have debugging, I guess from missing operand that you set a variable namefoobar
, then later use$fobar
. Also, look first on line 24, it is often best to search earliest error.– Archemar
Apr 2 '15 at 11:54
@Arhemar suppose my ksh file name is today.ksh then should i run as ksh -x today.ksh on terminal
– Aman
Apr 2 '15 at 12:17