[SWLUG] Any tips on locating this file.

Justin Mitchell justin at discordia.org.uk
Tue Aug 17 12:04:28 UTC 2004


> For your latter suggestion. Try using find with the -mtime <no. of day> 
> parameter. I use this for doing incremental backups. It picks up all 
> files modified since so many days ago. so "find / -mtime 30" should pick 
> up all files in the last month although a little more syntax would 
> probably be in order but you get the idea.
Actually, that gives you files which were modified exactly 30 days ago,
to get files within the last 30 days would be '-mtime -30'

> You could minimise the number of files depending on how you installed mysql.
> If from tarball you could generate a find script that only looks at 
> those files listed in the tarball.
> If from rpm use rpm -q --filesbypkg <mysql package name> to likewise get 
> a list of files.
if you have rpm, a much easier way is to ask the rpm system to tell you
which files have changed since they were shipped.
eg: rpm -V mysql-server


> >Last week I was working on a problem that involved running PHP on my desktop 
> >machine via 127.0.0.1 I could not get it to interface to my MYSQL Database.
> >I fiddled arounf trying to find out what was wrong and then gave up decided I 
This is likely because mysql should now ship so that it only listens to
its unix domain socket, and not to the internet, which prevents
unauthorised remote access.

if the default of not specifying a host in the mysql_connect() call
doesnt work, then try something like this as the hostname :-
'localhost:/var/lib/mysql/mysql.sock'


> >What I need is either a way of searching all files for the string. which is 
> >rather cumbersome or a way of listing all files that have been changed in the 
> >last week. If I can do the latter I may well be able to spot it.
grep -r mystring /
will do a recursive search of the entire system.

i would guess you changed the equivalent of your /etc/rc.d/init.d/mysqld
script which starts up the server. So searching just in /etc would be a
good start.





More information about the Swlug mailing list