All posts by Barry Mercer

Powersehll netapp volume resize

This script will resize any volumes on your controller that are more full than 96% and add an extra 5% on to them. You  can filter the list a little more if needed, for example I don’t attempt to resize any of our volumes that have the word “dr” in as they are snapmirror destinations.

 

 

$controllers = @(“controller1″,”controller2″)
$body=””
$resize=””
$emailto=”fillThisIn”
$emailfrom = “fillThisIn”
$emailsmtp = fillThisIn”
$emailsubject= “Drives resized”

foreach ($controller in $controllers){
connect-nacontroller $controller
$resize+= (Get-NaVol | where-object {$_.used -gt 96 } | ft -HideTableHeaders)
}

if ($resize -ne “”) {
foreach ($navol in $resize){
write-host “$navol”
Set-NaVolSize $navol +5%
$newsize = Get-NaVolSize $navol.SizeTotal
Set-NaVolAutosize $navol -Enabled
Set-NaVolAutosize $navol -MaximumSize +10%
$body += “Volume $navol on $controller script resized to $newsize and autogrow enabled `n”
}
$body += “check snapmirror destinations size for volumes above!”
send-mailmessage -to $emailto -from $emailfrom -smtpserver $emailsmtp -subject $emailsubject -body $body
}

 

Force Nexus Android Update

Want to force your Nexus to update to the latest version of Android, yet when you check it constantly say you have it? One way to do this is to wait… the other is to go to Settings>Apps>All. Find “Google services framework”. Force stop it then clear the data. After that got to the check for updates page. It should say last checked in 1970. Check for updates again and hopefully it will be there. I had to do this about 5 times before it worked, so you may have to too

CA Migration

I’ve recently migrated my 2003 DC’s CA to a non-dc 2008r2 server. Everything went surprisingly well. It’s pretty easy. Folow MS’s directions which are basically, backup the CA Database from the MMC, backup the registry. Remove the CA. Install the CA. Restore the database. Fiddle around a bit.

 

The only issue I had is the CRL. THe old crl was at http://oldca and removing the CA role removes this website. Although the CRL is in AD, it won’t get updated by the new CA.  I found this fantastic article which helped immensely with sorting out the CRL. The http one won’t work, but the AD one is good enough (I hope). Just a few points on the article that I didn’t notice, its ldap:/// not ldap:// (three / ) so make sure you type it correctly! I think the whole path is case sensitive too. If “publish crl” is greyed out after you’ve entered the information, you’ve typed something wrong.

Asterisk Fun

I’ve spent the last half hour or so trying to fix my Cisco 7945 that;s on my desk at home. I’t s anice phone, colour display and cisco brick-like build quality. Howerver, I don’t think Cisco want it to work with asterisk. After much trialling and fiddling I have it registered (extensions nat=no) and making and receiving calls. Anyway, recently I’d noticed the MWI light not coming on when I had a message. Out going calls were ok, but it turns out that inbound weren’t. Not changed anything, other than wiping my router but I wasn’t forwarding ports anway so what could be the problem? Asterisk keept on logging ast_tcptls_client_start: Unable to connect SIP socket to xxx:port Connection timed out I pinged my ddns and indeed xxx was my ip, so why didn’t it work? Well after 30 minutes I realised that my phone was natting itself with the IP of my ddns as BT change it whenever I reboot my router. I’d neglected to add the DDN settings back to my router when I wiped it, so it complaining was entirely justified. Added the DDNS config in, restarted the phone and away I go