Error: Not a writeable directory

Post Reply
LifeIsLong
Posts: 89
Joined: 09 Oct 08 2:22

Error: Not a writeable directory

Post by LifeIsLong » 20 Apr 17 2:12

So recently I started getting the following error on startup (before any splash screen or main window):

Information
-----------
Unable to connect to the database.

The database reports:
SQLITE_ERROR - not a writable directory

[OK]

If I click ok I get a dialog saying "cannot connect to the database," but if I click ok and then login with the same (default) database as was just attempted, everything looks and works fine. The database checks and vacuums with no errors or problems.

The only problem I have is that if I import pictures or change any picture, I suddenly have over 1000 out-of-sync pictures... most of them are not the ones I just imported or changed. I can save the metadata to the files and the count goes back down to 0, but when I make another change, they show up again as out-of-sync.

Any ideas?

Hert
Posts: 20291
Joined: 13 Sep 03 7:24

Re: Error: Not a writeable directory

Post by Hert » 20 Apr 17 7:23

Sounds like your temp folder is not writable (or full?). PSU configures SQLite to let SQLite use the temp folder of the OS. Perhaps you recently made changes to the computer? OS update...or security changes...or file system reconfiguration....or even a new hard drive?
This is a User-to-User forum which means that users post questions here for other users.
Feature requests, change suggestions, or bugs can be logged in the ticketing system

LifeIsLong
Posts: 89
Joined: 09 Oct 08 2:22

Re: Error: Not a writeable directory

Post by LifeIsLong » 20 Apr 17 10:53

Interesting. I checked my environment variables and C:\Windows\Temp is my temp folder. My C drive has 16GB free, and the temp folder does not have read only access set (and I deleted several files from it). I have not upgraded my harddisk recently...

Thinking back, I believe this started around the time I restored a catalog backup file, if that could help pinpoint something.

Is there any way to see what folder sqlite is trying to use as temp?

LifeIsLong
Posts: 89
Joined: 09 Oct 08 2:22

Re: Error: Not a writeable directory

Post by LifeIsLong » 21 Apr 17 13:00

Does PSU use the archive file attribute to help determine if a file has been changed?

Hert
Posts: 20291
Joined: 13 Sep 03 7:24

Re: Error: Not a writeable directory

Post by Hert » 21 Apr 17 17:03

No it doesn't.
This is a User-to-User forum which means that users post questions here for other users.
Feature requests, change suggestions, or bugs can be logged in the ticketing system

LifeIsLong
Posts: 89
Joined: 09 Oct 08 2:22

Re: Error: Not a writeable directory

Post by LifeIsLong » 11 May 17 1:43

I just noticed tonight that the directory I keep my databases in is marked with an "R", though none of the files (including the sqlite datbases) is marked with an R. I've tried making the directory non-read-only but have not succeeded (right-click properties). I even added read-only and then removed it: the files responded, but the directory still shows R.

Any further ideas?

LifeIsLong
Posts: 89
Joined: 09 Oct 08 2:22

Re: Error: Not a writeable directory

Post by LifeIsLong » 13 May 17 2:04

Is there any way I can determine exactly which path is not writable?

Hert
Posts: 20291
Joined: 13 Sep 03 7:24

Re: Error: Not a writeable directory

Post by Hert » 13 May 17 7:07

Here's a script that you can run to tell you what the temp folder is that PSU is using.
Note; This script can not be ran on the PSU Server version

Code: Select all

var
  ADs: TDBXOMClientDataset;
begin
  ADs := Catalog.NewDataset;
  ADs.CommandText := 'PRAGMA temp_store_directory';
  ADs.OpenSet;
  Say(ADs.FieldValue('temp_store_directory'));
  ADs.CloseSet;
  Catalog.FreeDataset(ADs);
end;
If that's the folder that is unwritable on your system is something that you can only guess. I would personally do a complete fresh drive format and Windows install when the file system is acting up.
This is a User-to-User forum which means that users post questions here for other users.
Feature requests, change suggestions, or bugs can be logged in the ticketing system

LifeIsLong
Posts: 89
Joined: 09 Oct 08 2:22

Re: Error: Not a writeable directory

Post by LifeIsLong » 13 May 17 12:56

I tried to run the script... got this error message (I am not using the server version):

Information
-----------
SCRIPT RUNTIME ERROR
Cannot open a non-select statement (0) when evaluating instruction CallProc ($0,$0,$E93480,$23BD69B0,'OpenSet').
Stack content is: [].
Source position: 6,14 (0)

[OK]

LifeIsLong
Posts: 89
Joined: 09 Oct 08 2:22

Re: Error: Not a writeable directory

Post by LifeIsLong » 07 Jul 17 14:30

I tried installing a clean copy of Win10 (creators edition). I still get this error message. Is there some path in my profile/settings that I could clear? I noticed that a new profile worked fine, but I dont want to lose my settings.

Post Reply