JBOSS EAP 6.3 INSTALLATION & Configuration
To represent the user add the following to the server-identities definition <secret value="dWF0cml56jAeNF8=" />
JBOSS EAP 6.3 INSTALLATION & Configuration:
HomePath: /usr/local/jboss/
1. Download the jboss-eap-6.3.0.zip from Red hat portal
2. Unzip the file to /usr/local
$ unzip jboss-eap-6.3.0.GA.zip
Jboss will be installed in /usr/local
$ cd /usr/local/jboss-eap-6.3/bin
3. Adding the users ,these step is common for both domain and standalone mode.
$ ./adduser.sh
# it will ask which type of user you want for Management User select a
What type of user do you wish to add?
a) Management User (mgmt-users.properties)
b) Application User (application-users.properties)
(a): a
Enter the details of the new user to add.
Using realm 'ManagementRealm' as discovered from the existing property files.
Username : master
Password :
# give user name and password for management user
4. Adding groups
What groups do you want this user to belong to? (Please enter a comma separated list, or leave blank for none)[ ]: Gowtham
About to add user 'master' for realm 'ManagementRealm'
Is this correct yes/no? Yes
Added user 'master' to file '/usr/local/jboss-eap-6.3/standalone/configuration/mgmt-users.properties'
Added user 'master' to file '/usr/local/jboss-eap-6.3/domain/configuration/mgmt-users.properties'
Added user 'master' with groups newproject to file '/usr/local/jboss-eap-6.3/standalone/configuration/mgmt-groups.properties'
Added user 'master' with groups newproject to file '/usr/local/jboss-eap-6.3/domain/configuration/mgmt-groups.properties'
Is this new user going to be used for one AS process to connect to another AS process?
e.g. for a slave host controller connecting to the master or for a Remoting connection for server to server EJB calls.
yes/no? Yes
Note:( Secret value used for the configuration purpose so note seperately)
To represent the user add the following to the server-identities definition <secret value="YWRtaW5trhryu3" />
5. Adding application user
$ ./add-user.sh
What type of user do you wish to add?
a) Management User (mgmt-users.properties)
b) Application User (application-users.properties)
(a): b
Enter the details of the new user to add.
Using realm 'ApplicationRealm' as discovered from the existing property files.
Username : slave
Password :
What groups do you want this user to belong to? (Please enter a comma separated list, or leave blank for none)[ ]: newproject
About to add user 'slave' for realm 'ApplicationRealm'
Is this correct yes/no? Yes
Added user 'slave' to file '/usr/local/jboss-eap-6.3/standalone/configuration/application-users.properties'
Added user 'slave' to file '/usr/local/jboss-eap-6.3/domain/configuration/application-users.properties'
Added user 'slave' with groups newproject to file '/usr/local/jboss-eap-6.3/standalone/configuration/application-roles.properties'
Added user 'slave' with groups newproject to file '/usr/local/jboss-eap-6.3/domain/configuration/application-roles.properties'
Is this new user going to be used for one AS process to connect to another AS process?
e.g. for a slave host controller connecting to the master or for a Remoting connection for server to server EJB calls.
yes/no? yes
To represent the user add the following to the server-identities definition <secret value="YXBwdXNgmghritht=" />
Configuration Steps:
Parsing the parameters to start
Domain Controller:
Home Path/bin/
-
cp domain.conf (as an backup before editing)
JAVA_OPTS="$JAVA_OPTS
-Djboss.bind.address=<Domain-Controller IP>
-Djboss.bind.address.management=<Domain-Controller IP>"
Slave (Host-Controller)
-
cp domain.conf (as an backup before editing)
JAVA_OPTS="$JAVA_OPTS
-Djboss.domain.master.address=<Domain-Controller
IP>-Djboss.bind.address=<Slave-IP>
-Djboss.bind.address.management=<Slave-IP>"
Configuration for domain and slave:
Home Path/domain/configuration
Domain-Controller:
-
cp host.xml (as an backup before editing>
-
No Change required except master name (Important)
Host-Controller:
-
cp host.xml (as an backup before editing>
-
In the Host.xml file do the changes based on below configuration:
########################################################################
<?xml version='1.0' encoding='UTF-8'?>
<host name="slave" xmlns="urn:jboss:domain:1.6">
<management>
<security-realms>
<security-realm name="ManagementRealm">
<server-identities>
<secret value="bWF0cml4Mgmgkrk575="/>
</server-identities>
<authentication>
<local default-user="$local" skip-group-loading="true"/>
<properties path="mgmt-users.properties" relative-to="jboss.domain.config.dir"/>
</authentication>
<authorization map-groups-to-roles="false">
<properties path="mgmt-groups.properties" relative-to="jboss.domain.config.dir"/>
</authorization>
</security-realm>
<security-realm name="ApplicationRealm">
############################################################################
<domain-controller>
<remote host="192.168.1.45" port="9999" security-realm="ManagementRealm" username="gowtham"/>
</domain-controller>
############################################################################
5.) add the secret value (whic we got during the adduser.sh script end in domain controller>
add the user name. domaincontroller ip and port 9999.
Start the Server from /home/bin/./domain.sh in (Master and Slave)
Console to be accessed:
http://<ipaddress>:9990
username:
password:
Create a Server Group:
Before Creating select in master or slave we need to create (ServerGroup and Servers):
-
Domain→ Server Groups → Add → (Name-Profile-SocketBindings)
Profile Types: Default, Full, HA, Full-HA.
2.) Domain → Server Configuration → Add → ( Name-ServerGroup-PortOffset-Autostart).
6.To start jboss eap 6.3.0 as service
For domain mode
$ sudo mkdir /etc/jboss-as
$ sudo cp jboss-as.conf /etc/jboss-as/
$ sudo cp jboss-as-domain.sh /etc/init.d
$ sudo chkconfig --add jboss-as-domain.sh
$ sudo service jboss-as-domain.sh start
$ vi jboss-as-domain.sh
#define where jboss is - this is the directory containing directories log, bin, conf etc
JBOSS_HOME="/usr/local/jboss-eap-6.2/"
#make sure java is in the path
JAVAPTH="/usr/java/bin "
#configuration to use 'all'
JBOSS_CONF="all"
JBOSS_HOST= as per host ip
#if JBOSS_HOST specified, use -b to bind jboss services to that address
JBOSS_BIND_ADDR=${JBOSS_HOST:+"-b $JBOSS_HOST"}
#define the script to use to start jboss
JBOSSSH=${JBOSSSH:-"$JBOSS_HOME/bin/domain.sh -c $JBOSS_CONF $JBOSS_BIND_ADDR" }
For standalonemode
$ sudo cp jboss-as-standalone.sh /etc/init.d
$ sudo chkconfig --add jboss-as-standalone.sh
$ sudo service jboss-as-standalone start
$ vi jboss-as-standalone.sh
#define where jboss is - this is the directory containing directories log, bin, conf etc
JBOSS_HOME="/usr/local/jboss-eap-6.2/"
#make sure java is in the path
JAVAPTH="/usr/java/bin "
#configuration to use 'all'
JBOSS_CONF="all"
JBOSS_HOST= 198.168.1.67
#if JBOSS_HOST specified, use -b to bind jboss services to that address
JBOSS_BIND_ADDR=${JBOSS_HOST:+"-b $JBOSS_HOST"}
#define the script to use to start jboss
JBOSSSH=${JBOSSSH:-"$JBOSS_HOME/bin/standalone.sh -c $JBOSS_CONF $JBOSS_BIND_ADDR" }
7. Clustering configuration
edit host-slave.xml in any one node
$ vi /usr/local/jboss-eap-6.2/domain/configuration/hosts-slave.xml
<?xml version='1.0' encoding='UTF-8'?>
<host name="slave1" xmlns="urn:jboss:domain:1.3">
<management>
<security-realms>
<security-realm name="ManagementRealm">
<server-identities>
<secret value="${jboss.domain.login.password}"/>
</server-identities>
<authentication>
<local default-user="$local"/>
<properties path="mgmt-users.properties" relative-to="jboss.domain.config.dir"/>
</authentication>
</security-realm>
<security-realm name="ManagementRealm">
<server-identities>
<secret value="d2Vsa29t"/>
</server-identities>
<authentication>
local default-user="$local"/>
<properties path="mgmt-users.properties" relative-to="jboss.domain.config.dir"/>
</authentication>
</security-realm>
<domain-controller>
<remote
host="${jboss.domain.master.address}"
port="${jboss.domain.master.port:9999}" security-realm="ManagementRealm"
username="${jboss.domain.login.user}"/>
</domain-controller>
Comments
Post a Comment