[one-users] RE: problem with upgrading OpenNebula DB

David david1228 at foxmail.com
Mon Jul 23 19:17:53 PDT 2012


Hi,
 The output of execute command, as flollows:
  
 [oneadmin at vm-master~]$ sqlite3 /opt/nebula/ONE_2.2/var/one.db
SQLite version 3.5.9
Enter ".help" for instructions
sqlite> .tables
backup        history       image_pool    user_pool   
backupdisk    host_pool     leases        vm_pool     
cluster_pool  host_shares   network_pool
sqlite> select * from user_pool where oid=0;
0|oneadmin|7bc8559a8fe509e680562b85c337f170956fcb06|1
sqlite> .schema
CREATE TABLE backup (oid INTEGER,vid INTEGER,bk_dir TEXT,state INTEGER,stime INTEGER,etime INTEGER,PRIMARY KEY(oid));
CREATE TABLE backupdisk (oid INTEGER,vid INTEGER,dk_name TEXT,dk_dir TEXT,state INTEGER,PRIMARY KEY(oid));
CREATE TABLE cluster_pool (oid INTEGER PRIMARY KEY, cluster_name VARCHAR(128), UNIQUE(cluster_name) );
CREATE TABLE history (vid INTEGER,seq INTEGER,host_name TEXT,vm_dir TEXT,hid INTEGER,vm_mad TEXT,tm_mad TEXT,stime INTEGER,etime INTEGER,pstime INTEGER,petime INTEGER,rstime INTEGER,retime INTEGER,estime INTEGER,eetime INTEGER,reason INTEGER,PRIMARY KEY(vid,seq));
CREATE TABLE host_pool (oid INTEGER PRIMARY KEY,host_name VARCHAR(256), state INTEGER,im_mad VARCHAR(128),vm_mad VARCHAR(128),tm_mad VARCHAR(128),last_mon_time INTEGER, cluster VARCHAR(128), template TEXT, UNIQUE(host_name));
CREATE TABLE host_shares(hid INTEGER PRIMARY KEY,disk_usage INTEGER, mem_usage INTEGER, cpu_usage INTEGER,max_disk  INTEGER,  max_mem   INTEGER, max_cpu   INTEGER,free_disk INTEGER,  free_mem  INTEGER, free_cpu  INTEGER,used_disk INTEGER,  used_mem  INTEGER, used_cpu  INTEGER,running_vms INTEGER);
CREATE TABLE image_pool (oid INTEGER PRIMARY KEY, uid INTEGER, name VARCHAR(128), type INTEGER, public INTEGER, persistent INTEGER, regtime INTEGER, source TEXT, state INTEGER, running_vms INTEGER, template TEXT, UNIQUE(name) );
CREATE TABLE leases (oid INTEGER, ip BIGINT, mac_prefix BIGINT, mac_suffix BIGINT,vid INTEGER, used INTEGER, PRIMARY KEY(oid,ip));
CREATE TABLE network_pool (oid INTEGER PRIMARY KEY, uid INTEGER, name VARCHAR(256), type INTEGER, bridge TEXT, public INTEGER, template TEXT, UNIQUE(name));
CREATE TABLE user_pool (oid INTEGER PRIMARY KEY, user_name VARCHAR(256), password TEXT,enabled INTEGER, UNIQUE(user_name));
CREATE TABLE vm_pool (oid INTEGER PRIMARY KEY,uid INTEGER,name TEXT,last_poll INTEGER, state INTEGER,lcm_state INTEGER,stime INTEGER,etime INTEGER,deploy_id TEXT,memory INTEGER,cpu INTEGER,net_tx INTEGER,net_rx INTEGER, last_seq INTEGER, template TEXT);
sqlite> 
  

 

 ------------------ 原始邮件 ------------------
  发件人: "Carlos Martín Sánch"<cmartin at opennebula.org>;
 发送时间: 2012年7月23日(星期一) 晚上6:17
 收件人: "David"<david1228 at foxmail.com>; 
 抄送: "users"<users at lists.opennebula.org>; 
 主题: Re: [one-users] problem with upgrading OpenNebula DB

 

Hi, 

 Can you please paste the output of  'sqlite3 /opt/nebula/ONE_2.2/var/one.db ".schema"' ?
 

 Regards
 --
Carlos Martín, MSc
Project Engineer
OpenNebula - The Open-source Solution for Data Center Virtualization www.OpenNebula.org | cmartin at opennebula.org | @OpenNebula



 On Mon, Jul 23, 2012 at 11:48 AM, David <david1228 at foxmail.com> wrote:
    
Hi,
 
While upgrading openNebula2.2(sqlite DB) to 3.2.1(mysql DB) :
 
$ onedb upgrade -v --sqlite /opt/nebula/ONE_2.2/var/one.db
 
I found a fault:"Database schema does not look to be created by OpenNebula: table user_pool is missing or empty."can you tell me how to solve it?   thank you!
 
gem -v: 1.8.10
 
ruby -v : ruby 1.9.2p290 (2011-07-09 revision 32553) [x86_64-linux] 
 
Regards!



_______________________________________________
Users mailing list
Users at lists.opennebula.org
http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opennebula.org/pipermail/users-opennebula.org/attachments/20120724/d7d83db6/attachment-0002.htm>


More information about the Users mailing list