Showing posts with label multiuser. Show all posts
Showing posts with label multiuser. Show all posts

12 June 2013

447. Multiuser ECCE

A recent comment lead me to make this post:
[..] Can you advise a correct way of setting up ECCE so that everyone can have an individual account and run on the same machine?

It's a valid question. I haven't had any need for it since I'm running my own cluster, which I currently don't share with anyone. I also manage a multi-user cluster overseas, but I am the only one using ECCE, and so I'm fine running the ECCE server here.

Anyway. I built ECCE 6.4 as shown e.g. here and here.

Below I install the ECCE server as the user verahill, and then install the client software as the users lindqvst and me. In the former case I configure the server using a copied config_from_server script, and in the latter case I use config_with_server. Both methods worked fine. All users are on the same machine, but by editing apps/siteconfig/DataServers you can quite easily configure the ECCE client to connect to a remote server.


Server:

hostname
helium
sudo adduser verahill sudo adduser lindqvst ./install_ecce.v6.4.csh
Main ECCE installation menu =========================== 1) Help on main menu options 2) Prerequisite software check 3) Full install 4) Full upgrade 5) Application software install 6) Application software upgrade 7) Server install 8) Server upgrade IMPORTANT: If you are uncertain about any aspect of installing or running ECCE at your site, please refer to the detailed ECCE Installation and Administration Guide at http://ecce.pnl.gov/docs/installation/2864B-Installation.pdf Hit at prompts to accept the default value in brackets. Selection: [1] 7 Host name: [helium] Server installation directory: [/home/verahill/ecce-v6.4/server] Enter the path to the ECCE application software directory that will use this server (even if this directory is not accessible from the current machine) or [return] if you have not installed application software yet or don't want to update it: ECCE v6.4 will be installed using the settings: Installation type: [server install] Host name: [helium] Server installation directory: [/home/verahill/ecce-v6.4/server] Are these choices correct (yes/no/quit)? [yes] ECCE installation succeeded. *************************************************************** !! You MUST perform the following steps in order to use ECCE !! -- Transfer the script: /home/verahill/ecce-v6.4/server/ecce-admin/config_from_server to the machine where the application software is installed. Run this script as the same user as the application software installation. (This step can be skipped if you have not installed the application software and the server name is specified during that install) -- Start the ECCE server as 'verahill' by running: /home/verahill/ecce-v6.4/server/ecce-admin/start_ecce_server ***************************************************************
cp /home/verahill/ecce-v6.4/server/ecce-admin/config_from_server ~ chmod ugo+r config_from_server


First client
su lindqvst
cd ~
cp /home/verahill/config_from_server .
cp /home/verahill/install_ecce.v6.4.csh .
./install_ecce.v6.4.csh
Main ECCE installation menu =========================== 1) Help on main menu options 2) Prerequisite software check 3) Full install 4) Full upgrade 5) Application software install 6) Application software upgrade 7) Server install 8) Server upgrade IMPORTANT: If you are uncertain about any aspect of installing or running ECCE at your site, please refer to the detailed ECCE Installation and Administration Guide at http://ecce.pnl.gov/docs/installation/2864B-Installation.pdf Hit at prompts to accept the default value in brackets. Selection: [1] 5 Host name: [helium] Server installation directory: [/home/lindqvst/ecce-v6.4/apps] ECCE installation succeeded. *************************************************************** !! You MUST perform the following steps in order to use ECCE !! -- Configure the application software to use the desired ECCE server by running the script: /home/lindqvst/ecce-v6.4/apps/scripts/config_with_server as the same user as the application software installation. (This step can be skipped if you prefer to copy over and run the config_from_server script created during the server installation in the ecce-admin directory) -- To register machines to run computational codes, please see the installation and compute resource registration manuals at http://ecce.pnl.gov/using/installguide.shtml -- Before running ECCE each user must source an environment setup script. For csh/tcsh users add this to ~/.cshrc: if ( -e /home/lindqvst/ecce-v6.4/apps/scripts/runtime_setup ) then source /home/lindqvst/ecce-v6.4/apps/scripts/runtime_setup endif For sh/bash users, add this to ~/.profile or ~/.bashrc: if [ -e /home/lindqvst/ecce-v6.4/apps/scripts/runtime_setup.sh ]; then . /home/lindqvst/ecce-v6.4/apps/scripts/runtime_setup.sh fi ***************************************************************
Next, configure:
./config_from_server
Enter the ECCE application software installation home directory: /home/lindqvst/ecce-v6.4/apps ECCE application software home directory is /home/lindqvst/ecce-v6.4/apps Is this correct? [yes] Adding data server URL for helium to siteconfig/DataServers Adding URL for online help to siteconfig/site_runtime Adding message server URL for helium to siteconfig/jndi.properti
And then do
echo 'export ECCE_HOME=/home/lindqvst/ecce-v6.4/apps' >> ~/.bashrc
echo 'export PATH=${ECCE_HOME}/scripts:${ECCE_HOME}/scripts/parsers:${PATH}' >> ~/.bashrc


Second client:
I set up a third user, installed ECCE as shown above for lindqvst, but instead of running config_from_server
I did:
/home/me/tmp/ecce-v6.4/ecce-v6.4/apps/scripts/config_with_server
Enter the full host name of the machine where the ECCE server is installed: helium ECCE server host name is helium Is this correct? [yes]
And then do
echo 'export ECCE_HOME=/home/me/ecce-v6.4/apps' >> ~/.bashrc
echo 'export PATH=${ECCE_HOME}/scripts:${ECCE_HOME}/scripts/parsers:${PATH}' >> ~/.bashrc
source ~/.bashrc


Tying it all together:

Start the server: As user verahill, start the server.
su verahill
/home/verahill/ecce-v6.4/server/ecce-admin/start_ecce_server
/home/verahill/ecce-v6.4/server/httpd/bin/apachectl start: httpd started [1] 13951 INFO BrokerService - ActiveMQ 5.1.0 JMS Message Broker (localhost) is starting INFO BrokerService - ActiveMQ JMS Message Broker (localhost, ID:helium-39358-1370944321599-0:0) started
ps a|grep 13951
13951 pts/3 S 0:00 grep -v -e ACTIVEMQ -e Loading -e AMQ -e Kaha -e help -e Transport
You should be able to autostart ecce using something along the lines of the following in your /etc/rc.local:
su verahill '/home/verahill/ecce-v6.4/server/ecce-admin/start_ecce_server' &
As a user, start ecce:
su lindqvst
/home/lindqvst/ecce-v6.4/apps/scripts/ecce
Create a password

Create a job
Then log out and log in as another user, e.g. me

su me
ecce
me is in reality called something else
Note that as user me you can't see any of the files in lindqvst's folder -- nor access them without inputting the correct (ECCE) username and password.

And again, note that there are alternative ways of setting this up -- you could have everyone log in as the same linux user, but still retain different ECCE identities. I think what I show here is more in line with how most people would want to use ECCE though.

Also, note that you can quite easily be a client on a different computer too -- the key lies in editing the apps/siteconfig/DataServers file.