Install NDOUtils in CentOS RHEL and fix related error

This article covers how to install NDOUtils in CentOS. NDOUtils is an addon for Nagios Core that allows you to export current and historical data from one or more Nagios Core instances to a MySQL database. NDOUtils is included with Nagios XI. A source in Nagios Network Analyzer is the data collector. Outside of Nagios Network Analyzer a source is the location where data is originating from.


NDOUtils uses the kernel message queue for transferring the data from Nagios to NDOUtils. We are going to increase the default values the Kernel boots with to ensure it operates optimally.

1. Downloading NDOUtils Source

cd /tmp

wget -O ndoutils.tar.gz https://github.com/NagiosEnterprises/ndoutils/releases/download/ndoutils-2.1.3/ndoutils-2.1.3.tar.gz

tar xzf ndoutils.tar.gz

2. Compile NDOUtils

cd /tmp/ndoutils-2.1.3/

./configure

make all

3. Install Binaries

This step installs the binary files.

make install

4. Initialize Database

This prepares the database for NDOUtils.

cd db/

./installdb -u 'ndoutils' -p 'ndoutils_password' -h 'localhost' -d nagios

cd .. 

Read More




Create custom php ini in Litespeed Webserver - How to do it

This article covers how to Create custom php.ini in Litespeed Webserver. Basically, compared to the Apache web server, the Litespeed web server configuration may feel a bit complicated. In hosting environment with cPanel servers, it is necessary to edit the PHP variables for each domain or customer and this can be done using by creating a custom php.ini for each user's home directory. So the clients can change the PHP values according to their requirements.  

There should some steps need to be done on Litespeed admin panel on cPanel/WHM to enable custom php.ini and you can follow the below steps to enable it.


To Create Custom Php.Ini In A Litespeed Webserver:

1. Login into WHM.

2. Select Litespeed Web Server

3. Litespeed Configuration > Admin Console > Configuration > Server > External App > lsphp5

4. Under Environment section >> add “PHPRC=$VH_ROOT”

5. Under “suEXEC User ” section >> add the account username for which custom php.ini has to be enabled.

6. Under “suEXEC Group ” section >> add the group name of the same account.

7. Click save and return to Main >> Litespeed Web server

8. Under Quick Configuration of PHP suEXEC settings,>> Set Enable PHP suExec to yes.

9. After that put custom php.ini in the user’s home directory and check it using a phpinfo page.

Read More




Troubleshoot server down issues - How to do it

This article covers how to troubleshoot server down issues. Basically, network issues might cause the Datacenter to go down. This can lead us into some unlucky instances. Troubleshooting server down issues is never an easy task. Whether you have a small home network, or a super connection of thousands of computers, there are meticulous steps you need to take to get your server back up running.


Steps to take when troubleshooting server down issues:

1. ANALYZE YOUR NETWORK INFRASTRUCTURE

You will have a better chance at troubleshooting network problems if you first figure out where everything is connected in the infrastructure.

2. STUDY YOUR NETWORK

If you don't have an infrastructure design to go by, you will have to learn your network’s layout when analyzing your connectivity. Several tools can help you to map out the entire network infrastructure. Tools such as IPCONFIG can aid in finding the problem.

3. CONNECTION IS DOWN

From the network troubleshooting application, find out from the OSI model if all the seven layers are working correctly. Usually, if the first layer doesn’t work the whole connection will be down. Check whether the network cable is plugged in.

4. NO IP ADDRESS

Your server could be down just because of unknown IP address settings. Anon IP address such as 0.0.0.0 or an automatic one that starts with 169.254 will typically result in server down problems. You will need to obtain a valid IP address before you can get your server back up. 

5. NO DNS SERVERS

Without DNS servers configured on your network, all communication will only be possible through an IP address. A server down issue, in this case, might be a broken a line between the router and the internet. 

6. NO DEFAULT GATEWAY

Your servers could be down because there is no default gateway IP address. This breaks the communication between the subnet and the local area network. You will still be able to work as usual on your local servers. 

7. MISCONFIGURED IP SUBNET MASK

A misconfigured subnet mask IP can impede server communication. You can manually configure this IP subnet mask or work with the DHCP server to identify the source if there is a misconfiguration.

Read More




An error occurred while reconnecting - Fix this Windows error now

This article covers methods to resolve fix 'An error occurred while reconnecting' Windows error. 


Causes for 'The Local Device Name is already in Use' Error on Windows:

1. Drive mapping has gone wrong – The process of network drive mapping can sometimes produce problems like this one when it comes to drive letters.

2. Some drive letters are unassigned – Some drives may have incorrect or even missing drive letters which causes this error to appear.

3. File and Printer Sharing is disabled – If this option is disabled in any firewall you might be using, networking becomes difficult and full of errors.

4. No space on the server – Users have reported that they had to free up at least a couple of gigabytes on the root drive of the network’s server to get rid of the problem.


To fix 'The Local Device Name is already in Use' Error on Windows:

Remap the Drive Using Command Prompt

Remapping the network drive is the official solution recommended by Microsoft for users facing this problem. However, it has worked for many users and it has become one of the most used methods for this problem. 

Check out the steps to implement this;

1. Search for “Command Prompt” either right in the Start menu or by tapping the search button right next to it. Right-click on the first result which will appear at the top and select the “Run as administrator” option.

2. Users who are using an older version of Windows can use the Windows Logo Key + R key combination in order to bring up the Run dialog box. Type in “cmd” in the box and use the Ctrl + Shift + Enter key combination in order to run Command Prompt as an administrator.

3. Copy and paste the command shown below and make sure you click the Enter key on your keyboard.

net use * /delete

4. After you see that the operation is completed successfully, run the following command:

net use Z: \\server\share /user:username password

5. Make sure you replace the username and password placeholders with the correct username and password. Check to see if the problem is resolved!

Read More




Set custom php.ini in FastCGI - How to set it up

This article covers how to set custom php.ini in FastCGI. Basically, FastCGI is the best to manage resources for a high traffic site in shared servers.


To create Custom php.ini with PHP5 under FastCGI:

1. First open .htaccess for the account in question and add the following lines to the bottom of the file:

AddHandler php5-fastcgi .php

Action php5-fastcgi /cgi-bin/php5.fcgi

2. Next, you'll need to source your main server php.ini which is located in /usr/local/lib/. Also note that it needs to have the correct ownership so we'll take care of that too:

cd /home/user/public_html/cgi-bin/

cp -a /usr/local/lib/php.ini .

chown user:user php.ini

3. Next we need to create the wrapper script. Create a file in your current directory (cgi-bin) called php5.fcgi as defined above and add the following:

#!/bin/sh

export PHP_FCGI_CHILDREN=1

export PHP_FCGI_MAX_REQUESTS=10

exec /usr/local/cpanel/cgi-sys/php5

4. Finally, make sure the ownership and permissions are correct on this file:

chown user:user php5.fcgi && chmod 0755 php5.fcgi

Read More




Server Hardening - What it means

This article covers techniques to prevent attacks on the server. Basically, if we manage our servers without proper precautionary actions it is easy to spoil the reputation of the server.

Hardening your server is the process of increasing security on your server through a variety of means to result in a much more secure operating environment. Server hardening is one of the most important tasks to be handled on your servers. 

The default configuration of most operating systems is not designed with security as the primary focus. 

Default server setups focus more on usability, functionality and communication.


Server Hardening Security Measures Includes:

1. Hide login password from cgi scripts.

This setting allows you to hide the REMOTE_PASSWORD variable from scripts that the cpsrvd daemon's CGI handler executes.

2. Referrer safety check.

Only permit cPanel, Webmail and WHM to execute functions when the browser-provided referrer (port and domain or IP address) exactly matches the destination URL.

3. Initial default/catch-all forwarder destination

Select Fail to automatically discard un-routable email that your servers new accounts receive. This will help protect your server from mail attacks.

4. Verify signatures of third-party cPaddons.

Enable this option to verify GPG signatures of all third-party CPaddons.

5. Prevent "nobody" from sending mail.

Enable to block email that the nobody user sent to the remote address. Nobody is the username for Apache.

6. Enable SPF on domains for newly created accounts.

7. Proxy subdomain override.

Disable this option to prevent automatically-generated proxy domains when a user creates a subdomain.

8. Proxy subdomain creation.

Disable this option to prevent the addition of cPanel, Webmail, Web Disk and WHM proxy subdomain DNS entries to new accounts.

9. Cookie IP validation.

Disable this option to allow logins regardless of the user's IP address.

Read More





Focus on your business, not your servers.

Click Here to Learn More




Recent Post