# \[SOLVED\] How to recover: "PDOException: could not find driver in /srv/nextcloud/html/3rdparty/doctrine/dbal/src/Driver/PDO/PDOConnect.php:28"

**URL:** <https://help.nextcloud.com/t/solved-how-to-recover-pdoexception-could-not-find-driver-in-srv-nextcloud-html-3rdparty-doctrine-dbal-src-driver-pdo-pdoconnect-php-28/248975>\
**Category:** ℹ️ Support\
**Tags:** update\_problems, nc33, setup\_warning\
**Created:** [September 6, 2026, 7:00am UTC](https://help.nextcloud.com/t/solved-how-to-recover-pdoexception-could-not-find-driver-in-srv-nextcloud-html-3rdparty-doctrine-dbal-src-driver-pdo-pdoconnect-php-28/248975 "2026-09-06T07:00:43Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![bignose](https://help.nextcloud.com/letter_avatar/bignose/32/5_5575768a8748004e209b776fc1b2916d.png) [@bignose](https://help.nextcloud.com/u/bignose)\
**Post date:** [September 6, 2026, 7:00am UTC](https://help.nextcloud.com/t/solved-how-to-recover-pdoexception-could-not-find-driver-in-srv-nextcloud-html-3rdparty-doctrine-dbal-src-driver-pdo-pdoconnect-php-28/248975/1 "2026-09-06T07:00:43Z")

</div>

## The Basics

- Nextcloud Server version: `33.0.8`
- Operating system and version: `Debian 13.6`
- Web server and version: `apache2/2.4.68-1~deb13u1`
- Reverse proxy and version: `none`
- PHP version: `8.4`
- Is this the first time you’ve seen this error?: `Yes`
- When did this problem seem to first start?
  - `When attempting to 'maintenance:repair'`

- Installation method _(e.g. AlO, NCP, Bare Metal/Archive, etc.)_
  - `Install from `[https://download.nextcloud.com/server/releases/nextcloud-33.0.8.zip](https://download.nextcloud.com/server/releases/nextcloud-33.0.8.zip)

- Are you using CloudfIare, mod\_security, or similar?: `No`

### Summary of the issue you are facing:

During an attempted upgrade, I mistakenly removed the entire Nextcloud `…/html/` directory. Realising this was a problem I attempted to recover:

- Ensure the Nextcloud database is not damaged.
- Ensure the Nextcloud `…/data/` directory is not damaged.
- Restore the Nextcloud `…/html/config/` directory.
- Download the Nextcloud installation archive from [https://download.nextcloud.com/server/releases/nextcloud-33.0.8.zip](https://download.nextcloud.com/server/releases/nextcloud-33.0.8.zip)
  - Unpack that installation archive to `…/html/.`

- Run `… occ maintenance:repair` command to correct this broken Nextcloud instance.

Nextcloud crashes, complaining (accurately) that a file it wants is not in `…/html/3rdparty/`.

How can I continue the repair beyond this point; how do I provide Nextcloud the correct contents of `…/html/3rdparty/`? It does not appear in the installation archive, nor in any backup I have.

I assume there might be many more files Nextcloud expects to find in that directory. How can I get the repair complete without those files; alternatively, how can I find and install those files correctly?

### Steps to replicate it (hint: details matter!):

1. Make the mistake of deleting everything within `…/html/`.

2. Restore the `…/html/config/` directory.

3. Download and install Nextcloud installation archive `nextcloud-33.0.8.zip` into `…/html/.`

4. Run Nextcloud admin command `… occ maintenance:repair`.

Nextcloud crashes with a traceback:

```auto
An unhandled exception has been thrown:
PDOException: could not find driver in /srv/nextcloud/html/3rdparty/doctrine/dbal/src/Driver/PDO/PDOConnect.php:28
Stack trace:
…

```

### Configuration

#### Nextcloud

```auto
<?php

$CONFIG = array(
    'instanceid' => 'REDACTED',
    'passwordsalt' => 'REDACTED',
    'secret' => 'REDACTED',
    'config_is_read_only' => false,
    'installed' => true,
    'log_type' => 'syslog',
    'logdateformat' => DateTime::ISO8601,
    'maintenance' => false,
    'maintenance_window_start' => 23,
    'trusted_domains' => [
        'REDACTED.example.org',
    ],
    'overwrite.cli.url' => 'https://REDACTED.example.org/nextcloud',
    'htaccess.RewriteBase' => '/nextcloud',
    'mail_from_address' => 'nextcloud',
    'mail_domain' => 'REDACTED.example.org',
    'mail_send_plaintext_only' => true,
    'default_language' => 'en',
    'default_locale' => 'en_AU',
    'default_phone_region' => 'AU',
    'trashbin_retention_obligation' => 'auto, 30',
    'memcache.locking' => '\\OC\\Memcache\\Redis',
    'redis' => array(
        'host' => 'localhost',
        'port' => 6379,
        'timeout' => 0.0,
        'password' => '',
    ),
);
?>

```

---

<div class="post-metadata">

**Author:** ![jtr](https://help.nextcloud.com/letter_avatar/jtr/32/5_5575768a8748004e209b776fc1b2916d.png) [@jtr](https://help.nextcloud.com/u/jtr)\
**Post date:** [September 6, 2026, 5:44pm UTC](https://help.nextcloud.com/t/solved-how-to-recover-pdoexception-could-not-find-driver-in-srv-nextcloud-html-3rdparty-doctrine-dbal-src-driver-pdo-pdoconnect-php-28/248975/2 "2026-09-06T17:44:05Z")

</div>

> [@bignose](#):
>
> - Installation method _(e.g. AlO, NCP, Bare Metal/Archive, etc.)_
> - `Install from `[https://download.nextcloud.com/server/releases/nextcloud-33.0.8.zip](https://download.nextcloud.com/server/releases/nextcloud-33.0.8.zip)

~~That’s the official source repo snapshot, but not an installation asset. For example, it lacks `3rdparty/` and other core components located in other repositories, that are required for an actual installation.~~

Please use the official Archive download links.

---

<div class="post-metadata">

**Author:** ![bignose](https://help.nextcloud.com/letter_avatar/bignose/32/5_5575768a8748004e209b776fc1b2916d.png) [@bignose](https://help.nextcloud.com/u/bignose)\
**Post date:** [September 7, 2026, 12:38am UTC](https://help.nextcloud.com/t/solved-how-to-recover-pdoexception-could-not-find-driver-in-srv-nextcloud-html-3rdparty-doctrine-dbal-src-driver-pdo-pdoconnect-php-28/248975/3 "2026-09-07T00:38:14Z")

</div>

> [@jtr](#):
>
> That [archive from the [Index of /server/releases](https://download.nextcloud.com/server/releases/) repository] is the official source repo snapshot, but not an installation asset.

When did that change? I’ve been installing from those archives for years without a problem.

Looking in [the installation page](https://nextcloud.com/install/#tab_link_download-server) today, it leads me to a file in the same directory, but with no Nextcloud version (‘latest.zip’). This is not suitable for a reliable automated install, I need to download the file for the specific version I’ve chosen, for a reproducible deployment. So which file should I be using for that?

The only archive files there that are marked by full version number (e.g. “33.0.8”), are the files named starting with ‘nextcloud’ (e.g. [https://download.nextcloud.com/server/releases/nextcloud-33.0.8.zip](https://download.nextcloud.com/server/releases/nextcloud-33.0.8.zip) for version “33.0.8”). If you say I should not be using those, which file with a fully-specified version URL are you saying I should install?

Also this does not seem to do much to address the problem I face immediately: How do I get the ‘3rdparty’ directory populated correctly, for some specific Nextcloud version?

---

<div class="post-metadata">

**Author:** ![bignose](https://help.nextcloud.com/letter_avatar/bignose/32/5_5575768a8748004e209b776fc1b2916d.png) [@bignose](https://help.nextcloud.com/u/bignose)\
**Post date:** [September 7, 2026, 5:07am UTC](https://help.nextcloud.com/t/solved-how-to-recover-pdoexception-could-not-find-driver-in-srv-nextcloud-html-3rdparty-doctrine-dbal-src-driver-pdo-pdoconnect-php-28/248975/4 "2026-09-07T05:07:58Z")

</div>

> [@bignose](#):
>
> So which file should I be using for that?

Attempting to proceed:

- Downloaded ‘latest-33.zip’ and unpacked it to a temporary directory.
- Replaced (removed existing, copied from the unpacked files) the ‘3rdparty/’ directory.

When I run `…/occ maintenance:repair` I get the same crash and error as initially reported.

How do I determine what files are needed, and how to install precisely those files to satisfy this Nextcloud instance to the point it can repair?

---

<div class="post-metadata">

**Author:** ![jtr](https://help.nextcloud.com/letter_avatar/jtr/32/5_5575768a8748004e209b776fc1b2916d.png) [@jtr](https://help.nextcloud.com/u/jtr)\
**Post date:** [September 7, 2026, 8:16pm UTC](https://help.nextcloud.com/t/solved-how-to-recover-pdoexception-could-not-find-driver-in-srv-nextcloud-html-3rdparty-doctrine-dbal-src-driver-pdo-pdoconnect-php-28/248975/5 "2026-09-07T20:16:29Z")

</div>

My bad. I completely misread the URL; I thought you were pulling it from the GitHub link. I blame my mobile device I was reading your message on yesterday. 🙂 Sorry about that.

---

<div class="post-metadata">

**Author:** ![jtr](https://help.nextcloud.com/letter_avatar/jtr/32/5_5575768a8748004e209b776fc1b2916d.png) [@jtr](https://help.nextcloud.com/u/jtr)\
**Post date:** [September 7, 2026, 8:25pm UTC](https://help.nextcloud.com/t/solved-how-to-recover-pdoexception-could-not-find-driver-in-srv-nextcloud-html-3rdparty-doctrine-dbal-src-driver-pdo-pdoconnect-php-28/248975/6 "2026-09-07T20:25:45Z")

</div>

> [@bignose](#):
>
> ```auto
> An unhandled exception has been thrown:
> PDOException: could not find driver in /srv/nextcloud/html/3rdparty/doctrine/dbal/src/Driver/PDO/PDOConnect.php:28
> Stack trace:
> …
> 
> ```

The full stack trace would be more helpful, but this isn’t say a file is missing from `3rdparty`. It’s saying the PHP extension for your database isn’t installed.

I don’t see any database configuration in your provided config file.

---

<div class="post-metadata">

**Author:** ![bignose](https://help.nextcloud.com/letter_avatar/bignose/32/5_5575768a8748004e209b776fc1b2916d.png) [@bignose](https://help.nextcloud.com/u/bignose)\
**Post date:** [September 12, 2026, 12:05am UTC](https://help.nextcloud.com/t/solved-how-to-recover-pdoexception-could-not-find-driver-in-srv-nextcloud-html-3rdparty-doctrine-dbal-src-driver-pdo-pdoconnect-php-28/248975/7 "2026-09-12T00:05:37Z")

</div>

> [@jtr](#):
>
> I don’t see any database configuration in your provided config file.

Thank you for this. It prompted me to verify the restored configuration, and indeed the database connection settings were not there.

I now have the database settings in one place, where the ‘autoconfig.php’ and ‘config.php’ can both use them. With this in place, the error ceases and I can continue.

---

<div class="post-metadata">

**Author:** ![system](https://help.nextcloud.com/user_avatar/help.nextcloud.com/system/32/29333_2.png) [@system](https://help.nextcloud.com/u/system)\
**Post date:** [September 20, 2026, 12:06am UTC](https://help.nextcloud.com/t/solved-how-to-recover-pdoexception-could-not-find-driver-in-srv-nextcloud-html-3rdparty-doctrine-dbal-src-driver-pdo-pdoconnect-php-28/248975/8 "2026-09-20T00:06:35Z")

</div>

This topic was automatically closed 8 days after the last reply. New replies are no longer allowed.
