Web Hosting Talk







View Full Version : Absolute Path Question:


Rebel
06-25-2002, 10:59 PM
Trying to install a program and I keep getting the absolute paths wrong...was wondering if anyone could help.

Say I have mydomain.com and I make a sub account called sub.mydomain.com.

I am going to install a program that calls for an absolute path and I enter in /usr/local/psa/home/vhosts/sub.mydomain.com/news because I have a news file in the httpdocs/news

I am getting an error and was wondering that since it's a subdomain account, whether I need to enter in the path differently...

WebmastTroy
06-25-2002, 11:15 PM
I'm not sure what control panel or server setup your using. I'm only familiar with CPanel and it's setup.

You might try something like this: /usr/local/psa/home/vhosts/mydomain.com/sub/news . Usually, a subdomain is actually another level after a domain, even though you wouldn't think it is.

You can try it....I can't guarantee anything, though, sorry.
:(

chuckt101
06-25-2002, 11:23 PM
Do you have shell access?

cd to the directory and type "pwd".

If not, log in via ftp and see where the subdomain dir is and use that to figure out what the path is since you should know the path to your main www directory.

Finally, you can just ask your webhost.. :p

As WebmastTroy said, CPanel places subdir under your main www directory. HSphere places it under your HOME directory ie:

/home/hsphere/local/myusername/mydomain.com
/home/hsphere/local/myusername/test.mydomain.com

Rebel
06-25-2002, 11:29 PM
It's a plesk sub domain account, it's seperate from the mother account.

The Prohacker
06-25-2002, 11:30 PM
What language?? PHP? Perl?

And whats the error?

Rebel
06-25-2002, 11:37 PM
Could not open /usr/local/psa/home/vhosts/sub.mydomain.com/news/newsdat.txt for writing. Could not create a new file in your News Files directory (/usr/local/psa/home/vhosts/sub.mydomain.com/news). Check permissions on this directory.

I know the permissions are correct, I have followed the directions to the letter and this isn't my first time ever installing the program called Coranto. It is just my first time installing it on a sub domain plesk account.

The program file path works(/usr/local/psa/home/vhosts/sub.mydomain.com/cgi-bin), but the news path needs to be in the httpdocs directory and that is the path that is not working.. :(

The Prohacker
06-25-2002, 11:39 PM
Is it PHP?????

Rebel
06-25-2002, 11:41 PM
It's cgi based... :stickout

http://factory.eatsleepcode.ca/coranto/

Chicken
06-26-2002, 12:11 AM
Rebel, you missed a folder, try:

/usr/local/psa/home/vhosts/sub.mydomain.com/httpdocs/news

Now, the last part I'm not sure of ('news') as you said, "because I have a news file in the httpdocs/news" - so I'm not sure if 'news' is supposed to be a file or a folder and/or if you're supposed to have a file *after* the above path.

This should get you there however.

akashik
06-26-2002, 04:44 AM
what have you set the permissions to?
on both the folder, and the text file?

Also, does the server the account is on allow you to set those permissions.

It does seem like the path is finding the file as you're getting an issue with opening it, rather than finding it.

Greg Moore

fractiousws
06-26-2002, 05:16 AM
Wouldn't it be
/usr/local/psa/home/vhosts/mydomain.com/subdomain/httpdocs/news ???

Chicken
06-26-2002, 06:08 AM
Plesk doesn't put subdomains under domains. Path I posted should be correct unless he's done somethign whacky with the server, in which case he's on his own... ;D

fractiousws
06-26-2002, 07:34 AM
Yeah but when a sub domain is created it can be just creates a folder in the domains directory as the subdomain name. This is where the /www.domain.com/subdomain came from.

fractiousws
06-26-2002, 07:34 AM
Nevermined, I am thinking CPanel sorry.

Chicken
06-26-2002, 10:54 AM
Yeah, Plesk doesn't consider the subdomain to be part of the domain. Each is set up as if it were a domain (not under anything), which is good sometimes, though generally people want subdomains and with plesk they won't use their existing space and just add them. You'd have to make them a reseller and the creation process is a bit more complicated.

One point of Plesk that isn't so wonderful...

Rebel
06-26-2002, 12:31 PM
Originally posted by Chicken
Rebel, you missed a folder, try:

/usr/local/psa/home/vhosts/sub.mydomain.com/httpdocs/news

Now, the last part I'm not sure of ('news') as you said, "because I have a news file in the httpdocs/news" - so I'm not sure if 'news' is supposed to be a file or a folder and/or if you're supposed to have a file *after* the above path.

This should get you there however.

Don't take this the wrong way, but I love you. ;)

It works, o' happy days. :D