Jump to content

Move data base files to a different location


Recommended Posts

I'm new to this. I'm trying to move the databases (repositories) from the default location to something like "C:\plastic".

I shut down the service.

I found some instructions, and created a db.conf file in the installation folder (C:\program files\plasticscm\server .

The file has:

<DbConfig>

<ProviderName>firebird</ProviderName>

<DatabasePath>c:\Plastic</DatabasePath>

</DbConfig>

in it.

I then moved the three files that were in the installation folder

repositories.plastic.fdb, rep_3.plastic.fdb, and rep_1.plastic.fdb

This is all on my computer (not a server).

I turned on the service. When I started the plasticscm program, I got the error message that it could not find the repository that I had created. It acted like there was something wrong with thedb.conf file. When I moved everything back to its original location, it all worked.

What am I doing wrong.

Thanks,

Neal

Link to comment
Share on other sites

Sorry,

I was wrong. It did not work. I installed the firebird software. I then created the db.conf file. I created a folder C:\plastic and copied the db files from c:\program files\plasticscm\server into the folder. The db.conf file is:

<DbConfig>

<ProviderName>firebird</ProviderName>

<ConnectionString>ServerType=0;User=SYSDBA; Password=masterkey;Database={0};Pooling=true; connection lifetime=60;Charset=UNICODE_FSS; </ConnectionString>

<DatabasePath>c:\plastic</DatabasePath>

</DbConfig>

The connectionstring is a single line.

I then rebooted the computer (restarting the service) and the plasticscm re-created the data base files in c:\program files\plasticscm\server.

It acts like it is not dealing with the db.conf file.

I should add that the workspace that I defind was still there when I rebooted the computer (I don't know where that is located).

Neal

Link to comment
Share on other sites

Are you using embedded Firebird (ServerType=1) or installed Firebird (ServerType=0), then?

I suppose that the db.conf file is placed in c:\program files\plasticscm\server, isn't it?

Best,

Luis

Link to comment
Share on other sites

Thanks for trying to help. I've tried things both ways:

Case One on an XP machine I used an inbeded firebird (I assume). I turned off the Plastic Server service. I created a folder c:\plastic and moved the two FDB files into it (repositories.plastic.fdb and rep_1.plastic.fdb) from c:\program files\plasticscm\server. I created a db.conf file with the following contents:

<DbConfig>

<ProviderName>firebird</ProviderName>

<DatabasePath>c:\Plastic</DatabasePath>

</DbConfig>

On the web I have seen reference to a workspace fdb but I did not find that in the server folder (or anywhere). This is for both cases.

I then turned the Plastic Server service back on. When I started up plastic.exe, the two fdb files above were re-created in the c:\program files\plasticscm\server folder.

Case Two was on a Win7 machine. I did the same thing except for the differences described below:

I installed firebird 2.1.4.18393

the db.conf file had the following contents:

<DbConfig>

<ProviderName>firebird</ProviderName>

<ConnectionString>ServerType=0;User=SYSDBA; Password=masterkey;Database={0};Pooling=true; connection lifetime=60;Charset=UNICODE_FSS; </ConnectionString>

<DatabasePath>c:\plastic</DatabasePath>

</DbConfig>

The connection string is a single line.

Essentially the same thing happens.

Those two fdb files are re-created in the server folder and it it does not seem to use the C:\plastic folder. In both cases, if I create a new repository, it is created in the c:\program files\plasticscm\server folder.

Also in your last post you had:

Are you using embedded Firebird (ServerType=1) or installed Firebird (ServerType=1), then?

In both cases above you have ServerType=1, which is which, please?

I don't know what else I can do to describe the situation. I'm obvisouly doing something wrong. Something must be wrong in the db.conf file.

Thanks in advance for your help.

Neal

Link to comment
Share on other sites

Sorry, I wanted to mean ServerType=1 if you're using Firebird embedded and ServerType=0 otherwise.

If I have understood correctly your problem, the databases you want to reuse were created in the default mode of Plastic SCM, that is, embedded. So, if you want to reuse them placing them in a different location, you'll need a db.conf, specifing the ConnectionString in a single line and ServerType=1. If you state ServerType=0 it'll try to use a Firebird installation and won't use the existing embedded databases. So, the db.conf file should be like the one you used in the Windows7 machine but with "ServerType=1".

Don't care about the workspaces.fdb file, this is a reminiscence of PlasticSCM 2.8.

Finally, if this doesn't work yet, could you please attach the loader.log.txt file? This is the server's log. Maybe it tells us something interesting.

Best regards,

Luis

Link to comment
Share on other sites

Thanks again.

So, I made changes to the XP case and ensured that I was doing things just like you asked. It is using the internal firbird database. I used the db.conf file that I created for for the Win7 (installed firebird database softwre), changing the Servertypoe to 1. I moved the databases to c:\plastic and it worked. Thanks.

The real goal is to use this on my Win7 OS using the external firbird. So I went back to that. I'm testing this with a virtual win7 machine on my computer. I went back to a virgin win7 OS. I installed the firbird 2.1.4 and then then I installed te plastic SCM software. I created the c:\plastic folder and created the db.conf file like I showed you before. It still is re-creating the rep_1.plastic.fdb and repositories.plastic.fdb files in the server folder. And not using the c:\plastic folder I created to hold the databases.

I then looked into the loader.log file and there were error messages like: "Error while trying to open file [c:\program files\plasticscm\server\workspaces.plastic.fdb] at ak.bg (CmConnection A_O). I will try and attach the log file for you.

Thanks again in advance for your help.

Neal

loader.log.txt

Link to comment
Share on other sites

Hi, Neal:

So, I made changes to the XP case and ensured that I was doing things just like you asked. It is using the internal firbird database. I used the db.conf file that I created for for the Win7 (installed firebird database softwre), changing the Servertypoe to 1. I moved the databases to c:\plastic and it worked. Thanks.

Great!

The real goal is to use this on my Win7 OS using the external firbird. So I went back to that. I'm testing this with a virtual win7 machine on my computer. I went back to a virgin win7 OS. I installed the firbird 2.1.4 and then then I installed te plastic SCM software. I created the c:\plastic folder and created the db.conf file like I showed you before. It still is re-creating the rep_1.plastic.fdb and repositories.plastic.fdb files in the server folder. And not using the c:\plastic folder I created to hold the databases.

I then looked into the loader.log file and there were error messages like: "Error while trying to open file [c:\program files\plasticscm\server\workspaces.plastic.fdb] at ak.bg (CmConnection A_O). I will try and attach the log file for you.

The error that appears in the log is not informative; as I told you, the workspaces database is not created anymore.

Could you check if plastic server has read/write permissions on c:\plastic? You can try and give full access temporarily just to verify that this is not the problem.

Luis

Link to comment
Share on other sites

Thanks again for your support.

I'm not quite sure how to give plastic server those rights. I did look at the security tab on both the folder c:\plastic and the several fdb files in the folder and set them all to have full access relative all users and groups. It did not seem to make any difference.

Thanks again for any insite that you can give me on this issue.

I'm tring to get this work on my laptop (Win7). If I succeed then I will install this on a Win 2003 server and start using it (actually a bunch of us will be using it).

Thanks again,

Neal Kaufman

Link to comment
Share on other sites

Hi, Neal:

I'm running out of ideas, so let me test the case and try to figure out what's happening there.

First, I want to double check the case:

- Windows Seven

- External Firebird 2.1.4

- Databases in c:\plastic

Is that right?

Thanks,

Luis

Link to comment
Share on other sites

I made it work the first try :-), following these instructions:

http://codicesoftware.blogspot.com/2011/01/upgrading-plastic-scm-to-firebird.html

Are you sure that your "db.conf" is really a "db.conf" and not a "db.conf.txt" file? Keep in mind that by default Win7 don't show the file extensions for known extensions, so if you created your db.conf file by right clicking and selecting "New file" Win7 created a db.conf.txt file. I bet that's the problem :-)

Best regards,

Luis

Link to comment
Share on other sites

I noticed that also yesterday. I really don't know if there is any compatibility issue between Plastic SCM and Firebird 2.5, so you can try and please tell us. Also, if you're willing to reuse your Firebird 2.1.4 databases in Firebird 2.5 I don't know if it's necessary an upgrade of the databases or anything like that. For instance, databases need upgrade from SQLServer CE 3.5 to SQLServer CE 4.0.

Thanks in advance for your feedback,

Luis

Link to comment
Share on other sites

I did install firebird 2.5. Since I was just testing things. I did not try and use 2.1.4 databases. Plastic does seem to work with firebird 2.5. At least the very simple initial trials that I used.

I did find another problem (I fixed it myself). I used internal firbird on one of the developers machine. I modified the db.conf to point to the folder where I wanted to store the repositories. It was something like "c:\usr\LSD\proj\2010\plastic_repositories". I got error messages when I tried to use it. However, if I used a much shorter path location: "c:\plastic_repositories" it worked.

After installing in on a developer's machine I have a whole new problem that I can use advice on. I'll start a separate thread.

Thanks for help,

Neal

Link to comment
Share on other sites

Hi Neal, Firebird 2.5 should be OK.

I also tried the database path with the embedded FireBird, could not see any issue there, my defined path for the database files was D:\D_Temp\dir1\dir2\dir3\dir4\plastic_repositories

Different drive, multiple sub-dirs, maybe in your case there was permission issues in your path?

cheers,

Miller

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...