This is the home page for kfb, an open source project for Firebird RDBMS tool on Linux
This is one of the many open source database projects for Firebird RDBMS administration tools on Linux. Like many of its precedents its source code can be downloaded at http://sourceforge.net/projects/kfb
Kfb is programmed with KDevelop (C++ and Qt). It is fully GUI and based mainly on IBPP, another open source project of C++ interface to Firebird API's. Kfb also includes some other libraries, ncrypt and fbcopy, and all of them are open source projects and all can be downloaded at http://sourceforge.net
If you are a lover for C, php, or freepascal (lazarus) and in favour of GTK, ( or embed system ) and interested in free commercial usage, perhaps you wuold like to have a peep at this website: http://sites.google.com/site/firebirdarchitect/
I have tried to achieve the goal of stability, speed and security in this project, while still keeping it easy to operate and include as many functions as possible. Kfb opeartes on FB 1.5 , 2. 0. x and 2 .1. x SuperServer. Some efforts are to make this program more handy for the daily operations, such as:
copy table, split table, join table , create table from view (both structure and data) en/de-crypt whole database (its extension files, shadows, external tables files) with one click. wipe database with standard military grade (whole database or single file) Save/Retrieve file to/from selected BLOB column. compress/un-compress selected BLOB en/de crypt Var/Char column data
The enhanced functions of backup and restore database to/from multiple files create role, grant/revoke privileges with users groups confiscate and publicize a database (strip off all privileges from a database creator/owner, while keep the database data un-touched, or make a database open to the public against the will of it creator/owner ).
list Firebird API calls from inside of IBPP . SQL monitor, I call it (Fire)Bird-Watcher.
generate test data (populate random table data, all types except array)
Some experimental functions drop/add NOTNULL to /from DOMAINS drop/add not null to/from column when alter table Batch lift Domains automatically from ALL tables ( data un-touched）
As a long-time-user of Firebird and Open Source programs( most of them are from http://sourceforge.net and http://freshmeat.net) I am very happy that now I can do some little contribution to this open source and Linux community.
Following are some screenshots of kfb, hope you enjoy them
Thank you for sharing part of your time with this program
1. The splash screen with many functions( KDE is more than just a pretty face). On this splash screen user can turn on/off the Firebird server, detect the version of server, detect if the server is running, monitor the start time of the server/program, set a time to shutdown the server by force ( useful for sysdba), the rpm installation message of the Firebird server, and decide the main color for the main program (change the color of kfb by the will of the user. For this example it is the pale green shown in the middle of the splash-screen. It is WYSIWYG)
2. The main widget( window) of kfb. It is formed with 3 sizeable widgets (windows). The left one is the Listview for database structure, which can be collapsed/expanded, printed/saved to plain file at any node. The upper-right one is the main data grid table, which can also be saved to plain text file in a What You See Is What You Get manner. User can select any row with the Row function just under the table ( already seen it ?) Just a click of the table name button will show/list all rows in the table ( no use for user to understand SQL). Below it is the Main Text Edit, it will display many information for you. Now it shows the table meta object information. The Main Menu is not pulled down.
3. The ISQL user-interface. This is for advanced SQL users. Here user can issue any SQL command and execute it. Apart from viewing the result( for a select command) user can also view the internal Firebird API calls from the monitoring widget below ( I call it Bird-Watcher).
4. Alter table function. User can almost do anything to alter a table, including some new functions.
5.Backup/restore database in multiple files. kfb allow user to choose to backup "hot or cold‘and name the extension files automatically, across any directory
6. The Tool widget (window). Here user can copy/append/split/join/compare table within/across databases. Save/Retrieve file to/from any selected BLOB colum, Compress/un-compress Blob data, encrypt/decrypt Var/Char data, create table both structure and source data from a view, batch duplicate domains across databases... It is very useful for me, I hope it can also work well for you.
7. Create Role and grant/revoke privileges main widget.Here user may need some database security skills to manage well. It has covered almost all grant/revoke possibilities.
8. Automatic generate data to populate a table. It supports all datatypes except array. User can have a preview of the data before really populate it to table. You can try to populate 10,000 (no limit ) records and see how many seconds it used.
The security functions, such as cipher/de-cipher/WIPE ( standard military grade) the WHOLE database (the main database file, extension files, shadows, external table file) with one button click, conficate dabase from its creator/owner, operation on any single files... are not presented here. The drop/add NOTＮＵＬＬ Batch Lift Domain function (lift domain constraint on ALL table on ANY column which is under this domain constraint with ONE click, in ONE GO, leaving the data un-touched. Suppose there are 100 tables, each table has 3 columns under this Domain, and now you have to alter/change the Domain...)
kfb on FC7 with FB2.1Beta2 compiled with kdevelop 3.5.x (2007-10)
A couple of days ago I have just upgraded kfb to work on Fedora 7 and FirebirdSS2.1Beta2,compiled with kdevelop 3.5.01. Following is a Step by Step procedure of how I did it, hoping it will be helpful if you also would like to do it.
1) install Fedora 7
2) install FirebirdSS-2.1Beta2 http://www.ibphoenix.com/main.nfs?a=ibphoenix&s=1193445699:746237&page=ibp_download_21 FirebirdSS-22.214.171.12480-Beta2.nptl.i686(2).rpm When you issue the command: rpm -ivh FirebirdSS-126.96.36.19980-Beta2.nptl.i686.rpm you will be very likely to get a Dependencies error warning, particularly if you have installed FC7 freshly, but not up-graded it from an older FC version lower than FC4 . Take out your old CD of Red Hat9, or Fedora1 - Fedora4 and find commpat-libstdc++-33-3.2.3-61.i386.rpm (or download it directly from anywhere). And then rpm -ivh compat-libstdc++-33-3.2.3-61.i386.rpm After the above libstdc is installed, try again of rpm -ivh FirebirdSS-188.8.131.5280-Beta2.i686.rpm This time the Fb Server should be installed without any problems. Then do all the routines as you did for any other FB installations, such as change the SYSDBA password, add some new users, and so on, and do a Console connection and selection, or create a new database to make sure the FB installation is solid and safe.
3) install/up-grade kdevelop to 3.5.x download kdevelop 3.5.x at: http://www.kdevelop.org/index.html?filename=3.5/download.html
http://download.opensuse.org/repositories/home:/amilcarlucas/Fedora_7/i386/kdevelop-3.5.0-14.1.i386.rpm rpm -Fivh kdevelop-3.5.0-14.i386.rpm After it is installed/up-graded, open it and play around with it and you'll find something new. Get familiar with it.
4) copy the kfb project (the whole directory) over to the place you are going to develop it.
5) Open kdevelop3.5.01and Project->Open Project->kfb
6) As this is a fresh/un-compiled project, you do not/cannot do Build->Clean Project/Distclean. Do directly Build->Run Automake & friends If you get a warning: *** YOU'RE USING autoconf (GNU Autoconf) 2.61.
*** KDE requires autoconf 2.53 or newer
then you need to replace the admin dir of your project with the one from KDE 3.5. You can do that by following these steps (assuming /home/user/projects/myproject as path for the project):
* cd to a temporary folder
* svn co svn://anonsvn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin admin
* rm -rf admin/.svn
* rm -rf /home/user/projects/myproject/admin
* mv admin /home/user/projects/myproject/
7) Following is how I didi it:
[root@fbase ~]# cd /home/litaoman/dvlp
[root@fbase dvlp]# svn co svn://anonsvn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin admin
Checked out revision 729593.
[root@fbase dvlp]# rm -rf admin/.svn
[root@fbase dvlp]# rm -rf /home/litaoman/dvlp/kfb/admin
[root@fbase dvlp]# mv admin /home/litaoman/dvlp/kfb/
8) then the same settings as the old version of kdevelop Build->Run automake & friends Build->Run Configure Build->Build Project
9) I found some faults which could escape the check of kdevelop3.3.x cannot escape this new kdevelop3.5.x : image11 in ThreeWidgetsMainBase.cpp co_table:: in co_tables.cpp were successfully passed in version3.3.x, but detained by this new version. Simply fix them( by deleting) and compile, and .... Run !
10) The splash screen of kfb against the back-ground of Fedora 7
That's it, hope you enjoy it and it is helpful to you.
There is a thread at the following place about how to combine Firebird and php together to build 24x7x365 around-clock, around-global live,active remote mirror databases, no need to connect any database on the networks. http://tech.groups.yahoo.com/group/firebird-php/message/2292 This function is not included in this version of kfb.
More than this, and more important, is that by doing this I found an easy but sure way to solve the problem of
HOW TO OBTAIN A CROSS-SECTION OF A LIVE, ACTIVE DATABASE ON ITS TIME AXIS.
Each of the nbackup files is a cross-section of the above database, recording the fixed, un-changable data of that database at the moment when this nbackup file was made. If you burn this file onto an optical-disc then you will really get an "cross-section" of the active database not only in data, but also in physical shape. Of course the total sum of the "cross-sections" will be the complete action history of the database, and each "cross-section" is its act- ion at a particular time point. You can express this clearly in Math formula, if you like.
Since those "cross-sections" are transfered to a remote location ( by e-mail as an/multi attachment in the threaded examples ), even if the original database is damaged, the databases at the remote locations are survived.
And since each "cross-section" is fixed and un-changable, it can also be used as a prove of the status of an active database at a particular moment, no matter what happened before/after that moment to the database. nbackup, IT IS REALLY SOMETHING GOOD AND USEFUL, THANKS.
Still expecting your bug-reports and suggestion of improvements, requirements of more functions ( already a long list...) for the next release of kfb. If you have any 'strange' idea, just bring it forward and I will try my very best to realize it, together with you.
The updated version of kfb has been released on 11/12/2007, and can be downloaded at
http://sourceforge.net/projects/kfb download page within package of kfbpkg 1.0 The new files are: kfbprj-0.2a.tar.bz2, kfbprj-0.2a.tar.gz, and MUST-README-2a.txt
The new version will search for Firebird engine path when starts. It will first search /opt/firebird/, then search /usr/lib/firebird/<version?>. If it found more than one Firebird engine, or none at all, it will pop out an input window asking user to input ONLY ONE full path to the engine to use.
The new version has also changed libibpp.so to libkfb_ibpp.so, and added a useful function: kfb-Report. Now user can generate report directly with kfb. the kfb-report function is based on another open-source program NCReport at http://sourceforge.net/projects/ncreport. ( the original one can not work on Firebird engine)
Now user can have 2 kinds of reports from kfb-report: 1. a dynamic report with all data still in the connected database 2. a fixed report with data retieved from kfb tables/views on the TableGrid. It is What-You-See-Is-What-You-Get
Following are some pictures of the reports made by kfb-report
The designing of a text source report
The launching of the designed report
. The preview of the report before printing
A dynamic report made from a live, connected firebird database, some data are from Blob text.
Expecting your skill, perhaps some artistic gifts, to make the report more attractive and easy to read.
Visit the website http://sourceforge.net/projects/kfb, get the source code and tail it to meet your own need. Enjoy the pleasure of this open source and Linux world, and I
(expecting your bug reports and involvements to improve this open source program)