Hi,
I want to check if a variable has a value assigned to it or not.
I can do following -
cat $Var > File1
if
then
echo "$Var has value"
else
echo "$Var is null"
fi
But I have to check for 3 Variables and I want to wrap it up in couple of unix statements.
Any... (3 Replies)
Hello,
I need help with the eval command.
I have been building a lengthy cmd using eval, and I need to create $var from the output of the cmd. Here is what I have.
Out=/dfezz1/output.txt
Node="'LPAR Info:'"
Gr3p0=" |grep"
Printc=" prtconf"
Output1=" 1>>$Out 0>&1"
Cat1="cat... (8 Replies)
I am making of a script that will go through a couple of for loops and create file names based on the values in that loop, however the variable that combines everything is not getting assigned properly:
#! /bin/bash
for imod in K33_j1b_WS9_6
do
for emod in mb2A mb2C mb3A mb3C mb4A... (1 Reply)
Hi,
i'm posting this in the Solaris forum although maybe it should be better in the General unix forum, I'm formatting an output witht he following command:
crontab -l | grep GBOUAT8 | grep UTP | grep -i stop | sed 's/\\//'
08 2 * * 2-6 /apps/sum_glob/gbo_uat/sparse/bin/dmg_cronlaunch -ENVI... (2 Replies)
The requirement is, there is a log file which contains a huge data. i need to get a particular field out of it by searching with another field.
ex:
2011-03-28 13:00:07,423 : millis=231 q={ call get_data_account(?,?,?,?,?) }, params=
i need to search for the word "get_data_account" in file... (1 Reply)
Hi all,
Hope someone can help me out here.
I have this BASH script (see below)
My problem lies with the variable path.
The output of the command find will give me several fields. The 9th field is the path. I want to captured that and the I want to filter this to a specific level.
The... (6 Replies)
I am trying to check whether a variable has been assigned on the command line or not.
Here is what I did:
#!/usr/bin/bash
if( $variable == '\0')
{
print "variable was not assigned"
exit
}
else
NF = 2 {print $1, ""}
exit
fi
awk -f question1.awk variable = 58 letters.txt.
So... (3 Replies)
Experts,
I'm having problems with the code below.
I'm trying to test $var2 for two different regexs.
I thought it could be done per below, but I'm getting the following error when running.
$ ./test.pl b fed50c0100****
Unescaped left brace in regex is deprecated, passed through in regex; marked... (2 Replies)
Discussion started by: timj123
2 Replies
LEARN ABOUT CENTOS
papi_get_multiplex
PAPI_get_multiplex(3) PAPI PAPI_get_multiplex(3)NAME
PAPI_get_multiplex -
Get the multiplexing status of specified event set.
SYNOPSIS Detailed Description
C Interface:
#include <papi.h>
int PAPI_get_multiplex( int EventSet );
Fortran Interface:
#include fpapi.h
PAPIF_get_multiplex( C_INT EventSet, C_INT check )
Parameters:
EventSet an integer handle for a PAPI event set as created by PAPI_create_eventset
Return values:
PAPI_OK
PAPI_EINVAL One or more of the arguments is invalid, or the EventSet is already multiplexed.
PAPI_ENOEVST The EventSet specified does not exist.
PAPI_EISRUN The EventSet is currently counting events.
PAPI_ENOMEM Insufficient memory to complete the operation.
PAPI_get_multiplex tests the state of the PAPI_MULTIPLEXING flag in the specified event set, returning TRUE if a PAPI event set is
multiplexed, or FALSE if not.
Example:
* int EventSet = PAPI_NULL;
* int ret;
*
* // Create an empty EventSet
* ret = PAPI_create_eventset(&EventSet);
* if (ret != PAPI_OK) handle_error(ret);
*
* // Bind it to the CPU component
* ret = PAPI_assign_eventset_component(EventSet, 0);
* if (ret != PAPI_OK) handle_error(ret);
*
* // Check current multiplex status
* ret = PAPI_get_multiplex(EventSet);
* if (ret == TRUE) printf("This event set is ready for multiplexing.")
* if (ret == FALSE) printf("This event set is not enabled for multiplexing.")
* if (ret < 0) handle_error(ret);
*
* // Turn on multiplexing
* ret = PAPI_set_multiplex(EventSet);
* if ((ret == PAPI_EINVAL) && (PAPI_get_multiplex(EventSet) == TRUE))
* printf("This event set already has multiplexing enabled0);
* else if (ret != PAPI_OK) handle_error(ret);
*
See Also:
PAPI_multiplex_init
PAPI_set_opt
PAPI_create_eventset
Author
Generated automatically by Doxygen for PAPI from the source code.
Version 5.2.0.0 Tue Jun 17 2014 PAPI_get_multiplex(3)