diff --git a/python/samba/tdb_util.py b/python/samba/tdb_util.py index d967434..01fdb44 100644 --- a/python/samba/tdb_util.py +++ b/python/samba/tdb_util.py @@ -32,6 +32,10 @@ def tdb_copy(file1, file2): if os.path.exists(toolpath): break + if not os.path.exists(toolpath): + raise Exception("Error I could not find tdbbackup maybe you need to" + " install tdb-tools?") + tdbbackup_cmd = [toolpath, "-s", ".copy.tdb", file1] status = subprocess.call(tdbbackup_cmd, close_fds=True, shell=False)