06-15-2010
Yeah... fine, it's work!
I found my problem... on the top of my script I defined a path's variable with the name PATH, so the shell could no more to find the date function... it's stupid!
Thanks for your help!
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I am trying to modify a script which accepts date in format dd/mm/yy. I am trying to modify the script so that it retrieves the date that was 15 days earlier from today as start date. Eg.if today is 05/09/2006, the script should retrieve 21/08/2006 as start date. Is there any script/code to... (2 Replies)
Discussion started by: ritzwan0
2 Replies
2. UNIX for Dummies Questions & Answers
Doubt #1
I have a program that I want the user to input date. When the user inputs the date, is it able to format it to system date dd-mm-yyy and then echo the value into a text file?
Doubt#2
If the above is not going to work, I tried to have the system date appear in the user input field and... (6 Replies)
Discussion started by: frossie
6 Replies
3. Shell Programming and Scripting
I need to increment a date value through shell script.
Input value consist of start date and end date in DATE format of unix.
For eg.
I need increment a date value of 1/1/09 to 31/12/09 i.e for a whole yr.
The output must look like
1/1/09
2/2/09
.
.
.
31/1/09
.
.
1/2/09
.
28/2/09... (1 Reply)
Discussion started by: sunil087
1 Replies
4. Shell Programming and Scripting
Im in EST, and im using the command
CurrentDate=`TZ="EST+24" date +'%y%m%d'`
to get the yesterday's date.
Does this work perfectly for the boundary conditions of month end or year end(leap year) etc ? (2 Replies)
Discussion started by: prasperl
2 Replies
5. Shell Programming and Scripting
Hi,
I want to compare today's date(DDMMYYYY) with yesterday(DDMMYYYY) from system date,if (today month = yesterday month) then execute alter query else do nothing.
The above requirement i want in Shell script(KSH)...
Can any one please help me?
Double post, continued here. (0 Replies)
Discussion started by: kumarmsk1331
0 Replies
6. Shell Programming and Scripting
I have a shell script (.sh) and I want to pass a parameter value to the awk command but I am getting exception, please assist.
diff=$1$2.diff
id=$2 new=new_$diff
echo "My id is $1"
echo "I want to sync for user account $id"
##awk command I am using is as below
cat $diff | awk... (2 Replies)
Discussion started by: Ashunayak
2 Replies
7. UNIX for Dummies Questions & Answers
Hi ,
How would i write a shell script to run the code from one date to another date EXample 2014-01-01 to 2014-02-28, can i any provide some clue on this (4 Replies)
Discussion started by: vikatakavi
4 Replies
8. Shell Programming and Scripting
hi all,
How to compare two files whether they are same are not...? like i had my input files as 20141201_file.txt and 20141130_file2.txt
how to compare the above files based on date .. like todays file and yesterdays file...? (4 Replies)
Discussion started by: hemanthsaikumar
4 Replies
9. Linux
Hi,
My question is how to calculate the quarter end date according to the current date in shell script? (2 Replies)
Discussion started by: Divya_1234
2 Replies
10. UNIX for Beginners Questions & Answers
Hi Community!
Following on from this code in another thread:
#!/bin/bash
file_string=`/bin/cat date.txt | /usr/bin/awk '{print $5,$4,$7,$6,$8}'`
file_date=`/bin/date -d "$file_string"`
file_epoch=`/bin/date -d "$file_string" +%s`
now_epoch=`/bin/date +%s`
if
then
#let... (2 Replies)
Discussion started by: Greenage
2 Replies
LEARN ABOUT CENTOS
btraceback
BTRACEBACK(1) Network backup, recovery and verification BTRACEBACK(1)
NAME
btraceback - wrapper script around gdb and bsmtp
SYNOPSIS
btraceback /path/to/binary pid
DESCRIPTION
btraceback is a wrapper shell script around the gdb debugger (or dbx on Solaris systems) and bsmtp, provided for debugging purposes.
USAGE
btraceback is called by the exception handlers of the Bacula daemons during a crash. It can also be called interactively to view the cur-
rent state of the threads belonging to a process, but this is not recommended unless you are trying to debug a problem (see below).
NOTES
In order to work properly, debugging symbols must be available to the debugger on the system, and gdb, or dbx (on Solaris systems) must be
available in the $PATH.
If the Director or Storage daemon runs under a non-root uid, you will probably need to be modify the btraceback script to elevate privi-
leges for the call to gdb/dbx, to ensure it has the proper permissions to debug when called by the daemon.
Although Bacula's use of btraceback within its exception handlers is always safe, manual or interactive use of btraceback is subject to the
same risks than live debugging of any program, which means it could cause Bacula to crash under rare and abnormal circumstances. Conse-
quently we do not recommend manual use of btraceback in production environments unless it is required for debugging a problem.
ENVIRONMENT
btracback relies on $PATH to find the debugger.
FILES
/usr/lib/bacula/btraceback
The script itself.
/usr/sbin/btraceback
symbolic link to /usr/lib/bacula/btraceback
/etc/bacula/scripts/btraceback.gdb
the GDB command batch used to output a stack trace
AUTHOR
This manual page was written by Lucas B. Cohen <lbc@members.fsf.org>
SEE ALSO
bsmtp(1)
Kern Sibbald 6 December 2009 BTRACEBACK(1)