Wednesday, December 3, 2008

Synergy 6.5 License server installation

Here is the step by step instructions on setting up the Synergy license server (11.5).
Based on Telelogic Lifecycle Solutions Licensing Guide.
As root:
- Create user flexnet.
[root@licserv ~]# adduser flexnet
[root@licserv ~]# passwd flexnet
As flexnet:
- Copy licence archive to Linux machine.
- [root@licserv ~]# mkdir -p /opt/flexnet/linux
- [root@licserv ~]# chown -R flexnet:flexnet /opt/flexnet/linux
- Unpack the flex.tar file from …/license_server/linux to the newly created installation directory /opt/flexnet/linux:
[flexnet@licserv linux]$ tar -xvf /home/flexnet/linux/flex.tar
You should get :
[flexnet@licserv linux]$ pwd
/opt/flexnet/linux
[flexnet@
licserv linux]$ ll
total 3240
-rwxr-xr-x 1 flexnet flexnet 1021668 Apr 12 2008 lmgrd
-rwxr-xr-x 1 flexnet flexnet 1011900 Nov 27 2007 lmutil
-rwxr-xr-x 1 flexnet flexnet 1263712 Sep 5 10:44 telelogic

- Save or copy the FLEXnet license file you received from Telelogic into a text file called license.dat:

[flexnet@licserv flexnet]$ cp -pr license.dat.txt_validtilldec08end /opt/flexnet/license.dat

- Find out your FlexLM hostid:
[flexnet@licserv flexnet]$ /opt/flexnet/linux/lmutil lmhostid
lmutil - Copyright (c) 1989-2007 Macrovision Europe Ltd. and/or Macrovision Corporation. All Rights Reserved.
The FLEXnet host ID of this machine is "001b786ed876"

- Add the following line at the very begining of the licence.dat file:

SERVER licserv 001b786ed876 19353

where licserv is the machine where license server will be running, 001b786ed876 is the hostid you discovered in the previous step, 19353 is the port to be used by the license server.

- Set up the license file location to the LM_LICENSE_FILE variable:

[flexnet@licserv flexnet]$ export LM_LICENSE_FILE=/opt/flexnet/license.dat

- Add the LM_LICENSE_FILE set to the flexnet ini file (.bashrc):

export LM_LICENSE_FILE=/opt/flexnet/license.dat

- You may also want to create a link
/usr/local/flexlm/licenses/license.dat -> /opt/flexnet/license.dat
'cause flexlm is looking for the license.dat by default in the /usr/loca/flexlm/license.
- Change directory to the installation path:
[flexnet@licserv flexnet]$ cd /opt/flexnet/linux
- Start the license server:
[flexnet@licserv flexnet]$ /opt/flexnet/linux/lmgrd -local -c license.dat -l license.log
- Make sure it is running:
[flexnet@licserv flexnet]$ /opt/flexnet/linux/lmutil lmstat -c license.dat
You should get the following:
[flexnet@licserv ~]$ /opt/flexnet/linux/lmutil lmstat -c license.dat
lmutil - Copyright (c) 1989-2007 Macrovision Europe Ltd. and/or Macrovision Corporation. All Rights Reserved.
Flexible License Manager status on Sun 11/30/2008 09:25
License server status: 19353@licserv
License file(s) on
licserv: /opt/flexnet/license.dat:
licserv: license server UP (MASTER) v11.5
Vendor daemon status (on licserv):
telelogic: UP v11.5
This completes the Synergy license server installation.
Make sure you refer to this license server by inspecting the following file on you: Synergy engine installations:
/usr/local/ccm/etc/license_data.txt
It should have the following content:
$ cat /usr/local/ccm/etc/license_data.txt
19353@
licserv

Make sure to add the server start command to the machine boot procedure.
Remember, the license daemon has to run with the flexnet user, not as ccm_root or root.

Tuesday, November 25, 2008

Synergy troubleshooting: Linux Java GUI client does not start

Make sure to use esd for identification.
On Synergy server machine file $CCM_HOME/esd/ccm.ini should have the lines:
[Options]
engine_daemon = TRUE
This will make it work even if there is no rsh-server daemon running on server.
(Linux RHEL 5.* do not have rsh installed by default as it is not secure).

Monday, November 3, 2008

How To: start / check / stop flex license for Telelogic products

Start
/opt/flexnet/telelogic/linux/lmgrd -local -c /opt/flexnet/telelogic/license.dat -log /opt/flexnet/telelogic/license.log
Check
/opt/flexnet/telelogic/linux/lmutil lmstat -c /opt/flexnet/telelogic/license.dat
Stop
/opt/flexnet/telelogic/linux/lmutil lmdown -c /opt/flexnet/telelogic/license.dat

Tuesday, October 28, 2008

Monday, April 14, 2008

Linux tips: see machine HW config

Virtual directory /proc holds virtual files :
version
mounts
modules
meminfo
filesystems
driver
devices
uptime
stat
scsi
etc...
... and virtual dirs per all running processes.

To see the values just "cut" the corresponding file, e.g.

$ cat /proc/version
Linux version 2.4.21-27.ELsmp (bhcompile@bugs.build.redhat.com) (gcc version 3.2.3 20030502 (Red Hat Linux 3.2.3-47)) #1 SMP Wed Dec 1 21:59:02 EST 2004
$ cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 15
model : 4
model name : Intel(R) Xeon(TM) MP CPU 3.16GHz
stepping : 1
cpu MHz : 3169.446
cache size : 1024 KB
physical id : 0
siblings : 2
runqueue : 0
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 5
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm lm
bogomips : 6317.67
...

$ cat /proc/meminfo
total: used: free: shared: buffers: cached:
Mem: 8396136448 8349917184 46219264 0 98226176 6759067648
Swap: 8587182080 38506496 8548675584
MemTotal: 8199352 kB
MemFree: 45136 kB
MemShared: 0 kB
...

Monday, February 18, 2008

Q: Is it possible have two Informix dbs under same name on a single server (in different locations)?

A: No, it is not.
No matter how we call it - (mydb or /data/synergydb/mydb) it will all be the same.

Trouble starting Synergy session

Warning provided to user when starting synergy client session:
Duplicate user name: 'john'
Warning: Syntax error(s) in attribute 'users' of base/model/base/1.
Starting in multiple server mode.
Set the environment variable CCM_ADDR to serv:32920:123.321.231.213 to send commands to this server.
SYNERGY/CM address is serv:32920:
123.321.231.213.

Solution: run "ccm users" and remove the extra occurence of the problematic user ('john').

Tuesday, February 12, 2008

How To Fix: recreate accidentally removed prep project (original project version exists, successor working project exists) (work)

1. Create new project for Integration Testing purpose.
To do this: copy project from existing Working Project (myproj#john-2.00.00:project:1). Make sure new project has the same release as the working project and the correct version name and purpose.
The project is created but the status is working. We will change this later.
2. List all three projects to see their full object names:
$ ccm query -type project -name myproj -f "%objectname"
1)
myproj#1.00.00:project:1
2)
myproj#2.00.00:project:1
3)
myproj#john-2.00.00:project:1

3. Now fix the relations of the projects. We shall get the project 2.00.00 as a successor of 1.00.00, and then 2.00.00-john as a successor of 2.00.00.
First relate the projects as needed, then remove the old links:
$ ccm relate -n successor -f myproj#1.00.00:project:1 -t myproj#2.00.00:project:1
'successor' relationship created from '
myproj#1.00.00:project:1' to 'myproj#2.00.00:project:1'
$ ccm relate -n successor -f myproj#2.00.00:project:1 -t myproj#john-2.00.00:project:1
'successor' relationship created from '
myproj#2.00.00:project:1' to 'myproj#john-2.00.00:project:1'
$ ccm unrelate -n successor -f myproj#john-2.00.00:project:1 -t myproj#2.00.00:project:1
'successor' relationship deleted from '
myproj#john-2.00.00:project:1' to 'myproj#2.00.00:project:1'
$ ccm unrelate -n successor -f
myproj#1.00.00:project:1 -t myproj#john-2.00.00:project:1
'successor' relationship deleted from '
myproj#1.00.00:project:1' to 'myproj#john-2.00.00:project:1'

4. Check the Integration Testing project status:
$ ccm attr -s status myproj#2.00.00:project:1
working
It should be prep, not working. (Working was inherited from the original working project it was copied from).
5. Change the status attribute:
Note that to change the status we should clear the 'Make Copies Modifiable' property of the project work area as suggested:
$ ccm attr -m status -v prep myproj#2.00.00:project:1
Check in to prep state not permitted for projects with 'Make Copies Modifiable' work area setting.
Attribute 'status' could not be modified on object '
myproj#2.00.00:project:1'

$ ccm attr -m status -v prep
myproj#2.00.00:project:1
Status has been now changed to prep, no output is produced by command ccm attr.
~~~ End of story ~~~

Sunday, February 10, 2008

Q: Unbounded file-versions are related to project? [ ref:00D2nW4.500224kaq:ref ]

Q: We've discovered a number of files that are not bounded (as reported by finduse command), yet they are marked as belonging to a project. This looks like inconsistency. Is such a situation normal or should we worry about this state?

Here is an example:

ccm finduse -name con_chk.o
con_chk.o#1 integrate john relocatable_obj MYAPP 1 1871
Object is not used in scope.

A: This is the project it was originally created in. There is no other relation. For a file that is used in a project, you will get a list of locations it is at.

Concept of Synergy collapse command is problematic

The collapse command enables you to delete object versions from the database and adjust history links. You use this command when the object you delete has successors. All collapsed objects are removed from the database. If you collapse a project, its members are unused and the project is removed.

Note Before you check in a working version to a non-modifiable state, be sure to collapse the earlier checkpointed versions you do not want in your database; otherwise, you will only be able to collapse the checkpointed versions while working in the ccm_admin role.

The immediate successor of a checkpointed version must be writable to collapse the predecessor. For example, assume you have an object named bufcolor.c with a version history of: 1 --> 2 --> 3 --> 4, where version 1 is in the integrate state, versions 2 and 3 are checkpointed versions, and version 4 is in the working state. If you want to collapse version 3, you can do so because version 4 is in the working state. If version 4 was in the integrate state, you would not be able to collapse version 3.

You can perform a collapse command on a specified object except when the object has either of the following characteristics:

• the object is non-modifiable and you are not working in the ccm_admin role

• the object is a member of a project

Note Collapsing a version that has multiple successors and predecessors links each of the version’s predecessors with each of the version’s successors. Collapsing a version that has no predecessors and multiple successors unlinks the successors’ histories.

All users can collapse objects to which they have write access.

Users working in the ccm_admin role can collapse non-modifiable objects as well.

As a matter of fact this command kind of breaks the very idea of the Synergy/CM - Task-Based CM:

Synergy/CM defines a release as a collection of tasks. It is content of this collection (and not the content of the code line) that defines what goes into release and what does not.

When an object is collapsed, this is done outside of the tasks. The operation does not require any task to perform. Thus the release content is changed without any trace left.

Change propagation is task-based as well. So if at any time we would want to propagate the specific change (task) to another version, we may propagate the incomplete change - without the collapsed object and without knowing something is missing.

And if for some reason we'll ever look at the release tasks, we'll see some empty tasks (those that held the only file that was collapsed). We'll then wonder what's the point of having an empty tasks to change the code.

Hence it does look like the collapse operation is only acceptable for non-source files, e.g. shared build products.

Thursday, February 7, 2008

Synergy and CBD (citation)

by Greg Fischer
We are doing component development where I work, and have been for a few years.

To answer some of your questions:
Synergy deals with components very well, if you set it up correctly in the very beginning. Otherwise yes, there will be alot of overhead. (I'll come back to this).

You can easily reach a point where you have too many components. But, it is manageable again, if you set it up correctly to start. Yes, you will have a different release for each component project, and that would be your biggest headache, as you would have to determine if the releases change together at major milestones or separately.

You basically have three ways to implement this. Let's say Application A requires components B and C. You need the build products from B and C to build A. So, within project A, you can:

1> Have a directory named "Components" for example, with maybe subdirectories for B and C, and your reconfigure properties will include task folders to provide you with the latest B and C products and any other B and C files you need.

2> You have an absolute project which contains all possible required components for everybody, and this absolute project is then a subproject for Project A and any other projects that need it. On Windows, your users would then check out the Components common project, along with Project A, then map a network drive (pick a standard - everybody uses Q:) to map the top-level directory of your workarea for the Components project. Then any reference to files needed by Project A would be Q:\components\componentB\B1.dll, etc.

3> The components directory under Project A "uses" integrate projects as part of the baseline for the dependent components. This has the added advantage of having the build manager be able to NOT select the latest baseline for a component in their baseline, or having the developers go back a baseline (or two or X number) to help in bug fixes.

We started doing 1> here, but that gets messy, because Project A is now collecting tasks for Components B and C, and the number of tasks in the baseline just gets bigger and bigger and bigger (and quickly).

I've done 2> in my career, with Synergy, with great success. The one problem with 2> is that people will tend to check out the *entire* Components absolute project, thereby getting components A through Z, when all they need is B and C.

We're just in the process of implementing 3> now, and so far, so good. Synergy treats "integrate" projects special, so you can have it "relative" to many other projects, but because it is in the "integrate" state, Synergy allows this, AND and Update won't bother with those - they are static.

So the initial setup of your projects will be key, but Synergy can definitely handle it.
http://www.cmcrossroads.com/component/option,com_fireboard/Itemid,558/func,view/id,83799/catid,24/
Greg Fischer

How To Fix: Synergy project is locked

Sometimes when the client session terminates in the middle of the operation (e.g. reconfigure), the project is locked and is not accessible from the new GUI session.
To solve this: locate all the user sessions via ccm monitor and kill them.

How To: list project reconfigure folders

Here is the way to list all the reconfigure folders for a specific project:
ccm reconfigure_properties -show folders <project properties>
For example:
$ ccm reconfigure_properties -show folders PROD#verb8.18.19:project:1
1) Folder 24630: All Completed Tasks for Release ABC_3.07
2) Folder 26646: All Completed Tasks for Release CBGTR_6.01
3) Folder 27144: All Completed Tasks for Release OIUY_6.04
4) Folder 27527: All Completed Tasks for Release ZZZ_7.10
5) Folder 28060: All Completed Tasks for Release TYU_6.05

Wednesday, February 6, 2008

Synergy numbers

Telelogic support suggest projects should not have more than 2K objects for performance sake.

There used to be a reference to the source of this suggestion somewhere but no more.

Monday, January 14, 2008

ClearCase and eclipse

It is been known that CC working with Eclipse require (3 times) more licenses than pure CC for the same number of users.
As it comes out (hint from Miron), this may be due to the fact that Eclipse normally does not refresh its GUI when anything happens on the FS or in its current team provider, unless explicitly required to do so (by F5). This usually causes a lot of confusion and failed operations sometimes. So the guess is that Rational integration of the CC with Eclipse forces the Eclipse refresh every so often to keep it in sync with the repository. Thus it connects to CC repository even if the user did not request to do so, and by issuing this request it uses up a license (that it otherwise would not use).