Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Oleg Borisenko
tapebackup
Commits
c213421f
Commit
c213421f
authored
Sep 06, 2021
by
Oleg Borisenko
Browse files
Error levels slightly changed to be not confusing
parent
1ca9b293
Changes
3
Hide whitespace changes
Inline
Side-by-side
tapebackup/models/restorehistory.py
View file @
c213421f
...
...
@@ -42,7 +42,7 @@ class RestoreHistory(Base):
log
.
info
(
"Restored successfully %s"
,
restoring
.
relative_path
)
return
True
else
:
log
.
warning
(
"Restoration %s failed, status %d"
,
restoring
.
relative_path
,
copy_result
)
log
.
error
(
"Restoration %s failed, status %d"
,
restoring
.
relative_path
,
copy_result
)
return
False
Index
(
'restore_history_index'
,
RestoreHistory
.
status
,
unique
=
False
)
tapebackup/scripts/restore_daemon.py
View file @
c213421f
...
...
@@ -32,9 +32,9 @@ def restore_copy_process(mountpoint, f, dbsession, loop):
f
.
status
=
True
f
.
restored_at_time
=
datetime
.
datetime
.
now
()
elif
copy_result
!=
0
:
log
.
warning
(
"File % restore failed"
,
f
.
file_to_restore
.
relative_path
)
log
.
error
(
"File % restore failed"
,
f
.
file_to_restore
.
relative_path
)
else
:
log
.
warning
(
"File % restored; checksum failed"
,
f
.
file_to_restore
.
relative_path
)
log
.
error
(
"File % restored; checksum failed"
,
f
.
file_to_restore
.
relative_path
)
return
...
...
tapebackup/views/default.py
View file @
c213421f
...
...
@@ -231,7 +231,7 @@ def file_filter(request):
if
tape
.
location
==
'Inside tape library'
:
tapes_inside_list
.
append
(
tape
.
label
)
else
:
tapes_outside
.
append
(
"Кассета с номером %s находится в %s и файлы с нее **НЕ БУДУТ** восстановлены"
%
tape
.
label
,
tape
.
location
)
tapes_outside
.
append
(
"Кассета с номером %s находится в %s и файлы с нее **НЕ БУДУТ** восстановлены"
%
(
tape
.
label
,
tape
.
location
)
)
tapes_inside
=
[
"Кассеты с номерами %s находятся внутри ленточной библиотеки и могут быть использованы для восстановления."
\
%
" "
.
join
(
str
(
x
)
for
x
in
tapes_inside_list
)]
tapes_status
=
tapes_inside
+
tapes_outside
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment