Operating System - HP-UX
1856450 Members
3490 Online
104113 Solutions
New Discussion

Re: The specified number is not valid for this command

 
SOLVED
Go to solution
Rainer Lindenmayer
Occasional Advisor

The specified number is not valid for this command

The following error was received when booting a system:
sbin/rc[38]: 048 The specified number is not valid for this command
This message is displayed after the DHCP message and before the start of the list of services being started. HPUX 11.00 QPK1100 SEP 2002
8 REPLIES 8
Michael Tully
Honored Contributor

Re: The specified number is not valid for this command

It looks like an environment problem in relation to a shell command. Were there any changes done to either the scripts in /sbin/rc? or any the env files under /etc/rc.config.d/?

Was this message displayed on the first reboot of the system after applying the patch bundle?
Anyone for a Mutiny ?
Rainer Lindenmayer
Occasional Advisor

Re: The specified number is not valid for this command

Hallo Michael,
yes, the message displayed on the first reboot of the system, after applying QPK1100 SEP 2002.
There are no changes in sbin/rc or /etc/rc.config.d
The colored highlights on status message (list of services being started) are all white. Normaly its green or yellow.
Thanks
Frank Slootweg
Honored Contributor
Solution

Re: The specified number is not valid for this command

I have no specific/detailed pointers/instructions, but apparently you have to follow special installation instructions (for the QPK?) and you have not.

See for example the following thread (for 11.11, but, as far as I know, the problem is similar for 11.00):

http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x161e06350fe2d61190050090279cd0f9,00.html
Steve Steel
Honored Contributor

Re: The specified number is not valid for this command

Hi


See if you have loaded patch PHCO_26789.

It has the following strange special instructions.

..
Special Installation Instructions:

Shell now recognizes octal and hexa numbers inside arithmetic expression.

This may have impact on some of the scripts.
For example: rc.utils might have configured as follows:
let ROWS="$rows"
let COLS="$cols"

Now, if the rows/cols variables start with a 0, the shell will interpret the
data as octal numbers resulting in incorrect interpretations or errors. Hence we
advise users to change the rc.utils as follows:
let ROWS="${rows##*(0)}"
let COLS="${cols##*(0)}"


If so try the change as it happened to me.

Steve Steel
If you want truly to understand something, try to change it. (Kurt Lewin)
Rainer Lindenmayer
Occasional Advisor

Re: The specified number is not valid for this command

Hi
thanks to all, the problem is solved. Steve and Frank had the correct reference
That is the solution:
let ROWS="${rows##*(0)}"
let COLS="${cols##*(0)}"

Bye,
Rainer
Pete Randall
Outstanding Contributor

Re: The specified number is not valid for this command

Frank/Steve,

Can this be changed proactively (i.e. before the QPK is applied)?

Pete

Pete
Frank Slootweg
Honored Contributor

Re: The specified number is not valid for this command

Pete (and others),

As far as I know, this can be changed proactively (i.e. before the QPK is applied).

The problem is that the shell treats 048, i.e. with a leading zero, as octal and you can not have octal 8. The "${rows##*(0)}" construct strips of the leading zero(s) and also works in an old shell:

$ rows=048
$ let ROWS="${rows##*(0)}"
$ echo $ROWS
48
$
Pete Randall
Outstanding Contributor

Re: The specified number is not valid for this command

Thanks Frank - I wanted to be sure.

Pete

Pete