Gitlab Community Edition Instance
Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
bnachtw
dsmci
Commits
eea7ac98
Commit
eea7ac98
authored
Dec 01, 2021
by
Bjoern Nachtwey
Browse files
move evaluation for profiling to child tread, collect more detailed data
parent
9abe3fbf
Changes
1
Hide whitespace changes
Inline
Side-by-side
perl/dsmci.pl
View file @
eea7ac98
...
...
@@ -66,7 +66,7 @@
# 2020-02-12 0.6.8.1 add trailing "*" to backup path for windows again
# 2021-07-14 0.6.8.2 changed names of log files, adding "dsmci"
# 2021-07-15 0.6.9 identify and remove duplicate entries with "SUN" and "SUY" keeping "SUN" if both are given
# 2021-11-29 0.6.
9-
1 move evaluation for profiling to child tread, collect more data
# 2021-11-29 0.6.1
0
move evaluation for profiling to child tread, collect more
detailed
data
#
# important notes
#
...
...
@@ -478,19 +478,6 @@ open $GLOBALLOGFILE, '<' , $globallog_filename or warn "cannot open global log f
while
(
my
$line
=
<
$GLOBALLOGFILE
>
)
{
# reset variables for profiling
my
$et
;
# elapsed time
my
$oi
;
# objects inspected
my
$ob
;
# objects backed up
my
$ou
;
# objects updated
my
$od
;
# objects deleted
my
$oe
;
# objects expired
my
$of
;
# objects failed
my
$bi
;
# bytes inspected
my
$bt
;
# bytes transfered
my
$dtt
;
# transfer time
my
$rc
=
-
1
;
# return code of child process
#
# identify subdir
#
...
...
@@ -520,8 +507,20 @@ while (my $line = <$GLOBALLOGFILE>)
#
if
(
$line
=~
/#profilinglog/
)
{
printf
"
LINE: %s
\n
",
$line
;
(
undef
,
$et
,
$dir
,
$rc
,
$oi
,
$ob
,
$oi
,
$ob
,
$ou
,
$od
,
$oe
,
$of
,
$bi
,
$bt
,
$dtt
)
=
split
'
;
',
$line
;
# reset variables for profiling
my
$et
;
# elapsed time
my
$oi
;
# objects inspected
my
$ob
;
# objects backed up
my
$ou
;
# objects updated
my
$od
;
# objects deleted
my
$oe
;
# objects expired
my
$of
;
# objects failed
my
$bi
;
# bytes inspected
my
$bt
;
# bytes transfered
my
$dtt
;
# transfer time
my
$rc
=
-
1
;
# return code of child process
(
undef
,
$et
,
$dir
,
$rc
,
$oi
,
$ob
,
$ou
,
$od
,
$oe
,
$of
,
$bi
,
$bt
,
$dtt
)
=
split
'
;
',
$line
;
$total_elaped_time
+=
$et
;
# "Summary on elapsed time"
$total_objects_inspected
+=
$oi
;
# "Total number of objects inspected"
...
...
@@ -534,9 +533,10 @@ printf "LINE: %s\n", $line;
$total_bytes_transferred
+=
$bt
;
# "Total number of bytes transferred"
$total_transfer_time
+=
$dtt
;
# "Total transfer time"
my
$tline
=
sprintf
"
%10.10d ; %s ; %
4
d ;
% 15.15d ; % 15.15d ; % 15.15d ; % 15.15d ; % 15.15d ; % 15.15
d ; %
15.3
lf ; %
15.3
lf; %
15.3
lf
",
my
$tline
=
sprintf
"
%10.10d ; %s ; %d ;
%d ; %d ; %d ; %d ; %d ; %
d ; %lf ; %lf; %lf
",
$et
,
$dir
,
$rc
,
$oi
,
$ob
,
$ou
,
$od
,
$oe
,
$of
,
$bi
,
$bt
,
$dtt
;
printf
"
TLINE: %s
\n
",
$tline
;
# need to figure out why I implemented this vvv
if
(
$actpathdir
ne
$startpath
)
{
push
@proftimes
,
$tline
;
...
...
@@ -914,7 +914,7 @@ sub fork_backup_threads
}
}
# print line for profiling log
printf
$GLOBALLOGFILE
"
#profilinglog ;
%d ; %s ; %d ; %d ; %d ; %d ; %d ; %d ; %d ; %.3lf ; %.3lf; %.3lf
",
printf
$GLOBALLOGFILE
"
#profilinglog ; %d ; %s ; %d ; %d ; %d ; %d ; %d ; %d ; %d ; %.3lf ; %.3lf; %.3lf
",
$et
,
$dir
,
$childreturnvalue
,
$oi
,
$ob
,
$ou
,
$od
,
$oe
,
$of
,
$bi
,
$bt
,
$dtt
;
if
(
$debugmode
==
2
)
{
...
...
Write
Preview
Markdown
is supported
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