Hi Laird,
According to the descriptions in |--domainproperties| in
|create-domain|(1)
<
http://docs.oracle.com/cd/E26576_01/doc.312/e24938/create-domain.htm#GSRFM00023>:
On UNIX, creating sockets that listen on ports 1-1024 requires
superuser privileges.
Looks as if this statement would benefit from being repeated in the
description of --portbase, where it's probably more prominent.
If you are running without superuser privileges on a UNIX or Linux
system, you might be encountering this restriction:
Without superuser privileges:
$ asadmin create-domain --nopassword --portbase=70 jx
Port 118 is in use.
Usage: asadmin [asadmin-utility-options] create-domain
[--adminport <adminport(default:4848)>] [--portbase <portbase>]
[--template <template>] [--domaindir <domaindir>]
[--instanceport <instanceport(default:8080)>]
[--savemasterpassword[=<savemasterpassword(default:false)>]]
[--usemasterpassword[=<usemasterpassword(default:false)>]]
[--domainproperties <domainproperties>]
[--keytooloptions <keytooloptions>]
[--savelogin[=<savelogin(default:false)>]]
[--nopassword[=<nopassword(default:false)>]]
[--checkports[=<checkports(default:true)>]]
[-?|--help[=<help(default:false)>]] domain_name
Command create-domain failed.
With superuser privileges:
$ sudo asadmin create-domain --nopassword --portbase=70 jx
Password:
Using port 118 for Admin.
Using port 150 for HTTP Instance.
Using port 146 for JMS.
Using port 107 for IIOP.
Using port 151 for HTTP_SSL.
Using port 108 for IIOP_SSL.
Using port 109 for IIOP_MUTUALAUTH.
Using port 156 for JMX_ADMIN.
Using port 136 for OSGI_SHELL.
Using port 79 for JAVA_DEBUGGER.
On Unix platforms, port numbers below 1024 may require special
privileges.
Distinguished Name of the self-signed X.509 Server Certificate is:
[CN=adc6140529.us.oracle.com,OU=GlassFish,O=Oracle
Corporation,L=Santa Clara,ST=California,C=US]
Distinguished Name of the self-signed X.509 Server Certificate is:
[CN=adc6140529.us.oracle.com-instance,OU=GlassFish,O=Oracle
Corporation,L=Santa Clara,ST=California,C=US]
No domain initializers found, bypassing customization step
Domain jx created.
Domain jx admin port is 118.
Domain jx allows admin login as user "admin" with no password.
Command create-domain executed successfully.
Regards,
-Paul
On 3/19/2012 2:27 PM, Laird Nelson wrote:
> Color me puzzled.
>
> Attempting to create a domain like so, and it's failing telling me
> port 118 is in use. I didn't know (or read) that asadmin used port
> 118. The best list of ports that I could find that Glassfish's
> domains use by default is accessible from here:
> http://docs.oracle.com/cd/E26576_01/doc.312/e24928/domains.htm#gldel
>
> Google searches on various common sense combinations of asadmin and
> port 118 came back empty.
>
> If it helps, there is currently a JBoss instance on the box that is
> running (on HTTP port 8080 and others) that I am not permitted to take
> down--and in any event I want to understand what's going on.
>
> JXdevi: ./bin/asadmin create-domain --nopassword --portbase=70 jx
> Port 118 is in use.
> Usage: asadmin [asadmin-utility-options] create-domain
> [--adminport <adminport(default:4848)>] [--portbase <portbase>]
> [--template <template>] [--domaindir <domaindir>]
> [--instanceport <instanceport(default:8080)>]
> [--savemasterpassword[=<savemasterpassword(default:false)>]]
> [--usemasterpassword[=<usemasterpassword(default:false)>]]
> [--domainproperties <domainproperties>]
> [--keytooloptions <keytooloptions>]
> [--savelogin[=<savelogin(default:false)>]]
> [--nopassword[=<nopassword(default:false)>]]
> [--checkports[=<checkports(default:true)>]]
> [-?|--help[=<help(default:false)>]] domain_name
> Command create-domain failed.
>
> How would I work around a port 118 conflict? Port 118 is apparently a
> well-known TCP port for "SQL services", whatever those are.
>
> My apologies if this is a rudimentary question.
>
> Best,
> Laird
>
> --
> http://about.me/lairdnelson
>