Category Archives: Server issues

Configuring Nameservers at registrar end

Setup nameservers at different registrars;

Fabulous.com

1) Click on manage -> nameservers > and then “create nameserver” at the very bottom of the page under “Nameserver Edit.”
2) FQDN is ns1 followed by your domain registered at fabulous, followed by its IP address. Click “continue” and repeat for ns2.

Enom.com

login
Click on Registered Domains
Click on the domain name in question
Click on DNS Server Settings
Enter in your DNS Servers here then click save and you are DONE!!!!

domains >> advanced tools >> register a nameserver

http://www.enom.com/domains/RegNameServer.asp

Register a NameServer Name
Note: The domain name must be in
the customer’s account.
(Example: To register NS1.myname.com,
the domain name myname.com
must be registered to you at eNom.)

Update a NameServer IP
Note: The domain name must be in
the customer’s account.

Delete a NameServer
Note: The domain name must be in
the customer’s account.
If there are any domains using this nameserver
the deletion process will fail

1&1

1. Login to your account
2. Click Manage Your Domains
3. Check the domain you want to edit
4. At the top of the list, hit arrow next to DNS, then Edit DNS Settings
5. In the drop down box, hit My Name Server
6. Fill in your custom nameservers

A Small Orange

If you registered your domain through A Small Orange, you’ll need to login to the customer/billing area at https://customers.asmallorange.com.
1. Select My Sites -> Domains
2. Select the Domain from the list on the left by clicking on the link.
3. Select Register Nameserver on the left and enter the ns1.example.com and the IP address. Click Submit
4. Repeat for ns2.example.com
5. Select Change DNS from the menu list on the left.
6. Enter ns1.example.com and ns2.example.com
7. Done!

DirectNIC

1. Login to your account.
2. Click Domain Manager
3. To the right of the domain name, there are three icons: a telephone, and computer and a house (I think). Click the computer (middle icon).
4. Before you enter the Nameservers, you need to click on the link above for “Create Nameserver”.
5. create the ns1 and ns2 with your IP addresses.
6. When you’re done, go back to Domain Manager and select the computer icon next the your domain again.
7. Enter the nameservers you just created and click Modify.

DomainSite

1. Login to your account
2. Select Manage Registered Domain Names.
3. Click on the domain name you wish to add nameservers for.
4. Select Register a Name Server.
5. Type ns1 in the Host Name box
6. Enter the ns1 IP.
7. Click continue.
8. Click Register.
9. Click Continue managing
10. Select Register a Name Server.
11. Enter ns2 in the hostname box.
12. Enter the ns2 ip in the IP Address box.
13. Click continue.
14. Click Register.
15. Change your nameservers to the ones you’ve just created.

GoDaddy

1. Login to your GoDaddy Account.
2. Click on My Account
3. Click on Manage Domains
4. Click on the domain name you want to modify.
5. In the lower left corner of the page, there is a Host Summary. Click Add.
6. Enter the ns1 and ns2 and IP addresses. Then click OK.
7. Click the Nameservers icon across the top.
8. Change the nameservers to the ones you just created.

Ref: http://help.godaddy.com/article.php?article_id=668&topic_id=&prog_id=GoDaddy&

Mydomain

(Also applies to Dotster)

1. Log into your account, and navigate to the “My Domains” page.
2. Under the “STEP 1. CHOOSE …” header, click on the domain you want nameservers under.
3. Under “Name Servers”, click “Register Name Server”
4. Enter “ns1” (no quotes) in the “Host Name” box, and your first nameserver IP.
5. On the success page, click “Back to Domain Information”.
6. Repeat steps 3. to 5., using your second nameserver IP.
7. Under “Name Servers”, click “Update Name Servers”.
8. Change the nameserver to the ones you’ve just created.

Namecheap

1. Login to your account.
2. Click Manage Domains
3. Click on the domain name.
4. On the left, click on Nameserver Registration
5. for the first two (ns1 ns2), enter the IP addresses.
6. click add nameservers
7. Go back to manage domains
8. Select the domain
9. Click Domain Name Server Setup.
10. Change the Nameservers to your custom nameservers

Network Solutions

1. Login to Account Manager
2. Click the check box next to the domain you want to manage, then click “Edit DNS”
3. Ignore the warnings and click the “continue button under “Move DNS to A New Name Server” (do not select DNS Manager Continue)
4. Ignore the warning on the next page, and click Continue
5. Enter your custom nameservers, ns1.example.com and ns2.example.com and click Continue
6. On the next screen, enter the IP addresses for those nameservers and click Continue.
7. Ignore the warnings and click Save DNS.

OpenSRS

1. Login into your domain control panel.
2. Once logged in go to Name servers
3. Scroll down to the bottom of the page and click on the link following If you want to create or modify a name server which is based on yourdomain.com
4. At the bottom of this page type in ns1 then the IP Address provided to you by A Small Orange if you are a VPS Customer in the host name field. If you are shared or a reseller for the host name type in 64.22.96.90. Then click on Create Name Server
5. After that repeat #4 but then use ns2 and use the other IP Address A Small Orange provided of you are a VPS Customer but use 67.19.36.196 if you are a shared or reseller customer.
6. After 72 hours head over back to the Control Panel and go back to nameservers. Now type in ns1.youdomain.com and ns2.yourdomain.com and you are now done.
7. Now Jump up on your desk and say “I did it. I made nameservers.”

Register.com

1. Login to your domain control panel.
2. Click on the domain you wish to change.
3. Scroll all the way to the bottom, and under “Advanced Technical Setting”, click on “Managed Registered Name Servers”
4. On the next screen, look for Register DNS Server.
5. Enter “ns1” for DNS Server, and the IP address (notice the domain name is pre-defined). Click the Continue button.
6. On the next screen (a confirmation screen), click Continue.
7. Repeat steps 3 – 6.
8. Now that the Nameserver IPs are registered, you can look for the section “Domain Name System Servers”
9. Enter ns1.example.com and ns2.example.com.
10. You’re done. Do a victory jig.

Stargate

1. Login to customer control panel
2. Enter your domain name example.com into the Jump to Domain field and use the drop down menu to select Domain Registration Service.
3. In the Domain Management Console, select the button “Manage Child Name Server”.
4. Enter ns1 for hostname field next to your domain example.com and enter the IP address 1.2.3.4 below it.
5. Click on the Modify Name Server button.
6. Change the nameservers to ns1.example.com and ns2.example.com that you created in Step 4.
7. Do a victory jig while the DNS propagates throughout the Internet.

Checking Load due to a particular user in the server

Whenever the load in the server increases due to a particular user in the server. Check the following:

Find the domain owned by the user:

grep username /etc/userdomains

use the following command after you get the domain name:

less /usr/local/apache/domlogs/domain.com | awk ‘{print $1}’ | sort | uniq -c | sort -n

This will give the ip and number of connections in the descending order. For example:

 13832 65.52.110.145
 19112 66.249.68.183
208262 157.55.16.55

In the above case we can see too many connections from those ips. This is surely abnormal. Immediately block such ips in the server using csf

csf -d IP

[if not present use iptables].

using ip tables:

iptables -A INPUT -s <ip> -j DROP

To change the permission of files and directories

find . -type f  -perm 755 -exec chmod 644 {} \;

find . -type d  -perm 777 -exec chmod 755 {} \;

Error: Your hostname could not be resolved to an IP address

If the DNS for your hostname is not set up correctly, you may get an email saying something similar to this:

Your hostname (srv.yourdomain.com) could not be resolved to an IP address. This means that /etc/hosts is not set up correctly, and/or there is no dns entry for srv.yourdomain.com. Please be sure that the contents of /etc/hosts are configured correctly, and also that there is a correct ‘A’ entry for the domain in the zone file. Some or all of these problems can be caused by /etc/resolv.conf being setup incorrectly. Please check that file if you believe everything else is correct. You may be able to automatically correct this problem by using the ‘Add an A entry for your hostname’ option under ‘Dns Functions’ in your Web Host Manager.

Most of the time, this error email is triggered by private name servers not being set up correctly.  It also could mean there are missing, corrupted or improperly formatted DNS records.

If you are using private name servers (optional on reseller & SEO Hosting and required on VPS and dedicated servers), then please check the following:

  1. Did you register your private name servers with your registrar with the correct IP addresses?
  2. Is there an A record for each of your private name servers?
  3. Are the correct nameservers listed in the DNS Zone for the domain using them? (DNS Glue)

If you are not using private name servers, or your private name servers are setup correctly, then you may be missing the A record for your hostname.

  1. Login to WHM.
  2. Click on the DNS Functions icon or navigate to the DNS Functions section in the sidebar.
  3. Click on Add an A Entry for your Hostname
  4. Check to see if an A record exists:
    1. If an A record exists, it will be shown there. Make sure it is the correct IP address.
    2. If no A record exists, then use the Add Entry button to add the IP.  Make sure the correct IP is listed there before continuing.  This will add the missing A record.

On a dedicated server or VPS, you would also want to make sure the hostname exists in/etc/hosts as well.

How to reduce server load

1 )netstat -plan | grep :80 | awk ‘{print $5}’ | cut -d: -f 1 | sort | uniq -c | sort -n
2) netstat -plan | grep :25 | awk ‘{print $5}’ | cut -d: -f 1 | sort | uniq -c | sort -n

3) pstree -paul

4) cd /tmp
5) rm -f dos-* sess_* .spamassassin*
6) find . -user nobody -exec rm -f ‘{}’ \;
7) ps -C exim -fH ewww
8) ps -C exim -fH eww |grep home

9) mysqladmin proc |grep Sleep |awk {‘print $4’}|cut -d_ -f 1|sort|uniq -c|sort -nk 1
10) ps -C exim -fH ewww
11) for i in `ipcs -s | awk ‘{print $2}’`; do (ipcrm -s $i); done
12) for i in `mysqladmin proc |grep Sleep |cut -d ” ” -f 2`; do mysqladmin kill $i; done
13) exim -bp |grep “*** frozen ***” |awk ‘{print $3}’ |xargs exim -Mrm
14) exiqgrep -z -i | xargs exim -Mrm;exiqgrep -o 432000 -i | xargs exim -Mrm