function fxn
{
echo "target in build_ndm is $target"
}
function main
{
target=${server_type}
echo "target in main is $target"
fxn
}
In the above the value of target is not being propagated to the function while ideally it should be since typeset variables are visible in sub functions
What is the issue here
Moderator's Comments:
edit by bakunin: Please use CODE-tags as prescribed by the forum rules. Thank you.
Last edited by Scrutinizer; 12-24-2015 at 06:16 AM..
Reason: Restored content deleted by OP, otherwise thread incomprehensible
Hi all,
I have problem understanding shell script.Written that
$bindir/put_load.ksh ; typeset RV= $?
I dont have any other document about script. How can i find that $bindir is exist or not what is the content of that, i am working on new box . how can i search that in old box what... (4 Replies)
I have found this command *typeset* and the option * -f *, which should provide me the list of all the currently defined functions. Is there any possibility of specifying the file in which this command to search ? (1 Reply)
Hi,
Could any one please explain about typeset or share any link from where i can study about typeset i.e how to use it, how to define it.. etc?
Thanks-
Yogi (3 Replies)
Hi,
Can any one please explain me the use of 'typeset' in shell scripting?
I donot under stand the use and advantages of using typeset.
In one of our script, it is written like typeset VERBOSE NO_UPDATE
typeset LOAD_SYBASE_TABLES
I donot understand what actually these lines do.
As per my... (2 Replies)
Hi,
All the scripts we have here use typeset instead of normal variables.
They don't have any parameters, they just get declared at the beginning of the scripts like this: typeset var1 var2 var3Could anyone tell me why this is done? I don't see the advantage in this over using normal variables. (1 Reply)
Hi,
As per my understanding typeset wil lmake a variable constant or readonly and -i option will make a variable integer. But please see the below outputs
typeset -i abc=000001;echo $abc
1
typeset -i abc=0000010;echo $abc
8
typeset -i abc=00000100;echo $abc
64
typeset -i... (3 Replies)
Hi All,
typeset -Z4 curtime command is giving different result than expected inside scripts in linux.But it gives expected results outside the scripts.Can you please help us
---------- Post updated at 05:37 AM ---------- Previous update was at 05:25 AM ----------
curTime=`date +%H%M`... (5 Replies)
I don't have man typeset entry in unix.
what is the use of typeset command and can you give some examples for that. (1 Reply)
Discussion started by: ramkumar15
1 Replies
LEARN ABOUT OPENSOLARIS
stmfaddtotargetgroup
stmfAddToTargetGroup(3STMF) SCSI Target Mode Framework Library Functions stmfAddToTargetGroup(3STMF)NAME
stmfAddToTargetGroup - add a target to an existing target group
SYNOPSIS
cc [ flag... ] file... -lstmf [ library... ]
#include <libstmf.h>
int stmfAddToTargetGroup(stmfGroupName *targetGroupName,
stmfDevid targetName);
PARAMETERS
targetGroupName The name of the target port group to which the specified targetName is added.
targetName The device identifier of the target port to add to the specified target group.
DESCRIPTION
The stmfAddToTargetGroup() function adds a target to an existing target group.
RETURN VALUES
The following values are returned:
STMF_ERROR_EXISTS The specified targetName already exists in this tagettGroupName or in another target group in the system.
STMF_ERROR_GROUP_NOT_FOUND The specified targetGroupName was not found in the system.
STMF_STATUS_SUCCESS The API call was successful.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Interface Stability |Committed |
+-----------------------------+-----------------------------+
|MT-Level |Safe |
+-----------------------------+-----------------------------+
SEE ALSO libstmf(3LIB), attributes(5)SunOS 5.11 9 Jun 2008 stmfAddToTargetGroup(3STMF)