[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#392217: marked as done (jailtool not handle PRUNE and GRAFT properly and rsync failed)



Your message dated Sun, 18 Nov 2018 17:40:57 +0000
with message-id <[🔎] E1gOR45-000Ds4-2l@fasolo.debian.org>
and subject line Bug#913763: Removed package(s) from unstable
has caused the Debian Bug report #392217,
regarding jailtool not handle PRUNE and GRAFT properly and rsync failed
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
392217: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=392217
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: jailtool
Version: 1.1-3

This very usefull tool have a trial bug.

- The script don't handle properly PRUNE and GRAFT statement because the
code use two time the same variables in the same scope... (See patch
below)

- If your jail configuration have the following statement:

PRUNE=/usr/share/timezone
GRAFT=/usr/share/timezone/GMT
GRAFT=/usr/share/timezone/posix/GMT

Rsync will complain because /usr/share/timezone doesn't exists.

There is the patch

--- update-jail-orig	2006-10-10 18:25:57.894197424 +0000
+++ update-jail-new	2006-10-10 19:20:34.041908544 +0000
@@ -19,6 +19,9 @@
 #   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307  USA
 #
 
+require File::Basename;
+require File::Path;
+
 use strict;
 
 sub collectDirs {
@@ -162,11 +165,11 @@
 FILES: foreach my $file (@files) {
    foreach my $prune (@prune) {
       if (substr($file, 0, length($prune)) eq $prune) {
-         my $graft;
+         my $graft_flag = 0;
          foreach my $graft (@graft) {
-	    $graft ||= (substr($file, 0, length($graft)) eq $graft);
+	    $graft_flag ||= (substr($file, 0, length($graft)) eq
$graft);
 	 }
-         next FILES if !$graft;
+         next FILES if !$graft_flag;
       }
    }
    if (-d $file) {
@@ -184,6 +187,15 @@
       if ($simulate) {
          print "SIMUL: syncing $file with $target$file\n";
       } else {
+		 my $dir_path = File::Basename::dirname($target .
$file);
+		 if ( ! -d $dir_path)
+		 {
+			my @new_dirs = File::Path::mkpath($dir_path, 0,
0755) or 
+			 	die "Failed to create path $dir_path";
+			for my $new_dir (@new_dirs) {
+				print "Create new directory path
$new_dir\n";
+			}
+		 }
          system "rsync -qlpogtD $file $target$file";
       }
    }
@@ -216,6 +228,15 @@
       if ($simulate) {
          print "SIMUL: syncing $file with $target$file\n";
       } else {
+		 my $dir_path = File::Basename::dirname($target .
$file);
+		 if ( ! -d $dir_path)
+		 {
+			my @new_dirs = File::Path::mkpath($dir_path, 0,
0755) or 
+			 	die "Failed to create path $dir_path";
+			for my $new_dir (@new_dirs) {
+				print "Create new directory path
$new_dir\n";
+			}
+		 }
          system "rsync -qlpogtD $file $target$file";
       }
    }


Eric Girard
UNIX Administrator
Gameloft::Global Network Services


--- End Message ---
--- Begin Message ---
Version: 1.1-6+rm

Dear submitter,

as the package jailtool has just been removed from the Debian archive
unstable we hereby close the associated bug reports.  We are sorry
that we couldn't deal with your issue properly.

For details on the removal, please see https://bugs.debian.org/913763

The version of this package that was in Debian prior to this removal
can still be found using http://snapshot.debian.org/.

This message was generated automatically; if you believe that there is
a problem with it please contact the archive administrators by mailing
ftpmaster@ftp-master.debian.org.

Debian distribution maintenance software
pp.
Scott Kitterman (the ftpmaster behind the curtain)

--- End Message ---

Reply to: