Re: Problems with tar (tcllib)



On Feb 7, 2:22 pm, "Stéphane A." <stephanearn...@xxxxxxxx> wrote:
On 5 fév, 23:47, Keith.Pick...@xxxxxxxxx wrote:



Hello All:
I have a simple script that uses the tcllibtarcommand. Ittar
creates atarfile containing a directory. The directory contains
subdirectories. Each of those sub-directories contain the following
sub-directories:

exec/
export/
server/
lib/

The directory tree looks this way:

devdir_4.1/
subdir1/
exec/
bin/
file1
file2
file3

export/
file1
file2
file3

lib/
file1
file2
file3

server/
bin/
file1

subdir2/
exec/
bin/
file1
file2
file3
export/
file1
file2
file3

lib/
file1
file2
file3

server/
bin/
file1

... etc

The problem I am having is that it is not archiving the exec/
directory. The export/ directory does contain some of the same
executables that are located in the exec/ directory. But, when you do
atartvf on the tarfile that is created, there is one instance of the
exec directory in one of the subdirs, but none of the others. It's as
if the exec/ directory gets passed over.

Here is my script:

#!/usr/bin/tclsh

lappend auto_path /export/kdp/dev/tcl/lib
package requiretar

::tar::create tarball.tardevdir_4.1

Any help would be greatly appreciated.

Maybe permissions were not set right?
Hope it helps.

Stéphane

I received a response via e-mail from Aaron F. requesting the fileset
in question that is being tarred. I couldn't provide original files
because of company proprietary issues, but I dummied up a set of files
with similar directory structure. When I ran my script against that,
things worked perfectly. That kind of tells me I do have a
permissions problem. Even though I put a routine in the script to
change permissions to 777 (just for the fun of it), it didn't seem to
make a difference. Before I put the permission change in the script,
the permissions on the exec/ folder(the one giving all the problems)
were rwxr-xr-x (755). So, i'm at a loss as to why there is a
problem. I was able to get past my problem using an exec command
(just an extra line of code). However, I will post to the tcllib
project site as a bug. Incidentally, i'm using tcllib version 1.9.
Thanks to all for the responses. I will return and report any
solutions to the problem.

.



Relevant Pages

  • Re: Need Help
    ... eg: file1, file2, file3 etc ... into, max 5-6, chunk files and then loading these chunk files into ...
    (comp.unix.shell)
  • RE: [SLE] File Counts

    (SuSE)
  • Re: fopen() with full path affecting subsequent fopen calls
    ... Normally I would expect file2 to be written in the same place as it ... did when I didn't use the full path for file1. ... as well as file3 (which ... It's very likely a "current working directory" problem of some sort, ...
    (comp.lang.c)
  • Re: Need Help
    ... eg: file1, file2, file3 etc ... This means that if script is executing file1, ...
    (comp.unix.shell)
  • Re: Need help comparing lines in two files
    ... With the suggested changes, my foreach loop ... script now works as I hoped it would. ... will either match File1, or have new email addresses in them. ... my $file2; ...
    (perl.beginners)