x
This website is using cookies. We use cookies to ensure that we give you the best experience on our website. More info. That's Fine
HPC:Factor Logo 
 
Latest Forum Activity

Where are CE databases actually saved?

I dunk for bananas Page Icon Posted 2023-05-20 11:20 PM
#
Avatar image of I dunk for bananas
H/PC Elite

Posts:
704
Location:
Europe
Status:
Maybe a silly question, but where does CE actually save its databases? Is it in the registry? Or somewhere on the filesystem? I'd love to find a way to move them to a persistent location so they don't vanish every time my device loses power
 Top of the page
torch Page Icon Posted 2023-05-21 2:30 AM
#
Avatar image of torch
Subscribers
H/PC Guru

Posts:
5,755
Location:
United States 
Status:
I don’t have a direct answer but for example in the SCL there’s some backup programs - more specifically BSQUARE Backup which lets you backup databases.
I’m sure there’s other ones in the SCL too. Because I think bsqauee is only mips / arm (if I recall correctly, don’t quote me)
 Top of the page
I dunk for bananas Page Icon Posted 2023-05-22 5:32 PM
#
Avatar image of I dunk for bananas
H/PC Elite

Posts:
704
Location:
Europe
Status:
@C:Amie do you perhaps have a clue?
 Top of the page
CE Geek Page Icon Posted 2023-05-23 12:24 AM
#
Avatar image of CE Geek
Global Moderator
H/PC Oracle

Posts:
12,671
Location:
Southern California
Status:
I'd love to know how to access the object store in the file system for the same reason too. The problem with backing up databases is that, once restored, they are never recognized by ActiveSync as the same data, and because they are seen by ActiveSync as changed on the device, they will overwrite what's on Outlook on the host PC the next time you sync. Every database backup utility I've ever tried has produced the same effect. (And, torch, there are other programs that will back up databases on MIPS devices. I've cited one in my thread on the Casio BE-300 [DBBackup], and there are a few others, including Developer One's FlashBackDB, EZBackup, Syware's ViceTool, and PhatWare's HPC Database Explorer.)
 Top of the page
torch Page Icon Posted 2023-05-23 12:43 AM
#
Avatar image of torch
Subscribers
H/PC Guru

Posts:
5,755
Location:
United States 
Status:
CE Geek - 2023-05-22 5:24 PM


I'd love to know how to access the object store in the file system for the same reason too. The problem with backing up databases is that, once restored, they are never recognized by ActiveSync as the same data, and because they are seen by ActiveSync as changed on the device, they will overwrite what's on Outlook on the host PC the next time you sync. Every database backup utility I've ever tried has produced the same effect. (And, torch, there are other programs that will back up databases on MIPS devices. I've cited one in my thread on the Casio BE-300 [DBBackup], and there are a few others, including Developer One's FlashBackDB, EZBackup, Syware's ViceTool, and PhatWare's HPC Database Explorer.)

I'm not trying to hijack the thread, but I was just curious, do you also mean doing a full ActiveSync backup produces the same behavior as an On-Device utility?
 Top of the page
CE Geek Page Icon Posted 2023-05-23 12:48 AM
#
Avatar image of CE Geek
Global Moderator
H/PC Oracle

Posts:
12,671
Location:
Southern California
Status:
No, the ActiveSync backup doesn't produce this effect, ostensibly because it's done on the host PC rather than separately on the device.
 Top of the page
torch Page Icon Posted 2023-05-23 1:39 AM
#
Avatar image of torch
Subscribers
H/PC Guru

Posts:
5,755
Location:
United States 
Status:
Oh, then that's bad news for people without ActiveSync support on their respective devices.

Maybe it's just how CE works that certain things can't be "read" on the device proper, only using a host connection. (I'm just surmising here)
 Top of the page
CE Geek Page Icon Posted 2023-05-23 10:34 AM
#
Avatar image of CE Geek
Global Moderator
H/PC Oracle

Posts:
12,671
Location:
Southern California
Status:
Not necessarily, because then synching with a host PC isn't involved. In one sense it's better because you do all the changes on the device, and then just do a new backup that can be restored later if the databases get deleted by the device. I set up the restore (usually using a self-executing restore file backed up from bUSEFUL Backup Plus) in the startup queue in my CE 5 and CE 6 devices to restore them on each restart on devices that dump them on reboot (and not all of them do; I've found that my WM8505 netbooks/tablet retain the POOM databases even after shutdown and restart).
 Top of the page
C:Amie Page Icon Posted 2023-05-23 6:17 PM
#
Avatar image of C:Amie
Administrator
H/PC Oracle

Posts:
18,007
Location:
United Kingdom
Status:
You all have it backwards
Databases are not usually in the file system and the file system is not independent of the object store.

On most CE devices the object store is a series of RAM heaps. Databases are a partition type (volume) within the object store, which comprises its own pages of which system databases are one. The RAM file system is a partition in the object store (not the same for CF cards, apart from the mount points). The registry is a third type of object in the object store.

The reason backup tools bork ActiveSync is because the backup tool doesn't write to RAM, it does an API load of the database. The recovery tool performs SQL INSERT operations to drop the data back. Everything has different recovery and update time stamps and the ActiveSync Outlook sync driver in turn at this point has an empty database and no idea that the record was previously synched at all. So CE thinks that it is authoritative.
There isn't anything that you can do about this that I am aware of as the recovery and transaction models are handled internally by the object store driver/ActiveSync DLL and are transparent to the developer.

If you have a device where the system databases are retained after a full power down in primary and secondary power, then the system databases will be in the file system (which will be a FAT32 file system). Where that is is down to the OEM, however be aware that it could be RAM shadowed or it could be fully hidden and invisible to the operating system.

Feel free to go through the object store API though
https://learn.microsoft.com/en-us/previous-versions/windows/embedded/ms923167(v=msdn.10)
http://systemmanager.ru/windowsce21_documentationarchive.en/html/activesync.htm
 Top of the page
Jump to forum:
Seconds to generate: 0.179 - Cached queries : 67 - Executed queries : 8