News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Can't get past FTP in the installer?

Started by [Unknown], May 30, 2004, 01:02:34 AM

Previous topic - Next topic

[Unknown]

For a more up to date version of this tutorial please see the doc site

The installer for Beta 5 does not actually require FTP, it only uses it if there is a problem with the permissions of some files.

If you have trouble using the FTP client, chances are you are entering the FTP details incorrectly, or the FTP server is denying access from itself.  However, you can fix the problem manually, in which case the installer won't even bother to try itself.

If you are on a linux or other unix based server, which is what most servers are, you will need to chmod the following list of files to 777.  This can be done easily with most modern FTP clients, by right clicking on the files and going to "Permissions", "chmod", or "Properties..." (it varies...)  The files and directories are:

  • attachments (directory)
  • avatars (directory)
  • Packages (directory)
  • Packages/installed.list
  • Packages/server.list
  • Smileys (directory)
  • Themes (directory)
  • Themes/default/languages/Install.english.php (and any other Install.language.php files.)
  • agreement.txt
  • Settings.php
  • Settings_bak.php
  • install.php

These files are exactly the ones the installer will try to make writable for you if it can connect through FTP.  It only asks for FTP information if one of these files is not writable.

These files and directories need to be writable so that all the features of SMF can work properly.  For information on why this is not really a security risk, please read the "Why chmod 777 is NOT a security risk" topic.

If, on the other hand, you are under windows... you need to change the NTFS permissions for those same files.  If you do not know how to do this, please ask your host to do it for you or have them just make the entire forum's directory and all it's files writable. (the installer will not offer FTP on windows because it won't do any good...)

The next release will have more detail in its FTP error messages.

Thank you for your patience,
-[Unknown]

welo

Quote from: [Unknown] on May 30, 2004, 01:02:34 AMIf you have trouble using the FTP client, chances are you are entering the FTP details incorrectly, or the FTP server is denying access from itself.

Just a quick point of note here because on a preliminary search I don't see anyone pointing it out: When the installer asks for your FTP username (predefined as "localhost" in the first box), just use hxxp:yoursite.com [nonactive] (rather than hxxp:yoursite.com [nonactive], hxxp:yoursite.com [nonactive] etc.). Took me several tries before I figured it out.

(Good to meet ya btw ;). Looks like a promising script indeed)
hxxp:llamasery.com [nonactive] - Enlightened Internet Strategies

[Unknown]

Thanks, I'll change it so it supports being given URLs like such.

! The installer now supports using ftp://hostname.tld/ as the server.

-[Unknown]

Thing

Chmod - ?? What? ???

I've changed the FTP address to the one the previous poster said - still no luck.

Killer Possum

Try the CHMOD manually...

Quote from: [Unknown] on May 30, 2004, 01:02:34 AM
If you are on a linux or other unix based server, which is what most servers are, you will need to chmod the following list of files to 777.  This can be done easily with most modern FTP clients, by right clicking on the files and going to "Permissions", "chmod", or "Properties..." (it varies...)  The files and directories are:

  • attachments (directory)
  • avatars (directory)
  • Packages (directory)
  • Packages/installed.list
  • Packages/server.list
  • Smileys (directory)
  • Themes (directory)
  • Themes/default/languages/Install.english.php (and any other Install.language.php files.)
  • agreement.txt
  • Settings.php
  • Settings_bak.php
  • install.php

These files are exactly the ones the installer will try to make writable for you if it can connect through FTP.  It only asks for FTP information if one of these files is not writable.

sjkramer

What if you don't have a right click ??
Like us MAC users... ;D

[Unknown]

Quote from: sjkramer on August 14, 2004, 09:03:16 PM
What if you don't have a right click ??
Like us MAC users... ;D

Then use a PC :P.

No, seriously, in the Mac FTP clients there's a way.  Sometimes you have to Control - Click, or get to it with a menu or button.

-[Unknown]

Dr_Doog

#7
i've done it twice manually and it still comes up. one of these day's i'm switching from fuitadnet...

never mind, fixed it.

answer:  it has it set up to go to the full directory on the server, where as it should just be /var/www/forum

mediman

Quote from: [Unknown] on June 07, 2004, 06:30:32 AM
Thanks, I'll change it so it supports being given URLs like such.

! The installer now supports using ftp://hostname.tld/ as the server.

-[Unknown]
maybe it will work now with any ftpd´s but i know a lot of people who have a problem with ftp://domain.com/folder

maybe it would be better to open the ftp connection only with ftp://domain.com and add the folder "forum" or whatever in the chmod thing, or using change directory after etablish the connection...

mediman
My Projects: http://ticker-oase.de 
Please do not PM me with support requests.

hobo jim

What kind of a path do you write in the Install Path? /www/ or ftp:// or D:\ ?

[Unknown]

Quote from: hobo jim on December 31, 2004, 03:25:24 PM
What kind of a path do you write in the Install Path? /www/ or ftp:// or D:\ ?

/www/ is the one.  So, if you see this in your FTP:

+ public_html
    - cgi-bin
    + forum
       - attachments
       - avatars
       - Packages
       - Smileys
       - Sources
       - Themes
    - some other folder


Type:

/public_html/forum/

-[Unknown]

admactanium

Quote from: sjkramer on August 14, 2004, 09:03:16 PM
What if you don't have a right click ??
Like us MAC users... ;D
control click on the file/s in your ftp client. it should bring up a menu. if you have one that says "file info" then use that and set the permissions to 777. i use transmit, seems to be the best ftp client for macs.

smooth_jake

Quote from: [Unknown] on May 30, 2004, 01:02:34 AM
The installer for Beta 5 does not actually require FTP, it only uses it if there is a problem with the permissions of some files.

If you have trouble using the FTP client, chances are you are entering the FTP details incorrectly, or the FTP server is denying access from itself.  However, you can fix the problem manually, in which case the installer won't even bother to try itself.

If you are on a linux or other unix based server, which is what most servers are, you will need to chmod the following list of files to 777.  This can be done easily with most modern FTP clients, by right clicking on the files and going to "Permissions", "chmod", or "Properties..." (it varies...)  The files and directories are:

  • attachments (directory)
  • avatars (directory)
  • Packages (directory)
  • Packages/installed.list
  • Packages/server.list
  • Smileys (directory)
  • Themes (directory)
  • Themes/default/languages/Install.english.php (and any other Install.language.php files.)
  • agreement.txt
  • Settings.php
  • Settings_bak.php
  • install.php

These files are exactly the ones the installer will try to make writable for you if it can connect through FTP.  It only asks for FTP information if one of these files is not writable.

These files and directories need to be writable so that all the features of SMF can work properly.  For information on why this is not really a security risk, please read the "Why chmod 777 is NOT a security risk" topic.

If, on the other hand, you are under windows... you need to change the NTFS permissions for those same files.  If you do not know how to do this, please ask your host to do it for you or have them just make the entire forum's directory and all it's files writable. (the installer will not offer FTP on windows because it won't do any good...)

The next release will have more detail in its FTP error messages.

Thank you for your patience,
-[Unknown]

i cannot copy these files to to the webserver.

[li]Packages/installed.list[/li]
[li]Packages/server.list[/li]

it says it has bad extension.
PLEASE JOIN MY ARMY
hxxp:www.kingsofchaos.com/recruit.php?uniqid=wq7wpgcs [nonactive]

Oldiesmann

I don't know why you wouldn't be able to copy those to the server, unless your FTP client doesn't like uploading empty files.

My recommended FTP clients:

FileZilla for Windows
RBrowserLite for Mac OS X

davo88

I can't get the FTP part working in Package Manager when installing updates. I have about 6 installations of SMF running (for testing and modding), I'd really like to get it working and not to have to chmod them all manually every time there's an update.  :)

So far I've tried

FTP Server:    ftp://my_domain.net , my_domain.net ,  ftp://66.98.123.45 , 66.98.123.45
Port:       21
Username:      xxxxx   
Password:      yyyyy
Local path to SMF:  /httpdocs/smf , httpdocs/smf ,  /smf , smf

And a whole lot of other variations.

Any suggestions on what to try next?

[Unknown]

Your path is likely wrong.  What error message or path does this tool give you?

http://www.simplemachines.org/community/index.php?topic=28393.0

-[Unknown]

davo88

This gives me...

An error occured while trying to connect. The error was:

530 Login incorrect.


Tried a couple of variations for the FTP server - both domain name and IP.

[Unknown]

Quote from: davo88 on March 29, 2005, 07:22:56 PM
This gives me...

An error occured while trying to connect. The error was:

530 Login incorrect.


Tried a couple of variations for the FTP server - both domain name and IP.

That message means your username and/or password are incorrect, not that the domain/ip is wrong.

-[Unknown]

davo88

I reset the FTP password in Plesk and tried again - similar error. Then found I had a trailing space on the end of my_domain.net !!

So fixed that and re-ran it. It detected the directory as /smf_2 and produced a different error as follows ...


An error occured while trying to connect. The error was:

550 /smf_2: No such file or directory



The detected directory then changed to httpdocs/smf_2 and it proceded to connect and arrive at Write this down! screen.

So then went to PM and tried an update again - this time it was v1.02 update on a v1.01 installation.

The FTP part connected and continued through to the Proceed link.

Proceeded, but then it generated this error on completion

2: copy(/home/httpd/vhosts/my_domain.net/httpdocs/smf_2/changelog.txt~): failed to open stream: Permission denied
File: /home/httpd/vhosts/my_domain.net/httpdocs/smf_2/Sources/Subs-Package.php
Line: 1285


So manually went in via FTP and none of the directories/files had changed to 777. So did all that manually and tried again and it completed successfully.

So did fix_ownerships.php do anything? ... other than detect the directories?

And the fact that the FTP part in PM appeared to complete its work successfully, yet no directories/files were 777'ed, does this indicate anything?

Dave






[Unknown]

Quote from: davo88 on March 29, 2005, 09:05:12 PM
So fixed that and re-ran it. It detected the directory as /smf_2 and produced a different error as follows ...

That's a total guess.. it can't really know until you give it a password.

Quote
550 /smf_2: No such file or directory [/i]

The detected directory then changed to httpdocs/smf_2 and it proceded to connect and arrive at Write this down! screen.

See, now it can know ;).  At this point, it has fixed *ownership* issues.  It has not made any permission changes, only safe mode issues.  I plan to change the tool so it does more.

Quote2: copy(/home/httpd/vhosts/my_domain.net/httpdocs/smf_2/changelog.txt~): failed to open stream: Permission denied
File: /home/httpd/vhosts/my_domain.net/httpdocs/smf_2/Sources/Subs-Package.php
Line: 1285

This means that httpdocs/smf_2 is not writable - that directory itself.

QuoteSo did fix_ownerships.php do anything? ... other than detect the directories?

In your case, that's the main change it made.  But, for example, attachments will now work even in safe mode if Apache runs as nobody.

-[Unknown]

Advertisement: