bugstoreBackup - Bugs: bug #46605, exceptDirs being checked after...

 
 

bug #46605: exceptDirs being checked after mount with precommand doesn't work

Submitted by:  None
Submitted on:  Fri 04 Dec 2015 08:53:55 PM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: None
Privacy: PublicAssigned to: None
Open/Closed: Open

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Wed 24 May 2017 08:18:58 AM UTC, comment #4:

Hi,

I found another flaw in that context.
I use precommand to mount a directory tree via sshfs.
As suggested by comment #2: I moved section '# precommand ausführen' directly in front of section '# initialise include, exclude and checkBlocks rules'.
However, sourceDir is checked prior mounting with precommand which raises errors about an unexisting sourceDir.

I moved the section '# precommand ausführen' directly after the section which IMHO creates prLog.
The code is now:

$main::__prLog = $prLog; # used in rules
$prLog->fork($req);

(@main::cleanup) = ($prLog, 1);

my (%suppressWarning);
{
my $s;
foreach $s (@$suppressWarning)
{
$suppressWarning{$s} = 1;
}
}

#
# precommand ausführen
#
...

Are there any sideeffects to expect?

Anonymous
Sat 05 Dec 2015 03:51:03 PM UTC, comment #3:

I see no reason why your workaround should not work. I just included the change in my (not yet ready) candidate for the version.

Maybe this description shows how to mount via fstab:
https://wiki.archlinux.org/index.php/Sshfs
(But I didn't check in detail, so maybe I'm wrong.)

Regards, Heinz-Josef

Heinz-Josef Claes <hjclaes>
Project Administrator
Sat 05 Dec 2015 09:10:58 AM UTC, comment #2:

Hi,

It's a pitty if this would only works with an auxiliary script, since this means I have to do a major rework of my cronjobs that call storeBackup. Also storeBackupMount needs root access to modify /etc/fstab.

My workaround now is to edit storeBackup.pl and place section
before section

With this small modification precommands are executed earlier and all mount are present when storeBackup checks for include/exclude files. And: not need for auxiliary scripts.

Does this change have any side-effects?

Anonymous
Fri 04 Dec 2015 11:26:45 PM UTC, comment #1:

Hi,

at least for the second part (having a mountcommand) there is already a solution. You might want to take a look at storeBackupMount.pl.
http://www.nongnu.org/storebackup/en/node36.html

Anonymous
Fri 04 Dec 2015 08:53:55 PM UTC, original submission:

I use precommand to mount a sshfs. Works fine until I tried to exclude a folder with exceptDirs. The error is:
<pre>
ERROR 2015.12.04 21:46:26 21500 no directory resulting from exceptDir pattern <vdr>
</pre>
Where "vdr" is the folder I want to exclude.

expectDirs throws an error that a folder can not be found prior the filesystem is mounted. Thus the folder is never there. IMHO this should be interchanged to execute precommand prior expectdir. If this would have some sideeffect, maybe we could introduce a "mountcommand" that is executed prior all folder/files checks.

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by hjclaes (Posted a comment)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    No Changes Have Been Made to This Item

    Back to the top


    Powered by Savane 3.1-cleanup1