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
0answers
31 views

Drush corrupts site [closed]

When using the drush command that makes a change to Drupal it is corrupting my Drupal 9 site. I have been using it steadily and think it may be a result of being updated. Any help would be GREATLY ...
0
votes
1answer
44 views

Hook on drush cache:rebuild

Is it possible to hook on drush cache:rebuild before the command is executed? I've seen some hooks for afterwards, but I am trying to compile my less files into css before cache the is rebuild. I'd be ...
0
votes
1answer
28 views

Why will drupal not recognize my configuration?

I am trying to import configuration from one site to another. I have copied the directory full of config files from an older site to my new site. When I try to run Drush cim, the files all show up ...
1
vote
1answer
28 views

user:role:add for email addresses in Drush 9/10?

In Drush 8, you can add a role to an email address like this: drush user-add-role "power user" --mail=penguin@example.com In Drush 9, the --mail option no longer exists for user:role:add. ...
0
votes
0answers
15 views

Drush failing to load drush.php file

I have Drupal 8 project on my local machine, which is set up with composer and I got drush included. When I'm in project root I can call drush like: vendor/bin/drush -v And that work well (...
-1
votes
1answer
29 views

How do I fix the error given from “drush en nodejs -y”?

When I run drush en nodejs -y, I get this error. In PmCommands.php line 247: Unable to install modules nodejs due to missing modules nodejs. How do I fix that error? I am using Drush 10.2.2 and ...
0
votes
0answers
34 views

PHP Segfault error when running a migration

I ran drush migrate-upgrade on a Drupal 8 fresh installed site, and it generated the migrations (from Drupal 7 to Drupal 8). After that, I tried to run drush mim upgrade_d7_user (after roles and ...
2
votes
1answer
31 views

How can I suppress the “connection to @remote closed” message?

I'm running Drush 10 and have set up site aliases for my local and the remote Drupal site. When I run the following command for my local alias: drush @local dd This returns: var/www/html/abc But ...
0
votes
0answers
17 views

migration plugin works but fail to migrate in drupal database

I try to migrate old blog article to a drupal website here is my migration class : class Article extends SqlBase { /** *{@inheritDoc} */ public function query() { $query = $this->...
0
votes
2answers
62 views

Is there a cli equivalent of the web ui with underspecification?

background I run drush cget markdown.settings and see: dependencies: module: - markdown parser: id: michelf/php-markdown-extra render_strategy: type: none settings: ...
-1
votes
0answers
57 views

'Drush cr' returns Symfony error

When I run 'drush cr', I get the following: PHP Fatal error: Uncaught TypeError: Argument 2 passed to Symfony\Component\EventDispatcher\EventDispatcher::dispatch() must be an instance of Symfony\...
0
votes
0answers
20 views

Multi site Image cache issue

actually i am new to drupal and i have migrated my drupal site from 8 to 9. This site is multi site, every thing is working fine but the issue is related to the images. When i cleared the cache using ...
1
vote
1answer
51 views

How do I replace drush_set_error()?

Just updating a module for Drupal 9 and Drush 10 and drush_set_error() no longer appears as a function in the Drush code (as far as I can see). What should I be using instead?
0
votes
1answer
43 views

Exception: In BootstrapHook.php line 32, how can I consistently resolve this?

My build process is (mostly working), but sometimes when I swap out to a new project, I am winding up with an error which looks like the output below. I have found this error message extremely ...
0
votes
0answers
38 views

Drush cr is responding with Bootstrap Failed

I have a Drupal 8.9 site I built on my development server. I've now copied it over to my production server (Ubuntu 16) and set up the database. I need to run drush cr to finish the process but when I ...
0
votes
0answers
31 views

How do I change local site alias?

I've recently upgraded from Drush 8 to Drush 9. In Drush 8, I use drush @project.local.sitename status; in Drush 9, I have to run drush @project-local.sitename status. How can I replace the hyphen ...
0
votes
0answers
52 views

Drush commands are not working in Xampp on Windows

In Xampp 2 Drupal sites are there.one is drupal 7.0 and another one is drupal 8.8.7. Drush version is 8.3.5, PHP version is 7.2.22 ,composer 1.9.2 When I try enabling module in Drupal 7.0 drush en ...
0
votes
0answers
20 views

Updated to 8.9.1 getting 'content_moderation_state plugin does not exist' message

Updated a drupal project to 8.9.1, all seemed to go smoothly. After i run drush updb and I got the following message. Anyone know what's this about and how to resolve? All other update were run ...
1
vote
1answer
35 views

Workaround for missing migrate-deregister command in Drush 10.3.1?

I'm trying to migrate and upgrade a site from Drupal 7 to Drupal 8 (version 8.9.1). The migration cannot be accomplished with the UI, since I need to make some changes to the content types and ...
1
vote
0answers
26 views

Unable to set author and created time when translating node programmatically

I am adding translation to a node programmatically using a script which I run with drush scr. Everything works as far as adding translation and copying all the fields over. However, I am not able to ...
0
votes
2answers
48 views

Problem with drush and site alias (Drupal 8.8.6 / Drush 10.3.1)

I've installed two drupal sites on a share hosting (OVH), in two folders : dev.www www I've installed drush 10.3.1 and create two alias, but when I try use alias (drush @dev status), I have the ...
2
votes
1answer
37 views

How to ensure successful update after system failure during updb causing the site to remain in maintenance mode?

Running drush updb to upgrade drupal core or other modules, puts the site in maintenance mode. I recently faced an issue (probably an edge case) where the site was stuck in maintenance mode after ...
0
votes
1answer
39 views

Can't find migration when running drush migration:status

I'm trying a tutorial to migrate users data from a CSV file. From here: https://u.group/thinking/drupal-8-csv-migration/ I've created a module as suggested. Here is the code: /config/install/...
0
votes
0answers
35 views

How can I execute one Drush 10 installation from any of my different sites (NOT multi-site)?

What is the proper way to install Drush 10 if I have a domain and several independently installed subdomains like described below? I want to avoid multiple drush installs. On my shared hosting account,...
0
votes
0answers
56 views

'[warning] Drush command terminated abnormally.'

Drush won't run at the command line in any Drupal 8 subdomain installation: [warning] Drush command terminated abnormally. I am using GreenGeeks hosting for several Drupal 8.8.7 sites, one 8.8.6 site, ...
0
votes
2answers
109 views

How to overcome error caused by non-existent service “entity.manager”?

I am running drush first time in my Drupal 9 project and getting the following error In CheckExceptionOnInvalidReferenceBehaviorPass.php line 86: The service "sanitize.userfields.commands"...
1
vote
1answer
64 views

How can I upgrade to core 9?

I have Drupal 8.8.* and I would like to migrate to Drupal 9 using Drush 8. I know, we can use composer however I just wanted to confirm, whether we can do by using Drush command? I tried using Drush ...
1
vote
1answer
22 views

How can I use config-set to “unset” the value of a variable?

I am trying to use config-set to "unset" a variable. In this case, I have a media image field that has required crop types on it, which is breaking my behat tests, so I want to use drush to ...
0
votes
0answers
48 views

How to migrate content using migrate-manifest?

English is not my native language so please be patient. I'm totally new to Drupal development so I was learning how to migrate from Drupal7 to Drupal8 due to some work necessities to test a POC, the ...
0
votes
1answer
23 views

Cannot export theme settings to the .info file

I am using Drupal 7. After modifying a setting for my theme in the Appearance menu, I get the following alert message on my site's homepage: The settings for this theme are currently served from a ...
0
votes
0answers
8 views

Schedule a current state of a content to be publish is not working

I'm having some issues with drupal/core 8.7.7, when i crate a new content or use a content already published , i want to schedule that content to be changed from one state to another. ex: But when i ...
0
votes
0answers
54 views

Drush database issue

I have encountered an issue with Drush. I am missing a number of commands. When running a command with --debug I am told [Symfony\Component\Console\Exception\CommandNotFoundException] Command rq was ...
0
votes
0answers
51 views

Drush on Acquia Dev Desktop is terribly slow

I'm running version 2, built Jan 9 2020, on a Windows 10 machine. I'm opening the command line via the dev desktop interface (via the small, black command line icon), and all drush commands run ...
2
votes
2answers
54 views

What's the syntax of drush generate --answers argument?

So I am trying to automate theme creation using drush. There is no documentation on how to fill the --answers argument there https://drushcommands.com/drush-9x/core/generate/ I have tried: drush ...
0
votes
0answers
34 views

Running drush updb for a multisite alias is not working

I have a multisite enviroment and I'm trying to run drush updb and drush cim for the multisites using aliases. To achieve this i created a wildcarded alias file like this in drush/sites: alias.site....
0
votes
0answers
17 views

search-index with drush fails on field_collection error

I've been rebuilding my search index using "drush search-index" for the better part of the day. There have been a few odd errors that I have handled as I went along, making some fixes in the process ...
0
votes
1answer
54 views

drush migrate:status comes back with SQLSTATE [hy000] [2002] No such file or directory

Using drush on my macOS. Using Nginx and MYSQL through brew. Website is running fine. The other drush commands work fine, drush cr, drush cc, etc. But running drush migrate:status or drush ms results ...
3
votes
2answers
94 views

Interactive Drush Script

I would like to write an interactive Drush script that potentially makes a change to all pages of a website. Let's say we would would like to change "Foo" to "Baz" on each page. We want to review ...
1
vote
1answer
31 views

How to confirm that drush-based cron is being called from crontab?

I don’t know whether this is a docksal-specific question or a general cron one, but likely the latter. I’ve set up a crontab for docksal (see https://blog.docksal.io/running-scheduled-events-with-...
0
votes
0answers
18 views

Creating site alias issue [duplicate]

Using examples/example.site.yml, I created a self.site.yml file which seemed to work fine. I get the correct values when running drush site:alias @self.stage, but when I try to run drush command @...
0
votes
0answers
66 views

Does drush stop events from firing and/or bypass event subscribers?

I'm running some migrations and have logic dependent on their Events public static function getSubscribedEvents() { $events[MigrateEvents::POST_IMPORT][] = ['onMigratePostImport']; return $...
0
votes
2answers
77 views

I get errors when I try to do anything with migrations

So I'm new to Drupal, and I'm trying to set up a migration. I followed a tutorial to import a basic csv as an article yesterday, that worked ok. There are no errors showing using the admin area of ...
1
vote
0answers
42 views

How do I install Drush 9 without Composer? [duplicate]

I'm using the Drupal image for Docker to test module development. I also want to use Drush to automate certain tasks. However, the Drush 9 installation instructions state that the only supported ...
0
votes
0answers
17 views

Error using drush to generate YML file

I am attempting to use the Migrate File Entities to Media Entities module, https://www.drupal.org/project/migrate_file_to_media I am running Drupal 8.7.10 and drush 9.7.2. in Acquia DevDesktop ver. 2....
0
votes
1answer
35 views

Use drush to install a module on all of the sites of a multisite at once

I have a Drupal 8 multisite, setup with 6 different sites. I want to install Admin Toolbar on all of them on my local dev environment (mamp / terminal / drush). I have downloaded that module using ...
0
votes
0answers
33 views

Could not initialize PECL extension even though memcached installed

I am migrating a site from one remote server to another. I have set up the new server will all the prerequisites installed memcached server and its extension too. But when I try to run drush cr I get ...
-1
votes
1answer
210 views

Is it possible to update/remove/install 1 package with composer without updating everything?

I have seen a few posts answering this and saying that "composer require package" or "composer update package" will do this; but absolutely everything i do with composer attempts to update everything ...
0
votes
0answers
31 views

I can't clone a project

I have a locally multi-site. Locally Drush works perfectly fine. But When I try to clone this project in different machine I get this error in Acquia Dev Desktop: I also tried to run a Drush command ...
0
votes
1answer
49 views

Troubles with external configuration

I'm working in the creation of a custom profile. When the installation is already finished, on the configuration module /admin/config/development/configuration appears the following warning The ...
0
votes
0answers
55 views

How can I create a content type field?

How do i create a content type field using Drush or Drupal Console? I tried both ways but nothing seems to work. I am using Drush Commandline Tool 9.7.1 and Drupal Console version 1.9.4. Drush: $ ...

1
2 3 4 5
38