eclipse error: glassfish\domains\domain1 does not exist

前端 未结 8 927
感情败类
感情败类 2020-11-30 13:03

I have java ee6 web profile sdk & I am using eclipse ee. I installed Glassfish plugin for eclipse using Download additional server adapters in the New Serve

相关标签:
8条回答
  • 2020-11-30 13:23

    Although late reply, but may be useful to someone facing similar issues.

    If no domain exists in your glassfish path i.e say C:\glassfish4\glassfish\domains\ then you can create a new domain in the same path as follows:

    1. Navigate to C:\glassfish4\bin\ directory and double click on asadmin.bat. It will open a command prompt as asadmin >

    2. Type the following command asadmin > create-domain --adminport 4848 domain1

    3. Click Enter repeatedly to keep the default settings viz. username (admin) password and other things.

    That's it. You will find the domain1 created under C:\glassfish4\glassfish\domains\ directory with all default configurations.

    If want to create domain in another directory or want some more info then can refer Oracle Glassfish Reference Manual:

    http://docs.oracle.com/cd/E19798-01/821-1758/create-domain-1/index.html

    0 讨论(0)
  • 2020-11-30 13:24

    create a new domain with

    asadmin create-domain myDomain
    

    add the path of this new domain, if there is a message "domain is not valid", make the folder domains/myDomain/conf permission to not only the root. If there is the message "is not writtable" then open Eclipse as root and try again. This should be work in these cases.

    0 讨论(0)
  • 2020-11-30 13:26

    In my case, the C:\glassfish4\glassfish\domains\domain1\config\ domain.xml was renamed to something like domain568912323464576456.xml, so I edited the file, leaving it as it supposed to be named and done, server started up again.

    0 讨论(0)
  • 2020-11-30 13:28

    Either your eclipse glassfish plugin points to the wrong domain or your server has no domain although there should be at least a default domain which is usually named domain1.

    Check what's the name of your domain in glassfish-install-dir\glassfish\domains directory. If there is no subdir, you can create a domain with the asadmin tool:

    glassfish-install-dir\bin\asadmin create-domain your-domain-name
    

    See this description of the create-domain command.

    If you already have a domain with a different name than domain1, you have to reconfigure your eclipse glassfish plugin. (Since I don't use eclipse, I can't take you any further. But I remember a BalusC tutorial on this topic).

    0 讨论(0)
  • 2020-11-30 13:32

    I ran into this same problem and fixed it with the following:

    1. Open a command prompt and browse to C:\glassfish3\glassfish\bin (or whatever your glassfish directory is)
    2. Execute asadmin
    3. Type in create-domain --adminport 4848 domain1 (your debug port can probably be whatever)
    4. Go back into Eclipse and continue
    0 讨论(0)
  • 2020-11-30 13:35

    You must to add a password to your admin user. Eclipse mistake. Eclipse doesn't recognise the domain without admin password.

    When you create the domain, add a admin user and a password and Eclipse doesn't complain any more.

    0 讨论(0)
提交回复
热议问题