Sponsored Content
Operating Systems Solaris about gtar command with zcvf options Post 302382575 by raghu.iv85 on Wednesday 23rd of December 2009 08:18:20 PM
Old 12-23-2009
about gtar command with zcvf options

Hi all,

will gtar zcvf command work in csh and tcsh shells? Becuase when i'm executing one script in bash and ksh, it's working fine. But it's not working in csh and tcsh shells. We have to run multiple scripts in tcsh, so we can not change the shell while executing these scripts. One of my script is only having this command.

can anyone please suggest on this?

Regards,
Raghu.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

how to? launch command with string of command line options

my description from another thread... here's my code: #!/bin/bash IFS=$'\n' function OutputName() { input=$1 echo $input input=`echo "$input" | sed -e 's/.//'` input=`echo "$input".avi` output_name=$input } if ]; then echo... (5 Replies)
Discussion started by: TinCanFury
5 Replies

2. HP-UX

Linux - HP UX Command options

Just I gone with the script, I found some command's options which are not compatible with " HP-UX ". If I found any alternate commands to the following, most probably I will solve the issue here. 1. " iostat -x " --> this command's option( x ) is not available in HP-UX... (2 Replies)
Discussion started by: pk_eee
2 Replies

3. Shell Programming and Scripting

gtar error

Hi All, We have a gtar file and we are trying to untar the file with the option gtar -xvzf <filename> The gtar gets us till the end and throws the error message as highlighed below mfcp/XFHFCD2.CPY mfcp/XFHFCD3.CPY mfcp/XFHFCD.CPY gzip: stdin: unexpected end of file gtar:... (1 Reply)
Discussion started by: ganga.dharan
1 Replies

4. UNIX for Dummies Questions & Answers

gtar - question

I am trying to write a very large file, 570 gb, to a tape using gtar like this : gtar czxf /dev/rmt/1 ./* I get a message: off_t value 570635451556 too large (max=68719476735) It is writing to tape, but will it be good? Thanks (1 Reply)
Discussion started by: iancrozier
1 Replies

5. Shell Programming and Scripting

Need to disable options from a command

Hi, I am working on a Linux machine. I need to disable 2 options from the available 6 options of a command. For eg. in the "ls" command we have various options like "l ,r, t, a, .... " From this, I need to disable option "a" So when the users type in "ls -a", they should get an error or... (4 Replies)
Discussion started by: aster007
4 Replies

6. UNIX for Dummies Questions & Answers

Running set options from the command line and bash command

I'm reading about debugging aids in bash and have come across the set command. It says in my little book that an addition to typing set you can also use them "on the command line when running a script..." and it lists this in a small table: set -o option Command Line... (5 Replies)
Discussion started by: Straitsfan
5 Replies

7. Solaris

Gtar Lib file not found.

Hello All, I am preparing a script to view or Extract contents of a tape drive using gtar.But facing a strange issue while trying to extract files using gtar. If running script using sudo the getting the below error. ################ /usr/local/lib /usr/X11/lib /usr/X11R6/lib... (1 Reply)
Discussion started by: ajaincv
1 Replies

8. AIX

GTAR - new ways for faster backup - help required

We are taking backup of our application data(cobol file system, AIX/unix) before and after EOD job runs. The data size is approximately 260 GB in biggest branch. To reduce the backup time, 5 parallel execution is scheduled through control-m which backups up the files in 5 different *.gz. The job... (2 Replies)
Discussion started by: Bharath_79
2 Replies

9. AIX

GTAR - new ways to faster backup - help required

We are taking backup of our application data(cobol file system, AIX/unix) before and after EOD job runs. The data size is approximately 260 GB in biggest branch. To reduce the backup time, 5 parallel execution is scheduled through control-m which backups up the files in 5 different *.gz. The job... (8 Replies)
Discussion started by: Bharath_79
8 Replies

10. UNIX for Beginners Questions & Answers

Ls command options

Hi, If I want to list files with names containing a certain letter like " a " using just one ls command, is there any way of doing that? Note that it is containing a letter instead of one of the following (starting, ending with a letter or having the letter in between). what I want is to show... (1 Reply)
Discussion started by: AAAnni
1 Replies
runat(1)							   User Commands							  runat(1)

NAME
runat - execute command in extended attribute name space SYNOPSIS
/usr/bin/runat file [command] DESCRIPTION
The runat utility is used to execute shell commands in a file's hidden attribute directory. Effectively, this utility changes the current working directory to be the hidden attribute directory associated with the file argument and then executes the specified command in the bourne shell (/bin/sh). If no command argument is provided, an interactive shell is spawned. The environment variable $SHELL defines the shell to be spawned. If this variable is undefined, the default shell, /bin/sh, is used. The file argument can be any file, including a directory, that can support extended attributes. It is not necessary that this file have any attributes, or be prepared in any way, before invoking the runat command. OPERANDS
The following operands are supported: file Any file, including a directory, that can support extended attributes. command The command to be executed in an attribute directory. ERRORS
A non-zero exit status will be returned if runat cannot access the file argument, or the file argument does not support extended attributes. USAGE
See fsattr(5) for a detailed description of extended file attributes. The process context created by the runat command has its current working directory set to the hidden directory containing the file's extended attributes. The parent of this directory (the ".." entry) always refers to the file provided on the command line. As such, it may not be a directory. Therefore, commands (such as pwd) that depend upon the parent entry being well-formed (that is, referring to a direc- tory) may fail. In the absence of the command argument, runat will spawn a new interactive shell with its current working directory set to be the provided file's hidden attribute directory. Notice that some shells (such as zsh and tcsh) are not well behaved when the directory parent is not a directory, as described above. These shells should not be used with runat. EXAMPLES
Example 1: Using runat to list extended attributes on a file example% runat file.1 ls -l example% runat file.1 ls Example 2: Creating extended attributes example% runat file.2 cp /tmp/attrdata attr.1 example% runat file.2 cat /tmp/attrdata > attr.1 Example 3: Copying an attribute from one file to another example% runat file.2 cat attr.1 | runat file.1 "cat > attr.1" Example 4: Using runat to spawn an interactive shell example% runat file.3 /bin/sh This spawns a new shell in the attribute directory for file.3. Notice that the shell will not be able to determine what your current direc- tory is. To leave the attribute directory, either exit the spawned shell or change directory (cd) using an absolute path. Recommended methods for performing basic attribute operations: display runat file ls [options] read runat file cat attribute create/modify runat file cp absolute-file-path attribute delete runat file rm attribute permission changes runat file chmod mode attribute runat file chgrp group attribute runat file chown owner attribute interactive shell runat file /bin/sh or set your $SHELL to /bin/sh and runat file The above list includes commands that are known to work with runat. While many other commands may work, there is no guarantee that any beyond this list will work. Any command that relies on being able to determine its current working directory is likely to fail. Examples of such commands follow: Example 5: Using man in an attribute directory example% runat file.1 man runat getcwd: Not a directory Example 6: Spawning a tcsh shell in an attribute directory example% runat file.3 /usr/bin/tcsh tcsh: Not a directory tcsh: Trying to start from "/home/user" A new tcsh shell has been spawned with the current working directory set to the user's home directory. Example 7: Spawning a zsh shell in an attribute directory example% runat file.3 /usr/bin/zsh example% While the command appears to have worked, zsh has actually just changed the current working directory to '/'. This can be seen by using /bin/pwd: example% /bin/pwd / ENVIRONMENT VARIABLES
SHELL Specifies the command shell to be invoked by runat. EXIT STATUS
The following exit values are returned: 125 The attribute directory of the file referenced by the file argument cannot be accessed. 126 The exec of the provided command argument failed. Otherwise, the exit status returned is the exit status of the shell invoked to execute the provided command. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWcsu | +-----------------------------+-----------------------------+ |CSI |Enabled | +-----------------------------+-----------------------------+ |Interface Stability |Evolving | +-----------------------------+-----------------------------+ SEE ALSO
open(2), attributes(5), fsattr(5) NOTES
It is not always obvious why a command fails in runat when it is unable to determine the current working directory. The errors resulting can be confusing and ambiguous (see the tcsh and zsh examples above). SunOS 5.10 22 Jun 2001 runat(1)
All times are GMT -4. The time now is 08:32 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy