I am using GlassFish 3.1.2. I want to create a service of GlassFish so that each the system start it will automatically start the GlassFish domain.
In default domain domain1, there is a cluster cluster1 having two instances instance1 and instance2.
But when I use the command...
asadmin>domain1Service.exe start
It starts the domain, but clusters are not started. So How can I make a service which can start clusters ??
Do I have to create separate service for each instance within a cluster ??
We can create service over cluster instance in GlassFish.
For that we have to create separate service for each instance.
This command is used to create service for each an instance..
asadmin>>create-service --nodedir <<node-dir location>> <<node-name>>
Thanks,
Gunjan.
It sounds like you are running this on a windows machine, so I would write a batch script (.bat) that executes the appropriate asadmin commands.
asadmin start-domain --user admin --passwordfile adminpassword.txt domain1
asadmin start-cluster --user admin --passwordfile adminpassword.txt cluster1
Than I would setup the service to point at the batch file.
Related
I have created two containers (ddev-website-web and ddev-api-web) via DDEV.
Now I want to access the website container from the api container via SFTP.
How can I create a SFTP user in DDEV for the website container? Is this possible at all?
The containers are already connected via a router.
I think
Install sshd using this technique from ddev-contrib will work for you, at least will get you started with having an ssh server
Add vsftpd by adding to webimage_extra_packages inthe config.ssh.yaml: webimage_extra_packages: [vsftpd, openssh-server] to your .ddev/config.yaml
From there, you may have some extra config to do based on https://linuxopsys.com/topics/install-vsftpd-ftp-server-on-debian
As a test environment to monitor status of Windows Servers (CPU, Disk usage, Memory, network etc) I have placed two testing nodes with Windows-Exporter configured on custom port :15000
Next, I have created proper jobs for each separate Windows instances and created dashboard in Grafana.
The problem is that I'm looking for securing nodes so only Prometheus server can access node output and all other computers in same network get deny access to node website.
I have tried to install Windows Node with setting:
msiexec /i windows_exporter-0.19.0-amd64.msi LISTEN_PORT="15000" EXTRA_FLAGS="--web.config.file=C:\Configuration\web.yml"
As well as with different configurations of " and ' in commandline for EXTRA_FLAGS parameter - yet it seems they are being ignored. The only parameter working fine is change of listen port.
I have followed instructions provided at https://prometheus.io/docs/guides/basic-auth/ to set up basic auth.
Web.yml looks like this:
basic_auth:
username: 'scrapper'
password: '$2a$14$AWpxyT1KcRPSE07IfmqTqOZznpMfGwxHP8uPVQV8G0qdjggND3hgC'
However, after installation with msiexec - entry in Windows services for windows_exporter is without web.config.file entry:
"C:\Program Files\windows_exporter\windows_exporter.exe" --log.format logger:eventlog?name=windows_exporter --telemetry.addr 0.0.0.0:15000
I have tried to edit service entry with sc command but it broke node completely, making me rolling back to unprotected access to node.
Does basic auth work on windows-exporter same way as on node-exporter for Linux OSes?
Or is there other possible way to secure access to node exposed data without need to install IIS?
I have never worked with node exporter in Windows, but in Linux, your Web.yml configuration file should be as follows:
basic_auth_users:
<string>: <secret>
like this:
basic_auth_users:
scrapper: $2a$14$AWpxyT1KcRPSE07IfmqTqOZznpMfGwxHP8uPVQV8G0qdjggND3hgC
I am following the article that I found here...
https://docs.docker.com/datacenter/install/aws/
I am able to deploy the template, but I do not see the UCP and DTR URLs in the output tab.
Actually there are only 2 parameters in the output tab. DefaultDNSTarget and Managers. How do I connect to docker swarm?
I need to connect to Public IP of Docker Manager instance. For e.g. if the IP is 52.90.20.41 then the ssh command will look something like this...
ssh -i yourkey.pem docker#52.90.20.41
In the "Managers" Parameter of the output tab the value should be a URL that will redirect you to a filtered view of the EC2 Instances that are the managers. There you will see the PublicIpAddresses of the managers.
I have a weblogic cluster env with one admin and two managed servers, i need JMX ports added to startup script.
I have two shell script to start admin and managed server.
Please advice how to add the JMX port in the start up script.
Add the following JVM parameters to your Weblogic startup scripts
-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=8888
Goto admin console> server> click on managed server > server start > Argument.
You can add above parameter in under argument list.
also add -Djavax.management.builder.initial=weblogic.management.jmx.mbeanserver.WLSMBeanServerBuilder in the arguments list
I have designed a simple windows service in .NET 2.0.
I am trying to deploy it on my local machine. I have switched to design view, and setup ServiceInstaller and ServiceProcessInstaller objects. There is a Project Installer. I have also wrapped the Windows Service into a .NET setup project and install it, leaving an .exe in the specified directory.
I have fired up cmd and entered the path to installutil. This works fine, but then I typeinstallutil and the full path to the service, in Visual Studio command prompt, and this does not work (I've also tried installutil /i and all sorts of things out of desperation). The permissions are local system (extensive).
Any ideas what I am doing wrong? For those here who have installed Windows Services, what was your methodology to install the service?
Thanks
We actually create an installer built into our application. It's a console app that has a command line to install/uninstall the server as well as run as a service or in console mode.
See this article on a Self Installing Service for some details. I like this method as it provides flexibility.
DESCRIPTION:
SC is a command line program used for communicating with the
NT Service Controller and services.
USAGE:
sc [command] [service name] ...
The option has the form "\\ServerName"
Further help on commands can be obtained by typing: "sc [command]"
Commands:
query-----------Queries the status for a service, or
enumerates the status for types of services.
queryex---------Queries the extended status for a service, or
enumerates the status for types of services.
start-----------Starts a service.
pause-----------Sends a PAUSE control request to a service.
interrogate-----Sends an INTERROGATE control request to a service.
continue--------Sends a CONTINUE control request to a service.
stop------------Sends a STOP request to a service.
config----------Changes the configuration of a service (persistant).
description-----Changes the description of a service.
failure---------Changes the actions taken by a service upon failure.
qc--------------Queries the configuration information for a service.
qdescription----Queries the description for a service.
qfailure--------Queries the actions taken by a service upon failure.
delete----------Deletes a service (from the registry).
create----------Creates a service. (adds it to the registry).
control---------Sends a control to a service.
sdshow----------Displays a service's security descriptor.
sdset-----------Sets a service's security descriptor.
GetDisplayName--Gets the DisplayName for a service.
GetKeyName------Gets the ServiceKeyName for a service.
EnumDepend------Enumerates Service Dependencies.
The following commands don't require a service name:
sc
boot------------(ok | bad) Indicates whether the last boot should
be saved as the last-known-good boot configuration
Lock------------Locks the Service Database
QueryLock-------Queries the LockStatus for the SCManager Database
EXAMPLE:
sc start MyService
Here's another reference specific to .NET services.
http://bytes.com/forum/thread739857.html
I'm calling installutil in my setup package and it works for me just fine.
That'd be great if you posted an error message that you're getting when running installutil.