Seems like the if statement is not correct either: If "no-defaults" is true, then the config file should *not* be read.
Otoh, then you have the opposite problem, if no-defaults is false / not set, then of course the below code *should* be executed. So you still need to trace where it is set. (Or maybe it is not set / handled anywhere?) henrik On Mon, Apr 2, 2012 at 2:27 PM, Wajahat Abbassi <wajahat.abba...@gmail.com> wrote: > Hi Henrik, > > Thank you so much for the help. I have figured out what is going wrong. > Inside the drizzled/drizzled.cc file, the vm.count("no-defaults") is always > getting true event if we specify --no-defaults options. This results in > execution of following code: > > if (vm.count("no-defaults")) > { > printf("yessssssssssss"); > > fs::path system_config_file_drizzle(system_config_dir); > system_config_file_drizzle /= "drizzled.cnf"; > defaults_file_list.insert(defaults_file_list.begin(), > system_config_file_drizzle.file_string()); > > fs::path config_conf_d_location(system_config_dir); > config_conf_d_location /= "conf.d"; > > CachedDirectory config_conf_d(config_conf_d_location.file_string()); > if (not config_conf_d.fail()) > { > > BOOST_FOREACH(CachedDirectory::Entries::const_reference iter, > config_conf_d.getEntries()) > { > string file_entry(iter->filename); > if (not file_entry.empty() && file_entry != "." && file_entry != > "..") > defaults_file_list.push_back((config_conf_d_location / > file_entry).file_string()); > } > } > } > > > Now I will debug, why vm.count("no-defaults") is getting true always. I > deliberately denied entry to this code snippet and I can see that the > configuration file doesn't picked up then. This looks good. So the problem > is just in the setting of vm.count("no-defaults") > > Thanks. > > Wajahat Abbassi. > > > > On 2 April 2012 11:48, Henrik Ingo <henrik.i...@avoinelama.fi> wrote: >> >> Hi Wajahat >> >> Looks good. You are on the right track. Note that there are a few >> options like --no-defaults that drizzled should process early on, >> earlier than normal options. The point is, for other options drizzled >> will read the config files first and then process options. But for >> no-defaults of course it has to evaluate the option before it reads >> any config file. >> >> henrik >> >> On Mon, Apr 2, 2012 at 1:04 PM, Wajahat Abbassi >> <wajahat.abba...@gmail.com> wrote: >> > Hi Henrik, >> > >> > I am debugging that --no-defaults bug since yesterday. I can see that >> > this >> > option is not working. i.e. >> > >> > waj@wajahat:~/drizzle/drizzled$ strace ./drizzled --no-defaults 2>&1| >> > grep >> > cnf >> > open("/usr/local/etc/drizzle/drizzled.cnf", O_RDONLY) = 3 >> > >> > If I remove the drizzled.cnf from the path, then strace shows: >> > >> > waj@wajahat:~/drizzle/drizzled$ strace ./drizzled --no-defaults 2>&1| >> > grep >> > cnf >> > open("/usr/local/etc/drizzle/drizzled.cnf", O_RDONLY) = -1 >> > >> > Initially I was thinking that it might loads up the configuration but >> > doesn't use them if --no-defaults is specified. But I tried setting up >> > few >> > parameters in drizzled.cnf and 'drizzled' picks up those parameter even >> > if I >> > specify --no-defaults. >> > >> > But I analyzed drizzled/main.cc, drizzled/drizzled.cc and most of the >> > files >> > in drizzled directory but couldn't find location where 'drizzled' loads >> > up >> > all the configuration. I will keep looking the code, at least I am >> > getting >> > better understanding of the code through this code analyses. >> > >> > Thanks >> > >> > Wajahat Abbassi >> > >> > >> > >> > On 31 March 2012 17:11, Henrik Ingo <henrik.i...@avoinelama.fi> wrote: >> >> >> >> On Sat, Mar 31, 2012 at 12:56 PM, Wajahat Abbassi >> >> <wajahat.abba...@gmail.com> wrote: >> >> > I have a question please. If I make any change in the Drizzle code >> >> > then >> >> > I >> >> > need to recompile again in order to see the effect of that code >> >> > change >> >> > please? If the answer is yes, then is there any quick way of >> >> > compiling >> >> > the >> >> > code because on my laptop it takes a long time to compile actually >> >> > (considering the fact that my laptop is 3 years old :( ). >> >> >> >> The first time it takes long on any computer. 30 - 60 minutes is >> >> minimum. But when you do changes you will see that only the changed >> >> file needs to be recompiled, this just takes a minute or less. >> >> >> >> Occasionally, for instance if you would add a new plugin, remove one >> >> that used to exist, or you just run ./configure again, you end up >> >> recompiling everything from scratch. >> >> >> >> henrik >> >> >> >> > >> >> > For code contributions, I am following the Standard Operating >> >> > Procedure >> >> > from: >> >> > http://docs.drizzle.org/contributing/code.html >> >> > >> >> > I have assigned the following bug to myself on launchpad and I am >> >> > working on >> >> > it. If I would have any questions then I will probably ask it on IRC. >> >> > So >> >> > far >> >> > so good. The bug is: >> >> > >> >> > https://bugs.launchpad.net/drizzle/+bug/935951 >> >> > >> >> > If anyone can give me initial pointers/hints about how to approach >> >> > the >> >> > above >> >> > bug then it will be of great help to me. >> >> > >> >> > Thank you. >> >> > >> >> > Wajahat Abbassi >> >> > >> >> > >> >> > On 27 March 2012 15:53, Wajahat Abbassi <wajahat.abba...@gmail.com> >> >> > wrote: >> >> >> >> >> >> Dear Henrik, >> >> >> >> >> >> Thank you for the positive feedback. >> >> >> >> >> >>> >> >> >>> One thing I wanted to ask is, have you ever contributed to some >> >> >>> open >> >> >>> source project before? Is some work you have done, even just >> >> >>> academic, >> >> >>> publicly available so it could be reviewed by Drizzle mentors? >> >> >> >> >> >> >> >> >> This is the first time I am participating in Google summer of code >> >> >> and >> >> >> I >> >> >> am excited about it. In my past projects, I have worked on Grid >> >> >> middleware >> >> >> framework at University of Reading, UK. I designed the integration >> >> >> mechanism >> >> >> between GridSphere Portal and Gridway Metaschedular. I will send the >> >> >> copy of >> >> >> that work on you email address in a separate email. >> >> >> >> >> >>> >> >> >>> >> >> >>> If not, you might want to consider trying to fix some >> >> >>> low-hanging-bugs >> >> >>> during the GSOC application period to showcase your skills: >> >> >>> >> >> >>> https://bugs.launchpad.net/drizzle/+bugs?field.tag=low-hanging-fruit >> >> >> >> >> >> >> >> >> I am more than happy to pick up the bugs and fix them. I will now >> >> >> setup >> >> >> my >> >> >> machine with the Drizzle and then pick up a bug to get myself >> >> >> familiar >> >> >> with >> >> >> the system. Thank you for this suggestion. >> >> >> >> >> >> Wajahat Abbassi >> >> >> >> >> >> >> >> >> >> >> >> >> >> >> On Mon, Mar 26, 2012 at 1:31 AM, Wajahat Abbassi >> >> >> <wajahat.abba...@gmail.com> wrote: >> >> >> > Hi Marcus & Danial, >> >> >> > >> >> >> > I hope you are doing good. I am interested to work in the emerging >> >> >> > Database >> >> >> > system Drizzle as a GSoC student this year. I have gone through >> >> >> > the >> >> >> > list >> >> >> > of >> >> >> > very interesting ideas on >> >> >> > http://wiki.drizzle.org/GSOC_2012_Project_Ideas. I >> >> >> > have found 1) Compression (Mentor: Marcus) and 2) Make all plugins >> >> >> > dynamic >> >> >> > (Mentor: Danial) very interesting and promising. I would be really >> >> >> > pleased >> >> >> > to make my contributions in one of these projects please. The >> >> >> > following >> >> >> > is >> >> >> > my brief introduction: >> >> >> > >> >> >> > I am currently a Mphil student. Previously, I hold M.Sc in Network >> >> >> > Centred >> >> >> > computing focusing mainly on network programming, data >> >> >> > communications >> >> >> > and >> >> >> > high performance computing from at University of Reading, UK. I >> >> >> > have >> >> >> > extensive hands on experience in different programming languages >> >> >> > (C. >> >> >> > C++, >> >> >> > J2EE, J2SE, Ruby on rails and Shell scripting). In my >> >> >> > dissertation, I >> >> >> > worked >> >> >> > on grid computing paradigm where I designed and developed an >> >> >> > integration >> >> >> > layer between GridWay Metaschedular and GridSphere Portal >> >> >> > framework >> >> >> > to >> >> >> > offer >> >> >> > a PORTLET-based GUI to allow the GRID based distributed jobs to be >> >> >> > scheduled >> >> >> > to the Grid worker nodes remotely and also to perform various job >> >> >> > management >> >> >> > functions. >> >> >> > >> >> >> > The following is a list of some of my academic projects: >> >> >> > >> >> >> > · Implemented Enterprise JavaBeans according to the EJB >> >> >> > 3.0 >> >> >> > specification (JSR 220). Deployment and execution of stateless & >> >> >> > state-full >> >> >> > session EJB. >> >> >> > >> >> >> > · Developed MVC based Sporting manager using Servlets, >> >> >> > JSPs & >> >> >> > JavaBeans. >> >> >> > >> >> >> > · Designed, developed and demonstrated a client-server >> >> >> > Java >> >> >> > based >> >> >> > application for checking student module sections that is >> >> >> > consistent >> >> >> > with >> >> >> > programme specification. >> >> >> > >> >> >> > · Implemented the FTP protocol using C and UNIX System >> >> >> > calls >> >> >> > in >> >> >> > Advanced OS course. >> >> >> > >> >> >> > I am really looking forward to have a very productive summer of >> >> >> > coding >> >> >> > with >> >> >> > Drizzle. >> >> >> > >> >> >> > Please find my attached resume. >> >> >> > >> >> >> > Yours Sincerely, >> >> >> > >> >> >> > Wajahat Abbassi >> >> >> > >> >> >> > >> >> >>> >> >> >>> > _______________________________________________ >> >> >>> > Mailing list: https://launchpad.net/~drizzle-discuss >> >> >>> > Post to : drizzle-discuss@lists.launchpad.net >> >> >>> > Unsubscribe : https://launchpad.net/~drizzle-discuss >> >> >>> > More help : https://help.launchpad.net/ListHelp >> >> >>> > >> >> >>> >> >> >>> >> >> >>> >> >> >>> -- >> >> >>> henrik.i...@avoinelama.fi >> >> >>> +358-40-8211286 skype: henrik.ingo irc: hingo >> >> >>> www.openlife.cc >> >> >>> >> >> >>> My LinkedIn profile: >> >> >>> http://www.linkedin.com/profile/view?id=9522559 >> >> >> >> >> >> >> >> >> >> >> > >> >> >> >> >> >> >> >> -- >> >> henrik.i...@avoinelama.fi >> >> +358-40-8211286 skype: henrik.ingo irc: hingo >> >> www.openlife.cc >> >> >> >> My LinkedIn profile: http://www.linkedin.com/profile/view?id=9522559 >> > >> > >> >> >> >> -- >> henrik.i...@avoinelama.fi >> +358-40-8211286 skype: henrik.ingo irc: hingo >> www.openlife.cc >> >> My LinkedIn profile: http://www.linkedin.com/profile/view?id=9522559 > > -- henrik.i...@avoinelama.fi +358-40-8211286 skype: henrik.ingo irc: hingo www.openlife.cc My LinkedIn profile: http://www.linkedin.com/profile/view?id=9522559 _______________________________________________ Mailing list: https://launchpad.net/~drizzle-discuss Post to : drizzle-discuss@lists.launchpad.net Unsubscribe : https://launchpad.net/~drizzle-discuss More help : https://help.launchpad.net/ListHelp