Skip to content

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
martialblog committed Jul 7, 2023
1 parent f30e5de commit ad1dcd6
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 17 deletions.
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,13 +74,13 @@ options:
Check if a job is runing longar than 7 days (default value):

```bash
check_bareos.py -u bareos -d p job -rt -t 4 -st R -w 1 -c 4
check_bareos.py job -rt -t 4 -st R -w 1 -c 4
```

Check how much jobs are in the wating status:

```bash
check_bareos.py -u bareos -d p job -js -w 50 -c 100
check_bareos.py job -js -w 50 -c 100
```

## Tape
Expand Down Expand Up @@ -113,19 +113,19 @@ options:
Check how much tapes are empty in the storage:

```bash
check_bareos.py -u bareos -d p tape -e -w 15 -c 10
check_bareos.py tape -e -w 15 -c 10
```

Check how much tapes are expired:

```
check_bareos.py -u bareos -d p tape -ex
check_bareos.py tape -ex
```

Check how much tapes will expire in the next 14 days;

```bash
check_bareos.py -u bareos -d p tape -wex -t 14 -w 10 -c 5
check_bareos.py tape -wex -t 14 -w 10 -c 5
```

## Status
Expand Down Expand Up @@ -164,35 +164,35 @@ options:
Check total size of all backups:

```bash
check_bareos.py -u bareos -d p status -b -w 400 -c 500
check_bareos.py status -b -w 400 -c 500
```

Check total size of all full backups:

```bash
check_bareos.py -u bareos -d p status -b -f -w 400 -c 500
check_bareos.py status -b -f -w 400 -c 500
```

Check total size of all diff backups:

```bash
check_bareos.py -u bareos -d p status -b -d -w 400 -c 500
check_bareos.py status -b -d -w 400 -c 500
```

Check total size of all inc backups:

```bash
check_bareos.py -u bareos -d p status -b -i -w 400 -c 500
check_bareos.py status -b -i -w 400 -c 500
```

Check if a full backup has 0 Bytes(is Empty) and trigger warning it is at least 1 and trigger ciritcal if more than 5 are empty:

```bash
check_bareos.py -u bareos -d p status -e -f -w 1 -c 5
check_bareos.py status -e -f -w 1 -c 5
```

Check if a diff/inc backup is larger than 2 TB (default value) and trigger warning it is at least 1 and trigger ciritcal if more than 5 are empty:

```bash
check_bareos.py -u bareos -d p status -o -d -i -w 1 -c 5
check_bareos.py status -o -d -i -w 1 -c 5
```
12 changes: 6 additions & 6 deletions check_bareos.py
Original file line number Diff line number Diff line change
Expand Up @@ -560,8 +560,8 @@ def commandline(args):
jobParser.add_argument('-n', '--name', dest='name', action='store', help='Name of the job')
jobParser.add_argument('-t', '--time', dest='time', action='store', help='Time in days (default=7 days)')
jobParser.add_argument('-u', '--unit', dest='unit', choices=['GB', 'TB', 'PB'], default='TB', help='display unit')
jobParser.add_argument('-w', '--warning', dest='warning', action='store', help='Warning value', default=5)
jobParser.add_argument('-c', '--critical', dest='critical', action='store', help='Critical value', default=10)
jobParser.add_argument('-w', '--warning', dest='warning', action='store', help='Warning threshold', default=5)
jobParser.add_argument('-c', '--critical', dest='critical', action='store', help='Critical threshold', default=10)
jobParser.add_argument('-st', '--state', dest='state', choices=JOBSTATES.keys(), default='C', help='Bareos Job State [default=C]')
jobParser.add_argument('-f', '--full', dest='full', action='store_true', help='Backup kind full')
jobParser.add_argument('-i', '--inc', dest='inc', action='store_true', help='Backup kind inc')
Expand All @@ -575,8 +575,8 @@ def commandline(args):
tapeGroup.add_argument('-ex', '--expiredTapes', dest='expiredTapes', action='store_true', help='Count how much tapes are expired')
tapeGroup.add_argument('-wex', '--willExpire', dest='willExpire', action='store_true', help='Count how much tapes are will expire in n day')
tapeGroup.add_argument('-r', '--replaceTapes', dest='replaceTapes', action='store_true', help='Count how much tapes should by replaced')
tapeParser.add_argument('-w', '--warning', dest='warning', action='store', help='Warning value', default=5)
tapeParser.add_argument('-c', '--critical', dest='critical', action='store', help='Critical value', default=10)
tapeParser.add_argument('-w', '--warning', dest='warning', action='store', help='Warning threshold', default=5)
tapeParser.add_argument('-c', '--critical', dest='critical', action='store', help='Critical threshold', default=10)
tapeParser.add_argument('-m', '--mounts', dest='mounts', action='store', help='Amout of allowed mounts for a tape [used for replace tapes]', default=200)
tapeParser.add_argument('-t', '--time', dest='time', action='store', help='Time in days (default=7 days)', default=7)

Expand All @@ -591,8 +591,8 @@ def commandline(args):
statusParser.add_argument('-i', '--inc', dest='inc', action='store_true', help='Backup kind inc')
statusParser.add_argument('-d', '--diff', dest='diff', action='store_true', help='Backup kind diff')
statusParser.add_argument('-t', '--time', dest='time', action='store', help='Time in days')
statusParser.add_argument('-w', '--warning', dest='warning', action='store', help='Warning value [default=5]', default=5)
statusParser.add_argument('-c', '--critical', dest='critical', action='store', help='Critical value [default=10]', default=10)
statusParser.add_argument('-w', '--warning', dest='warning', action='store', help='Warning threshold [default=5]', default="5")
statusParser.add_argument('-c', '--critical', dest='critical', action='store', help='Critical threshold [default=10]', default="10")
statusParser.add_argument('-s', '--size', dest='size', action='store', help='Border value for oversized backups [default=2]', default=2)
statusParser.add_argument('-u', '--unit', dest='unit', choices=['MB', 'GB', 'TB', 'PB', 'EB'], default='TB', help='display unit [default=TB]')

Expand Down

0 comments on commit ad1dcd6

Please sign in to comment.