LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-07-2004, 10:36 AM   #1
sdebiasio
LQ Newbie
 
Registered: Jul 2004
Posts: 22

Rep: Reputation: 15
How to resolve log rotation error?


Hi,

My log file rotation function is not working, I keep getting the following error emailed to me from Cron:

Enter password: /usr/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user: 'root@localhost' (Using password: NO)'

Anyone know how I can resolve this? The root account is set up with a password in the MySQL user table. Do I need to set up a new account with no password required?

Thanks!
 
Old 09-07-2004, 10:40 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,598

Rep: Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532
One solution is this, i.e. create a new full priviledged user with to password and the other is to supply the root password in mysqladmin. If I remember well you can run it with -u root -p password to do your job.
Regards
 
Old 09-07-2004, 11:42 AM   #3
sdebiasio
LQ Newbie
 
Registered: Jul 2004
Posts: 22

Original Poster
Rep: Reputation: 15
Thanks for your help!

When I try to edit mysqladmin, I get a bunch of weird characters. How can I edit this file to supply the password? (I assume that's what I need to do?)

Also, if instead, I create a new full-privileged user with no password, do I simply need to set up the cron job under that username?
 
Old 09-07-2004, 12:06 PM   #4
scuzzman
Senior Member
 
Registered: May 2004
Location: Hilliard, Ohio, USA
Distribution: Slackware, Kubuntu
Posts: 1,851

Rep: Reputation: 47
If you get a bunch of wierd characters, I think it's probably a binary. Personally, I don't use SQL, but i think you may actually want to run it like this:
Code:
[user@host ~]$ mysqladmin -u root -p PASSWORD
 
Old 09-08-2004, 03:48 AM   #5
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,598

Rep: Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532
You don't edit mysqladmin. You just have to run it as scuzzman said. Or if you can create a full priviledged user with no password you can run it like this:
Code:
mysqladmin -u full-user
so it does not ask for a password
Perhaps you can provide us with the script or the crontab entry to help you more.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Webalizer With Log Rotation dmedici Linux - Software 0 08-17-2004 10:06 AM
Snort log rotation suggestions zerocomm Linux - Security 1 05-26-2004 11:23 PM
manual log rotation will103 Linux - Newbie 2 04-20-2004 03:20 AM
disable log rotation in site krishn Linux - General 1 07-28-2003 08:53 AM
Log rotation - NewB nrastogi Linux - Software 1 02-12-2003 11:44 PM


All times are GMT -5. The time now is 06:18 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration