FileSet {
Name = XXX
..
File = "\\|c:/windows/system32/cscript.exe //NOLOGO \"C:/Program Files/Bacula/_jobs/filelist.js\""
..
}
// UTF-8 function sToUTF8(sText, srcCharset) { if (!srcCharset) srcCharset = "cp866"; //ADODB.Stream default - Unicode. KOI8-R, cp866, windows-1251 with (new ActiveXObject("ADODB.Stream")) { //http://www.w3schools.com/ado/ado_ref_stream.asp type = 2; //Binary 1, Text 2 (default) mode = 3; //Permissions have not been set 0, Read-only 1, Write-only 2, Read-write 3, //Prevent other read 4, Prevent other write 8, Prevent other open 12, Allow others all 16 charset = "utf-8"; open(); writeText(sText); position = 0; charset = srcCharset; var nPos = 3; return readText().substr(nPos); } } function ShowFolderList(folderspec) { var fso, f, fc; var p; fso = new ActiveXObject("Scripting.FileSystemObject"); f = fso.GetFolder(folderspec); re = /\\/g; // \ -> / fc = new Enumerator(f.Files); for (; !fc.atEnd(); fc.moveNext()) { try { p = fc.item(); r = '' + p; r = r.replace(re, "/"); // replace \ to "/". if (p.Size < 2097152) // 2 MB WScript.Echo(sToUTF8(r)); } catch(e) { } } fc = new Enumerator(f.SubFolders); for (; !fc.atEnd(); fc.moveNext()) { try { ShowFolderList(fc.item()); } catch(e) { } } } ShowFolderList("D:\\Private\\Buhgalteria");
bconsole
server, we select restore
and we specify the corresponding job for recovery.help
- hintfind
- find the file you needls
, dir
- view files in the current directory (directories with subdirectories will be displayed with "+")cd
- change directorymark file
- mark the file in the current locationmark dir/
- mark a separate directory located in the current locationmark *
- mark all files and directories inside the current directory. By the way, TAB also works here.lsmark
- view marked filespwd
- show current directoryestimate
- calculate the size of the recovered filesdone
- finish markfind
, then go to the right directory with cd
and make a mark
for what we need.Source: https://habr.com/ru/post/134924/
All Articles