Operating System - HP-UX
1748272 Members
4241 Online
108760 Solutions
New Discussion

Getting error at system startup : /sbin/rc[67]: syntax error at line 269 : `"' unmatched

 
PEPSICOTeam
Occasional Contributor

Getting error at system startup : /sbin/rc[67]: syntax error at line 269 : `"' unmatched

 

Hi Experts,

Getting error message at system startup,  appreciate if anyone knows whats the issue here..and what to check:

OS : hp-ux 11.23 , rebooted after 250 days.

 

 

 

 

Below message while booting up: 

---------------------------------------

...

Rights for non-DOD U.S. Government Departments and Agencies are as set
forth in FAR 52.227-19 (1,2).
/sbin/rc[67]: syntax error at line 269 : `"' unmatched  `"` `"'
/sbin/rc1.d/S093vxvm-reconfig[51]: /etc/vx/lib/vxcommon:  not found
/sbin/rc1.d/S105vparinit[63]: /usr/sbin/kcpath:  not found
/sbin/rc[14]: /sbin/rc2.d/S370named:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S550sfmdb:  not found
/sbin/rc2.d/S590Rpcd[30]: syntax error at line 269 : `"' unmatched

...

-----

 

Thanks in advance,

6 REPLIES 6
donna hofmeister
Trusted Contributor

Re: Getting error at system startup : /sbin/rc[67]: syntax error at line 269 : `"' unmatched

look at this file -- /sbin/rc2.d/S590Rpcd[30].  That the one with the syntax error (at line 269 : `"' unmatched)

 

there's a (really) good chance that this file has been changed.

PEPSICOTeam
Occasional Contributor

Re: Getting error at system startup : /sbin/rc[67]: syntax error at line 269 : `"' unmatched

The message saying syntax error for all the files,  does that means all the files having syntax error.

I am sure that there is some problem under  /etc/rc.config.d/  for some file.  Is there any command to check it...

Thank for your reply...

 

PEPSICOTeam
Occasional Contributor

Re: Getting error at system startup : /sbin/rc[67]: syntax error at line 269 : `"' unmatched

 

 

This is the error at system startup:

---------------------------------------

 

Rights for non-DOD U.S. Government Departments and Agencies are as set
forth in FAR 52.227-19 (1,2).
/sbin/rc[67]: syntax error at line 269 : `"' unmatched  `"` `"'
/sbin/rc1.d/S093vxvm-reconfig[51]: /etc/vx/lib/vxcommon:  not found
/sbin/rc1.d/S105vparinit[63]: /usr/sbin/kcpath:  not found
/sbin/rc[14]: /sbin/rc2.d/S370named:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S550sfmdb:  not found
/sbin/rc2.d/S590Rpcd[30]: syntax error at line 269 : `"' unmatched
/sbin/rc2.d/S620xfs[10]: env:  not found
/sbin/rc2.d/S620xfs[10]: grep:  not found
/sbin/rc2.d/S700acct[39]: syntax error at line 269 : `"' unmatched
/sbin/rc2.d/S700xf86[252]: /var/tmp/xf86.log: cannot create
/sbin/rc2.d/S700xf86[268]: tee:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S810hpsmdb:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S810pctl:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S890hpsim:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S895gwlmagt:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S895gwlmcms:  not found
/sbin/rc2.d/S900drd[21]: syntax error at line 269 : `"' unmatched
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S996vradmind:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S996vxrsyncd:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S999isisd:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc2.d/S99appqcime:  not found
/sbin/rc3.d/S200tps.rc[15]: /usr/bin/hostname:  not found
/sbin/rc3.d/S69esmrc[52]: /esm/platform:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
/sbin/rc[14]: /sbin/rc3.d/S700shcschedulerd:  not found
/sbin/rc3.d/S800cmcluster[486]: /usr/bin/tty:  not found
interpreter "/bin/sh" not found
file link resolves to "/usr/bin/sh"
-----------------------------------------------------------------------------

 

 

 

 

 

 

 

- Now to decode the first line , where the error came first:  [  /sbin/rc[67]: syntax error at line 269 : `"' unmatched  `"` `"' ]

 

- Firstly :

/sbin/rc  line 67 pointing to /sbin/rc.config  and  further  to  /etc/rc.config.d/     ,

 

/sbin/rc [ line 67 ]

67          . /etc/rc.config

 

 

 

- Secondly :

/etc/rc.config  file contains below :

 

 >cat -n  /etc/rc.config
     1  # This script sources configuration files for various subsystems. Configuration
     2  # variables are in files CFG_FILE in /etc/rc.config.d/*, and /etc/TIMEZONE.
     3  # Simple error checks are done: test file perms and for dumped "core" files.
     4  # Filenames containing [.,~#] are not sourced - they are possible names of
     5  # backup files such as file.bak, file.OLD, ~file, file~, file,v, #file etc.
     6  #
     7  # @(#)B11.23_LR
     8
     9  for CFG_FILE in /etc/rc.config.d/* /etc/TIMEZONE
    10  do
    11          fname=${CFG_FILE##*/}           # get file basename
    12          if [ -f $CFG_FILE -a "$fname" != "core" -a "${fname##*[.,~\#]}" = "$fname" ]
    13          then . $CFG_FILE                # source a valid config file
    14          fi
    15  done

#---------------------------------------------------------------------------------------------------------------------

 

 

 

Please advise how to fix the syntax error , and where exactly is the syntax error ...

 

 

Thanks,

 

 

Steven Schweda
Honored Contributor

Re: Getting error at system startup : /sbin/rc[67]: syntax error at line 269 : `"' unmatched

> interpreter "/bin/sh" not found
> file link resolves to "/usr/bin/sh"

 

   I'd worry about this one first.  Did you lose the "/usr" file system?

PEPSICOTeam
Occasional Contributor

Re: Getting error at system startup : /sbin/rc[67]: syntax error at line 269 : `"' unmatched

Thanks..

 

James R. Ferguson
Acclaimed Contributor

Re: Getting error at system startup : /sbin/rc[67]: syntax error at line 269 : `"' unmatched

Hi:

 

Keeping "backup" copies of files in the '/etc/rc.config.d' directory can lead to the behavior you have observed. You can keep backup copies of files here _ONLY_ if you follow the rules documented in '/etc/rc.config'.

One way to expose your problem is to do:

 

# sh -vx /etc/rc.config 2>&1|more

 
The actual filename of the culprit will appear as 'fname=' in the traced output with clear syntax errors.

 

Regards!

 

...JRF...