Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docker compose deployment was failed to start server after restart seervice #489

Open
NickLin910221 opened this issue Mar 28, 2024 · 0 comments

Comments

@NickLin910221
Copy link

I have restart my owncloud service wih docker compose
But went out the error

Next Doctrine\DBAL\Exception\TableNotFoundException: An exception occurred while executing 'SELECT * FROM oc_appconfig':

SQLSTATE[42S02]: Base table or view not found: 1146 Table 'owncloud.oc_appconfig' doesn't exist in /var/www/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Driver/AbstractMySQLDriver.php:61
Stack trace:
#0 /var/www/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/DBALException.php(182): Doctrine\DBAL\Driver\AbstractMySQLDriver->convertException()
owncloud-docker/base#1 /var/www/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/DBALException.php(159): Doctrine\DBAL\DBALException::wrapException()
owncloud-docker/base#2 /var/www/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(2226): Doctrine\DBAL\DBALException::driverExceptionDuringQuery()
owncloud-docker/base#3 /var/www/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(1313): Doctrine\DBAL\Connection->handleExceptionDuringQuery()
owncloud-docker/base#4 /var/www/owncloud/lib/private/DB/Connection.php(191): Doctrine\DBAL\Connection->executeQuery()
owncloud-docker/base#5 /var/www/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Query/QueryBuilder.php(212): OC\DB\Connection->executeQuery()
owncloud-docker/base#6 /var/www/owncloud/lib/private/DB/QueryBuilder/QueryBuilder.php(141): Doctrine\DBAL\Query\QueryBuilder->execute()
owncloud-docker/base#7 /var/www/owncloud/lib/private/AppConfig.php(312): OC\DB\QueryBuilder\QueryBuilder->execute()
owncloud-docker/base#8 /var/www/owncloud/lib/private/AppConfig.php(80): OC\AppConfig->loadConfigValues()
owncloud-docker/base#9 /var/www/owncloud/lib/private/AppConfig.php(289): OC\AppConfig->getApps()
owncloud-docker/base#10 /var/www/owncloud/lib/private/App/AppManager.php(133): OC\AppConfig->getValues()
owncloud-docker/base#11 /var/www/owncloud/lib/private/App/AppManager.php(154): OC\App\AppManager->getInstalledAppsValues()
owncloud-docker/base#12 /var/www/owncloud/lib/private/legacy/app.php(352): OC\App\AppManager->getInstalledApps()
owncloud-docker/base#13 /var/www/owncloud/lib/private/legacy/app.php(108): OC_App::getEnabledApps()
owncloud-docker/base#14 /var/www/owncloud/lib/kernel.php(591): OC_App::loadApps()
owncloud-docker/base#15 /var/www/owncloud/lib/kernel.php(1059): OC::init()
owncloud-docker/base#16 /var/www/owncloud/lib/base.php(27): require_once('/var/www/ownclo...')
owncloud-docker/base#17 /var/www/owncloud/console.php(52): require_once('/var/www/ownclo...')
owncloud-docker/base#18 /var/www/owncloud/occ(11): require_once('/var/www/ownclo...')

Here is the config
version: "3"

volumes:
files:
driver: local
driver_opts:
type: none
device: /home/dearestbee/disk/owncloud
o: bind
mysql:
driver: local
driver_opts:
type: none
device: /home/dearestbee/disk/owncloud
o: bind
redis:
driver: local
driver_opts:
type: none
device: /home/dearestbee/disk/owncloud
o: bind

services:
owncloud:
image: owncloud/server:${OWNCLOUD_VERSION}
container_name: owncloud_server
restart: always
ports:
- ${HTTP_PORT}:8080
depends_on:
- mariadb
- redis
environment:
- OWNCLOUD_DOMAIN=${OWNCLOUD_DOMAIN}
- OWNCLOUD_TRUSTED_DOMAINS=${OWNCLOUD_TRUSTED_DOMAINS}
- OWNCLOUD_DB_TYPE=mysql
- OWNCLOUD_DB_NAME=owncloud
- OWNCLOUD_DB_USERNAME=owncloud
- OWNCLOUD_DB_PASSWORD=owncloud
- OWNCLOUD_DB_HOST=mariadb
- OWNCLOUD_ADMIN_USERNAME=${ADMIN_USERNAME}
- OWNCLOUD_ADMIN_PASSWORD=${ADMIN_PASSWORD}
- OWNCLOUD_MYSQL_UTF8MB4=true
- OWNCLOUD_REDIS_ENABLED=true
- OWNCLOUD_REDIS_HOST=redis
- OWNCLOUD_SUB_URL=/owncloud
healthcheck:
test: ["CMD", "/usr/bin/healthcheck"]
interval: 30s
timeout: 10s
retries: 5
volumes:
- files:/mnt/data

mariadb:
image: mariadb:10.11 # minimum required ownCloud version is 10.9
container_name: owncloud_mariadb
restart: unless-stopped
environment:
- MYSQL_ROOT_PASSWORD=owncloud
- MYSQL_ROOT_HOST="%"
- MYSQL_USER=owncloud
- MYSQL_PASSWORD=owncloud
- MYSQL_DATABASE=owncloud
# - MARIADB_AUTO_UPGRADE=1
command: ["--max-allowed-packet=128M", "--innodb-log-file-size=64M"]
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-u", "root", "--password=owncloud"]
interval: 10s
timeout: 5s
retries: 5
volumes:
- mysql:/var/lib/mysql

redis:
image: redis:6
container_name: owncloud_redis
restart: unless-stopped
command: ["--databases", "1"]
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 5s
retries: 5
volumes:
- redis:/data

@DeepDiver1975 DeepDiver1975 transferred this issue from owncloud-docker/base Aug 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant