I am using PCLinuxOS 2007. but the same steps should work for all linux boxes

INSTALLING THE SUPER SERVER

make sure that you have an NPTL Kernal and associated libraies
$>/lib/libc.so.6
this will display NPTL details
get package from Sourceforge (get ntpl package if you have a OS for that)
go to your work area (for me i have my root home "/root") and untar the dowloaded file. Then install it
$> tar -xvzf FirebirdSS-2.0.3.12981-1.nptl.i686.tar.gz
$> cd FirebirdSS-2.0.3.12981-1.i686

$> ./install.sh

firebird server automatically starts up
when promting for SYSDBA password give one (Say Masterkey)

stoping the server:
$> /etc/rc.d/init.d/firebird stop

starting the server:
$> /etc/rc.d/init.d/firebird start

checking whether server is running or not:
$>ps -eaf | grep fb

clean your workarea by removing the untar location
$> rm -rf FirebirdSS-2.0.3.12981-1.i686/

INSTALLING THE FLAMEROBIN

Go to your home or working directory (say /root)
just unzip / untar the flamerobin package. thats it.
$> tar -xvzf flamerobin-0.8.3-i386-gtk2.tgz -C /

start flamerobin.
$> flamerobin
if flamerobin binary is not located in the path, you may have to specify the full path
i suggest create a shortcut on desktop
remember that flamerobin uses libfbclient shared libary, which gets installed along with server
But there are chances that flamerobin many not be able to find the library
you may need to create a softlink to flamerobin to work like
$> ln -s /opt/firebird/lib/libfbclient.so.2.0.3 /lib/libfbclient.so.1

adminstering firebird using flamerobin is very easy. No other tools are required including the command line tools :).
but if you want to use, nobody is stopping and everything is included with server installation.
this is particularly useful if flamerobin refuse to connect.

 

SETTING UP ODBC DRIVER.

Download the latest ODBC driver from firebird site. no need to download the source file
and compile because already compiled .so file is available for download.
the file i got is OdbcFb32-beta-2.0.0144.tar.gz (offcource its a beta)
unpack and copy the libOdbcFb32.so file /usr/lib folder
for configuring the unixODBC, it is better to get the Qt based GUI. but that is not mandatory
but atleast unixODBC should be installed.
onces unixODBC is installed. we will have 2 files in /etc/ folder
odbcinst.ini - configuration of divers
odbc.ini - DNS entry which is refering the configured driver in odbcinst.ini
let me give the content of these files
[root@localhost etc]# cat odbcinst.ini
[PostgreSQL]
Description = ODBC for PostgreSQL
Driver = /usr/lib/libodbcpsql.so.2
Setup = /usr/lib/libodbcpsqlS.so.1
FileUsage = 1

[Firebird]
Description = Firebird ODBC driver
Driver = /usr/lib/libOdbcFb32.so
Driver64 = /usr/lib/libOdbcFb32.so
Setup = /usr/lib/libOdbcFb32.so
Setup64 = /usr/lib/libOdbcFb32.so
UsageCount = 1
CPTimeout =
CPReuse =
[root@localhost etc]#
 
so i have both PostgresSQL and Firebird ODBC drivers configured.
now let us see the DNS entry
 
[root@localhost etc]# cat odbc.ini
[test]
Description = Firebird
Driver = Firebird
Dbname = localhost:/home/rj/test.fdb
Client =
User = SYSDBA
Password = masterkey
Role =
CharacterSet = NONE
ReadOnly = No
NoWait = No
Dialect = 3
QuotedIdentifier = Yes
SensitiveIdentifier = No
AutoQuotedIdentifier = No
UseSchemaIdentifier = 0 - Set null field SCHEMA
LockTimeoutWaitTransactions = 0
SafeThread = Yes

[root@localhost etc]#
 
thats it. everything is done. now you can use isql (not the isql of firebird) 
utility supplied along with unixODBC
 
[root@localhost etc]# isql test
+---------------------------------------+
| Connected! |
| |
| sql-statement |
| help [tablename] |
| quit |
| |
+---------------------------------------+
SQL>
 
Hay you are connected though ODBC driver.
Here i got a table in the database with name EMP. so i just tried to query something
 
SQL> select * from emp;
+---------------------------------------------------+-------------------------+-------+
| NM | DOB | ID |
+---------------------------------------------------+-------------------------+-------+
| Jobin | 1978-01-20 21:31:04.2230| 1 |
| Dijin | 1981-07-16 21:31:04.2230| 2 |
| Rose | 1982-04-06 00:00:00 | 3 |
+---------------------------------------------------+-------------------------+-------+
SQLRowCount returns 3
3 rows fetched
SQL>

 

USING COMMAND LINE UTILITIES

$>gsec -user sysdba -password masterkey

GSEC> display (display all users)

$/usr/lib/firebird/bin/isql

connecting to an exisitng database using isql
---------------------------------------------
>isql
sql>CONNECT ..\examples\empbuild\employee.fdb user SYSDBA password masterkey;

creating a new database
-----------------------
SQL>CREATE DATABASE 'D:\data\test.fdb' page_size 8192 user 'SYSDBA' password 'masterkey';
GUI tool for administraton: Flamerobin.
by default firebird uses the port 3050

try installing supper server
----------------------------
new user "firebird" will be created on linux
set the password for firebird user
>sudo passwd firebird

shutting down the server
------------------------
>sudo su -c "fgmgr -shut -password masterkey" firbird
starting up
su -c "fbmgr -start" firebird

in my experiance in PClinuxOS. i am able to shutdown and startup just like any other service
/etc/rc.d/init.d/firebird start
/etc/rc.d/init.d/firebird stop


Creating Alias. this will allow you to relocate datafiles without notifying users.
-----------------------
open aliases.conf and add lines like this
books = /home/bookworm/database/books.fdb

Restrict database access
open firebird.conf and change DatabaseAccess parameter
Restrict -> Access only listed filesystem tree
None -> Access only aliased databases only.

TCP/IP connection string
------------------------
<servername/ip>:<alias/path_of_db_file>


BACKUP AND RECOVERY

there are 2 tools available gbak and nbackup.

nbackup can be used for full aswell as incremental.

it works as an external tool to database which just reads the file of the database and creates the backup file. so speed of backup will be maximum with very less database overhead. but currently nbackup will work only for single file database in local machine. nbackup will put the database in backup mode (ALTER DATABASE BEGIN BACKUP). which locks the database file and creates an external file for ongoing transactions. these changes will be merged with original ones the backup completes. then it comes out of the backup mode (ALTER DATABASE END BACKUP)

syntax >nbackup [-U <user> -P <password>] -B 0 <database> [<backupfile>]

ex: C:\Data> nbackup -B 0 inventory.fdb inventory_1-Mar-2006.nbk

here 0 stands for the backup level. you can omit the backup file name. nbackup will create a proper name using date and time. in windows machine you may have to specify SYSDBA or other user capabile of taking bakcup like

"C:\Program Files\firebird\Firebird_2_0\bin\nbackup" -U jobin -P kuttan2k -B 0 TEST.FDB

you can restore the full backup like

C:\Data> nbackup -R inventory.fdb inventory_1-Mar-2006.nbk
Incremental Backups
-------------------
first we need to have a level 0 backup. (say weekly)
now we can take a level 1 backup witch contains all changes since last level 0. (say daily)
>nbackup -B 1 inventory.fdb inventory_3-Mar-2006.nbk 
if we require we can go for a level 2 backups (say hourly) which contains all the changes 
since last level 1
>nbackup -B 2 inventory.fdb inventory_3-Mar-2006_2.nbk
now suppose we want to go for a restore, we can do it by
>nbackup -R inventory.fdb inventory_1-Mar-2006.nbk inventory_3-Mar-2006.nbk inventory_3-Mar-2006_2.nbk 
if you want you can do yourown way of backup like coping over network or zipping. nbackup can
help here also
see http://www.firebirdsql.org/manual/nbackup-lock-unlock.html
using GBAK
----------
http://firebirdmasters.blogspot.com/2007/02/gbak-firebird-backup-and-restore-gbak.html 
backup information
------------------
select * from RDB$BACKUP_HISTORY 
Nbackup is architecturally superior. it can be compared with RMAN in Oracle.
here is a small architectural description : http://www.firebirdsql.org/index.php?op=devel&sub=engine&id=nbackup
 
Extract info from system tables RDB$
-----------------------------------
http://www.alberton.info/firebird_sql_meta_info.html
simple schema information can be obtained like:
SELECT a.RDB$RELATION_NAME, b.RDB$FIELD_NAME, b.RDB$FIELD_ID, d.RDB$TYPE_NAME,
c.RDB$FIELD_LENGTH, c.RDB$FIELD_SCALE
FROM RDB$RELATIONS a
INNER JOIN RDB$RELATION_FIELDS b
ON a.RDB$RELATION_NAME = b.RDB$RELATION_NAME
INNER JOIN RDB$FIELDS c
ON b.RDB$FIELD_SOURCE = c.RDB$FIELD_NAME
INNER JOIN RDB$TYPES d
ON c.RDB$FIELD_TYPE = d.RDB$TYPE
WHERE a.RDB$SYSTEM_FLAG = 0
AND d.RDB$FIELD_NAME = 'RDB$FIELD_TYPE'
ORDER BY a.RDB$RELATION_NAME, b.RDB$FIELD_ID

you can use the RDB$DATABASE same as DUAL in ORACLE
>select current_date,current_user,current_timestamp from RDB$DATABASE