11-23-2004
Absolute and relative path for directoroes anf files:
a).Be sure to use absolute PATHs for directories/files instead of relative PATHS in the scirpt.
b).Do n't use absolute PATH in case you are saving some data into the files or creating temp files and making use of them in the flow of the script.
For temp savings it should be good idea to use relative directories
because u want to run the script from 2 different places at the same time.
c).And as RTM said... u should have the same env (PATH .. etc )settings in both the places before running the script to get the same results.
10 More Discussions You Might Find Interesting
1. Solaris
Hi all,
First time poster here. Great forum.
Im trying to spawn new shells and pass commands to the new shells in a solaris 8 environment utilizing dtterm and its option -e.
I can successfully spawn a window utilizing the following code:
/usr/dt/bin/dtterm -display <ip.address> &
... (4 Replies)
Discussion started by: Rocketman8541
4 Replies
2. Shell Programming and Scripting
Hi all,
Im trying to figure out what the command would be to launch terminal windows from the command line in Open Step 4.2 . (looking for something similiar like /usr/bin/xterm or /usr/bin/dtterm etc)
echo $TERM = vt100
echo $SHELL = /bin/csh
Im combing over alot of OpenStep 4.2 and... (3 Replies)
Discussion started by: Rocketman8541
3 Replies
3. UNIX for Advanced & Expert Users
We have a program (reader) that reads audio files in a real-time continuous stream from a sender program. If the reader gets weird we want the sender to be able to send one command that will stop the current reader and start a new one that will be able to continue reading in the files. The sender... (9 Replies)
Discussion started by: laforge
9 Replies
4. Programming
I want to spawn n child processes but have two different classes..with the foremost one forking/spawning the child process and the latter performing a function w/ the spawned processes.
I can do this in one class with an if statement and the simple
if((pid=fork())==0) //child process
{
... (1 Reply)
Discussion started by: StrengthThaDon
1 Replies
5. Shell Programming and Scripting
Hi,
I need to spawn mutilpe threads , each invoking a different set of shell scripts, in parallel.
What would be the best way to do that.
Any sample script would greatly help. I am a novice at Unix so any help is much appreciated.
Thanks (5 Replies)
Discussion started by: neeto
5 Replies
6. UNIX for Advanced & Expert Users
Hi - I need help. My user crontab is spawning multiple at processes (and multiple mencoder program starts, that exit, then restart, repeatedly), locking up my system.
For example I have this entry in my crontab:
$ sudo crontab -u victoria -e
* * * * * ~/recordings/pvr1
* * * * *... (10 Replies)
Discussion started by: gstuart
10 Replies
7. Shell Programming and Scripting
When trying to get the correct syntax to cron a script that creates a file with the date stamp as its output, sometimes I get these results:
- from the command line, I may encounter an error that leaves me without the usual $ prompt. Am I in a new shell? I try to exit it with 'exit' or :q! and... (1 Reply)
Discussion started by: landog
1 Replies
8. Shell Programming and Scripting
Hi,
I am having a shell script which has a while loop as shown below.
while
do
sleep 60
done
I am executing this script from Informatica ETL tool command task from where we can execute UNIX commands/scripts. When i do that, i am seeing 2 processes getting started for one script... (2 Replies)
Discussion started by: chekusi
2 Replies
9. Solaris
Hi,
I am having a shell script on Solaris 10 which has a while loop as shown below.
#!/usr/bin/ksh
#
while
do
sleep 60
done
Name of the shell script is coldcentric.sh. I executed script /DATAWAREHOUSE/LOAD/Scripts/coldcentric.sh from a command task in Informatica worklow as... (3 Replies)
Discussion started by: chekusi
3 Replies
10. Shell Programming and Scripting
Hi there,
I would like to understand the purpose of spawning a TTY shell?
Does it mean that it will help to open up a new Windows on the current interactive shell such that when the session gets lost the other won't
Any explanation will be helpful. (3 Replies)
Discussion started by: alvinoo
3 Replies
LEARN ABOUT CENTOS
amsamba
AMSAMBA(8) System Administration Commands AMSAMBA(8)
NAME
amsamba - Amanda Application to interface with smbclient
DESCRIPTION
Amsamba is an Amanda Application API script. It should not be run by users directly. It uses smbclient to backup and restore data.
The diskdevice in the disklist (DLE) must have the form '//CIFSHOST/SHARE/SUBDIR' where CIFSHOST is the CIFS host containing the data to be
backed up, SHARE is the share to connect, and subdir is the subdirectory to backup. '/subdir' can be ommited, in which case the complete
share is archived.
Unlike most applications, amsamba backs up and restores data located on a different system from that where amsamba itself runs. The host
containing the data is the CIFS host. In practice, amsamba is usually run on the same system as the Amanda server, with a DLE like
localhost "//CIFSHOST/SHARENAME" amsamba-dumptype
Include or exclude can be used, but not both. The path for 'exclude list' or 'include list' must be absolute path on the CIFS host. The
estimate calculates the complete size of the share, without regard for include or exclude directives. It will be larger than the actual
dump if you use include or exclude. Using 'estimate server' in the dumptype could give better estimate.
PROPERTIES
This section lists the properties that control amsamba's functionality. See amanda-applications(7) for information on application
properties and how they are configured.
SMBCLIENT-PATH
The path to the smbclient binary. The default is set when Amanda is built by the --with-smbclient configure option.
GNUTAR-PATH
The path to the gnutar binary. The default is set when Amanda is built by the --with-gnutar configure option. gnutar is used to create
the index.
AMANDAPASS
Location of the amandapass file, defaulting to "$CONFIG_DIR/amandapass". Relative pathnames are relative to the configuration
directory, "$CONFIG_DIR/<config>". Note that this file is located on the client, not on the server. The format of the file is as
follow:
Sharename User%Password Domain
Sharename is '//HOST/SHARE' without the SUBDIR. Sharename can be quoted, it can be '*' to match all share, it can be '//pc-host/*' to
match all share on pc-host. User is the username use to connect to the share. Password is the password use to connect to the share.
'%Password' is optional if the user can connect to the share without password. 'User%Password' is optional, the user 'guest' without
password is use to connect to the share. Domain is optional. Example:
//another-pc/share otheruser%otherpw domain
//another-pc/share otheruser%otherpw
//another-pc/share myuser mydomain
//another-pc/share myuser
//another-pc/share
ALLOW-ANONYMOUS
This username without password is used to connect to the share if no matching entry is found in the amandapass file.
DIRECTORY
For restore command only, the data is recoved in that directory. Must be a unix path for "tar" RECOVER-MODE or a smb path for "smb"
recover-MODE.
RECOVER-MODE
"tar" or "smb", default to "tar". If "tar", the data is recovered on the local machine, If "smb", the data is recovered on the smb
client machine.
INCLUDE AND EXCLUDE LISTS
This application supplies exclude lists via the smbclient -TX option. Normal shell-style wildcard expressions, using * and ?, are not
supported. All expressions are matched only from the base directory of the DLE. Expressions that match a directory may have a leading or
trailing "/". Example expressions:
./temp-files # exclude top-level dir "temp-files" entirely
./temp-files/ # same
/temp-files # same
temp-files # same
./temp-files/* # BAD: does nothing
*.iso # BAD: does nothing
proxy/local/cache # exclude "cache" in dir "proxy/local"
Include lists are supported only if excludes are not given. They are handled via the smbclient -TI option. Include matching is identical to
the exclude matching described above.
EXAMPLE
define application app_amsamba {
property "SMBCLIENT-PATH" "/usr/bin/smbclient"
property "GNUTAR-PATH" "/bin/tar"
property "AMANDAPASS" /etc/amandapass"
property "ALLOW-ANONYMOUS" "guest"
}
SEE ALSO
amanda(8), amanda.conf(5), amanda-applications(7)
The Amanda Wiki: : http://wiki.zmanda.com/
AUTHOR
Jean-Louis Martineau <martineau@zmanda.com>
Zmanda, Inc. (http://www.zmanda.com)
Amanda 3.3.3 01/10/2013 AMSAMBA(8)