Subject Re: problem using shutdown script
Author crescendo_naz
--- In firebird-support@yahoogroups.com, Helen Borrie <helebor@t...>
wrote:
> At 02:03 PM 29/10/2004 +0000, you wrote:
>
>
>
> >Issue #1
> >
> >In Linux we use the script ./fbmgr -shut -username user -password
to
> >shutdown the database server. This works only when the database
server
> >is started using the default port 3050. If this is changed, then
the
> >shutdown script throws the following error. Please help. Is the
> >default port hard coded ?
>
> I don't think so.
> Check the port entry in your /etc/services file. The installer will
have
> written it as
>
> gds_db 3050/tcp # Firebird SQL Database Remote Protocol
>
> You'll need to change that to the correct port.
>
>
> >-Failed to establish a connection.
> >-Connection refused
> >can not attach to server

Yes, You are right. The default port 3050 is written at /etc/services.
This is the cause for the problem as it is not inside my application
scope. Since I am starting firebird as an application I can use any
port as fbserver takes port as an argument. Similarly if the shutdown
script fbmgr -shut can also take port as an argument and stop, then
this will solve the problem. Any suggestions for this ?


> >
> >Issue #2
> >What is the shutdown script to be used for windows ?
>
> If you are running FB as a service, study the document
README.instsvc (in
> the \doc directory). There's no "script". You can install a
Control Panel
> applet. You can also use the NET STOP FirebirdS
erverDefaultInstance
> command from the command line to shut down the server service or,
if
> Guardian is running, NET STOP FirebirdGuardianDefaultInstanceto shut
down
> Guardian.
>
> If you are running it as an application, I don't know of any way to
stop it
> from the command line. You need to log out and log in again, or use
the
> Guardian tray icon utility.
>
> As a rule, you should be very loath to stop the server
> arbitrarily. Databases should be shut down first; otherwise users'
pending
> work could be lost.

Yes, I am running the firebirddb as an application and I need to stop
it progmatically without any manual intervention. I can shutdown the
database using something like this,

gfix -shut -user <username> -password <password> <databasename>

This shutdown only the database and not the database server listening
in the port 3050. How do I solve this ? Please Help

>
> ./heLen

Regards,
Nazeem.