个人工具

UbuntuHelp:Firebird2.0

来自Ubuntu中文

跳转至: 导航, 搜索

ubuntu intrepid/jaunty includes both firebird 2.0.4 and firebird 2.1.x Here is how you can inspect the firebird2.0 related packages

apt-cache search firebird2.0-*

install the super server package (you will be asked about the SYSDBA password and what service to enable :Super Server or Classic )

sudo apt-get install firebird2.0-super

The following extra packages will be installed:
  firebird2.0-common libfbclient2
Recommended packages:
  firebird-utils
The following NEW packages will be installed:
  firebird2.0-common firebird2.0-super libfbclient2
0 upgraded, 3 newly installed, 0 to remove and 1 not upgraded.
Need to get 4355kB of archives.
After unpacking 10.6MB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://archive.ubuntu.com gutsy/universe firebird2.0-common 2.0.3.12981.ds1-1ubuntu2 [894kB]
Get:2 http://archive.ubuntu.com gutsy/universe libfbclient2 2.0.3.12981.ds1-1ubuntu2 [614kB]
Get:3 http://archive.ubuntu.com gutsy/universe firebird2.0-super 2.0.3.12981.ds1-1ubuntu2 [2847kB]
Fetched 4355kB in 9s (459kB/s)                                                                                                           
Preconfiguring packages ...
Selecting previously deselected package firebird2.0-common.
(Reading database ... 206209 files and directories currently installed.)
Unpacking firebird2.0-common (from .../firebird2.0-common_2.0.3.12981.ds1-1ubuntu2_i386.deb) ...
Selecting previously deselected package libfbclient2.
Unpacking libfbclient2 (from .../libfbclient2_2.0.3.12981.ds1-1ubuntu2_i386.deb) ...
Selecting previously deselected package firebird2.0-super.
Unpacking firebird2.0-super (from .../firebird2.0-super_2.0.3.12981.ds1-1ubuntu2_i386.deb) ...
Setting up firebird2.0-common (2.0.3.12981.ds1-1ubuntu2) ...
Setting up libfbclient2 (2.0.3.12981.ds1-1ubuntu2) ...

Setting up firebird2.0-super (2.0.3.12981.ds1-1ubuntu2) ...
Created default security.fdb

 * Starting Firebird 2.0 server manager...
 * Firebird 2.0 server manager already running.

Install the examples and dev files

sudo apt-get install firebird2.0-examples firebird2.0-dev firebird-utils

The employee.fdb archive will be under this dir /usr/share/doc/firebird2.0-examples/examples/empbuild/

cd /usr/share/doc/firebird2.0-examples/examples/empbuild/
sudo gunzip employee.fdb.gz
sudo chown firebird.firebird employee.fdb
sudo mv employee.fdb /var/lib/firebird/2.0/data/

connect to db

 isql-fb

SQL> connect "/var/lib/firebird/2.0/data/employee.fdb " user 'SYSDBA' password 'SYSDBApassword';

Now you can check the server version and the tables

SQL> show tables;
       COUNTRY                                CUSTOMER
       DEPARTMENT                             EMPLOYEE
       EMPLOYEE_PROJECT                       JOB
       PROJECT                                PROJ_DEPT_BUDGET
       SALARY_HISTORY                         SALES

SQL> show version
CON> ;
ISQL Version: LI-V2.0.3.12981 Firebird 2.0
Server version:
Firebird/linux Intel (access method), version "LI-V2.0.3.12981 Firebird 2.0"
Firebird/linux Intel (remote server), version " LI-V2.0.3.12981 Firebird 2.0/tcp (borkstation32)/P10"
Firebird/linux Intel (remote interface), version "LI-V2.0.1.12855 Firebird 2.0/tcp (borkstation32)/P10"
on disk structure version 11.0

For an GUI admin tool you might check the flamerobin administration tool included in ubuntu can be installed by an simple

sudo apt-get install flamerobin

Then use it from the menu Applications->Programming-> FlameRobin There is an easier method using the apt-url [1]

Other Guides

Here is how to install Firebird2.1 on dapper, feisty , hardy , gutsy and intrepid ibex This tutorial explains how you can install the Firebird database server (version 2.0.3) on an Ubuntu 7.10 server using the official tar.gz installer For an older guide (firebird 1.5.x) Read the page bellow Installing Firebird 1.5.x How to install and set Firebird server in ubuntu