- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Using tar command
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-29-2002 02:21 PM
05-29-2002 02:21 PM
I have a question regarding about create a tar file using a tar command. I am using HP-UX 10.20. When I execute the tar command by manual,it is worked:
tar cvf BK.tar cantata marcato rhapsody
but when I put in the script, it does not work and send the error message is:
./ASIBk[29]: /usr/bin/tar: arg list too long
-ASIBk is the script name
-29 is the line number
-cantata, marcato, and rhapsody are the directories that I would like to tar.
Would you help me with this problem. Thank you.
Regards,
Jennifer Lam.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-29-2002 02:39 PM
05-29-2002 02:39 PM
Re: Using tar command
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-29-2002 05:09 PM
05-29-2002 05:09 PM
Re: Using tar command
Can you show us your script?
You could get the "argument list too long" error if you had used wildcards in your script i.e.:
tar cvf BK.tar cantata/* marcato/* rhapsody/*
This is because the wildcars are expanded by the shell interpreter before passing on to the tar command.
To fix that, use the same syntax you did on the command line, that is:
tar cvf BK.tar cantata marcato rhapsody
Hope this helps. Regards.
Steven Sim Kok Leong
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-29-2002 05:26 PM
05-29-2002 05:26 PM
Re: Using tar command
There are couple of things you could do. You could try and include './' in front of the directories names in your script. The real answer is to change the 'large_ncargs_enabled' parameter in your kernel to the value of '1'
The default is 20478 bytes, (value 0) but you can increase this value to 2048000 by changing the kernel parameter.
You can use the command 'getconf ARG_MAX'
$ getconf ARG_MAX
20478
HTH
~Michael~
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-29-2002 08:20 PM
05-29-2002 08:20 PM
Re: Using tar command
the problem is * is intrepeted as say x no . of lines , now trar can have only a fix argument which by default is 20478 , even any other operation using this * like rm -i will not be possible as it will again complin about it , solution is to either increse the arg count or may be try to split the list like
tar cvf abc,tar < directory 1 >
tar uvf abc.tar
tar uvf abc.tar
Manoj Srivastava
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-29-2002 11:48 PM
05-29-2002 11:48 PM
Re: Using tar command
tar uvf abc.tar
tar uvf abc.tar
-niraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-31-2002 12:32 PM
05-31-2002 12:32 PM
Re: Using tar command
I am running HP-UX 10.20.
I would like to know how or what file do you get in to change the 'large_ncargs_enable' parameter in kernel to 1?
I did try the following:
- I type in the command
$ getconf ARG_MAX (I get 20478)
20478
- I did try to get in SAM to configuration, but I don't see the parameter
'large_ncargs_enable'
Would you help me. Thank you.
Regards,
Jennifer Lam.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-31-2002 12:56 PM
05-31-2002 12:56 PM
SolutionTo be able to see this parameter you need to first install patch PHKL_16410. See the details below. Once you have installed the patch you should be able to see the parameter within SAM.
HTH
Michael
Here is the details from the Technical Knowledge Base document:
PROBLEM
I am getting errors like:
Arg list too long
when I issue certain commands, such as 'find'. What is causing the
error and how can I make it go away?
CONFIGURATION
Operating System - HP-UX
Version - 10.20
RESOLUTION
The 'arg list too long' error occurs when you exceed the maximum
length of arguments that can be passed to a command.
The default is 20478 bytes, but you can increase this value to 2048000
by setting the kernel parameter 'large_ncargs_enabled = 1' (default is 0).
You can execute 'getconf ARG_MAX' to find out if 'large_ncargs_enabled'
is set to 1 or 0. For example:
$ getconf ARG_MAX
20478
If you receive 20478 when you execute the command, recompile the kernel
with 'large_ncargs_enabled = 1' to resolve the error.
Note that for HP-UX 11.0 systems, the limit is set to the larger value
by default, and the large_ncargs_enabled kernel tunable is not needed.
Note that patch:
PHKL_16410
s800 10.20 LVM/UFS/NDDB/flkmgr/VxFS,DMAPI/PCI/SCSI/MO/dump
enables this kernel parameter, so you may need to install it if you
do not already have it or a superseding patch installed already.
Note: This patch, as with any patch, may be superseded. Please
check for the latest patch at the Electronic Support Center
(ESC) by using either of these web sites:
http://us-support.external.hp.com
http://europe-support.external.hp.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-31-2002 01:08 PM
05-31-2002 01:08 PM
Re: Using tar command
First, you will need to have patch PHKL_16751 installed.
Then will need to add a line to 'stand/system' in the tunable parameters list that reads:
large_ncargs_enabled 1
Next, you can use SAM and regenerate your kernel. Upon reboot, you should have the larger environement space.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-31-2002 01:15 PM
05-31-2002 01:15 PM
Re: Using tar command
Do *not* use PHKL_16410 as you will see from the Patch Database. You will note the critcal alert, "Patch PHKL_15959 introduced a problem...while the problem was introduced in PHKL_15959, it is also present in superseding patches PHKL_16388, PHKL_16410...".
Use the successor patch PHKL_16751.
Regards!
...JRF...