Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
backupninja
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Liberate
backupninja
Commits
8db80421
Commit
8db80421
authored
10 years ago
by
intrigeri
Browse files
Options
Downloads
Patches
Plain Diff
Fix indentation in sys handler.
Thanks to Jools Wills <jools@oxfordinspire.co.uk> for the patch.
parent
14eed7f7
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
handlers/sys.in
+23
-23
23 additions, 23 deletions
handlers/sys.in
with
23 additions
and
23 deletions
handlers/sys.in
+
23
−
23
View file @
8db80421
...
...
@@ -203,7 +203,7 @@ if [ "$packages" == "yes" ]; then
# don't expand * since it can be used in $packagemgroptions
set
-o
noglob
debug
"
$VSERVER
$vserver
exec
$packagemgr
$packagemgroptions
>
$VROOTDIR
/
$vserver$packagesfile
"
$VSERVER
$vserver
exec
$packagemgr
$packagemgroptions
>
$VROOTDIR
/
$vserver$packagesfile
||
fatal
"can not save
$packagemgr
info to
$packagesfile
"
$VSERVER
$vserver
exec
$packagemgr
$packagemgroptions
>
$VROOTDIR
/
$vserver$packagesfile
||
fatal
"can not save
$packagemgr
info to
$packagesfile
"
set
+o noglob
fi
# is $debconfgetselections available inside $vserver ?
...
...
@@ -271,7 +271,7 @@ catiffile () {
echo
$DASHES
>>
$sysreportfile
for
file
in
`
find
$1
-maxdepth
3
-noleaf
-type
f
`
do
catiffile
$file
catiffile
$file
done
fi
echo
$DASHES
>>
$sysreportfile
...
...
@@ -558,14 +558,14 @@ fi
if
[
"
$partitions
"
==
"yes"
]
;
then
if
[
"
$dosfdisk
"
==
"yes"
]
;
then
if
[
!
-x
"
$SFDISK
"
]
;
then
warning
"can't find sfdisk, skipping sfdisk report."
partitions
=
"no"
warning
"can't find sfdisk, skipping sfdisk report."
partitions
=
"no"
fi
fi
if
[
"
$dohwinfo
"
==
"yes"
]
;
then
if
[
!
-x
"
$HWINFO
"
]
;
then
warning
"can't find hwinfo, skipping partition report."
partitions
=
"no"
warning
"can't find hwinfo, skipping partition report."
partitions
=
"no"
fi
fi
fi
...
...
@@ -587,15 +587,15 @@ fi
if
[
"
$hardware
"
==
"yes"
]
;
then
if
[
"
$dohwinfo
"
==
"yes"
]
;
then
if
[
-f
$hardwarefile
]
;
then
rm
$hardwarefile
rm
$hardwarefile
fi
touch
$hardwarefile
echo
-e
"
\n\n
====================== summary ======================
\n
"
>>
$hardwarefile
debug
"
$HWINFO
--short --cpu --network --disk --pci >>
$hardwarefile
"
$HWINFO
--short
--cpu
--network
--disk
--pci
>>
$hardwarefile
for
flag
in
cpu network bios pci
;
do
echo
-e
"
\n\n
======================
$flag
======================
\n
"
>>
$hardwarefile
$HWINFO
--
$flag
>>
$hardwarefile
echo
-e
"
\n\n
======================
$flag
======================
\n
"
>>
$hardwarefile
$HWINFO
--
$flag
>>
$hardwarefile
done
fi
fi
...
...
@@ -608,21 +608,21 @@ fi
if
[
"
$partitions
"
==
"yes"
]
;
then
if
[
"
$dosfdisk
"
==
"yes"
]
;
then
devices
=
`
LC_ALL
=
C
$SFDISK
-l
2>/dev/null |
grep
"^Disk /dev"
| @AWK@
'{print $2}'
|
cut
-d
:
-f1
`
if
[
"
$devices
"
==
""
]
;
then
warning
"No harddisks found"
fi
for
dev
in
$devices
;
do
debug
"
$SFDISK
will try to backup partition tables for device
$dev
"
[
-b
$dev
]
||
continue
label
=
${
dev
#/dev/
}
label
=
${
label
//\//-
}
outputfile
=
${
partitionsfile
//__star__/
$label
}
debug
"
$SFDISK
$sfdisk_options
-d
$dev
>
$outputfile
2>/dev/null"
$SFDISK
$sfdisk_options
-d
$dev
>
$outputfile
2>/dev/null
if
[
$?
-ne
0
]
;
then
warning
"The partition table for
$dev
could not be saved."
if
[
"
$devices
"
==
""
]
;
then
warning
"No harddisks found"
fi
done
for
dev
in
$devices
;
do
debug
"
$SFDISK
will try to backup partition tables for device
$dev
"
[
-b
$dev
]
||
continue
label
=
${
dev
#/dev/
}
label
=
${
label
//\//-
}
outputfile
=
${
partitionsfile
//__star__/
$label
}
debug
"
$SFDISK
$sfdisk_options
-d
$dev
>
$outputfile
2>/dev/null"
$SFDISK
$sfdisk_options
-d
$dev
>
$outputfile
2>/dev/null
if
[
$?
-ne
0
]
;
then
warning
"The partition table for
$dev
could not be saved."
fi
done
fi
if
[
"
$dohwinfo
"
==
"yes"
]
;
then
debug
"Using
$HWINFO
to get all available disk information"
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment