System datastore showing 0/0 GB

Hi Team,
After fresh installation of OpenNebula, I’m getting this result on datastores :slight_smile:

Should it be like this ? I still didn’t touched anything regarding storage, and I thought that by default, the system datastore will have the same GB as the other ones …

BTW -
I’ve now noticed some change between image vs. system datastores.
It seems that DS_MAD is missing there :

can it tell something ?

Hello, it is normal for system ds not have ds_mad. you should check logs for monitoring errors

grep -i error /var/log/one/oned.log

Hi, thanks for your prompt.
Here is the output :
grep -i error /var/log/one/oned.log
Tue Mar 16 09:24:47 2021 [Z0][ONE][I]: Log level:3 [0=ERROR,1=WARNING,2=INFO,3=DEBUG]
Tue Mar 16 09:24:47 2021 [Z0][ONE][E]: SQL command was: SELECT version FROM local_db_versioning WHERE oid=(SELECT MAX(oid) FROM local_db_versioning), error: no such table: local_db_versioning
Tue Mar 16 09:24:47 2021 [Z0][ONE][E]: SQL command was: SELECT version FROM db_versioning WHERE oid=(SELECT MAX(oid) FROM db_versioning), error: no such table: db_versioning
Wed Mar 17 00:00:01 2021 [Z0][ONE][E]: SQL command was: SELECT MIN(stime) FROM history, error: callback requested query abort

BTW -
I’ve installed OpenNebula twice. one on a VM and one on physical server - and the same result…

Hmm, looks like you are missing db_verioning table. Try to create it manually

Thanks Krisitan !
But where and how to create it ? what is the exact command ?
[or to which file should I add it ? to vi /etc/one/oned.conf ]?

I recommend you connect to your mysql server and check if tables are missing. If you don’t know, then google for ‘how to list mysql tables cli’ in google

but you probably dont use mysql but sqlite located in /var/lib/one/one.db. In that case I recommend you to use mysql

https://docs.opennebula.io/5.12/deployment/opennebula_installation/frontend_installation.html#step-5-enabling-mysql-mariadb-postgresql-optional

thanks again Kristian for this info !

Hello Again,
The issue was with 5.12 , so now I’ve tried to install the newest version, 5.13 to see if it solves the issue.
But still, the same result.

How cab it be that I’m installing something from scratch on a new and clean machine and it happens again ? what am I missing ? I don’t want to deal with DBs, just want to install a straight-forward product.
Someone have a clue ?

probably some bug with sqlite integration? I installed OpenNebula few times without problems, but I always use MySQL.

Very Strange.

Someone who using sqlite had this issue ??

Hi, it seems that you are ssh mode, it is normal it displays 0. These drivers uses the local storage of each host, and so each host will have different usage statistics.

The actual usage of the datastore in each host is show under the host information or onehost show command. Note that this behavior is different for other drivers.

Oh, Thanks Ruben for the professional reply.

I had an issue with create a VM [Pending STATE forever], so I suspected it was this issue. but now that you are saying that it’s normal behavior, I’ll go ahead and add the host again, and check other things.

Thanks !

When I’ll add an host, should I configure something in order to be able to create the VM on the host’s datastore [local] ? or if I’ll choose the VM to be create on the host, it’ll choose the host’s datastore by default ?

this is really helpful for me. thank you for sharing with us…

Damm even I am having a similar kind of issue, I have searched all over the internet and even have posted on number of threads on different forum, no solution seems to work. I am really frustrated, can anyone of you here help me resolve this issue, I am very much tired now.

Hello @laser

If you want to use local storage of the host, you need to follow these steps:

  • Have a system datastore using TM_MAD=ssh (this is created by default when you start OpenNebula first time)
  • Create the host and wait until it is in ON state.
  • Then when creating the VM, it will be deployed on the host and the system datastore.

If the VM is in PENDING state for so long, you need to check /var/log/one/sched.log to see what is the problem there. If you are not able to figure out, you can increase the scheduler debug level by editing the file /etc/one/sched.conf and changing the value under debug_level, then restart the scheduler.

Best,
Álex.