I am able to pass system symbols in native commands like:

ln -s \$SYSNAME/fitb              /RSM02A/opt/fitb

_________________________________________________________________
Dave Jousma
Assistant Vice President, Mainframe Engineering
[email protected]
1830 East Paris, Grand Rapids, MIĀ  49546 MD RSCB2H
p 616.653.8429
f 616.653.2717


-----Original Message-----
From: IBM Mainframe Discussion List [mailto:[email protected]] On Behalf 
Of David Magee
Sent: Tuesday, February 09, 2016 9:52 AM
To: [email protected]
Subject: Re: Unix support of symbols in .profile

Kirk,

My .profile is

umask 027                                                               
Sys_MPT=$(sysvar SYSNAME)                                               
echo $Sys_MPT                                                           
echo $HOME/$Sys_MPT/maxdate                                             
if [ ! -f $HOME/$Sys_MPT/maxdate ]; then                                
  /usr/sbin/mount -v -f UNIX.ZFS.QRDR.C2ECQRLF.$Sys_MPT ./$Sys_MPT
  echo "* The QRadar LEEF file was NOT mounted. *"                      
  echo "* A mount command has been issued. *"                           
  else                                                                  
  echo "* The QRadar LEEF file was ALREADY mounted. *"                  
fi  

The echo's in STDOUT are:
    
SYSQ                                          
/u/c2ecqrlf/SYSQ/maxdate                      
* The QRadar LEEF file was ALREADY mounted. * 

But STDERR is showing

[: /u/c2ecqrlf/.profile 5: FSUM7351 not found   

and the mount was NOT performed.

Something must not be right with my if statement. The if statement works when 
variables are not in the statement.                                             
                    

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions, send email to 
[email protected] with the message: INFO IBM-MAIN

This e-mail transmission contains information that is confidential and may be 
privileged.   It is intended only for the addressee(s) named above. If you 
receive this e-mail in error, please do not read, copy or disseminate it in any 
manner. If you are not the intended recipient, any disclosure, copying, 
distribution or use of the contents of this information is prohibited. Please 
reply to the message immediately by informing the sender that the message was 
misdirected. After replying, please erase it from your computer system. Your 
assistance in correcting this error is appreciated.


----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to