10-08-2008
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
hi all ,
i wanted to know if someone knows how can i use
a variable inside another variable
e.g.
#!/bin/csh
foreach test(1 2 3)
set sta_$test = "2"
##now its the problem i want to echo the new var
#$sta_$test , each time with anothe num ($test = 1... (2 Replies)
Discussion started by: udi
2 Replies
2. Shell Programming and Scripting
program name--test
#!/bin/bash
output1=`/home/user/a.c`
output2=`/home/user/a.c`
k=`$output1 + 1`
m=`$output2 + 1`
echo $k
echo $m
---------------------------------------------------------------------------
prgram name--a.c
#include<stdio.h>
int main() (1 Reply)
Discussion started by: sameworld1980
1 Replies
3. Shell Programming and Scripting
#!\bin\sh
TEST=test.log
GREP=\usr\bin\grep
$GREP -i 'dog\|cat' ${TEST}
Why doesn't grep run at all? (10 Replies)
Discussion started by: jazzaddict
10 Replies
4. Shell Programming and Scripting
I am using variable to give the location of the file I am using but I get error.
Here is the code:
LogFile=/tmp/log.email
echo -e "could not close the service - error number $error \n" > $LogFile
well this is not all the code but is enough because the problem start when I try to use the... (3 Replies)
Discussion started by: programAngel
3 Replies
5. Shell Programming and Scripting
Hi folks,
I am facing problem when I concat variables with the string.
Value for 'JDBC_CLASSES' variable looks malformed (/classes12.zip2.0KAGES)
But, my expected result for 'JDBC_CLASSES' is
/opt/API-R111/PACKAGES/jdbc/ORACLE9.2.0/classes12.zip
Am I missing anything here?
My... (10 Replies)
Discussion started by: Adhil
10 Replies
6. Emergency UNIX and Linux Support
Hi all!
I know that environment variables can be set on the .bashrc file, but I need to set them from a sh script. I saw a lot of websites that teach this but it doesn't work for me.
#!/bin/sh
DEKTOP=$DESKTOP=:/home/rrodrigues/Desktop
export DESKTOP
if I do echo $DESKTOP returns me... (10 Replies)
Discussion started by: ruben.rodrigues
10 Replies
7. Shell Programming and Scripting
can someone please explain to me what i'm doing wrong with this code:
WELT=$(awk '(($1 ~ "^${caag}$") || ($2 ~ "^${caag}$"))' /tmp/Compare.TEXT)
when run from the command line, it works. but it seems to be having a problem doing the comparison when variables are involved.
i tested from... (1 Reply)
Discussion started by: SkySmart
1 Replies
8. Shell Programming and Scripting
hi,
i have a shell script which calls another shell which in turn calls another shell script.
Main_shell_script.sh
echo "In Main_shell_script.sh"
FILENAME="original.txt" # LINE 1
DST_FILENAME=$FILENAME # LINE 2
echo "FILENAME = {$FILENAME}"
echo "DST_FILENAME =... (3 Replies)
Discussion started by: Little
3 Replies
9. Shell Programming and Scripting
Hi All,
i have a requirement where i have to run a script with at least 25 arguements and position of arguements can also change. the unapropriate way is like below. can we achieve this in more good and precise way??
#!/bin/ksh
##script is sample.ksh
age=$1
gender=$2
class=$3
.
.
.... (3 Replies)
Discussion started by: Lakshman_Gupta
3 Replies
10. Shell Programming and Scripting
From the command line:
dions-air:scripts dion$ ls -l /Users/dion/Library/Application\ Support/Garmin/Devices/3816821036/History/2014-06-07-055251.TCX
-rw-r--r-- 1 dion staff 157934 7 Jun 06:55 /Users/dion/Library/Application Support/Garmin/Devices/3816821036/History/2014-06-07-055251.TCXworks... (2 Replies)
Discussion started by: dionbl
2 Replies
LEARN ABOUT OSF1
acl_init
acl_init(3) Library Functions Manual acl_init(3)
NAME
acl_init - Allocate and initialize ACL internal working storage
LIBRARY
Security Library (libpacl.a)
SYNOPSIS
#include <sys/acl.h>
acl_t acl_init( const size_t size);
PARAMETERS
Specifies the size of the working storage in bytes.
DESCRIPTION
NOTE: This function is based on Draft 13 of the POSIX P1003.6 standard.
The acl_init() function allocates and initializes working storage for an ACL of at least size bytes. A pointer to the working storage is
returned. When the area is first allocated, it contains a ACL that has no ACL entries.
RETURN VALUES
Upon successful completion, the acl_init() function returns a pointer to the working storage. Otherwise, a NULL pointer is returned and
errno is set to indicate the error.
ERRORS
If any of the following conditions occur, the acl_init() function returns a value of NULL and sets errno to the corresponding value: The
acl_t to be returned requires more memory than allowed by the hardware or system-imposed memory management constraints. The function is
not supported by the implementation.
RELATED INFORMATION
acl_add_perm(3), acl_clear_perm(3), acl_create_entry(3), acl_free(3)
Security delim off
acl_init(3)