http://ip/~username/ can't visit

levilee

Member
May 11, 2012
8
0
51
cPanel Access Level
Reseller Owner
Hi,

I have created an account in my cPanel, now i want to use the temp URL http://ip/~username/, but found it redirect to httpd://www.ip/~username/. this leading to this temp URL can't visit..
I haven't point my domain to this server.. so the temp URL is import for me.. Can some help about it?

Best Regards,

Levi
 

Travis

Active Member
Apr 24, 2002
31
3
383
cPanel Access Level
Root Administrator
Hiya!

In EasyApache you would need to disable mod_userdir protection.

WHM >> Apache Mod_userdir tweak >> Disable mod_userdir protection
 

Infopro

Well-Known Member
May 20, 2003
17,076
523
613
Pennsylvania
cPanel Access Level
Root Administrator
Twitter
I would suggest instead to, Exclude Protection for that one account instead of simply disabling mod_userdir.

The redirection is going to www.ip though, this seems strange to me for some reason. Makes me think you've got something else configured incorrectly or thats a typo in your first post.
 

ZacharyR

Member
Nov 25, 2012
11
0
1
Devon, UK
cPanel Access Level
Root Administrator
Yes, enable Mod_userdir tweak and it'll work. :)
This is usually enabled by default or were you perhaps following the instructions of CSF?
Which, for your information, recommends that you disable this feature. Anyway, enable it.

I can see in your cPanel/WHM Access Level it says "Reseller Owner". ;)
If you're a reseller you will probably have to ask your host to enable it.
But bear in mind that not all hosts are prepared to enable this feature.
So if they say no they will probably provide you with a very good reason.
 
Last edited:

Infopro

Well-Known Member
May 20, 2003
17,076
523
613
Pennsylvania
cPanel Access Level
Root Administrator
Twitter
Yes, enable Mod_userdir tweak and it'll work. :)
We can assume it's already enabled, by the OP above and this thread's title.

This is usually enabled by default or were you perhaps following the instructions of CSF?
Which, for your information, recommends that you disable this feature. Anyway, enable it.
That's not correct. From CSF Security Check:
"To prevents users from stealing bandwidth or hackers hiding access to your servers, you should check WHM > Security Center > mod_userdir Tweak"


I can see in your cPanel/WHM Access Level it says "Reseller Owner". ;)
If you're a reseller you will probably have to ask your host to enable it.
But bear in mind that not all hosts are prepared to enable this feature.
So if they say no they will probably provide you with a very good reason.
You'll need to Exclude Protection for the account you want to be able to do this with. The reason a host wouldn't want to Exclude Protection on your account might be the same reason that's posted in WHM:

Apache's mod_userdir allows users to view their sites by entering a tilde(~) and their username as the uri on a specific host. For example http://test.cpanel.net/~fred/ will bring up the user fred's domain. The disadvantage of this feature is that any bandwidth usage used by this site will be put on the domain it is accessed under (in this case test.cpanel.net). mod_userdir protection prevents this from happening. You may however want to disable it on specific virtual hosts (generally shared ssl hosts.)
More Info and warnings on all this can be found in the docs located here:

Apache mod_userdir Tweak - cPanel Documentation


Nice sig, ZacharyR.
 

ZacharyR

Member
Nov 25, 2012
11
0
1
Devon, UK
cPanel Access Level
Root Administrator
My bad. Yes, CSF does indeed recommend to "enable" this feature.
When I said "disable" I was thinking about "disabling" IP/~username :p
But of course, to achieve that you ENABLE the tweak that DISABLES it.