initializing db and generating config string