cancel
Showing results for 
Search instead for 
Did you mean: 

Error "Cannot create resource tree" on start database

5,217

Recently we have moved in our product the database from SA10 version to SA12(12.0.1.3311 on Linux). Sometimes on high avilability deployment(using heartbeat package) on database start in error messages log(-oe option) appears message "Cannot create resource tree" and nothing(even not first line 'SQL Anywhere Network Server Version 12.0.1.3311') in regular output messages log file(-o option). WHat can be areason for this error message.

Thanks in advance, Hanan Brener

Accepted Solutions (1)

Accepted Solutions (1)

Former Member

To expand on Glenn's answer a little bit, SQL Anywhere needs to create some temporary files for the database temp file, shared memory communication (these are actually sockets and shared memory, but appear as files in the file system), and a few others. They are placed in a directory structure rooted at $SATMP, $ASTMP, $TMP, or /tmp (whichever is the first one that is set).

In order for SQL Anywhere to start up, it must be able to create this directory tree for its temporary files. This requires execute permission on all directories up to the parent of $SATMP. Additionally, it requires read/write/execute permission on $SATMP itself.

If the $SATMP directory already has the correct permissions, you may look for existing directories that might conflict with the directories that SQL Anywhere is trying to create. You may also want to check the system logs to see if anything stands out.

If all of that fails, I find that strace can be a powerful tool for determining the exact cause of file-system-related issues.

Breck_Carter
Participant
0 Kudos

It has to be some kind of record... Google yields only 4 hits on "Cannot create resource tree" and two of them point here 🙂

Answers (2)

Answers (2)

Former Member

The message indicates that the server is unable to write to the SQL Anywhere resource directory on your Linux machine - likely a file permissions problem.

Former Member
0 Kudos

Hy all.. Sorry for opening an old discusion but i need some help.. Please read this first: New thread

So.. I have some problems with TEMP dir I guess but I feel like a first-timer with linux when reading Sybase support papers. Anyhow, how do I check in which one does SqlAnywhere store TEMP files? "strance" says:

access("/tmp/.SQLAnywhere", W_OK)       = 0
umask(0)                                = 022
mkdir("/tmp/.SQLAnywhere", 0777)        = -1 EEXIST (File exists)
umask(022)                              = 0
open("/tmp/.SQLAnywhere/__SQLAnyCli__3881_3a561f00", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
umask(0)                                = 022
mkdir("/tmp/.SQLAnywhere", 0777)        = -1 EEXIST (File exists)
umask(022)                              = 0
umask(0)                                = 022
mkdir("/tmp/.SQLAnywhere/__SQLAnyCli__3881_3a561f00", 0777) = 0
mkdir("/tmp/.SQLAnywhere/__SQLAnyCli__3881_3a561f00/shmem", 0777) = 0
mkdir("/tmp/.SQLAnywhere/__SQLAnyCli__3881_3a561f00/fifos", 0777) = 0
mkdir("/tmp/.SQLAnywhere/__SQLAnyCli__3881_3a561f00/tmp", 0777) = 0

So.. I think default temp folder is /tmp.SQLAnywhere.. "ls -a -l" says:

drwxrwxrwt.  7 root root  4096 Apr 27 20:25 tmp
...
drwxrwxrwx.  7 apache apache   4096 Apr 27 20:25 .SQLAnywhere

So, what is the problem then? Again.. Everything works as it should in console with "php /var/www/html/dbtest.php", but if I run the script in browser I get an error:

Warning: sasql_connect(): SQLAnywhere: [-100] Database server not found in /var/www/html/dbtest.php
VolkerBarth
Contributor

No, I don't have an answer or a clue - I'd simply suggest to ask that as another new question (or add it to the one you have started if it seems related), such as "How to find out where SQL Anywhere expects its temporary files?" or whatever seems appropriate - I guess this will get more attraction from other readers...