I am working on a Mac.
I am running Linux Ubuntu server in a VirtualBox. GlassFish 4 and MySql are already running there. The Linux IP is 10.0.1.12.
On the guest system (Mac) I am running Eclipse Luna. I installed the GlassFish Tools for Eclipse Luna and restarted Eclipse.
Then I wanted to add server for GlassFish4. But Eclipse is asking me for "Server root" and I have no clue what it means! I entered "10.0.1.12:4848/" just as I can access GlassFish from the host system (Mac OS) by a browser. But it just doesn't accept that URL. It seems to expect a local directory path. Here is the dialog box:
Thanks in advance for any hints!!
You need to install a Glassfish4 Server to your local machine (the one Eclipse is running on) despite the fact that you want to connect to and manage a remote Glassfish server; Eclipse will use some of the files in that local installation to manage the remote Glassfish server. Assuming you already have Glassfish4 installed on a remote machine:
[For example purposes]
Let's assume the remote Glassfish server is at 192.168.2.7 on default port 4848 for administration and you've set a password for 'admin' user as 'gfish'.
Let's also assume that your local desktop (development machine running Eclipse Luna) is at 192.168.2.3
Download Glassfish4 Open Source edition zip
Unzip the contents to a directory on your local machine: let's say inside of path /glassfish_server/ you will now have:
/glassfish_server/glassfish4/glassfish/ structure
Back in Eclipse:
Create a New Server -> Select 'Glassfish4' option
Server's Hostname =[remote ip address] // E.G. 192.168.2.7
Server Name: GlassFish 4 at 192.168.2.7 // get's auto-filled
[Next] This is the page you were specifically having issue with:
Set the Root Path to your Local Glassfish Server install directory
so in this example: /glassfish_server/glassfish4/glassfish/ should be accepted
[Next] Now use the credentials and configuration for your remote glassfish server. Run a Ping-Test to test connection.
The server root means the directory where GlassFish is located. This might be, for example, /opt/glassfish4/glassfish. Eclipse needs this so that it can look for the bin/ directory and be able to start/stop the server using the scripts in there.
Related
I have a project running on linux - ubuntu server.
I cloned this project to the server with git.
I made many changes on the project on the server.
I need to get this new version on my local PC.
How can I do it?
If you have SSH access to that Linux server, you can use an SSH URL like:
# on PC
git clone remoteUser#remoteServer:/path/to/repo
That supposes you have published your SSH public key to the remote server ~remoteUser/.ssh/authorized_keys
I have created a Personal Server using the P4V "Helix Client" on my Windows 10 workstation at home.
I would like to be able to connect to this server from my laptop on the LAN so that I can pull from it. (To make sure that everything that is required for the project is correctly in the repository, and testing)
Should I be able to connect to this server using the workstations IP address and port 1666?
Is there an additional step I need to take to "serve" the repository?
A "personal server" doesn't listen on the network by default (the client spawns a short-lived server process in place each time it runs a command).
To convert your personal server into a shared server, install the Perforce service (this'll be part of the server installer on Windows) and set its server root directory to match the path you gave your personal server.
Alternatively, you can go to a command prompt and run:
p4d -r Z:\Core\.p4root -p 1666
but that server will only be up and listening for as long as that command prompt is open, whereas the service (p4s.exe) will run in the background.
We need to provide "localhost:1666" as the server which means that (the same as the IP address 127.0.0.1). It will only work for you and not other machines.
Open the tab "Initialize New Personel Server" Tab and then specify your server location.
I am using Red Hat Enterprise Linux Server release 5.1 (Tikanga) and apache-tomcat-6.0.35.tomcat install on port 8080 than i change in 80(default) . Using tomcat deploy war file(abc.war) successfully but i want to access this application as (www.abc.com). plz suggest how to replace index file(ROOT)??
Two things:
You need to pay for a domain name and point it at your IP address.
Create (or symlink) your application's .xml file to ROOT.xml in the webapps directory. This will mean you can access the application using '/' as well as '/abc'.
RackSpace Cloud Server Ubuntu-12.04, Intellij Idea-11.1.2, Windows-8, Tomcat-7.0.26, JDK-6.
On Intellij Idea when i try to run jsf project on my remote Tomcat 7 server it says:
Error running servername: Unable to connect to the ip-address:1099
It seems problem is about JNDI port which is 1099 but I couldn't activate it I guess. Tomcat config is sth. like that:
What I've tried?
Setting CATALINA_OPTS or JAVA_OPTS on the server side with:
CATALINA_OPTS=-Dcom.sun.management.jmxremote
-Dcom.sun.management.jmxremote.port=1099
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false
and
JAVA_OPTS=-Dcom.sun.management.jmxremote
-Dcom.sun.management.jmxremote.port=1099
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false
But this one did not work, any ideas?
My answer to my question:
The correct way to deploy remotely is editing JAVA_OPTS environment variable on the remote server. Just enter the command below:
export JAVA_OPTS="-Dcom.sun.management.jmxremote=
-Dcom.sun.management.jmxremote.port=1099
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false"
If that's not going to work and if you don't have any obsession to deploy your website via Intellij Idea, I've got the solution for this problem. To be able to run your website under Tomcat, you can/should get artifact in form of .war file.
It can be done in Intellij from project settings(ctrl+alt+shift+s) then hit the plus button and add new artifact(web:application archieve)
After rebuilding the artifact, .war file can be seen in project-folder\out\artifacts. Next, you should place this file into your tomcat/webapps folder.
For example if you are using Tomcat-7, the folder that I mean exists in /var/lib/tomcat7/webapps. Before copying your .war file you should rename it as ROOT.war. This provides to access your site directly by http://youripaddress:8080. After restarting Tomcat7 service you can access the site.
But not finished yet, you can debug your project remotely like you are debugging your project at your local machine with Intellij Idea. Open Run/Debug Configuration in Idea, hit the plus button and there must be Remote. This is the way to debug your projects for application servers like JBoss, Glassfish as well in Idea. Enter your host and port numbers, select your project as a module.
Before starting to debug, as Intellij says you should give the following parameter to your server JVM:
JAVA_OPTS="$JAVA_OPTS -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005"
To be able to do that in Ubuntu and for Tomcat-7, modified the catalina.sh file in usr/share/tomcat7 folder. I inserted the parameter above of the if [ -z "$LOGGING_MANAGER" ]; then line. It must be on the middle part of the file. Then you should be able to debug your project with Intellij Idea.
I am having difficulty connecting to a remote Windows system running cygwin.
When I connect from a linux box to cygwin, it connects fine and "sees" the
remote home directory as /home/userID
When I connect from Windows cygwin to the remote windows cygwin, it sees
the home directory as /cygdrive/c/Documents and Settings/UserID
Finally, when I am logged onto the remote Windows machine (the one with the problem)
home is /home/UseID but the value for cygpath -H is
$ echo $(cygpath -H)
/cygdrive/c/Documents and Settings
This seems to be causing my connection problem from windows to windows
and no problem from linux to windows
Any ideas how to fix it?
Since you have the correct path in /etc/passwd, one possibility is that perhaps the SSH client you are using from your Windows systems is sending custom environment values.
If you're using PuTTY, before connecting, look in the tree panel on the left hand side of the dialog. There should be an entry called Connection and a sub-entry called Data which will bring you to an option screen that has a section called Environment variables. Check if the HOME var is being overridden there and if so, remove it.
If you're using a different SSH client, check its configuration to see if its using the SendEnv option. More info on that here: http://www.openbsd.org/cgi-bin/man.cgi?query=ssh_config.
Or you could try blocking off custom environments on the destination/server side by disabling AcceptEnv in the SSHd configuration on the system you're connecting to. More info on that here: http://www.openbsd.org/cgi-bin/man.cgi?query=sshd_config.
Hope this helps.