Re: [firebird-support] Implicit path for Database
Saturday, September 2, 2017, 9:35:20 AM, Neagu wrote: > In databases.conf I can put the lists of alias of Known databases, but I > look for a way to specify only the alias of path where the databases are > store. > Now, If I not specify a path in connect string, the databases is search > in C:\Windows\System32 And, on POSIX, it will search in the current working directory (cwd). You can (and should) configure which directories the server is allowed to search for databases to connect to. The parameter for this, in firebird.conf, is DatabaseAccess. By default, it is set to 'Full', meaning the server can accept connections to databases anywhere. The alternative settings are: None. This takes no arguments. The server can connect only to databases whose full paths are specified in databases.conf. Restrict. This takes a list of one or more filesystem paths where the server may connect to databases located there. If you have databases in sub-directories of that path, you must list each path separately. Use semicolons to separate multiple paths. > Will be good also a way to specify the path where the databses are store > if I not specify a path in connect string. Something like this is possible, as long as you want to store the database in Firebird's root directory *AND* that path is specified as a parameter of DatabaseAccess Restrict (or DatabaseAccess FULL is the current setting). In general, though, storing a database amongst the software components is not a brilliant idea. Read the built-in documentation for DatabaseAccess in firebird.conf. Did you know that you can create an alias for a database that does not yet exist? For example. myNewDB = d:\databases\development.fdb After that is saved, you can create a new database named 'development.fdb' in d:\databases by passing the alias as the database name parameter in your CREATE DATABASE statement. In this case, your DatabaseAccess configuration can be NONE (because the database is known through databases.conf) or FULL (server does not care where a database is located). RESTRICT will work, too, if d:\databases is included in the list of allowed directories. Don't forget that any changes you do in firebird.conf will take effect only after restarting the Firebird service. Helen
[firebird-support] Re: Connect to FB database through VPN
Ok, Then do I still require port forwarding even though connection is through a VPN? Bill Zwirs
[firebird-support] Implicit path for Database
Hello, In databases.conf I can put the lists of alias of Known databases, but I look for a way to specify only the alias of path where the databases are store. Will be good also a way to specify the path where the databses are store if I not specify a path in connect string. Now, If I not specify a path in connect string, the databases is search in C:\Windows\System32 Thanks, Neagu --- This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus
Re: [firebird-support] Connect to FB database through VPN
01.09.2017 11:28, sntpywhl3bfbefeaicfmgdnmn3pewm6576tee...@yahoo.com [firebird-support] wrote: > Is there something different I should be doing to connect to a FB database > through a VPN? No. Media is irrelevant for TCP. -- WBR, SD. ++ Visit http://www.firebirdsql.org and click the Documentation item on the main (top) menu. Try FAQ and other links from the left-side menu there. Also search the knowledgebases at http://www.ibphoenix.com/resources/documents/ ++ Yahoo Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/firebird-support/ <*> Your email settings: Individual Email | Traditional <*> To change settings online go to: http://groups.yahoo.com/group/firebird-support/join (Yahoo! ID required) <*> To change settings via email: firebird-support-dig...@yahoogroups.com firebird-support-fullfeatu...@yahoogroups.com <*> To unsubscribe from this group, send an email to: firebird-support-unsubscr...@yahoogroups.com <*> Your use of Yahoo Groups is subject to: https://info.yahoo.com/legal/us/yahoo/utos/terms/
[firebird-support] Connect to FB database through VPN
I have FB3 database at a customer site and was able to log in remotely because they had Port Forwarding set on their router for Port 3050 and I used the connection string - IP Address:Database Alias. Now they have moved to a VPN (OpenVPN) and removed the Port Forwarding on port 3050. I have setup OpenVPN on the remote computer and they have provided me with the clientbundle for the SSL stuff. I can open the VPN and log onto their server but when I try to connect to the database I get the error: Unable to complete network request to host xxx.xxx.xxx.xx. Failed to establish connection. Is there something different I should be doing to connect to a FB database through a VPN? Any help would be appreciated. Bill Zwirs
[firebird-support] Re: FB and VPN
The exception they are getting is: ISC ERROR CODE:335544721 ISC ERROR MESSAGE: Unable to complete network request to host "[Server Name]". Error reading data from the connection. An existing connection was forcibly closed by the remote host. Any suggestions? Thanks in advance. Ed Dressel
Re: [firebird-support] Re: Sort error No free space found in temporary...
> Hey Thomas > Thanks for the answer. The command output is this: > Max cpu time unlimited unlimited seconds > Max file size unlimited unlimited bytes > Max data size unlimited unlimited bytes > Max stack size 8388608 unlimited bytes > Max core file size 0 unlimited bytes > Max resident set unlimited unlimited bytes > Max processes 514866 514866 > processes > Max open files 4096 4096 files > Max locked memory 65536 65536 bytes > Max address space unlimited unlimited bytes > Max file locks unlimited unlimited locks > Max pending signals 514866 514866 signals > Max msgqueue size 819200 819200 bytes > Max nice priority 0 0 > Max realtime priority 0 0 > Max realtime timeout unlimited unlimited us > > Max Open Files seems a bit low, is that the reason? Very likely, so try to increase the Max open files limit and restart the Firebird process. Increasing the limits might be a bit tricky, cause it may differ across Linux distros (to have new limits being persistent) and even more interestingly, how processes are started (e.g. via user based SSH session vs. started as systemd service etc.) Try to Google for your Linux distro. So, best check if new limits have been applied is always done via: sudo cat /proc//limits Hope this helps. -- With regards, Thomas Steinmaurer http://www.upscene.com/ Professional Tools and Services for Firebird FB TraceManager, IB LogManager, Database Health Check, Tuning etc.
[firebird-support] Re: Firebird 2.5: Nested querys help
Hi Set. Your query is working just as I needed. Good querys are the best querys as they are simpler. Thank you very much. Best regards. Hernando.
[firebird-support] Re: Sort error No free space found in temporary...
Hey Thomas Thanks for the answer. The command output is this: Max cpu time unlimitedunlimitedseconds Max file size unlimitedunlimitedbytes Max data size unlimitedunlimitedbytes Max stack size8388608 unlimitedbytes Max core file size0unlimitedbytes Max resident set unlimitedunlimitedbytes Max processes 514866 514866 processes Max open files4096 4096 files Max locked memory 6553665536bytes Max address space unlimitedunlimitedbytes Max file locksunlimitedunlimitedlocks Max pending signals 514866 514866 signals Max msgqueue size 819200 819200 bytes Max nice priority 00 Max realtime priority 00 Max realtime timeout unlimitedunlimitedus Max Open Files seems a bit low, is that the reason? When the errors happened we saw increased disk queue length and disk load percentage rise.
Re: [firebird-support] Sort error No free space found in temporary...
Hello Thomas, > Hey > The other day we had a major slowdown on a database - one server with a single > database. Some of our queries received this error: > Sort error No free space found in temporary directories operating system > directive open failed > All queries that received this error used union in some way. > > > The Firebird log is shows a lot of errors at the same time. > Cannot dump the monitoring data operating system directive open failed Too > many > open files > And > Cannot initialize the shared memory region operating system directive open > failed Too many open files "Too many open files" usually means that the Firebird process isn't allowed to acquire more file handles from the OS. What is the output of? sudo cat /proc//limits > > > After this the following changes was made to the config > TempBlockSize = 2048576(changed from default value) > TempCacheLimit = 567108864(changed from default value) With TempCacheLimit, you basically tell Firebird how much RAM it is allowed to use for temporary data structure caused by sorting, group by etc. before spilling temporary stuff out onto disk. > (I took the values from the firebird_25_superclassic_64bit.conf from ib-aid) > > > However today same thing happened once again. Does anyone know the solution to > this? > > > TempDirectories in config is set to default, so I guess /tmp/firebird i used, > this disk has about 12Gb free space at the time of writing. Could all this > space have been consumed and causing the errors? If TempDirectories is commented out (thus not explicitly set), Firebird will use whatever the OS returns as disk location for temporary data. Do you monitor disk usage somehow to correlate e.g. increased disk usage with error message above? > > > A few weeks back we moved the database from a Windows Server 2008R2 to CentOs > to accommodate an increased load, on the database, before this we hand never > seen this kind of error. The windows server used a default firebird config > file > except for DefaultDbCachePages that was configured to 1024. > > > Firebird: SuperClassic 2.5.7 > Server: Virtual server, 16 cores, 128Gb of Ram, Multi disk SSD SAN. -- With regards, Thomas Steinmaurer http://www.upscene.com Professional Tools and Services for Firebird FB TraceManager, IB LogManager, Database Health Check, Tuning etc.
Re: [firebird-support] why I not get first row in procedure
Ok, I find my mistake: It is necessary add a line SUSPEND after DO before the second FOR SELECT like this: FOR SELECT DO *SUSPEND* FOR SELECT Thanks. -- Luigi Siciliano -- ++ Visit http://www.firebirdsql.org and click the Documentation item on the main (top) menu. Try FAQ and other links from the left-side menu there. Also search the knowledgebases at http://www.ibphoenix.com/resources/documents/ ++ Yahoo Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/firebird-support/ <*> Your email settings: Individual Email | Traditional <*> To change settings online go to: http://groups.yahoo.com/group/firebird-support/join (Yahoo! ID required) <*> To change settings via email: firebird-support-dig...@yahoogroups.com firebird-support-fullfeatu...@yahoogroups.com <*> To unsubscribe from this group, send an email to: firebird-support-unsubscr...@yahoogroups.com <*> Your use of Yahoo Groups is subject to: https://info.yahoo.com/legal/us/yahoo/utos/terms/
[firebird-support] why I not get first row in procedure
Hallo, why I not get first row in this procedure: SET TERM ^ ; RECREATE PROCEDURE ESTRATTO_CONTO_prova ( CONTO Char(5), CLIENTE Smallint, DATADAL DATE, DATAAL date ) RETURNS ( ID Integer, DATA_REGISTRAZIONE Date, CAUSALE_ID Char(3), DATA_DOCUMENTO Date, NUMERO_DOCUMENTO Varchar(20), DESCRIZIONE_TESTA Varchar(120), DOC_TESTA_ID Integer, CONTO_ID Char(5), CLIFOR_ID Smallint, DARE CURRENCY_D, AVERE CURRENCY_D, SALDO CURRENCY_D, DESCRIZIONE_CORPO Varchar(120), PARTITA Integer, SCADENZA Date, DENOMINAZIONE Varchar(60), CAUSALE_DESCRIZIONE Varchar(80), CONTO_DESCRIZIONE Varchar(60) ) AS DECLARE VARIABLE SOMMA float; BEGIN SALDO = 0; FOR SELECT 0, /* PNT.ID, */ :DATADAL, /* PNT.DATA_REGISTRAZIONE, */ NULL, /* PNT.CAUSALE_ID, */ :DATADAL, /* PNT.DATA_DOCUMENTO, */ NULL, /* PNT.NUMERO_DOCUMENTO, */ NULL, /* PNT.DESCRIZIONE, */ null, /* PNT.DOC_TESTA_ID, */ null, /* PNC.CONTO_ID, */ null, /* IIF (PNC.CLIENTE_ID IS NOT NULL, PNC.CLIENTE_ID, PNC.FORNITORE_ID) AS "CLIFOR_ID", */ COALESCE(SUM(PNC.DARE), 0), COALESCE(SUM(PNC.AVERE), 0), COALESCE(SUM(PNC.DARE - PNC.AVERE), 0) + :SALDO, 'Riporto...', /* PNC.DESCRIZIONE, */ NULL, /* PNC.PARTITA, */ NULL, /* PNC.SCADENZA, */ NULL, /* IIF (PNC.CLIENTE_ID IS NOT NULL, C.DENOMINAZIONE, F.DENOMINAZIONE) as DENOMINAZIONE, */ NULL, /* TC.DESCRIZIONE, */ NULL /* PDC.DESCRIZIONE */ from PN_TESTA PNT JOIN PN_CORPO PNC on PNT.ID = PNC.PN_TESTA_ID LEFT JOIN CLIENTI C ON PNC.CLIENTE_ID = C.ID LEFT JOIN FORNITORI F ON PNC.FORNITORE_ID = F.ID LEFT JOIN TIPO_CAUSALI TC ON PNT.CAUSALE_ID = TC.ID LEFT JOIN PIANO_DEI_CONTI PDC ON PNC.CONTO_ID = PDC.ID WHERE PNC.CONTO_ID = :CONTO AND (((PNC.CLIENTE_ID IS NULL) AND (PNC.FORNITORE_ID IS NULL)) OR (IIF (PNC.CLIENTE_ID IS NOT NULL, PNC.CLIENTE_ID, PNC.FORNITORE_ID) = :CLIENTE)) AND DATA_REGISTRAZIONE < :DATADAL INTO :ID, :DATA_REGISTRAZIONE, :CAUSALE_ID, :DATA_DOCUMENTO, :NUMERO_DOCUMENTO, :DESCRIZIONE_TESTA, :DOC_TESTA_ID, :CONTO_ID, :CLIFOR_ID, :DARE, :AVERE, :SALDO, :DESCRIZIONE_CORPO, :PARTITA, :SCADENZA, :DENOMINAZIONE, :CAUSALE_DESCRIZIONE, :CONTO_DESCRIZIONE DO FOR SELECT PNT.ID, PNT.DATA_REGISTRAZIONE, PNT.CAUSALE_ID, PNT.DATA_DOCUMENTO, PNT.NUMERO_DOCUMENTO, PNT.DESCRIZIONE, PNT.DOC_TESTA_ID, PNC.CONTO_ID, IIF (PNC.CLIENTE_ID IS NOT NULL, PNC.CLIENTE_ID, PNC.FORNITORE_ID) AS "CLIFOR_ID", PNC.DARE, PNC.AVERE, PNC.DARE - PNC.AVERE + :SALDO, PNC.DESCRIZIONE, PNC.PARTITA, PNC.SCADENZA, IIF (PNC.CLIENTE_ID IS NOT NULL, C.DENOMINAZIONE, F.DENOMINAZIONE) as DENOMINAZIONE, TC.DESCRIZIONE, PDC.DESCRIZIONE from PN_TESTA PNT JOIN PN_CORPO PNC on PNT.ID = PNC.PN_TESTA_ID LEFT JOIN CLIENTI C ON PNC.CLIENTE_ID = C.ID LEFT JOIN FORNITORI F ON PNC.FORNITORE_ID = F.ID LEFT JOIN TIPO_CAUSALI TC ON PNT.CAUSALE_ID = TC.ID LEFT JOIN PIANO_DEI_CONTI PDC ON PNC.CONTO_ID = PDC.ID WHERE PNC.CONTO_ID = :CONTO AND (((PNC.CLIENTE_ID IS NULL) AND (PNC.FORNITORE_ID IS NULL)) OR (IIF (PNC.CLIENTE_ID IS NOT NULL, PNC.CLIENTE_ID, PNC.FORNITORE_ID) = :CLIENTE)) AND PNT.DATA_REGISTRAZIONE >= :DATADAL AND PNT.DATA_REGISTRAZIONE <= :DATAAL ORDER BY PNT.DATA_REGISTRAZIONE, PNT.ID, PNT.CAUSALE_ID, PNT.DATA_DOCUMENTO, PNT.NUMERO_DOCUMENTO INTO :ID, :DATA_REGISTRAZIONE, :CAUSALE_ID, :DATA_DOCUMENTO, :NUMERO_DOCUMENTO, :DESCRIZIONE_TESTA, :DOC_TESTA_ID, :CONTO_ID, :CLIFOR_ID, :DARE, :AVERE, :SALDO, :DESCRIZIONE_CORPO, :PARTITA, :SCADENZA, :DENOMINAZIONE, :CAUSALE_DESCRIZIONE, :CONTO_DESCRIZIONE DO SUSPEND; END^ SET TERM ; ^ If I run the select separately I obtain the right result per select. Thanks. -- Luigi Siciliano -- ++ Visit http://www.firebirdsql.org and click the Documentation item on the main (top) menu. Try FAQ and other links from the left-side menu there. Also search the knowledgebases at http://www.ibphoenix.com/resources/documents/ ++ Yahoo Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/firebird-support/ <*> Your email settings: Individual