Hi,
I happened to come across a piece of C code that establishes
connection to oracle database and then daemonize. Since daemonizing
requires forking , then the parent to exit and child to become the session group leader,
i would like to know what would happen to the database connection that
was established. Can the daemon process still access(insert/update into some table) the database schema without any inconsistent behaviour?
I have been reading that "It is not recommended or
really supported to have a connection open and then do a fork()". But
i get confused with all the answers since they say that we might end
up getting ORA-03113 error. But this code has been running quite
successfully.
Please refer to the link which says its bad to fork()
http://groups.google.co.in/group/com...aeb9cda37a4fd1
Can you guide me in this, as to what would be the effect of doing such
coding. Is it better to establish db connection after daemonizing?
Thanks
Sathya