-
Notifications
You must be signed in to change notification settings - Fork 295
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
"File bookmarks_all_xxx.html has an unknown file format. Nothing was imported" #969
Comments
Hi @TheNomad11 ! What are the respective Shaarli versions and HTTP server configurations? Also, are the HTTP server and PHP properly configured to allow uploading files >= 1 MiB? |
Hi @virtualtam I think I have the same problem. My original file is 1072 KB, exported from Diigo. When importing I got the same message After trimming the file (while trying to figure if this is the problem with syntax or specific characters) I've found that the problem is really in file size. File trimmed to My server configuration:
Some of my PHP settings:
I'm not administrator of this server but I can ask for changes if that is the problem. |
Hi @izumitelj ! What is the value for the PHP |
@virtualtam here it is:
and here are other settings |
@virtualtam It seems like this has to do with PHP version. The issue is present with PHP 5.6, while with PHP 7 it works as expected without errors. Unfortunately I can't switch to PHP 7 yet :(. Can someone look into this issue, probably Thanks |
OK, just to sum things up, could you provide us with the following information so we can try to reproduce the issue?
Note: PHP provides different configuration files (one per environment: apache2, cli, fpm, etc.), be sure to check values from the one used by the actual HTTP server (Apache2 / Nginx+FPM, etc.) Example on a dedicated server running Debian 8 Jessie, using Apache 2.4 and PHP 5.6: $ uname -a
Linux myserver 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt11-1+deb8u5 (2015-10-09) x86_64 GNU/Linux
$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 8.2 (jessie)
Release: 8.2
Codename: jessie
$ dpkg -l apache2 | grep ^i
ii apache2 2.4.10-10+deb8u10 amd64 Apache HTTP Server
$ dpkg -l php5 | grep ^i
ii php5 5.6.30+dfsg-0+deb8u1 all server-side, HTML-embedded scripting language (metapackage)
$ grep post_max /etc/php5/apache2/php.ini
post_max_size = 501M
$ grep upload_max /etc/php5/apache2/php.ini
upload_max_filesize = 500M In the meantime, I'll write a tool to generate dummy bookmark files of configurable size, to run tests against different environments. |
It uses the Faker library to generate fake yet coherent bookmark entries that can then be used to: - test Shaarli bookmark imports - test NetscapeBookmarkParser - diagnose performance issues See: - https://faker.readthedocs.io/en/latest/ - shaarli/Shaarli#902 - shaarli/Shaarli#969 - https://github.com/shaarli/netscape-bookmark-parser Signed-off-by: VirtualTam <virtualtam@flibidi.net>
Hmm... maybe I've made wrong assumption about incompatible PHP version. System admins said that they have checked all relevant variables and even tried switching Mod Security off. According to them the only thing that fixed the problem was switching to PHP 7 (which I couldn't do because of the other services). In the mean time they gave me chance to migrate to newer server that supports multiple PHP versions per subdomain. Now I've tested it and it works OK on both versions PHP Old server:
New server:
|
With release |
I exported my bookmarks from shaarli (newest version) and tried to import it in another shaarli instance. Then I got this error message
"File bookmarks_all_20170917_231302.html (1139620 bytes) has an unknown file format. Nothing was imported".
The file is 1,1 MB big.
I then made the file smaller, including only one entry. Then the import worked fine.
Are there issues with larger files? Why do I get an error message about the file format being invalid?
The text was updated successfully, but these errors were encountered: