Verizon Wireless Router default DNS Server trouble

A location we serve recently added Verizon Fios for broadband, with the Wifi Router MI424WR.
The connection speed was fantastic but they were having problems connecting to specific websites. Reloading would bring up the page normally about 1 out of 3 times. The rest of the time it was a “page not found” error. It really seemed like a DNS problem; some of Verizon’s default DNS servers must have the right answer while others don’t.

Figuring out how to set the DNS servers that this router uses for DHCP wasn’t easy!

On the “My Network” page, I had to click on “Broadband Connection (Ethernet/Coax) Properties”

Then “Settings” at the bottom. On the settings page was a drop down menu for “DNS Server” where I changed it to “use the following DNS Server Addresses” and entered in some well known public DNS servers such as google’s.

Then they didn’t have problems accessing sites any more!

Posted in Uncategorized | Leave a comment

httpd: apr_sockaddr_info_get() failed for HOSTNAME

After upgrading Apache, I was seeing the subject error. To fix it, I put the full hostname into the /etc/hosts file on the line that begins with 127.0.0.1

What I’m not sure of is why this only happens on some servers, but not all…?

Posted in Uncategorized | Leave a comment

Can’t connect to local MySQL server through socket

on a mysql server while trying to connect from command line, i just get:
ERROR 2002 (HY000): Can’t connect to local MySQL server through socket ‘/var/run/mysqld/mysqld.sock’ (2)

I see that mysql is creating the socket in /var/lib/mysql/mysql.sock
So to correct the problem, I created a symlink from the actual socket to where mysql command is looking;
mkdir /var/run/mysqld
cd /var/run/mysqld
ln -s /var/lib/mysql/mysql.sock mysqld.sock

Then mysql connects from command line. What I’d like to know is, what tells command line to look for the sock at ‘/var/run/mysqld/mysqld.sock’, even though my.cnf is specifying ‘/var/run/mysql/mysql.sock’ ?

Posted in Uncategorized | Leave a comment

Can’t kill a non-numeric process ID at /usr/local/share/perl/5.14.2/File/Pid.pm line 124

update the File/Pid.pm as per https://rt.cpan.org/Public/Bug/Display.html?id=18960

pico +122 /usr/local/share/perl/5.14.2/File/Pid.pm

add ‘or return undef’ before the semicolon on the line with ‘my $pid = $self->_get_pid_from_file’


sub running {
    my $self = shift;
    my $pid  = $self->_get_pid_from_file or return undef;

    return   kill(0, $pid)
           ? $pid
           : undef;
}
Posted in Uncategorized | 1 Comment

Can’t locate Net/FTP/File.pm

perl -MCPAN -e shell
> install Net::FTP::File

Posted in Uncategorized | Leave a comment

ReadyNAS woes

After shutting the system off for a week’s vacation, the ReadyNAS 1000 was acting weird. Started giving an error about “the local security authority is internally inconsistent” and we couldn’t connect to the share from windows. I tried rebooting from Frontview but it didn’t seem to reboot.

I was able to connect with ssh and restart samba thanks to this post, and that worked – now I could connect. But for some reason, the ReadyNAS would not reboot from Frontview. So I rebooted from SSH. After it came back up, all the Services under Standard File Protocols were disabled and I could no longer SSH.

I tried to re-install the EnableRootSSH add-on but it keeps saying “Invalid Checksum detected in update file”
Now I can reboot from Frontview (thankfully since ssh is gone) and I did a full file check overnight but still in the same place. Reboots cause all file services to become unchecked and any add-on gives an Invalid Checksum.

I’m trying to boot up the backup ReadyNAS and it’s at the slowly blinking blue light. Soft reset seems to have gotten it going. Installed the EnableSSH add-on and it’s doing a filesystem check now.

Posted in Uncategorized | Leave a comment

Trouble Setting up stunnel4 on Ubuntu

I installed stunnel4 (with apt-get) on a new ubuntu server

2013.08.23 16:38:23 LOG7[10589:140529841223424]: SSL alert (read): fatal: unknown CA
2013.08.23 16:38:23 LOG3[10589:140529841223424]: SSL_connect: 14094418: error:14094418:SSL routines:SSL3_READ_BYTES:tlsv1 alert unknown ca

ultimately i copied over pem files from another server and set the group and file ownership to stunnel4

Posted in Uncategorized | Leave a comment

Lock down wp-login.php by ip address

Sick of wordpress login getting slammed by bots and bringing the server to its knees. Most of the plugins and solutions out there seem way too complicated for our needs. So for now I am just putting some code into the top of wp-login.php to block anyone but the very few people who should be logging in. Note that this will get lost and require replacing after WordPress updates.


# Custom wp-login security added 8-21-2013
# 11.22.33.44 = Me
# 55.66.77.88 = My friend
# 127.0.0.1 = localhost

$allowed = array('11.22.33.44','55.66.77.88','127.0.0.1');

if($_SERVER["REMOTE_ADDR"]){
  $ip = $_SERVER["REMOTE_ADDR"];

  if(!in_array($ip, $allowed)){
    print "Sorry but you do not have permission to access this page from $ip";
    exit();
  }
}
Posted in Uncategorized | Leave a comment

mysql import stuck on /*!40000 ALTER TABLE `mytable` ENABLE KEYS */

I was importing a mysql database and it was taking forever.
> show processlist showed Info for the query that was running over an hour:
/*!40000 ALTER TABLE `mytable` ENABLE KEYS */

This post clued me in to the fact that, since the “State” was “Repair with Keycache”, the temporary tables are filling up the whole 60GB partition I’d set for this DB.

Whenever you get “Repair With Keycache” as a status, you have no free space to do file sorting

Starting over with a bigger partition and hopefully this will do it!

Posted in Uncategorized | Leave a comment

mysql: error while loading shared libraries: libmysqlclient.so.15: cannot open shared object file: No such file or directory

After installing MySQL on Ubuntu server, I was getting the subject error. I tried to download the file as per this page but after trying that, I still got the exact same error.

What fixed it was going into /usr/lib and linking to the file in /usr/lib64,
cd /usr/lib
ln -s /usr/lib64/libmysqlclient.so.15

then mysql worked!

Posted in Uncategorized | Leave a comment