Username
Forgot password?
Welcome to our site!
Or Join with FTTF

Trying to install LampCMS on Dreamhost VPS

0

5252 views
Alright, I've gotten MongoDB installed on my server. I'm pretty confident that my issue lies in the !config.ini file. I've set up my MySQL database info under the [DB] section, though I've left the TCP_Port_number blank. I'm sure I need to change the information in the [MONGO] section, but I have no idea what to change it to.

Like I said, I'm working on a Dreamhost VPS so anybody with experience in this, please help! I've never worked with MongoDB before but I know I've got it enabled on the right server. I've also verified that the mongo PHP extension is installed. However, I have no idea how to use MongoDB from this point. I've gone through the MongoDB docs and tried to access the Mongo shell but I've had no success.

If it helps, the error I'm seeing is:
Error: unauthorized db:LAMPCMS lock type:-1 client:127.0.0.1

You can check it out
here. Thanks in advance!


UPDATE 1:
So, coolest thing ever. Dreamhost ran across this post and took a look into the issue without me ever contacting them. Freaking. Awesome.

Anywho, their support guy determined that my syntax was wrong in this line:

server = "mongodb://username:password@127.0.0.1:27017"






So they fixed that. However, there was still an error. After enabling debugging, this is the full error we're seeing:

Error in Exception handler: : file_put_contents(/home/trezytv/qa.trezy.tv/logs/cgi-php.log)
[function.file-put-contents]: failed to open stream: Permission denied in
/home/trezytv/qa.trezy.tv/lib/Lampcms/Log.php on line: 214 line 214#0
[internal function]: LampcmsErrorHandler(2, 'file_put_conten...', '/home/trezytv/q...', 214, Array) #1
/home/trezytv/qa.trezy.tv/lib/Lampcms/Log.php(214): file_put_contents('/home/trezytv/q...', '?DEBUG November...', 10) #2
/home/trezytv/qa.trezy.tv/lib/Lampcms/Log.php(240): Lampcms\Log::l('Exception caugh...', 2) #3
/home/trezytv/qa.trezy.tv/lib/!inc.php(337): Lampcms\Log::d('Exception caugh...', 2) #4
/home/trezytv/qa.trezy.tv/lib/Lampcms/Exception.php(259): d('Exception caugh...') #5 /home/trezytv/qa.trezy.tv/lib/!inc.php(86): Lampcms\Exception::formatException(Object(Lampcms\DevException)) #6
[internal function]: exception_handler(Object(Lampcms\DevException)) #7
{main}






They weren't able to get past that point since they're not actually familiar with LampCMS, so I'm back. Any suggestions?


UPDATE 2:
Okay, now I've beaten the previous error. I ran across this support question which helped me out. I just needed to fix the permissions for the logs folder and set the file destination in /lib/LampCMS/Log.php.

Now I have a new error:


Error: MongoConnectionException caught. Unable to connect to Mongo: Couldn't authenticate with database admin: username [root]

Exception Class: Lampcms\DevException

Error code: 1

File: /home/trezytv/qa.trezy.tv/lib/Lampcms/Mongo/DB.php

Line: 159

Trace: 
#0 /home/trezytv/qa.trezy.tv/lib/Lampcms/Registry.php(180): __construct(Lampcms\Config\Ini)
#1 /home/trezytv/qa.trezy.tv/lib/Lampcms/Registry.php(506): Lampcms\{closure}(Lampcms\Registry)
#2 /home/trezytv/qa.trezy.tv/lib/Lampcms/Registry.php(483): Lampcms\{closure}(Lampcms\Registry)
#3 /home/trezytv/qa.trezy.tv/lib/Lampcms/Cache/Mongo.php(111): __get('Mongo')
#4 /home/trezytv/qa.trezy.tv/lib/Lampcms/Cache/Cache.php(146): factory(Lampcms\Registry)
#5 /home/trezytv/qa.trezy.tv/lib/Lampcms/Registry.php(227): __construct(Lampcms\Registry)
#6 /home/trezytv/qa.trezy.tv/lib/Lampcms/Registry.php(506): Lampcms\{closure}(Lampcms\Registry)
#7 /home/trezytv/qa.trezy.tv/lib/Lampcms/Registry.php(483): Lampcms\{closure}(Lampcms\Registry)
#8 /home/trezytv/qa.trezy.tv/lib/Lampcms/Registry.php(211): __get('Cache')
#9 /home/trezytv/qa.trezy.tv/lib/Lampcms/Registry.php(506): Lampcms\{closure}(Lampcms\Registry)
#10 /home/trezytv/qa.trezy.tv/lib/Lampcms/Registry.php(483): Lampcms\{closure}(Lampcms\Registry)
#11 /home/trezytv/qa.trezy.tv/www/index.php(70): __get('Tr')




Suggestions welcome!
 
Edited Nov 26, 2012 04:12 PM
Formatting
asked November 20, 2012 at 3:43 PM

 us
Updated the original post to reflect the solution to the original problem and the new problem that has arisen.
flag
Nov 26, 2012 02:48 PM
Updated the original post again to show the solution to the previous problem, as well as the new issue.
flag
Nov 26, 2012 03:18 PM

4 Answers

0
Best answer
 
Problem solved!!! Dreamhost support had placed single quotes around the password on my server line. Simply removing the quotes fixed the problem. Woohoo!
flag
answered November 27, 2012 at 9:27 AM
0
 
you can try with config

server = "mongodb://127.0.0.1:27017"
flag
answered November 26, 2012 at 3:25 PM
Can you clarify? Do you mean just change the server= line in !config.php to not have a username/pass?
flag
Nov 26, 2012 03:50 PM
@Trezy Peebles
Are you having SSH permission? You try to type: "mongo". If it's not require user and password to connecting. That means when you set !config: server = line, it will be run
flag
Nov 26, 2012 03:56 PM
@Tùng Mang Viên
I *think* I understand what you're saying. The server is requiring authentication. If I leave the username/password off of the server line and check the web page I get a response that it's unauthorized. If I add the username/password, I get the MongoExceptionConnection which you should be able to see here: http://qa.trezy.tv
flag
Nov 26, 2012 04:03 PM
@Trezy Peebles
So, you should try to access mongodb with SSH, then using that user and pass to config in lampcms. Because, I think you don't have user/pass to access mongodb, not related with lampcms
flag
Nov 26, 2012 04:11 PM
Ah, I understand a bit better. I do have an admin account with which I can hook up to my mongoDB via SSH. I have also created a separate user in my lampcms database inside of mongoDB specifically for lampcms. Unfortunately, I'm getting the same error whether I use the admin account or the new account. Is there a way to apply some sort of permissions inside mongoDB? I didn't see any way to do so in the mongoDB documentation, but I may have missed something.
flag
Nov 26, 2012 04:22 PM
0
 
Can you post your config of mongodb connect in !config.ini. Maybe I can help you!
flag
Edited Nov 22, 2012 11:43 AM
fix
answered November 22, 2012 at 11:42 AM
Pages : 1 | 2 >

Your answer

Join with account you already have

FTTF

Preview

Alert