added functions to open and close the configuration file