Seafile upgrade: Failed to upgrade database, duplicate column name

Hey,

I have some trouble upgrading to seafile 7.0.4 on my Raspi. I run 6.3 at the moment. Upgrade has worked this afternoon but I didn’t see the info about certifi and seahub would not start, so flashed a backed up version to get it running again. Now after reading a bit more I wanted to try again with certifi installed but now I cannot get the upgrade to run.
I am a little experienced user, but have read and followed the information in Seafile Server 7.0.3 for Raspberry Pi is ready! 17.07.2019 and on the release site as far as I know. Does anybody have an idea what could be the problem?
Thanks :slight_smile:

seafile@raspberrypi:~ $ seafile-server-7.0.4/upgrade/upgrade_6.3_7.0.sh

This script would upgrade your seafile server from 6.3 to 7.0
Press [ENTER] to contiune

Updating seafile/seahub database …

[INFO] You are using SQLite3
[INFO] updating seafile database…
Traceback (most recent call last):
File “/home/seafile/seafile-server-7.0.4/upgrade/db_update_helper.py”, line 384, in
main()
File “/home/seafile/seafile-server-7.0.4/upgrade/db_update_helper.py”, line 379, in main
db_updater.update_db()
File “/home/seafile/seafile-server-7.0.4/upgrade/db_update_helper.py”, line 275, in update_db
super(SQLiteDBUpdater, self).update_db()
File “/home/seafile/seafile-server-7.0.4/upgrade/db_update_helper.py”, line 125, in update_db
self.update_seafile_sql(seafile_sql)
File “/home/seafile/seafile-server-7.0.4/upgrade/db_update_helper.py”, line 296, in update_seafile_sql
self.apply_sqls(self.seafile_db, sql_path)
File “/home/seafile/seafile-server-7.0.4/upgrade/db_update_helper.py”, line 289, in apply_sqls
conn.execute(line)
sqlite3.OperationalError: duplicate column name: status

Failed to upgrade your database

Hello,
same problem here with Mariadb.
Any hints to solve the Problem?
Thank You,
Ralf

These are normal, since you did run the (database) upgrade script earlier. Therefore you get such “duplicated” errors.
@Ralf0815 probably the same. Check it.

1 Like

Now, you should run the minor upgrade script, to migrate avatars and create the symlink to seafile-server-latest

1 Like

Thanks a lot - it works like a charm!

Hello

I had the same problem:

and I did the same solution.

It seem to work, but there are still a bit problems:

The language in the web interface is not in french (althought it was in french in version 6.3), and some icons are not shown: (EO36) instead of the column icon, and EO36 instead of the Trash icon.

Does anybody have an idea what could be the problem?
Thanks !

Hi
I have the same problem. I returned to a backup of the server, but not of the seafile.db file. Now, I cannot run the upgrade_6.3_7.0.sh properly and get the error sqlite3.OperationalError: duplicate column name: status.
After minor-upgrade.sh, version 7.0.5 runs but with errors in seahub.log and in the browser.
Is there a way to repair the sqlite3 db or to manipulate it to get the upgrade running?