从社区版迁移到专业版资料库不显示


#1

我从7.0.2社区版升级到7.0.3专业版,网页可以打开,客户端也正常连接,但是资料库全部不见了,启动时终端未报错,切换了两个用户资料库都不显示。
切换回社区版正常。


#2

把你的升级过程和升级后的问题现象贴一下吧


#3

升级过程参照文档来的。

系统:Linux ubuntu 4.15.0-51-generic #55-Ubuntu SMP Wed May 15 14:27:21 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
我下的专业版是 seafile-pro-server_7.0.3_x86-64_Ubuntu.tar.gz

1、下载之后,解压。
2、停止之前的社区版。seafile.sh stop && seahub.sh stop
3、进入7.0.3专业版目录。
4、执行 sudo ./pro/pro.py setup --migrate
5、启动专业版 sudo seafile.sh start && seahub.sh start

这些操作没发现有报错。

重新在浏览器打开 Seafile,登录账号,网页上显示“没有资料库请创建”的提示。

如果有必要的话,我可以再来一次,将每一步截图附加上来。


#4

升级后资料库显示有问题建议清理下seahub缓存,你在论坛里搜下,有关于清理seahub缓存的帖子


#5
$ ls /tmp
hsperfdata_root
jna-3506402
lu721416pfvt.tmp
OSL_PIPE_0_seafilepipe
OSL_PIPE_0_SingleOfficeIPC_53bc4297d6d012e1a744f3977d159334
rc.local.log
seafile-office-output
systemd-private-9329f29aecfc4a2882bd1dbcadd8b9c6-memcached.service-C1riM7
systemd-private-9329f29aecfc4a2882bd1dbcadd8b9c6-systemd-resolved.service-cZ39L8
systemd-private-9329f29aecfc4a2882bd1dbcadd8b9c6-systemd-timesyncd.service-udlAOe

seafile-office-output 吗?
没有看到其他帖子提到的 /tmp/seahub-cache/*,这个缓存目录是否可配置?我怕我可能修改过。
我的 /tmp 是 tmpfs 格式,放在内存中的,有尝试过重启系统,问题依旧。


#6

你配置了memcached服务了吗
你还是把网页失败的现象贴一下吧


#7

有配置memcached。


#8

再贴一下刚刚的升级操作过程吧

root@ubuntu:/opt/seafile/seafile-server-7.0.2# ./seafile.sh stop

Stopping seafile server ...
Done.
root@ubuntu:/opt/seafile/seafile-server-7.0.2# ./seahub.sh stop

Stopping seahub ...
Done.

root@ubuntu:/opt/seafile/seafile-server-7.0.2# cd ..
root@ubuntu:/opt/seafile# ls
aio_seafile-server.log  installed  pro-data          seafile-pro-server-7.0.3                       seafile-server-latest
ccnet                   logs       seafile-data      seafile-pro-server_7.0.3_x86-64_Ubuntu.tar.gz  seahub-data
conf                    pids       seafile-data_bak  seafile-server-7.0.2
root@ubuntu:/opt/seafile# cd seafile-pro-server-7.0.3/
root@ubuntu:/opt/seafile/seafile-pro-server-7.0.3# ls
check-db-type.py     migrate-to-ceph.sh   seaf-backup-cmd.py  seaf-gen-key.sh              seahub                  sql
check_init_admin.py  pro                  seaf-backup-cmd.sh  seafile                      seahub-extra            upgrade
create-db            reset-admin.sh       seaf-encrypt.sh     seafile-background-tasks.sh  seahub.sh
index_op.py          run_index_master.sh  seaf-fsck.sh        seafile.sh                   setup-seafile-mysql.py
migrate.py           run_index_worker.sh  seaf-fuse.sh        seaf-import.sh               setup-seafile-mysql.sh
migrate.sh           runtime              seaf-gc.sh          seafobj_migrate.py           setup-seafile.sh
root@ubuntu:/opt/seafile/seafile-pro-server-7.0.3# ./pro/pro.py setup --migrate

Checking java ... Done
Your seafile server is using mysql

-------------------------------------------------------------
This script would do the minor upgrade for you.
Press [ENTER] to contiune
-------------------------------------------------------------



------------------------------
migrating avatars ...


DONE
------------------------------


updating seafile-server-latest symbolic link to /opt/seafile/seafile-pro-server-7.0.3 ...

DONE
------------------------------

root@ubuntu:/opt/seafile/seafile-pro-server-7.0.3# ./seafile.sh start

** Message: seafile-controller.c(1157): loading seafdav config from /opt/seafile/conf/seafdav.conf

[06/18/19 16:35:19] ../common/session.c(139): using config file /opt/seafile/conf/ccnet.conf
[06/18/19 16:35:19] ../common/license.c(406): Loading license file /opt/seafile/seafile-license.txt ..
[06/18/19 16:35:19] ../common/license.c(409): License file /opt/seafile/seafile-license.txt does not exist, allow at most 3 trial users
License file /opt/seafile/seafile-license.txt does not exist, allow at most 3 trial users
Starting seafile server, please wait ...
** Message: seafile-controller.c(1157): loading seafdav config from /opt/seafile/conf/seafdav.conf

Seafile server started

Done.
root@ubuntu:/opt/seafile/seafile-pro-server-7.0.3# ./seahub.sh start

LC_ALL is not set in ENV, set to en_US.UTF-8
Starting seahub at port 8000 ...

Seahub is started

Done.


#9

你运行下fsck吧 https://manual-cn.seafile.com/maintain/seafile_fsck.html


#10

FSCK结果。

root@ubuntu:/opt/seafile/seafile-pro-server-7.0.3# ./seaf-fsck.sh

Starting seaf-fsck, please wait ...

[06/18/19 16:59:38] fsck.c(601): Running fsck for repo e6ac70ac-5bea-49c8-9e2f-d8e041355699.
[06/18/19 16:59:38] fsck.c(427): Checking file system integrity of repo test(e6ac70ac)...
[06/18/19 16:59:39] fsck.c(665): Fsck finished for repo e6ac70ac.

[06/18/19 16:59:39] fsck.c(601): Running fsck for repo cc0813f7-eacc-4df3-9bc9-f3a6b9a87a7d.
[06/18/19 16:59:39] fsck.c(427): Checking file system integrity of repo 我的资料库(cc0813f7)...
[06/18/19 17:00:30] fsck.c(665): Fsck finished for repo cc0813f7.

[06/18/19 17:00:30] fsck.c(601): Running fsck for repo 9111a7e0-0e47-453f-b3c2-c66abfad8c93.
[06/18/19 17:00:30] fsck.c(427): Checking file system integrity of repo XXXXXX(9111a7e0)...
[06/18/19 17:00:37] fsck.c(665): Fsck finished for repo 9111a7e0.

[06/18/19 17:00:37] fsck.c(601): Running fsck for repo 8ce12a47-206c-40a3-a803-886c667dfa06.
[06/18/19 17:00:38] fsck.c(427): Checking file system integrity of repo 我的资料库(8ce12a47)...
[06/18/19 17:00:38] fsck.c(665): Fsck finished for repo 8ce12a47.

[06/18/19 17:00:38] fsck.c(601): Running fsck for repo 7816e488-e5ec-4a08-826c-8e8b26fd2ad8.
[06/18/19 17:00:38] fsck.c(427): Checking file system integrity of repo 个人维基(7816e488)...
[06/18/19 17:00:51] fsck.c(665): Fsck finished for repo 7816e488.

[06/18/19 17:00:51] fsck.c(601): Running fsck for repo 77e16071-a5f4-4eef-a63e-8b6751d453a8.
[06/18/19 17:00:51] fsck.c(427): Checking file system integrity of repo My Library Template(77e16071)...
[06/18/19 17:00:51] fsck.c(665): Fsck finished for repo 77e16071.

[06/18/19 17:00:51] fsck.c(601): Running fsck for repo 4b93b0ac-7fcf-4157-9f26-94594318cff1.
[06/18/19 17:00:51] fsck.c(427): Checking file system integrity of repo 相册(4b93b0ac)...
[06/18/19 17:02:22] fsck.c(665): Fsck finished for repo 4b93b0ac.

[06/18/19 17:02:22] fsck.c(601): Running fsck for repo 3b88946f-c618-46a9-8780-511c1b9d6baf.
[06/18/19 17:02:22] fsck.c(427): Checking file system integrity of repo debug(3b88946f)...
[06/18/19 17:02:23] fsck.c(665): Fsck finished for repo 3b88946f.

[06/18/19 17:02:23] fsck.c(601): Running fsck for repo 34720653-a3e0-42b5-9811-a11cd6485f67.
[06/18/19 17:02:23] fsck.c(427): Checking file system integrity of repo 相册(34720653)...
[06/18/19 17:04:52] fsck.c(665): Fsck finished for repo 34720653.

[06/18/19 17:04:52] fsck.c(601): Running fsck for repo 22363595-787f-48be-8a62-8d6694953c72.
[06/18/19 17:04:52] fsck.c(427): Checking file system integrity of repo 我的资料库(22363595)...
[06/18/19 17:05:17] fsck.c(665): Fsck finished for repo 22363595.

seaf-fsck run done

Done.

再贴下系统管理的截图


#11

image 你这俩目录是咋回事,另外你看下seafile.log有啥报错没有吧


#12
root@ubuntu:/opt/seafile# ls -a -l
总用量 132716
drwxr-xr-x 12 root root      4096 6月  18 17:17 .
drwxr-xr-x  4 root root      4096 6月  18 10:06 ..
-rw-------  1 root root      1919 7月  16  2018 aio_seafile-server.log
drwx------  3 root root      4096 6月  18 17:17 ccnet
drwx------  2 root root      4096 6月  18 16:56 conf
drwxr-xr-x  2 root root      4096 6月  17 16:52 installed
drwxr-xr-x  3 root root      4096 6月  18 10:34 logs
drwxr-xr-x  2 root root      4096 6月  18 17:17 pids
drwx------  2 root root      4096 6月  18 09:47 pro-data
lrwxrwxrwx  1 root root        22 7月  29  2018 seafile-data -> /media/st1000/seafile/
drwx------  9 root root      4096 7月  16  2018 seafile-data_bak
drwxrwxr-x 10 root root      4096 6月  13 10:57 seafile-pro-server-7.0.3
-rw-r--r--  1 root root 135841948 6月  18 09:43 seafile-pro-server_7.0.3_x86-64_Ubuntu.tar.gz
drwxr-xr-x  7 root root      4096 6月  13 13:39 seafile-server-7.0.2
lrwxrwxrwx  1 root root        20 6月  18 17:17 seafile-server-latest -> seafile-server-7.0.2
drwxr-xr-x  4 root root      4096 7月  17  2018 seahub-data

seafile-data 是链接
seafile-data bak 是以前刚装上的时候弄的原始备份。
seafile.log有报错,很多重复的

[06/18/2019 05:16:14 PM] filelock-mgr.c(1035): Failed to get OnlineOffice file locks
.[06/18/2019 05:16:42 PM] ../common/seaf-db.c(460): Error prepare statement SELECT quota FROM RoleQuota WHERE role=?: mysql_stmt_prepare failed: Table 'seafile_db.RoleQuota' doesn't exist.

[06/18/2019 05:05:23 PM] ../common/seaf-db.c(460): Error prepare statement SELECT r.repo_id, s.size, b.commit_id, v.repo_id, v.origin_repo, v.path, v.base_commit, fc.file_count, i.status, st.storage_id FROM Repo r LEFT JOIN Branch b ON r.repo_id = b.repo_id LEFT JOIN RepoSize s ON r.repo_id = s.repo_id LEFT JOIN VirtualRepo v ON r.repo_id = v.repo_id LEFT JOIN RepoFileCount fc ON r.repo_id = fc.repo_id LEFT JOIN RepoInfo i on r.repo_id = i.repo_id LEFT JOIN RepoStorageId st ON r.repo_id = st.repo_id WHERE r.repo_id = ? AND b.name = 'master': mysql_stmt_prepare failed: Table 'seafile_db.RepoStorageId' doesn't exist.


#13

你这好多数据表都没有创建出来,你的7.0.2开源版是怎么装出来的


#14

我是从 6.2.5 升级到 7.0.2的。
在7.0.2里执行了升级脚本,6.2到6.3,然后6.3到7.0,大概是这样。
刚开始的时候出现了markdown文档无法在线打开的问题,后面重新创建了base_file_xxxx这个表。就没问题了。
7.0.2可以正常运行的。
那现在要怎么办:disappointed_relieved:


#15

另外我迁移回社区版7.0.2,将log日志全部删除,启动后,日志中出现几个错误。

root@ubuntu:/opt/seafile/logs# cat controller.log 
[06/19/19 02:07:27] seafile-controller.c(175): starting ccnet-server ...
[06/19/19 02:07:27] seafile-controller.c(79): spawn_process: ccnet-server -F /opt/seafile/conf -c /opt/seafile/ccnet -f /opt/seafile/logs/ccnet.log -d -P /opt/seafile/pids/ccnet.pid
[06/19/19 02:07:27] seafile-controller.c(94): spawned ccnet-server, pid 1691
[06/19/19 02:07:28] seafile-controller.c(623): ccnet daemon connected.
[06/19/19 02:07:28] seafile-controller.c(207): starting seaf-server ...
[06/19/19 02:07:28] seafile-controller.c(79): spawn_process: seaf-server -F /opt/seafile/conf -c /opt/seafile/ccnet -d /media/st1000/seafile -l /opt/seafile/logs/seafile.log -P /opt/seafile/pids/seaf-server.pid
[06/19/19 02:07:28] seafile-controller.c(94): spawned seaf-server, pid 1828
[06/19/19 02:07:28] seafile-controller.c(453): pid file /opt/seafile/pids/seafevents.pid does not exist
[06/19/19 02:07:28] seafile-controller.c(79): spawn_process: /usr/bin/python2.7 -m seafevents.main --config-file /opt/seafile/conf/seafevents.conf --logfile /opt/seafile/logs/seafevents.log -P /opt/seafile/pids/seafevents.pid
[06/19/19 02:07:28] seafile-controller.c(94): spawned /usr/bin/python2.7, pid 1829
[06/19/19 02:07:28] seafile-controller.c(453): pid file /opt/seafile/pids/seafdav.pid does not exist
[06/19/19 02:07:28] seafile-controller.c(79): spawn_process: /usr/bin/python2.7 -m wsgidav.server.run_server runfcgi --log-file /opt/seafile/logs/seafdav.log --pid /opt/seafile/pids/seafdav.pid --port 8081 --host localhost
[06/19/19 02:07:28] seafile-controller.c(94): spawned /usr/bin/python2.7, pid 1830
[06/18/19 17:46:32] seafile-controller.c(453): pid file /opt/seafile/pids/seafevents.pid does not exist
[06/18/19 17:46:32] seafile-controller.c(486): seafevents need restart...
[06/18/19 17:46:32] seafile-controller.c(79): spawn_process: /usr/bin/python2.7 -m seafevents.main --config-file /opt/seafile/conf/seafevents.conf --logfile /opt/seafile/logs/seafevents.log -P /opt/seafile/pids/seafevents.pid
[06/18/19 17:46:32] seafile-controller.c(94): spawned /usr/bin/python2.7, pid 2935
[06/18/19 17:46:42] seafile-controller.c(453): pid file /opt/seafile/pids/seafevents.pid does not exist
[06/18/19 17:46:42] seafile-controller.c(486): seafevents need restart...
[06/18/19 17:46:42] seafile-controller.c(79): spawn_process: /usr/bin/python2.7 -m seafevents.main --config-file /opt/seafile/conf/seafevents.conf --logfile /opt/seafile/logs/seafevents.log -P /opt/seafile/pids/seafevents.pid
[06/18/19 17:46:42] seafile-controller.c(94): spawned /usr/bin/python2.7, pid 3124
[06/18/19 17:46:52] seafile-controller.c(453): pid file /opt/seafile/pids/seafevents.pid does not exist
[06/18/19 17:46:52] seafile-controller.c(486): seafevents need restart...
[06/18/19 17:46:52] seafile-controller.c(79): spawn_process: /usr/bin/python2.7 -m seafevents.main --config-file /opt/seafile/conf/seafevents.conf --logfile /opt/seafile/logs/seafevents.log -P /opt/seafile/pids/seafevents.pid
[06/18/19 17:46:52] seafile-controller.c(94): spawned /usr/bin/python2.7, pid 3143
[06/18/19 17:47:02] seafile-controller.c(453): pid file /opt/seafile/pids/seafevents.pid does not exist
[06/18/19 17:47:02] seafile-controller.c(486): seafevents need restart...
[06/18/19 17:47:02] seafile-controller.c(79): spawn_process: /usr/bin/python2.7 -m seafevents.main --config-file /opt/seafile/conf/seafevents.conf --logfile /opt/seafile/logs/seafevents.log -P /opt/seafile/pids/seafevents.pid
[06/18/19 17:47:02] seafile-controller.c(94): spawned /usr/bin/python2.7, pid 3152
[06/18/19 17:47:12] seafile-controller.c(453): pid file /opt/seafile/pids/seafevents.pid does not exist
[06/18/19 17:47:12] seafile-controller.c(486): seafevents need restart...
[06/18/19 17:47:12] seafile-controller.c(79): spawn_process: /usr/bin/python2.7 -m seafevents.main --config-file /opt/seafile/conf/seafevents.conf --logfile /opt/seafile/logs/seafevents.log -P /opt/seafile/pids/seafevents.pid
[06/18/19 17:47:12] seafile-controller.c(94): spawned /usr/bin/python2.7, pid 3155
[06/18/19 17:47:22] seafile-controller.c(453): pid file /opt/seafile/pids/seafevents.pid does not exist
[06/18/19 17:47:22] seafile-controller.c(486): seafevents need restart...
[06/18/19 17:47:22] seafile-controller.c(79): spawn_process: /usr/bin/python2.7 -m seafevents.main --config-file /opt/seafile/conf/seafevents.conf --logfile /opt/seafile/logs/seafevents.log -P /opt/seafile/pids/seafevents.pid
[06/18/19 17:47:22] seafile-controller.c(94): spawned /usr/bin/python2.7, pid 3158
[06/18/19 17:47:32] seafile-controller.c(453): pid file /opt/seafile/pids/seafevents.pid does not exist
[06/18/19 17:47:32] seafile-controller.c(486): seafevents need restart...
[06/18/19 17:47:32] seafile-controller.c(79): spawn_process: /usr/bin/python2.7 -m seafevents.main --config-file /opt/seafile/conf/seafevents.conf --logfile /opt/seafile/logs/seafevents.log -P /opt/seafile/pids/seafevents.pid
[06/18/19 17:47:32] seafile-controller.c(94): spawned /usr/bin/python2.7, pid 3361
[06/18/19 17:47:42] seafile-controller.c(453): pid file /opt/seafile/pids/seafevents.pid does not exist
[06/18/19 17:47:42] seafile-controller.c(486): seafevents need restart...
[06/18/19 17:47:42] seafile-controller.c(79): spawn_process: /usr/bin/python2.7 -m seafevents.main --config-file /opt/seafile/conf/seafevents.conf --logfile /opt/seafile/logs/seafevents.log -P /opt/seafile/pids/seafevents.pid
[06/18/19 17:47:42] seafile-controller.c(94): spawned /usr/bin/python2.7, pid 3397
root@ubuntu:/opt/seafile/logs# cat seafdav.log 
[2019-06-18 17:46:23,304]:  Init seahub database...
[2019-06-18 17:46:23,305]:  Failed to init seahub db: No module named seahub_settings.
root@ubuntu:/opt/seafile/logs# cat seahub.log 
2019-06-18 17:46:26,490 [ERROR] root:68 <module> Failed to import seafevents package.
Traceback (most recent call last):
  File "/opt/seafile/seafile-server-7.0.2/seahub/seahub/utils/__init__.py", line 65, in <module>
    from seafevents import seafevents_api
ImportError: No module named seafevents
2019-06-18 17:46:26,501 [ERROR] root:566 <module> Failed to import seafevents package.
Traceback (most recent call last):
  File "/opt/seafile/seafile-server-7.0.2/seahub/seahub/utils/__init__.py", line 562, in <module>
    import seafevents
ImportError: No module named seafevents
2019-06-18 17:48:48,186 [WARNING] django.request:152 get_response Not Found: /favicon.ico

其他几个日志文件看上去都是正常的。


#16

你使用上没啥问题吧,这几个报错都是专业版相关的程序,如果功能上没啥问题就不用关,把 seafevents.conf 删掉重启一下服务应该就不会报错了


#17

目前使用了2天,没发现什么问题。


#18

现在这种情况还能抢救一下吗?
既然7.0.2社区版正常未报错,补上对应的数据表是否能解决?


#19

已解决


#20

@daniel.pan
查看日志仍然有缺失的表。

root@ubuntu:/opt/seafile/logs# cat seafile.log 
[06/19/19 10:23:19] http-server.c(220): fileserver: worker_threads = 10
[06/19/19 10:23:19] http-server.c(233): fileserver: backlog = 32
[06/19/19 10:23:19] http-server.c(248): fileserver: fixed_block_size = 8388608
[06/19/19 10:23:19] http-server.c(263): fileserver: web_token_expire_time = 3600
[06/19/19 10:23:19] http-server.c(278): fileserver: max_indexing_threads = 1
[06/19/19 10:23:19] http-server.c(293): fileserver: max_index_processing_threads= 3
[06/19/19 10:23:19] http-server.c(315): fileserver: cluster_shared_temp_file_mode = 600
[06/19/2019 10:23:19 AM] http-server.c(393): fileserver: enable_async_indexing = 1
[06/19/2019 10:23:19 AM] http-server.c(405): fileserver: async_indexing_threshold = 700
[06/19/2019 10:23:19 AM] http-server.c(418): fileserver: fs_id_list_request_timeout = -1
[06/19/2019 10:23:19 AM] ../common/mq-mgr.c(61): [mq client] mq cilent is started
[06/19/2019 10:23:19 AM] filelock-mgr.c(973): Cleaning expired file locks.
[06/19/19 10:31:15] http-server.c(220): fileserver: worker_threads = 10
[06/19/19 10:31:15] http-server.c(233): fileserver: backlog = 32
[06/19/19 10:31:15] http-server.c(248): fileserver: fixed_block_size = 8388608
[06/19/19 10:31:15] http-server.c(263): fileserver: web_token_expire_time = 3600
[06/19/19 10:31:15] http-server.c(278): fileserver: max_indexing_threads = 1
[06/19/19 10:31:15] http-server.c(293): fileserver: max_index_processing_threads= 3
[06/19/19 10:31:15] http-server.c(315): fileserver: cluster_shared_temp_file_mode = 600
[06/19/2019 10:31:15 AM] http-server.c(393): fileserver: enable_async_indexing = 1
[06/19/2019 10:31:15 AM] http-server.c(405): fileserver: async_indexing_threshold = 700
[06/19/2019 10:31:15 AM] http-server.c(418): fileserver: fs_id_list_request_timeout = -1
[06/19/2019 10:31:15 AM] ../common/mq-mgr.c(61): [mq client] mq cilent is started
[06/19/2019 10:31:15 AM] filelock-mgr.c(973): Cleaning expired file locks.
[06/19/2019 10:31:52 AM] ../common/seaf-db.c(460): Error prepare statement SELECT org_id FROM OrgRepo WHERE repo_id = ?: mysql_stmt_prepare failed: Table 'seafile_db.OrgRepo' doesn't exist.
[06/19/2019 10:31:58 AM] ../common/seaf-db.c(460): Error prepare statement SELECT org_id FROM OrgRepo WHERE repo_id = ?: mysql_stmt_prepare failed: Table 'seafile_db.OrgRepo' doesn't exist.
[06/19/2019 10:32:14 AM] ../common/seaf-db.c(460): Error prepare statement SELECT org_id FROM OrgRepo WHERE repo_id = ?: mysql_stmt_prepare failed: Table 'seafile_db.OrgRepo' doesn't exist.
[06/19/2019 10:33:02 AM] ../common/seaf-db.c(460): Error prepare statement SELECT r.repo_id, p.timestamp FROM Repo r LEFT JOIN FolderPermTimestamp p ON r.repo_id=p.repo_id WHERE r.repo_id IN ('7816e488-e5ec-4a08-826c-8e8b26fd2ad8', '22363595-787f-48be-8a62-8d6694953c72'): mysql_stmt_prepare failed: Table 'seafile_db.FolderPermTimestamp' doesn't exist.
[06/19/2019 10:33:02 AM] http-server.c(3259): Failed to get folder perm timestamp.
[06/19/2019 10:33:02 AM] http-server.c(3349): Failed to find origin repo perm ts. Returning empty array. Request content is: [{"repo_id":"22363595-787f-48be-8a62-8d6694953c72","token":"640cdbd969ce2c481196d18a68424da6e8a143de","ts":0},{"repo_id":"7816e488-e5ec-4a08-826c-8e8b26fd2ad8","token":"43c35825ccc633b930780a5c9549ec611fb520c2","ts":0}]
[06/19/2019 10:33:02 AM] ../common/seaf-db.c(460): Error prepare statement SELECT r.repo_id, l.update_time FROM Repo r LEFT JOIN FileLockTimestamp l ON r.repo_id=l.repo_id WHERE r.repo_id IN ('7816e488-e5ec-4a08-826c-8e8b26fd2ad8', '22363595-787f-48be-8a62-8d6694953c72'): mysql_stmt_prepare failed: Table 'seafile_db.FileLockTimestamp' doesn't exist.
[06/19/2019 10:33:02 AM] http-server.c(3513): Failed to get file lock timestamp.
[06/19/2019 10:33:02 AM] http-server.c(3601): Failed to find origin repo lock ts. Returing empty array. Request content is: [{"repo_id":"22363595-787f-48be-8a62-8d6694953c72","token":"640cdbd969ce2c481196d18a68424da6e8a143de","ts":0},{"repo_id":"7816e488-e5ec-4a08-826c-8e8b26fd2ad8","token":"43c35825ccc633b930780a5c9549ec611fb520c2","ts":0}]
[06/19/2019 10:33:19 AM] ../common/seaf-db.c(460): Error prepare statement SELECT r.repo_id, p.timestamp FROM Repo r LEFT JOIN FolderPermTimestamp p ON r.repo_id=p.repo_id WHERE r.repo_id IN ('7816e488-e5ec-4a08-826c-8e8b26fd2ad8', '22363595-787f-48be-8a62-8d6694953c72'): mysql_stmt_prepare failed: Table 'seafile_db.FolderPermTimestamp' doesn't exist.
[06/19/2019 10:33:19 AM] http-server.c(3259): Failed to get folder perm timestamp.
[06/19/2019 10:33:19 AM] http-server.c(3349): Failed to find origin repo perm ts. Returning empty array. Request content is: [{"repo_id":"22363595-787f-48be-8a62-8d6694953c72","token":"640cdbd969ce2c481196d18a68424da6e8a143de","ts":0},{"repo_id":"7816e488-e5ec-4a08-826c-8e8b26fd2ad8","token":"43c35825ccc633b930780a5c9549ec611fb520c2","ts":0}]
[06/19/2019 10:33:19 AM] ../common/seaf-db.c(460): Error prepare statement SELECT r.repo_id, l.update_time FROM Repo r LEFT JOIN FileLockTimestamp l ON r.repo_id=l.repo_id WHERE r.repo_id IN ('7816e488-e5ec-4a08-826c-8e8b26fd2ad8', '22363595-787f-48be-8a62-8d6694953c72'): mysql_stmt_prepare failed: Table 'seafile_db.FileLockTimestamp' doesn't exist.
[06/19/2019 10:33:19 AM] http-server.c(3513): Failed to get file lock timestamp.
[06/19/2019 10:33:19 AM] http-server.c(3601): Failed to find origin repo lock ts. Returing empty array. Request content is: [{"repo_id":"22363595-787f-48be-8a62-8d6694953c72","token":"640cdbd969ce2c481196d18a68424da6e8a143de","ts":0},{"repo_id":"7816e488-e5ec-4a08-826c-8e8b26fd2ad8","token":"43c35825ccc633b930780a5c9549ec611fb520c2","ts":0}]
[06/19/2019 10:33:49 AM] ../common/seaf-db.c(460): Error prepare statement SELECT r.repo_id, l.update_time FROM Repo r LEFT JOIN FileLockTimestamp l ON r.repo_id=l.repo_id WHERE r.repo_id IN ('7816e488-e5ec-4a08-826c-8e8b26fd2ad8', '22363595-787f-48be-8a62-8d6694953c72'): mysql_stmt_prepare failed: Table 'seafile_db.FileLockTimestamp' doesn't exist.
[06/19/2019 10:33:49 AM] http-server.c(3513): Failed to get file lock timestamp.
[06/19/2019 10:33:49 AM] http-server.c(3601): Failed to find origin repo lock ts. Returing empty array. Request content is: [{"repo_id":"22363595-787f-48be-8a62-8d6694953c72","token":"640cdbd969ce2c481196d18a68424da6e8a143de","ts":0},{"repo_id":"7816e488-e5ec-4a08-826c-8e8b26fd2ad8","token":"43c35825ccc633b930780a5c9549ec611fb520c2","ts":0}]
[06/19/2019 10:33:49 AM] ../common/seaf-db.c(460): Error prepare statement SELECT r.repo_id, p.timestamp FROM Repo r LEFT JOIN FolderPermTimestamp p ON r.repo_id=p.repo_id WHERE r.repo_id IN ('7816e488-e5ec-4a08-826c-8e8b26fd2ad8', '22363595-787f-48be-8a62-8d6694953c72'): mysql_stmt_prepare failed: Table 'seafile_db.FolderPermTimestamp' doesn't exist.
[06/19/2019 10:33:49 AM] http-server.c(3259): Failed to get folder perm timestamp.
[06/19/2019 10:33:49 AM] http-server.c(3349): Failed to find origin repo perm ts. Returning empty array. Request content is: [{"repo_id":"22363595-787f-48be-8a62-8d6694953c72","token":"640cdbd969ce2c481196d18a68424da6e8a143de","ts":0},{"repo_id":"7816e488-e5ec-4a08-826c-8e8b26fd2ad8","token":"43c35825ccc633b930780a5c9549ec611fb520c2","ts":0}]

另外 controller.log 中出现很多下面的错误,而且不断增长中。

[06/19/19 10:39:56] seafile-controller.c(594): pid file /opt/seafile/pids/elasticsearch.pid does not exist
[06/19/19 10:39:56] seafile-controller.c(637): elasticsearch need restart...
[06/19/19 10:39:56] seafile-controller.c(94): spawn_process: /opt/seafile/seafile-pro-server-7.0.3/pro/elasticsearch/bin/elasticsearch -Epath.logs=/opt/seafile/logs -Epath.data=/opt/seafile/pro-data/search/data -Enetwork.host=127.0.0.1 -p /opt/seafile/pids/elasticsearch.pid
[06/19/19 10:39:56] seafile-controller.c(109): spawned /opt/seafile/seafile-pro-server-7.0.3/pro/elasticsearch/bin/elasticsearch, pid 31551

再次查看cat elasticsearch.log 发现

Caused by: java.lang.RuntimeException: can not run elasticsearch as root
	at org.elasticsearch.bootstrap.Bootstrap.initializeNatives(Bootstrap.java:106) ~[elasticsearch-5.6.13.jar:5.6.13]
	at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:195) ~[elasticsearch-5.6.13.jar:5.6.13]
	at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:342) ~[elasticsearch-5.6.13.jar:5.6.13]
	at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:132) ~[elasticsearch-5.6.13.jar:5.6.13]
	... 6 more

难道不能用 root ?