Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email email@example.com
From: Johan De Meersman (vegivamptuxera.be)
Date: Thu Jan 14 2010 - 10:14:27 CST
On Thu, Jan 14, 2010 at 5:02 PM, <tony.chamberlainlemko.com> wrote:
> The other thing is, mysql appears to keep changing between
> /etc/init.d/mysqld and /etc/init/mysql so I also have to do an
> ls /etc/init.s/mysql* to figure out what to use to start which is also
> kind of a pain.
Hmm... I'm no RedHat/CentOS man, but if there's also init.1 through init.6,
it should be pretty safe to ignore those - the scripts in there should be
symlinks to the init.d ones.
> -----Original Message-----
> From: Johan De Meersman [mailto:vegivamptuxera.be]
> Sent: Thursday, January 14, 2010 09:44 AM
> To: tony.chamberlainlemko.com
> Cc: mysqllists.mysql.com
> Subject: Re: version
> You *should* be using a package manager (perfectly fine RPMs available for
> all your needs), but if you must do this, it's a reasonably safe bet to
> right-align and zero-pad all your number to 4 digits, at which point you're
> free to concatenate them and treat them as a single number.
> 126.96.36.199.19 then becomes 0014 0012 0005 0000 0019 which becomes
> You'd probably be safe with 3 or maaaaaaaybe even two positions, depending
> on how many releases get done :-)
> The better-but-more-work way is to compare every number separately,
> with the major release.
> On Thu, Jan 14, 2010 at 4:21 PM, <tony.chamberlainlemko.com> wrote:
> > I have an install script that does some stuff with mysql (i.e. install,
> > start, etc). It installs
> > mysql Ver 14.12 Distrib 5.0.19, for pc-linux-gnu (i686) using readline
> > This was good when we just used CentOS 4.5. Now we are doing some later
> > CentOS versions and the mysql version may be higher.
> > I want to do something like "mysql --version" and process the result and
> > if the version is >= 5.0.19 skip the mysql installation and just do the
> > other stuff. I can't compare as it is right now because the . and stuff
> > may screw up the comparison (e.g. ver 5.2 will show as greater than 5.19
> > eg).
> > I want to know, if I break the individual pieces like 14 12 5 0 19 I can
> > some sort of calculation to determine a number that I can actually
> > Or can I just remove all the decimal points, like 188.8.131.52.19 becomes
> > 14125019? I might have to make it like 14120050019 or something.
> > What is an algorithm I can use?
> > Thanks
> > --
> > MySQL General Mailing List
> > For list archives: http://lists.mysql.com/mysql
> > To unsubscribe: http://lists.mysql.com/mysql?unsub=vegivamptuxera.be
> Bier met grenadyn
> Is als mosterd by den wyn
> Sy die't drinkt, is eene kwezel
> Hy die't drinkt, is ras een ezel
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe: http://lists.mysql.com/mysql?unsub=vegivamptuxera.be
Bier met grenadyn
Is als mosterd by den wyn
Sy die't drinkt, is eene kwezel
Hy die't drinkt, is ras een ezel