Library not loaded: /usr/local/opt/readline/lib/libreadline.6.2.dylib

后端 未结 22 1708
闹比i
闹比i 2020-12-02 06:30

I just installed posgresql with homebrew and when I go on to type the command

psql

I get the following error:

dyld: Library         


        
相关标签:
22条回答
  • 2020-12-02 06:33

    I was getting the exact same error, but the above answers didn't work for me. I had to reinstall postgresql.

    brew reinstall postgresql

    0 讨论(0)
  • 2020-12-02 06:39

    It seems to me the problem is about update readline package. postgres tryied to use /usr/local/opt/readline/lib/libreadline.7.dylib in my case. So i just created a symlink to existing version of library /usr/local/opt/readline/lib/libreadline.8.dylib.

    worked for me:

    ln -s /usr/local/opt/readline/lib/libreadline.8.dylib /usr/local/opt/readline/lib/libreadline.7.dylib
    
    0 讨论(0)
  • 2020-12-02 06:42

    I had this issue, and the key for me was to reinstall both readline and postgres. Once postgres was reinstalled, the issue was resolved.

    0 讨论(0)
  • 2020-12-02 06:42

    I had this problem when I updated readline to version 7 by accident. I uninstalled readline and brew remind me 6.3.8 is still installed. It seems that version 7 is not working with PSQL at the moment.

    0 讨论(0)
  • 2020-12-02 06:42

    You could try brew doctor and see what it says.

    Possibly all you need is brew link --overwrite bash.

    For me, I just upgraded brew since OS X EL Capitan had some security upgrade that affetcs my /usr folder. During the brew upgrade, the bash link is broken, and this is what brew doctor tells me.

    So I just run brew link --overwrite bash and everything's fine.

    0 讨论(0)
  • 2020-12-02 06:43

    You might want to check if you have anything else symlinked to postgresql. I had previously linked to the postgres93 package, which, as of May '17, is unsupported and has been removed. Removing that link and then relinking worked for me:

    brew unlink postgresql93
    brew link postgresql
    
    0 讨论(0)
提交回复
热议问题