View Issue Details

IDProjectCategoryView StatusLast Update
0000897bareos-core[All Projects] webuipublic2019-04-11 12:01
ReporterrightmiremAssigned Tofrank 
PriorityhighSeveritymajorReproducibilityhave not tried
Status confirmedResolutionopen 
PlatformIntelOSDebian Jessie 8OS Version8
Product Version17.2.4 
Fixed in Version 
Summary0000897: Webui dashboard cannot access catalog data (input just spinning)
DescriptionMaybe related to issue:
https://bugs.bareos.org/view.php?id=896

After updating to Bareos 17.2.4 (including the webui), and a server restart ... opening the webui shows no data.

Jobstaus area (Running, Waiting, Successful, Failed) simply spin.

"Job Totals" area shows "No matching records found"

"Most recent job status per job name" shows "No matching records found"

Catalog is intact and bconsole can backup and restore normally.

Additional Informationroot@servername> apt list --installed | grep bareos

WARNING: apt does not have a stable CLI interface yet. Use with caution in scripts.

bareos/unknown,now 17.2.4-9.1 amd64 [installed]
bareos-bconsole/unknown,now 17.2.4-9.1 amd64 [installed,automatic]
bareos-client/unknown,now 17.2.4-9.1 amd64 [installed,automatic]
bareos-common/unknown,now 17.2.4-9.1 amd64 [installed,automatic]
bareos-database-common/unknown,now 17.2.4-9.1 amd64 [installed,automatic]
bareos-database-postgresql/unknown,now 17.2.4-9.1 amd64 [installed,automatic]
bareos-database-tools/unknown,now 17.2.4-9.1 amd64 [installed,automatic]
bareos-director/unknown,now 17.2.4-9.1 amd64 [installed,automatic]
bareos-docs/unknown,now 17.2.4-14.1 all [installed]
bareos-filedaemon/unknown,now 17.2.4-9.1 amd64 [installed,automatic]
bareos-storage/unknown,now 17.2.4-9.1 amd64 [installed,automatic]
bareos-storage-tape/unknown,now 17.2.4-9.1 amd64 [installed]
bareos-tools/unknown,now 17.2.4-9.1 amd64 [installed]
bareos-traymonitor/unknown,now 17.2.4-9.1 amd64 [installed,automatic]
bareos-webui/unknown,now 17.2.4-15.1 all [installed]

TagsNo tags attached.
bareos-master: impact
bareos-master: action
bareos-19.2: impact
bareos-19.2: action
bareos-18.2: impact
bareos-18.2: action
bareos-17.2: impact
bareos-17.2: action
bareos-16.2: impact
bareos-16.2: action
bareos-15.2: impact
bareos-15.2: action
bareos-14.2: impact
bareos-14.2: action
bareos-13.2: impact
bareos-13.2: action
bareos-12.4: impact
bareos-12.4: action

Activities

rightmirem

rightmirem

2018-01-26 14:38

reporter  

rightmirem

rightmirem

2018-01-26 14:55

reporter   ~0002884

"bareos-audit.log" is also repeating ...

26-Jan 14:53 servername-dir: Console [admin] from [127.0.0.1] cmdline llist jobs jobstatus=R jobname="" limit=1000 offset=1565000

...anytime the webgui is attempting to access data.
rightmirem

rightmirem

2018-02-12 09:51

reporter   ~0002905

Any progress on this issue? Have you been able to recreate it, or do you need more information from me?
archanfel

archanfel

2018-02-14 18:35

reporter   ~0002911

I have exactly the same issue.
Fresh install, CentOS 7, apache 2.4, php 7.2, mariadb 10.2
frank

frank

2018-02-14 18:54

manager   ~0002912

Thanks for the report, I'm going to fix this as soon as possible. I'm pretty sure what the case is here.
It should no longer happen after running your first backups. Nevertheless this needs a fix.
archanfel

archanfel

2018-02-14 19:09

reporter   ~0002914

The apache error log full of this:
array_merge(): Argument 0000001 is not an array in /usr/share/bareos-webui/module/Job/src/Job/Model/JobModel.php on line 126, referer: https://bareos.ttre.hu/bareos-webui/dashboard/

I do a backup job and the issue is still here.
frank

frank

2018-02-15 10:37

manager   ~0002915

Ok, just guessing here by now, but probably it's some kind of timing issue where the request takes longer than the refresh interval so the wheels keep on spinning. I have to dig a bit deeper, it looks like. As said, going to investigate as soon as possible.
rightmirem

rightmirem

2018-02-15 13:25

reporter   ~0002919

@frank
Thats a good thought. And I appreciate you looking into it. Is there a place where I can change the refresh interval as a test?

It may also be important to note, the WEB-UI was working fine right up until the update. So whatever changed, most certainly changed there. Perhaps the timeout changed in the update?
frank

frank

2018-02-15 13:43

manager   ~0002920

@archanfel

What is the output of https://<your host>/bareos-webui/dashboard/getData?data=jobslaststatus when you open it in your browser?

@rightmirem

Refresh interval can be changed in /etc/bareos-webui/configuration.ini, dashboard autorefresh_interval.

;
; Bareos WebUI Configuration File
;
; File: /etc/bareos-webui/configuration.ini
;

;------------------------------------------------------------------------------
; SESSION SETTINGS
;------------------------------------------------------------------------------
;
[session]
; Default: 3600 seconds
timeout=3600

;------------------------------------------------------------------------------
; DASHBOARD SETTINGS
;------------------------------------------------------------------------------
[dashboard]
; Autorefresh Interval
; Default: 60000 milliseconds
autorefresh_interval=60000

;------------------------------------------------------------------------------
; TABLE SETTINGS
;------------------------------------------------------------------------------
[tables]
; Possible values for pagination
; Default: 10,25,50,100
pagination_values=10,25,50,100

; Default number of rows per page
; for possible values see pagination_values
; Default: 25
pagination_default_value=25

; State saving - restore table state on page reload.
; Default: false
save_previous_state=false

;------------------------------------------------------------------------------
; VARIOUS SETTINGS
;------------------------------------------------------------------------------
[autochanger]
; Pooltype for label to use as filter.
; Default: none
labelpooltype=scratch
archanfel

archanfel

2018-02-16 10:39

reporter   ~0002924

@frank
The url gave me a blank page.

and this error log:
[:error] [pid 2479] [client xxx.xxx.xxx.xxx:25795] PHP Notice: Undefined index: result in /usr/share/b
areos-webui/module/Job/src/Job/Model/JobModel.php on line 262
frank

frank

2018-02-16 16:16

manager   ~0002926

@archanfel

What's the exact command output of 'llist jobs last current enabled' executed in bconsole in api 2?

* .api 2
* llist jobs last current enabled
*
archanfel

archanfel

2018-02-16 18:32

reporter   ~0002927

Okay, i may find the problem.
I have multiple catalog connected to multiple database, since we have a huge amount of data, so in one database its just break down.
I created multiple director configuration in the bareos-webui/directors.ini for each catalog. Now i can login after i pick one of the director and see everything what is in that specific catalog. All of the director-catalog pair working fine, but if i comment out the catalog= config parameter and use one director for all catalog the issue is got back.
archanfel

archanfel

2018-02-16 18:33

reporter   ~0002928

Here is the command output:

*.api 2
{
  "jsonrpc": "2.0",
  "id": null,
  "result": {
    "api": 2
  }
}*llist jobs last current enabled
{
  "jsonrpc": "2.0",
  "id": null,
  "error": {
    "code": 1,
    "message": "failed",
    "data": {
      "result": {},
      "messages": {
        "error": [
          "Could not find a Catalog resource\n"
        ]
      }
    }
  }
}*
rightmirem

rightmirem

2018-02-19 10:54

reporter   ~0002929

Hi @frank
Thanks again for the help. I did try to change the settings in:

    ;------------------------------------------------------------------------------
    ; DASHBOARD SETTINGS
    ;------------------------------------------------------------------------------
    [dashboard]
    ; Autorefresh Interval
    ; Default: 60000 milliseconds
    autorefresh_interval=60000

I tried "autorefresh_interval=" 180000, 360000, and 1480000 with no changes to the "psinning" in the webui.

Also, please note that anytime (and only when) the webui is attempting to access the data, we get the following error in the /var/log/apache2/error.log

    [Mon Feb 19 10:49:30.990344 2018] [:error] [pid 8019] [client 129.206.148.18:50539] PHP Notice: Undefined index: result in /usr/share/bareos-webui/module/Job/src/Job/Model/JobModel.php on line 123, referer: http://129.206.148.186:49200/bareos-webui/dashboard/
    [Mon Feb 19 10:49:30.990376 2018] [:error] [pid 8019] [client 129.206.148.18:50539] PHP Notice: Undefined index: result in /usr/share/bareos-webui/module/Job/src/Job/Model/JobModel.php on line 126, referer: http://129.206.148.186:49200/bareos-webui/dashboard/
    [Mon Feb 19 10:49:30.990394 2018] [:error] [pid 8019] [client 129.206.148.18:50539] PHP Warning: array_merge(): Argument 0000001 is not an array in /usr/share/bareos-webui/module/Job/src/Job/Model/JobModel.php on line 126, referer: http://129.206.148.186:49200/bareos-webui/dashboard/

Those lines are repeated infinitely, and multiple times per second, anytime the webui is attempting to connect. It stops if I halt or close the page - or stop apache2 server.

Thanks!
archanfel

archanfel

2018-02-19 11:36

reporter   ~0002930

If you run into the issue then the web server will hang. You need to restart the httpd service after changing the configuration file.
rightmirem

rightmirem

2018-02-19 12:30

reporter   ~0002931

Last edited: 2018-02-19 12:30

View 2 revisions

@archanfel
@Frank
"If you run into the issue then the web server will hang. You need to restart the httpd service after changing the configuration file."

Yes, thank you for reminding me. I forgot to add it to the post..

After trying each of the changes to the "autorefresh_interval" ... I did restart both apache and bareos completely.

    # service apache2 restart
    # service bareos-fd restart; systemctl status bareos-fd.service
    # service bareos-sd restart; systemctl status bareos-storage.service
    # service bareos-dir restart; systemctl status bareos-director.service

(in that order)

archanfel

archanfel

2018-02-22 16:40

reporter   ~0002936

Im convert my database backend from mysql to postgresql and this issue is gone. It seems only issued with the mysql. Plus with the postgresql it can hold millions of row without major breakdown.
rightmirem

rightmirem

2018-03-13 12:11

reporter   ~0002944

Last edited: 2018-03-13 12:14

View 2 revisions

Bump. Is there any news on this issue? Have you been able to recreate?

In relation to @archanfel post...I have been running PostGRES. I still have the issue.

rightmirem

rightmirem

2018-03-27 08:55

reporter   ~0002950

Any new action on this? Is there any information or tests I can provide to assist with the troubleshooting?
frank

frank

2018-03-27 13:16

manager   ~0002956

@rightmirem

Please execute the following command sequence in bconsole to see if a result is delivered in api mode 2 (json) and how it looks like.

1. ".api 2"
2. "list jobs limit=1"

Like:

* .api 2
{
  "jsonrpc": "2.0",
  "id": null,
  "result": {
    "api": 2
  }
}
* list jobs limit=1
{
  "jsonrpc": "2.0",
  "id": null,
  "result": {
    "jobs": [
      {
        "jobid": "2",
        "name": "backup-bareos-fd",
        "client": "bareos-fd",
        "starttime": "2017-12-21 15:35:55",
        "type": "B",
        "level": "F",
        "jobfiles": "2441",
        "jobbytes": "30181744",
        "jobstatus": "T"
      }
    ],
    "meta": {
      "range": {
        "limit": 1,
        "filtered": 0
      }
    }
  }
}*
rightmirem

rightmirem

2018-03-27 13:45

reporter   ~0002957

Last edited: 2018-03-27 13:46

View 2 revisions

Hi Frank,

Thanks again for the help! This seems to look OK.

*.api 2
{
  "jsonrpc": "2.0",
  "id": null,
  "result": {
    "api": 2
  }
}*

*list jobs limit=1
{
  "jsonrpc": "2.0",
  "id": null,
  "result": {
    "jobs": [
      {
        "jobid": "321",
        "jobstatus": "E",
        "name": "BackupCatalog",
        "type": "B",
        "client": "backupserver-fd",
        "jobbytes": "0",
        "starttime": "2017-10-05 17:38:07",
        "level": "F",
        "jobfiles": "0"
      }
    ],
    "meta": {
      "range": {
        "limit": 1,
        "filtered": 0
      }
    }
  }
}*

rightmirem

rightmirem

2018-05-14 11:31

reporter   ~0003001

Hi Frank,

Any updates?

did you look into the associated PhP code error that get's thrown when this happens?
rightmirem

rightmirem

2018-05-30 10:42

reporter   ~0003022

Hi Frank,

Any updates?

did you look into the associated PhP code error that get's thrown when this happens?
rightmirem

rightmirem

2018-06-06 12:38

reporter   ~0003028

Hello,

I'm not sure if this ticket has been abandoned? Is Frank still working with the project? Should I create a new ticket.

Again, this pretty much looks like a PhP coding error in the GUI. Maybe I can fix it myself.
frank

frank

2018-06-06 14:55

manager   ~0003029

Sorry for the delay.

I do, but I'm currently pretty busy on things for paying customers.

Are you still on Version 17.2.4 or did you upgrade to 17.2.5 meanwhile?

There were a few fixes in the maintenance release.

http://doc.bareos.org/master/html/bareos-manual-main-reference.html#x1-637000L

I will try to have a deeper look into this case again as soon as possible.
rightmirem

rightmirem

2018-06-06 15:47

reporter   ~0003030

Hi Frank,

No worries. I know how it gets

I haven't tried that update. Let me arrange that - and then we can continue troubleshooting if needed.

Thanks!
Mike
fearnop

fearnop

2018-06-07 23:34

reporter   ~0003034

Last edited: 2018-06-07 23:37

View 2 revisions

Same error here but i have fixed it for me.

pid 76687] write(7, "07-Jun 23:18 backup1000-dir: Console [admin] from [127.0.0.1] cmdline llist jobs jobstatus=R jobname=\"\" limit=1000 offset=788000\n", 129) = 129
[pid 76687] write(6, "\377\377\377\360", 4) = 4
[pid 76687] write(6, "\377\377\377\353", 4) = 4
[pid 76687] write(6, "\377\377\377\361", 4) = 4
[pid 76687] write(6, "\0\0\0\223{\"id\":null,\"jsonrpc\":\"2.0\",\"error\":{\"message\":\"failed\",\"code\":1,\"data\":{\"result\":{},\"messages\":{\"error\":[\"Could not find a Catalog resource\\n\"]}}}}", 151) = 151
[pid 76687] write(6, "\377\377\377\356", 4) = 4


Fixed it with setting the (custom) catalog to a fixed value (our catalog DIFFERS from the default one and is called WUFRA_Catalog)

/etc/bareos-webui/directors.ini +22

; Set catalog to explicit value if you have multiple catalogs
catalog = "WUFRA_Catalog"


Restart the dir and anything works nice.

Environment:

Ubuntu 16.04.4 LTS


root@backup1000:~# dpkg -l | grep bareos
ii bareos-bconsole 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - text console
ii bareos-common 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - common files
ii bareos-database-common 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - common catalog files
ii bareos-database-mysql 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - MySQL backend
ii bareos-database-tools 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - database tools
ii bareos-director 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - director daemon
ii bareos-filedaemon 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - file daemon
ii bareos-filedaemon-python-plugin 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - file daemon Python plugin
ii bareos-storage 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - storage daemon
ii bareos-storage-fifo 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - storage daemon FIFO backend
ii bareos-storage-tape 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - storage daemon tape support
ii bareos-tools 17.2.4-9.1 amd64 Backup Archiving Recovery Open Sourced - common tools
ii bareos-webui 17.2.4-15.1 all Backup Archiving Recovery Open Sourced - webui

photonn

photonn

2019-04-11 11:56

reporter   ~0003331

Same problem here. Upgraded to last webui version. Dashboard stopped working.

Changed from Chrome to Microsoft Edge, and everything worked flawlessly. Tried with Chrome again in private mode and everything seemed to work again also. I suggest you to try clear your browser cache and login back.

Regards.
photonn

photonn

2019-04-11 12:01

reporter   ~0003332

I can confirm that after clearing all files and images from my Chrome cache, i logged in again and the dashboard works.

Regards.

Issue History

Date Modified Username Field Change
2018-01-26 14:38 rightmirem New Issue
2018-01-26 14:38 rightmirem File Added: Screen Shot 2018-01-26 at 14.36.42.png
2018-01-26 14:55 rightmirem Note Added: 0002884
2018-01-26 16:25 frank Assigned To => frank
2018-01-26 16:25 frank Status new => confirmed
2018-01-26 16:26 frank Assigned To frank =>
2018-01-26 16:27 frank Assigned To => frank
2018-01-26 16:27 frank Status confirmed => new
2018-01-26 16:29 frank Status new => assigned
2018-02-12 09:51 rightmirem Note Added: 0002905
2018-02-14 18:35 archanfel Note Added: 0002911
2018-02-14 18:54 frank Note Added: 0002912
2018-02-14 18:55 frank Status assigned => confirmed
2018-02-14 19:09 archanfel Note Added: 0002914
2018-02-15 10:37 frank Note Added: 0002915
2018-02-15 13:25 rightmirem Note Added: 0002919
2018-02-15 13:43 frank Note Added: 0002920
2018-02-16 10:39 archanfel Note Added: 0002924
2018-02-16 16:16 frank Note Added: 0002926
2018-02-16 18:32 archanfel Note Added: 0002927
2018-02-16 18:33 archanfel Note Added: 0002928
2018-02-19 10:54 rightmirem Note Added: 0002929
2018-02-19 11:36 archanfel Note Added: 0002930
2018-02-19 12:30 rightmirem Note Added: 0002931
2018-02-19 12:30 rightmirem Note Edited: 0002931 View Revisions
2018-02-22 16:40 archanfel Note Added: 0002936
2018-03-13 12:11 rightmirem Note Added: 0002944
2018-03-13 12:14 rightmirem Note Edited: 0002944 View Revisions
2018-03-27 08:55 rightmirem Note Added: 0002950
2018-03-27 13:16 frank Note Added: 0002956
2018-03-27 13:45 rightmirem Note Added: 0002957
2018-03-27 13:46 rightmirem Note Edited: 0002957 View Revisions
2018-05-14 11:31 rightmirem Note Added: 0003001
2018-05-30 10:42 rightmirem Note Added: 0003022
2018-06-06 12:38 rightmirem Note Added: 0003028
2018-06-06 14:55 frank Note Added: 0003029
2018-06-06 15:47 rightmirem Note Added: 0003030
2018-06-07 23:34 fearnop Note Added: 0003034
2018-06-07 23:37 fearnop Note Edited: 0003034 View Revisions
2019-04-11 11:56 photonn Note Added: 0003331
2019-04-11 12:01 photonn Note Added: 0003332