BigNerd95 / RouterOS-Backup-Tools

Tools to encrypt/decrypt and pack/unpack RouterOS v6.13+ backup files
GNU Lesser General Public License v3.0
280 stars 101 forks source link

um4.dat file missing error #25

Open g3d12 opened 1 year ago

g3d12 commented 1 year ago

Hi Can you please help me with resetting password process. I got unfortuanlety such an error: Traceback (most recent call last): File "/home/kabs/Pobrane/mtkk/RouterOS-Backup-Tools/ROSbackup.py", line 595, in main() File "/home/kabs/Pobrane/mtkk/RouterOS-Backup-Tools/ROSbackup.py", line 590, in main reset_password(args.input, args.default, args.output) File "/home/kabs/Pobrane/mtkk/RouterOS-Backup-Tools/ROSbackup.py", line 455, in reset_password shutil.copy(temp_dir+'/default/'+file, temp_dir+'/original/'+file) File "/usr/lib/python3.10/shutil.py", line 417, in copy copyfile(src, dst, follow_symlinks=follow_symlinks) File "/usr/lib/python3.10/shutil.py", line 254, in copyfile with open(src, 'rb') as fsrc: FileNotFoundError: [Errno 2] No such file or directory: './tempDir/default/um4.dat'

kaulpa commented 1 year ago

Hi there

I had the same issue and was able to solve it by a small modification of the script. Because the um4.* files aren't available in my backups, I removed them form the overwrite_list at line 449. In my case it looks now this way. "overwrite_list = ['user.dat','user.idx']"

So I was able to run the tool and reset my password.

Wit4r7 commented 7 months ago

Thank you so much for this, :) Just saved me couple of hours to configure my router agin!