Re: [Monetdb-developers] Works fine once, then get Invalid credentials for user monetdb
Probably you aren't but the binpkgs you use are. You'll probably have less frustrations at this point if you just compile from source, using the monetdb-install.sh script. What seems wrong here is that the default path is set to the builddir instead of the target dir.
Thanks for the suggestion. My results were mixed. The good news is that in the latest nightly stable build the problems with the intermitant bad passwords and with the server failing to reboot have been fixed! So that is great! However the not-so-good news is that now my JDBC connection is no longer working properly. Do I need to use a newer version of the JDBC driver in conjunction with this latest stable nightly build? If so I could not find it - where do I get it? The problem with the JDBC driver is that when running with merovingian I get: Maximum number of redirects reached, aborting connection attempt. Sorry. then instead of running withmerovingian, as a test I ran with: mserver5 --dbinit="include sql;" and when running that way I get InvalidCredentialsException:checkCredentials:Invalid credentials for user 'monetdb' However I am using the default username and password of monetdb for both and haven't changed this. Furthermore If I run mclient with -umonetdb and specify monetdb as the password it accepts it there just fine. So I assume monetdb is still the default valid username/password for this stable nightly. But for some reason when I pass this as the user name and password in my JDBC connection it won't accept it. As mentioned earlier, this part was working just fine under the released version of MonetDB5. Can someone please help? I am running out of time to get this implemented so I am hoping to close this loop today. Thank you so much!!
On 12-06-2008 13:32:09 -0700, Rt Ibmer wrote:
Probably you aren't but the binpkgs you use are. You'll probably have less frustrations at this point if you just compile from source, using the monetdb-install.sh script. What seems wrong here is that the default path is set to the builddir instead of the target dir.
Thanks for the suggestion. My results were mixed. The good news is that in the latest nightly stable build the problems with the intermitant bad passwords and with the server failing to reboot have been fixed! So that is great!
However the not-so-good news is that now my JDBC connection is no longer working properly. Do I need to use a newer version of the JDBC driver in conjunction with this latest stable nightly build? If so I could not find it - where do I get it?
The problem with the JDBC driver is that when running with merovingian I get: Maximum number of redirects reached, aborting connection attempt. Sorry.
Please try with http://www.ins.cwi.nl/~monet/tars/latest/stable/jdbcclient.jar and file a bug if the problem persists.
then instead of running withmerovingian, as a test I ran with:
mserver5 --dbinit="include sql;"
and when running that way I get InvalidCredentialsException:checkCredentials:Invalid credentials for user 'monetdb'
This is to be expected, since databases created with monetdb/merovingian are not compatible with manually started databases. Merovingian adds a layer of security to your databases, using an encryption key.
Furthermore If I run mclient with -umonetdb and specify monetdb as the password it accepts it there just fine. So I assume monetdb is still the default valid username/password for this stable nightly. But for some reason when I pass this as the user name and password in my JDBC connection it won't accept it.
The "stable" Java sources as of yesterday/today should work with the server/monetdb/merovingian as found on the same day.
This is to be expected, since databases created with monetdb/merovingian are not compatible with manually started databases. Merovingian adds a layer of security to your databases, using an encryption key.
Thanks. I asked on the list previously but did not see any answer - can someone explain what then merovingian uses for the user name / password by default, if not monetdb/monetdb? There is some cryptic info in the .conf file that says some setting is ignored if using merovingian but it doesn't go on to then say what setting IS used...
On 13-06-2008 12:40:04 -0700, Rt Ibmer wrote:
This is to be expected, since databases created with monetdb/merovingian are not compatible with manually started databases. Merovingian adds a layer of security to your databases, using an encryption key.
Thanks. I asked on the list previously but did not see any answer - can someone explain what then merovingian uses for the user name / password by default, if not monetdb/monetdb? There is some cryptic info in the .conf file that says some setting is ignored if using merovingian but it doesn't go on to then say what setting IS used...
merovingian sets the vault key, the thing that mserver5 complains about when it is not set (which is the default). This key is used to cypher and decypher your passwords. Hence, if you use another vault key, the passwords can no longer be decyhered to the value you think it should be.
merovingian sets the vault key, the thing that mserver5
Sets it to what exactly? And where is it set? A cryptic message in the .conf says something.secret is for mserver5 but ignored if using merovingian, but then does not go on to say what you are supposed to do/set if ineed using merovngian. I really don't care about using merovngian or not. I just need the db to start automatically at boot as a dameon. Monetdb seems like a great and fast engine but I have to say it has been really a huge uphill struggle with the amount of bugs and invalid setups I've run into. I've spent the past several days just trying to dig through this with no progress. I hope these bugs can be straightened out quickly. I'd really like to use it but must make some progress. Hopefully we can get this straightened out quickly? Thank you!
complains about when it is not set (which is the default). This key is used to cypher and decypher your passwords. Hence, if you use another vault key, the passwords can no longer be decyhered to the value you think it should be.
On 13-06-2008 13:09:10 -0700, Rt Ibmer wrote:
merovingian sets the vault key, the thing that mserver5
Sets it to what exactly? And where is it set? A cryptic message in the .conf says something.secret is for mserver5 but ignored if using merovingian, but then does not go on to say what you are supposed to do/set if ineed using merovngian.
in each database dir in the dbfarm, there is a file (*.secret I think) that stores the secret, which is exactly the argument that merovingian passes to mserver5.
I really don't care about using merovngian or not. I just need the db to start automatically at boot as a dameon.
If you don't care, from my point of view you're on your own.
Monetdb seems like a great and fast engine but I have to say it has been really a huge uphill struggle with the amount of bugs and invalid setups I've run into. I've spent the past several days just trying to dig through this with no progress. I hope these bugs can be straightened out quickly. I'd really like to use it but must make some progress. Hopefully we can get this straightened out quickly? Thank you!
You seem to walk a lot of paths that actually seem illogical to me as well. Maybe you better wait a week (or two) untill we have pushed the release out, and then try again using the released products.
in each database dir in the dbfarm, there is a file (*.secret I think) that stores the secret, which is exactly the argument that merovingian passes to mserver5.
Thank you! That is what I've been trying to figure out. And so it passes the value in the .secret file as the password that it should expect? However I am not seeing any such .secret files in there. Here is what I have for the demo: under dbfarm/demo there is just a bat and box dir. ls -l /usr/var/MonetDB5/dbfarm/demo/bat total 84 drwx------ 2 root root 4096 Jun 13 15:18 01 drwx------ 2 root root 4096 Jun 13 15:18 02 drwx------ 2 root root 4096 Jun 13 15:18 03 drwx------ 2 root root 4096 Jun 13 15:18 04 drwx------ 2 root root 4096 Jun 13 15:18 05 drwx------ 2 root root 4096 Jun 13 15:18 10 drwx------ 2 root root 4096 Jun 13 15:18 11 -rw------- 1 root root 268 Jun 13 15:17 2.desc -rw------- 1 root root 4 Jun 13 15:17 2.head -rw------- 1 root root 4 Jun 13 15:17 2.tail -rw------- 1 root root 4108 Jun 13 15:17 2.theap -rw------- 1 root root 268 Jun 13 15:17 3.desc -rw------- 1 root root 4 Jun 13 15:17 3.head -rw------- 1 root root 4 Jun 13 15:17 3.tail -rw------- 1 root root 4108 Jun 13 15:17 3.theap -rw------- 1 root root 268 Jun 13 15:17 4.desc -rw------- 1 root root 0 Jun 13 15:17 4.head -rw------- 1 root root 0 Jun 13 15:17 4.tail -rw------- 1 root root 4096 Jun 13 15:17 4.theap drwxr-xr-x 2 root root 4096 Jun 13 15:21 BACKUP drwxr-xr-x 2 root root 4096 Jun 13 15:21 LEFTOVERS ls -l /usr/var/MonetDB5/dbfarm/demo/box total 0
I really don't care about using merovngian or not. I just need the db to start automatically at boot as a dameon.
If you don't care, from my point of view you're on your own.
Sorry I think you misunderstood. I do not mean that I don't care about your product. I mean that I am not committed to using merovangian and am fine not using it. But my understand is that if I want my db to start up at boot time and jdbc to access it then that is what I have to do?
You seem to walk a lot of paths that actually seem illogical to me as well.
Here's all I'm trying to do: 1) create a db and schemas. I can do this successfully with mclient. 2) make monetdb start up at boot time and listen for connections using meroviangian. if there is another way please let me know. 3) use jdbc to access the db. I cannot do this because monetdb/monetdb gives an invalid credientials response using my jdbc as well as your jdbcclient. I am quite certain there is a bug here because if I use the RELEASE build than everything works great with regards to this!!! However I cannot use that build because of the other bugs I've reported which the latest nightly fixes - but then it introduces this problem. Unfortunately I cannot wait a couple weeks until the release as by then I will be forced to go with mysql which is dog-slow compared to monetdb. Please help!! Thank you very much!!
On 13-06-2008 13:32:42 -0700, Rt Ibmer wrote:
in each database dir in the dbfarm, there is a file (*.secret I think) that stores the secret, which is exactly the argument that merovingian passes to mserver5.
Thank you! That is what I've been trying to figure out.
And so it passes the value in the .secret file as the password that it should expect?
However I am not seeing any such .secret files in there. Here is what I have for the demo:
If you don't use `monetdb` to create a database, the file isn't created. I looked up what the file actually is called: ".vaultkey"
under dbfarm/demo there is just a bat and box dir.
There should be a ".vaultkey" file as well when created with `monetdb`. Merovingian uses that file.
I really don't care about using merovngian or not. I just need the db to start automatically at boot as a dameon.
If you don't care, from my point of view you're on your own.
Sorry I think you misunderstood. I do not mean that I don't care about your product. I mean that I am not committed to using merovangian and am fine not using it. But my understand is that if I want my db to start up at boot time and jdbc to access it then that is what I have to do?
My opinion is that you have to start merovingian at boot, as it is made exactly for doing what you want.
Here's all I'm trying to do:
1) create a db and schemas. I can do this successfully with mclient. 2) make monetdb start up at boot time and listen for connections using meroviangian. if there is another way please let me know. 3) use jdbc to access the db. I cannot do this because monetdb/monetdb gives an invalid credientials response using my jdbc as well as your jdbcclient.
I think you should switch 1) and 2). Do not manually start mserver5 yourself if you intend to use merovingian. Let monetdb and merovingian handle all interactions with the database server.
I am quite certain there is a bug here because if I use the RELEASE build than everything works great with regards to this!!! However I cannot use that build because of the other bugs I've reported which the latest nightly fixes - but then it introduces this problem.
Unfortunately I cannot wait a couple weeks until the release as by then I will be forced to go with mysql which is dog-slow compared to monetdb. Please help!! Thank you very much!!
Use the latest "nightly stable" sources (monetdb-install.sh --nightly=stable ...) and help us to resolve bugs by carefully describing your steps such that we can replay them. Thanks!
There should be a ".vaultkey" file as well when created with `monetdb`. Merovingian uses that file.
Thanks. I edited that file by deleting what was there, and replacing it simply with "monetdb" (without the quotes). Then I saved it off. Then I restart merovingian but it still says invalid credentials.
My opinion is that you have to start merovingian at boot, as it is made exactly for doing what you want.
That is what I am planning to do. But for now I am starting it by typing into the command window, for testing purposes.
1) create a db and schemas. I can do this successfully with mclient. 2) make monetdb start up at boot time and listen for connections using meroviangian. if there is another way please let me know. 3) use jdbc to access the db. I cannot do this because monetdb/monetdb gives an invalid credientials response using my jdbc as well as your jdbcclient.
I think you should switch 1) and 2). Do not manually start mserver5 yourself if you intend to use merovingian. Let monetdb and merovingian handle all interactions with the database server.
The first thing I do is run merovingian. Then I try my jdbc code as well as your jdbcclient.jar and it says "too many redirects. sorry". So then the only reason I am running mserver5 is as a diagnostic - just to see what it does when I try JDBC. And in that case it gives the invalid credientials. I am assuming merovingian ran into this too but instead of saying invalid credientials it says too may redirects as it tries.
I am quite certain there is a bug here because if I use the RELEASE build than everything works great with regards to this!!!
How do you explain that I do not have this problem running the RELEASE code, only with the nightly. I think something is broken since the release!
Use the latest "nightly stable" sources (monetdb-install.sh --nightly=stable ...) and help us to resolve bugs by carefully describing your steps such that we can replay them.
But I thought I have already done this? I already tried installing from scratch using --night=stable, and already laid out step by step what I am trying. Is there something else I can try? If you were getting an invalid credientials when trying to connect via jdbc to meroviangian how would you go about troubleshooting this?
On 13-06-2008 13:56:30 -0700, Rt Ibmer wrote:
There should be a ".vaultkey" file as well when created with `monetdb`. Merovingian uses that file.
Thanks. I edited that file by deleting what was there, and replacing it simply with "monetdb" (without the quotes). Then I saved it off. Then I restart merovingian but it still says invalid credentials.
It's not a password. It's a vault "key". The best thing to do here is to destroy and create the database such that it gets a new key assigned.
My opinion is that you have to start merovingian at boot, as it is made exactly for doing what you want.
That is what I am planning to do. But for now I am starting it by typing into the command window, for testing purposes.
That should work fine.
1) create a db and schemas. I can do this successfully with mclient. 2) make monetdb start up at boot time and listen for connections using meroviangian. if there is another way please let me know. 3) use jdbc to access the db. I cannot do this because monetdb/monetdb gives an invalid credientials response using my jdbc as well as your jdbcclient.
I think you should switch 1) and 2). Do not manually start mserver5 yourself if you intend to use merovingian. Let monetdb and merovingian handle all interactions with the database server.
The first thing I do is run merovingian. Then I try my jdbc code as well as your jdbcclient.jar and it says "too many redirects. sorry".
Ok, that is a bug, we need to fix.
So then the only reason I am running mserver5 is as a diagnostic - just to see what it does when I try JDBC. And in that case it gives the invalid credientials. I am assuming merovingian ran into this too but instead of saying invalid credientials it says too may redirects as it tries.
That makes sense. We should fix the "too many redirects" thing, and then things will get easier for you.
I am quite certain there is a bug here because if I use the RELEASE build than everything works great with regards to this!!!
How do you explain that I do not have this problem running the RELEASE code, only with the nightly. I think something is broken since the release!
Quite a lot has changed. If you'd do the same "workaround" on the current release, the same problem should arise.
Use the latest "nightly stable" sources (monetdb-install.sh --nightly=stable ...) and help us to resolve bugs by carefully describing your steps such that we can replay them.
But I thought I have already done this? I already tried installing from scratch using --night=stable, and already laid out step by step what I am trying. Is there something else I can try?
I only read your mail afterwards.
If you were getting an invalid credientials when trying to connect via jdbc to meroviangian how would you go about troubleshooting this?
I would like to have a debug log when you get "too many redirects". Please run jdbcclient with -Xdebug and send me the monet_XXXXXXXXXXX.log file.
The problem with the JDBC driver is that when running with merovingian I get: Maximum number of redirects reached, aborting connection attempt. Sorry.
Please try with http://www.ins.cwi.nl/~monet/tars/latest/stable/jdbcclient.jar and file a bug if the problem persists.
How do you file a bug? I didn't see it on the MonetDB web site. Link please.
then instead of running withmerovingian, as a test I ran with:
mserver5 --dbinit="include sql;"
and when running that way I get InvalidCredentialsException:checkCredentials:Invalid credentials for user 'monetdb'
The "stable" Java sources as of yesterday/today should work with the server/monetdb/merovingian as found on the same day.
I just installed from source the very latest stable nightly. It was no different than yesterday. I still get the above error when trying to connect with my JDBC application. I also get the exact same error when trying with jdbcclient.jar: java -jar jdbcclient.jar -umonetdb password: <monetdb> Database connect failed: InvalidCredentialsException:checkCredentials:Invalid credentials for user 'monetdb' *** Also - its been said several times that username/password works differently when using merovingian. Eventually once this bug is fixed I'll be using that - so can someone please explain how to set the username/password properly for jdbc when using merovingian. I realize that is not related to this bug, but something I'll need to understand once the bug is fixed so I'd like to know this in advance. Thank you.
On 13-06-2008 13:05:27 -0700, Rt Ibmer wrote:
The problem with the JDBC driver is that when running with merovingian I get: Maximum number of redirects reached, aborting connection attempt. Sorry.
Please try with http://www.ins.cwi.nl/~monet/tars/latest/stable/jdbcclient.jar and file a bug if the problem persists.
How do you file a bug? I didn't see it on the MonetDB web site. Link please.
SourceForge is quite cryptic about it, but here: http://sourceforge.net/tracker/?atid=482468&group_id=56967&func=browse
The "stable" Java sources as of yesterday/today should work with the server/monetdb/merovingian as found on the same day.
I just installed from source the very latest stable nightly. It was no different than yesterday. I still get the above error when trying to connect with my JDBC application.
I also get the exact same error when trying with jdbcclient.jar:
java -jar jdbcclient.jar -umonetdb password: <monetdb> Database connect failed: InvalidCredentialsException:checkCredentials:Invalid credentials for user 'monetdb'
*** Also - its been said several times that username/password works differently when using merovingian. Eventually once this bug is fixed I'll be using that - so can someone please explain how to set the username/password properly for jdbc when using merovingian. I realize that is not related to this bug, but something I'll need to understand once the bug is fixed so I'd like to know this in advance. Thank you.
either: use a new database (or remove the old one), or use merovingian again.
username/password properly for jdbc when using merovingian. I realize that is not related to this bug, but something I'll need to understand once the bug is fixed so I'd like to know this in advance. Thank you.
either: use a new database (or remove the old one), or use merovingian again.
This is happening after a fresh install. No db exists. Here are my steps: 1) start with a clean machine - no monetdb every installed previously. 2) run the .sh to install / build from source. BTW I am using the --optimise feature in case that matters. 3) once completed I am doing this: changing the /etc/monetdb5.conf file to set /mnt/MonetDB5/dbfarm as the farm location. Then doing this: mkdir -p /mnt/MonetDB5/dbfarm merovingian monetdb create demo monetdb start demo mclient -lsql --time --database=demo mclient connects fine with monetdb/monetdb But then neither jdbcclient.jar nor my real jdbc baesd app can connect - says invalid credentials for monetdb! Am I doing something wrong or is there a bug? Thank you.
On 13-06-2008 13:13:19 -0700, Rt Ibmer wrote:
This is happening after a fresh install. No db exists. Here are my steps:
Are you sure no dbs exist? Have you removed your entire dbfarm?
1) start with a clean machine - no monetdb every installed previously.
Ok.
2) run the .sh to install / build from source. BTW I am using the --optimise feature in case that matters.
What are the exact arguments, and from where do you call it? Do you use the super source tarball of the last release? Using --optimise is fine, and the MonetDB Team encourages you to use it in any situation where you aim for speed.
3) once completed I am doing this:
changing the /etc/monetdb5.conf file to set /mnt/MonetDB5/dbfarm as the farm location. Then doing this:
mkdir -p /mnt/MonetDB5/dbfarm merovingian monetdb create demo monetdb start demo mclient -lsql --time --database=demo
mclient connects fine with monetdb/monetdb
But then neither jdbcclient.jar nor my real jdbc baesd app can connect - says invalid credentials for monetdb!
Am I doing something wrong or is there a bug? Thank you.
Please post your `mserver5 --version`, it is important to know what version you are using.
Are you sure no dbs exist? Have you removed your entire dbfarm?
Yes I am certain because I am starting with a fresh clean build image for the server. This image has our base installation of our application without any monetdb every being installed.
2) run the .sh to install / build from source. BTW I am using the --optimise feature in case that matters.
What are the exact arguments, and from where do you call it? Do you use the super source tarball of the last release?
I am not using the tarball rather just using the .sh. Is that OK? This is exactly what I am doing: wget http://monetdb.cwi.nl/projects/monetdb//Assets/monetdb-install.sh chmod +x monetdb-install.sh ../monetdb-install.sh --enable-sql --nightly=stable --enable-optimise --prefix=/usr
3) once completed I am doing this:
changing the /etc/monetdb5.conf file to set /mnt/MonetDB5/dbfarm as the farm location. Then doing this:
mkdir -p /mnt/MonetDB5/dbfarm merovingian monetdb create demo monetdb start demo mclient -lsql --time --database=demo
mclient connects fine with monetdb/monetdb
But then neither jdbcclient.jar nor my real jdbc baesd app can connect - says invalid credentials for monetdb!
Am I doing something wrong or is there a bug? Thank you.
Please post your `mserver5 --version`, it is important to know what version you are using.
Here you go: MonetDB server v5.6.0 (32-bit), based on kernel v1.24.0 (32-bit oids) Copyright (c) 1993-2008 CWI, all rights reserved Visit http://monetdb.cwi.nl/ for further information Configured for prefix: /usr Libraries: Compiled by: root@domU-12-31-38-00-A5-55 Compilation: gcc -O2 -std=c99 -O6 -fomit-frame-pointer -finline-functions -falign-loops=4 -falign-jumps=4 -falign-functions=4 -fexpensive-optimizations -funroll-loops -frerun-cse-after-loop -frerun-loop-opt -ftree-vectorize Linking : /usr/bin/ld Thank you!
On 13-06-2008 13:36:30 -0700, Rt Ibmer wrote:
3) once completed I am doing this:
changing the /etc/monetdb5.conf file to set /mnt/MonetDB5/dbfarm as the farm location. Then doing this:
Ok, I used /var/tmp/test-dbfarm
mkdir -p /mnt/MonetDB5/dbfarm merovingian monetdb create demo monetdb start demo
This all went fine
mclient -lsql --time --database=demo
This gave me: (pegasus:/var/tmp) fabian% $INSTALL_DIR/bin/mclient -lsql --time --database=demo !SQLException:SQLinit:Catalogue initialization failed (pegasus:/var/tmp) fabian% Merovingian's log: MSG merovingian[26601]: database 'demo' already running since 2008-06-14 10:26:41, up min/avg/max: 0/0/0, crash average: 0.00 0.00 0.00 (1-0=0) MSG merovingian[26601]: proxying client 127.0.0.1:60461 for database 'demo' to mapi:monetdb://pegasus.ins.cwi.nl:50001/ MSG merovingian[26601]: client has 127.0.0.1:60461 disconnected from proxy ERR demo[26610]: !mvc_init: unable to create system tables The database afterwards becomes problematic for merovingian: (pegasus:/var/tmp) fabian% killall merovingian MSG merovingian[26601]: caught signal 15, Merovingian 0.7 stopping ... MSG merovingian[26601]: control channel closed MSG merovingian[26601]: Merovingian 0.7 stopping ... MSG merovingian[26601]: sending process 26610 (database 'demo') the TERM signal ERR merovingian[26601]: timeout of 7 seconds expired, sending process 26610 (database 'demo') the KILL signal TME 2008-06-14 10:30:20 Investigations pending...
On 14-06-2008 10:31:58 +0200, Fabian Groffen wrote:
changing the /etc/monetdb5.conf file to set /mnt/MonetDB5/dbfarm as the farm location. Then doing this:
Ok, I used /var/tmp/test-dbfarm
Right. When I do NOT change this location (and leave it to the default) all works fine, however, when I change this location, the scenario as below happens for me. Unfortunately I haven't been able to get your redirection limit error due to this.
On 14-06-2008 10:45:26 +0200, Fabian Groffen wrote:
On 14-06-2008 10:31:58 +0200, Fabian Groffen wrote:
changing the /etc/monetdb5.conf file to set /mnt/MonetDB5/dbfarm as the farm location. Then doing this:
Ok, I used /var/tmp/test-dbfarm
Right. When I do NOT change this location (and leave it to the default) all works fine, however, when I change this location, the scenario as below happens for me.
Ok, I didn't change sql_logdir to point to a different location, which caused at least the catalog initialisation errors I got.
Unfortunately I haven't been able to get your redirection limit error due to this.
Now I've both set up fine, all works fine for me.
participants (2)
-
Fabian Groffen
-
Rt Ibmer