Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
By jeanluca on
Hi All
I've tried to install modules using the functionality provided by drupal ( Modules -> Install new module, I've tried both methods )
When I do this I get a screen with
----------------------
WARNING: You are not using an encrypted connection, so your password will be sent in plain text. Learn more.
To continue, provide your server connection details
Connection method
FTP CONNECTION SETTINGS
.....
etc
----------------------
What is going wrong here, is here an bug report somewhere ?
cheers
Luca
Comments
Modules -> Install new module
Where exactly is this in the menu system? See here for info on installing modules...
http://drupal.org/getting-started/install-contrib/modules
But really you should be getting very acquainted with...
http://drupal.org/documentation/build
This page is standard
This page is standard functionality in Drupal 7.
However, not all servers are set up to support uploading new modules or themes via the admin interface, and in the cases where they aren't, it can be very confusing.
There is a core issue for attempting to fix this confusion: #686060: Explain that the Update manager only works if you have FTP or SSH access to your server
Ahah
drupal-7.0-beta2/#overlay=admin/modules/install
My exploration of 7 hadn't got that far. Thanks for the info.
Same problem drupal 7rc4 on Ubuntu and Nginx
I had the same problem with drupal 7rc4 on ubuntu and nginx and for me just were the permissions of drupal files
I solved it as follows
open a termninal and write
sudo chown www-data:www-data -R /var/www/drupal
where www-data is nginx user (maybe is the same with apache) and /var/www/drupal is the path drupal installation
work fine
thanks, solved the command sudo chown www-data:www-data -R /var/www/mySite
Thanks !!!..
Thanks !!!..
This worked perfectly fine for me as well.
chown: www-data: illegal group name in Terminal MAC with XAMP
i have a error, please help
sudo chown www-data:www-data -R /var/www/Store
chown: www-data: illegal group name
Looks like the command is invalid for your environment
Verify which group is used by apache in httpd.conf and replace :www-data with :{Group used in httpd.conf}
Are you sure you are solving your issue the right way? In other words: Why do you run `sudo chown www-data:......`?
Suggest to create your own issue explaining the problems you are trying to solve.
check, worked for me too $>
check, worked for me too
$> chown -R apache:apache /www/drupal/c7
thnx
Changing your entire codebase
Changing your entire codebase to be owned by the apache or www-data user (as done in the last two comments above) is generally a bad idea from a security perspective.
Why? Because it opens up the ability for any web process on the server to be able to write to your files. Your Drupal installation therefore becomes vulnerable to basically any kind of exploit anywhere else on the server.
Again, if you aren't able to install modules via the Drupal admin UI, that's not a problem. It's just the way your server is configured. You could set up your server to allow FTP or other kinds of access if you want to, but in most cases it's not necessary. If you have the ability to easily go on the command line and do stuff, then that UI wasn't primarily designed for you anyway! You can easily download modules via Drush, or other methods that allow you to install files directly on your server. See http://drupal.org/documentation/install/modules-themes for more information (a handbook page which, now that #686060: Explain that the Update manager only works if you have FTP or SSH access to your server has been committed to Drupal core, is also linked to from the various help messages and error messages you get while trying to do this via the admin UI).
Maybe instead of telling us
Maybe instead of telling us to give the web server write permissions to the whole drupal folder, it would be a good idea to tell us what folders NEED that access. I personally have got the temporary directory to be writeable, the sites/all/modules directory to be writeable, and still I need FTP access. Maybe it is a PHP setting rather than a directory setting?
This has only happened since I changed servers, so it must be a configuration setting somewhere. I have full root access should I need to change anything. I really would appreciate the help in fixing this because providing FTP details each time I install or upgrade a module is a pain.
Thanks,
Bryn
Drupal File Permissions vs. FTP Permissions
I'm not sure if the following is what you were looking for, but it may help someone else. c:
Drupal File Webserver Permissions vs. FTP Permissions
There is a guide available on securing files and folders while giving the webserver proper access. In short, you want to avoid giving the webserver access to everything in the Drupal folder as owner. Instead, give the webserver access via a group, whether it's "www-data" or (in my case on a fresh Linux Slackware 13.37 install), "apache." Details of the webserver's user/group can usually be found in your /etc/httpd/httpd.conf file.
Even after all of this, you will still need to provide FTP access when using the update manager (the admin interface). Apache (if you're using that as the HTTP server) does not process FTP requests. There is an Apache module intended for FTP requests, however standard Apache processes HTTP requests. Although you are using update manager via HTTP, the actual internal downloads happen via an FTP connection. So the permissions set for the webserver are moot in this context, as internally, the FTP "user" is no longer the webserver. As a result, the FTP "user" does not share the webserver's permissions. This is why you must provide FTP account credentials. That way, Drupal can access an FTP connection using an actual server-defined user with proper server-defined permissions.
Personally, I prefer using the command line and I avoid FTP unless I really need to use it for my own server. Check out Drush. It is much simpler and it is a very powerful Drupal management command line tool. There are also other command line options to download modules, unpackage them and move them to their appropriate directories. FTP is just one of many ways!
Enabling FTP On Linux Slackware 13.37
Like I said, I prefer using Drush and alternative command line tools to manage my Drupal installation. But if you REALLY want to setup an FTP server, here is a simple way to do it on Slackware 13.37 if you have the necessary packages installed. If you did a full Slackware installation, you have the necessary packages. If not, Google can help you out.
For anyone seeking to setup an FTP server themselves on a Slackware 13.37 installation, it is a simple matter of uncommenting wanted features in the /etc/vsftpd.conf file (if you choose to go with vsftpd as opposed to proftpd, which are both just a few of the tools available for setting up a server with FTP; you can find specific docs and other compare/contrast info via Google). Simply uncomment local_enable and write_enable to allow server users to login and write to files. All the configuration settings are here, so run through them and set up your server whichever way you would like.
After setting up vsftpd.conf with your preferred settings, edit /etc/inetd.conf
Find the part that says:
Uncomment the line with the ftp configuration:
ftp stream tcp nowait root /usr/sbin/tcpd vsftpd
Then restart the service with the following command:
/etc/rc.d/rc.inetd restart
Test out your server by connecting to it via FTP and login as a user. It should work!
Great Work man Thanks!
Great Work man
Thanks!
You have to give the access permission for that
Open Terminal
Paste this command:
sudo chown www-data:www-data -R /var/www/html/Your-Drupal-folder/sites
How it works in MAc Terminal with XAMP?
How it works in MAc Terminal?
The CLI is the CLI
AFAIK, the CLI (Command Line Interface) works the same on every platform.
Whether it is a good idea to give the web server full ownership over the Drupal sites-folder and its subdirectories … well, that is not the way I do it. Here is my notes about installing Drupal 7, which includes sections about resolving file ownership issues:
http://heim.ifi.uio.no/gisle/staging2/drupalprimer/drupal7/intro_drupali...
Note that the examples in my write-up assumes that the webserver group is named "apache". If it is named something else (e.g. "www-data"), you should use that. (Also see comment by mmjvb of 23 August 2019 at 01:24 above.)
- gisle