Resetting APC AP7920 PDU

I have three APC PDUs – all the AP7920 model, they monitor power consumption and allow remote switching of a bunch of devices in the main rack. Last week I sourced a fourth device to live in the garage comms rack. This came from eBay, and as has been the case with every used device I’d have, it still had old IP config and an unknown username and password set.

So for future-Howard’s benefit: how to reset the password and settings so it can be set up from scratch…

Continue reading

Conditional DNS on UniFi’s UDM-Pro

A quick How To for getting conditional DNS forwarding working on the UDM-PRO hardware. Before this upgrade I ran a CloudKey Gen 2 controller and a USG-PRO-4 for routing – this allowed me to deploy custom configuration via the config.gateway.json to insert extra options to the running config.

The options I needed were to force the DNS server on the gateway to check against my Active Directory DNS for those entries that arrive with the correct suffix – ad.durdle.com. This allows the lookup of clients from the UniFi’s DHCP lease table as well as AD DNS entries.

The UDM-PRO is a completely different beast from the old controller and gateway, running an entirely different OS. It doesn’t support config via json. So what’s a geek to do?

Continue reading

Windows 10, why you no sleep?

A (minor) annoyance of my recent new build Windows 10 machine has been its inability to properly sleep. I’d hit Sleep, it’d go through the motions of spinning down fans and sleeping… and then immediately spring back into life.

I’ve actually put up with this for months, but yesterday spent some time working out what was happening, so for Future Howard’s benefit, here’s how to see what is keeping your machine awake.

Continue reading

Clearing Ubiquiti UniFi USG DNS entries

Another post to save Future Howard the trouble of trying to remember how to fix a problem: when the DNS server in the USG-PRO has cached an old or invalid IP for a host. To verify:

  • SSH to the USG-PRO itself (not the Cloud Key/Controller).
  • To see the list of IPs it has stored, with the incorrect entry:
    cat /etc/hosts
  • To edit (elevated) and remove the offending line
    sudo vi /etc/hosts
  • And to ensure the DNS service forgets the incorrect value:
    clear dns forwarding cache

You’re welcome, Future Howard.

.svn/tmp directory may be missing or corrupt

For future-Howard (and team), how to fix the error from SVN “your .svn/tmp directory may be missing or corrupt”.

for /R /D %i in (.svn) do if exist "%i" mkdir "%i/tmp"

Open CMD, cd to the SVN directory then run the above command. It will place a new tmp directory inside each .svn directory.

After you run the command, an svn cleanup should succeed.