HELP! I lost my Data Directory when restarting TeamCity

I just lost all of my Team City configurations. Need to know if it's possible to get them back.

I have TC server installed on a linux machine, and second TC agent on a windows machine. I was installing a python plugin from the following site: https://code.google.com/p/teamcity-python/.
https://code.google.com/p/teamcity-python/When I downloaded and placed the zip file in the /<TC Data Directory>/Plugins folder, and re-started the TC service, it initialized my data directory. Now it's asking me to create a new admin account. I think i have lost all of my


Here's are my steps, if this helps anyone figure out what happened:

1. upload python.zip to my linux server

2. place python.zip in /<TC Data Directory>/Plugins folder on the linux machine

3. stopped TC service by executing "> Teamcity_7.1/bin/runall.sh stop"

at this point it told me that the JAVA_HOME directory is not set (i had set it weeks ago when i first set up the server, but now the env variable seems to have disappeared).

New Bitmap Image.bmp

4. I tried to restart the service (as you see above) by running "> Teamcity_7.1/bin/runall.sh start" but it complained again about the JAVA_HOME not being defined, and would not start the service.

5. I created the JAVA_HOME variable and pointed it to my java installation.  Then tried starting the service again.  This time it worked.

New Bitmap Image.bmp


6. Then, I stopped and started the service again, just for good measure.  Guess i just wanted to make sure the JAVA_HOME didn't disappear again.

New Bitmap Image.bmp

There's something about the buldagent.properties.lock.  Can someone explain to me what that means?


7. Then, when I finally browsed to the TeamCity home page, it told me it was initializing the Data Directory, and then showed me this:

New Bitmap Image.bmp


Does this mean all the TC projects and configurations i had created are gone for good?  Is there any way to recover them??  (No, i had not made a back up of the configurations, and yes i am kicking myself now.)

Any kind of help is appreciated!

Thanks,
GG.

2 comments
Comment actions Permalink

Gohar,

Installing a plugin is a harmless operation. Unstable plugins can affect a server performance, but it does not cause configuration data loss.

By default TeamCity stores its configuration directory under user profile.
You started TeamCity process by alternate account, so the server wasn't able to find its configs in current $HOME/.BuildServer

You need to restart the server under original account, or define system-wide TEAMCITY_DATA_PATH variable.

0
Comment actions Permalink

Thank you so much for the help Michael!

You were right. I had initially set TEAMCITY_DATA_PATH to point to a non-default data directory.  And because i had used export  to create the TEAMCITY_DATA _PATH variable, instead of something more permanent, when I restarted TeamCIty, the environment variable disappeared, and so TeamCity, not finding my original data directory, created a new one in its default location at /home/.BuildServer, and thus started up with a clean slate.

When i checked, my original data directory was still there, un-harmed. All I needed to do is set the TEAMCITY_DATA_PATH variable again (this time permanently) to point to it, and then re-start team-city. And voila.

0

Please sign in to leave a comment.