हेओ शुरू करते समय लाइब्रेरी लोड नहीं हुई। अगर किसी अन्य धागे में इस प्रश्न का उत्तर दिया गया है तो मैं पहले से माफी माँगता हूं। मैंने साइट के माध्यम से खोज की है लेकिन मुझे कोई जवाब नहीं मिला। हालांकि, निकटतम संबंधित मुद्दा Ruby on Rails/PostgreSQL - Library not Loaded error when starting server- libq.5.dylib था, लेकिन इसे कभी हल नहीं किया गया था, और उत्तर मेरी मदद नहीं करता है।रेल/पोस्टग्रेएसक्यूएल पर रूबी - सर्वर
मैं अपने मैक ओएसएक्स 10.6.8 पर पोस्टग्रेएसक्यूएल चलाने की कोशिश कर रहा हूं। मेरे पास पहले से रूबी 1.9.3p392 और रेल 3.2.13 स्थापित है।
जब से मैं 10.6.8 करती हैं, और PostGresApp 10.7+ की आवश्यकता है, मैं यहाँ मैनुअल संस्थापक (v9.2.3) उपलब्ध का उपयोग कर पीजी स्थापित करने की कोशिश की: http://www.enterprisedb.com/products-services-training/pgdownload
मैं पहली बार में उसके डिफ़ॉल्ट पथ के लिए इसे स्थापित:/लाइब्रेरी/PostgreSQL/9.2 /। मैंने फिर पीजी मणि (PATH=$PATH:/Library/PostgreSQL/9.2/bin
sudo gem install pg
) स्थापित किया। जब मैंने अपना लोकहोस्ट लॉन्च करने के लिए rails s
की कोशिश की, तो मुझे नीचे त्रुटि मिली।
कुछ पढ़ने के बाद, मैंने अनुमान लगाया कि यह एक पथ त्रुटि हो सकती है, इसलिए मैंने पीजी मणि हटा दिया, और फिर postgresql अनइंस्टॉलर का उपयोग किया। मैंने फिर /users/stewartmccoy/Library/PostgreSQL/9.2/... में पीजी को पुनर्स्थापित किया और फिर पीजी मणि को पुनर्स्थापित किया। लेकिन मुझे अभी भी वही त्रुटि मिलती है।
कोई विचार है कि मैं PostgreSQL को सही तरीके से कैसे स्थापित कर सकता हूं और मेरे रेल सर्वर को चला सकता हूं?
stewart-mccoys-macbook:footy_subs stewartmccoy$ rails s
/Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/pg-0.14.1/lib/pg.rb:4:in `require': dlopen(/Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/pg-0.14.1/lib/pg_ext.bundle, 9): Library not loaded: libpq.5.dylib (LoadError)
Referenced from: /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/pg-0.14.1/lib/pg_ext.bundle
Reason: image not found - /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/pg-0.14.1/lib/pg_ext.bundle
from /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/pg-0.14.1/lib/pg.rb:4:in `<top (required)>'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:72:in `require'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:72:in `block (2 levels) in require'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:70:in `each'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:70:in `block in require'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:59:in `each'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:59:in `require'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler.rb:132:in `require'
from /Users/stewartmccoy/Code/footy_subs/config/application.rb:13:in `<top (required)>'
from /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/commands.rb:53:in `require'
from /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/commands.rb:53:in `block in <top (required)>'
from /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/commands.rb:50:in `tap'
from /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/commands.rb:50:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
stewart-mccoys-macbook:footy_subs stewartmccoy$ gem uninstall pgSuccessfully uninstalled pg-0.14.1
stewart-mccoys-macbook:footy_subs stewartmccoy$ PATH=$PATH:/users/stewartmccoy/Library/PostgreSQL/9.2/bin sudo gem install pg
Password:
Fetching: pg-0.14.1.gem (100%)
Building native extensions. This could take a while...
Successfully installed pg-0.14.1
1 gem installed
Installing ri documentation for pg-0.14.1...
Installing RDoc documentation for pg-0.14.1...
stewart-mccoys-macbook:footy_subs stewartmccoy$ rails s
/Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/pg-0.14.1/lib/pg.rb:4:in `require': dlopen(/Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/pg-0.14.1/lib/pg_ext.bundle, 9): Library not loaded: libpq.5.dylib (LoadError)
Referenced from: /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/pg-0.14.1/lib/pg_ext.bundle
Reason: image not found - /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/pg-0.14.1/lib/pg_ext.bundle
from /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/pg-0.14.1/lib/pg.rb:4:in `<top (required)>'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:72:in `require'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:72:in `block (2 levels) in require'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:70:in `each'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:70:in `block in require'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:59:in `each'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler/runtime.rb:59:in `require'
from /Users/stewartmccoy/.rvm/gems/[email protected]/gems/bundler-1.3.4/lib/bundler.rb:132:in `require'
from /Users/stewartmccoy/Code/footy_subs/config/application.rb:13:in `<top (required)>'
from /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/commands.rb:53:in `require'
from /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/commands.rb:53:in `block in <top (required)>'
from /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/commands.rb:50:in `tap'
from /Users/stewartmccoy/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/commands.rb:50:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
* thankyou * उचित स्तर का विस्तार प्रदान करने के लिए - पीजी संस्करण, पीजी पैकेज प्रकार, होस्ट ओएस, आदि –
संभव डुप्लिकेट [रेल/पोस्टग्रेएसक्यूएल पर रूबी - सर्वर- libq.5.dylib शुरू करते समय लाइब्रेरी लोड नहीं हुई त्रुटि) (http://stackoverflow.com/questions/9182645/ruby-on-rails-postgresql-library-not-loaded-error-when-starting-server-libq) – bummi