CNAME getting redirected to /cgi-sys/defaultwebpage.cgi

danielati

Active Member
Nov 7, 2011
31
1
58
cPanel Access Level
Website Owner
Hi!

I'm having a problem configuring cname.
I have r.dominio1.com located on the X server.
I have r.dominio2.com located on the Y server.

I'm configuring cname as below:
r.dominio1.com. CNAME r.dominio2.com.

When running r.dominio1.com I am redirected to r.dominio1.com/cgi-sys/defaultwebpage.cgi
When checking the IP after the execution, it points to the IP of the server Y, however, it does not point to the domain r.dominio2.com.

I want to do some sort of redirect using cname. Is it correct how I am establishing values?

Thanks
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,910
2,216
463
Hello,

Could you verify if a DNS zone for dominio2.com is configured on the "X" server? If so, and if the DNS for that domain name is handled remotely, try removing that zone to see if the issue persists.

Thank you.
 

danielati

Active Member
Nov 7, 2011
31
1
58
cPanel Access Level
Website Owner
Hello,

Could you verify if a DNS zone for dominio2.com is configured on the "X" server? If so, and if the DNS for that domain name is handled remotely, try removing that zone to see if the issue persists.

Thank you.

Hello Michael,

doesn't exist a DNS zone for dominio2.com configured in the "X" server...
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,910
2,216
463
Hello,

Is cPanel installed on both of these servers? Also, ensure r.dominio2.com exists as a subdomain under an account or it's own account on the destination server.

Thank you.
 

danielati

Active Member
Nov 7, 2011
31
1
58
cPanel Access Level
Website Owner
Hello,

Is cPanel installed on both of these servers? Also, ensure r.dominio2.com exists as a subdomain under an account or it's own account on the destination server.

Thank you.

Hello,

Yes. Both servers has cPanel installed.
r.dominio2.com has an own account on the destination server ("Y").

On the "X" server has a subdomain to r.dominio1.com

Thank you.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,910
2,216
463
Hello,

Could you open a support ticket using the link in my signature so we can take a closer look? You can post the ticket number here so we can update this thread with the outcome.

Thank you.
 

danielati

Active Member
Nov 7, 2011
31
1
58
cPanel Access Level
Website Owner
Hello,

I opened the ticket, as recommended, and follow the solution below:

What this shows is that there is no entry for r.dominio1.com. If you'd like to display the content for r.dominio2.com, you will want to add an alias for this cPanel account so that r.dominio2.com is also known on this server as r.dominio1.com. This can be done in cPanel Home >> Domains >> Aliases. Documentation for this feature is available here:
Aliases - Documentation - cPanel Documentation


So, I created an alias in r.dominio2.com for r.dominio1.com, and it worked.

I am very grateful for the help of all involved.

Best regards,
Daniela
 
Last edited:
  • Like
Reactions: cPanelMichael

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,910
2,216
463
I'm happy to see the issue is now resolved. Thank you for updating us with the outcome.
 

samuelmf

Well-Known Member
May 22, 2006
125
6
168
Perú
I want to leave a tip here:
When i created a cname it always showed me the nasty cgi-sys page, and tried many solutions but the origin of the problem was on the destination domain of the cname, because it was using the shared ip instead a dedicated ip.
So to avoid that problem i changed the ip from shared to dedicated on the destination domain of the cname and it worked fine. Bye bye cgi-sys page ;)
 
  • Like
Reactions: cPanelMichael

shripadd

Registered
Feb 7, 2015
4
0
1
Aurangabad, Maharashtra, India
cPanel Access Level
Website Owner
Hi
I offer a SaaS application https://mysaas.com when customer SignUp I offer them a virtual subdomain like https://cus1.mysaas.com. (We added wildcard domain).
So far everything is fine, Now I wish to offer the custom facility to add a CNAME record on their end and use this application with their url. So They added a CNAME entry in their WHM/Cpanel.

demo.customer-domain.com. >> 300 > IN > CNAME > cus1.mysaas.com

Now if I try to do nslookup it get resolved properly
nslookup demo.customer-domain.com
Server: Unknown
Address 191.168.0.1
Non-authoritative answer
Name cust1.mysaas.com
Address 167.99.17.11
Alias demo.customer-domain.com

So visitor is reached to my server, but when we open it in web browser user getting cgi-sys/defaultwebpage.cgi Default website page.

I have a similar setup on a cloudways server where we are not using WHM/Cpanel and its working fine there, My be something with that etc., I am not an expert so don't know the exact reason. Please provide some help
 

sabuj92

Registered
Sep 17, 2019
3
0
1
Chittagong
cPanel Access Level
Root Administrator
How can I point my root domain mysite.com to a subdomain of another site subdomain.another.com?
The subdomain is wildcard subdomain. I have cPanel root server access.

I just want to make it looks like Shopify. A Shopify store example.shopify.com can be accessible from both the Shopify subdomain and store owners custom domain. Do we need to edit virtual host file or anything and update dns from domain control panel? We are using centos 7, cpanel, Apache server.
 

GOT

Get Proactive!
PartnerNOC
Apr 8, 2003
1,753
311
363
Chesapeake, VA
cPanel Access Level
DataCenter Provider
If you get a second ip for your server and assign that to the account that handles all the different domains then that will display the content regardless of domain used.

However it does not address what I would forsee as an SSL issue because I'm pretty sure that you're going to want SSL for each domain that points to your shared software. You would need to add each domain that points there as a domain alias to the subdomain account as opposed to creating separate accounts as it sounds like you may be doing now.

This will save you money from a license perspective as well...
 

sabuj92

Registered
Sep 17, 2019
3
0
1
Chittagong
cPanel Access Level
Root Administrator
If you get a second ip for your server and assign that to the account that handles all the different domains then that will display the content regardless of domain used.

However it does not address what I would forsee as an SSL issue because I'm pretty sure that you're going to want SSL for each domain that points to your shared software. You would need to add each domain that points there as a domain alias to the subdomain account as opposed to creating separate accounts as it sounds like you may be doing now.

This will save you money from a license perspective as well...
Hi can you give me an example? Actually I am newbie here. Can't understand clearly.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,910
2,216
463
Hello @shripadd,

I moved your post into the existing thread on this topic. Can you confirm if assigning a dedicated IP address to the account on the cPanel & WHM server addresses the issue?

Thank you.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,910
2,216
463
Hello @sabuj92,

I moved your post into this thread. Can you confirm if the instructions in this thread are what you are looking for?

Thank you.
 

sabuj92

Registered
Sep 17, 2019
3
0
1
Chittagong
cPanel Access Level
Root Administrator
Hello @sabuj92,

I moved your post into this thread. Can you confirm if the instructions in this thread are what you are looking for?

Thank you.
Not exactly. Let me explain again.
I have a software installed in my root domain for example "sabuj92.com" that allows customers to register and create their own website in a subdomain like "something.sabuj92.com" exactly like blogger and wordpress.com. This is working perfectly. No problem with this side.

But I want to add an option where customers can add their own domain pointing to the subdomain. so the website contents showing in the subdomain "something.sabuj92.com" will be able to access from their custom domain for example "custom.com".

Someone sent me a solution:
You need three DNS records: wildcard ("*") for the shopsite.example.com -- though would recommend doing shopsite.id.example.com where id is a server / cluster id that resolves to the same IP . In the DNS editor, you would put in *.id for the sub domain. So say you have a server named "shoppie", the id could then be "shoppie" making it joeshop.shoppie.example.com . The second record would be a CNAME record for "www" at the client's domain that points to the shopsite.id.example.com record. And the third record would be an A record that points to an IP that has a vhost and the only function is does is redirect to www.

Then on the web server, just add in the new subdomain as normal and add the real domain as an alias .
But this is not fully cleared to me.
 
Last edited by a moderator:

jeafgilbert

Registered
Oct 10, 2019
1
1
3
Indonesia
cPanel Access Level
Website Owner
Hello, I'd like to share my solution.

My domains are in the same host provider and using cPanel. I had played around with (domain1.com) Zone Editor, Subdomain, Alias, and Redirecting, (domain2.com) Zone Editor, and Alias but no luck. And finally I successfully show sub.domain2.com contents to sub.domain1.com just by adding "Addon Domain" in domain2 cPanel with this value:

- Add New Domain: sub.domain1.com
- Subdomain: sd1
- Document Root: sd1.subdomain2.com

I cleared every settings related to this requirement in domain1.com. So no settings added in domain1.com to make this work, only in domain2.com.

So I have sub.domain1.com in URL with sub.domain2.com contents.

Hope it helps!
– JG
 
  • Like
Reactions: shripadd