VERSION: 5.0
UNIX News for MATLAB
--------------------
Notation: $MATLAB is the MATLAB root directory path
--------
File: README.news50
----
0. Table of Contents
-----------------
1. Important MATLAB 5 UNIX level commands
2. -help option on MATLAB 5 UNIX level commands
3. Online documentation overview
3.1 At the UNIX command prompt
3.2 At the MATLAB command prompt
5. 'ldd' utility for showing shared library information
6. Help
Appendix: UNIX Setup
--------
1. Important MATLAB 5 UNIX level commands
--------------------------------------
In $MATLAB:
matlabdoc - Script to view online documentation.
(Also accessible from $MATLAB/bin.)
install_matlab - Script to start an installation.
In $MATLAB/bin:
matlab - Script to start MATLAB.
mex - Script to build a MEX file.
in $MATLAB/etc:
lmstart - Script to start/restart the FLEXlm
license manager.
lmdown - Script to just take down the FLEXlm
license manager.
lmstat - Script to show the status of the
FLEXlm license manager.
Links to 'matlab', 'mex', and 'matlabdoc' can be put in
a single access directory during installation.
2. -help option on MATLAB 5 UNIX level commands
--------------------------------------------
ALL MATLAB UNIX level commands like 'install_matlab', 'matlab',
'mex', 'matlabdoc', and the license manager scripts respond to
'-help' option. Detailed usage information is provided in all
cases.
3. Online documentation overview
-----------------------------
3.1 At the UNIX command prompt
--------------------------
There is now a single point of entry for all MATLAB
documentation at the UNIX prompt. The command to execute is:
Directly from the CD-ROM After installation in $MATLAB
-----------------------_ -----------------------------
doc* matlabdoc
* Use DOC* on HP Systems
Usage is:
command -help - Usage.
command - View html documentation.
command -ascii - View ASCII README files.
command -man - View manual pages.
Notes: 1. After installation a link to 'matlabdoc' also exists
in $MATLAB/bin.
2. A link to 'matlabdoc' is installed in the access
directory during installation.
3. The MATLAB Help Desk is currently not available
directly from the CD-ROM for UNIX.
3.2 At the MATLAB command prompt
----------------------------
At the MATLAB command prompt the following commands are
available:
help - Function help, display help at command line
helpwin - Function help, separate window for naviagation
helpdesk - MATLAB help Desk: comprehensive hypertext
documentation and troubleshooting
4. 'ldd' utility for showing shared library information
----------------------------------------------------
The script utility is located in $MATLAB/bin.
ldd -help - Usage.
ldd file - When applied to an executable file or a
MEX-file it will display information about
the shared libraries required for
execution.
5. Help
----
If you have questions or want to report problems please contact:
The MathWorks, Inc. Technical Support:
Email: support@mathworks.com
Phone: 508-647-7000
FAX: 508-647-7201
========================================================================
Appendix: UNIX Setup
========================================================================
0. Table of Contents
-----------------
1. Critical Operating System patch requirements
1.1 HP-UX 10.x 'expr' command bug
2. Operating system version table for MATLAB 5 builds
3. New area required for installation
4. Making MATLAB 5 and MATLAB 4 coexist
5. License manager issues
5.1 Overview
5.2 FLEXlm now supported on Linux
5.3 'lmhostid' changes
5.4 MATLAB vendor daemon (MLM) configuration changes
5.5 License file formats
5.6 port@host support
5.7 Can switch debug logfile automatically
5.8 'lmboot' supports merged license files automatically
5.9 -e option for listing debug logfile
5.10 -k option to check whether license file tcp ports are free
5.11 Minor bugs in the FLEXlm 5.0a distribution
5.12 Globetrotter Software, Inc. Home Page
6. Comments about operating system and tool requirements
6.1 Hewlett Packard (HP) 9000 PA_RISC support
6.1.1 Series 800 support
6.1.2 Patching MATLAB 4.2c for Series 800 support
7. Comments about 'Installation Guide for UNIX' document
7.1 Getting to an online version of this document
7.2 Errata: Boot links are now called lmboot_TMW5 and
lmdown_TMW5
7.3 Errata: Default FLEXlm debug logfile is
/usr/tmp/lm_TMW5.log
7.4 Errata: $MATLAB/toolbox/local directory holds the
local environment files
7.5 Errata: Manual pages no longer installed in system
level directory
7.6 'New Style' license format used in document, but
'Old Style' shipped with MATLAB 5.0
8. Miscellaneous
8.1 Manual pages no longer installed in system level directory
8.2 SunOS 5.4 linker (ld) bug patch
1. Critical Operating System patch requirements
--------------------------------------------
1.1 HP-UX 10.x 'expr' command bug
-----------------------------
This bug will prevent you from installing and running MATLAB on
HP-UX 10.0, 10.01, 10.10, and 10.20 systems.
----------------------------------------------------------------
CD-ROM: A file containing a patch is provided at the top level.
When the CD-ROM is mounted on a HP system the filename
is:
HPUX10.PCH;1
On non-HP systems the filename is:
hpux10.pch
Detar this file as follows:
(cd /tmp; tar -xf "/cdrom/HPUX10.PCH;1") (HP systems)
(cd /tmp; tar -xf /cdrom/hpux10.pch) (non-HP systems)
What is created is the directory,
/tmp/hpux10.pch
All of this will be done automatically if you attempt
to install MATLAB from the CD-ROM on a HP 9000 PA-RISC
system and the problem is detected.
----------------------------------------------------------------
----------------------------------------------------------------
FTP: The file, hpux10.pch, is included in the boot.ftp tar
file. Run in $MATLAB,
tar -xvf boot.ftp
Then,
(cd /tmp; tar -xf $MATLAB/hpux10.pch)
What is created is the directory,
/tmp/hpux10.pch
----------------------------------------------------------------
See the README file in this directory for installation
instructions. This README file is repeated below.
AFTERWARD: It is strongly recommended that you simply use step
2. in the README. Our attempts at using the HP patch
process for this patch can only be described as
frustrating.
====================================================================
| Topic: 'expr' bug in HP-UX 10.x
| By: The MathWorks, Inc.
| Date(s): May 1996 - 29
| Dec 1996 - 16
|
| 1. There is a bug in the /usr/bin/expr command in HP-UX 10.x.
| There is an official patch for HP-UX 10.0 and 10.01. However,
| it is still broken in HP-UX 10.10, and 10.20!
|
| 2. Here is the easiest way to fix the problem for any HP-UX 10.x
| system.
|
| . Become superuser in this directory.
|
| . Check that the owner and group of the patched 'expr'
| command in this directory is 'bin'.
|
| Fix this if this is not true using the commands:
|
| chown bin expr
| chgrp bin expr
|
| . Copy the 'expr' command to /usr/bin
|
| cp -p expr /usr/bin/expr
|
| 3. For HP-UX 10.0 and 10.01 customers who want to use the standard
| HP patch install process, see the installation instructions in
| the patch, 'PHCO_6194', in this directory.
|
| There is currently no official patch for HP-UX 10.10. So use
| step 2. above for this case. Do the same for 10.20.
|
| 4. To test the installation run the command at the shell prompt:
|
| /usr/bin/expr "a" : '\(A\)'
|
| It should return the empty string NOT a '0'.
====================================================================
2. Operating system version table for MATLAB 5 builds
--------------------------------------------------
Platform OS version
-------- ----------
Sun Sparc (sun4) SunOS 4.1.4
Sun Sparc (sol2) Solaris 2.5
HP 9000 PA-RISC (hp700) HP-UX 10.01
DEC Alpha (alpha) Digital UNIX 4.0A
IBM RS/6000 (ibm_rs) AIX 4.1
Silicon Graphics (sgi) IRIX 6.2
Silicon Graphics (sgi64) IRIX 6.2
Linux (lnx86) Linux 2.0.18
A check is done of the OS version at the start of scripts like
'install', 'install_matlab', 'matlab', and 'mex'. It will print
a message if you are running an older version then what MATLAB 5
was built with. If the version is too old it will be considered
an error and you are prompted to quit.
3. New area required for installation
----------------------------------
Please install 5.0 in a new, empty area. This will start you off
with a clean update tree. You may install future MATLAB 5 updates
over this area. DO NOT install over an existing MATLAB 5 alpha or
beta copy.
BE SURE that MATLAB 4 and MATLAB 5 are installed in DIFFERENT
areas!
4. Making MATLAB 5 and MATLAB 4 coexist
------------------------------------
For information about running MATLAB 5.0 and MATLAB 4.2c on the
same machine, access on the Web The MathWorks home page
(http://www.mathworks.com). Look for installation information under
the TechNotes/FAQ link under the TechSupportInfo link.
We want users to able to use MATLAB 5 and MATLAB 4 independently
but have them coexist conveniently on the same system.
We will be providing a new license file that will work with
MATLAB 5 and MATLAB 4. Start the license manager daemons in
MATLAB 5.
cd $MATLAB/etc
./lmstart
Make a copy of the MATLAB 5 license file in MATLAB 4.
cp $MATLAB/etc/license.dat $MATLAB4/etc/license.dat
MATLAB 5 and MATLAB 4 are now ready to use. Note that the DAEMON
line does not need to be changed when you copy the license file to
MATLAB 4 because it is used ONLY when the license manager is
started.
We now review the critical files and links in MATLAB 5 and MATLAB 4
and show how they are related.
MATLAB 5 MATLAB 4
-------- --------
matlab <-----> matlab
.matlab5rc.sh <-----> .matlabrc.sh
pathdef.m
mex <-----> cmex,fmex
mexopts.sh <-----> .mexrc.sh
gccopts.sh
cxxopts.sh
matlabdoc
lmstart <-----> lmstart
/usr/tmp/lm_TMW5.* <-----> /usr/tmp/lm_TMW4.*
/usr/tmp/lockMLM5 <-----> /usr/tmp/lockMLM4
/etc/lmboot_TMW5 <-----> /etc/lmboot
/etc/lmdown_TMW5 <-----> /etc/lmdown
lmdown <-----> lmdown
lmstat <-----> lmstat
lm* (other utilities) <-----> lm* (other utilities)
lmopts.sh
man pages (MATLAB) <-----> man pages (system)
For a user of MATLAB, the only potential conflict is the
script, 'matlab'. One of the names will have to be different.
The suggested solution is to use a common access directory
for links to the MATLAB 4 and MATLAB 5 utilities and have the
the change reflected there. You then add the access directory
to your UNIX search path at login. So if you need to install
both MATLAB 4 and MATLAB 5 install MATLAB 4 first. Then the
MATLAB 5 installer will find the MATLAB 4 links and create
and/or fix the links so they look like:
matlab -> $MATLAB/bin/matlab
mex -> $MATLAB/bin/mex
matlabdoc -> $MATLAB/bin/matlabdoc
matlab4 -> $MATLAB4/bin/matlab
cmex -> $MATLAB4/bin/cmex
fmex -> $MATLAB4/bin/fmex
5. License manager issues
----------------------
5.1 Overview
--------
This version of MATLAB uses the FLEXlm 5.0a distribution
with 5.0b lmgrd daemons.
The license manager script interface to FLEXlm provided
by The MathWorks is now built around a configurable
options file called,
lmopts.sh.
Users now can choose between 3 interfaces for FLEXlm
administration.
1) MathWorks Script mode - This provides a script
interface that goes beyond standard FLEXlm utilities.
It provides a robust, uniform look and feel that is
the same across all our UNIX platforms. It is the
default.
2) Globetrotter Script mode - This provides a script
interface to just the bare FLEXlm utilities.
Set LM_UTIL_MODE=0 in lmopts.sh.
3) Roll your own mode - This is for experienced FLEXlm
users who have systems in place to handle FLEXlm.
Simply take the license.dat file and the FLEXlm
utilities in $MATLAB/etc/$ARCH for platform ARCH.
No MATLAB provided scripts are used.
To start up the license manager,
cd $MATLAB/etc
lmstart
To take down the license manager,
cd $MATLAB/etc
lmdown
We have assumed here that you have properly configured
your lmopts.sh file.
IMPORTANT: Do not start up FLEXlm as superuser for
security reasons. Globetrotter Software,
the makers of FLEXlm, and The MathWorks,
encourage you to follow this advice.
5.2 FLEXlm now supported on Linux
-----------------------------
FLEXlm is now supported on Linux. Customers who want to run
both MATLAB 4.2c and MATLAB 5 on Linux will need TWO license
files. Note that MATLAB 4.2c licensing does not use daemons
while MATLAB 5 does. This means that to run MATLAB 4.2c on
Linux requires ONLY that you place a correct license file in
$MATLAB4/etc/license.dat.
5.3 'lmhostid' changes
------------------
. hp700 - The ID module is no longer supported.
Globetrotter recommends using the 32-bit number
obtained by executing at the UNIX prompt,
echo `uname -i` 16o p | dc
This is NOW the default number returned by 'lmhostid'.
The ethernet number is still supported, but not
recommended, since it is insecure.
5.4 MATLAB vendor daemon (MLM) configuration changes
------------------------------------------------
MLM is configured to no longer use all FEATURE lines.
In MATLAB 4.2c, the FLEXlm vendor daemon was configured on
each architecture to use all copies of the 'same' feature line.
In MATLAB 5 this is shut off as recommended by Globetrotter,
Software. This means that ONLY the first FEATURE line for a
given feature will be processed by the vendor daemon.
For example, in MATLAB 4.2c the following feature lines,
FEATURE MATLAB MLM 1.000 1-jan-0 4 ...
FEATURE MATLAB MLM 1.000 1-jan-0 5 ... 12345678
would make 9 (the sum of 4 an 5) licenses available for MATLAB.
The MATLAB 5 vendor daemon will only allow 4. You will NOW
require lines of the form,
FEATURE MATLAB MLM 1.000 1-jan-0 4 ...
INCREMENT MATLAB MLM 1.000 1-jan-0 5 ... HOSTID=12345678
to have a total of 9 licenses for MATLAB. The new passcodes
will enforce this requirement.
5.5 License file formats
--------------------
There are two formats of license files, which will be referred to
'Old Style', and 'New Style'. For MATLAB 5.0 we will be using
'Old Style' so that they will work with MATLAB 4. We will
move to the 'New Style' in future releases.
Changes from MATLAB 4:
. The version number (field 4) is now 5.
. Additional lines with the same feature name are handled
by INCREMENT lines.
Old Style: (example)
---------
FEATURE MATLAB MLM 5 01-jan-1997 1 0123456789ABCDEFGHIJ ""
FEATURE SIMULINK MLM 5 01-jan-1997 1 0123456789ABCDEFGHIJ ""
INCREMENT SIMULINK MLM 5 01-jan-1997 2 0123456789ABCDEFGHIJ "" 12345678
New Style: (example)
---------
FEATURE MATLAB MLM 5 01-jan-1997 1 0123456789ABCDEFGHIJ
FEATURE SIMULINK MLM 5 01-jan-1997 1 0123456789ABCDEFGHIJ
INCREMENT SIMULINK MLM 5 01-jan-1997 2 0123456789ABCDEFGHIJ \
HOSTID=12345678
Some changes in going from 'Old Style' to 'New Style'.
. A '\' at the end of a line is a continuation character.
. All fields after the passcode (20 digit hexdecimal number)
use keywords.
5.6 port@host support
-----------------
There is complete support for port@host in MATLAB 5. This
means that whenever a license file is referred to as part
of a '-c' argument for example and it makes sense you can
substitute port@host. Port and host are taken from the
SERVER line in the license.dat file.
5.7 Can automatically switch debug logfile
--------------------------------------
Both MathWorks and Globetrotter script mode automatically
start up the license manager in such a way that the debug
log output is piped to a separate process. This will allow
the logfile to be switched without affecting the proper
operation of the license manager. Simply use the 'mv'
command to rename the file and a new copy of the current
file will be created by the process.
5.8 Merged license files automatically supported
--------------------------------------------
In MATLAB 4 if you merged license files you had to modify
the lmboot script and tell it about the other daemons.
This is no longer necessary.
5.9 -e option for listing debug logfile
-----------------------------------
Both the 'lmstart' and 'lmboot' scripts take the option
'-e nlines' which list the last nlines of the debug
logfile(s). The default is the last 10 lines.
5.10 -k option to check whether license file tcp ports are free
------------------------------------------------------------
Both the 'lmstart' and 'lmboot' scripts take the option
'-k' which checks whether the tcp ports on the SERVER lines
in your license file are free on the local host.
5.11 Minor bugs in FLEXlm 5.0a distribution
--------------------------------------
The following 3 problems were noticed during development.
Some are worked around in MathWorks script mode.
. If both the hostname and hostid are invalid you may get:
------------------------------------------------------------------------
license manager: can't initialize: No SERVER lines in license file ...
------------------------------------------------------------------------
. If you don't have proper permission on your /dev/lan0 device
on hp700 systems you may get:
------------------------------------------------------------------------
lmhostid: Cannot find ethernet device (-29,175:2) No such file or ...
------------------------------------------------------------------------
. The lmver utility returns a version of XXX like:
------------------------------------------------------------------------
lmver - Copyright (C) 1989-1994 Globetrotter Software, Inc.
FLEXlm XXX (lmgr.a), Copyright (C) 1988-1996 Globetrotter Software, Inc.
------------------------------------------------------------------------
5.12 Globetrotter Software, Inc. Home Page
-------------------------------------
The WEB address for Globetrotter Software's home page is,
http://www.globetrotter.com
You may contact The MathWorks for help regarding FLEXlm and
MATLAB. Enquiries about other products like FLEXadmin, etc.
should be directed to Globetrotter Software.
Under On-Line Docs you will find the useful document,
'FLEXlm End User Manual'.
6. Comments about operating system and tool requirements
-----------------------------------------------------
6.1 Hewlett Packard (HP) 9000 PA_RISC support
-----------------------------------------
6.1.1 Series 800 support
6.1.2 Patching MATLAB 4.2c for Series 800 support
6.1.1 Series 800 support
------------------
There is support now for 'newer' HP 9000 series 800
systems. It must be a PA-RISC 1.1 or higher architecture.
The MATLAB architecture name is 'hp700' for both the
series 700 and 800 systems. Also the MATLAB MEX-file
extension for both series is '.mexhp7'.
6.1.2 Patching MATLAB 4.2c for Series 800 support
-------------------------------------------
For installation you should temporarily make a fix to
the file /bin/hp9000s700 and then run the install. Then
undo this fix and patch some files in the MATLAB
distribution.
a. Temporarily fixing/creating the /bin/hp9000s700 file
----------------------------------------------------
As superuser fix or create the file
/bin/hp9000s700
such that it looks like:
-----------------------------------------------------------------
# @(#) $Revision: 1.4 $
exit 0
-----------------------------------------------------------------
The lines, '--------------------...', are NOT part of
the file. There are THREE(3) lines in this file. The
first line MUST be blank and the last MUST be 'exit 0'.
Be sure that the file is executable.
chmod 755 /bin/hp9000s700
b. Patching files
--------------
After installation you need to add the test for
HP 9000/800 in the arch script. This is embedded in
several files.
Here is the MATLAB 4.2c Bourne Shell code fragment
for determining the arch on the HP. The code that
needs to be added has '->' in the left hand column.
Do not include the '->'!
-----------------------------------------------------------------
HP-UX) # hp300 and hp700
if [ -f /bin/hp9000s300 ]; then
(/bin/hp9000s300) > /dev/null 2>&1
if [ $? -eq 0 ]; then
Arch="hp300"
fi
fi
if [ -f /bin/hp9000s700 ]; then
(/bin/hp9000s700) > /dev/null 2>&1
if [ $? -eq 0 ]; then
Arch="hp700"
fi
fi
-> if [ -f /bin/hp9000s800 ]; then
-> (/bin/hp9000s800) > /dev/null 2>&1
-> if [ $? -eq 0 ]; then
-> Arch="hp700"
-> fi
-> fi
;;
-----------------------------------------------------------------
The following user files have this dependency and
need this patch:
MATLAB
$MATLAB/install_matlab <- critical
$MATLAB/install/arch.sh <- critical
$MATLAB/etc/util/arch.sh <- critical
$MATLAB/extern/src/F2f
$MATLAB/extern/src/bf2f
SIMULINK
$MATLAB/simulink/src/bf2f
Signal Blocks
$MATLAB/toolbox/dspblks/bin/roller
Fixpoint Blocks toolbox
$MATLAB/toolbox/fixpoint/bin/fpoptmze
The minimal and critical changes are the first
three.
7. Comments about 'Installation Guide for UNIX' document
-----------------------------------------------------
7.1 Getting to an online version of this document
---------------------------------------------
Before installation: (PostScript version only)
-------------------
CD-ROM: after mounting copy from top level
directory the file:
guide.ps (GUIDE.PS;1 on HP systems)
or for A4 paper size
guide_a4.ps (GUIDE_A4.PS;1 on HP systems)
Then view or print it.
FTP: download from the UNIX FTP area the file:
installguide.ps
or for A4 paper size
installguide_a4.ps
Then view or print it.
After installation:
------------------
PostScript:
----------
Print or view the file:
$MATLAB/installguide.ps
or for A4 paper size
$MATLAB/installguide_a4.ps
PDF:
---
To view the PDF file directly assuming you have
installed a PDF reader on your system execute
at the UNIX command prompt:
matlabdoc -a ins_unix
You can save a copy by using the MATLAB Help Desk.
7.2 Errata: Boot links are now called lmboot_TMW5 and lmdown_TMW5
-------------------------------------------------------------
In order not to conflict with MATLAB 4 boot links which are
'lmboot' and 'lmdown' the MATLAB 5 boot links are:
/etc/lmboot_TMW5 -> $LM_ROOT/lmboot
/etc/lmdown_TMW5 -> $LM_ROOT/lmdown
Here LM_ROOT is normally $MATLAB/etc.
The distributed code fragments are correct.
Use the 'lmboot -s' command as superuser to create
the links.
7.3 Errata: Default FLEXlm debug logfile is /usr/tmp/lm_TMW5.log
------------------------------------------------------------
This has been changed from $MATLAB/etc/license.log5. To
choose a different default edit the
$MATLAB/etc/lmopts.sh
file after installation.
7.4 Errata: $MATLAB/toolbox/local directory holds the local
-------------------------------------------------------
environment files
-----------------
The MATLAB directory that holds the local environment
files like matlabrc.m, license.m, printopt.m, etc. is
$MATLAB/toolbox/local
It is NOT $MATLAB/toolbox/matlab/local as stated in several
places in the document.
7.5 Errata: Manual pages no longer installed in system level
--------------------------------------------------------
directory
---------
On page 1-12 it describes how you can specify a location for
the manual pages in the Installation Data Screen for the CD-ROM
installation. You may do so but it will have no effect. See
Section 8.1 below for more details about accessing the manual
pages and where they are located in the distribution.
7.6 'New Style' license format used in document, but 'Old Style'
------------------------------------------------------------
shipped with MATLAB 5.0
-----------------------
In Section 5.5 above license file formats 'Old Style' and
'New Style' are described. The 'New Style' license file format
is used in the document, but you will be shipped an 'Old Style'
license file until a future release. This is required so that
a single license file can work with MATLAB 4.2c and MATLAB 5.
8. Miscellaneous
-------------
8.1 Manual pages no longer installed in system level directory
----------------------------------------------------------
The manual pages are no longer installed in a system level
directory. The installers still let you believe that you can
install them, but in reality nothing is done. To view them at
the UNIX prompt type:
matlabdoc -man
The unformatted manual pages are located in:
$MATLAB/man/unformatted
The formatted manual pages are located in:
$MATLAB/man/formatted
8.2 SunOS 5.4 linker (ld) bug patch
-------------------------------
This bug will prevent you from creating mex files on Solaris
2.4 systems. The patch file provided by Sun is at the top
level of the CD-ROM. When the CD-ROM is mounted on a Sun system
the filename is:
sunos5.pch
Copy the patch file from the CD-ROM like:
cp /cdrom/sunos5* /tmp (also known as 102303-05)
NOTE: sunos5.pch is a compressed tar file.
Next extract the patch as root like:
cd /tmp; cat sunos5.pch | zcat | tar -xvf -
which creates directory:
102303-05
See the README file:
102303-05/README.102303-05
for a description and installation instructions.
9. Help
----
If you have questions or want to report problems please contact:
The MathWorks, Inc. Technical Support:
Email: support@mathworks.com
Phone: 508-647-7000
FAX: 508-647-7201
FLEXlm is a Trademark of Globetrotter Software
MATLAB is a Registered Trademark of The MathWorks, Inc.
PostScript is a Registered Trademark of Adobe Systems, Inc.
UNIX is a Registered Trademark of the Open Group Company
------------------------------------------------------------------------
Copyright (c) 1996-1998 by The MathWorks, Inc.
$Revision: 1.4 $ $Date: 1998/09/27 20:56:45 $
------------------------------------------------------------------------