When you say did not run, what message did you get? You say you've written a csh script, which I assume is not the same as your interactive shell? Did you set the shebang correctly on the first line of your script. e.g.:
Did you verify that csh exists at that location?
Last edited by Scrutinizer; 12-26-2009 at 06:27 PM..
The script checks for free space stats on Oracle. If there are any tablespaces with more than 85% usage it prints the details of the tablespace. If all the tablespaces have more than 15% free space, then "All tablespaces have more than 15 pct free space" must be printed on the screen.
When I run... (2 Replies)
Hi,
please consider, I'm pretty new to HP-UX, thanks.
Our server (rp7420 with HP-UX 11.31) has crashed due to disk write error (not boot partition). So I replaced damaged device with the new one of the same size and performed dd copy 1:1 to restore data - vxfs partition "/dev/vg01/lvol1"... (4 Replies)
Hi!
I have a svn backup script that works perfectly if I execute it from the command line but if I set it as a cronjob to run at night, only part of the code works.
So, basically the scripts starts by deleting the folder yesterday and then moves the folder today to the folder yesterday. When... (4 Replies)
how to run an already developed script run against a list of ip addresses solaris 8 question.
the script goes away and check traffic information, for example
check_GE-VLANStats-P3 1.1.1.1
and returns the results ok.
how do I run this against an ip list? i.e a list of 30 ip addresses (26 Replies)
Hello community,
I created a script to simply query DB and then analize data. The environment where the script will works is two RedHat machines that access both to an external database. My script runs from the first crontab node. But what about if the first node goes down?
What I need is copy... (2 Replies)
Hi,
First of all merry christmas and Happy holidays to all :D
My situation is as below,
When a backup job runs on a mainframe server, it creates a 0byte file on a network drive which is accessible through linux
Linux server : Red Hat Enterprise Linux Server release 5.3 Beta (Tikanga)
File... (6 Replies)
Hello
I have a problem with the crontab command
when I run a code containing Curl on the command line it runs without fail but as soon as I program it with crontab it executes everything except the curl returns fail
thank you for helping me to resolve this problem because since Monday I look... (14 Replies)
Linux System having all Perl, Python, PHP (and Ruby) installed
From a Shell script, can call a Perl, Python, PHP (or Ruby ?) file
eg
eg
a Shell script run in a case statement call to run a php file, also Perl or/and Python file???
Like
#!/usr/bin/bash
....
....
case $INPUT_STRING... (1 Reply)
Discussion started by: hoyanet
1 Replies
LEARN ABOUT NETBSD
getmode
SETMODE(3) BSD Library Functions Manual SETMODE(3)NAME
getmode, setmode -- modify mode bits
LIBRARY
Standard C Library (libc, -lc)
SYNOPSIS
#include <unistd.h>
void *
setmode(const char *mode_str);
mode_t
getmode(const void *set, mode_t mode);
DESCRIPTION
The setmode() function accepts a string representation of a file mode change, compiles it to binary form, and returns an abstract representa-
tion that may be passed to getmode(). The string may be an numeric (octal) or symbolic string of the form accepted by chmod(1), and may rep-
resent either an exact mode to set or a change to make to the existing mode.
The getmode() function adjusts the file permission bits given by mode according to the compiled change representation set, and returns the
adjusted mode. While only the permission bits are altered, other parts of the file mode, particularly the type, may be examined.
Because some of the possible symbolic values are defined relative to the file creation mask, setmode() may call umask(2), temporarily chang-
ing the mask. If this occurs, the file creation mask will be restored before setmode() returns. If the calling program changes the value of
its file creation mask after calling setmode(), setmode() must be called again to recompile the mode string if getmode() is to modify future
file modes correctly.
If the mode passed to setmode() is invalid, setmode() returns NULL.
EXAMPLES
The effects of the shell command 'chmod a+x myscript.sh' can be duplicated as follows:
const char *file = "myscript.sh";
struct stat st;
mode_t newmode;
stat(file, &st);
newmode = getmode(setmode("a+x"), st.st_mode);
chmod(file, newmode);
ERRORS
The setmode() function may fail and set errno for any of the errors specified for the library routines malloc(3) or strtol(3). In addition,
setmode() will fail and set errno to:
[EINVAL] The mode argument does not represent a valid mode.
SEE ALSO chmod(1), stat(2), umask(2), malloc(3)HISTORY
The getmode() and setmode() functions first appeared in 4.4BSD.
BUGS
Each call to setmode allocates a small amount of memory that there is no correct way to free.
The type of set should really be some opaque struct type used only by these functions rather than void *.
BSD January 4, 2009 BSD