LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 12-18-2006, 05:49 PM   #1
darthbator
LQ Newbie
 
Registered: Oct 2006
Distribution: Ubuntu 6.10, Red Hat 9, Mac OS X
Posts: 11

Rep: Reputation: 0
ubuntu cacti install issues


I have been trying to get this to work for months now, I started on an OS 10.4.8 machine and ended up moving to ubuntu since I am a little more familiar with linux then unix. I still cannot get cacti up and running although I am now pretty sure that this has to do with adodb.

This message has been cross posted from the ubuntu forums

Hello there everyone recently I have run into some issues trying to get cacti installed on my Ubuntu 6.10 server at work. I was originally trying to get it to run an old G4 Power Mac, however repeated failure at getting graphs to display and a mysql.sock to create has led me back to linux.

So I decided to install cacti just like I would on any other system. First I got LAMP running. (all commands are run as root)

apt-get -u install apache2
apt-get -u install mysql-server
apt-get -u install php4

So now I have apache2 php4 and mysql5 all up and running and by the looks of phpinfo() all playing happily together. So I decided to try installing cacti.

apt-get -u install cacti

cacti pulls down and installs (along with some dependencies like dbconf-common, php4-snmp etc). dbconf offers to configure it for me but I decline, as I would rather do it myself.

So now that everything is installed I get to configuring mysql. First I create the cacti database

mysqladmin -u root create cacti

now I create a user to admin that databse

useradd cactiuser -p userspassword

I head back into mysql and grant that user permissions to the table

(console)mysql -u root
(mysql)GRANT ALL ON cacti.* TO cactiuser@localhost IDENTIFIED BY 'userspassword';
(mysql)flush privileges;
(mysql)exit


Looks good to me so far so I head to /usr/shared/cacti/site/include/config.php and add

$database type = "mysql";
$database_default = "cacti";
$database_hostname = "localhost";
$database_username = "cactiuser";
$database_password = "userspassword";

after that I quickly change the ownership or rra and log to cactiuser

chown -R cactiuser ./log ./rra

Now I dump a quick symbolic link in the www root and I'm good to go

cd /var/www
ln -s /usr/share/cacti/site cacti


done and done, now I run a quick test just to make sure the user is able to connect to the database.

mysql -u cactiuser -h localhost -p cacti

success, it logs into the mysql client and I am able to show tables; and see the cacti table.

So I point my browser to http://localhost/cacti and I get the following error..

Warning: mysql_pconnect(): Access denied for user 'www-data'@'localhost' (using password: NO) in /usr/share/php/adodb/drivers/adodb-mysql.inc.php on line 372

hmmmm ok, I'm not exactly the most familiar with ado but I decided to take a look at it anyways, line 372 of adodb-mysql.inc.php reads

$this->_connectionID = mysql_pconnect($argHostname,$argUsername,$argPassword,$this->clientFlags);

ummm ok back to being a n00b because I don't know what that means nor how to go about fixing it. thanks for bearing with my lengthy explanation, and thank you in advance for any help you guys are able to provide.
 
Old 12-21-2006, 03:52 AM   #2
sheryco
Member
 
Registered: Feb 2003
Location: FTWorth, TX
Distribution: Gentoo, Debian, CentOS, FreeBSD, NetBSD & OpenBSD
Posts: 55

Rep: Reputation: 15
I had issues the first time I install cacti when I install on my debian machine.
So I logged into the server via ssh and ...........
Quote:
#mysql -uroot
mysql>GRANT ALL ON cacti.* TO 'cactiuser'@'%' IDENTIFIED BY 'userspassword';
mysql>flush privileges;
mysql>\q
That was it.
All mysql connection errors disappeared.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how to install & configure cacti on Ubuntu linux ketut_hendratha Linux - Newbie 4 08-23-2006 05:30 AM
can you install games on ubuntu that are windows?my children love ubuntu but we can't chasity Linux - Software 3 07-14-2006 12:15 AM
ubuntu install issues boxerboy Ubuntu 16 09-12-2005 12:47 PM
Ubuntu apt-get issues biojayc Linux - Software 2 08-22-2005 08:08 PM
Clean install from Ubuntu Warty to Ubuntu Hoary Erik_the_Red Linux - Newbie 2 06-05-2005 07:14 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 12:45 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration