Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Related Tools

Notices

Reply
 
Thread Tools Search this Thread
Old 05-17-2013, 12:54 PM   #421
mariosipad
Groupie
mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'
 
Posts: 174
Karma: 10372
Join Date: Nov 2012
Device: iPad & iPhone with Marvin
Resizing of covers is the only performance issue on any computer, in my experience.

On my NAS, Synology DS-110j (128Mb main memory), I use the setting
Code:
 $config['cops_recentbooks_limit'] = '50';
on faster machines I use
Code:
 $config['cops_recentbooks_limit'] = '250';
or more. But that only applies to "Recent Items".

When you have a lot of books from one writer or if you have a lot of books with the title starting with the same letter it really can become an issue.

However in my experience if you use a server running Debian or any other flavour of Linux the reading app stays reasonably responsive even when the CPU of your NAS is at 100%.
mariosipad is offline   Reply With Quote
Old 05-18-2013, 04:25 PM   #422
vlad59
Addict
vlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five words
 
Posts: 340
Karma: 37761
Join Date: Sep 2011
Device: Kobo eReader Touch, Kobo Aura HD
Quote:
Originally Posted by electronicfur View Post
Runs fine on my low powered Dockstar NAS with only 128MB of memory running Debian.
It's also running fine on mine Except that I use Archlinux.

Quote:
One thing that would be good is an option to not display book images in lists, or cache the images somehow after the resizing; resizing is the biggest performance issue on my small NAS.
I thought many times about that (https://github.com/seblucas/cops/issues/5). But caching the thumbnail mean having to write on the disk and for now COPS is a pure read only application. That simplify a lot (no extra check, no security holes, ...) and that mean an easy install for every average Joe user.

I had the same issue, I added a cache header (a simple workaround I agree) so that going on the same page after a few day don't burn your CPU again. I also thought about using Nginx caching system but lost interest.

I don't think I'll add that myself to COPS, but I'll happily review and merge any clean patch about it.

Quote:
Also I noticed that the Tags and Series pages dont respect the cops_max_item_per_page setting. With over 9000 tags this caused JFBReader to crash on my phone.
9000 tags .... WAHHH ... is Calibre still usable with that much tags ?

Anyway this issue has already been reported : https://github.com/seblucas/cops/issues/27

I'll do it but don't know when.

Quote:
But a great app, means I can stop running calibre2opds.
Thanks !
vlad59 is online now   Reply With Quote
 
Enthusiast
Old 05-20-2013, 06:18 AM   #423
mariosipad
Groupie
mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'
 
Posts: 174
Karma: 10372
Join Date: Nov 2012
Device: iPad & iPhone with Marvin
Quote:
Originally Posted by vlad59 View Post
I added a cache header (a simple workaround I agree) so that going on the same page after a few day don't burn your CPU again.
I tried to implement a cache header on my WAMP (Windows 7/Apache) server, but the results were not as consistent as I would expect them to be.

Did you use any specific settings for COPS?

I will try the cache header settings on my Debian COPS server later. Maybe the results are more consistent there. Or maybe I need to read up about this topic some more!
mariosipad is offline   Reply With Quote
Old 05-22-2013, 09:53 AM   #424
vlad59
Addict
vlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five words
 
Posts: 340
Karma: 37761
Join Date: Sep 2011
Device: Kobo eReader Touch, Kobo Aura HD
Quote:
Originally Posted by mariosipad View Post
I tried to implement a cache header on my WAMP (Windows 7/Apache) server, but the results were not as consistent as I would expect them to be.

Did you use any specific settings for COPS?

I will try the cache header settings on my Debian COPS server later. Maybe the results are more consistent there. Or maybe I need to read up about this topic some more!
In theory there nothing to add in Apache config if your library is outside your web directory. Thoses lines in fetch.php tell the browser to keep the images 14 days :

Code:
    $expires = 60*60*24*14;
    header("Pragma: public");
    header("Cache-Control: maxage=".$expires);
    header('Expires: ' . gmdate('D, d M Y H:i:s', time()+$expires) . ' GMT');
vlad59 is online now   Reply With Quote
Old 05-22-2013, 03:44 PM   #425
mariosipad
Groupie
mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'
 
Posts: 174
Karma: 10372
Join Date: Nov 2012
Device: iPad & iPhone with Marvin
Quote:
Originally Posted by vlad59 View Post
In theory there nothing to add in Apache config if your library is outside your web directory. Thoses lines in fetch.php tell the browser to keep the images 14 days :

Code:
    $expires = 60*60*24*14;
    header("Pragma: public");
    header("Cache-Control: maxage=".$expires);
    header('Expires: ' . gmdate('D, d M Y H:i:s', time()+$expires) . ' GMT');
For the intrepid people who are like me running Apache and want to try for themselves. I "removed" the code from fetch.php (this code cannot work in Apache afaik) and added the following to the .htaccess file: (do not forget to enable [headers_module] in apache)
Code:
## Cache
<ifModule mod_headers.c>
Header unset Pragma

# remove and disable ETag
Header unset ETag
FileETag None

# remove Last-Modified
Header unset Last-Modified
 
# cache images for 10 days
<FilesMatch "\.(jpg|ico|jpeg|png|gif)$">
  Header set Cache-Control "max-age=864000, public, must-revalidate"
</FilesMatch>
 
# cache epub/opf/pdf docs for 10 days
<FilesMatch "\.(epub|mobi|opf|pdf)$">
  Header set Cache-Control "max-age=864000, public, must-revalidate"
</FilesMatch>
 
# cache html/htm/xml/txt diles for 2 days
<FilesMatch "\.(html|htm|xml|txt|xsl)$">
  Header set Cache-Control "max-age=7200, must-revalidate"
</FilesMatch>

</ifModule>
However it did not really work for me as I have my data outside of my web directory .

I may have to rethink my storage strategy. More required.

Anyone with a brilliant idea to make this work?
mariosipad is offline   Reply With Quote
Old 05-23-2013, 11:06 AM   #426
lunatic_raver
Junior Member
lunatic_raver began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Jan 2013
Device: nexus 7
Hi!
Any news on the synology package? I've been looking on the Synocommunity's repo, but they still have the 0.3.4 version.
Just for clarification, I have a custom column (language). Is it supported on the new version?

Thanks for this really useful software!
lunatic_raver is offline   Reply With Quote
Old 05-23-2013, 04:45 PM   #427
vlad59
Addict
vlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five words
 
Posts: 340
Karma: 37761
Join Date: Sep 2011
Device: Kobo eReader Touch, Kobo Aura HD
Quote:
Originally Posted by lunatic_raver View Post
Hi!
Any news on the synology package? I've been looking on the Synocommunity's repo, but they still have the 0.3.4 version.
Just for clarification, I have a custom column (language). Is it supported on the new version?

Thanks for this really useful software!
I guess the synocommunity maintainers are busy :

https://github.com/SynoCommunity/spksrc/pulls

There's a lot of pull request waiting (and of course my own). I'll try to build a package myself this weekend.

Only some custom columns are supported for now (you can check it on the config_default.php)
vlad59 is online now   Reply With Quote
Old 05-24-2013, 04:38 PM   #428
vlad59
Addict
vlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five wordsvlad59 can name that ebook in five words
 
Posts: 340
Karma: 37761
Join Date: Sep 2011
Device: Kobo eReader Touch, Kobo Aura HD
Quote:
Originally Posted by mariosipad View Post
For the intrepid people who are like me running Apache and want to try for themselves. I "removed" the code from fetch.php (this code cannot work in Apache afaik) and added the following to the .htaccess file: (do not forget to enable [headers_module] in apache)
Can you explain why it can't work ? These headers are only interpreted by your browser so the webserver should not interfere with them.

Thanks.
vlad59 is online now   Reply With Quote
Old 05-24-2013, 07:26 PM   #429
mariosipad
Groupie
mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'
 
Posts: 174
Karma: 10372
Join Date: Nov 2012
Device: iPad & iPhone with Marvin
Quote:
Originally Posted by vlad59 View Post
Can you explain why it can't work ? These headers are only interpreted by your browser so the webserver should not interfere with them.
Good question! It made me rethink my statement that as far a I know "this code cannot work in Apache". I am certainly no Apache expert, but I try to search for solutions to problems and learn from them (the solutions and the problems).

It was my understanding that for the "header command" to work in Apache the module mod_headers.c should be loaded. Just like for x-sendfile and rewrite (now no longer needen for COPS to work perfectly). For these commands to work in Apache the corresponding modules (mod_xsendfile.c and mod_rewrite.c) should be loaded and active. In my version of Apache for Windows (WAMP) mod_headers.c was not enabled. Hence my statement that "this code cannot work in Apache". I omitted to add "unless you enable mod_headers.c.

Since then I found (about) the same code vlad59 used in fetch.php. There was no mention of the need to enable mod_headers.c. So I may be wrong in assuming the module needed to be loaded for it to work in Apache.

I just completed a little testing.
My browser Firefox (21.0) under OSX caches the covers. there is no significant CPU activity except the first time when covers are converted to thumbnails.
It does not seem to matter if mod_header.c is loaded or not.
Caching by firefox is what I expect to happen. To know if the headers code of COPS works I will have to test over time. I will keep an eye on it.

However I distinctly remember that when I tested on a slower Windows 7 PC with less memory I saw a lot (100%) of cpu activity every time I "revisited" a library after I used an other library. Mod_headers.c was not loaded then.
I do not see this behavior now with the faster PC and a new installation of WAMP and COPS.

@vlad59: can you follow my reasoning?

[A possible explanation is that the Apache installation of WAMP on my old PC has become "corrupted" as a result of a bit to much experimenting over time. One or two other things do not seem to work as I expect them to.]
mariosipad is offline   Reply With Quote
Old 05-25-2013, 04:48 AM   #430
maxjens
Connoisseur
maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.
 
maxjens's Avatar
 
Posts: 88
Karma: 490410
Join Date: Jul 2010
Device: iPad & Bebook Neo
@mariosipad

Are you now stating that the slower pc was the problem and that after installing everything on a faster pc without installing the module everything works fine?
maxjens is offline   Reply With Quote
Old 05-25-2013, 03:12 PM   #431
jlsturgeon
Member
jlsturgeon began at the beginning.
 
Posts: 10
Karma: 10
Join Date: May 2013
Device: Nexus 7 tablet
Hi, I'm having a bit of trouble getting this working on my Synology 411+ running DSM 4.0 and not sure what I've done wrong. I also tried skimming through this thread to see if I could find an answer on my own, but it's very long and a lot of it is too technical for me to follow. I do apologize in advance if this is a question already answered that I ought to have found. Any help would be appreciated!

I followed all the steps given on https://github.com/seblucas/cops/wiki/Howto---Synology
using the "if you want your Calibre directory inside your webroot" option as that seemed the simpler of the two. I also eventually remembered that I had to set up port forwarding for port 80 in my router configuration utility as I had not previously enabled WebStation and the EZ-Internet automatic configuration isn't supported on my router. My file structure within the "web" folder is single directory named "Calibre" containing two subdirectories named "cops-master" and "Data." The "Data" file contains all my folders with the books and the metadata file, and Calibre on my PC is now using it as its library with no problem.

I had a bit of difficulty figuring out how to edit the config_local.php file, per step 6, but finally downloaded it to my Windows desktop, edited it in notepad, saved it, and moved it back to the "cops-master" folder, overwriting the original. I also had a bit of difficulty following the instructions as to what the directory paths were and where in the config file they go; I don't know if this was partly because using Notepad, the file is very hard to read. I've never worked with php files before so I'm not really too familiar with the format. In any case, I changed both those values to './Calibre/Data/'.

As I said, I'm having no problem with Calibre itself using the library at that location. However, when I tried to add my library as a custom OPDS catalog in FBReader on my Nexus7 tablet, I tried it both as [hostname]/Calibre, using the hostname I have for Synology DDNS, and as [IPaddress]/Calibre, and either way FBReader returns a HTTP/1.1 403 Forbidden error. Before I remembered to set up port forwarding for port 80, I was just getting request for username and password but authentication would repeatedly fail. If I leave off the /Calibre part and just put in my hostname or IP address, FBReader says "This is not an OPDS catalog."

What did I goof up that would make FBReader unable to access my library?
jlsturgeon is offline   Reply With Quote
Old 05-26-2013, 06:52 AM   #432
maxjens
Connoisseur
maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.
 
maxjens's Avatar
 
Posts: 88
Karma: 490410
Join Date: Jul 2010
Device: iPad & Bebook Neo
Are all the cops files in the subdirectory cops-master or in the directory calibre? Seeing your ./Calibre/Data they should be in ./Calibre. Are they?
maxjens is offline   Reply With Quote
Old 05-26-2013, 12:25 PM   #433
jlsturgeon
Member
jlsturgeon began at the beginning.
 
Posts: 10
Karma: 10
Join Date: May 2013
Device: Nexus 7 tablet
All the COPS files were in the "cops-master" directory because when I unzipped the file as instructed, they were automatically unzipped into that directory. I moved all the files that were in ./Calibre/cops-master and put them in ./Calibre and I get now a different error when I try to add the library in FBReader. Now it says "HTTP/1.0 500 Internal Server Error." Is that progress? ;-)
jlsturgeon is offline   Reply With Quote
Old 05-26-2013, 01:21 PM   #434
maxjens
Connoisseur
maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.maxjens ought to be getting tired of karma fortunes by now.
 
maxjens's Avatar
 
Posts: 88
Karma: 490410
Join Date: Jul 2010
Device: iPad & Bebook Neo
Do you add the library <yourip>\Calibre\index.php or feed.php. I would first try using safari or internet explorer. Then you know it works.
maxjens is offline   Reply With Quote
Old 05-26-2013, 01:31 PM   #435
mariosipad
Groupie
mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'mariosipad knows the difference between 'who' and 'whom'
 
Posts: 174
Karma: 10372
Join Date: Nov 2012
Device: iPad & iPhone with Marvin
@jlsturgeon
What you can do:
0 - Update your Synology firmware to DSM 4.2 (maybe not necessary for COPS but it's good te be up-to-date).
1 - Organize your files on your synology in the following way:
a - put all your files you want to access with a browser on ereader in the directory "web" on your Synology Diskstation
b - put the COPS files in a directory "Calibre"
c - put all your calibre files inside a directory "data" inside the directory "calibre" in the "web" directory
d - edit the file config_local.php to contain the following line:
Code:
     $config['calibre_directory'] = "./data/";
e - then from a browser:
Code:
http://<IP_of_your_synology/calibre/checkconfig.php
f - if there are no errors Succes!!
g - if there are errors post them here
mariosipad is offline   Reply With Quote
Reply

Tags
calibre opds, kobo aura, synology

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP+Apache web server for calibre ... chaley Related Tools 254 04-28-2014 08:18 PM
[Old Thread] Android FBreader and Calibre OPDS server question kalex Calibre 4 12-15-2012 01:50 PM
External OPDS catalogue in Calibre bolton Calibre 1 09-05-2012 06:14 AM
Calibre OPDS server with windows apps? nickdma Related Tools 9 02-02-2011 03:09 PM
Calibre Command Line usage with PHP artoros Related Tools 13 07-01-2010 09:57 AM


All times are GMT -4. The time now is 02:21 PM.


MobileRead.com is a privately owned, operated and funded community.