vault CLI only fetching 5 files using GET

If you are having a problem using Vault, post a message here.

Moderator: SourceGear

Post Reply
mattyp60
Posts: 6
Joined: Tue Sep 11, 2012 6:50 am

vault CLI only fetching 5 files using GET

Post by mattyp60 » Mon Dec 31, 2012 4:57 am

System Info

Ubuntu server 10.04 LTS
java version "1.6.0_24"
OpenJDK Runtime Environment (IcedTea6 1.11.3) (6b24-1.11.3-1ubuntu0.12.04.1)
OpenJDK 64-Bit Server VM (build 20.0-b12, mixed mode)

Vault CLI version "SourceGear Vault Standard Command Line Client 5.1.2.19281"
Vault server version "[31/12/2012 12:39:44] Version Check: Your server is version 5.1.2.19281"

Problem

I am trying to use the following command to grab all files from a repository:

Code: Select all

vault GET -host xxxxxxx -ssl -user xxxxxx -password xxxxxxxxxxxx -merge overwrite -performdeletions removeworkingcopy -verbose -nonworkingfolder ~/Evolution/testpull -repository "Tyoteho WT" \$
It is a pretty large repository with about 3600 files spread out over a large directory structure.

When I run this command the output is:
log4j:WARN No appenders could be found for logger (com.cdesg.jni.natives.NativeLoader).
log4j:WARN Please initialize the log4j system properly.
This warning doesn't seem to adversely affect any other vault functions as I can do things like set working folders, list repositories etc and it still prints the <success>true</success> output when it's finished.

But with the GET call it fetches the ENTIRE directory structure but for some reason only pulls 5 files and then just kinda sits not doing anything, as if it's timed out, but there is no error or notification so I have to manually stop the command (using ctrl+C).

I have no problems pulling files from the same repo on windows using the vault GUI.

Any ideas?

Example

Not sure if this helps but in a clean directory with no working folders on the system, on the first run these files are found:
xxx@wtciserver:~/Evolution/testpull$ find . -type f
./Site/favicon.ico
./Site/settingsLocalDeployment.php
./Site/debug.php
./build.xml
./build.config
On the second run these files are found:
xxx@wtciserver:~/Evolution/testpull$ find . -type f
./Site/favicon.ico
./Site/_sgbak/settingsLocalDeployment.php.2012-12-31.13-13-56.3600
./Site/_sgbak/favicon.ico.2012-12-31.13-13-56.3720
./Site/_sgbak/debug.php.2012-12-31.13-13-56.3670
./Site/settingsLocalDeployment.php
./Site/debug.php
./build.xml
./_sgbak/build.xml.2012-12-31.13-13-56.1040
./_sgbak/build.config.2012-12-31.13-13-56.3270
./build.config
On closer inspection actually looks like some vault internal files are pulled rather than different files from the repository each time.

Beth
Posts: 8550
Joined: Wed Jun 21, 2006 8:24 pm
Location: SourceGear
Contact:

Re: vault CLI only fetching 5 files using GET

Post by Beth » Mon Dec 31, 2012 8:46 am

In your last example, that is not doing the same thing as the first thing you described. You can't perform a Get without any working folders. What it is probably doing is making the folder you get to a working folder and then building some structure in it.

What I'd like you to try for something to compare this to is set the working folder first to the place you want to perform your get to. Then perform a Get to the working folder. Does that work at all?
Beth Kieler
SourceGear Technical Support

mattyp60
Posts: 6
Joined: Tue Sep 11, 2012 6:50 am

Re: vault CLI only fetching 5 files using GET

Post by mattyp60 » Mon Dec 31, 2012 9:12 am

Hi, thanks for the response!

I don't really need a working folder so I used -nonworkingfolder but I did contradict it a little using "removeworkingcopy". I ideally just want it to grab latest from repo and delete anything that exists in that directory.

But for the sake of getting it working I will try it with a working folder:

Code: Select all

 vault SETWORKINGFOLDER -host xxx -ssl -user xxx -password xxx -repository "Tyoteho WT" \$ ~/Evolution/testpull2workingfolder/
Response:
<vault>
<listworkingfolders>
<workingfolder reposfolder="$" localfolder="/home/xxx/Evolution/testpull2workingfolder/" />
</listworkingfolders>
<result>
<success>True</success>
</result>
Then:

Code: Select all

 vault GET -host xxx -ssl -user xxx -password xxx -merge overwrite -performdeletions removeworkingcopy -verbose -repository "Tyoteho WT" \$
Response:
log4j:WARN No appenders could be found for logger (com.cdesg.jni.natives.NativeLoader).
log4j:WARN Please initialize the log4j system properly.
And it's still sat waiting again. All directories correctly fetched but gets stuck after first 5 files again:
~/Evolution/testpull2workingfolder$ find . -type f
./Site/favicon.ico
./Site/settingsLocalDeployment.php
./Site/debug.php
./build.xml
./build.config
Could the log4j warning be causing the problems do you think?

Beth
Posts: 8550
Joined: Wed Jun 21, 2006 8:24 pm
Location: SourceGear
Contact:

Re: vault CLI only fetching 5 files using GET

Post by Beth » Mon Dec 31, 2012 9:35 am

The log4j error has come up before, but it doesn't look like it was considered a problem in the past: http://support.sourcegear.com/viewtopic.php?f=5&t=12120.

Have you tried waiting for a while to see if you have just a performance problem going on?

Check your Vault Server Log on the Vault server at %windir%\temp\sgvault\sgvault.log for any errors.
Beth Kieler
SourceGear Technical Support

mattyp60
Posts: 6
Joined: Tue Sep 11, 2012 6:50 am

Re: vault CLI only fetching 5 files using GET

Post by mattyp60 » Mon Dec 31, 2012 10:05 am

Yeah when I originally tried this I left it going for a few days as I originally tried it using a jenkins plugin.

I guess this time it's been running for about an hour or two and it's still stuck on 5 files.

I'll have to get back to you with the Server Log as the network admin is on holiday at the moment.

Can you think of anything else I could try in the meantime?

Beth
Posts: 8550
Joined: Wed Jun 21, 2006 8:24 pm
Location: SourceGear
Contact:

Re: vault CLI only fetching 5 files using GET

Post by Beth » Mon Dec 31, 2012 10:38 am

Try making the command as simple as possible by removing the additional options.

vault GET -host xxx -ssl -user xxx -password xxx -repository "Tyoteho WT" -verbose $
Beth Kieler
SourceGear Technical Support

mattyp60
Posts: 6
Joined: Tue Sep 11, 2012 6:50 am

Re: vault CLI only fetching 5 files using GET

Post by mattyp60 » Tue Jan 01, 2013 3:59 am

Ok I tried that, I even tried without SSL and it grabbed a lot more files this time (around 470) but still not all of them

mattyp60
Posts: 6
Joined: Tue Sep 11, 2012 6:50 am

Re: vault CLI only fetching 5 files using GET

Post by mattyp60 » Wed Jan 02, 2013 8:44 am

Got the server log, this error appears a lot the day I was testing it with user "ciuser":
----31.12.2012 18:28:09 ciuser--nblzone-XXXXXXXXXX--SSL Disabled Uncaught Exception: Exception of type 'System.Web.HttpUnhandledException' was thrown.
Inner Exception: An error occurred while communicating with the remote host. The error code is 0x80070040.
----31.12.2012 18:28:09 ciuser--nblzone-XXXXXXX(XXXXXXX)--SSL Disabled at System.Web.UI.Page.HandleError(Exception e)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest()
at System.Web.UI.Page.ProcessRequest(HttpContext context)
at ASP.vaultfiledownload_aspx.ProcessRequest(HttpContext context)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
Inner Exeption Stack Trace: at System.Web.Hosting.ISAPIWorkerRequestInProcForIIS6.FlushCore(Byte[] status, Byte[] header, Int32 keepConnected, Int32 totalBodySize, Int32 numBodyFragments, IntPtr[] bodyFragments, Int32[] bodyFragmentLengths, Int32 doneWithSession, Int32 finalStatus, Boolean& async)
at System.Web.Hosting.ISAPIWorkerRequest.FlushCachedResponse(Boolean isFinal)
at System.Web.HttpResponse.Flush(Boolean finalFlush)
at System.IO.BufferedStream.Write(Byte[] array, Int32 offset, Int32 count)
at VaultServiceSQL.VaultSqlSCC.GetDeltaChainForFullFile(VaultSqlConn conn, Int64 nObjVerID, Int32 nBufSize, String strFileToken, Stream s, ListDictionary ldDataStreams, RunningCRC32 crc, UInt32& nCRC)
at VaultServiceAPILib.VaultFileCacheManager.GetDeltaChainForFullFile(VaultSqlConn vsConn, Int32 nRepID, Int64 nTargetObjVerID, Int32 nBufSize, String strFileToken, Stream sFullFileStream, RunningCRC32 crc, UInt32& nCRC)
at VaultServiceAPILib.VaultDelta.CreateFullFile(VaultSqlConn vsConn, Int32 nRepID, Int64 nObjVerID, String strFileToken, Boolean& deltaIfAvailable, Stream sFullFileStream, RunningCRC32 crc, UInt32& nCRC)
at VaultServiceAPILib.VaultDelta.DeltaCreate(VaultSqlConn vsConn, Int32 nRepID, Int64 nBaseObjVerID, Int64 nTargetObjVerID, String strFileToken, Stream sDeltaStream, RunningCRC32 crc, UInt32& nCRC)
at VaultServiceAPILib.VaultServiceAPI.GetVaultFile(Int32 nRepID, VaultIntDnldItem& vidi, String strFileToken, Stream s, Boolean bSeekToOrigin, Boolean bFolderExportCalcCRC, UInt32& nCRC)
at VaultService.VaultFileDownload.Page_Load(Object sender, EventArgs e)
at System.Web.UI.Control.OnLoad(EventArgs e)
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
Let me know if u need the whole log and I'll PM it to you.

Beth
Posts: 8550
Joined: Wed Jun 21, 2006 8:24 pm
Location: SourceGear
Contact:

Re: vault CLI only fetching 5 files using GET

Post by Beth » Wed Jan 02, 2013 8:52 am

This is looking a networking issue.

Could you send an email to support at sourcegear.com (attn: Beth) with a link to this forum thread?
Beth Kieler
SourceGear Technical Support

Post Reply