Sponsored Content
Top Forums Shell Programming and Scripting lack of understanding > annoying error Post 302317775 by tom_cmu on Wednesday 20th of May 2009 01:59:26 AM
Old 05-20-2009
You are correct about "if [ "$work" = "STARTING" ]".

1. I put
work=""
after your sql_Dir=... statement

2. I modify the statement
echo "PAST LANDING DIR. CHECK with work = $work in the $landingDir copy to $toBackUpDir"
to trace on variable's value

3. I change your if cause script from if [ -<option> <argument>] to if test -<option> <argument>
and execute the script.
I get this.

_______________________________________________________
backup.sh is a shell script designed to backup pre- |
specified files to a pre-specified file path. For |
details see the parameters. - Jonathan Zacsh 5/20/09 |
______________________________________________________|
Script Started: Wed May 20 12:54:52 ICT 2009
---------------

Checking for specified landing directory: ./download/
Directory ./download/ is present and ready to receive backup.
Checking that ./download/ does not contain old backup files.
The variable $tarCheck returns: ./download//super_backup.tar
I am not ready to backup, first download and delete the above mentioned contents of the ./download/ landing directory.
AFTER NESTED ELSE#DEBUG
AFTER NESTED IF
PAST LANDING DIR. CHECK with work = NOT starting in the ./download/ copy to ./tmp
AFTER OUTER-LAYER IF-STATEMENT
Backup sequence ended early.

---------------
Script Ended: Wed May 20 12:54:52 ICT 2009
_______________________________________________________
|_____________________________________________________|

So it means if you can get this you can continue to fine tune your script.
I hope you will get it.
Note: super_backup.tar is existing in my sudirectory download .

Last edited by tom_cmu; 05-20-2009 at 06:21 AM..
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

a very annoying problem

hi i got fbsd here,when i try to start my X server as an user I got hte following error. Fatal server error: xf86OpenConsole: Server must be running with root permissions You should be usig Xwrapper to start the server or xdm. We strongly advise against making the server SUID root! But... (2 Replies)
Discussion started by: Stormpie
2 Replies

2. Shell Programming and Scripting

Very ANNOYING Problem - Please Help

Hey Guys I have an extremely annoying problem with regular expressions! At this point i believe the command 'read' is causing the problem due to the carriage return it places once its done. I have an continuous loop until the input is correct: (After initial read statement) while ... (7 Replies)
Discussion started by: shadow0001
7 Replies

3. Post Here to Contact Site Administrators and Moderators

Annoying tooltips

Hi Is there any way to turn off the (often ridiculously big) tooltips that are displayed when hovering over a topic in a topic list? It's driving me nuts. Thx. J (1 Reply)
Discussion started by: jgrogan
1 Replies

4. Shell Programming and Scripting

Help understanding syntax error Issue

Hi i as you may already know i am creating a menu driven program. I have chosen to take the approach of implementing each interface individually, after adding another interface and attempting to run the program i am faced with the following error: ./Assigntest: line 32: syntax error near... (6 Replies)
Discussion started by: warlock129
6 Replies

5. Shell Programming and Scripting

Need help understanding perl script error

I solicited this site earlier this week and got a good answer for a perl Script so I made this script from what understood from the answers But now I have a bug and I'm stump. It doesn't parse correctly the Output it stays on the first line My $f2 and reprints in a endless loop I'm sure there... (3 Replies)
Discussion started by: Ex-Capsa
3 Replies

6. UNIX for Advanced & Expert Users

Annoying in VI editor

Dear all, I try to search " ( double quote ) in a file using vi editor, I gave in the command mode /" it supposed to take to me to all the occurnces of " instead in some places it is taking me to different character.! It happens with some other characters in that file.... can you... (5 Replies)
Discussion started by: shahnazurs
5 Replies

7. Shell Programming and Scripting

Syntax error, not understanding the issue?

Close please. Refer to following thread: Sub Menu issues (2 Replies)
Discussion started by: Banned
2 Replies

8. IP Networking

Lack of IP Connectivity

Hi Can any one please help identify the issue in scenario 2: Connectivity Diagram: 1) Distribution Switch----Int_Switch----LabSwitch(Fa1/0)----Terminal Ser 2) Distribution Swtich----Int_Swtich----LabSwitch(Fa2/0)----3640 Router ---all links are access links Distribution Switch... (0 Replies)
Discussion started by: sureshcisco
0 Replies

9. Shell Programming and Scripting

How do I get out of the annoying > in bash???

Occasionally I make a mistake in my shell that results in there being a > for the prompt instead of the normal $. Today I accidentally left off a " in a sed command, sed s/\"//g" infile > outfile and then I get $ sed s/\"//g" infile > outfile > > I have never figured out how to get... (3 Replies)
Discussion started by: LMHmedchem
3 Replies
NETDISCO-MIBS-DOWNLOAD(1)				User Contributed Perl Documentation				 NETDISCO-MIBS-DOWNLOAD(1)

NAME
netdisco-mibs-download - Downloader for the Netdisco MIB bundle VERSION
This document refers to version 1.0700 of netdisco-mibs-download DESCRIPTION
Run this program to download the Netdisco MIB files bundle from Sourceforge. If the download is successful, you can run the netdisco-mibs- install program to unpack and install them. If the download fails, you can visit the Netdisco Sourceforge downloads page, details of which are given by this program on failure, and get the bundle yourself. ENVIRONMENT
Setting the environment variable "MIBS_DEBUG" to a true value will display information about failed mirror site downloads. EXIT CODES
0 - Successful download 1 - Failed download, possibly no available mirror 2 - Program must be run as root, and you are not root 3 - Error regarding the download directory AUTHOR
Oliver Gorwits "<oliver@cpan.org>" COPYRIGHT &; LICENSE Copyright (c) The University of Oxford 2007. All Rights Reserved. This program is free software; you can redistribute it and/or modify it under the terms of version 2 of the GNU General Public License as published by the Free Software Foundation. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA perl v5.14.2 2012-08-15 NETDISCO-MIBS-DOWNLOAD(1)
All times are GMT -4. The time now is 02:15 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy