-
Notifications
You must be signed in to change notification settings - Fork 62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't Acess DB even with sslmode=disable #10
Comments
Looks Like the error is returned when the user doesn't provide a password too ... |
Gabriel, Since you wrote this, I've fixed my email to highlight issues people open on this project. I'm sorry you got lost in the shuffle. I'm hoping you got a solution figured out. |
I am having same issue on windows. Using postgres 9.6.1 installed locally attempting to compare 2 databases within the same local postgres instance. Any workaround? |
Hopefully someone else will comment. I don't have any ideas right now. |
Ok, originally was attempting to run pgdiff from a script because there are so many options. In continuing to test, when pgdiff run directly on the command line, it works fine. I tried a variety of methods of starting pgdiff from a script and all failed with message "SSL not enabled on server". Very weird, perhaps this is a situation where when run as script network permissions are blocked or something of that nature. This was on windows 10, I didn't test on linux. As a suggestion that might avoid people putting the commands into scripts, it might be nice to have a configuration file with all the options in TOML format (https://github.com/pelletier/go-toml) and just pass a single path to config file as a single argument to pgdiff. |
Hi, I encountered the same problem on Windows with PostgreSQL 9.6.1 having a database user that does not need a password (setting connection method to Did not try it as I don't have a Go SDK installed, but maybe the password must not be part of the connection string, if it is empty? |
hstadler, Thanks for your insight. I'm at work, but I can check if the password is included or not when it is empty on my way home on the bus. |
Thx for your quick response! This is only a guess, so not sure if this would solve the problem... |
I have same problem, and it'll be fixed when I change 'trust' to 'md5', and use password in the command line. |
Same problem macOS. |
Same, Linux. |
Same (Linux CentOS 7, PostgreSQL 9.6.6)...
I'm trying to compare two schemas on a same database (production and development schemas), my connections at |
I'd love to figure out what people have done to make this work. I noticed this problem before (more than a year ago) but it was only temporary and I never figured out what was different. |
@joncrlsn it seems to be password related. When the password is an empty string then one error. When the password is a non-empty string then another error. My localhost database doesn't have password.
|
I can also confirm adding the |
I might be able to fix this. When the connection string is built, it includes the 'password=' part of the string even if there is no password specified. It might be as simple as not including 'password=' in that case. |
I made it work with a patch to pgutil:
|
same problem here; I don't use a password for my local env and this is not supported. Since pretty much all PG tools know how to use it wouldn't it much easier to accept a connection string for the two databases? Any reason the patch from @ivoras was not applied? |
Hello My Friend,
I'm trying to test the pgdiff solution on a linux machine, but I'm receiving the following error:
2016/08/19 12:11:24 Error running querypq: SSL is not enabled on the server
But looks like the option is correctly set as stated:
-- schemaType: TABLE
-- db1: {dbmon IP1 5432 zabbix sslmode=disable}
-- db2: {dbmon IP2 5432 zabbix sslmode=disable}
-- Run the following SQL against db2:
Can you give me some advice on how can I get rid of this error (without the need to implement SSL on servers)?
The text was updated successfully, but these errors were encountered: