Romance, Historical, Contemporary, Paranormal, Young Adult, Book reviews, industry news, and commentary from a reader's point of view

Making a Catalog based Calibre Library Available for Stanza

If you are a reader with over a couple hundred books in Calibre, it is fairly difficult to navigate, particularly if you are using Stanza. To make Calibre’s library more accessible via the internet (and thus via Stanza), a wonderful programmer shared this script on MobileRead. Essentially, the script looks at the database of Calibre and creates catalogs based on the database. The first screen includes the choice to browse your library by Recent Additions, Author, Series, Title, or Category.

Picture

From there, your authors, titles, series are divided by letter or by category (which is based on your tags).

IMG_0450

Essentially Calibre2Web creates your own little webstore or catalog that you can access anywhere and at anytime. The problem is that this isn’t easy to set up but it can be done. I’m going to try to explain it step by step.

Port Forwarding.

Already I can see some of you freeze up. Port forwarding, you cry, what the hell is that? Most people who have internet have modems or routers. These devices block outgoing and incoming traffic to protect your computer and home network from viruses. By engaging port forwarding, you allow outside traffic to connect to your home computer. It’s kind of like one of those computerized doggy doors that allow dogs with only a certain connected collar to use it.

Your traffic is the dog, moving in and out of the door. Port forwarding tells the door that your dog is okay to move in and out.

Everyone’s router or modem is different, but www.portforward.com has a screenshot explanation of how to forward a port on nearly every router/modem. You can choose any 4 digit number. I think the default for Calibre is 8000.   REMEMBER THIS NUMBER.   It will become important later on.

Webserver

HFS is a program that allows your computer to act as a web server. Essentially that means that the data on your computer can be offered up for access to the world wide web. This is an executable file. It does not need to be installed. You simply download and then doubleclick it to run. This program must be running at all times that you want access to your Calibre data.  Drag the CalibreBooks folder onto HFS. When it asks whether you want a real folder or virtual, pick Real.

ScreenShot013

Getting Your Computer Ready to Run the Script

This is the hardest part of the installation.   The Calibre2Web is a SQL script, or a special computer language script.   It tells the computer to do certain things but in order for the computer to run the script, you have to have a special piece of software called a “sqlite3 ODBC driver”.   The developer of Calibre2Web suggests that you download this one.    I downloaded the sqliteodbc.exe file.

Once the file is downloaded, you double click to  install the program.   Simply click on all the defaults.

Next, you will add an “ODBC connection”.   If you are running Windows Vista, you need to be an administrator to do this.   Go to “Control Panel->Administrative Tools->Data Sources (ODBC)” (Click to see a bigger screenshot)

ScreenShot001

Click on the System DSN tab (it’s the second tab).   Click on the Add button and scroll to the bottom to see “SQLite3 ODB Driver”. Press Finish.   Another dialog box will appear. Add the following information

  • Data Source Name = CALIBRE
  • Database Name = Your Calibre Path\metadata.db   (mine is C:\Documents and Settings\Jane\My Documents\My Dropbox\CalibreBooks\metadata.db)

Press OK and then Press OK again to close out of the Data Sources (ODBC).

Take a break and come back.

Calibre2Web Script

Download the Calibre2Web Script if you haven’t already.   Copy the contents into the CalibreBooks folder (same place that your metadata.db file is.   Double click on the calibre2web.bat file.

ScreenShot008

It will open a command window and   look like this.

ScreenShot010

You should be able to go to your CalibreBooks folder and see a folder called “_CATALOG”.   In it should be a number of xml files.

Stanza

Now you are ready to add your catalog address to the Stanza application.

  • Tap Online Catalog
  • Tap + sign
  • In the URL add in the url from the HFS program + /_CATALOGS/catalog.xml. I.e., mine is http://192.xxx.xxx:PORT/_CATALOGS/catalog.xml. [Port being the 4 digit number you picked in the “port forwarding” step.

IMG_0448IMG_0449

This only allows you to access Stanza from within your network.   To take it one step more and be able to access this catalog from the road, you’ll need to sign up for a DNS redirect service.   I use no-ip.com because it is free.

DNS Redirect Service

Most internet service providers assign temporary IP addresses to your modem.   In order for your access to remain the same all the time, here are service providers that will redirect whatever the temporary IP address is to a domain name.   I use no-ip.com.   You must sign up for a domain name and then download a “Dynamic DNS Update Client.”   Your domain name could be mybooks.redirectme.net or something like that.

Like HFS, this program must run at all times that you want access to your files. If you have a computer at home that is always on and connected to the internet, this is the one you should use.   I have a old computer box that I store just a few things on for this purpose alone.

Once you have your domain name and update client running, go back to HFS.   Click on the “You are in Easy Mode” button so that it changes to “You are in expert mode.”

Go to Menu and choose “dynamic dns updater”.   No-IP.com is a selection. It will ask you for your No-IP.com username and password and domain name (such as mybooks.redirectme.net).   The address next to “Open in Browser” should change to “mybooks.redirectme.net/CalibreBooks/” or whatever your domain name is.   Remember this.

ScreenShot014

Go to your Stanza application:

  • Tap Online Catalog
  • You can either add a new catalog (I have both “home” and “away”) or change your existing personal catalog.
  • Tap + sign if you want to add new.
  • Tap “Edit” if you want to change existing personal catalog.
  • Enter in the URL: http://mybooks.redirectme.net:PORT/CalibreBooks/_CATALOGS/catalog.xml.

Every time you change the content in Calibre, you will have to re-run “Calibre2Web.bat”.   This will generate an updated catalog of files.   Remember, HFS and the Dynamic DNS Updater have to be running at all times.

Whew.   If you made it this far, congratulations. You now have an online catalog of all your ebooks which you can now access anywhere, anytime.   If you have questions or want other screenshots, let me know.

****

Troubleshooting:

1) Your script cannot be found: You might have a corrupt driver. Reinstall the sql lite program and redownload the calibre2web files.

2) You get a catalog error.   This can mean either your internet connection is down or because the xml file is cutting off   due to the characters in the title, author, series, category that it doesn’t recognize.   Go through your Calibre files to look for odd punctuation such as curlyquote marks instead of straight quote marks.

Jane Litte is the founder of Dear Author, a lawyer, and a lover of pencil skirts. She spends her downtime reading romances and writing about them. Her TBR pile is much larger than the one shown in the picture and not as pretty. You can reach Jane by email at jane @ dearauthor dot com

7 Comments

  1. Love Stanza? Hate primitive desktop app? Calibre2Web lets you use your Calibre desktop library via the Web | TeleRead: Bring the E-Books Home
    Aug 16, 2009 @ 06:13:53

    [...] other details: Download for ZIP is here. Also see DearAuthor. Digg us! Slashdot us! Share the [...]

  2. Statch
    Aug 16, 2009 @ 06:29:17

    Jane, this is a wonderful post. I’m going to store it away and try it sometime. It does make me think, though, how complicated ebook reading is if you don’t want DRM.

    I was browsing on Mobileread the other day and I read a post where someone seriously insisted that the average person can figure out how to strip DRM. I’m not a computer geek but I’ve played with them for a long time, and done some easy programming, and it still took me forever to figure out how to do it the first time. (Darn Python.) It was a little easier with the second format I tried, but even once I got it all set up, it still requires a lot more time than the average person is going to want to spend.

    And yet if I don’t do it, I lose my books when I switch devices. I recently switched from a Dell Axim to the iPod Touch. I had been using Mobipocket, so would have lost access to all those books if I hadn’t already stripped them, so that I could just use Calibre to format-switch them into ePub. It took me a while to get the Touch working with Calibre, though, and even now the darn IP address keeps changing on me – an easy fix, but not something the average person would have been looking for as the problem.

    This was a long way of saying that ebooks are going to remain a niche market until the publishers decide they actually want to make it work for the ‘real’ average person, not the imaginary average person who exists in a programmer’s mind. The ‘real’ average person is going to give up on ebooks the first time they switch devices and lose access to their books, IMHO.

    ReplyReply

  3. Sandy (Strlady)
    Aug 16, 2009 @ 09:40:28

    Love this! I just got an iTouch and was thinking about putting a book on it (I have a Sony Reader so haven’t been to much in a hurry) but this little program seems to be a keeper! Thanks for sharing the info.

    ReplyReply

  4. Teddypig
    Aug 16, 2009 @ 10:57:57

    Why not just use Googledocs with it’s tags and folder system and which is password protected and save yourself all that work? I use Googledocs with my iPhone all the time as a way to file and keep my eBooks handy.

    ReplyReply

  5. Create Your Own Cloud of Ebooks with Calibre + Calibre OPDS + Dropbox | Dear Author: Romance Novel Reviews, Industry News, and Commentary
    Feb 14, 2010 @ 04:01:52

    [...] by David Pierron. It runs without adding new software to your computer or changing drivers or anything crazy like that. This is the site for Calibre OPDS and this is the direct download [...]

  6. create you own cloud with calibre + calibre opds + dropbox « Morgen Free's Blog
    Mar 15, 2011 @ 16:16:06

    [...] by David Pierron. It runs without adding new software to your computer or changing drivers or anything crazy like that. This is the site for Calibre OPDS and this is the direct download [...]

  7. Getting eBooks from Calibre to Your Device Using Send to Device and the Connect/Share Functions. | Dear Author
    Jan 22, 2012 @ 11:57:49

    [...] This only works if a) you have calibre running and b) you can connect to your wifi network.  See this post for information about port forwarding and DNS redirect services which allows you to access Calibre from the [...]

Leave a Reply

Notify me of followup comments via e-mail. You can also subscribe without commenting.

%d bloggers like this: