Questions tagged [drush]

Use it for questions about the command line shell and Unix scripting interface for Drupal (a.k.a. Drush).

Filter by
Sorted by
Tagged with
2
votes
1answer
523 views

drush perm-grant gives “The drush command 'perm-grant' could not be found”

I am using drush -u 15 perm-grant --roles="site administrator" but the command returns: The drush command 'perm-grant' could not be found. any ideas about that? according this documentation the ...
2
votes
1answer
504 views

Drush rsync permission woes (files directory)

I'm rsyncing just the files directory (rest of the site is done through git) from my local Ubuntu setup to my centOS server. It worked at least (thankfully), but produced a ton of errors. First it ...
1
vote
3answers
546 views

Why doesn't my watchdog() function run when I execute my custom module from Drush

I have a custom module that performs an import from an xml file. It can be invoked two different ways. From a menu callback or a custom drush command. The import works fine and all of it's many ...
0
votes
0answers
36 views

Drush behaves strangely on Windows 10 with Acquia Dev Desktop

After having istalled drush via composer locally I had to make the following changes inside sites\default\settings.php for it to work: Create the database connection array $databases['default']['...
0
votes
0answers
13 views

Drush migration argument for xml source

I asked this question a while back and it was answered correctly and helpfully. However, I'm currently looking for a different solution. I need a way to create a custom argument which I can use to ...
5
votes
2answers
2k views

drush default site alias

Is there a way of specifying a default site alias ? couldnt find it in drushrc example nor aliases example. motivation i am sclerotic and lazy :) usually running drush from the dir where the site is,...
2
votes
1answer
382 views

How to use another php version for drush 9?

On live server I use differents drush and php versions for drupal 8.4 and 7. I install drush 9 to ~/drush9 directory with composer require drush/drush:9.* command. On dev server and drupal 8.4 I use ...
0
votes
1answer
345 views

Drush Hangs on wget but wget Works

Every drush command I run hangs on wget. However, if I run wget outside of drush, it works just fine. I am behind an http proxy and suspect that's factoring into the problem. I don't understand why ...
0
votes
1answer
25 views

How can I create dynamic options based on the existing bundles from hook_drush_command()?

I want to create dynamic options based on the entity types (returned by entity_get_info() function) inside the hook_drush_command(). There's no bootstrapped Drupal available at all, so the db_query() ...
-1
votes
1answer
579 views

Drush 6 installed on a centos server. How do i find out where its installed and upgrade it?

how do i find where is drush installed? its currently on drush 6 and looking to update it to drush 7 for drupal 8. Whats an easy way to find where its installed and update it?
0
votes
0answers
13 views

Can I remove warnings/notices from the output of “drush pm:security --fields=name --format=json”?

Running a command similar to drush pm:security --fields=name --format=json gives me what I am looking for. Is there a way to remove warnings and notices from the output? I can't see anything in the ...
0
votes
0answers
17 views

Priority of aliases files for Drush

I have an installation with lando. On the project, we have a directory drush with an aliases file for the project. This file defines aliases with the root specific for the lando architecture. In my ...
1
vote
1answer
734 views

Drush Make: error “unable to unzip”

I'm trying to setup a new project using the Drush make command. I'm working on localhost (xampp) on a Windows 8.1 machine. The problem is that if a module present in my make file requires an external ...
0
votes
1answer
363 views

How do I perform outstanding entity updates after 8.7?

I have just tested the update to 8.7.1 (from 8.6.x) which includes the removal of the old automatic entity update functionality, which means drush entup no longer works. As far as I understand the ...
0
votes
2answers
2k views

Update fails with undefined function system_rebuild_module_data in update.inc but the function is defined in system.module

When I run drush updb on my Drupal 8.3.1 site, I get: PHP Fatal error: Call to undefined function system_rebuild_module_data() in /var/www/mysite/web/core/includes/update.inc on line 46 ...
0
votes
0answers
19 views

Drush not working after updating Acquia dev desktop

So basically I updated my Acquia dev desktop in my MAC and the Drush stopped working throwing some error. I have been trying to fix this issue from past few hours but I couldn't find anything on the ...
0
votes
1answer
30 views

drush handling array variable values

I am using Drupal 7 and drush 7.4.0. How do I handle array variables with drush? For example, I have a variable, social_sharing, for which drush vget social_sharing Produces: facebook: facebook ...
1
vote
1answer
640 views

How to install a drupal distribution using Drush quickstart command?

What is the command for drush qc to install a drupal distribution? I'm trying to install this one: https://drupal.org/project/onepagecv
0
votes
1answer
31 views

Drush not fully installed

I have installed Drush 8.2.3 globally on a Lubuntu 18.04 image. This was done without Composer (I used the default install instructions here) However, if I run drush topic and select any topic number ...
2
votes
2answers
827 views

Loading a queue?

How can I use Drush to pass data into a Drupal Queue? function hook_cron_queue_info() { $queues['my_queue_name'] = array( 'worker callback' => '_my_queue_callback', // This is the callback ...
0
votes
0answers
26 views

Errors while updating core to latest version

I have a website I had worked on but never finished, last year. It is at version 8.5.4. I've imported it (from a devdesktop environment) into a Docker/Docksal environment. At this point I can see a ...
3
votes
1answer
1k views

Why does cloning a private git repository via Drush make file fail using SSH authentication?

I have multiple private git accounts set up with SSH system's keychain authentication for each git repo. It works to clone private git repos from command line: git clone git@git_ssh_alias:git-...
1
vote
0answers
236 views

`drush pm-update drupal` fails to copy to backup

Tried to update some of my Drupal 7 installation with drush. Some of them were successful while some were not. The error ones generate message like this: [foobar@server htdocs]$ drush pm-update ...
0
votes
0answers
59 views

How to change the drush default timeout of 14400?

We face a major problem for our client. To put it in context, this is a Drupal 8 with commerce that has a large number of products that come from a PIM. To be clearer, the products are not managed in ...
9
votes
5answers
9k views

How to list all users in drush?

I would like to list information about all users using drush. There is user-information, but it shows information only about single user. Are there any other solutions?
1
vote
1answer
418 views

Updating modules fails with XAMPP on Windows 10

I'm pretty sure I installed Drush 8 correctly on Windows 10. I ran the command window as administrator. I changed to my Drupal directory, but I get "Command pm-update needs a higher bootstrap level to ...
-3
votes
1answer
37 views

Running Drupal's drush cron jobs with a newer PHP version from Software Collections

How do you run Drupal's drush cron jobs when your server has a newer PHP version installed from Software Collections? The server is running Scientific Linux 7, which comes with PHP 5.4, but we need, ...
1
vote
1answer
390 views

Running drush entity:updates claimed successful but not changing anything

I am working on a project with custom entity type. My module works fine in my local environment. But when I deployed to my staging site, things are strange. For instance, I tried to change my entity ...
0
votes
1answer
51 views

How can I query a Drupal 7 database from Drupal 8?

I want to query users, nodes etc in my D7 database that I am currently migrating to D8 to compare with the migrated content. I want to use custom Drush commands to run some checks. Is this possible?
0
votes
1answer
61 views

Drush 9 on Windows 7 problem

I installed drush 9 and now I'm getting the following error whenever I run a drush command: /usr/bin/sh: /cygdrive/c/mysite/vendor/drush/drush/drush.launcher: No such file or directory Details: I ...
0
votes
2answers
40 views

Drush error when attempting Drupal update: unable to copy/move [closed]

I have a Drupal site running on localhost (Windows) that I'm trying to update from 8.6.7 to 8.6.15. When using Drush to perform the update (drush up drupal -y), I encounter the following error: ...
2
votes
3answers
2k views

Unable to connect to local MySQL db using drush sql-sync

I'm attempting to use drush sql-sync to sync my prod database to my local dev copy, and everything seems to work until drush attempts to log into the local MySQL. When it does, it throws this error: "...
2
votes
1answer
25 views

How to replace drush_download_file in Drush 9

drush_download_file() existed in includes/drush.inc for Drush 8 and below, but this has been removed in Drush 9 as far as I can tell. Is there a standard way that file downloads should be executed in ...
0
votes
0answers
26 views

WHERE the alias file should locate in drupal

I have tried some ways to create an alias for my local Drupal project https://www.drupal.org/node/1401522 https://www.drupal.org/project/drush/issues/831272 https://www.drupal.org/project/drush/...
1
vote
1answer
57 views

No such file or directory in Drupal\Component\DependencyInjection\PhpArrayContainer->createService()

I installed a fresh D8 (Drupal 8.6.15) site on my local dev and I am unable to use drush. After I installed the site, I also did a composer install. My dev is set up on php 7.1 using AMMPS and drush ...
0
votes
2answers
400 views

Cannot install Drupal via drush in the root of site

I am going absolutely insane. I have been up for several hours scouring the internet, installing, removing, installing, removing, and I CANNOT get Drupal (7 or 8) to install at the root of a site (...
0
votes
1answer
48 views

Drush: How do I change the Drupal root

My Drush commands doesn't work because my Drupal files are in another directory than the one set in Drush. Everything is set up to this path so I can't just change the folder name. Drush status [..]...
3
votes
2answers
2k views

Drush bootstrap level error

Im running onto some issues with Drush. I worked with php 5.3 and after upgrading to 5.5, i ran into some issues and decided to downgrade my PHP version back to 5.3. Now im running into the issue that ...
0
votes
1answer
102 views

Drush command to run cron won't work in Crontab

I am attempting to run two Drush commands from my crontab: # m h dom mon dow command */2 * * * * drush -r /path -l https://www.domain.com/ cron */2 * * * * drush -r /path -l https://www.domain.com/...
2
votes
1answer
174 views

Drush cim: error “Table xyz already exists”

I'm trying to deploy a dev website to a dev server. When running drush cim on the dev server, drush ends with an error message: Table honeypot_user already exists When running drush cim again ...
1
vote
1answer
27 views

Where is the `Drush` command specific documentation?

To be more specific than the title, I want to know what drush cim exactly does, like: where is the drush cim command specific documentation? Does cim command remove the files after they are imported, ...
1
vote
2answers
495 views

Drush installation problem [closed]

I've twice followed these instructions to install Drush 8. At the end of the process I can run Drush anywhere and it responds as expected. However, whenever my server connection is broken and I log ...
2
votes
2answers
1k views

How to clear page cache without rebuilding other caches

I have a large site which uses Drupal cores 'page caching for anonymous users'. I have made some javascript changes which I need to deploy. Since pages are currently cached I will need to clear the ...
1
vote
2answers
885 views

SQL query to CSV

I'm doing some queries on my Drupal site using the drush sql-query command. I'd like to export the results to a CSV. Is it possible to do this via the command options, some plugin, or some other ...
6
votes
2answers
1k views

Change module settings stored in an array with drush

I would like to configure a module (addtoany) settings with drush. This is the variable: addtoany_nodetypes: Array ( [about_us] => about_us [contact] => contact [page] => page ...
4
votes
1answer
561 views

How do I link Drush to my Drupal site on Pantheon?

A friend of mine got me into Drupal and did the initial setup for me. At first, I was using localhost to play with Drupal and Drush to download and enable modules. Now I have my own Pantheon hosting ...
0
votes
1answer
397 views

What version of Drush is compatible with Drupal 6 / PHP 5.2

Just installed drush on a system using PHP 5.2. However, when I run drush, a message is displayed saying Your command line PHP installation is too old. Drush requires atleast PHP 5.3.0. To suppress ...
1
vote
1answer
1k views

How to get Drush in my path in Windows 10?

I have Drush 9 installed on Windows 10. I installed it via Composer using Lando. I want to put this drush in my system path so that I can use it from cmd.exe, Powershell, and so on. I want to do ...
0
votes
0answers
25 views

How to install the module Entity Browser?

I'm trying to install the Entity Browser module, but I'm getting this error: It basically says that the "entity_browser" entity type does not exist, and based on the error I tried to install the ...
0
votes
2answers
2k views

How do I convert a pre-existing site to a Composer-managed application?

The latest Drush 9.x version recommends that Drupal 8 sites will be built using Composer, with Drush listed as a dependency. However, when you install Composer and Drush globally per step #1 on http://...