暂无图片
暂无图片
暂无图片
暂无图片
2
暂无图片

有人说 "免费" 的数据库,谁敢用?

昨天写了一篇针对国产数据库"免费"的文章 震惊!这个国产数据库居然免费用!,然后一些群友就有不同的意见了。这也难怪,毕竟青菜萝卜,各有所爱!

群友的观点


我提到我们MogDB 采用了类似Oracle一样的paper License策略,当然我们目的也就是为了做生态。老实说,在目前国内的严峻环境中,采样这个策略,真的需要非常大的勇气。毕竟现在大家都在勒紧裤腰带过日子呢。

首先我要说明一点,Oracle确实从来没有强调免费,但是确实用户可以免费下载,而且下载的版本跟企业版本也并无两样;这就造成了在国内事实上的”免费“。但是这无疑是让Oracle在国内份额如此之高的一个重要原因。

用的人多了,自然而然生态也很好了,开发者、DBA都趋之若鹜了。

当然MogDB 数据库采用类似策略,我们本意也是想让更多的开发者、更多的DBA人员参与进来,多多学习和测试,给我们反馈更多的宝贵意见。

除了MogDB 数据库软件之外,其配套的工具如异构数据迁移工具MTK,兼容性分析工具SCA等等,大家都可以在官网(mogdb.io)下载,随便使用一个邮箱就能获得license,进而进行使用体验;最重要的是,license还是通用的。比如mtk的license,同时sca,mdb等工具都可以使用。。。是不是很方便?

实际上我曾经测过很多国产数据库,想找人要一份安装软件介质都老费劲了,实在是太麻烦。数据库软件本来就是让人用的,藏着掖着干什么呢

用开源的PostgreSQL不香吗

既然网友提出了这个问题,那么我就来尝试回答一下。

首先我想说PostgreSQL确实这些发展很快,尤其是国内,这几年因为xc的原因,很多国产数据库厂商都选择了基于PostgreSQL来进行二次开发增强(当然直接套壳的也不少,享受开源的红利,我认为也没有太大的毛病,谁让PostgreSQLSQL的开源协议如此友好呢)。

当然也确实很多用户都选择了开源的PostgreSQL,尤其是已经运维能力比较强的客户。如果运维能力跟得上,那么用开源软件是完全ok的,我没有任何意见。

但从另外一个角度来讲,现在国内用户选择数据库替换的原因有很多,成本并不是唯一因素。

就拿我们已经完成国产化上线的这些客户来讲,用户需要的数据库产品,不仅仅是能满足他们的要求,而且需要有较高的Oracle、MySQL兼容性,同时后台还有强大的技术支撑能力。

比如某事业单位使用了PostgreSQL来做替换核心Oracle数据库,那么其改造成本还是非常高的,尽管我知道PostgreSQL也有相关的Oracle兼容性插件。

实事求是的讲,这2年MogDB在兼容性做的非常多了,相比开源插件而言就要多的太多了,这里简单提一提(如果大家有兴趣,后续我可以写一个系列,针对MogDB for Oracle/MySQL 方面的兼容):

从以上5个维度来讲,我们都做了大量兼容,另外还要补充一点,我们也做了大量针对PostgreSQL的兼容。大家所熟知的鼎捷ERP 之前就是基于PostgreSQL开发,目前部分用户已经迁移到了MogDB,运行平稳。

最后我不得不再次吐槽原生PostgreSQL那些令人糟心的问题,比如事务ID回卷、增量检查点等至今都没有解决。

“免费”等于不好?便宜无好货?

首先我再次重申一下,MogDB从来没有说过免费。但是如果你要白嫖,我们也就当不知道。哈哈。

继续回到这个话题上来,MySQL、PostgreSQL开源这么多年了,你能说他不好么?话说openGauss开源至今也有已经4年了,参与者众多,生态繁荣。

我认为对于一个数据库软件,还不好用,得让用户来评价,这里我给大家附上一段今天刚升级的一套测试环境。

[root@mogdb1 ~]# ptk cluster status -n mog506
[   Cluster State   ]
cluster_name                   : mog506
cluster_state                  : Normal
database_version               : MogDB-5.0.6 (build 8b0a6ca8)
mogha_installed                : yes

[  Datanode State   ]
  cluster_name |  id  |      ip       | port  | user | nodename | db_role | state  |     uptime      | upstream  
---------------+------+---------------+-------+------+----------+---------+--------+-----------------+-----------
  mog506       | 6001 | 172.20.22.125 | 25000 | omm2 | dn_6001  | primary | Normal | 4 days 12:42:34 | -         
               | 6002 | 172.20.22.126 | 25000 | omm2 | dn_6002  | standby | Normal | 4 days 12:42:30 | -         
               | 6003 | 172.20.22.128 | 25000 | omm2 | dn_6003  | standby | Normal | 4 days 12:42:27 | -         
[root@mogdb1 ~]

[root@mogdb1 ~]# ptk cluster -n mog506 upgrade -y -p /root/MogDB-5.0.7-CentOS-x86_64-all.tar.gz
INFO[2024-06-04T17:40:24.535] PTK Version: 1.4.7 release                   
INFO[2024-06-04T17:40:24.540] new step recorder, current step: "start"     
Tip:
        The upgrade process relies on SSH.
        Please ensure that the network is always worked
        during the upgrade process.
INFO[2024-06-04T17:40:24.540] parsing package from /root/MogDB-5.0.7-CentOS-x86_64-all.tar.gz 
INFO[2024-06-04T17:40:32.355] kernel package name: MogDB-5.0.7-CentOS-64bit.tar.gz 
INFO[2024-06-04T17:40:32.356] package version: MogDB-5.0.7,92.924,c4707384 
INFO[2024-06-04T17:40:32.356] check db version                             
INFO[2024-06-04T17:40:32.356] big upgrade: true                            
INFO[2024-06-04T17:40:32.356] current version: 5.0.6, target version: 5.0.7 
INFO[2024-06-04T17:40:32.356] current number: 92.920, target number: 92.924 
INFO[2024-06-04T17:40:32.520] version is ok                                
INFO[2024-06-04T17:40:32.521] prepare all upgrade sql                      
INFO[2024-06-04T17:40:33.304] extract upgrade_sql.tar.gz successfully      
WARN[2024-06-04T17:40:33.304] no sql file found for upgrade maindb         
WARN[2024-06-04T17:40:33.304] no sql file found for upgrade otherdb        
WARN[2024-06-04T17:40:33.304] no sql file found for rollback maindb        
WARN[2024-06-04T17:40:33.304] no sql file found for rollback otherdb       
INFO[2024-06-04T17:40:33.542] create temp dir                              
INFO[2024-06-04T17:40:33.560] upload upgrade_extensions.tar.gz             
INFO[2024-06-04T17:40:33.579] extract upgrade_extensions.tar.gz to dir /opt/mogdb506/tmp/upgrade 
INFO[2024-06-04T17:40:33.749] check cluster status                         
INFO[2024-06-04T17:40:33.952] cluster state is ok                          
INFO[2024-06-04T17:40:34.069] check db config: enable_stream_replication   
INFO[2024-06-04T17:40:34.120] config is ok: enable_stream_replication=on   
INFO[2024-06-04T17:40:34.120] check db config: enable_global_syscache      
INFO[2024-06-04T17:40:34.168] config is ok: enable_global_syscache=off     
INFO[2024-06-04T17:40:34.168] create remote temporary upgrade directory    
INFO[2024-06-04T17:40:34.188] set cluster to read-only                     
INFO[2024-06-04T17:40:34.225] begin: wait_xlog_sync                        
INFO[2024-06-04T17:40:34.225] check disk size                              
INFO[2024-06-04T17:40:34.384] check and wait xlog sync                     
INFO[2024-06-04T17:40:34.437] finished: wait_xlog_sync                     
INFO[2024-06-04T17:40:34.437] begin: backup_old_files                      
INFO[2024-06-04T17:40:34.437] backup old app and tool                      
INFO[2024-06-04T17:41:00.004] finished: backup_old_files                   
INFO[2024-06-04T17:41:00.004] begin: exec_pre_sql                          
INFO[2024-06-04T17:41:00.004] set cluster to read-write                    
INFO[2024-06-04T17:41:00.105] call hook script: before_pre_upgrade_script  
INFO[2024-06-04T17:41:01.093] checking cluster status                      
INFO[2024-06-04T17:41:01.626] cluster status is normal                     
INFO[2024-06-04T17:41:01.626] set upgrade_mode to 2                        
INFO[2024-06-04T17:41:01.660] check and turn on support_extended_features  
INFO[2024-06-04T17:41:01.747] execute rollback sql                         
INFO[2024-06-04T17:41:01.747] execute rollback sql on maindb               
INFO[2024-06-04T17:41:01.908] execute rollback sql on otherdb: [template1 dbm template0 tpch sysbench user01_db test], parallel num: 10 
INFO[2024-06-04T17:41:02.275] execute upgrade sql                          
INFO[2024-06-04T17:41:02.275] execute upgrade sql on maindb                
INFO[2024-06-04T17:41:02.425] execute upgrade sql on otherdb: [template1 dbm template0 tpch sysbench user01_db test], parallel num: 10 
INFO[2024-06-04T17:41:02.778] execute checkpoint                           
INFO[2024-06-04T17:41:03.126] call hook script: after_pre_upgrade_script   
INFO[2024-06-04T17:41:03.144] finished: exec_pre_sql                       
INFO[2024-06-04T17:41:03.144] begin: stop_datanode                         
......
[pg_trgm, pg_prewarm, postgis, whale, wal2json, oracle_fdw, pg_bulkload, pg_repack, mysql_fdw] 
INFO[2024-06-04T17:41:24.944] [172.20.22.125][omm2] upload All-Plugins.tar.gz 
INFO[2024-06-04T17:41:24.944] [172.20.22.126][omm2] upload All-Plugins.tar.gz 
INFO[2024-06-04T17:41:24.944] [172.20.22.128][omm2] upload All-Plugins.tar.gz 
INFO[2024-06-04T17:41:25.268] [172.20.22.125][omm2] make user omm2's dir(s): /opt/mogdb506/tool/plugins 
INFO[2024-06-04T17:41:25.382] [172.20.22.125][omm2] extract All-Plugins.tar.gz to dir /opt/mogdb506/tool/plugins 
INFO[2024-06-04T17:41:25.387] [172.20.22.128][omm2] make user omm2'
s dir(s): /opt/mogdb506/tool/plugins 
⣽ executing...INFO[2024-06-04T17:41:25.798] [172.20.22.126][omm2] make user omm2's dir(s): /opt/mogdb506/tool/plugins 
INFO[2024-06-04T17:41:25.929] [172.20.22.126][omm2] extract All-Plugins.tar.gz to dir /opt/mogdb506/tool/plugins 
INFO[2024-06-04T17:41:26.417] [172.20.22.125][omm2] change /opt/mogdb506/tool/plugins owner to omm2 
INFO[2024-06-04T17:41:26.598] [172.20.22.128][omm2] extract All-Plugins.tar.gz to dir /opt/mogdb506/tool/plugins 
INFO[2024-06-04T17:41:27.084] [172.20.22.126][omm2] change /opt/mogdb506/tool/plugins owner to omm2 
INFO[2024-06-04T17:41:27.647] [172.20.22.128][omm2] change /opt/mogdb506/tool/plugins owner to omm2 
INFO[2024-06-04T17:41:27.665] [172.20.22.128][omm2] installing plugin [pg_prewarm] ... 
INFO[2024-06-04T17:41:27.666] [172.20.22.125][omm2] installing plugin [pg_trgm] ... 
INFO[2024-06-04T17:41:27.670] [172.20.22.126][omm2] installing plugin [pg_trgm] ... 
INFO[2024-06-04T17:41:27.706] [172.20.22.125][omm2] plugin [pg_trgm] installed successfully 
INFO[2024-06-04T17:41:27.706] [172.20.22.125][omm2] installing plugin [pg_prewarm] ... 
INFO[2024-06-04T17:41:27.717] [172.20.22.126][omm2] plugin [pg_trgm] installed successfully 
INFO[2024-06-04T17:41:27.717] [172.20.22.126][omm2] installing plugin [pg_prewarm] ... 
......
INFO[2024-06-04T17:41:51.079] finished: exec_post_sql                      
INFO[2024-06-04T17:41:51.079] begin: restart_dn_finally                    
INFO[2024-06-04T17:41:51.079] restart all datanodes                        
INFO[2024-06-04T17:41:51.096] operation: stop                              
INFO[2024-06-04T17:41:51.096] ========================================     
INFO[2024-06-04T17:41:51.160] stop db [172.20.22.128:25000] ...            
INFO[2024-06-04T17:41:53.192] stop db [172.20.22.128:25000] successfully   
INFO[2024-06-04T17:41:53.192] ========================================     
INFO[2024-06-04T17:41:53.192] stop successfully                            
INFO[2024-06-04T17:41:53.210] operation: stop                              
INFO[2024-06-04T17:41:53.210] ========================================     
INFO[2024-06-04T17:41:53.286] stop db [172.20.22.126:25000] ...            
INFO[2024-06-04T17:41:54.318] stop db [172.20.22.126:25000] successfully   
INFO[2024-06-04T17:41:54.318] ========================================     
INFO[2024-06-04T17:41:54.318] stop successfully                            
INFO[2024-06-04T17:41:54.334] operation: stop                              
INFO[2024-06-04T17:41:54.334] ========================================     
INFO[2024-06-04T17:41:54.396] stop db [172.20.22.125:25000] ...            
INFO[2024-06-04T17:41:56.426] stop db [172.20.22.125:25000] successfully   
INFO[2024-06-04T17:41:56.426] ========================================     
INFO[2024-06-04T17:41:56.426] stop successfully                            
INFO[2024-06-04T17:41:56.426] checking cluster state before start          
INFO[2024-06-04T17:41:56.480] operation: start                             
INFO[2024-06-04T17:41:56.480] ========================================     
INFO[2024-06-04T17:41:56.480] start db [172.20.22.125:25000] ...           
INFO[2024-06-04T17:41:59.384] start db [172.20.22.125:25000] successfully  
INFO[2024-06-04T17:41:59.384] start db [172.20.22.126:25000] ...           
INFO[2024-06-04T17:42:02.613] start db [172.20.22.126:25000] successfully  
INFO[2024-06-04T17:42:02.613] start db [172.20.22.128:25000] ...           
INFO[2024-06-04T17:42:05.635] start db [172.20.22.128:25000] successfully  
INFO[2024-06-04T17:42:05.836] ========================================     
INFO[2024-06-04T17:42:05.836] start cluster successfully                   
INFO[2024-06-04T17:42:05.836] finished: restart_dn_finally                 
INFO[2024-06-04T17:42:05.836] upgrade successfully                         

If you confirm that the upgrade is correct, you can run this command to finish the upgrade:
    ptk cluster -n mog506 upgrade-commit
If you want to rollback the upgrade, you can run:
    ptk cluster -n mog506 upgrade-rollback [-H|--host HOST] [-i|--id ID]
INFO[2024-06-04T17:42:05.836] time elapsed: 1m41s                          
[root@mogdb1 ~]#  ptk cluster -n mog506 upgrade-commit
INFO[2024-06-04T17:42:13.828] PTK Version: 1.4.7 release                   
INFO[2024-06-04T17:42:13.833] new step recorder, current step: "restart_dn_finally" 
INFO[2024-06-04T17:42:13.833] check cluster status                         
INFO[2024-06-04T17:42:13.833] checking cluster status                      
INFO[2024-06-04T17:42:14.106] cluster status is normal                     
INFO[2024-06-04T17:42:14.106] enable cluster read-write                    
INFO[2024-06-04T17:42:14.106] set cluster to read-write                    
INFO[2024-06-04T17:42:14.319] set upgrade_mode to 0                        
INFO[2024-06-04T17:42:14.350] restore support_extended_features value      
INFO[2024-06-04T17:42:14.408] create temp dir                              
INFO[2024-06-04T17:42:14.423] upload upgrade_extensions.tar.gz             
INFO[2024-06-04T17:42:14.441] extract upgrade_extensions.tar.gz to dir /opt/mogdb506/tmp/upgrade 
INFO[2024-06-04T17:42:14.619] call hook script: on_commit_script           
INFO[2024-06-04T17:42:14.822] clear temporary directories                  
INFO[2024-06-04T17:42:15.095] commit success                               
INFO[2024-06-04T17:42:15.095] time elapsed: 1s                             
[root@mogdb1 ~]# 
[root@mogdb1 ~]# ptk cluster status -n mog506
[   Cluster State   ]
cluster_name                   : mog506
cluster_state                  : Normal
database_version               : MogDB-5.0.7 (build c4707384)
mogha_installed                : yes

[  Datanode State   ]
  cluster_name |  id  |      ip       | port  | user | nodename | db_role | state  |  uptime  | upstream  
---------------+------+---------------+-------+------+----------+---------+--------+----------+-----------
  mog506       | 6001 | 172.20.22.125 | 25000 | omm2 | dn_6001  | primary | Normal | 00:00:26 | -         
               | 6002 | 172.20.22.126 | 25000 | omm2 | dn_6002  | standby | Normal | 00:00:23 | -         
               | 6003 | 172.20.22.128 | 25000 | omm2 | dn_6003  | standby | Normal | 00:00:20 | -         
[root@mogdb1 ~]#

复制


有一说一:用起来真的很丝滑,2分钟就可以完成一套MogDB主备集群的升级。

“免费” 能让生态更活跃

我们认为让更多的人参与进来,能促进生态繁荣,尤其是对我们DBA来讲我认为是天大的好事儿。

为什么这样讲?用的企业多了,如果出问题了,他们找谁?使用量越多,那么DBA的需求就会越旺盛。这个观点我想不用证明了,Oracle、MySQL就是最好的证明。


写在最后!上次同事说Kamus在为某银行做的数据库高可用架构分享十分十分的精彩!考虑到4月份的直播中,很多网友私信我说听得意犹未尽,那么ok!我邀请了K总今天下午15点来进行线上分析!欢迎预约,一起来直播间敞开聊!



MogDB是云和恩墨基于openGauss的功能增强企业发行版,

围绕高性能、高可用、全密态、多数据库兼容等特点,

已广泛应用于银行、保险、证券、交易所、制造等关键行业。

                    

1、MogDB技术群请加vx(Roger_database) 

2、MogDB更多技术细节与行业应用 www.mogdb.io

3、数据库兼容适配 marketing@enmotech.com


文章转载自Roger的数据库专栏,如果涉嫌侵权,请发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

文章被以下合辑收录

评论

lqkitten
暂无图片
9月前
评论
暂无图片 0
首先我再次重申一下,MogDB从来没有说过免费。但是如果你要白嫖,我们也就当不知道。
9月前
暂无图片 点赞
评论
R
reddey
暂无图片
10月前
评论
暂无图片 0
不要怕用户白嫖,如果客户单位用了你们的产品,自己搞不定后续售后,还是会找到你们的。
10月前
暂无图片 点赞
评论