Post Reply
laymonk
Posts: 5
Joined: Thu Sep 01, 2022 5:28 pm

SOS - n00b - Awasu Crashed - All my channels are gone

Post by laymonk » Thu Sep 01, 2022 5:33 pm

Hi,

I recently purchased Awasu, and for the past few days have fed it hundreds of channels.

It crashed just now, forcing a restart ... and while restarting, it prompted me to synchronize something (and did point out that I'd used the same folder previously). Well, not being aware yet what this feature does, I accepted to use the same folder.

Now all my channels are gone. This is like 5 days work, down the drain.

Is there any way I can get back my channels and avoid starting afresh ?

Thanks in advance for any suggestions

User avatar
support
Site Admin
Posts: 3073
Joined: Fri Feb 07, 2003 12:48 pm
Location: Melbourne, Australia
Contact:

Re: SOS - n00b - Awasu Crashed - All my channels are gone

Post by support » Fri Sep 02, 2022 12:28 am

The first thing to do is backup your data files.

In your email, you said you found the local data, but channels are configured in the roaming data directory e.g. %AppData%\Roaming\Awasu\. The channels are configured in the Channels\ sub-directory. Is there anything there?

laymonk
Posts: 5
Joined: Thu Sep 01, 2022 5:28 pm

Re: SOS - n00b - Awasu Crashed - All my channels are gone

Post by laymonk » Fri Sep 02, 2022 10:55 am

Thanks for responding ...

Expectedly, the channels config seems to have been overwritten when Awasu restarted after the crash ... so, the AwasuNews.channel is the only file there. I will have to read and understand the whole point of the synchronization, to avoid a recurrence

So, can the files in %AppData%\Local\Awasu\ be used to try and recreate the channels ?

User avatar
support
Site Admin
Posts: 3073
Joined: Fri Feb 07, 2003 12:48 pm
Location: Melbourne, Australia
Contact:

Re: SOS - n00b - Awasu Crashed - All my channels are gone

Post by support » Fri Sep 02, 2022 11:07 am

laymonk wrote:
Fri Sep 02, 2022 10:55 am
Expectedly, the channels config seems to have been overwritten when Awasu restarted after the crash ... so, the AwasuNews.channel is the only file there.
I suspect what's happened is that you synchronized with an empty sync file, so Awasu has dutifully updated its configuration to match that i.e. empty :-)

Send me your archive.db (and archive.db-shm and archive.db-wal if they're there), plus all the files in the Logs/ sub-directory, and I'll see what I can do...

laymonk
Posts: 5
Joined: Thu Sep 01, 2022 5:28 pm

Re: SOS - n00b - Awasu Crashed - All my channels are gone

Post by laymonk » Fri Sep 02, 2022 11:32 am

OK ... send it here in this forum or via email ?

Thanks a million ... much appreciated

laymonk
Posts: 5
Joined: Thu Sep 01, 2022 5:28 pm

Re: SOS - n00b - Awasu Crashed - All my channels are gone

Post by laymonk » Fri Sep 02, 2022 11:37 am

Also, there are other archive db files

archive2.{db,db-wal,db-shim}
archive-offline.{db,db-wal,db-shim} - has the largest size, so I suspect this contains feeds downloaded for offline usage

Should I include any of these other archive files in what I send ?

User avatar
support
Site Admin
Posts: 3073
Joined: Fri Feb 07, 2003 12:48 pm
Location: Melbourne, Australia
Contact:

Re: SOS - n00b - Awasu Crashed - All my channels are gone

Post by support » Fri Sep 02, 2022 11:38 am

laymonk wrote:
Fri Sep 02, 2022 11:32 am
OK ... send it here in this forum or via email ?
Email them. Send config.ini as well, the other files aren't necessary.

User avatar
support
Site Admin
Posts: 3073
Joined: Fri Feb 07, 2003 12:48 pm
Location: Melbourne, Australia
Contact:

Re: SOS - n00b - Awasu Crashed - All my channels are gone

Post by support » Sun Sep 04, 2022 4:12 am

You asked in your email how I managed to recover your channels.

The XML files in the Logs/ directory are copies of the last feed received from each channel (this is what's shown when you choose Show last feed in the UI). Feeds often have a link back to themselves, so I wrote a script to iterate over these files and extract that link.

Code: Select all

#!/usr/bin/env python3

import sys
import os

import feedparser

print( "<opml version=\"1.0\">" )
print( "<body>" )
print()

dname = "laymonk/Logs"
for root, dnames, fnames in os.walk( dname ):
    for fname in fnames:
        if os.path.splitext( fname )[1] != ".xml":
            continue
        fname = os.path.join( root, fname )

        data = feedparser.parse( fname )
        links = data["feed"].get( "links", {} )
        urls = [ link for link in links if "xml" in link["type"] ]
        if urls:
            assert len( urls[0] ) == 1
            url = urls[0].get( "href" )
            print( "<outline xmlUrl=\"{}\" />".format( url ) )
        else:
            print( "===", fname, "===", file=sys.stderr )
            for link in links:
                print( link, file=sys.stderr )
            print( file=sys.stderr )

print()
print( "</body>" )
print( "</opml>" )
For those feeds that don't have such a link, they often have links to their home page, which will give you an idea of where the channel came from, and let you manually re-create the channel.

laymonk
Posts: 5
Joined: Thu Sep 01, 2022 5:28 pm

Re: SOS - n00b - Awasu Crashed - All my channels are gone

Post by laymonk » Mon Sep 05, 2022 12:27 pm

WOW ... most useful insight ... thanks a million

You saved me many hours of manual effort ... much appreciated

Post Reply

Return to “Awasu - General Discussion”