Changes between Version 7 and Version 8 of SolarisInstallation

Show
Ignore:
Author:
T_oo (IP: 127.0.0.1)
Timestamp:
31.12.2009 12:40:14 (4 years ago)
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • SolarisInstallation

    v7 v8  
    1 [[TOC(heading=Content:)]] 
    2  
    3 = Coherence (Open)Solaris Installation Guide = 
     1{{{ 
     2#!html 
     3<h1 style="text-align: center; color: blue; font-size:3.0em">HowTo: Installation on Solaris</h1> 
     4}}} 
     5 
     6[[TOC(heading= ,inline)]] 
     7 
     8[[BR]] 
     9[[BR]] 
     10 
     11== Coherence (Open)Solaris Installation Guide == 
    412 
    513This document gives a brief overview on how to install Coherence on (Open)Solaris. 
    614 
    7 == Dependencies and Installation == 
     15=== Dependencies and Installation === 
     16 
    817There is a mimimum set of dependencies that Coherence needs to be able to run. Thanks to the built-in package manager this is very easy. Either use the Package Manager GUI tool in Gnome or a root shell like this: 
    918{{{ 
     19#!bash 
    1020  Mike@Sisyphos:~$ pkg install <package-name> 
    1121}}} 
    2030Variant 1: 
    2131{{{ 
     32#!bash 
    2233  Mike@Sisyphos:~$ su 
    2334  Mike@Sisyphos:~$ password: 
    3142Variant 2: 
    3243{{{ 
     44#!bash 
    3345  Mike@Sisyphos:/$ cd ~ 
    3446  Mike@Sisyphos:~$ mkdir Development 
    4355Both variants will leave you with an executable in /usr/bin which can be run from any location by just typing 
    4456{{{ 
     57#!bash 
    4558  Mike@Sisyphos:~$ coherence 
    4659}}} 
    61741) Create user and group for the server (we assume upnp/nas here), if you don't want to reuse an existing user. The group should be allowed to access your media files. If you have setup your box as a file server then you probably have already a dedicated group for accessing it, which would be a good candidate. If not do 
    6275{{{ 
     76#!bash 
    6377  Mike@Sisyphos:~$ groupadd nas 
    6478  Mike@Sisyphos:~$ useradd -g nas -d /var/coherence upnp 
    67812) Create a private folder for Coherence. There we store the config file, the log file and a lock file which prevents more than one instance to start (if started via start script). 
    6882{{{ 
     83#!bash 
    6984  Mike@Sisyphos:~$ mkdir /var/coherence 
    7085  Mike@Sisyphos:~$ chown upnp:nas /var/coherence 
    74893) Copy the [[attachment:coherence.conf config file]] into that folder and give proper permissions. 
    7590{{{ 
     91#!bash 
    7692  Mike@Sisyphos:~$ cd /var/coherence 
    7793  Mike@Sisyphos:/var/coherence$ chown upnp:nas coherence.conf 
    8096 
    81974) Copy the socalled [[attachment:coherence.sh method script]] (a script to control the server) to /lib/svc/method/coherence (no extension) and set permissions. This file is used by the Service Management Facility (SMF) to control the service. 
    82 {{{ 
     98 
     99{{{ 
     100#!bash 
    83101  Mike@Sisyphos:~$ chmod 555 /lib/svc/method/coherence 
    84102}}} 
    87105 
    881066) Import the service description to add the new service. 
    89 {{{ 
     107 
     108{{{ 
     109#!bash 
    90110  Mike@Sisyphos:~$ svccfg import /var/svc/manifest/application/coherence.xml 
    91111}}} 
    92112 
    93113The service is now ready and only needs to be started. Check that it is really there: 
    94 {{{ 
     114 
     115{{{ 
     116#!bash 
    95117  Mike@Sisyphos:~$ svcs coherence 
    96118  STATE          STIME    FMRI 
    99121 
    100122Enable the service and you are done. 
    101 {{{ 
     123 
     124{{{ 
     125#!bash 
    102126  Mike@Sisyphos:~$ svcadmin enable coherence 
    103127  Mike@Sisyphos:~$ svcs coherence 
    109133 
    110134== Troubleshooting == 
     135 
    111136In case something goes wrong you have several means to look for a reason. 
    112137 
    1131381) If your service doesn't want to go online and stays offline or in maintenance mode check if all dependencies (of the service, not coherence itself) are met: 
    114 {{{ 
     139 
     140{{{ 
     141#!bash 
    115142  Mike@Sisyphos:~$ svcs -l coherence 
    116143  fmri         svc:/application/upnp/coherence:default 
    128155  dependency   require_all/none svc:/system/filesystem/local:default (online) 
    129156}}} 
     157 
    130158Spend special attention to the dependencies. All four must be "online". Use the next command to find other info (only useful if the service makes trouble). 
    131 {{{ 
     159 
     160{{{ 
     161#!bash 
    132162  Mike@Sisyphos:~$ svcs -x coherence 
    133163  svc:/application/upnp/coherence:default (Coherence UPNP/DLNA media server) 
    142172 
    143173A good pool of information is also the set of properties assigned to the service. You get them via: 
    144 {{{ 
     174 
     175{{{ 
     176#!bash 
    145177  Mike@Sisyphos:~$ svcprop coherence 
    146178  coherence/config astring /var/coherence/coherence.conf 
    211243 
    2122443) If the service enters the maintenance state and you receive a "could not set context for method" error in the service log, make sure the service account has a home directory set.  Note the attempt to change directories. 
    213 {{{ 
     245 
     246{{{ 
     247#!bash 
    214248  [ Apr 28 21:55:26 Executing start method ("/lib/svc/method/coherence start"). ] 
    215249  svc.startd could not set context for method: chdir: No such file or directory 
    218252 
    219253The solution is to add a sensible home directory to the service account: 
    220 {{{ 
     254 
     255{{{ 
     256#!bash 
    221257  [jmccune@rain ~]$ pfexec usermod -d /var/coherence upnp 
    222258}}}