Skip to main content

How to change the server name of the top level DAS/Standalone Server

Please note these forums are being decommissioned and use the new and improved forums at
No replies
Joined: 2010-06-11
Points: 0

I have installed glassfish 4 and want to override the server name for the default server profile.

<server name="bill" config-ref="server-config">
      <application-ref ref="__admingui" virtual-servers="__asadmin"></application-ref>
      <resource-ref ref="jdbc/__TimerPool"></resource-ref>
      <resource-ref ref="jdbc/__default"></resource-ref>
      <resource-ref ref="jms/__defaultConnectionFactory"></resource-ref>
      <resource-ref ref="concurrent/__defaultManagedScheduledExecutorService"></resource-ref>
      <resource-ref ref="concurrent/__defaultManagedExecutorService"></resource-ref>
      <resource-ref ref="concurrent/__defaultContextService"></resource-ref>
      <resource-ref ref="concurrent/__defaultManagedThreadFactory"></resource-ref>

It appears to be hard-coded to "server" because when I change it to anything else, the start-domain process fails with

com.sun.enterprise.universal.xml.MiniXmlParserException: "Xml Parser Error: The server element for server does not exist. Command start-domain failed./pre>

Is it possible to change it ? If not, can someone show me in code where I could change it, please.