If you push play, the video should scoot out to about the 14m40s mark where MySQLTuner appears on one of the slides. Thanks to Trent Hornibrook for letting me know!
If you push play, the video should scoot out to about the 14m40s mark where MySQLTuner appears on one of the slides. Thanks to Trent Hornibrook for letting me know!
I enjoy using CPAN because it installs Perl modules with a simple interface, fetches dependencies, and warns you when things are about to end badly. However, one of my biggest complaints is when it constantly confirms installing dependencies. While this is an annoyance if you have to install a module with many dependencies (or if you’re working with CPAN on a new server), you can tell CPAN to automatically confirm the installation of dependencies.
To do this, simply bring up a CPAN shell:
perl -MCPAN -e shell |
Run these two commands in the CPAN shell:
o conf prerequisites_policy follow o conf commit |
Now, exit the CPAN shell, start the CPAN shell, and try to install a module that you need. All dependencies will be automatically confirmed, downloaded and installed.
The first line sets your dependency policy to follow rather than ask (the default). The second line tells CPAN to write the changes to your user’s CPAN configuration file to make them permanent.
A big thanks goes out to Lee Hambley for the fix.
WARNING: There are some occasions where you would not want to install dependencies from CPAN. Examples of these situations are when your operating system’s package manager (yum, up2date, apt-get, aptitude, etc) has installed Perl modules in an alternative location or when you have manually installed modules in a non-standard way. I’m a Red Hat guy, and these problems rarely arise on Red Hat/Fedora systems, but your mileage may vary.
MySQLTuner 0.9.9 is now available for download. There’s a new wiki for the script at wiki.mysqltuner.com. The new wiki contains links to downloads, changelogs, and other details.
If you want to know when the latest releases are available, there are multiple options:
--checkversion option when you run the scriptI was working with a CentOS 5 x86_64 installation running VMWare server last week when I stumbled upon this error:
Use of uninitialized value in string eq at /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi/VMware/VmPerl.pm line 114.
You can run the vmware-cmd application with this error (it’s not a fatal error) and keep going with your normal business. However, if you want to remove the error, comment out lines 114 and 115 in the Perl module referenced by the error:
die "Perl API Version does not match dynamic library version."
unless (version() eq $VERSION);
Commenting out these lines does not affect the VMWare server in any way.
One of the most frustrating aspects of CPAN is connecting to mirrors via FTP. Most of the time, the mirrors are extraordinarily slow when it comes to FTP logins, and they often fail. As we all know, RHEL enjoys pulling some shenanigans (Scalar::Util – enough said) when perl receives an upgrade, and when I need CPAN to work quickly, it often does the opposite.
I was struggling to find a way to reconfigure CPAN to use HTTP mirrors rather than FTP, but I couldn’t figure out where CPAN was holding this data. It wasn’t in ~/.cpan and there was nothing in /etc for it. However, I found that you can reconfigure CPAN by running the following command:
# perl -MCPAN -e shell
CPAN: File::HomeDir loaded ok (v0.69)
cpan shell -- CPAN exploration and modules installation (v1.9205)
ReadLine support enabled
cpan[1]> o conf init
The configuration script will run again as if you had never configured CPAN. Best of all, if you need to stop mid-way through the reconfiguration, your original configuration is still there. If you’d rather just adjust your mirror list rather than starting over completely with the CPAN configuration, use the following:
Display your current mirrors:
o conf urllist
Delete the first mirror in your list:
o conf urllist shift
Delete the last mirror in your list:
o conf urllist pop
Add on a new mirror:
o conf urllist push http://cpan.mirror.facebook.com/
Save your mirror changes:
o conf urllist commit