<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: rc.config Syntax error in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978911#M294091</link>
    <description>Please, revoke the write and execute bits from rc.config (chmod 0444 /etc/rc.config).&lt;BR /&gt;As others already have replied this file isn't meant to be executed but to be sourced.&lt;BR /&gt;As you can easiliy verify the sourcing of rc.config actually happens here:&lt;BR /&gt;&lt;BR /&gt;# grep -n rc\.config /sbin/rc&lt;BR /&gt;58:# If /etc/rc.config contains default information (first boot),&lt;BR /&gt;66:if [ -f /etc/rc.config ]; then&lt;BR /&gt;67:     . /etc/rc.config&lt;BR /&gt;76:     echo "\nWARNING: /etc/rc.config does not exist"&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;rc.config isn't meant to be tampered with at all.&lt;BR /&gt;So it was a good decision to copy the original from newconfig back in place.&lt;BR /&gt;&lt;BR /&gt;Your syntax error most likely results from any of your files in /etc/rc.config.d&lt;BR /&gt;&lt;BR /&gt;What you could do to possibly identify the culprit may be this:&lt;BR /&gt;&lt;BR /&gt;# cd /etc/rc.config.d&lt;BR /&gt;# echo *|xargs -n1 sh -n 2&amp;gt;&amp;amp;1|grep -v permission\ denied&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Wed, 11 Apr 2007 03:02:58 GMT</pubDate>
    <dc:creator>Ralph Grothe</dc:creator>
    <dc:date>2007-04-11T03:02:58Z</dc:date>
    <item>
      <title>rc.config Syntax error</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978904#M294084</link>
      <description>Recently, I had some issues regarding my server's hostname, whenever I restarted the system it changed back to "unknown".  After reading some other thread, I found my problem in the rc.config file &lt;BR /&gt;I tried to manually started it:&lt;BR /&gt;&lt;BR /&gt;root:/etc #ll rc.config&lt;BR /&gt;-r--r--r--   1 root       sys            636 Apr 11 00:34 rc.config&lt;BR /&gt;root:/etc #./rc.config&lt;BR /&gt;sh: ./rc.config: Execute permission denied.&lt;BR /&gt;&lt;BR /&gt;I changed permissions to allow execution to everybody&lt;BR /&gt;&lt;BR /&gt;root:/etc #chmod 777 rc.config&lt;BR /&gt;root:/etc #./rc.config&lt;BR /&gt;./rc.config[13]: Syntax error at line 3 : `(' is not expected.&lt;BR /&gt;&lt;BR /&gt;now i get this weird error saying that there's a syntax error on the rc.config file, i have already checked and replace this file with another one (the one on /usr/newconfig/etc/rc.config) but still got the same problem.&lt;BR /&gt;&lt;BR /&gt;just by looking at the file I can't find anything wrong with it, can somebody help me find the source of the problem (see rc.config attachment)&lt;BR /&gt;</description>
      <pubDate>Wed, 11 Apr 2007 00:53:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978904#M294084</guid>
      <dc:creator>Mynor Aguilar</dc:creator>
      <dc:date>2007-04-11T00:53:45Z</dc:date>
    </item>
    <item>
      <title>Re: rc.config Syntax error</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978905#M294085</link>
      <description>&lt;!--!*#--&gt;Without a "#!" first line, this script&lt;BR /&gt;(script fragment, actually) does not specify&lt;BR /&gt;the shell to be used to process it.  With a&lt;BR /&gt;plain "#", you might be getting a C shell, or&lt;BR /&gt;who knows what?&lt;BR /&gt;&lt;BR /&gt;Script fragments like this are normally fed&lt;BR /&gt;to the shell of your choice, for example:&lt;BR /&gt;&lt;BR /&gt;   sh ./rc.config&lt;BR /&gt;&lt;BR /&gt;And for that, you don't need execute&lt;BR /&gt;permission.&lt;BR /&gt;&lt;BR /&gt;That may not make your script (fragment) work&lt;BR /&gt;properly, but it should get it executed.</description>
      <pubDate>Wed, 11 Apr 2007 01:12:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978905#M294085</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2007-04-11T01:12:49Z</dc:date>
    </item>
    <item>
      <title>Re: rc.config Syntax error</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978906#M294086</link>
      <description>cd /etc&lt;BR /&gt;sh rc.config            &lt;BR /&gt;you may try entering &lt;BR /&gt;echo Done &lt;BR /&gt;in last of the your rc.config to check for execution.&lt;BR /&gt;</description>
      <pubDate>Wed, 11 Apr 2007 01:46:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978906#M294086</guid>
      <dc:creator>Anshumali</dc:creator>
      <dc:date>2007-04-11T01:46:39Z</dc:date>
    </item>
    <item>
      <title>Re: rc.config Syntax error</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978907#M294087</link>
      <description>Change your permission back to read and execute via sh &lt;FILENAME&gt;&lt;BR /&gt;&lt;/FILENAME&gt;</description>
      <pubDate>Wed, 11 Apr 2007 01:48:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978907#M294087</guid>
      <dc:creator>Jollyjet</dc:creator>
      <dc:date>2007-04-11T01:48:15Z</dc:date>
    </item>
    <item>
      <title>Re: rc.config Syntax error</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978908#M294088</link>
      <description>rc.config is meant to be sourced:&lt;BR /&gt;# . ./rc.config&lt;BR /&gt;&lt;BR /&gt;If you replaced by the one it newconfig, you should be fine.  This file should not be changed, only the files under /etc/rc.config.d/.&lt;BR /&gt;&lt;BR /&gt;Note line 13 is sourcing files in rc.config.d/ and it could be a file there that has that "(" syntax error.&lt;BR /&gt;&lt;BR /&gt;I assume you know, you can't have any left over files in that directory??&lt;BR /&gt;&lt;BR /&gt;You could also add "set -x" to rc.config to see which file in rc.config.d/ has the problem, then remove that -x.</description>
      <pubDate>Wed, 11 Apr 2007 02:08:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978908#M294088</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2007-04-11T02:08:30Z</dc:date>
    </item>
    <item>
      <title>Re: rc.config Syntax error</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978909#M294089</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;How do u know that there is problem with ur&lt;BR /&gt;/etc/rc.config ? &lt;BR /&gt;If u r experienceing problem with hostname then &lt;BR /&gt;it cound be some configuration errors (HOSTNAME)&lt;BR /&gt;in the file /etc/rc.config.d/netconf.&lt;BR /&gt;&lt;BR /&gt;Check this and also restore permissions of&lt;BR /&gt;/etc/rc.config.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;-Santosh</description>
      <pubDate>Wed, 11 Apr 2007 02:21:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978909#M294089</guid>
      <dc:creator>SANTOSH S. MHASKAR</dc:creator>
      <dc:date>2007-04-11T02:21:03Z</dc:date>
    </item>
    <item>
      <title>Re: rc.config Syntax error</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978910#M294090</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;/etc/rc.config doesnot require execute permissions.&lt;BR /&gt;This file is executed by init and executed in the&lt;BR /&gt;same shell&lt;BR /&gt;eg. &lt;BR /&gt;# . /etc/rc.config&lt;BR /&gt;&lt;BR /&gt;will execute the file in same shell so that all&lt;BR /&gt;the env. variables are available in the present&lt;BR /&gt;shell.&lt;BR /&gt;&lt;BR /&gt;Also as u have told below&lt;BR /&gt;&lt;BR /&gt;root:/etc #./rc.config&lt;BR /&gt;./rc.config[13]: Syntax error at line 3 : `(' is not expected.&lt;BR /&gt;&lt;BR /&gt;Line no. 13 is&lt;BR /&gt;if [ -f $CFG_FILE -a "$fname" != "core" -a "${fname##*[.,~\#]}" = "$fname" ]&lt;BR /&gt;&lt;BR /&gt;nowhere '(' sign.&lt;BR /&gt;&lt;BR /&gt;So I suggest u to verify /etc/rc.config.d/netconf&lt;BR /&gt;and set HOSTNAME parameter in that file&lt;BR /&gt;and reboot the machine. If u don't want to&lt;BR /&gt;reboot u can temporarily set hostname as&lt;BR /&gt;&lt;BR /&gt;# hostname &lt;UR_HOSTNAME&gt;&lt;BR /&gt;&lt;BR /&gt;but it will vanish after a reboot, so&lt;BR /&gt;set HOSTNAME in /etc/rc.config.d/netconf&lt;BR /&gt;&lt;BR /&gt;&lt;/UR_HOSTNAME&gt;</description>
      <pubDate>Wed, 11 Apr 2007 03:01:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978910#M294090</guid>
      <dc:creator>SANTOSH S. MHASKAR</dc:creator>
      <dc:date>2007-04-11T03:01:06Z</dc:date>
    </item>
    <item>
      <title>Re: rc.config Syntax error</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978911#M294091</link>
      <description>Please, revoke the write and execute bits from rc.config (chmod 0444 /etc/rc.config).&lt;BR /&gt;As others already have replied this file isn't meant to be executed but to be sourced.&lt;BR /&gt;As you can easiliy verify the sourcing of rc.config actually happens here:&lt;BR /&gt;&lt;BR /&gt;# grep -n rc\.config /sbin/rc&lt;BR /&gt;58:# If /etc/rc.config contains default information (first boot),&lt;BR /&gt;66:if [ -f /etc/rc.config ]; then&lt;BR /&gt;67:     . /etc/rc.config&lt;BR /&gt;76:     echo "\nWARNING: /etc/rc.config does not exist"&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;rc.config isn't meant to be tampered with at all.&lt;BR /&gt;So it was a good decision to copy the original from newconfig back in place.&lt;BR /&gt;&lt;BR /&gt;Your syntax error most likely results from any of your files in /etc/rc.config.d&lt;BR /&gt;&lt;BR /&gt;What you could do to possibly identify the culprit may be this:&lt;BR /&gt;&lt;BR /&gt;# cd /etc/rc.config.d&lt;BR /&gt;# echo *|xargs -n1 sh -n 2&amp;gt;&amp;amp;1|grep -v permission\ denied&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 11 Apr 2007 03:02:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978911#M294091</guid>
      <dc:creator>Ralph Grothe</dc:creator>
      <dc:date>2007-04-11T03:02:58Z</dc:date>
    </item>
    <item>
      <title>Re: rc.config Syntax error</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978912#M294092</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;/etc/rc.config doesnot require execute permissions.&lt;BR /&gt;This file is executed by init and executed in the&lt;BR /&gt;same shell&lt;BR /&gt;eg. &lt;BR /&gt;# . /etc/rc.config&lt;BR /&gt;&lt;BR /&gt;will execute the file in same shell so that all&lt;BR /&gt;the env. variables are available in the present&lt;BR /&gt;shell.&lt;BR /&gt;&lt;BR /&gt;Also as u have told below&lt;BR /&gt;&lt;BR /&gt;root:/etc #./rc.config&lt;BR /&gt;./rc.config[13]: Syntax error at line 3 : `(' is not expected.&lt;BR /&gt;&lt;BR /&gt;Line no. 13 is&lt;BR /&gt;if [ -f $CFG_FILE -a "$fname" != "core" -a "${fname##*[.,~\#]}" = "$fname" ]&lt;BR /&gt;&lt;BR /&gt;nowhere '(' sign.&lt;BR /&gt;&lt;BR /&gt;So I suggest u to verify /etc/rc.config.d/netconf&lt;BR /&gt;and set HOSTNAME parameter in that file&lt;BR /&gt;and reboot the machine. If u don't want to&lt;BR /&gt;reboot u can temporarily set hostname as&lt;BR /&gt;&lt;BR /&gt;# hostname &lt;UR_HOSTNAME&gt;&lt;BR /&gt;&lt;BR /&gt;but it will vanish after a reboot, so&lt;BR /&gt;set HOSTNAME in /etc/rc.config.d/netconf&lt;BR /&gt;if u want to set it parmenant.&lt;/UR_HOSTNAME&gt;</description>
      <pubDate>Wed, 11 Apr 2007 03:03:47 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978912#M294092</guid>
      <dc:creator>SANTOSH S. MHASKAR</dc:creator>
      <dc:date>2007-04-11T03:03:47Z</dc:date>
    </item>
    <item>
      <title>Re: rc.config Syntax error</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978913#M294093</link>
      <description>thanks for all your replies, I'm currently out of office and will let you know the status of this as soon as I can.&lt;BR /&gt;Thanks</description>
      <pubDate>Wed, 11 Apr 2007 08:43:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rc-config-syntax-error/m-p/3978913#M294093</guid>
      <dc:creator>Mynor Aguilar</dc:creator>
      <dc:date>2007-04-11T08:43:31Z</dc:date>
    </item>
  </channel>
</rss>

