Can NSsbackup create backups on a file server that is locally mounted?

Asked by mfpost on 2009-01-15

I have been trying to use NSsbackup for several days now, but I have yet to get even one good backup. I am running Ubuntu (8.10) on a high end machine. I am trying to backup over the network to a Windows server. I believe the Windows box is using NTFS. I am using ext3. I have the share mounted under /mnt. The folder I am using is several level (directories) down, so the path is "/mnt/Xserver/michael/MyBackup/SQA-mfp/". When I try to use backup now I never get a completed backup. Sometimes It starts to create a backup, but sooner or later it goes to sleep and never wakes up. Some times it never even creates the basic files and folders. Any idea what I am doing wrong?

Question information

English Edit question
nssbackup Edit question
No assignee Edit question
Solved by:
Jean-Peer Lorenz
Last query:
Last reply:
Jean-Peer Lorenz (peer.loz) said : #1


to get an idea what you are doing please give some additional informations about your set-up. Maybe then a problem can be turned out. Please answer the following questions:

1. What version of NSsbackup are you using?
2. How did you install it? Via PPA or from source code...?
3. How do you invoke NSsbackup? Do you use the menu entries and if so, what menu entries? Or from command-line? Are you invoke it as user or with super-user rights?
4. Are you able to access the backup target manually? Is it possible to write to it with the same user rights as you start NSsbackup with (create a file there for instance)?
5. Are you able to create a backup on a local target at all?
6. Does it work to backup very few data e.g. a single file over the network? What means 'it goes to sleep'?
7. Are any messages showed up?
8. Please post the logfile that is written during the backup process. It is stored under '~./local/share/nssbackup' for users and '/var/log' for super-users by default (if you did not changed the log target).

Please read the following pages for upcoming reports and questions:

How to Report Bugs Effectively:
Debugging Procedures:

Thank you in advance.
Best regards. Jean-Peer.

mfpost (mfpost) said : #2

1. I am using version 0.2-0 RC2
2. I installed via PPA
3. From the menu "System>Administration>NSsbackup Configuration Gui" It asks for my password when I open it so I assume it is in super-user mode.
4. Yes I can access and create files both as a user and as super-user
5. I set it to the default folder (/var/backup) but it never created any files there
6. I tried backing up one file to the network share and it failed.
     Goes to sleep means if I run ps and lookup the process ID of the backup process it almost always shows an "S" or "SN". I believe that mean the process is sleeping.
7. No I do not get any messages right now. When I first installed it and tried I would get a message about the backup starting. Now I don't get that.
8. Here is the config it isn't much and I have it set to debug.
NSSBackup 'Default Profile' Logger


2009-01-15 13:40:55,122 - DEBUG - - Validating config file
2009-01-15 13:40:55,122 - INFO - - ConfigManager created with '/etc/nssbackup.conf'
2009-01-15 13:40:55,184 - INFO - - BackupManager created

A little more info. Last week I was trying sbackup and having similar problem. I read about NSsbackup and decided to give it a try. I have not gotten a finished backup from either. My gut feeling is that my problem is not so much a bug as it is a configuration issue or maybe a setup issue.

Thanks for the help

Jean-Peer Lorenz (peer.loz) said : #3


Ok, some more questions:

1. What is your distribution and kernel version?
2. How are your backups invoked? Using schedules (cron) or by pressing the 'Backup now' button withiin the configuration gui?

Moreover, if you know what you are doing, please try the following. If you don't feel so, just answer the questions above and we will look for another way.

* start the application as usual (from the System menu)
* disable any additional profiles within NSsbackup configuration GUI
* create a source directory containg some testing files for backup (don't use important data); for example '~/nssbackup-test/'
* create a backup destination of your choice; you can use the default if you want
* check any of the items in the configuration tool so it doesn't contain some rubbish settings
* save the config file from the configuration gui
* post the content of the config file from the '/etc/nssbackup.conf' here
* start your backup from the configuration gui by pressing the 'Backup now' button

Afterwards, please post the content of the log file here and check the backup destination folder. Were popup messages displayed when backing up?

Good luck. Jean-Peer.

mfpost (mfpost) said : #4

1. My distro is Ubuntu (8.10). My kernel is 2.6.27-9-generic
2. I have setup the cron but it never seems to do anything. The ones I have been telling you about are from using the "Backup Now" button.

file = /var/log/nssbackup.log
level = 10

prefix = /usr


/home/michael/temp/misc/delicious.odt = 1

splitsize = 0
target = /var/backup
format = gzip
mountdir = /mnt/nssbackup
purge = log
maxincrement = 21
lockfile = /var/lock/nssbackup.lock

from = NSsbackup Daemon <email address hidden>


NSSBackup 'test2' Logger


2009-01-16 12:40:37,803 - INFO - - ConfigManager created with '/etc/nssbackup.d/nssbackup-test2.conf'
2009-01-16 12:40:37,804 - INFO - - BackupManager created

I ran the following at a terminal a few seconds after entering the command.
A few seconds later they are all gone but no backup is ever made.
michael@SQA-MFP1:~/.local/share$ ps -auc | grep backup
michael 25040 0.0 0.7 37044 26344 ? S 12:32 0:00 gksu nssbackup-config-gui
root 25041 0.4 0.9 84696 33576 ? Ss 12:32 0:02 python /usr/bin/nssbackup-config-gui
michael 25249 0.5 0.5 36688 17768 ? S 12:41 0:00 gedit file:///var/log/nssbackup.log
michael 25283 0.0 0.0 3236 812 pts/0 S+ 12:42 0:00 grep backup

Jean-Peer Lorenz (peer.loz) said : #5

There is something I don't understand so far: The posted log is created for the profile 'test2', but the config file is (if this file is '/etc/nssbackup.conf') for the default profile.

Maybe I should explain the whole profile feature first:

* There is always a so called default profile that (in this version) cannot be disabled. It configuration file is stored under '/etc/nssbackup.conf' for super-users and '~/.config/nssbackup/nssbackup.conf' for non-root users.
* One can add profiles that are run separately from the default profile (and should not interfere with other profiles; but maybe that's the problem?)
* Each profile got its own configuration file
* These configuration files are stored in '/etc/nssbackup.d/' for super-users, otherwise in '~/.config/nssbackup/nssbackup.d/'
* Active profiles are named 'nssbackup-profilename.conf; disabled profiles are named 'nssbackup-profilename.conf-disable'

Known limitations: I experienced an issue related to the logging and profiles: The problem is, that all profiles use the same name for the log file. Since the user doesn't change the log directory for each profile to a different directory, log files were overwritten during the backup process. You can work around this by 1. not using profiles (at least for debugging purposes) or 2. set the log directory within the configuration tool to different destinations for each profile. Because of that I asked you to disable any additional profiles for the debugging.

I fixed this for RC3 (not released), but the RC2 still contains the issue.

Before we figure out what is the problem in your case, we need debugging output and logs. So, please re-check to use only the default profile for backing up a single file or directory to a local destination. Post the config file and the log file (including file path, name and content).

If an exception is raised before the logging was set up it would be displayed in the shell (but wouldn't be logged into a file of course). As you are obviously familiar to the use of the shell invoke the backup process from the shell with following command:

to run as root - uses the config file from '/etc...' and stores the log in '/var/...':
sudo nssbackupd

to run as non-root - uses the config file from '/.config/nssbackup...' and stores the log in '/.local/share/...':

Check the output for any error messages (and post the whole output it here).

I'm sorry for the trouble and thanks a lot for your effort.

Regards. Jean-Peer

mfpost (mfpost) said : #6

OK, I think we have something a bit more helpful now. I ran the following command from a console (logged in as a user).
"sudo /usr/share/nssbackup/nssbackup /etc/nssbackup.d/nssbackup-test2.conf /var/backups/nssbackup/"

I got the following output.
2009-01-19 10:00:31,735 - DEBUG - - Validating config file
2009-01-19 10:00:31,735 - INFO - - ConfigManager created with '/etc/nssbackup.conf'
2009-01-19 10:00:31,825 - INFO - - BackupManager created
2009-01-19 10:00:31,869 - ERROR - - Launch helper exited with unknown return code 1
2009-01-19 10:00:31,871 - ERROR - - Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/nssbackup/", line 138, in run
  File "/usr/lib/python2.5/site-packages/nssbackup/managers/", line 87, in makeBackup
GError: Launch helper exited with unknown return code 1

2009-01-19 10:00:31,963 - WARNING - - Launch helper exited with unknown return code 1
2009-01-19 10:00:31,964 - ERROR - - Couldn't copy the logfile into the snapshot directory
2009-01-19 10:00:31,966 - INFO - - ConfigManager created with '/etc/nssbackup.d/nssbackup-test2.conf'
2009-01-19 10:00:31,966 - INFO - - BackupManager created
2009-01-19 10:00:31,976 - ERROR - - Launch helper exited with unknown return code 1
2009-01-19 10:00:31,976 - ERROR - - Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/nssbackup/", line 157, in run
  File "/usr/lib/python2.5/site-packages/nssbackup/managers/", line 87, in makeBackup
GError: Launch helper exited with unknown return code 1

2009-01-19 10:00:31,984 - WARNING - - Launch helper exited with unknown return code 1
2009-01-19 10:00:31,985 - ERROR - - Couldn't copy the logfile into the snapshot directory

file = /var/log/nssbackup.log
level = 20

prefix = /usr


/media/ = 0
/var/cache/ = 0
/var/ = 1
/home/ = 1
/var/spool/ = 0
/var/tmp/ = 0
/usr/local/ = 1
/etc/ = 1

target = /var/backup
format = gzip
mountdir = /mnt/nssbackup
purge = log
maxincrement = 7
lockfile = /var/lock/nssbackup.lock



NSSBackup 'test2' Logger


2009-01-19 10:00:31,966 - INFO - - ConfigManager created with '/etc/nssbackup.d/nssbackup-test2.conf'
2009-01-19 10:00:31,966 - INFO - - BackupManager created

 One odd thing I noticed is that if I type in "nssb" and hit the tab key at a console it finds the command and finishes it (I get "nssbackup"). But if I then hit enter I get "bash: nssbackup: command not found".

Jean-Peer Lorenz (peer.loz) said : #7

Ok, this looks good. There are actually 2 problems:

1. The logs didn't contain something useful due to the above described issue. If you'd disable additional profiles, the error would be logged in the log file. Anyway, the log issue is fixed for RC3.

2. The notification module, i.e. the module that displays nice popup windows for user's information, returns an error. This is not directly an issue of NSsbackup but we should handle the error. I will include this in RC3.

Please do the following:

1. Since this is a real bug, create a bug report containing the post of the recent shell output.
2. Please check, if you've installed the package 'notification-daemon'.

At last I want to answer your question concerning the auto-complete within the shell:
There is a script '/usr/share/nssbackup/nssbackup' that is only used by cron daemon and should not be called by users. Furthermore there are the scripts: 'nssbackupd', 'nssbackup-config-gui' and 'nssbackup-restore-gui'. If you type 'nss' and expand it by pressing TAB, the bash is able to expand to 'nssbackup'. From here multiple choices exist. You could type a 'd' TAB to expand to 'nssbackupd' or '-c' TAB to expand to 'nssbackup-config-gui' etc. These scripts are found in the PATH if you press ENTER. So they were find by the shell.

Always read carefully what commands to use ;)

Thank you very much for your effort and check out the announcements. I'll fix it as soon as possible.

Best regards. Jean-Peer.

mfpost (mfpost) said : #8

OK I have opened bug #319294.

I do have notification-daemon installed. It is version "0.3.7-lubuntu15".

Another thing I noticed, that may be a bug, every time I open nssbackup-config-gui the "Do backups" field on the Time tab is set to "custom". I have several times set the "Do backups" to "never" and saved the configuration but when I reopen nssbackup-config-gui that field is set to "custom". Also that field has several embedded carriage returns, I would have expected just the cron command.

The following is from the "Custom cron time definition" field


0 1 * * * root if [ -x '/usr/share/nssbackup' ]; then /usr/share/nssbackup; fi; root if [ -x '/usr/share/nssbackup' ]; then /usr/share/nssbackup; fi;

One last odd thing. I finally figured out what you meant by disabling the profiles, so I did that. Now neither /etc/nssbackup.d/' or '~/.config/nssbackup/nssbackup.d/' have anything in them.

Since I don't know exactly how NSsbackup is supposed to work it is difficult for me to determine what is a bug and what is just my misunderstanding. If either of the above are bugs let me know and I will enter a bug on them.

Best Jean-Peer Lorenz (peer.loz) said : #9

Thank you for your bug report!

One word about profiles:

Disabling profiles is possible using the configuration tool: click on Profile Manager in the Toolbar and then un-check the profiles you don't want to use. You can re-activate them in the same way.

And yes, somebody should create a proper documentation I guess ;)

To the second point: yes, you're right. The decribed behaviour is known but not as expected. If you want, please create a bug report for this issue.

Best regards. Jean-Peer.

(if your question is solved, please mark it as closed, thank you)

mfpost (mfpost) said : #10

Thanks Jean-Peer Lorenz, that solved my question.

lastico (jojo-lastico) said : #11


I get the same log :

2009-01-15 13:40:55,122 - DEBUG - - Validating config file
2009-01-15 13:40:55,122 - INFO - - ConfigManager created with '/etc/nssbackup.conf'
2009-01-15 13:40:55,184 - INFO - - BackupManager created

I found a solution which is particularly surprising. In fact when I install these packets :

exim4 exim4-base exim4-config exim4-daemon-light

the backup was done. The problem is that these packets seem to be related with email and i don't understand why it solves the problem.

If you have an explication ?