Monit is a small, easy to configure monitoring system for *nix systems that will attempt to restart services that have failed. Grab the tarball, extract, configure, make, and make install: [usr-1@srv-1 ~]$ tar -xzf mon*4.7*.gz [usr-1@srv-1 ~]$ cd mon*7 [usr-1@srv-1 monit-4.7]$ ./configure checking for gcc… gcc checking for C compiler default output file name… a.out […]
Monitoring and Automatic Recovery of Services with Monit
Logging Performance Monitor Counters to SQL Server – Part 1
There are 4 parts to this article: Part 1 – Part 2 – Part 3 – Part 4 On Windows Server 2003, Perfmon counters can be logged directly to a SQL database. Let’s do that. Create a database on your SQL Server. We called the database pmon: We’ll create a device for the database with […]
Logging Performance Monitor Counters to SQL Server – Part 2
There are 4 parts to this article: Part 1 – Part 2 – Part 3 – Part 4 Use Windows NT authentication: Do not dynamically determine the port. Uncheck and make sure port 1433 is used: Change the default database to pmon: The rest of the defaults are OK: Click finish, and the summary screen […]
Logging Performance Monitor Counters to SQL Server – Part 3
There are 4 parts to this article: Part 1 – Part 2 – Part 3 – Part 4 Click Test Data Source, and if all is happy, a window showing the results of the ODBC connectivity test will pop up: Another summary of the ODBC connection: Let’s use our perfmon database. In performance monitor, create […]
Logging Performance Monitor Counters to SQL Server – Part 4
There are 4 parts to this article: Part 1 – Part 2 – Part 3 – Part 4 After you close out the settings, the counter log should be started. If not, then start it: Add the counters from the database by clicking on the log icon from System Monitor and selecting the database via […]
Lua Monitoring Script
Here is a Lua script we put together that measures the latency of a web host, the time to resolve the host, and the time to retrieve a page: — time to resolve host, time to ping host, time to get host/page print (“\”page name\”,\”host latency ms\”,\”dns resolve ms\”,\”page receive ms\””) — fromCSV from http://www.lua.org/pil/20.4.html […]
Installing Rsyslog With a MySQL and Loganalyzer
Ahhh… how to keep track of all of those logs. You could go fabulous and use Splunk (or one of splunks alternatives), but if you want some free and simple analysis with not a lot of extra load, rsyslog dumping into a database with Loganalyzer is a pretty decent option. For an introduction to rsyslog, […]
Forwarding Rsyslog Logs to Central Server
If you would like to forward your logs to a central syslog server, add something like this to the bottom of rsyslog.conf: $WorkDirectory /var/spool/rsyslog # where to place spool files $ActionQueueFileName fwdRuleall # unique name prefix for spool files $ActionQueueMaxDiskSpace 1g # 1gb space limit (use as much as possible) $ActionQueueSaveOnShutdown on # save messages […]
Syslog Client for Windows
The Rsyslog Windows Agent from Adiscon provides a comprehensive and scalable syslog client that runs on all Microsoft Windows operating systems from 2000 on up to 2012, even Windows 8. Installation is a typical next, next, next: The configuration options are many, and you can use TCP: Notice that you can queue at the client […]
Obtaining sorted DNS listings from an NT command prompt
It is fairly easy to obtain DNS information for a domain listed by name or IP address. You can use the following procedure regardless of what platform your DNS is running on. You can also use this to verify what names your DNS thinks it is resolving, since this won’t necessarily match your hosts file. […]
LMHOSTS Generator
In the Name Resolution section, we wrote about a technique for forcing the NBT cache to contain entries for critical servers on a network. Even if the WINS server is down or the entries are corrupt, the cached entries will allow name resolution. An LMHOSTS file is needed that contains all of the server names, […]
Using the LMHOSTS file to backup WINS
In addition to resolving NetBIOS names for small networks, the LMHOSTS file can be used to back up WINS. Since the cached entries are referred to first, you can manually reset the cache of a corrupt or missing domain by reloading the entries in the LMHOSTS file. Make sure your system has the LMHOSTS checked […]
WINS Tips and Tricks
We’ve found that a star topology generally works best for WINS replication, with push/pull replication from one central hub. One indication that your WINS database entries are invalid is if you get “no domain controller available” errors between trusted domains in the system event log. This can almost always be cleared up by disabling replication […]
BIND Installation and Initial Configuration
We’ll start out simple in this section with just three hosts, a cname for www, and an mx record. As we integrate DNS with other services we will add more sections. We are using Red Hat 7.1, but there is little here that is distribution-specific. The only thing that might change is the way you […]
Using rndc to Administer BIND
We will explore rndc, which is a new tool with BIND 9 that takes the place of ndc in BIND 8. First we need to create a key using dnssec-keygen: [root@srv-3 /root]# dnssec-keygen -a hmac-md5 -b 256 -n user rndc Krndc.+157+34404 [root@srv-3 /root]# ls Krndc.+157+34404.key Krndc.+157+34404.private [root@srv-3 /root]# cat *.private Private-key-format: v1.2 Algorithm: 157 (HMAC_MD5) […]
BIND Administration with Webmin
We will use Webmin to automate updates of forward and reverse zones. Webmin will automatically update both, as well as restart your services and increment your serial number. Webmin is much more than just a DNS tool. It can be used to administer many services. Since Webmin is Open Source, released under the BSD license, […]
DNS/BIND TTL Settings During Domain Migrations
There are two different default DNS/BIND TTL settings you need to switch when moving domains to a different IP address. One is the negative caching setting in the SOA record, and the other is the default ttl at the top of the file ($ttl).. If you have different TTL settings for your indidual record, you […]
Logging With BIND 9
We talked in this article about setting the TTLs for DNS records in BIND for the purposes of moving a website, or, more specifically, changing the IP address of an authoritative DNS server. In this article, we will show you how to turn up the logging and output the results to a file. Again, this […]
Restricting Recursive Lookups with BIND 8/9
When you allow recursive lookups, you open yourself up to various security risks and performance issues, so you should only allow recursion when needed. Recursive lookups are lookups for domains you are not authoritative for. That is, if you are authoritative for mycompany.com, and you don’t allow recursion, then if somebody queries your server for […]
Example Domain for Documentation
If you need to put a domain name in documentation, example.net, example.com, and example.org are reserved for this purpose as defined in this RFC. This will prevent an inadvertently run script from causing trouble, as well as avoiding an association with a seemingly arbitrary host.